Browse Source

给每个流程加上结束提醒,借款添加保存按钮,预算去掉人员成本

余思翰 8 months ago
parent
commit
7fd4363a3c

+ 7
- 5
oa-ui/src/views/flowable/form/archiveForm.vue View File

2
  * @Author: ysh
2
  * @Author: ysh
3
  * @Date: 2024-06-21 18:51:51
3
  * @Date: 2024-06-21 18:51:51
4
  * @LastEditors: Please set LastEditors
4
  * @LastEditors: Please set LastEditors
5
- * @LastEditTime: 2024-09-19 13:57:28
5
+ * @LastEditTime: 2024-10-08 09:32:30
6
 -->
6
 -->
7
 <template>
7
 <template>
8
   <div class="app-container">
8
   <div class="app-container">
421
                 })
421
                 })
422
               }
422
               }
423
               if (this.taskName == '成果归档') {
423
               if (this.taskName == '成果归档') {
424
-                complete(this.taskForm).then(response => {
425
-                  this.$modal.msgSuccess(response.msg);
426
-                  this.$emit('goBack')
427
-                });
424
+                this.$modal.confirm('最后一个节点,提交将结束流程,是否提交?').then(() => {
425
+                  complete(this.taskForm).then(response => {
426
+                    this.$modal.msgSuccess(response.msg);
427
+                    this.$emit('goBack')
428
+                  });
429
+                })
428
               }
430
               }
429
             })
431
             })
430
           } else {
432
           } else {

+ 10
- 10
oa-ui/src/views/flowable/form/budget/addBudget.vue View File

1
 <!--
1
 <!--
2
  * @Author: ysh
2
  * @Author: ysh
3
  * @Date: 2024-03-25 15:05:59
3
  * @Date: 2024-03-25 15:05:59
4
- * @LastEditors: wrh
5
- * @LastEditTime: 2024-09-20 09:28:33
4
+ * @LastEditors: Please set LastEditors
5
+ * @LastEditTime: 2024-10-08 15:47:18
6
 -->
6
 -->
7
 <template>
7
 <template>
8
   <div>
8
   <div>
123
                 <tr>
123
                 <tr>
124
                   <td style="width: 80px">姓名</td>
124
                   <td style="width: 80px">姓名</td>
125
                   <td style="width: 100px">部门</td>
125
                   <td style="width: 100px">部门</td>
126
-                  <td style="width: 100px">基础工资</td>
127
-                  <td style="width: 100px">岗位工资</td>
128
-                  <td style="width: 110px">人员成本(元/天)</td>
126
+                  <!-- <td style="width: 100px">基础工资</td> -->
127
+                  <!-- <td style="width: 100px">岗位工资</td> -->
128
+                  <!-- <td style="width: 110px">人员成本(元/天)</td> -->
129
                   <!-- <td style="width: 100px">进出场单价</td> -->
129
                   <!-- <td style="width: 100px">进出场单价</td> -->
130
                   <td style="width: 100px">预算天数</td>
130
                   <td style="width: 100px">预算天数</td>
131
                   <td style="width: 100px">总额</td>
131
                   <td style="width: 100px">总额</td>
133
                 <tr v-for="user in chooseUser" :key="user.userId">
133
                 <tr v-for="user in chooseUser" :key="user.userId">
134
                   <td>{{ user.nickName }}</td>
134
                   <td>{{ user.nickName }}</td>
135
                   <td>{{ user.dept ? user.dept.deptName : user.deptName }}</td>
135
                   <td>{{ user.dept ? user.dept.deptName : user.deptName }}</td>
136
-                  <td>{{ 1780 }}</td>
137
-                  <td>{{ user.salary.salary }}</td>
138
-                  <td>{{ parseFloat((user.salary.salary + 1780) / 21.75).toFixed(2) }}</td>
136
+                  <!-- <td>{{ 1780 }}</td> -->
137
+                  <!-- <td>{{ user.salary.salary }}</td> -->
138
+                  <!-- <td>{{ parseFloat((user.salary.salary + 1780) / 21.75).toFixed(2) }}</td> -->
139
                   <td>
139
                   <td>
140
                     <el-input v-model="user.days" placeholder="请输入天数" @blur="calculateUserTotal(user)"></el-input>
140
                     <el-input v-model="user.days" placeholder="请输入天数" @blur="calculateUserTotal(user)"></el-input>
141
                   </td>
141
                   </td>
142
                   <td class="staffCost">{{ user.staffCost }}</td>
142
                   <td class="staffCost">{{ user.staffCost }}</td>
143
                 </tr>
143
                 </tr>
144
                 <tr>
144
                 <tr>
145
-                  <td colspan="6">合计</td>
145
+                  <td colspan="3">合计</td>
146
                   <td>{{ budgetForm.staffCost }}</td>
146
                   <td>{{ budgetForm.staffCost }}</td>
147
                 </tr>
147
                 </tr>
148
               </table>
148
               </table>
192
                   <td class="carCost">{{ car.expense }}</td> 
192
                   <td class="carCost">{{ car.expense }}</td> 
193
                 </tr>
193
                 </tr>
194
                 <tr>
194
                 <tr>
195
-                  <td colspan="5">合计</td>
195
+                  <td colspan="6">合计</td>
196
                   <td>{{ budgetForm.carCost }}</td>
196
                   <td>{{ budgetForm.carCost }}</td>
197
                 </tr>
197
                 </tr>
198
               </table>
198
               </table>

+ 1
- 1
oa-ui/src/views/flowable/form/budget/budget.vue View File

2
  * @Author: ysh
2
  * @Author: ysh
3
  * @Date: 2024-04-08 16:08:33
3
  * @Date: 2024-04-08 16:08:33
4
  * @LastEditors: Please set LastEditors
4
  * @LastEditors: Please set LastEditors
5
- * @LastEditTime: 2024-07-10 18:25:25
5
+ * @LastEditTime: 2024-10-08 15:23:50
6
 -->
6
 -->
7
 <template>
7
 <template>
8
   <div>
8
   <div>

+ 10
- 10
oa-ui/src/views/flowable/form/budget/components/budgetTable.vue View File

1
 <!--
1
 <!--
2
  * @Author: ysh
2
  * @Author: ysh
3
  * @Date: 2024-05-10 15:50:41
3
  * @Date: 2024-05-10 15:50:41
4
- * @LastEditors: wrh
5
- * @LastEditTime: 2024-09-20 10:23:57
4
+ * @LastEditors: Please set LastEditors
5
+ * @LastEditTime: 2024-10-08 15:58:46
6
 -->
6
 -->
7
 <template>
7
 <template>
8
   <div>
8
   <div>
59
           <table border="1" style="width: 100%;">
59
           <table border="1" style="width: 100%;">
60
             <tr v-if="userLen != 1" style="background-color:#f8f8f9">
60
             <tr v-if="userLen != 1" style="background-color:#f8f8f9">
61
               <td :rowspan="userLen" style="background-color:#f8f8f9">人员</td>
61
               <td :rowspan="userLen" style="background-color:#f8f8f9">人员</td>
62
-              <td>姓名</td>
63
-              <td>基本工资</td>
64
-              <td>岗位工资</td>
65
-              <td>人员成本(天)</td>
62
+              <td colspan="4">姓名</td>
63
+              <!-- <td>基本工资</td> -->
64
+              <!-- <td>岗位工资</td> -->
65
+              <!-- <td>人员成本(天)</td> -->
66
               <td>预算天数</td>
66
               <td>预算天数</td>
67
               <td></td>
67
               <td></td>
68
               <td>金额</td>
68
               <td>金额</td>
69
               <td>备注</td>
69
               <td>备注</td>
70
             </tr>
70
             </tr>
71
             <tr v-for="user in budgetForm.chooseUser" :key="'user' + user.userId">
71
             <tr v-for="user in budgetForm.chooseUser" :key="'user' + user.userId">
72
-              <td>{{ user.nickName }}</td>
73
-              <td>1780</td>
74
-              <td>{{ user.salary.salary }}</td>
75
-              <td>{{ parseFloat((user.salary.salary + 1780) / 21.75).toFixed(2) }}</td>
72
+              <td colspan="4">{{ user.nickName }}</td>
73
+              <!-- <td>1780</td> -->
74
+              <!-- <td>{{ user.salary.salary }}</td> -->
75
+              <!-- <td>{{ parseFloat((user.salary.salary + 1780) / 21.75).toFixed(2) }}</td> -->
76
               <!-- <td>{{ user.inOutPrice }}</td> -->
76
               <!-- <td>{{ user.inOutPrice }}</td> -->
77
               <td>{{ user.days }}</td>
77
               <td>{{ user.days }}</td>
78
               <td></td>
78
               <td></td>

+ 7
- 5
oa-ui/src/views/flowable/form/business/contractForm.vue View File

2
  * @Author: ysh
2
  * @Author: ysh
3
  * @Date: 2024-05-10 15:31:57
3
  * @Date: 2024-05-10 15:31:57
4
  * @LastEditors: Please set LastEditors
4
  * @LastEditors: Please set LastEditors
5
- * @LastEditTime: 2024-09-29 11:01:48
5
+ * @LastEditTime: 2024-10-08 09:28:41
6
 -->
6
 -->
7
 <template>
7
 <template>
8
   <div class="app-container">
8
   <div class="app-container">
975
                 });
