diff --git a/src/pages/processCenter/pages/components/ProcessFooter.vue b/src/pages/processCenter/pages/components/ProcessFooter.vue index c6537ed59..0e7bcbdb5 100644 --- a/src/pages/processCenter/pages/components/ProcessFooter.vue +++ b/src/pages/processCenter/pages/components/ProcessFooter.vue @@ -70,7 +70,7 @@ size="mini" class="common-button-primary" @click="handleSave" - :loading="submitLoading" + :loading="saveLoading" v-if="showSave"> 保存 @@ -80,7 +80,7 @@ size="small" class="common-button-danger" @click="beforeBack" - :loading="submitLoading" + :loading="isSubmitBack" v-if="showBack"> {{ backBTNText }} @@ -239,7 +239,7 @@ export default { type: Boolean, default: false }, - // 保存按钮loading + // 退回按钮loading isSubmitBack: { type: Boolean, default: false @@ -426,7 +426,7 @@ export default { text-align: right; background: #fff; z-index: 999; - padding: 0; + padding: 0 10px 0 0; .footer-line { height: 1px; box-shadow: 0 -1px 2px 0px #e8e8e8; diff --git a/src/pages/processCenter/pages/creatProcess/bzhHd-rh/step1.vue b/src/pages/processCenter/pages/creatProcess/bzhHd-rh/step1.vue index 7f255940a..9d714ddac 100644 --- a/src/pages/processCenter/pages/creatProcess/bzhHd-rh/step1.vue +++ b/src/pages/processCenter/pages/creatProcess/bzhHd-rh/step1.vue @@ -15,7 +15,7 @@
- + @@ -33,7 +33,7 @@ - + - + - + @@ -196,35 +196,35 @@ fontWeight: 'bold', height: '20px'}"> @@ -252,7 +252,7 @@ - +

技术委员会分委会主任/技术主管部门负责人

@@ -264,85 +264,85 @@
- + - +

责任工程师

- - + +
- + - +

参会人员所在部门负责人

- - + +
- + - +

标准法规部人员

- - + +
- + - +

标准法规部主管领导

- - + +
- + - +

费用管理部门

- - + +
- + - +

技术委员会常务副主任/总院院长

- - + +
- + - +

总院技术委员会主任

