[update] 修改年度制修订标准化发起流程
This commit is contained in:
@@ -59,6 +59,8 @@ const standardizationInitAgree = (params) => postAction('/process/es/annualInit/
|
|||||||
const standardizationInitReject = (params) => postAction('/process/es/annualInit/reject', params)
|
const standardizationInitReject = (params) => postAction('/process/es/annualInit/reject', params)
|
||||||
// 根据流程id获取流程信息
|
// 根据流程id获取流程信息
|
||||||
const standardizationInitGetDataById = (taskId, params) => getAction(`/process/es/annualInit/handle/${taskId}`, params)
|
const standardizationInitGetDataById = (taskId, params) => getAction(`/process/es/annualInit/handle/${taskId}`, params)
|
||||||
|
// 草稿的办理回显数据
|
||||||
|
const standardizationInitGetDataDraft = (params) => getAction('', params)
|
||||||
|
|
||||||
// 企标制修订流程
|
// 企标制修订流程
|
||||||
// 保存
|
// 保存
|
||||||
@@ -373,6 +375,7 @@ export {
|
|||||||
standardizationInitAgree,
|
standardizationInitAgree,
|
||||||
standardizationInitReject,
|
standardizationInitReject,
|
||||||
standardizationInitGetDataById,
|
standardizationInitGetDataById,
|
||||||
|
standardizationInitGetDataDraft,
|
||||||
|
|
||||||
enStandardEditSave,
|
enStandardEditSave,
|
||||||
enStandardEditApproval,
|
enStandardEditApproval,
|
||||||
|
|||||||
@@ -426,6 +426,17 @@ export const EsRevisionPlanActivityReportNodes = new EsEnums({
|
|||||||
standardizationSumUp: { text: '标准化工程师归档', value: 'sid-482034AD-DB3C-4A93-9E0D-B8834F4767F0' }
|
standardizationSumUp: { text: '标准化工程师归档', value: 'sid-482034AD-DB3C-4A93-9E0D-B8834F4767F0' }
|
||||||
})
|
})
|
||||||
|
|
||||||
|
// 年度制修订计划-标准化发起
|
||||||
|
export const EsRevisionPlanStandardizationInitNodes = new EsEnums({
|
||||||
|
standardizationStart: { text: '标准化工程师发起', value: 'sid-A6DD8A92-30D8-4733-9EE3-D8C6636D73C6' },
|
||||||
|
contactSelectApprover: { text: '部所联络人选取审批人', value: 'sid-ECCB8ADE-F528-482C-8714-0D33471EF662' },
|
||||||
|
mainDrafterLeaderSend: { text: '主起草单位主管级领导审批下发', value: 'sid-B6F66797-8F09-4B84-AA8E-28B841067217' },
|
||||||
|
mainDrafterEnterInfo: { text: '主起草人填写信息', value: 'sid-2A8155BC-4634-4353-BD0E-89CE07F0D335' },
|
||||||
|
contactsApproval: { text: '部所联络人汇总', value: 'sid-69F04E36-5EDB-4693-8284-FFF3FCBE2B3D' },
|
||||||
|
mainDrafterLeaderApproval: { text: '主起草单位主管级领导批准', value: 'sid-60783E25-8671-404F-9E7D-B9181CA07B69' },
|
||||||
|
standardizationSumUp: { text: '标准化归档', value: 'sid-482034AD-DB3C-4A93-9E0D-B8834F4767F0' }
|
||||||
|
})
|
||||||
|
|
||||||
// 企标更改流程
|
// 企标更改流程
|
||||||
export const EsChangeNodes = new EsEnums({
|
export const EsChangeNodes = new EsEnums({
|
||||||
mainDrafterStart: { text: '主起草人发起', value: 'sid-030A34BF-65B2-460C-BCAB-4BFEE0F77987' },
|
mainDrafterStart: { text: '主起草人发起', value: 'sid-030A34BF-65B2-460C-BCAB-4BFEE0F77987' },
|
||||||
|
|||||||
+1
-1
@@ -241,7 +241,7 @@ export default {
|
|||||||
// 说明是已发起流程
|
// 说明是已发起流程
|
||||||
this.currentNodeName = this.$route.query.taskName
|
this.currentNodeName = this.$route.query.taskName
|
||||||
} else {
|
} else {
|
||||||
this.currentNodeName = '发起人发起'
|
this.currentNodeName = '标准化工程师发起'
|
||||||
}
|
}
|
||||||
// 如果是查看进入的,不可编辑,不可操作
|
// 如果是查看进入的,不可编辑,不可操作
|
||||||
if (this.$route.query.onlyLook) {
|
if (this.$route.query.onlyLook) {
|
||||||
|
|||||||
+63
-29
@@ -85,8 +85,8 @@
|
|||||||
|
|
||||||
<!-- 人员信息 -->
|
<!-- 人员信息 -->
|
||||||
<div v-show="switchValue === 'user'" class="detail-page-scroll-content p-0">
|
<div v-show="switchValue === 'user'" class="detail-page-scroll-content p-0">
|
||||||
<process-detail-list>
|
<process-detail-list :processKey="ProcessKey.ES_ANNUAL_INIT.value">
|
||||||
<personnel-info slot="personnelInfo" ref="personnelInfo" :data="personnelInfoData" :currentNode="currentNode"></personnel-info>
|
<personnel-info slot="personnelInfo" ref="personnelInfo" :data="personnelInfoData" :currentNode="currentNodeName"></personnel-info>
|
||||||
</process-detail-list>
|
</process-detail-list>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -144,11 +144,12 @@ import {
|
|||||||
standardizationInitTurnTo,
|
standardizationInitTurnTo,
|
||||||
standardizationInitAgree,
|
standardizationInitAgree,
|
||||||
standardizationInitReject,
|
standardizationInitReject,
|
||||||
standardizationInitGetDataById
|
standardizationInitGetDataById,
|
||||||
|
standardizationInitGetDataDraft
|
||||||
} from '@/api/workCenter'
|
} from '@/api/workCenter'
|
||||||
import pick from 'lodash.pick'
|
import pick from 'lodash.pick'
|
||||||
import { WorkCenterMixin } from '@/mixins/WorkCenterMixin'
|
import { WorkCenterMixin } from '@/mixins/WorkCenterMixin'
|
||||||
import { ProcessKey } from '../../../enums/commonEnums'
|
import { ProcessKey, EsRevisionPlanStandardizationInitNodes } from '@/enums/commonEnums'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'RevisionPlanStandardizationInitFlow',
|
name: 'RevisionPlanStandardizationInitFlow',
|
||||||
@@ -173,40 +174,61 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted () {
|
mounted () {
|
||||||
// 获取人员信息结构
|
|
||||||
this.getPersonInfoStructure(ProcessKey.ES_ANNUAL_INIT.value)
|
|
||||||
if (this.$route.query.taskId) {
|
|
||||||
this.currentNodeName = this.$route.query.taskName
|
|
||||||
// 有流程id说明是从流程中心来的,需要初始化数据
|
|
||||||
this.getProcessData(this.$route.query.taskId)
|
|
||||||
} else {
|
|
||||||
this.currentNodeName = '标准化工程师发起'
|
|
||||||
}
|
|
||||||
// 初始化节点
|
// 初始化节点
|
||||||
const taskName = this.$route.query.taskName
|
const nodeId = this.$route.query.nodeId
|
||||||
if (taskName) {
|
if (nodeId) {
|
||||||
if (taskName === '标准化工程师发起') {
|
if (nodeId === EsRevisionPlanStandardizationInitNodes.standardizationStart.value) {
|
||||||
|
// 标准化工程师发起
|
||||||
this.currentNode = 1
|
this.currentNode = 1
|
||||||
} else if (taskName === '各部所联络人 填写/下发任务') {
|
} else if (nodeId === EsRevisionPlanStandardizationInitNodes.contactSelectApprover.value) {
|
||||||
|
// 部所联络人选取审批人
|
||||||
this.currentNode = 2
|
this.currentNode = 2
|
||||||
} else if (taskName === '主起草单位主管级领导审批下发') {
|
} else if (nodeId === EsRevisionPlanStandardizationInitNodes.mainDrafterLeaderSend.value) {
|
||||||
|
// 主起草单位主管级领导审批下发
|
||||||
this.currentNode = 3
|
this.currentNode = 3
|
||||||
} else if (taskName === '主起草人填写信息') {
|
} else if (nodeId === EsRevisionPlanStandardizationInitNodes.mainDrafterEnterInfo.value) {
|
||||||
|
// 主起草人填写信息
|
||||||
this.currentNode = 4
|
this.currentNode = 4
|
||||||
} else if (taskName === '部所联络人汇总') {
|
} else if (nodeId === EsRevisionPlanStandardizationInitNodes.contactsApproval.value) {
|
||||||
|
// 部所联络人汇总
|
||||||
this.currentNode = 5
|
this.currentNode = 5
|
||||||
} else if (taskName === '主起草单位主管级领导批准') {
|
} else if (nodeId === EsRevisionPlanStandardizationInitNodes.mainDrafterLeaderApproval.value) {
|
||||||
|
// 主起草单位主管级领导批准
|
||||||
this.currentNode = 6
|
this.currentNode = 6
|
||||||
} else if (taskName === '标准化归档') {
|
} else if (nodeId === EsRevisionPlanStandardizationInitNodes.standardizationSumUp.value) {
|
||||||
|
// 标准化归档
|
||||||
this.currentNode = 7
|
this.currentNode = 7
|
||||||
} else {
|
} else {
|
||||||
// 预留加签节点
|
// 预留加签节点
|
||||||
this.currentNode = 999
|
this.currentNode = 999
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// 如果不是第一个节点,人员信息全部不可选
|
// 获取人员信息结构
|
||||||
if (this.currentNode !== 1) {
|
this.getPersonInfoStructure(ProcessKey.ES_ANNUAL_INIT.value, () => {
|
||||||
this.initPersonInfoData()
|
if (this.$route.query.processInstanceId) {
|
||||||
|
if (this.currentNode === 1) {
|
||||||
|
this.disabled = false
|
||||||
|
this.initPersonInfoData(true)
|
||||||
|
} else {
|
||||||
|
this.disabled = true
|
||||||
|
// 如果不是第一个节点,人员信息全部不可选
|
||||||
|
this.initPersonInfoData(false)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
if (this.$route.query.taskId && !this.$route.query.draftId) {
|
||||||
|
// 有流程id说明是从流程中心来的,需要初始化数据
|
||||||
|
this.getProcessData('todo', { taskId: this.$route.query.taskId })
|
||||||
|
}
|
||||||
|
if (this.$route.query.draftId) {
|
||||||
|
// 有草稿id,说明是从流程中心-草稿来的,需要初始化数据
|
||||||
|
this.getProcessData('draft', { draftId: this.$route.query.draftId, projectId: this.$route.query.projectId })
|
||||||
|
}
|
||||||
|
if (this.$route.query.taskName) {
|
||||||
|
// 说明是已发起流程
|
||||||
|
this.currentNodeName = this.$route.query.taskName
|
||||||
|
} else {
|
||||||
|
this.currentNodeName = '标准化工程师发起'
|
||||||
}
|
}
|
||||||
// 如果是查看进入的,不可编辑,不可操作
|
// 如果是查看进入的,不可编辑,不可操作
|
||||||
if (this.$route.query.onlyLook) {
|
if (this.$route.query.onlyLook) {
|
||||||
@@ -216,6 +238,7 @@ export default {
|
|||||||
},
|
},
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
|
ProcessKey,
|
||||||
loading: false,
|
loading: false,
|
||||||
switchValue: 'base',
|
switchValue: 'base',
|
||||||
processInfoForm: this.$form.createForm(this),
|
processInfoForm: this.$form.createForm(this),
|
||||||
@@ -270,15 +293,26 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
getProcessData (taskId) {
|
getProcessData (type, param) {
|
||||||
standardizationInitGetDataById(taskId).then(res => {
|
let func
|
||||||
|
let params = {}
|
||||||
|
if (type === 'todo') {
|
||||||
|
func = standardizationInitGetDataById
|
||||||
|
params = param.taskId
|
||||||
|
} else {
|
||||||
|
func = standardizationInitGetDataDraft
|
||||||
|
params = param
|
||||||
|
}
|
||||||
|
func(params).then(res => {
|
||||||
if (res.success) {
|
if (res.success) {
|
||||||
this.model = res.result
|
this.model = res.result
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
// 初始化流程信息
|
// 初始化流程信息
|
||||||
this.processInfoForm.setFieldsValue(pick(this.model.common, 'prcName', 'dueTime', 'prcMes'))
|
this.processInfoForm.setFieldsValue(pick(this.model.common, 'prcName', 'dueTime', 'prcMes'))
|
||||||
// 初始化流程审批信息,todo:需要判断是不是草稿进来的,草稿进来的才回显审批信息
|
// 初始化流程审批信息,草稿进来的才回显审批信息
|
||||||
// this.approvalInfoForm.setFieldsValue(pick(this.model[0], 'commitText', 'commitFile'))
|
if (type === 'draft') {
|
||||||
|
this.approvalInfoForm.setFieldsValue(pick(this.model.common, 'commitText', 'commitFile'))
|
||||||
|
}
|
||||||
})
|
})
|
||||||
this.$refs.baseInfoRef.initData(this.model.dataList)
|
this.$refs.baseInfoRef.initData(this.model.dataList)
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user