975
                 });
976
               }
976
               }
977
               else if (this.taskName == '合同签订') {
977
               else if (this.taskName == '合同签订') {
978
-                complete(this.taskForm).then(response => {
979
-                  this.$modal.msgSuccess(response.msg);
980
-                  this.$emit('goBack')
981
-                });
978
+                this.$modal.confirm('最后一个节点,提交将结束流程,是否提交?').then(() => {
979
+                  complete(this.taskForm).then(response => {
980
+                    this.$modal.msgSuccess(response.msg);
981
+                    this.$emit('goBack')
982
+                  });
983
+                })
982
               }
984
               }
983
             })
985
             })
984
           } else {
986
           } else {

+ 4
- 2
oa-ui/src/views/flowable/form/business/subContract.vue View File

2
  * @Author: ysh
2
  * @Author: ysh
3
  * @Date: 2024-05-10 15:31:57
3
  * @Date: 2024-05-10 15:31:57
4
  * @LastEditors: Please set LastEditors
4
  * @LastEditors: Please set LastEditors
5
- * @LastEditTime: 2024-09-29 11:15:09
5
+ * @LastEditTime: 2024-10-08 09:29:11
6
 -->
6
 -->
7
 <template>
7
 <template>
8
   <div class="app-container">
8
   <div class="app-container">
919
                 handleComplete(this.taskForm);
919
                 handleComplete(this.taskForm);
920
               }
920
               }