- - + +
@@ -363,6 +363,12 @@ + { + let mes = JSON.parse(res.mes) + this.rh_pageData = mes.rh_pageData + this.roleForm = mes.roleForm + }); + }, //上传按钮 - uploadFile (val) { + uploadFile(val) { }, // 文件上传限制条件 handleBeforeUpload(file) { @@ -488,13 +521,35 @@ export default { handleBeforeRemove(file, fileList) { this.fileData = fileList this.fileTextList.forEach((item, index) => { - if (item.name === file.name || item.id === file.id ) { - this.fileTextList.splice(index,1) + if (item.name === file.name || item.id === file.id) { + this.fileTextList.splice(index, 1) } }) }, // 文件上传成功 - handleOnsuccess() {}, + handleOnsuccess(res, file, fileList) { + if (res.ok) { + if (this.fileTextList !== null) { + this.newDataList = this.fileTextList + this.newDataList.push({ + id: res.data.attId, + name: res.data.standName + }) + } else { + this.newDataList.push({ + id: res.data.attId, + name: res.data.standName + }) + } + this.rh_pageData.infoSources = this.newDataList + this.$message({ + showClose: true, + message: res.message, + type: 'success' + }) + this.fileMadel = false + } + }, /** 添加 */ @@ -522,7 +577,7 @@ export default { this.deleteDataList.map(item => { let index; index = this.rh_pageData.comityTel.findIndex(items => { - return items.id === item; + return items === item; }); if (index > -1) { this.rh_pageData.comityTel.splice(index, 1); @@ -537,35 +592,88 @@ export default { // 协会外部联系方式批量选择 selectedDelete(val) { this.deleteDataList = val - console.log(val) }, // 流程阶段负责人选择 - choiceZRR (type, title, id) { + choiceZRR(type, title, id) { this.nodeList = [] this.nodeList.push(id) this.type = type this.drawerTitle = title this.roleShowflag = true }, - drawerCheck (data) { + drawerCheck(data) { + var idList = '' + var nameList = '' + data.forEach(item => { + if (nameList.length > 0) { + nameList += ',' + idList += ',' + } + idList += item.id; + nameList += item.name; + }); + if (this.type === 'feeUser') { + this.roleForm.feeUser = nameList + this.roleForm.feeUserId = idList + } else { + this.roleForm.dockUser = idList + this.roleForm.dockUserName = nameList + this.rh_pageData.comityInRole = nameList + this.rh_pageData.comityInRoleId = idList + } + this.roleShowflag = false + }, + + // 流程阶段人选择 + choiceZRROne(type, title, id) { + this.nodeListOne = [] + this.nodeListOne.push(id) + this.type = type + this.drawerTitleOne = title + this.roleShowflagOne = true + }, + drawerCheckOne(data) { this.unqualidiedData.forEach(item => { item.engineer = data[0].name item.engineerId = data[0].id }) - this.roleForm.dockUser = data[0].id - this.roleForm.dockUserName = data[0].name - this.roleShowflag = false + if (this.type === 'leaderUser') { + this.roleForm.leaderUser = data[0].name + this.roleForm.leaderUserId = data[0].id + } else { + this.roleForm.engineerUser = data[0].name + this.roleForm.engineerUserId = data[0].id + } + this.roleShowflagOne = false }, + // 保存按钮 - handleSave(){}, + handleSave() { + this.saveLoading = true + let _formData = new FormData() + _formData.append('id', this.bpnId || '') + _formData.append('createUser', this.$store.getters.userInfo.userId) + _formData.append('createUserName', this.$store.getters.userInfo.userName) + _formData.append('prcType', '20') + _formData.append('json', JSON.stringify({ + roleForm: this.roleForm, + rh_pageData: this.rh_pageData + })) + saveTaskFirst(_formData).then(res => { + this.saveLoading = false + this.$message.success('保存成功') + this.bpnId = res.result + }).catch(e => { + this.saveLoading = false + }) + }, // 提交按钮 handleSubmit() { let json = { - prcCreateUser: this.$store.getters.userInfo.userId, - prcCreateUserName: this.$store.getters.userInfo.userName, + roleList: this.roleForm, rh_pageData: this.rh_pageData, - directorList: this.roleForm.dockUser, + directorList: this.rh_pageData.comityInRoleId, } this.$refs['rh_pageData'].validate((valid) => { if (valid) { @@ -573,16 +681,16 @@ export default { if (valid) { this.isSubmit = true const paramsInfo = { - type: '11' + type: '20' } - startProcess(paramsInfo).then(res=>{ + startProcess(paramsInfo).then(res => { this.taskID = res.data const params = new FormData(); params.set('json', JSON.stringify(json)) params.set('userId', this.$store.getters.userInfo.userId) params.set('taskId', this.taskID) completeTask(params).then(res => { - if(res.success === true) { + if (res.success === true) { this.$message.success('提交成功') this.$router.push("/processCenter"); } @@ -591,7 +699,8 @@ export default { }) } }) - } }) + } + }) } } } @@ -599,15 +708,18 @@ export default { diff --git a/src/pages/processCenter/pages/creatProcess/bzhHd-rh/step5.vue b/src/pages/processCenter/pages/creatProcess/bzhHd-rh/step5.vue index 7f2ac2480..2afd920d9 100644 --- a/src/pages/processCenter/pages/creatProcess/bzhHd-rh/step5.vue +++ b/src/pages/processCenter/pages/creatProcess/bzhHd-rh/step5.vue @@ -1,13 +1,477 @@ - diff --git a/src/pages/processCenter/pages/creatProcess/bzhHd-rh/step6.vue b/src/pages/processCenter/pages/creatProcess/bzhHd-rh/step6.vue new file mode 100644 index 000000000..b82f77cb2 --- /dev/null +++ b/src/pages/processCenter/pages/creatProcess/bzhHd-rh/step6.vue @@ -0,0 +1,506 @@ + + + + + diff --git a/src/pages/processCenter/pages/creatProcess/bzhHy-ch/step1.vue b/src/pages/processCenter/pages/creatProcess/bzhHy-ch/step1.vue new file mode 100644 index 000000000..c3dc1c60a --- /dev/null +++ b/src/pages/processCenter/pages/creatProcess/bzhHy-ch/step1.vue @@ -0,0 +1,455 @@ + + + + + + diff --git a/src/pages/processCenter/pages/creatProcess/bzhHy-ch/step2.vue b/src/pages/processCenter/pages/creatProcess/bzhHy-ch/step2.vue new file mode 100644 index 000000000..0ae0c1ae0 --- /dev/null +++ b/src/pages/processCenter/pages/creatProcess/bzhHy-ch/step2.vue @@ -0,0 +1,372 @@ + + + + + diff --git a/src/pages/processCenter/pages/creatProcess/bzhHy-ch/step3.vue b/src/pages/processCenter/pages/creatProcess/bzhHy-ch/step3.vue new file mode 100644 index 000000000..949394dbc --- /dev/null +++ b/src/pages/processCenter/pages/creatProcess/bzhHy-ch/step3.vue @@ -0,0 +1,401 @@ + + + + + diff --git a/src/pages/processCenter/pages/creatProcess/bzhHy-ch/step4.vue b/src/pages/processCenter/pages/creatProcess/bzhHy-ch/step4.vue new file mode 100644 index 000000000..074766923 --- /dev/null +++ b/src/pages/processCenter/pages/creatProcess/bzhHy-ch/step4.vue @@ -0,0 +1,376 @@ + + + + + + diff --git a/src/pages/processCenter/pages/creatProcess/bzhHy-ch/step5.vue b/src/pages/processCenter/pages/creatProcess/bzhHy-ch/step5.vue new file mode 100644 index 000000000..0ddce9d3b --- /dev/null +++ b/src/pages/processCenter/pages/creatProcess/bzhHy-ch/step5.vue @@ -0,0 +1,370 @@ + + + + + + diff --git a/src/pages/processCenter/pages/creatProcess/cywbbzzxd/step1.vue b/src/pages/processCenter/pages/creatProcess/cywbbzzxd/step1.vue index 80f0fab34..18e8c2297 100644 --- a/src/pages/processCenter/pages/creatProcess/cywbbzzxd/step1.vue +++ b/src/pages/processCenter/pages/creatProcess/cywbbzzxd/step1.vue @@ -1,192 +1,78 @@ - + @@ -188,6 +196,7 @@ export default { isSubmit: false, saveLoading: false, turnLoading: false, + drawerModal: false, dataList: [], endDataList: [], lastDataList: [], @@ -240,6 +249,26 @@ export default { } }, methods: { + //确认转办 + checkedTransferRole (data) { + this.assigneeNewLoading = true + changeAssigneeNew({ + taskId: this.$route.query.taskIds, // 任务id + assignee: data[0].id, // 被委托人 + userId: this.$store.getters.userInfo.userId, // 委托人 + pId: this.$route.query.prcId // 流程实例 + }).then(res => { + this.isTransfer = false + if (res.success) { + this.drawerModal = false + this.$message.success('调整成功') + this.$router.push("/processCenter"); + this.processNum() + } else { + this.$message.warning(res.message) + } + }) + }, processTable() { this.$http.get("lawss/activiti/get_list_by_instance", { prcNum: this.$route.query.prcNum, @@ -326,51 +355,17 @@ export default { }, // 提交按钮 handleSubmit() { - this.isSubmit = true - let zqa = new Map(); - for (let lastDataListElement of this.dataList) { - let a = zqa.get(lastDataListElement.dutyPeopleInfoId) - if( a == null){ - a = { - id: lastDataListElement.dutyPeopleInfoId, - name: lastDataListElement.dutyPeopleInfo, - standardInfoList: [] - } - } - a.standardInfoList.push(lastDataListElement); - zqa.set(a.id, a); - } - let list = []; - for(let item of zqa) { - list.push(item[1]) - } - let json = { - dockUserList: list, - passInfo: this.passInfo - } - let flag=false - this.dataList.forEach(item => { - if (item.dutyPeopleInfo === '') { - flag=true - this.isSubmit = false - } - }) - if(flag)return this.$message.warning('请选择分发负责人填入') - const params = new FormData(); - params.set('json', JSON.stringify(json)) - params.set('userId', this.$store.getters.userInfo.userId) - params.set('taskIds', this.taskIds) - completeTask(params).then(res => { - if(res.success === true) { - this.$message.success('提交成功') - this.$router.push("/processCenter"); - } - this.isSubmit = false - }).catch(e => { - this.isSubmit = false - }) }, + //驳回按钮 + beforeBack(){ + }, + //转办按钮 + handleTransfer(){ + this.drawerModal = true + this.drawerTitle = '转办处理人' + this.selectPeople = row + }, // 流程阶段负责人选择 choiceZRR (type, title, id) { this.nodeList = [] diff --git a/src/pages/processCenter/pages/creatProcess/zcch/step1-1.vue b/src/pages/processCenter/pages/creatProcess/zcch/step1-1.vue new file mode 100644 index 000000000..baf107b3c --- /dev/null +++ b/src/pages/processCenter/pages/creatProcess/zcch/step1-1.vue @@ -0,0 +1,904 @@ + + + + + + + diff --git a/src/pages/processCenter/pages/creatProcess/zcch/step1.vue b/src/pages/processCenter/pages/creatProcess/zcch/step1.vue index d9b6940eb..f91509233 100644 --- a/src/pages/processCenter/pages/creatProcess/zcch/step1.vue +++ b/src/pages/processCenter/pages/creatProcess/zcch/step1.vue @@ -11,7 +11,7 @@
- + + placeholder="请选择参会时间"> @@ -66,12 +67,26 @@ > - - 点击上传 - + +
+
+ {{ item.name }} +
+
+
+ + 点击上传 + +
- {{ foldFormFlag ? '隐藏基础信息' : '展开基础信息' }} + {{ foldFormFlag ? '隐藏基础信息' : '展开基础信息' }} - +
- + 添加 - + 批量删除
@@ -109,36 +124,49 @@ row-key="id"> + + + + - +
- + 添加 - + 批量删除
@@ -153,48 +181,103 @@ row-key="id"> + + + + + + + + + + +
+ + +
+
+
@@ -207,44 +290,33 @@ class="label-input-form"> - +

