sasp-flow-render 1.1.6 → 1.1.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -797,7 +797,7 @@
|
|
|
797
797
|
nodeFormButtonObj: {},
|
|
798
798
|
optColumnWidth: 336,
|
|
799
799
|
showModel: "list",//默认风格 list:列表card:卡片
|
|
800
|
-
showInfo: "",//展示信息 flow:流程信息 form:表单信息
|
|
800
|
+
showInfo: "flow",//展示信息 flow:流程信息 form:表单信息
|
|
801
801
|
operateType: {},
|
|
802
802
|
resourceTabOpts: ['draft','pending','processed','rescinded','finished','discontinue','flowQuery'],
|
|
803
803
|
tabTypeObj: {},//标签页对象
|
|
@@ -1128,6 +1128,7 @@
|
|
|
1128
1128
|
this.flowDefine = this.flowDefineByFlowId[row.flowId];
|
|
1129
1129
|
this.startNodeKeyObj = this.startNodeKeyObjByFlowId[row.flowId];
|
|
1130
1130
|
this.flowVersionNodeObj = this.flowVersionNodeObjByFlowId[row.flowId];
|
|
1131
|
+
this.initFlowObj();
|
|
1131
1132
|
// Object.assign(this.formInfo, this.formInfoByFlowId[row.flowId]);
|
|
1132
1133
|
}
|
|
1133
1134
|
|
|
@@ -1156,6 +1157,11 @@
|
|
|
1156
1157
|
openUpdateFlowForm(row,executePosition) {
|
|
1157
1158
|
this.currentRowData = row;
|
|
1158
1159
|
this.currNodeName = 'noEnd';
|
|
1160
|
+
let currentNodeObj1 = this.flowNodeIdToInfo[row.currentNode] ||{};
|
|
1161
|
+
let result = this.exeNewFlowEvent("editBefore",currentNodeObj1.nodeLinkId ||'');//新事件规则
|
|
1162
|
+
if(result === false && typeof result == "boolean"){
|
|
1163
|
+
return;
|
|
1164
|
+
}
|
|
1159
1165
|
this.flowInstDataDialog = true;
|
|
1160
1166
|
this.initUpdateFlowForm(row).then(() =>{
|
|
1161
1167
|
this.$nextTick(() => {
|
|
@@ -1347,7 +1353,6 @@
|
|
|
1347
1353
|
|
|
1348
1354
|
saveNewBatchDealFormData() {
|
|
1349
1355
|
this.saveFormInfo().then(result => {
|
|
1350
|
-
// console.log('保存方法1', result);
|
|
1351
1356
|
if (result) {
|
|
1352
1357
|
let flowNewBatchDealVm = this.$refs.flowNewBatchDealRef;
|
|
1353
1358
|
// 数据保存成功,更改行数据
|
|
@@ -1376,7 +1381,6 @@
|
|
|
1376
1381
|
});
|
|
1377
1382
|
}
|
|
1378
1383
|
this.$set(flowObj, "isEdited", true);
|
|
1379
|
-
// console.log('flowObj', flowObj, flowNewBatchDealVm);
|
|
1380
1384
|
this.flowInstDataDialog = false;
|
|
1381
1385
|
// 刷新下一步处理人
|
|
1382
1386
|
if (flowNewBatchDealVm) {
|
|
@@ -1387,7 +1391,6 @@
|
|
|
1387
1391
|
},
|
|
1388
1392
|
|
|
1389
1393
|
newBatchDealSubmit(selectionArr, submitType) {
|
|
1390
|
-
// console.log('提交',selectionArr);
|
|
1391
1394
|
if (selectionArr.length === 0) {
|
|
1392
1395
|
return this.$message.warning('请先勾选要提交的数据!');
|
|
1393
1396
|
}
|
|
@@ -1420,7 +1423,7 @@
|
|
|
1420
1423
|
nextStepSelectionArr.push(selectionObj);
|
|
1421
1424
|
}
|
|
1422
1425
|
});
|
|
1423
|
-
|
|
1426
|
+
|
|
1424
1427
|
if (params.length > 0) {
|
|
1425
1428
|
this.saveBatchDealFormData(this.formInfo.formId, JSON.stringify(params)).then(resData => {
|
|
1426
1429
|
if (resData.operateSuccess) {
|
|
@@ -1476,7 +1479,7 @@
|
|
|
1476
1479
|
selectArr.push(item);
|
|
1477
1480
|
}
|
|
1478
1481
|
});
|
|
1479
|
-
|
|
1482
|
+
|
|
1480
1483
|
if (selectArr.length === 0) {
|
|
1481
1484
|
return this.$message.warning("暂无提交内容!");
|
|
1482
1485
|
}
|
|
@@ -1649,7 +1652,6 @@
|
|
|
1649
1652
|
* @param row 流程行数据
|
|
1650
1653
|
*/
|
|
1651
1654
|
openFlowRecord(row) {
|
|
1652
|
-
console.log('流转记录',row);
|
|
1653
1655
|
let arr = ["2", "3", "4"]; // 旧版本的已办结已撤销以及已中止数据通过旧版接口查询流转记录
|
|
1654
1656
|
if (arr.indexOf(row.flowStatus) > -1 && row.isOldData === "1") {
|
|
1655
1657
|
this.flowRecordObj = {instId: row.flowInstId || "", oldDialogVisible: true};
|
|
@@ -1881,14 +1883,14 @@
|
|
|
1881
1883
|
let currentNodeObj = this.flowNodeIdToInfo[this.currentInst.currentNode || this.draftNodeId] ||{};
|
|
1882
1884
|
afterClickResult=this.exeFlowEvent("nextStep","afterClick", this.currentInst.currentNode || this.draftNodeId);
|
|
1883
1885
|
//
|
|
1884
|
-
if(currentNodeObj.openEvent
|
|
1886
|
+
if(currentNodeObj.openEvent === '1'){
|
|
1885
1887
|
afterClickResult = this.exeNewFlowEvent("nextClick",currentNodeObj.nodeLinkId);
|
|
1886
1888
|
}
|
|
1887
1889
|
|
|
1888
1890
|
// let afterValidateResult;
|
|
1889
1891
|
// let currentNodeObj = this.flowNodeIdToInfo[this.currentInst.currentNode || this.draftNodeId] ||{};
|
|
1890
1892
|
this.exeFlowEvent("nextStep","afterValidate", this.currentInst.currentNode || this.draftNodeId);
|
|
1891
|
-
if(currentNodeObj.openEvent
|
|
1893
|
+
if(currentNodeObj.openEvent === '1'){
|
|
1892
1894
|
this.exeNewFlowEvent("nextCheck",currentNodeObj.nodeLinkId);
|
|
1893
1895
|
}
|
|
1894
1896
|
|
|
@@ -2248,7 +2250,9 @@
|
|
|
2248
2250
|
Object.assign(params,this.flowParams || {},obj);
|
|
2249
2251
|
this.saspFlowAxios.post(this.api.plFlowInst.executeNextStep,params).then(res => {
|
|
2250
2252
|
if (res && res.data && res.data.operateSuccess) {
|
|
2251
|
-
this.
|
|
2253
|
+
if (!this.flowId.includes(",")) {
|
|
2254
|
+
this.initTabNum();
|
|
2255
|
+
}
|
|
2252
2256
|
this.$message({type: "success", message: "提交成功!"});
|
|
2253
2257
|
if (this.flowBatchPendingDialog) {
|
|
2254
2258
|
this.batchTabRemove(this.currentInst.dataId);
|
|
@@ -2308,7 +2312,7 @@
|
|
|
2308
2312
|
*/
|
|
2309
2313
|
sureCompleteSign() {
|
|
2310
2314
|
let checkedUserArr = this.$refs.completeSignRef.chooseUsers || [];
|
|
2311
|
-
if (checkedUserArr.length
|
|
2315
|
+
if (checkedUserArr.length === 0) {
|
|
2312
2316
|
this.$message({type: "error", message: "请选择加签人!"});
|
|
2313
2317
|
return;
|
|
2314
2318
|
}
|
|
@@ -2324,7 +2328,9 @@
|
|
|
2324
2328
|
if (res && res.data && res.data.operateSuccess) {
|
|
2325
2329
|
this.completeSignDialog = false;
|
|
2326
2330
|
this.flowInstDataDialog = false;
|
|
2327
|
-
this.
|
|
2331
|
+
if (!this.flowId.includes(",")) {
|
|
2332
|
+
this.initTabNum();
|
|
2333
|
+
}
|
|
2328
2334
|
this.$message({type: "success", message: "加签成功!"});
|
|
2329
2335
|
this.tabCrudSearch();
|
|
2330
2336
|
} else {
|
|
@@ -2339,7 +2345,7 @@
|
|
|
2339
2345
|
*/
|
|
2340
2346
|
sureTurnSign() {
|
|
2341
2347
|
let checkedUserArr = this.$refs.turnSignRef.chooseUsers || [];
|
|
2342
|
-
if (checkedUserArr.length
|
|
2348
|
+
if (checkedUserArr.length === 0) {
|
|
2343
2349
|
this.$message({type: "error", message: "请选择转签人!"});
|
|
2344
2350
|
return;
|
|
2345
2351
|
}
|
|
@@ -2352,7 +2358,9 @@
|
|
|
2352
2358
|
if (res && res.data && res.data.operateSuccess) {
|
|
2353
2359
|
this.turnSignDialog = false;
|
|
2354
2360
|
this.flowInstDataDialog = false;
|
|
2355
|
-
this.
|
|
2361
|
+
if (!this.flowId.includes(",")) {
|
|
2362
|
+
this.initTabNum();
|
|
2363
|
+
}
|
|
2356
2364
|
this.$message({type: "success", message: "转签成功!"});
|
|
2357
2365
|
this.tabCrudSearch();
|
|
2358
2366
|
} else {
|
|
@@ -2386,7 +2394,9 @@
|
|
|
2386
2394
|
}).then(res => {
|
|
2387
2395
|
if (res && res.data && res.data.operateSuccess) {
|
|
2388
2396
|
this.$message({type: "success", message: "退回成功!"});
|
|
2389
|
-
this.
|
|
2397
|
+
if (!this.flowId.includes(",")) {
|
|
2398
|
+
this.initTabNum();
|
|
2399
|
+
}
|
|
2390
2400
|
if (this.flowBatchPendingDialog) {
|
|
2391
2401
|
this.batchTabRemove(this.currentInst.dataId);
|
|
2392
2402
|
} else {
|
|
@@ -2425,7 +2435,9 @@
|
|
|
2425
2435
|
}).then(res => {
|
|
2426
2436
|
if (res && res.data && res.data.operateSuccess) {
|
|
2427
2437
|
this.$message({type: "success", message: "取回成功!"});
|
|
2428
|
-
this.
|
|
2438
|
+
if (!this.flowId.includes(",")) {
|
|
2439
|
+
this.initTabNum();
|
|
2440
|
+
}
|
|
2429
2441
|
if (this.flowBatchPendingDialog) {
|
|
2430
2442
|
this.batchTabRemove(this.currentInst.dataId);
|
|
2431
2443
|
} else {
|
|
@@ -2699,7 +2711,9 @@
|
|
|
2699
2711
|
} else {
|
|
2700
2712
|
this.tabCrudSearch();
|
|
2701
2713
|
}
|
|
2702
|
-
this.
|
|
2714
|
+
if (!this.flowId.includes(",")) {
|
|
2715
|
+
this.initTabNum();
|
|
2716
|
+
}
|
|
2703
2717
|
} else {
|
|
2704
2718
|
this.$message({type: "error", message: res.data.operateMessage});
|
|
2705
2719
|
}
|
|
@@ -3235,7 +3249,7 @@
|
|
|
3235
3249
|
// let CTX = window.JAVA_URL;
|
|
3236
3250
|
let CTX = "";
|
|
3237
3251
|
let paramValues = [this,this.saspFlowAxios,CTX,formData,this.loginUser,AjaxUtil,this.nextNode]; // 入参
|
|
3238
|
-
if(executeType == "addAfter"
|
|
3252
|
+
if(executeType == "addAfter"){ //新增或后
|
|
3239
3253
|
(this.newScriptObj[executeType] || []).forEach(event => {
|
|
3240
3254
|
event && event(...paramValues); // 执行事件
|
|
3241
3255
|
});
|
|
@@ -3275,7 +3289,7 @@
|
|
|
3275
3289
|
}
|
|
3276
3290
|
});
|
|
3277
3291
|
}catch (e) {
|
|
3278
|
-
console.log(e);
|
|
3292
|
+
// console.log(e);
|
|
3279
3293
|
result=false;
|
|
3280
3294
|
}
|
|
3281
3295
|
|
|
@@ -3339,10 +3353,12 @@
|
|
|
3339
3353
|
},
|
|
3340
3354
|
|
|
3341
3355
|
tabClick(tab) {
|
|
3342
|
-
if (this.showInfo
|
|
3356
|
+
if (this.showInfo === "flow" && this.$refs[tab.name + "Ref"] && this.$refs[tab.name + "Ref"].crud) {
|
|
3343
3357
|
this.$refs[tab.name + "Ref"].crud.search();
|
|
3344
|
-
this.
|
|
3345
|
-
|
|
3358
|
+
if (!this.flowId.includes(",")) {
|
|
3359
|
+
this.initTabNum();
|
|
3360
|
+
}
|
|
3361
|
+
} else if (this.showInfo === "form" && this.$refs[tab.name + "Ref"] && this.$refs[tab.name + "Ref"].getDataRows) {
|
|
3346
3362
|
this.$refs[tab.name + "Ref"].getDataRows();
|
|
3347
3363
|
this.initTabNum();
|
|
3348
3364
|
}
|
|
@@ -3357,6 +3373,7 @@
|
|
|
3357
3373
|
},
|
|
3358
3374
|
|
|
3359
3375
|
initFlowObj() {//处理流程定义对象
|
|
3376
|
+
this.isRefreshGetNextUsers = [];
|
|
3360
3377
|
let gatewayFields = this.flowDefine.gatewayFields || "";
|
|
3361
3378
|
this.isRefreshGetNextUsers = gatewayFields.split(",");
|
|
3362
3379
|
Object.keys(this.allNodeInfo).forEach(key => {
|
|
@@ -3370,22 +3387,24 @@
|
|
|
3370
3387
|
}
|
|
3371
3388
|
}
|
|
3372
3389
|
});
|
|
3373
|
-
|
|
3374
|
-
|
|
3375
|
-
|
|
3376
|
-
|
|
3377
|
-
|
|
3378
|
-
|
|
3379
|
-
|
|
3380
|
-
|
|
3381
|
-
|
|
3382
|
-
|
|
3383
|
-
|
|
3384
|
-
|
|
3385
|
-
|
|
3386
|
-
|
|
3387
|
-
|
|
3388
|
-
|
|
3390
|
+
if (!this.flowId.includes(",")) {
|
|
3391
|
+
let tabSetting = JSON.parse(this.flowDefine.tabSetting);
|
|
3392
|
+
tabSetting.forEach(data => {
|
|
3393
|
+
this.$set(this.tabTypeObj, data.type, data);
|
|
3394
|
+
});
|
|
3395
|
+
Object.keys(this.tabTypeObj).forEach(key => {
|
|
3396
|
+
let objTemp = this.tabTypeObj[key];
|
|
3397
|
+
objTemp.tabName = objTemp["showName"] || objTemp["name"];
|
|
3398
|
+
});
|
|
3399
|
+
let tabTitleType = this.flowDefine.tabTitleType;
|
|
3400
|
+
if (tabTitleType === "1") {
|
|
3401
|
+
this.tabTypeObj["showtTabText"] = true;
|
|
3402
|
+
this.tabTypeObj["showTabIcon"] = true;
|
|
3403
|
+
} else if (tabTitleType === "2") {
|
|
3404
|
+
this.tabTypeObj["showtTabText"] = true;
|
|
3405
|
+
} else if (tabTitleType === "3") {
|
|
3406
|
+
this.tabTypeObj["showTabIcon"] = true;
|
|
3407
|
+
}
|
|
3389
3408
|
}
|
|
3390
3409
|
},
|
|
3391
3410
|
|