921
               else if (this.taskName == '合同签订') {
921
               else if (this.taskName == '合同签订') {
922
-                handleComplete(this.taskForm);
922
+                this.$modal.confirm('最后一个节点,提交将结束流程,是否提交?').then(() => {
923
+                  handleComplete(this.taskForm);
924
+                })
923
               }
925
               }
924
             })
926
             })
925
           } else {
927
           } else {

+ 11
- 4
oa-ui/src/views/flowable/form/changeForm.vue View File

259
             getNextFlowNode(params).then(res => {
259
             getNextFlowNode(params).then(res => {
260
               if (this.taskName == '变更登记') {
260
               if (this.taskName == '变更登记') {
261
                 this.$set(this.taskForm.variables, "approvalList", this.leaderList);
261
                 this.$set(this.taskForm.variables, "approvalList", this.leaderList);
262
+                complete(this.taskForm).then(response => {
263
+                  this.$modal.msgSuccess(response.msg);
264
+                  this.$emit('goBack')
265
+                });
266
+              } else if (this.taskName == '变更确认') {
267
+                this.$modal.confirm('最后一个节点,提交将结束流程,是否提交?').then(() => {
268
+                  complete(this.taskForm).then(response => {
269
+                    this.$modal.msgSuccess(response.msg);
270
+                    this.$emit('goBack')
271
+                  });
272
+                })
262
               }
273
               }
263
-              complete(this.taskForm).then(response => {
264
-                this.$modal.msgSuccess(response.msg);
265
-                this.$emit('goBack')
266
-              });
267
             })
274
             })
268
           } else {
275
           } else {
269
             this.form.changeId = this.taskForm.formId;
276
             this.form.changeId = this.taskForm.formId;

+ 34
- 3
oa-ui/src/views/flowable/form/finance/borrowForm.vue View File

274
           </el-row>
274
           </el-row>
275
         </el-form>
275
         </el-form>
276
         <div style="text-align: center;" v-if="taskName != ''">
276
         <div style="text-align: center;" v-if="taskName != ''">
277
+          <el-button type="warning" @click="saves()">保 存</el-button>
277
           <el-button type="primary" @click="submitForm">提 交</el-button>
278
           <el-button type="primary" @click="submitForm">提 交</el-button>
278
         </div>
279
         </div>
279
       </el-col>
280
       </el-col>
450
   },
451
   },
451
   methods: {
452
   methods: {
452
     initRules() {
453
     initRules() {
453
-      if (this.taskName == '部门审核') {
454
+      if(this.taskName == '借款申请'){
455
+        this.rules = {
456
+          remark: [
457
+            { required: true, message: '请输入说明', trigger: 'blur' },
458
+          ],
459
+        }
460
+      }else if (this.taskName == '部门审核') {
454
         this.rules = {
461
         this.rules = {
455
           deptComment: [
462
           deptComment: [
456
             { required: true, message: '请输入部门负责人意见', trigger: 'blur' },
463
             { required: true, message: '请输入部门负责人意见', trigger: 'blur' },
461
           managerComment: [
468
           managerComment: [
462
             { required: true, message: '请输入分管领导审核意见', trigger: 'blur' }
469
             { required: true, message: '请输入分管领导审核意见', trigger: 'blur' }
463
           ],
470
           ],
464
-          managerAmount:[
471
+          managerAmount: [
465
             { required: true, message: '请输入核准金额', trigger: 'blur' }
472
             { required: true, message: '请输入核准金额', trigger: 'blur' }
466
           ]
473
           ]
467
         }
474
         }
600
         managerAmount: '',
607
         managerAmount: '',
601
       });
608
       });
602
     },
609
     },
610
+    // 保存
611
+    async saves() {
612
+      if (this.formTotal == 0) {
613
+        this.form.borrowId = this.taskForm.formId;
614
+        await addBorrow(this.form)
615
+        for (let detail of this.detailList) {
616
+          detail.borrowId = this.taskForm.formId;
617
+          await addBorrowDetail(detail);
618
+        }
619
+        this.initForm();
620
+      } else {
621
+        // 更新借款审批表
622
+        await updateBorrow(this.form);
623
+        // 更新借款明细项
624
+        await delBorrowDetail(this.taskForm.formId)
625
+        for (let detail of this.detailList) {
626
+          detail.borrowId = this.taskForm.formId;
627
+          await addBorrowDetail(detail);
628
+        }
629
+      }
630
+      this.$message.success('保存成功')
631
+    },
603
     /** 提交按钮 */
632
     /** 提交按钮 */
604
     async submitForm() {
633
     async submitForm() {
605
       if (this.taskName == '借款申请') {
634
       if (this.taskName == '借款申请') {
663
                 this.submitFD(); //提交到财务部审核
692
                 this.submitFD(); //提交到财务部审核
664
               }
693
               }
665
               else if (this.taskName == '财务处理') {
694
               else if (this.taskName == '财务处理') {
666
-                this.handleComplete(this.taskForm);
695
+                this.$modal.confirm('最后一个节点,提交将结束流程,是否提交?').then(res => {
696
+                  this.handleComplete(this.taskForm);
697
+                })
667
               }
698
               }
668
             })
699
             })