流程发起人

- - + +
- + - +

法规认证部部长

- - -
-
-
-
- - - -

法规认证部副总监

-
- - + +
- +

公司副总

- - + +
@@ -262,6 +334,55 @@ @submit="handleSubmit" > + + +
+ +

点击或拖拽上传文件

+
+
+
+ + +
+ +

点击或拖拽上传文件

+
+
+
+
@@ -280,6 +401,7 @@ }, data() { return { + commentText: '', isSubmit: false, saveLoading: false, active: "1", //默认显示 @@ -291,16 +413,250 @@ time2: '', place: '', Company: '', + modelNameList: '', + modelList: [] + }, + formRules: { + title: [ + { required: true, message: '请输入课题名称', trigger: 'blur' }, + ], + content: [ + { required: true, message: '请输入主要议题', trigger: 'blur' }, + ], + price: [ + { required: true, message: '请输入费用', trigger: 'blur' }, + ], + time: [ + { required: true, message: '请选择课题研究周期', trigger: 'change' }, + ], + time2: [ + { required: true, message: '请选择参会时间', trigger: 'change' }, + ], + place: [ + { required: true, message: '请输入参会地点', trigger: 'blur' }, + ], + Company: [ + { required: true, message: '请输入承办单位', trigger: 'blur' }, + ], + modelNameList: [ + { required: true, message: '请上传课题组通知', trigger: 'blur' }, + ] }, - formRules: {}, foldFormFlag: true, data1: [], data2: [], - roleForm: {}, - roleFormRules: {} + roleForm: { + revisionId: this.$store.getters.userInfo.userId, + revisionIdName: this.$store.getters.userInfo.userName, + ministerId: '', + ministerIdName: '', + presidentId: '', + presidentIdName: '', + }, + roleFormRules: { + ministerIdName: [ + {required: true, message: '请选择法规认证部部长', trigger: 'change'}, + ], + inspectorIdName: [ + {required: true, message: '请选择法规认证部总监', trigger: 'change'}, + ], + presidentIdName: [ + {required: true, message: '请选择公司副总', trigger: 'change'}, + ] + }, + fileMadel: false, + fileMadel2: false, + fileUrl: 'api/att/attFile/upload', + idList1: [], + idList2: [], + fileIndex: '', + fileList: [], + nodeList: [], + type: '', + drawerTitle: '', + modalshowflag: false, } }, methods: { + add1() { + var id = Number(Math.random().toString().substr(3, 3) + Date.now()).toString(36); + var json = { + ContactPerson: '', + Company: '', + Telephone: '', + Email: '', + id: id + } + this.data1.push(json) + }, + add2() { + var id = Number(Math.random().toString().substr(3, 3) + Date.now()).toString(36); + var json = { + Sindex: '', + Member: '', + Company: '', + Email: '', + id: id, + Department: '', + Telephone: '', + Identity: '', + dataName: '', + data: [], + } + this.data2.push(json) + }, + addDelete1() { + if (this.idList1.length > 0) { + this.$confirm('删除选中数据, 是否继续?', '提示', { + confirmButtonText: '确定', + cancelButtonText: '取消', + type: 'warning' + }).then(() => { + for (let a = 0; a < this.data1.length; a++) { + this.idList1.forEach(item => { + if (this.data1[a].id === item) { + this.data1.splice(a, 1) + } + }) + } + }).catch(() => { + this.$message({ + type: 'info', + message: '已取消删除' + }); + }); + } else { + this.$message.warning('请选择要删除的数据') + } + }, + addDelete2() { + if (this.idList2.length > 0) { + this.$confirm('删除选中数据, 是否继续?', '提示', { + confirmButtonText: '确定', + cancelButtonText: '取消', + type: 'warning' + }).then(() => { + for (let a = 0; a < this.data2.length; a++) { + this.idList2.forEach(item => { + if (this.data2[a].id === item) { + this.data2.splice(a, 1) + } + }) + } + }).catch(() => { + this.$message({ + type: 'info', + message: '已取消删除' + }); + }); + } else { + this.$message.warning('请选择要删除的数据') + } + }, + // 导入按钮 上传之前的钩子 + beginImportFile(file) { + var filename = file.name + var index1 = filename.lastIndexOf('.') + var index2 = filename.length + var fileSuffix = filename.substring(index1, index2) + // const fileSuffix = file.name.split('.')[1] // 后缀名 + // 判断上传文件格式 + if (fileSuffix === '.ppt' || fileSuffix === '.docx' || fileSuffix === '.DOCX' || fileSuffix === '.PPT' || fileSuffix === '.xls' || fileSuffix === '.xlsx') { + return true + } else { + this.$message.error('文件' + file.name + '格式不正确,请上传PPT,DOCX,XLS文件') + return false + } + // 判断文件上传大小 + // eslint-disable-next-line no-unreachable + if (file.size / 1024 / 1024 <= 200) { + return true + } else { + this.$message.error('文件' + file.name + '大小不超过200M') + return false + } + return true + }, + importFileSuccess(response, file) { + if (response.ok) { + this.rhform.modelList.push(response.data) + let list = '' + this.rhform.modelList.forEach(item => { + if (list.length > 0) { + list += ',' + list += item.name + } else { + list+= item.name + } + }) + this.rhform.modelNameList = list + this.$message({ + showClose: true, + message: response.message, + type: 'success' + }) + } else { + this.$message.error('程序异常,上传失败') + } + }, + importFileRemove(file, fileList) { + let list = '' + this.rhform.modelList = [] + fileList.forEach(item => { + this.rhform.modelList.push(item) + if (list.length > 0) { + list += ',' + list += item.name + } else { + list+= item.name + } + }) + this.rhform.modelNameList = list + }, + importFileSuccess2(response, file) { + if (response.ok) { + this.data2[this.fileIndex].data.push(response.data) + let list = '' + this.data2[this.fileIndex].data.forEach(item => { + if (list.length > 0) { + list += ',' + list += item.name + } else { + list+= item.name + } + }) + this.data2[this.fileIndex].dataName = list + this.$message({ + showClose: true, + message: response.message, + type: 'success' + }) + } else { + this.$message.error('程序异常,上传失败') + } + }, + importFileRemove2(file, fileList) { + let list = '' + this.data2[this.fileIndex].data = [] + fileList.forEach(item => { + this.data2[this.fileIndex].data.push(item) + if (list.length > 0) { + list += ',' + list += item.name + } else { + list+= item.name + } + }) + this.data2[this.fileIndex].dataName = list + }, + fileUpload() { + this.fileMadel = true + }, + fileUpload2(index) { + this.fileIndex = index + this.fileList = this.data2[this.fileIndex].data + this.fileMadel2 = true + }, handleTabs(type) { this.active = type; }, // 切换tabs @@ -310,14 +666,139 @@ handleSave() { }, // 保存事件 handleSubmit() { - console.log(this.rhform); + this.$refs['rhForm'].validate((valid) => { + if (valid) { + if (this.data1.length) { + if (this.data2.length) { + let ContactPerson = 0,Company = 0,Telephone = 0,Email = 0,Sindex = 0,Member = 0,Telephone2 = 0,Email2 = 0, Company2 = 0,Department = 0,Identity = 0 + this.data1.forEach((item, index) =>{ + if (!item.ContactPerson) { + ContactPerson++ + } else if (!item.Company) { + Company++ + } else if (!item.Telephone) { + Telephone++ + } else if (!item.Email) { + Email++ + } + }) + this.data2.forEach((item, index) =>{ + if (!item.Sindex) { + Sindex++ + } else if (!item.Member) { + Member++ + } else if (!item.Telephone) { + Telephone2++ + } else if (!item.Email) { + Email2++ + } else if (!item.Company) { + Company2++ + } else if (!item.Department) { + Department++ + } else if (!item.Identity) { + Identity++ + } + }) + if (ContactPerson > 0) { + return this.$message.warning('请输入联络人') + } else if (Company > 0) { + return this.$message.warning('请输入课题组联络人单位') + } else if (Telephone > 0) { + return this.$message.warning('请输入课题组联络人电话') + } else if (Email > 0) { + return this.$message.warning('请输入课题组联络人邮箱') + } else if (Sindex > 0) { + return this.$message.warning('请输入工作组排名顺序') + } else if (Member > 0) { + return this.$message.warning('请输入我司成员') + } else if (Telephone2 > 0) { + return this.$message.warning('请输入内部参与人员电话') + } else if (Email2 > 0) { + return this.$message.warning('请输入内部参与人员油邮箱') + } else if (Company2 > 0) { + return this.$message.warning('请输入内部参与人员单位') + } else if (Department > 0) { + return this.$message.warning('请输入内部参与人员部门') + } else if (Identity > 0) { + return this.$message.warning('请输入内部参与人员身份') + } else { + this.$refs['Form'].validate((valid) => { + if (valid) { + this.isSubmit = true + this.$http.get('lawss/activiti/startProcess', { + type: '18' + }, {}, res => { + if (res.ok) { + var json = Object.assign(this.rhform, this.roleForm) + json.commentText = this.commentText + json.data1 = this.data1 + json.data2 = this.data2 + this.$http.post('lawss/activiti/completeTask', { + json: JSON.stringify(json), + taskId: res.data, + userId: this.$store.getters.userInfo.userId + }, {}, res => { + if (res.success) { + this.$message.success('流程发起成功') + this.$router.push('/processCenter') + this.isSubmit = false + } else { + this.$message.warning('流程启动失败') + this.isSubmit = false + } + }) + } else { + this.$message.warning('流程启动失败') + this.isSubmit = false + } + }) + } else { + return this.$message.warning('请完善人员信息') + } + }) + } + } else { + return this.$message.warning('请添加集团内部参与人员') + } + } else { + return this.$message.warning('请添加课题组人员') + } + } else { + return this.$message.warning('请完善基础信息') + } + }) }, // 提交事件 - handleSelectionChange1() { + handleSelectionChange1(val) { + this.idList1 = [] + val.forEach(item => { + this.idList1.push(item.id) + }) }, // table1选中change事件 - handleSelectionChange2() { + handleSelectionChange2(val) { + this.idList2 = [] + val.forEach(item => { + this.idList2.push(item.id) + }) }, // table2选中change事件 - choiceZRR() { + choiceZRR(type, title, id) { + this.nodeList = [] + this.nodeList.push(id) + this.type = type + this.drawerTitle = title + this.modalshowflag = true }, // 点击人员input事件 + checkedRole(data) { + if (this.type === 'ministerId') { + this.roleForm.ministerId = data[0].id + this.roleForm.ministerIdName = data[0].name + } else if (this.type === 'inspectorId') { + this.roleForm.inspectorId = data[0].id + this.roleForm.inspectorIdName = data[0].name + } else if (this.type === 'presidentId') { + this.roleForm.presidentId = data[0].id + this.roleForm.presidentIdName = data[0].name + } + }, // 选择人员确认事件 }, mounted() {} }; diff --git a/src/pages/processCenter/pages/creatProcess/zcch/step2.vue b/src/pages/processCenter/pages/creatProcess/zcch/step2.vue new file mode 100644 index 000000000..0c294ddad --- /dev/null +++ b/src/pages/processCenter/pages/creatProcess/zcch/step2.vue @@ -0,0 +1,434 @@ + + + + + + + diff --git a/src/pages/processCenter/pages/creatProcess/zcch/step3.vue b/src/pages/processCenter/pages/creatProcess/zcch/step3.vue new file mode 100644 index 000000000..b9581e109 --- /dev/null +++ b/src/pages/processCenter/pages/creatProcess/zcch/step3.vue @@ -0,0 +1,409 @@ + + + + + + + diff --git a/src/pages/processCenter/pages/creatProcess/zchh/step1.vue b/src/pages/processCenter/pages/creatProcess/zchh/step1.vue index 930ba594e..fc0833f3b 100644 --- a/src/pages/processCenter/pages/creatProcess/zchh/step1.vue +++ b/src/pages/processCenter/pages/creatProcess/zchh/step1.vue @@ -11,9 +11,8 @@
@@ -25,20 +24,15 @@ - - - - + + placeholder="请选择参会时间"> - - - - - - 点击上传 - + +
+
{{ item.name }}
+
- {{ foldFormFlag ? '隐藏基础信息' : '展开基础信息' }} + {{ foldFormFlag ? '隐藏基础信息' : '展开基础信息' }} - + + + + + + + + + + +
+
+ {{ item.name }} +
+
+
+ + 点击上传 + +
+
+
+
+
+ + -
- - 添加 - - - 批量删除 - -
- - + -
- - 添加 - - - 批量删除 - -
- + + + + + + +
+ + +
+
+
@@ -221,44 +274,22 @@ class="label-input-form"> - +

流程发起人

- - + +
- + - +

法规认证部部长

- - -
-
-
-
- - - -

法规认证部副总监

-
- - -
-
-
-
- - - -

公司副总

-
- - + +
@@ -268,14 +299,40 @@
+ + +
+ +

点击或拖拽上传文件

+
+
+
+ @@ -283,7 +340,7 @@ import ProcessHeader from "../../components/ProcessHeader"; import ProcessFooter from "../../components/ProcessFooter"; import ProcessTitle from "../../components/ProcessTitle"; - import { saveTaskFirst } from "api/process"; + import { saveTaskFirst,inboundLiaisonDetail } from "api/process"; export default { name: "zchhStep1", @@ -294,48 +351,222 @@ }, data() { return { + fileList: [], + commentText: '', isSubmit: false, saveLoading: false, active: "1", //默认显示 + hhform: { + title2: '', + modelNameList2: '', + modelList2: [] + }, + formRules: { + title2: [ + { required: true, message: '请输入会议总结', trigger: 'blur' }, + ], + modelNameList2: [ + { required: true, message: '请上传课题组通知', trigger: 'blur' }, + ] + }, rhform: { title: '', - Participants: '', content: '', price: '', time: '', time2: '', place: '', Company: '', - summary: '', + modelNameList: '', + modelList: [] }, - formRules: {}, foldFormFlag: true, data1: [], data2: [], - roleForm: {}, - roleFormRules: {} + roleForm: { + revisionId: this.$store.getters.userInfo.userId, + revisionIdName: this.$store.getters.userInfo.userName, + approvalId: '', + approvalIdName: '', + }, + roleFormRules: { + approvalIdName: [ + {required: true, message: '请选择法规认证部部长', trigger: 'change'}, + ], + }, + fileMadel: false, + fileUrl: 'api/att/attFile/upload', + nodeList: [], + type: '', + drawerTitle: '', + modalshowflag: false, + taskIds: this.$route.query.taskIds, + pId: this.$route.query.prcId, } }, methods: { + updataFj (item) { + window.location.href = '/api/att/attFile/downloadFile?fileId=' + item.id + }, + getData() { + return new Promise((resolve, reject) => { + inboundLiaisonDetail({ + taskIds: this.taskIds, + pId: this.pId + }).then(res => { + let data = JSON.parse(res.mesg) + this.json = data + this.data1 = data.data1 + this.data2 = data.data2 + this.rhform.commentText = data.commentText + this.rhform.content = data.content + this.rhform.price = data.price + this.rhform.time = data.time + this.rhform.title = data.title + this.rhform.Company = data.Company + this.rhform.place = data.place + this.rhform.time2 = data.time2 + this.rhform.modelList = data.modelList + this.rhform.modelNameList = data.modelNameList + this.hhform.title2 = data.title2 || '' + this.hhform.modelList2 = data.modelList2 || [] + this.hhform.modelNameList2 = data.modelNameList2 || '' + this.roleForm.approvalId = data.approvalId + this.roleForm.approvalIdName = data.approvalIdName + }).catch(e => { + }) + }) + }, + // 导入按钮 上传之前的钩子 + beginImportFile(file) { + var filename = file.name + var index1 = filename.lastIndexOf('.') + var index2 = filename.length + var fileSuffix = filename.substring(index1, index2) + // const fileSuffix = file.name.split('.')[1] // 后缀名 + // 判断上传文件格式 + if (fileSuffix === '.ppt' || fileSuffix === '.docx' || fileSuffix === '.DOCX' || fileSuffix === '.PPT' || fileSuffix === '.xls' || fileSuffix === '.xlsx') { + return true + } else { + this.$message.error('文件' + file.name + '格式不正确,请上传PPT,DOCX,XLS文件') + return false + } + // 判断文件上传大小 + // eslint-disable-next-line no-unreachable + if (file.size / 1024 / 1024 <= 200) { + return true + } else { + this.$message.error('文件' + file.name + '大小不超过200M') + return false + } + return true + }, + importFileSuccess(response, file) { + if (response.ok) { + this.hhform.modelList2.push(response.data) + let list = '' + this.hhform.modelList2.forEach(item => { + if (list.length > 0) { + list += ',' + list += item.name + } else { + list+= item.name + } + }) + this.hhform.modelNameList2 = list + this.$message({ + showClose: true, + message: response.message, + type: 'success' + }) + } else { + this.$message.error('程序异常,上传失败') + } + }, + importFileRemove(file, fileList) { + let list = '' + this.hhform.modelList2 = [] + fileList.forEach(item => { + this.hhform.modelList2.push(item) + if (list.length > 0) { + list += ',' + list += item.name + } else { + list+= item.name + } + }) + this.hhform.modelNameList2 = list + }, + fileUpload() { + this.fileList = this.hhform.modelList2 + this.fileMadel = true + }, handleTabs(type) { this.active = type; }, // 切换tabs foldForm() { this.foldFormFlag = !this.foldFormFlag }, // 基础信息显隐 - handleSave() { - }, // 保存事件 handleSubmit() { - console.log(this.rhform); + this.$refs['hhForm'].validate((valid) => { + if (valid) { + let info = 0 + this.data2.forEach((item, index) =>{ + if (!item.info) { + info++ + } + }) + if (info > 0) { + return this.$message.warning('请选择是否参会') + } else{ + this.$refs['Form'].validate((valid) => { + if (valid) { + this.isSubmit = true + var json = Object.assign(this.rhform, this.roleForm, this.hhform) + json.commentText = this.commentText + json.data1 = this.data1 + json.data2 = this.data2 + this.$http.post('lawss/activiti/completeTask', { + json: JSON.stringify(json), + taskId: this.taskIds, + userId: this.$store.getters.userInfo.userId + }, {}, res => { + if (res.success) { + this.$message.success('流程发起成功') + this.$router.push('/processCenter') + this.isSubmit = false + } else { + this.$message.warning('流程启动失败') + this.isSubmit = false + } + }) + } else { + return this.$message.warning('请完善人员信息') + } + }) + } + } else { + return this.$message.warning('请完善会后信息') + } + }) }, // 提交事件 - handleSelectionChange1() { - }, // table1选中change事件 - handleSelectionChange2() { - }, // table2选中change事件 - choiceZRR() { + choiceZRR(type, title, id) { + this.nodeList = [] + this.nodeList.push(id) + this.type = type + this.drawerTitle = title + this.modalshowflag = true }, // 点击人员input事件 + checkedRole(data) { + if (this.type === 'approvalId') { + this.roleForm.approvalId = data[0].id + this.roleForm.approvalIdName = data[0].name + } + }, // 选择人员确认事件 }, - mounted() {} + mounted() { + this.getData() + } }; diff --git a/src/pages/processCenter/pages/creatProcess/zchh/step2.vue b/src/pages/processCenter/pages/creatProcess/zchh/step2.vue new file mode 100644 index 000000000..33a994a10 --- /dev/null +++ b/src/pages/processCenter/pages/creatProcess/zchh/step2.vue @@ -0,0 +1,474 @@ + + + + + + + diff --git a/src/pages/processCenter/pages/creatProcess/zcrh/step1-1.vue b/src/pages/processCenter/pages/creatProcess/zcrh/step1-1.vue new file mode 100644 index 000000000..464d47d12 --- /dev/null +++ b/src/pages/processCenter/pages/creatProcess/zcrh/step1-1.vue @@ -0,0 +1,881 @@ + + + + + + + diff --git a/src/pages/processCenter/pages/creatProcess/zcrh/step1.vue b/src/pages/processCenter/pages/creatProcess/zcrh/step1.vue index e7e394d54..5945f997e 100644 --- a/src/pages/processCenter/pages/creatProcess/zcrh/step1.vue +++ b/src/pages/processCenter/pages/creatProcess/zcrh/step1.vue @@ -78,7 +78,7 @@ - {{ foldFormFlag ? '隐藏基础信息' : '展开基础信息' }} + {{ foldFormFlag ? '隐藏基础信息' : '展开基础信息' }} @@ -223,7 +223,7 @@