@lambo-design/workflow-approve 1.0.0-beta.31 → 1.0.0-beta.33
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 +3 -3
- package/src/portrait.vue +53 -37
- package/src/workflow-diagram.vue +7 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lambo-design/workflow-approve",
|
|
3
|
-
"version": "1.0.0-beta.
|
|
3
|
+
"version": "1.0.0-beta.33",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"author": "lambo",
|
|
@@ -12,8 +12,8 @@
|
|
|
12
12
|
"devDependencies": {
|
|
13
13
|
"axios": "^0.24.0",
|
|
14
14
|
"axios-cache-plugin": "^0.1.0",
|
|
15
|
-
"@lambo-design/core": "^4.7.1-beta.
|
|
16
|
-
"@lambo-design/shared": "^1.0.0-beta.
|
|
15
|
+
"@lambo-design/core": "^4.7.1-beta.147",
|
|
16
|
+
"@lambo-design/shared": "^1.0.0-beta.224"
|
|
17
17
|
},
|
|
18
18
|
"dependencies": {
|
|
19
19
|
"bpmn-js": "^7.3.1",
|
package/src/portrait.vue
CHANGED
|
@@ -208,7 +208,7 @@
|
|
|
208
208
|
<Modal v-model="modalBoxShow" width="1000" title="流程跟踪图">
|
|
209
209
|
<Workflow_Diagram ref="processTrace" :instanceId="process.instanceId" :applyId="process.applyId"
|
|
210
210
|
:procId="process.procId" :table-columns="diagramTableColumns"
|
|
211
|
-
:tableData="process.tableData" :hisAudit="hisAudit"
|
|
211
|
+
:tableData="process.tableData" :hisAudit="hisAudit" :approve-detail-show-way="approveDetailShowWay"
|
|
212
212
|
:smart-flow-server-context="smartFlowServerContext">
|
|
213
213
|
</Workflow_Diagram>
|
|
214
214
|
</Modal>
|
|
@@ -383,6 +383,18 @@ export default {
|
|
|
383
383
|
required: false,
|
|
384
384
|
default: true,
|
|
385
385
|
},
|
|
386
|
+
//流程跟踪图附件列
|
|
387
|
+
showAttachmentFile: {
|
|
388
|
+
type: Boolean,
|
|
389
|
+
required: false,
|
|
390
|
+
default: true,
|
|
391
|
+
},
|
|
392
|
+
//流程跟踪图审批详情触发方式
|
|
393
|
+
approveDetailShowWay: {
|
|
394
|
+
type: String,
|
|
395
|
+
required: false,
|
|
396
|
+
default: 'click',
|
|
397
|
+
},
|
|
386
398
|
//业务表单保存方法
|
|
387
399
|
businessFormSave: {
|
|
388
400
|
type: Function,
|
|
@@ -706,37 +718,39 @@ export default {
|
|
|
706
718
|
}, label)
|
|
707
719
|
}
|
|
708
720
|
})
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
721
|
+
if (this.showAttachmentFile){
|
|
722
|
+
column.push({
|
|
723
|
+
title: `附件`, key: 'fileList', minWidth: 200,
|
|
724
|
+
render: (h, { row }) => {
|
|
725
|
+
if (!row.fileList || row.fileList.length === 0) {
|
|
726
|
+
return h('span', '无'); // 如果没有附件,显示“无”
|
|
727
|
+
}
|
|
715
728
|
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
729
|
+
//显示所有附件
|
|
730
|
+
return h('div', row.fileList.map(file => {
|
|
731
|
+
return h('a', {
|
|
732
|
+
style: {
|
|
733
|
+
display: 'block',
|
|
734
|
+
marginTop: '5px',
|
|
735
|
+
marginRight:'5px',
|
|
736
|
+
whiteSpace: 'nowrap',
|
|
737
|
+
overflow: 'hidden',
|
|
738
|
+
textOverflow: 'ellipsis',
|
|
739
|
+
maxWidth: '100px',
|
|
740
|
+
},
|
|
741
|
+
attrs: {
|
|
742
|
+
title: file.attachName // 鼠标悬停时显示完整名称
|
|
743
|
+
},
|
|
744
|
+
on: {
|
|
745
|
+
click: () => {
|
|
746
|
+
this.getAttach(file);
|
|
747
|
+
}
|
|
748
|
+
},
|
|
749
|
+
}, file.attachName);
|
|
750
|
+
}));
|
|
751
|
+
}
|
|
752
|
+
})
|
|
753
|
+
}
|
|
740
754
|
|
|
741
755
|
return column
|
|
742
756
|
},
|
|
@@ -1129,12 +1143,14 @@ export default {
|
|
|
1129
1143
|
self.loading = false
|
|
1130
1144
|
self.disable = false
|
|
1131
1145
|
self.$Message.success(result.message);
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
|
|
1136
|
-
|
|
1137
|
-
|
|
1146
|
+
setTimeout(() => {
|
|
1147
|
+
if (result.data) {
|
|
1148
|
+
let taskIds = result.data.map(item => item.id).join(',');
|
|
1149
|
+
self.executionCompleted(true, result.data[0].processInstanceId, taskIds, auditResult, self.curTaskId)
|
|
1150
|
+
} else {
|
|
1151
|
+
self.executionCompleted(true, null, null, auditResult, self.curTaskId)
|
|
1152
|
+
}
|
|
1153
|
+
}, 1000)
|
|
1138
1154
|
} else {
|
|
1139
1155
|
self.loading = false
|
|
1140
1156
|
self.disable = false
|
package/src/workflow-diagram.vue
CHANGED
|
@@ -128,6 +128,11 @@ export default {
|
|
|
128
128
|
type: String,
|
|
129
129
|
default: "审批"
|
|
130
130
|
},
|
|
131
|
+
approveDetailShowWay: {
|
|
132
|
+
type: String,
|
|
133
|
+
required: false,
|
|
134
|
+
default: "click"
|
|
135
|
+
},
|
|
131
136
|
tableColumns: {
|
|
132
137
|
type: Array,
|
|
133
138
|
default: () => {
|
|
@@ -304,7 +309,8 @@ export default {
|
|
|
304
309
|
var eventBus = this.bpmnViewer.get("eventBus");
|
|
305
310
|
var dones = this.tableData;
|
|
306
311
|
// eventBus.on('element.click', function (evt) {
|
|
307
|
-
eventBus.on('element.hover', function (evt) {
|
|
312
|
+
// eventBus.on('element.hover', function (evt) {
|
|
313
|
+
eventBus.on(`element.${this.approveDetailShowWay}`, function (evt) {
|
|
308
314
|
self.detailDones = [];
|
|
309
315
|
for (var item of dones) {
|
|
310
316
|
if (item.taskNode == evt.element.id) {
|