669
           } else {
700
           } else {

+ 13
- 11
oa-ui/src/views/flowable/form/oa/carForm.vue View File

1
 <!--
1
 <!--
2
  * @Author: ysh
2
  * @Author: ysh
3
  * @Date: 2024-02-29 11:44:28
3
  * @Date: 2024-02-29 11:44:28
4
- * @LastEditors: wrh
5
- * @LastEditTime: 2024-09-25 15:38:52
4
+ * @LastEditors: Please set LastEditors
5
+ * @LastEditTime: 2024-10-08 09:51:54
6
 -->
6
 -->
7
 
7
 
8
 <template>
8
 <template>
286
 import { getUsersDeptLeader, getUsersManageLeader, getDeptLeaders } from '@/api/system/post.js'
286
 import { getUsersDeptLeader, getUsersManageLeader, getDeptLeaders } from '@/api/system/post.js'
287
 import flow from '@/views/flowable/task/todo/detail/flow'
287
 import flow from '@/views/flowable/task/todo/detail/flow'
288
 import { flowXmlAndNode } from "@/api/flowable/definition";
288
 import { flowXmlAndNode } from "@/api/flowable/definition";
289
-import { listUser,getUser } from '@/api/system/user';
289
+import { listUser, getUser } from '@/api/system/user';
290
 import { getUserByRole } from "@/api/system/role";
290
 import { getUserByRole } from "@/api/system/role";
291
 import chooseUser from "@/views/flowable/form/budget/components/choosePeople.vue";
291
 import chooseUser from "@/views/flowable/form/budget/components/choosePeople.vue";
292
 import projectChoose from '@/views/flowable/form/components/chooseProject.vue';
292
 import projectChoose from '@/views/flowable/form/components/chooseProject.vue';
457
           dispatchComment: [
457
           dispatchComment: [
458
             { required: true, message: '请输入安排用车意见', trigger: 'blur' }
458
             { required: true, message: '请输入安排用车意见', trigger: 'blur' }
459
           ],
459
           ],
460
-          returnDate:[
460
+          returnDate: [
461
             { required: true, message: '返回日期不能为空', trigger: 'change' }
461
             { required: true, message: '返回日期不能为空', trigger: 'change' }
462
           ]
462
           ]
463
         }
463
         }
499
             }
499
             }
500
             data.drivers = arr
500
             data.drivers = arr
501
             this.chooseDriver = [];
501
             this.chooseDriver = [];
502
-            for(let d of arr){
503
-              getUser(Number(d)).then(res=>{
502
+            for (let d of arr) {
503
+              getUser(Number(d)).then(res => {
504
                 this.chooseDriver.push(res.data)
504
                 this.chooseDriver.push(res.data)
505
               })
505
               })
506
             }
506
             }
558
       let formData = new FormData();
558
       let formData = new FormData();
559
       let jsonForm = JSON.stringify(this.form);
559
       let jsonForm = JSON.stringify(this.form);
560
       formData.append("form", jsonForm);
560
       formData.append("form", jsonForm);
561
-      modifyCarApproval(formData).then(res=>{
561
+      modifyCarApproval(formData).then(res => {
562
         this.$message.success('保存成功')
562
         this.$message.success('保存成功')
563
       });
563
       });
564
     },
564
     },
649
           })
649
           })
650
         });
650
         });
651
       } else if (this.taskName == '安排用车') {
651
       } else if (this.taskName == '安排用车') {
652
-        complete(this.taskForm).then(response => {
653
-          this.$modal.msgSuccess(response.msg);
654
-          this.$emit('goBack')
655
-        });
652
+        this.$modal.confirm('最后一个节点,提交将结束流程,是否提交?').then(() => {
653
+          complete(this.taskForm).then(response => {
654
+            this.$modal.msgSuccess(response.msg);
655
+            this.$emit('goBack')
656
+          });
657
+        })
656
       }
658
       }
657
     },
659
     },
658
     getChooseType() {
660
     getChooseType() {

+ 8
- 7
oa-ui/src/views/flowable/form/oa/deviceForm.vue View File

2
  * @Author: ysh
2
  * @Author: ysh
3
  * @Date: 2024-03-07 13:44:39
3
  * @Date: 2024-03-07 13:44:39
4
  * @LastEditors: Please set LastEditors
4
  * @LastEditors: Please set LastEditors
5
- * @LastEditTime: 2024-08-26 13:44:24
5
+ * @LastEditTime: 2024-10-08 09:53:32
6
 -->
6
 -->
7
 
7
 
8
 <template>
8
 <template>
526
             this.$emit('goBack')
526
             this.$emit('goBack')
527
           });
527
           });
528
         });
528
         });
529
-      } else {
530
-        complete(this.taskForm).then(response => {
531
-          this.$modal.msgSuccess(response.msg);
532
-          this.$emit('goBack')
533
-        });
529
+      } else if (this.taskName == '归还确认') {
530
+        this.$modal.confirm('最后一个节点,提交将结束流程,是否提交?').then(() => {
531
+          complete(this.taskForm).then(response => {
532
+            this.$modal.msgSuccess(response.msg);
533
+            this.$emit('goBack')
534
+          });
535
+        })
534
       }
536
       }
535
-
536
     },
537
     },
537
     // 查询项目列表
538
     // 查询项目列表
