瀏覽代碼

修改提交任务

余思翰 1 年之前
父節點
當前提交
ee4e858278

+ 1
- 1
oa-back/ruoyi-flowable/src/main/java/com/ruoyi/flowable/service/impl/FlowTaskServiceImpl.java 查看文件

1250
                 Map<String, Object> newParameters = JSON.parseObject(JSON.toJSONString(parameters.get("variables")), Map.class);
1250
                 Map<String, Object> newParameters = JSON.parseObject(JSON.toJSONString(parameters.get("variables")), Map.class);
1251
                 FlowTaskVo flowTaskVo = new FlowTaskVo();
1251
                 FlowTaskVo flowTaskVo = new FlowTaskVo();
1252
                 flowTaskVo.setTaskId(taskId);
1252
                 flowTaskVo.setTaskId(taskId);
1253
-                newParameters.put("disabled", !((Boolean) checkIsStartUserNode(flowTaskVo).get("data")));
1253
+//                newParameters.put("disabled", !((Boolean) checkIsStartUserNode(flowTaskVo).get("data")));
1254
                 result.put("formData", newParameters);
1254
                 result.put("formData", newParameters);
1255
                 return AjaxResult.success("", result);
1255
                 return AjaxResult.success("", result);
1256
             }
1256
             }

+ 2
- 1
oa-ui/src/views/flowable/form/scForm.vue 查看文件

2
  * @Author: ysh
2
  * @Author: ysh
3
  * @Date: 2024-01-19 16:29:01
3
  * @Date: 2024-01-19 16:29:01
4
  * @LastEditors: Please set LastEditors
4
  * @LastEditors: Please set LastEditors
5
- * @LastEditTime: 2024-01-29 15:46:38
5
+ * @LastEditTime: 2024-01-29 16:51:20
6
 -->
6
 -->
7
 <template>
7
 <template>
8
   <div>
8
   <div>
143
     submit(tableForm) {
143
     submit(tableForm) {
144
       MessageBox.confirm('确认提交?', '任务提交', { confirmButtonText: '确认', cancelButtonText: '取消', type: 'warning' }).then(() => {
144
       MessageBox.confirm('确认提交?', '任务提交', { confirmButtonText: '确认', cancelButtonText: '取消', type: 'warning' }).then(() => {
145
         tableForm.formId = new Snowflake(1n, 1n, 0n).nextId().toString();
145
         tableForm.formId = new Snowflake(1n, 1n, 0n).nextId().toString();
146
+        tableForm.disabled = true;
146
         console.log(tableForm);
147
         console.log(tableForm);
147
         let formData = new FormData();
148
         let formData = new FormData();
148
         let form = JSON.stringify(tableForm);
149
         let form = JSON.stringify(tableForm);

+ 7
- 7
oa-ui/src/views/flowable/task/myProcess/send/index.vue 查看文件

17
           </el-col>
17
           </el-col>
18
         </el-tab-pane> -->
18
         </el-tab-pane> -->
19
         <el-tab-pane label="表单信息" name="1">
19
         <el-tab-pane label="表单信息" name="1">
20
-          <scform @submit="submits"></scform>
20
+          <scform @submit="submitForm"></scform>
21
         </el-tab-pane>
21
         </el-tab-pane>
22
         <!--流程图-->
22
         <!--流程图-->
23
         <el-tab-pane label="流程图" name="2">
23
         <el-tab-pane label="流程图" name="2">
56
     FlowUser,
56
     FlowUser,
57
     FlowRole,
57
     FlowRole,
58
     scform
58
     scform
59
-},
59
+  },
60
   props: {},
60
   props: {},
61
   data() {
61
   data() {
62
     return {
62
     return {
98
     submits(form) {
98
     submits(form) {
99
       getNextFlowNodeByStart({ deploymentId: this.deployId, variables: {} }).then(res => {
99
       getNextFlowNodeByStart({ deploymentId: this.deployId, variables: {} }).then(res => {
100
         let data = res.data
100
         let data = res.data
101
+        debugger
102
+        console.log(form);
101
         if (data.dataType === 'dynamic') {
103
         if (data.dataType === 'dynamic') {
102
           if (data.type === 'assignee') { // 指定人员
104
           if (data.type === 'assignee') { // 指定人员
103
             this.checkSendUser = true;
105
             this.checkSendUser = true;
229
         this.$modal.msgError("请选择流程接收角色组!");
231
         this.$modal.msgError("请选择流程接收角色组!");
230
         return;
232
         return;
231
       }
233
       }
232
-      if (this.formData.aaa) {
234
+      if (this.formData.formData == undefined) {
233
         definitionStart(this.procDefId, { approval: this.checkValues }).then(res => {
235
         definitionStart(this.procDefId, { approval: this.checkValues }).then(res => {
234
           this.$modal.msgSuccess(res.msg);
236
           this.$modal.msgSuccess(res.msg);
235
           this.goBack();
237
           this.goBack();
236
         })
238
         })
237
-
238
-      }
239
-      if (this.formData) {
239
+      }else if (this.formData) {
240
         const variables = this.formData.valData;
240
         const variables = this.formData.valData;
241
-        const formData = this.formData.formData;
241
+        let formData = this.formData.formData;
242
         // 表单是否禁用
242
         // 表单是否禁用
243
         formData.disabled = true;
243
         formData.disabled = true;
244
         // 是否显示按钮
244
         // 是否显示按钮

Loading…
取消
儲存