538
     getProjectList() {
539
     getProjectList() {

+ 7
- 7
oa-ui/src/views/flowable/form/procure/procureForm.vue View File

1
 <!--
1
 <!--
2
  * @Author: ysh
2
  * @Author: ysh
3
  * @Date: 2024-09-19 13:45:43
3
  * @Date: 2024-09-19 13:45:43
4
- * @LastEditors: wrh
5
- * @LastEditTime: 2024-09-24 15:16:51
4
+ * @LastEditors: Please set LastEditors
5
+ * @LastEditTime: 2024-10-08 09:55:20
6
 -->
6
 -->
7
 <template>
7
 <template>
8
   <div class="app-container">
8
   <div class="app-container">
38
             <el-input type="textarea" v-model="form.planComment" :autosize="{ minRows: 4 }"
38
             <el-input type="textarea" v-model="form.planComment" :autosize="{ minRows: 4 }"
39
               :disabled="taskName != '编制计划'"></el-input>
39
               :disabled="taskName != '编制计划'"></el-input>
40
             <auditor-row ref="zhRef" :isCurrent="taskName == '编制计划'"
40
             <auditor-row ref="zhRef" :isCurrent="taskName == '编制计划'"
41
-              :signature="form.planUserId ? form.planUserId : null"
42
-              :signTime="form.planTime"></auditor-row>
41
+              :signature="form.planUserId ? form.planUserId : null" :signTime="form.planTime"></auditor-row>
43
           </el-form-item>
42
           </el-form-item>
44
           <el-form-item label="分管审核意见:" prop="managerComment" label-width="130px">
43
           <el-form-item label="分管审核意见:" prop="managerComment" label-width="130px">
45
             <el-input type="textarea" v-model="form.managerComment" :autosize="{ minRows: 4 }"
44
             <el-input type="textarea" v-model="form.managerComment" :autosize="{ minRows: 4 }"
46
               :disabled="taskName != '分管审核'"></el-input>
45
               :disabled="taskName != '分管审核'"></el-input>
47
             <auditor-row ref="fgRef" :isCurrent="taskName == '分管审核'"
46
             <auditor-row ref="fgRef" :isCurrent="taskName == '分管审核'"
48
-              :signature="form.managerUserId ? form.managerUserId : null"
49
-              :signTime="form.managerTime"></auditor-row>
47
+              :signature="form.managerUserId ? form.managerUserId : null" :signTime="form.managerTime"></auditor-row>
50
           </el-form-item>
48
           </el-form-item>
51
           <el-form-item label="总经理审批意见:" prop="zjlComment" label-width="130px">
49
           <el-form-item label="总经理审批意见:" prop="zjlComment" label-width="130px">
52
             <el-input type="textarea" v-model="form.zjlComment" :autosize="{ minRows: 4 }"
50
             <el-input type="textarea" v-model="form.zjlComment" :autosize="{ minRows: 4 }"
232
               this.$set(this.taskForm.variables, "approval", result.data[0].userId);
230
               this.$set(this.taskForm.variables, "approval", result.data[0].userId);
233
               this.successComplete();
231
               this.successComplete();
234
             } else if (this.taskName == '总经理审批') {
232
             } else if (this.taskName == '总经理审批') {
235
-              this.successComplete();
233
+              this.$modal.confirm('最后一个节点,提交将结束流程,是否提交?').then(() => {
234
+                this.successComplete();
235
+              })
236
             }
236
             }
237
           })
237
           })
238
         } else {
238
         } else {

+ 9
- 6
oa-ui/src/views/flowable/form/settleForm.vue View File

1
 <!--
1
 <!--
2
  * @Author: ysh
2
  * @Author: ysh
3
  * @Date: 2024-04-30 09:03:14
3
  * @Date: 2024-04-30 09:03:14
4
- * @LastEditors: wrh
5
- * @LastEditTime: 2024-09-18 15:23:24
4
+ * @LastEditors: Please set LastEditors
5
+ * @LastEditTime: 2024-10-08 09:34:29
6
 -->
6
 -->
7
 <template>
7
 <template>
8
   <div class="app-container" v-loading="loading">
8
   <div class="app-container" v-loading="loading">
404
             <el-row>
404
             <el-row>
405
               <el-col :span="6" :xs="24" :offset="12">
405
               <el-col :span="6" :xs="24" :offset="12">
406
                 <el-form-item label="签名:" label-width="120px">
406
                 <el-form-item label="签名:" label-width="120px">
407
-                  <span class="auditor"> {{ form.managerUserName ? form.managerUserName : getUserName(form.managerUserId) }} </span>
407
+                  <span class="auditor"> {{ form.managerUserName ? form.managerUserName :
408
+    getUserName(form.managerUserId) }}
409
+                  </span>
408
                 </el-form-item>
410
                 </el-form-item>
409
               </el-col>
411
               </el-col>
410
               <el-col :span="6">
412
               <el-col :span="6">
673
         if (settleWorkResponse) {
675
         if (settleWorkResponse) {
674
           this.settleWorkList = settleWorkResponse.rows;
676
           this.settleWorkList = settleWorkResponse.rows;
675
           for (let work of this.settleWorkList) {
677
           for (let work of this.settleWorkList) {
676
-            if(work.priceId)
678
+            if (work.priceId)
677
               getPrice(work.priceId).then((settleWorkResponse) => {
679
               getPrice(work.priceId).then((settleWorkResponse) => {
678
                 if (settleWorkResponse.data) {
680
                 if (settleWorkResponse.data) {
679
                   this.setValue(work, "scale", settleWorkResponse.data.scaleGrade);
681
                   this.setValue(work, "scale", settleWorkResponse.data.scaleGrade);
819
               this.getNextFlowNodeFn();
821
               this.getNextFlowNodeFn();
820
             }
822
             }
821
           } else if (this.taskName == "董事长批准") {
823
           } else if (this.taskName == "董事长批准") {
822
-            this.getNextFlowNodeFn();
824
+            this.$modal.confirm('最后一个节点,提交将结束流程,是否提交?').then(() => {
825
+              this.getNextFlowNodeFn();
826
+            })
823
           }
827
           }
824
-
825
         } else {
828
         } else {
826
           this.$message.error('请完善表单必填项')
829
           this.$message.error('请完善表单必填项')
827
         }
830
         }

+ 7
- 5
oa-ui/src/views/flowable/form/settleOther.vue View File

1
 <!--
1
 <!--
2
  * @Author: ysh
2
  * @Author: ysh
3
  * @Date: 2024-04-30 09:03:14
3
  * @Date: 2024-04-30 09:03:14
4
- * @LastEditors: wrh
5
- * @LastEditTime: 2024-09-02 15:38:34
4
+ * @LastEditors: Please set LastEditors
5
+ * @LastEditTime: 2024-10-08 09:38:18
6
 -->
6
 -->
7
 <template>
7
 <template>
8
   <div class="app-container" v-loading="loading">
8
   <div class="app-container" v-loading="loading">
26
             <el-col :span="6" :xs="24" :offset="12">
26
             <el-col :span="6" :xs="24" :offset="12">
27
               <el-form-item label="工作上报人:" prop="reporterName">
27
               <el-form-item label="工作上报人:" prop="reporterName">
28
                 <span class="auditor">
28
                 <span class="auditor">
29
-                  {{form.reporterName ? "" : getUserName(form.reporter) }}
29
+                  {{ form.reporterName ? "" : getUserName(form.reporter) }}
30
                 </span>
30
                 </span>
31
               </el-form-item>
31
               </el-form-item>
32
             </el-col>
32
             </el-col>
535
       this.$refs["settleForm"].validate((vaild) => {
535
       this.$refs["settleForm"].validate((vaild) => {
536
         if (vaild) {
536
         if (vaild) {
537
           this.preserve();
537
           this.preserve();
538
-          if (this.taskName == "结算发起") {            
538
+          if (this.taskName == "结算发起") {
539
             this.getNextFlowNodeFn(null, this.deptId, true);
539
             this.getNextFlowNodeFn(null, this.deptId, true);
540
           } else if (this.taskName == "分管审核") {
540
           } else if (this.taskName == "分管审核") {
541
             getUserByPost({ postName: "总经理" }).then((res) => {
541
             getUserByPost({ postName: "总经理" }).then((res) => {
542
               this.getNextFlowNodeFn(res.data[0].userId);
542
               this.getNextFlowNodeFn(res.data[0].userId);
543
             });
543
             });
544
           } else if (this.taskName == "总经理审批") {
544
           } else if (this.taskName == "总经理审批") {
545
-            this.getNextFlowNodeFn();
545
+            this.$modal.confirm('最后一个节点,提交将结束流程,是否提交?').then(() => {
546
+              this.getNextFlowNodeFn();
547
+            })
546
           }
548
           }
547
 
549
 
548
         } else {
550
         } else {

+ 9
- 7
oa-ui/src/views/flowable/form/work/declareForm.vue View File

2
  * @Author: ysh
2
  * @Author: ysh
3
  * @Date: 2024-08-16 09:16:36
3
  * @Date: 2024-08-16 09:16:36
4
  * @LastEditors: Please set LastEditors
4
  * @LastEditors: Please set LastEditors
5
- * @LastEditTime: 2024-08-21 14:11:13
5
+ * @LastEditTime: 2024-10-08 09:45:17
6
 -->
6
 -->
7
 <template>
7
 <template>
8
   <div>
8
   <div>
133
     if (this.device == 'mobile') {
133
     if (this.device == 'mobile') {
134
       this.isFlow = false;
134
       this.isFlow = false;
135
       this.deviceWidth = '450px'
135
       this.deviceWidth = '450px'
136
-    }else{
136
+    } else {
137
       this.deviceWidth = '70%'
137
       this.deviceWidth = '70%'
138
     }
138
     }
139
     if (this.isFlow) {
139
     if (this.isFlow) {
262
       }
262
       }
263
     },
263
     },
264
     confirmForm() {
264
     confirmForm() {
265
-      this.form.confirmStatus = '1';
266
-      updateDeclare(this.form);
267
-      const params = { taskId: this.taskForm.taskId };
268
-      getNextFlowNode(params).then(() => {
269
-        this.handleComplete(this.taskForm);
265
+      this.$modal.confirm('最后一个节点,提交将结束流程,是否提交?').then(() => {
266
+        this.form.confirmStatus = '1';
267
+        updateDeclare(this.form);
268
+        const params = { taskId: this.taskForm.taskId };
269
+        getNextFlowNode(params).then(() => {
270
+          this.handleComplete(this.taskForm);
271
+        })
270
       })
272
       })
271
     },
273
     },
272
     handleComplete(taskForm) {
274
     handleComplete(taskForm) {

+ 81
- 26
oa-ui/src/views/oa/project/info.vue View File

182
               </template>
182
               </template>
183
               <div style="display: flex;" class="ml20" v-if="project.undertakingDept">
183
               <div style="display: flex;" class="ml20" v-if="project.undertakingDept">
184
                 <div>{{ getDeptNames(project.undertakingDept) }}</div>
184
                 <div>{{ getDeptNames(project.undertakingDept) }}</div>
185
-                <div>
186
-                  <el-button class="ml20" type="success" plain size="mini" icon="el-icon-refresh"
187
-                    @click="deptOpen = true" v-hasPermi="['oa:project:edit']">
185
+                <div class="ml20">
186
+                  <el-button type="success" plain size="mini" icon="el-icon-refresh" @click="deptOpen = true"
187
+                    v-hasPermi="['oa:project:edit']">
188
                     更换部门
188
                     更换部门
189
                   </el-button>
189
                   </el-button>
190
                 </div>
190
                 </div>
205
               </template>
205
               </template>
206
               <div style="display: flex;" class="ml20" v-if="project.projectLeader">
206
               <div style="display: flex;" class="ml20" v-if="project.projectLeader">
207
                 <div>{{ project.projectLeaderUser ? project.projectLeaderUser.nickName : "" }}</div>
207
                 <div>{{ project.projectLeaderUser ? project.projectLeaderUser.nickName : "" }}</div>
208
-                <div>
209
-                  <el-button class="ml20" type="success" plain size="mini" icon="el-icon-refresh"
210
-                    @click="prLeaderOpen = true" v-hasPermi="['oa:project:edit']">
208
+                <div class="ml20">
209
+                  <el-button type="success" plain size="mini" icon="el-icon-refresh" @click="prLeaderOpen = true"
210
+                    v-hasPermi="['oa:project:edit']">
211
                     更换项目负责人
211
                     更换项目负责人
212
                   </el-button>
212
                   </el-button>
213
                 </div>
213
                 </div>
310
                 </div>
310
                 </div>
311
               </div>
311
               </div>
312
             </el-descriptions-item>
312
             </el-descriptions-item>
313
-            <!-- <el-descriptions-item>
314
-              <template slot="label">
315
-                <svg-icon slot="prefix" icon-class="user" />
316
-                生产部门确认
317
-              </template>
318
-              <div>
319
-                <el-input disabled type="textarea" v-model="projectComment.scComment"></el-input>
320
-                <div class="sign mt10">
321
-                  <div class="mr20">签名:<span class="auditor">{{ projectComment.scApproverName }}</span>
322
-                  </div>
323
-                  <div class="ml20"><span>审核时间:{{ projectComment.scApprovalTime }}</span></div>
324
-                </div>
325
-              </div>
326
-            </el-descriptions-item> -->
327
           </el-descriptions>
313
           </el-descriptions>
328
         </div>
314
         </div>
329
       </div>
315
       </div>
339
                 <svg-icon slot="prefix" icon-class="form" />
325
                 <svg-icon slot="prefix" icon-class="form" />
340
                 安全交底记录表
326
                 安全交底记录表
341
               </template>
327
               </template>
342
-              <el-link type="primary" @click="openSafe = true">安全交底记录表</el-link>
328
+              <el-link type="primary" @click="openSafe = true" class="mr20">安全交底记录表</el-link>
329
+              <el-button type="warning" size="mini" plain @click="handleUrge('1')"
330
+                v-if="isSend">发送企业微信消息提醒相关人员</el-button>
343
             </el-descriptions-item>
331
             </el-descriptions-item>
344
             <el-descriptions-item :span="2">
332
             <el-descriptions-item :span="2">
345
               <template slot="label">
333
               <template slot="label">
346
                 <svg-icon slot="prefix" icon-class="form" />
334
                 <svg-icon slot="prefix" icon-class="form" />
347
                 技术交底记录表
335
                 技术交底记录表
348
               </template>
336
               </template>
349
-              <el-link type="primary" @click="openTech = true">技术交底记录表</el-link>
337
+              <el-link type="primary" @click="openTech = true" class="mr20">技术交底记录表</el-link>
338
+              <el-button type="warning" size="mini" plain @click="handleUrge('2')"
339
+                v-if="isSend">发送企业微信消息提醒相关人员</el-button>
350
             </el-descriptions-item>
340
             </el-descriptions-item>
351
             <el-descriptions-item :span="2">
341
             <el-descriptions-item :span="2">
352
               <template slot="label">
342
               <template slot="label">
355
               </template>
345
               </template>
356
               <el-select v-model="devices" multiple disabled style="width:100%">
346
               <el-select v-model="devices" multiple disabled style="width:100%">
357
                 <el-option v-for="item in deviceList" :key="item.deviceId" :label="item.name + '【' + (item.brand != null ? item.brand : '') + (item.series != null ? '-' + item.series + '】' : '')
347
                 <el-option v-for="item in deviceList" :key="item.deviceId" :label="item.name + '【' + (item.brand != null ? item.brand : '') + (item.series != null ? '-' + item.series + '】' : '')
358
-        + (item.code != null ? '(设备编号:' + item.code + ')' : '') " :value="item.deviceId">
348
+        + (item.code != null ? '(设备编号:' + item.code + ')' : '')" :value="item.deviceId">
359
                 </el-option>
349
                 </el-option>
360
               </el-select>
350
               </el-select>
361
             </el-descriptions-item>
351
             </el-descriptions-item>
548
 
538
 
549
 <script>
539
 <script>
550
 import { getDept } from "@/api/system/dept";
540
 import { getDept } from "@/api/system/dept";
551
-import { getUsersDeptLeaderByDept } from '@/api/system/post'
541
+import { getUsersDeptLeaderByDept, getUserByPost, getUsersManageLeaderByDept } from '@/api/system/post'
552
 import { listUser, getUser } from "@/api/system/user";
542
 import { listUser, getUser } from "@/api/system/user";
553
 import { getProject, updateProject } from "@/api/oa/project/project";
543
 import { getProject, updateProject } from "@/api/oa/project/project";
554
 import { listProjectWork, addProjectWork } from "@/api/oa/project/projectWork";
544
 import { listProjectWork, addProjectWork } from "@/api/oa/project/projectWork";
573
 import flow from '@/views/flowable/task/todo/detail/flow'
563
 import flow from '@/views/flowable/task/todo/detail/flow'
574
 import RowDetail from '@/views/flowable/task/myProcess/send/rowDetail.vue';
564
 import RowDetail from '@/views/flowable/task/myProcess/send/rowDetail.vue';
575
 import projectPrint from '@/views/flowable/form/components/print/projectPrint.vue';
565
 import projectPrint from '@/views/flowable/form/components/print/projectPrint.vue';
566
+import { sendQyMessage } from "@/api/qywx/index"
576
 
567
 
577
 export default {
568
 export default {
578
   components: { budgetInfo, SafeTab, TechnicalTab, PlanTab, SettleData, BorrowData, BudgetTab, achiData, choosePeople, flow, RowDetail, projectPrint },
569
   components: { budgetInfo, SafeTab, TechnicalTab, PlanTab, SettleData, BorrowData, BudgetTab, achiData, choosePeople, flow, RowDetail, projectPrint },
640
       },
631
       },
641
       isProjectLeader: false,
632
       isProjectLeader: false,
642
       printOpen: false,
633
       printOpen: false,
634
+      isSend: false,
643
     }
635
     }
644
   },
636
   },
645
   methods: {
637
   methods: {
681
           if (this.project.participates && this.project.participates.trim() !== '') {
673
           if (this.project.participates && this.project.participates.trim() !== '') {
682
             this.participates = (this.project.participates.split(',')).map(Number)
674
             this.participates = (this.project.participates.split(',')).map(Number)
683
           }
675
           }
676
+          this.getManagerList();
684
         }
677
         }
685
       })
678
       })
686
     },
679
     },
680
+    // 获取该项目的分管领导
681
+    getManagerList() {
682
+      let deptArr = [];
683
+      if (this.project.undertakingDept && this.project.undertakingDept.trim() !== '') {
684
+        deptArr = (this.project.undertakingDept.split(',')).map(Number)
685
+      }
686
+      for (let deptId of deptArr) {
687
+        getUsersManageLeaderByDept({ deptId }).then(resopnse => {
688
+          if (resopnse.data) {
689
+            resopnse.data.forEach(element => {
690
+              if (this.$store.getters.userId == element.userId) {
691
+                this.isSend = true
692
+              }
693
+            });
694
+          }
695
+        })
696
+      }
697
+
698
+    },
687
     getProjectChangeList(projectId) {
699
     getProjectChangeList(projectId) {
688
       listProjectChange({ pageNum: 1, pageSize: 100, projectId }).then(response => {
700
       listProjectChange({ pageNum: 1, pageSize: 100, projectId }).then(response => {
689
         this.projectChangeList = response.rows;
701
         this.projectChangeList = response.rows;
832
       let { procInsId, deployId } = resData
844
       let { procInsId, deployId } = resData
833
       this.clickRow = { procInsId, deployId }
845
       this.clickRow = { procInsId, deployId }
834
       this.recordOpen = true;
846
       this.recordOpen = true;
847
+    },
848
+    async handleUrge(type) {
849
+      if (!this.project.projectLeader) {
850
+        this.$message.error('项目负责人未选定')
851
+        return
852
+      }
853
+      let message = ''
854
+      let user = []
855
+      let userStirngList = []
856
+      if (type == '1') {
857
+        let { data } = await getUserByPost({ postName: "专职安全员" });
858
+        user.push(data[0].userId)
859
+        message = "<font color='warning'>请尽快进行安全交底:</font>  \n>" +
860
+          "项目编号:" + this.project.projectNumber + "  \n>" +
861
+          "项目名称:" + this.project.projectName + "  \n>"
862
+      } else if (type == '2') {
863
+        message = "<font color='warning'>请尽快进行技术交底:</font>   \n>" +
864
+          "项目编号:" + this.project.projectNumber + "  \n>" +
865
+          "项目名称:" + this.project.projectName + "  \n>"
866
+      }
867
+      let deptList = (this.project.undertakingDept.split(',')).map(Number)
868
+      for (let d of deptList) {
869
+        let { data } = await getUsersDeptLeaderByDept({ deptId: d });
870
+        user.push(data.userId)
871
+      }
872
+      user.push(this.project.projectLeader)
873
+      for (let u of user) {
874
+        let { data } = await getUser(u)
875
+        userStirngList.push(data.pinyin)
876
+      }
877
+      let userString = userStirngList.join('|')
878
+      this.$confirm('是否发送企业微信消息?', '提示', {
879
+        confirmButtonText: '确定',
880
+        cancelButtonText: '取消',
881
+        type: 'warning'
882
+      }).then(() => {
883
+        let formData = new FormData();
884
+        formData.append('message', message)
885
+        formData.append('userString', userString + '|YuSiHan|WangRongHua')
886
+        sendQyMessage(formData).then(() => {
887
+          this.$message.success('消息已发送!')
888
+        })
889
+      })
835
     }
890
     }
836
   },
891
   },
837
 }
892
 }
949
   border: 1px solid #cdd0d3;
1004
   border: 1px solid #cdd0d3;
950
 }
1005
 }
951
 
1006
 
952
-::v-deep .el-tag.el-tag--info{
1007
+::v-deep .el-tag.el-tag--info {
953
   border-color: #d1d1dc;
1008
   border-color: #d1d1dc;
954
-  color:#101010
1009
+  color: #101010
955
 }
1010
 }
956
 </style>
1011
 </style>

Loading…
Cancel
Save