@lambo-design/workflow-approve 1.0.0-beta.53 → 1.0.0-beta.55
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 +1 -1
- package/src/components/candidate-groups-box.vue +102 -91
- package/src/components/countersigners-box.vue +33 -30
- package/src/portrait.vue +279 -264
package/src/portrait.vue
CHANGED
|
@@ -26,9 +26,9 @@
|
|
|
26
26
|
<Title
|
|
27
27
|
v-if="handleButtons && (handleButtons.includes('auditOpinion') || handleButtons.includes('attachmentFile'))">
|
|
28
28
|
<a style="color: #989898">
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
29
|
+
<Icon v-if="auditShow" type="ios-arrow-down"/>
|
|
30
|
+
<Icon v-if="!auditShow" type="ios-arrow-up"/>
|
|
31
|
+
{{ handleName }}信息
|
|
32
32
|
</a>
|
|
33
33
|
</Title>
|
|
34
34
|
</a>
|
|
@@ -64,13 +64,14 @@
|
|
|
64
64
|
<Title
|
|
65
65
|
v-if="handleButtons && (handleButtons.includes('auditOpinion') || handleButtons.includes('attachmentFile'))">
|
|
66
66
|
<a style="color: #989898">
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
67
|
+
<Icon v-if="auditShow" type="ios-arrow-down"/>
|
|
68
|
+
<Icon v-if="!auditShow" type="ios-arrow-up"/>
|
|
69
|
+
{{ handleName }}信息
|
|
70
70
|
</a>
|
|
71
71
|
</Title>
|
|
72
72
|
</a>
|
|
73
|
-
<transition v-if="taskNode && isDetail && hisAuditOpinion[0].auditOpinion" name="draw"
|
|
73
|
+
<transition v-if="taskNode && isDetail && hisAuditOpinion[0].auditOpinion" name="draw"
|
|
74
|
+
@before-enter="beforeEnter"
|
|
74
75
|
@enter="enter" @before-leave="beforeLeave" @leave="leave">
|
|
75
76
|
<div class="box" v-show="auditShow">
|
|
76
77
|
<Form ref="auditOpinion" justify="center" :model="form"
|
|
@@ -91,9 +92,9 @@
|
|
|
91
92
|
<a @click="historyShow = !historyShow">
|
|
92
93
|
<Title v-if="handleButtons && handleButtons.includes('auditHistory')">
|
|
93
94
|
<a style="color: #989898">
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
95
|
+
<Icon v-if="historyShow" type="ios-arrow-down"/>
|
|
96
|
+
<Icon v-if="!historyShow" type="ios-arrow-up"/>
|
|
97
|
+
{{ handleName }}记录
|
|
97
98
|
</a>
|
|
98
99
|
</Title>
|
|
99
100
|
</a>
|
|
@@ -101,7 +102,8 @@
|
|
|
101
102
|
<div class="box" v-show="historyShow">
|
|
102
103
|
<Card class="process-history" :style="processHistoryHeight" dis-hover :bordered="false"
|
|
103
104
|
v-if="handleButtons && handleButtons.includes('auditHistory')">
|
|
104
|
-
<processHistory :portrait-width="portraitWidth" :list="processHistory" :done-page="isDetail"
|
|
105
|
+
<processHistory :portrait-width="portraitWidth" :list="processHistory" :done-page="isDetail"
|
|
106
|
+
:push-button="pushButton"
|
|
105
107
|
:smart-flow-server-context="smartFlowServerContext"></processHistory>
|
|
106
108
|
</Card>
|
|
107
109
|
</div>
|
|
@@ -110,9 +112,9 @@
|
|
|
110
112
|
<a @click="attachListShow = !attachListShow">
|
|
111
113
|
<Title v-if="handleButtons && handleButtons.includes('attachmentFile') && attachmentList.length > 0">
|
|
112
114
|
<a style="color: #989898">
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
115
|
+
<Icon v-if="attachListShow" type="ios-arrow-down"/>
|
|
116
|
+
<Icon v-if="!attachListShow" type="ios-arrow-up"/>
|
|
117
|
+
查看附件
|
|
116
118
|
</a>
|
|
117
119
|
</Title>
|
|
118
120
|
</a>
|
|
@@ -202,13 +204,15 @@
|
|
|
202
204
|
</Table>
|
|
203
205
|
</Modal>
|
|
204
206
|
<assigneeBox ref="assigneeHelpBox" :execution-completed="executionCompleted"
|
|
205
|
-
@update-selected="handleSelectedUser" @update-next-node-assignee="updateNextNodeAssignee"
|
|
207
|
+
@update-selected="handleSelectedUser" @update-next-node-assignee="updateNextNodeAssignee"
|
|
208
|
+
@add-multitask-instance="addMultitaskInstance"
|
|
206
209
|
:data="assigneeBoxData" :smart-flow-server-context="smartFlowServerContext"
|
|
207
210
|
:upms-server-context="upmsServerContext"/>
|
|
208
211
|
<Modal v-model="modalBoxShow" width="1000" title="流程跟踪图">
|
|
209
212
|
<Workflow_Diagram ref="processTrace" :instanceId="process.instanceId" :applyId="process.applyId"
|
|
210
213
|
:procId="process.procId" :table-columns="diagramTableColumns"
|
|
211
|
-
:tableData="process.tableData" :hisAudit="hisAudit"
|
|
214
|
+
:tableData="process.tableData" :hisAudit="hisAudit"
|
|
215
|
+
:approve-detail-show-way="approveDetailShowWay"
|
|
212
216
|
:smart-flow-server-context="smartFlowServerContext">
|
|
213
217
|
</Workflow_Diagram>
|
|
214
218
|
</Modal>
|
|
@@ -246,7 +250,8 @@
|
|
|
246
250
|
@on-focus="readingRangeClick(item)"
|
|
247
251
|
@on-click="readingRangeClick(item)"/>
|
|
248
252
|
</FormItem>
|
|
249
|
-
<FormItem label="候选人员:" prop="candidateGroups"
|
|
253
|
+
<FormItem label="候选人员:" prop="candidateGroups"
|
|
254
|
+
v-if="!item.isMultiInstance && item.actionType === 'CAND'">
|
|
250
255
|
<Input v-model="item.candidateNames"
|
|
251
256
|
placeholder="请选择候选人"
|
|
252
257
|
style="width: 68%"
|
|
@@ -254,11 +259,15 @@
|
|
|
254
259
|
@on-focus="candidateGroupsReadingRangeClick(item)"
|
|
255
260
|
@on-click="candidateGroupsReadingRangeClick(item)"/>
|
|
256
261
|
</FormItem>
|
|
257
|
-
<FormItem label="候选人员:" prop="candidateGroups"
|
|
262
|
+
<FormItem label="候选人员:" prop="candidateGroups"
|
|
263
|
+
v-if="item.isMultiInstance && item.actionType === 'CAND'">
|
|
258
264
|
</FormItem>
|
|
259
265
|
|
|
260
|
-
<countersingersBox style="margin-bottom: 10px" v-model="item.candidateNames"
|
|
261
|
-
|
|
266
|
+
<countersingersBox style="margin-bottom: 10px" v-model="item.candidateNames"
|
|
267
|
+
v-if="item.isMultiInstance && item.actionType === 'CAND'"
|
|
268
|
+
:item="item" :permScope="permScope" @update-cand-groups="updateCandGroups"
|
|
269
|
+
:upms-server-context="upmsServerContext"
|
|
270
|
+
:smart-flow-server-context="smartFlowServerContext"/>
|
|
262
271
|
</div>
|
|
263
272
|
<div v-if="handleButtons && handleButtons.includes('appointTimeoutTime')">
|
|
264
273
|
<Row>
|
|
@@ -302,8 +311,10 @@
|
|
|
302
311
|
</Form>
|
|
303
312
|
</Card>
|
|
304
313
|
</Modal>
|
|
305
|
-
<candidateGroupsHelpBox ref="candidateGroupsHelpBox" :show="candidateGroupsHelpBoxShow"
|
|
306
|
-
|
|
314
|
+
<candidateGroupsHelpBox ref="candidateGroupsHelpBox" :show="candidateGroupsHelpBoxShow"
|
|
315
|
+
@update-cand-groups="updateCandGroups"
|
|
316
|
+
:upms-server-context="upmsServerContext"
|
|
317
|
+
:smart-flow-server-context="smartFlowServerContext"/>
|
|
307
318
|
<template slot="page-footer">
|
|
308
319
|
<div>
|
|
309
320
|
<slot name="footer-button"></slot>
|
|
@@ -322,10 +333,12 @@
|
|
|
322
333
|
<Button style="margin-left: 10px;" v-if="handleButtons && handleButtons.includes('auditTo82') && !isDetail"
|
|
323
334
|
:disabled="disable" :loading="loading" @click="audit('82')">指定他人处理
|
|
324
335
|
</Button>
|
|
325
|
-
<Button style="margin-left: 10px;"
|
|
336
|
+
<Button style="margin-left: 10px;"
|
|
337
|
+
v-if="isParallelCountersignature && handleButtons && handleButtons.includes('addMultitaskInstance') && !isDetail"
|
|
326
338
|
:disabled="disable" :loading="loading" @click="showUpdateMultitaskInstanceModal('81')">加签
|
|
327
339
|
</Button>
|
|
328
|
-
<Button style="margin-left: 10px;"
|
|
340
|
+
<Button style="margin-left: 10px;"
|
|
341
|
+
v-if="isParallelCountersignature && handleButtons && handleButtons.includes('reductionMultitaskInstance') && !isDetail"
|
|
329
342
|
:disabled="disable" :loading="loading" @click="showUpdateMultitaskInstanceModal('83')">减签
|
|
330
343
|
</Button>
|
|
331
344
|
<Button style="margin-left: 10px;" v-if="handleButtons && handleButtons.includes('auditTo50') && !isDetail"
|
|
@@ -347,22 +360,21 @@
|
|
|
347
360
|
import LamboPageContainer from '@lambo-design/page-container'
|
|
348
361
|
import LamboIndicatorCard from '@lambo-design/indicator-card'
|
|
349
362
|
import Workflow_Diagram from './workflow-diagram'
|
|
350
|
-
import ajax from
|
|
351
|
-
import bus from '@lambo-design/shared/utils/bus'
|
|
352
|
-
import Title from
|
|
353
|
-
import processHistory from
|
|
354
|
-
import assigneeBox from
|
|
355
|
-
import CandidateGroupsHelpBox from
|
|
356
|
-
import CountersingersBox from
|
|
357
|
-
import LamboPagingTable from
|
|
358
|
-
import AuditOpinion from
|
|
359
|
-
import axios from
|
|
360
|
-
import UploadFile from
|
|
361
|
-
import {timestampToTime} from
|
|
363
|
+
import ajax from '@lambo-design/shared/utils/ajax'
|
|
364
|
+
import bus from '@lambo-design/shared/utils/bus'
|
|
365
|
+
import Title from './components/title'
|
|
366
|
+
import processHistory from './components/history'
|
|
367
|
+
import assigneeBox from './components/assignee-box'
|
|
368
|
+
import CandidateGroupsHelpBox from './components/candidate-groups-box'
|
|
369
|
+
import CountersingersBox from './components/countersigners-box'
|
|
370
|
+
import LamboPagingTable from '@lambo-design/paging-table'
|
|
371
|
+
import AuditOpinion from './components/opinion'
|
|
372
|
+
import axios from 'axios'
|
|
373
|
+
import UploadFile from '@lambo-design/upload-file'
|
|
374
|
+
import { timestampToTime } from '@lambo-design/shared/utils/date'
|
|
362
375
|
|
|
363
376
|
// 引入docx-preview插件
|
|
364
|
-
let docx = require('docx-preview')
|
|
365
|
-
|
|
377
|
+
let docx = require('docx-preview')
|
|
366
378
|
|
|
367
379
|
export default {
|
|
368
380
|
props: {
|
|
@@ -430,11 +442,12 @@ export default {
|
|
|
430
442
|
executionCompleted: {
|
|
431
443
|
type: Function,
|
|
432
444
|
required: false,
|
|
433
|
-
default: () => {
|
|
445
|
+
default: () => {
|
|
446
|
+
}
|
|
434
447
|
},
|
|
435
448
|
title: {
|
|
436
449
|
type: String,
|
|
437
|
-
default:
|
|
450
|
+
default: '流程办理'
|
|
438
451
|
},
|
|
439
452
|
smartFlowServerContext: {
|
|
440
453
|
type: String,
|
|
@@ -463,7 +476,7 @@ export default {
|
|
|
463
476
|
isExpanded: true,
|
|
464
477
|
showProcessInfo: true,
|
|
465
478
|
portraitWidth: 0,
|
|
466
|
-
requestSuccessCodes: [200,
|
|
479
|
+
requestSuccessCodes: [200, '200'],
|
|
467
480
|
auditShow: true,
|
|
468
481
|
historyShow: true,
|
|
469
482
|
attachListShow: true,
|
|
@@ -492,9 +505,9 @@ export default {
|
|
|
492
505
|
organTreeType: '00',
|
|
493
506
|
defaultOrganTreeType: '00',
|
|
494
507
|
ruleValidate: {
|
|
495
|
-
auditOpinion: [{required: true, trigger:
|
|
496
|
-
assignee: [{required: true, trigger:
|
|
497
|
-
candidateGroups: [{required: true, trigger:
|
|
508
|
+
auditOpinion: [{ required: true, trigger: 'blur', message: '意见不能为空' }],
|
|
509
|
+
assignee: [{ required: true, trigger: 'blur', message: '办理人不能为空' }],
|
|
510
|
+
candidateGroups: [{ required: true, trigger: 'blur', message: '候选人不能为空' }],
|
|
498
511
|
},
|
|
499
512
|
form: {
|
|
500
513
|
auditOpinion: '',
|
|
@@ -510,8 +523,8 @@ export default {
|
|
|
510
523
|
auditResult: '',
|
|
511
524
|
curAuditGroup: '',
|
|
512
525
|
custChange: 'auditInfo',
|
|
513
|
-
auditInfo:
|
|
514
|
-
auditProcess:
|
|
526
|
+
auditInfo: 'auditInfo',
|
|
527
|
+
auditProcess: 'auditProcess',
|
|
515
528
|
fileList: [],
|
|
516
529
|
ossFilePutUrl: '/manage/oss/file/put',
|
|
517
530
|
hisAudit: [],
|
|
@@ -520,8 +533,8 @@ export default {
|
|
|
520
533
|
auditTime: '',
|
|
521
534
|
}],
|
|
522
535
|
datas: {
|
|
523
|
-
orgName:
|
|
524
|
-
orgId:
|
|
536
|
+
orgName: '',
|
|
537
|
+
orgId: ''
|
|
525
538
|
},
|
|
526
539
|
editForm: {
|
|
527
540
|
approvalCost: '',
|
|
@@ -574,23 +587,23 @@ export default {
|
|
|
574
587
|
},
|
|
575
588
|
computed: {
|
|
576
589
|
processHistoryHeight() {
|
|
577
|
-
let str = ''
|
|
590
|
+
let str = ''
|
|
578
591
|
const hasAuditOpinion = this.taskNode && this.handleButtons && this.handleButtons.includes('auditOpinion')
|
|
579
592
|
const hasAttachmentFile = this.handleButtons && this.handleButtons.includes('auditHistory') && this.attachmentList.length > 0
|
|
580
593
|
const isDetail = this.isDetail && !this.hisAuditOpinion[0].auditOpinion.length > 0
|
|
581
594
|
if (hasAuditOpinion && !hasAttachmentFile && !isDetail) {
|
|
582
|
-
str +=
|
|
595
|
+
str += 'height: 43vh'
|
|
583
596
|
} else if (hasAuditOpinion && hasAttachmentFile && !isDetail) {
|
|
584
|
-
str +=
|
|
597
|
+
str += 'height: 40vh'
|
|
585
598
|
} else {
|
|
586
|
-
str +=
|
|
599
|
+
str += 'height: 67vh'
|
|
587
600
|
}
|
|
588
|
-
return str
|
|
601
|
+
return str
|
|
589
602
|
},
|
|
590
603
|
nodeColumn: function () {
|
|
591
604
|
let column = []
|
|
592
|
-
column.push({title: '序号', type: 'index', width: 70, align: 'center', fixed: 'left'})
|
|
593
|
-
column.push({title: '节点名称', key: 'taskName', minWidth: 150, align: 'center', fixed: 'left'})
|
|
605
|
+
column.push({ title: '序号', type: 'index', width: 70, align: 'center', fixed: 'left' })
|
|
606
|
+
column.push({ title: '节点名称', key: 'taskName', minWidth: 150, align: 'center', fixed: 'left' })
|
|
594
607
|
|
|
595
608
|
column.push({
|
|
596
609
|
title: '节点状态', key: 'auditResult', minWidth: 150, align: 'center', fixed: 'left',
|
|
@@ -657,7 +670,7 @@ export default {
|
|
|
657
670
|
}
|
|
658
671
|
})
|
|
659
672
|
column.push({
|
|
660
|
-
title:
|
|
673
|
+
title: '操作', width: 100, align: 'center',
|
|
661
674
|
render: (h, params) => {
|
|
662
675
|
return h('div', [
|
|
663
676
|
h('Button', {
|
|
@@ -681,86 +694,79 @@ export default {
|
|
|
681
694
|
},
|
|
682
695
|
reductionColumn: function () {
|
|
683
696
|
let column = []
|
|
684
|
-
column.push({title: '#', key: 'selectId', type: 'selection', align: 'center', width: 55})
|
|
685
|
-
column.push({title: '账号', key: 'auditId', align: 'center'})
|
|
686
|
-
column.push({title: '姓名', key: 'auditName', align: 'center'})
|
|
697
|
+
column.push({ title: '#', key: 'selectId', type: 'selection', align: 'center', width: 55 })
|
|
698
|
+
column.push({ title: '账号', key: 'auditId', align: 'center' })
|
|
699
|
+
column.push({ title: '姓名', key: 'auditName', align: 'center' })
|
|
687
700
|
return column
|
|
688
701
|
},
|
|
689
702
|
diagramTableColumns: function () {
|
|
690
703
|
let column = []
|
|
691
|
-
column.push({title: '序号', type: 'index', width: 60})
|
|
692
|
-
column.push({title: `${this.handleName}节点`, key: 'taskName', minWidth: 130})
|
|
693
|
-
column.push({title: `${this.handleName}人`, key: 'auditName', minWidth: 150, tooltip: true})
|
|
704
|
+
column.push({ title: '序号', type: 'index', width: 60 })
|
|
705
|
+
column.push({ title: `${this.handleName}节点`, key: 'taskName', minWidth: 130 })
|
|
706
|
+
column.push({ title: `${this.handleName}人`, key: 'auditName', minWidth: 150, tooltip: true })
|
|
694
707
|
column.push({
|
|
695
708
|
title: `${this.handleName}结果`, key: 'auditResult', minWidth: 150, align: 'center',
|
|
696
|
-
render: (h, {row, column, index}) => {
|
|
697
|
-
let label =
|
|
698
|
-
let tagColor =
|
|
699
|
-
if (row.auditResult == '00'){
|
|
700
|
-
label = '流程发起'
|
|
701
|
-
tagColor = 'green'
|
|
702
|
-
}
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
else if (row.auditResult == '
|
|
712
|
-
label = '
|
|
713
|
-
tagColor = '
|
|
714
|
-
}
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
else if (row.auditResult == '
|
|
724
|
-
label = '
|
|
725
|
-
tagColor = '
|
|
726
|
-
}
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
label = '会签减签';
|
|
733
|
-
tagColor = 'red'; // 青色
|
|
734
|
-
}
|
|
735
|
-
else if (row.auditResult == '90'){
|
|
736
|
-
label = '驳回到指定节点';
|
|
737
|
-
tagColor = 'magenta'; // 品红色
|
|
738
|
-
}
|
|
739
|
-
else{
|
|
740
|
-
label = '待审核';
|
|
741
|
-
tagColor = 'orange'; // 默认橙色
|
|
709
|
+
render: (h, { row, column, index }) => {
|
|
710
|
+
let label = ''
|
|
711
|
+
let tagColor = ''
|
|
712
|
+
if (row.auditResult == '00') {
|
|
713
|
+
label = '流程发起'
|
|
714
|
+
tagColor = 'green' // 绿色
|
|
715
|
+
} else if (row.auditResult == '10') {
|
|
716
|
+
label = '自动跳过'
|
|
717
|
+
tagColor = 'green' // 绿色
|
|
718
|
+
} else if (row.auditResult == '30') {
|
|
719
|
+
label = '通过'
|
|
720
|
+
tagColor = 'green' // 绿色
|
|
721
|
+
} else if (row.auditResult == '40') {
|
|
722
|
+
label = '驳回到上一级'
|
|
723
|
+
tagColor = 'volcano' // 火红色
|
|
724
|
+
} else if (row.auditResult == '50') {
|
|
725
|
+
label = '驳回到原点'
|
|
726
|
+
tagColor = 'red' // 红色
|
|
727
|
+
} else if (row.auditResult == '51') {
|
|
728
|
+
label = '流程终止'
|
|
729
|
+
tagColor = 'purple' // 紫色
|
|
730
|
+
} else if (row.auditResult == '60') {
|
|
731
|
+
label = '撤回'
|
|
732
|
+
tagColor = 'blue' // 蓝色
|
|
733
|
+
} else if (row.auditResult == '80') {
|
|
734
|
+
label = '跳转到指定节点'
|
|
735
|
+
tagColor = 'cyan' // 青色
|
|
736
|
+
} else if (row.auditResult == '83') {
|
|
737
|
+
label = '会签减签'
|
|
738
|
+
tagColor = 'red' // 青色
|
|
739
|
+
} else if (row.auditResult == '90') {
|
|
740
|
+
label = '驳回到指定节点'
|
|
741
|
+
tagColor = 'magenta' // 品红色
|
|
742
|
+
} else {
|
|
743
|
+
label = '待审核'
|
|
744
|
+
tagColor = 'orange' // 默认橙色
|
|
742
745
|
}
|
|
743
746
|
return h('Tag', {
|
|
744
747
|
props: {
|
|
745
748
|
color: tagColor,
|
|
746
749
|
value: row.auditResult
|
|
747
750
|
}
|
|
748
|
-
}, label)
|
|
751
|
+
}, label)
|
|
749
752
|
}
|
|
750
753
|
})
|
|
751
754
|
column.push({
|
|
752
755
|
title: `${this.handleName}时间`, key: 'auditTime', minWidth: 150,
|
|
753
|
-
render: (h, {row}) => {
|
|
754
|
-
const displayDate = row.startDate || row.auditDate
|
|
755
|
-
return h('span', displayDate)
|
|
756
|
+
render: (h, { row }) => {
|
|
757
|
+
const displayDate = row.startDate || row.auditDate
|
|
758
|
+
return h('span', displayDate)
|
|
756
759
|
}
|
|
757
760
|
})
|
|
758
761
|
column.push({
|
|
759
762
|
title: `${this.handleName}意见`, key: 'auditComment', minWidth: 180, tooltip: true,
|
|
760
|
-
render: (h, {row, column, index}) => {
|
|
761
|
-
let label =
|
|
762
|
-
if (row.auditComment == '' || row.auditComment == null)
|
|
763
|
-
|
|
763
|
+
render: (h, { row, column, index }) => {
|
|
764
|
+
let label = ''
|
|
765
|
+
if (row.auditComment == '' || row.auditComment == null) {
|
|
766
|
+
label = '无'
|
|
767
|
+
} else {
|
|
768
|
+
label = row.auditComment
|
|
769
|
+
}
|
|
764
770
|
return h('Label', {
|
|
765
771
|
props: {
|
|
766
772
|
value: row.auditComment
|
|
@@ -768,12 +774,12 @@ export default {
|
|
|
768
774
|
}, label)
|
|
769
775
|
}
|
|
770
776
|
})
|
|
771
|
-
if (this.showAttachmentFile){
|
|
777
|
+
if (this.showAttachmentFile) {
|
|
772
778
|
column.push({
|
|
773
779
|
title: `附件`, key: 'fileList', minWidth: 200,
|
|
774
780
|
render: (h, { row }) => {
|
|
775
781
|
if (!row.fileList || row.fileList.length === 0) {
|
|
776
|
-
return h('span', '无')
|
|
782
|
+
return h('span', '无') // 如果没有附件,显示“无”
|
|
777
783
|
}
|
|
778
784
|
|
|
779
785
|
//显示所有附件
|
|
@@ -782,7 +788,7 @@ export default {
|
|
|
782
788
|
style: {
|
|
783
789
|
display: 'block',
|
|
784
790
|
marginTop: '5px',
|
|
785
|
-
marginRight:'5px',
|
|
791
|
+
marginRight: '5px',
|
|
786
792
|
whiteSpace: 'nowrap',
|
|
787
793
|
overflow: 'hidden',
|
|
788
794
|
textOverflow: 'ellipsis',
|
|
@@ -793,11 +799,11 @@ export default {
|
|
|
793
799
|
},
|
|
794
800
|
on: {
|
|
795
801
|
click: () => {
|
|
796
|
-
this.getAttach(file)
|
|
802
|
+
this.getAttach(file)
|
|
797
803
|
}
|
|
798
804
|
},
|
|
799
|
-
}, file.attachName)
|
|
800
|
-
}))
|
|
805
|
+
}, file.attachName)
|
|
806
|
+
}))
|
|
801
807
|
}
|
|
802
808
|
})
|
|
803
809
|
}
|
|
@@ -808,7 +814,7 @@ export default {
|
|
|
808
814
|
provide() {
|
|
809
815
|
return {
|
|
810
816
|
toBeDoneListDoSearch: this.doSearch
|
|
811
|
-
}
|
|
817
|
+
}
|
|
812
818
|
},
|
|
813
819
|
methods: {
|
|
814
820
|
getWidth() {
|
|
@@ -834,24 +840,24 @@ export default {
|
|
|
834
840
|
taskId: this.taskId,
|
|
835
841
|
auditGroup: this.auditGroup
|
|
836
842
|
}
|
|
837
|
-
ajax.get(self.smartFlowServerContext +
|
|
843
|
+
ajax.get(self.smartFlowServerContext + '/manage/processTodo/list', { params: param }).then(function (resp) {
|
|
838
844
|
if (resp.data.code === '200') {
|
|
839
845
|
self.curTaskId = resp.data.data.rows[0].taskId
|
|
840
846
|
self.instanceId = resp.data.data.rows[0].procInstanceId
|
|
841
847
|
self.curAuditGroup = resp.data.data.rows[0].auditGroup
|
|
842
848
|
let procType = resp.data.data.rows[0].procType
|
|
843
|
-
ajax.get(self.smartFlowServerContext +
|
|
849
|
+
ajax.get(self.smartFlowServerContext + '/manage/processType/lists?proType=' + procType)
|
|
844
850
|
.then(resp => {
|
|
845
851
|
let data = resp.data.data.rows
|
|
846
852
|
self.permScope = data[0].permScope
|
|
847
853
|
self.defaultOrganTreeType = data[0].organTreeType ? data[0].organTreeType : '00'
|
|
848
854
|
self.getNodeOrganTreeType(procType)
|
|
849
855
|
}).catch(err => {
|
|
850
|
-
console.log(err)
|
|
856
|
+
console.log(err)
|
|
851
857
|
})
|
|
852
858
|
self.getAttachList(self.curTaskId)
|
|
853
|
-
self.getHisAudit(self.curTaskId)
|
|
854
|
-
self.getProcessHistory(self.curTaskId)
|
|
859
|
+
self.getHisAudit(self.curTaskId)
|
|
860
|
+
self.getProcessHistory(self.curTaskId)
|
|
855
861
|
} else {
|
|
856
862
|
self.$Message.error(resp.data.message)
|
|
857
863
|
}
|
|
@@ -859,14 +865,14 @@ export default {
|
|
|
859
865
|
console.log(err)
|
|
860
866
|
})
|
|
861
867
|
},
|
|
862
|
-
getNodeOrganTreeType(procType){
|
|
868
|
+
getNodeOrganTreeType(procType) {
|
|
863
869
|
const self = this
|
|
864
870
|
let param = {
|
|
865
871
|
procType: procType,
|
|
866
872
|
procId: this.procId,
|
|
867
873
|
taskNode: this.taskNode
|
|
868
874
|
}
|
|
869
|
-
ajax.get(self.smartFlowServerContext +
|
|
875
|
+
ajax.get(self.smartFlowServerContext + '/manage/processTodo/getNodeOrganTreeType', { params: param }).then(function (resp) {
|
|
870
876
|
if (resp.data.code === '200') {
|
|
871
877
|
self.organTreeType = resp.data.data ? resp.data.data : self.defaultOrganTreeType
|
|
872
878
|
} else {
|
|
@@ -885,7 +891,7 @@ export default {
|
|
|
885
891
|
taskId: this.taskId,
|
|
886
892
|
auditGroup: this.auditGroup
|
|
887
893
|
}
|
|
888
|
-
ajax.get(self.smartFlowServerContext +
|
|
894
|
+
ajax.get(self.smartFlowServerContext + '/manage/processDone/getDoneDetail', { params: param }).then(function (resp) {
|
|
889
895
|
if (resp.data.code === '200') {
|
|
890
896
|
let rows = resp.data.data.rows
|
|
891
897
|
if (rows.length > 0) {
|
|
@@ -901,7 +907,7 @@ export default {
|
|
|
901
907
|
self.curTaskId = taskList[0].taskId
|
|
902
908
|
self.instanceId = taskList[0].procInstanceId
|
|
903
909
|
} else {
|
|
904
|
-
ajax.get(self.smartFlowServerContext +
|
|
910
|
+
ajax.get(self.smartFlowServerContext + '/manage/processTodo/list', { params: param }).then(function (todoResp) {
|
|
905
911
|
if (todoResp.data.code === '200') {
|
|
906
912
|
self.curTaskId = todoResp.data.data.rows[0].taskId
|
|
907
913
|
self.instanceId = todoResp.data.data.rows[0].procInstanceId
|
|
@@ -914,8 +920,8 @@ export default {
|
|
|
914
920
|
})
|
|
915
921
|
}
|
|
916
922
|
self.getAttachList(self.curTaskId)
|
|
917
|
-
self.getHisAudit(self.curTaskId)
|
|
918
|
-
self.getProcessHistory(self.curTaskId)
|
|
923
|
+
self.getHisAudit(self.curTaskId)
|
|
924
|
+
self.getProcessHistory(self.curTaskId)
|
|
919
925
|
} else {
|
|
920
926
|
self.$Message.error(resp.data.message)
|
|
921
927
|
}
|
|
@@ -932,12 +938,12 @@ export default {
|
|
|
932
938
|
ajax.post(self.smartFlowServerContext + '/manage/approvalCenter/getNodeData', param).then(function (resp) {
|
|
933
939
|
if (resp.data.code === '200') {
|
|
934
940
|
self.handleButtons = resp.data.data[0].handleButtons
|
|
935
|
-
if (resp.data.data[0].hasOwnProperty('isSequential')){
|
|
941
|
+
if (resp.data.data[0].hasOwnProperty('isSequential')) {
|
|
936
942
|
self.isParallelCountersignature = !resp.data.data[0].isSequential
|
|
937
943
|
}
|
|
938
944
|
self.handleName = resp.data.data[0].handleName ? resp.data.data[0].handleName : '审批'
|
|
939
945
|
self.auditOpinionTitle = resp.data.data[0].handleName ? resp.data.data[0].handleName + '意见' : '审批意见'
|
|
940
|
-
if (!self.handleButtons || (!self.handleButtons.includes('auditOpinion') && !self.handleButtons.includes('attachmentFile') && !self.handleButtons.includes('auditHistory'))){
|
|
946
|
+
if (!self.handleButtons || (!self.handleButtons.includes('auditOpinion') && !self.handleButtons.includes('attachmentFile') && !self.handleButtons.includes('auditHistory'))) {
|
|
941
947
|
self.showProcessInfo = false
|
|
942
948
|
}
|
|
943
949
|
} else {
|
|
@@ -947,7 +953,7 @@ export default {
|
|
|
947
953
|
console.log(err)
|
|
948
954
|
})
|
|
949
955
|
},
|
|
950
|
-
getNextNodes(){
|
|
956
|
+
getNextNodes() {
|
|
951
957
|
const self = this
|
|
952
958
|
self.nextNodesFormList = []
|
|
953
959
|
self.nextNodesOldSettings = []
|
|
@@ -975,38 +981,38 @@ export default {
|
|
|
975
981
|
candidateGroups: '',
|
|
976
982
|
isMultiInstance: data[i].isMultiInstance,
|
|
977
983
|
actionType: 'ASSIGNEE',
|
|
978
|
-
remainDay
|
|
979
|
-
remainTime
|
|
980
|
-
inAdvanceDay
|
|
981
|
-
inAdvanceTime
|
|
982
|
-
processing
|
|
984
|
+
remainDay: 0,
|
|
985
|
+
remainTime: 0,
|
|
986
|
+
inAdvanceDay: 0,
|
|
987
|
+
inAdvanceTime: 0,
|
|
988
|
+
processing: '00'
|
|
983
989
|
}
|
|
984
990
|
//显示具体候选人信息
|
|
985
|
-
if (data[i].candidateGroups){
|
|
991
|
+
if (data[i].candidateGroups) {
|
|
986
992
|
nextNodeForm.actionType = 'CAND'
|
|
987
|
-
let names = []
|
|
988
|
-
let candidates = {}
|
|
993
|
+
let names = []
|
|
994
|
+
let candidates = {}
|
|
989
995
|
for (let groupName in data[i].candidateGroups) {
|
|
990
996
|
if (data[i].candidateGroups.hasOwnProperty(groupName)) {
|
|
991
|
-
let group = data[i].candidateGroups[groupName]
|
|
997
|
+
let group = data[i].candidateGroups[groupName]
|
|
992
998
|
group.forEach(item => {
|
|
993
|
-
names.push(item.name)
|
|
994
|
-
})
|
|
995
|
-
candidates[groupName] = group.map(item => item.id + ':' + item.name).join(',')
|
|
999
|
+
names.push(item.name)
|
|
1000
|
+
})
|
|
1001
|
+
candidates[groupName] = group.map(item => item.id + ':' + item.name).join(',')
|
|
996
1002
|
}
|
|
997
1003
|
}
|
|
998
|
-
nextNodeForm.candidateNames = names.join(',')
|
|
999
|
-
nextNodeForm.candidates = candidates
|
|
1000
|
-
nextNodeOldForm.candidates = candidates
|
|
1004
|
+
nextNodeForm.candidateNames = names.join(',')
|
|
1005
|
+
nextNodeForm.candidates = candidates
|
|
1006
|
+
nextNodeOldForm.candidates = candidates
|
|
1001
1007
|
}
|
|
1002
1008
|
if (data[i].timeLimit) {
|
|
1003
|
-
let expireTime = data[i].timeLimit.split(
|
|
1004
|
-
let warningTime = data[i].timeLimit.split(
|
|
1005
|
-
let handleType = data[i].timeLimit.split(
|
|
1006
|
-
let days = expireTime.slice(0, expireTime.indexOf(
|
|
1007
|
-
let hourOfDay = expireTime.slice(expireTime.indexOf(
|
|
1008
|
-
let daysWarn = warningTime.slice(0, warningTime.indexOf(
|
|
1009
|
-
let hourOfDayWarn = warningTime.slice(warningTime.indexOf(
|
|
1009
|
+
let expireTime = data[i].timeLimit.split(';')[0].split(':')[1]
|
|
1010
|
+
let warningTime = data[i].timeLimit.split(';')[1].split(':')[1]
|
|
1011
|
+
let handleType = data[i].timeLimit.split(';')[2].split(':')[1]
|
|
1012
|
+
let days = expireTime.slice(0, expireTime.indexOf('D')) //过期天
|
|
1013
|
+
let hourOfDay = expireTime.slice(expireTime.indexOf('D') + 1, expireTime.indexOf('H')) //过期小时
|
|
1014
|
+
let daysWarn = warningTime.slice(0, warningTime.indexOf('D')) //警告天
|
|
1015
|
+
let hourOfDayWarn = warningTime.slice(warningTime.indexOf('D') + 1, warningTime.indexOf('H')) //警告小时
|
|
1010
1016
|
nextNodeForm.remainDay = parseInt(days)
|
|
1011
1017
|
nextNodeForm.remainTime = parseInt(hourOfDay)
|
|
1012
1018
|
nextNodeForm.inAdvanceDay = parseInt(daysWarn)
|
|
@@ -1030,10 +1036,10 @@ export default {
|
|
|
1030
1036
|
procId: this.procId,
|
|
1031
1037
|
applyId: this.applyId
|
|
1032
1038
|
}
|
|
1033
|
-
ajax.get(self.smartFlowServerContext + '/manage/processDone/getAttachmentList', {params: param}).then(function (resp) {
|
|
1039
|
+
ajax.get(self.smartFlowServerContext + '/manage/processDone/getAttachmentList', { params: param }).then(function (resp) {
|
|
1034
1040
|
self.attachmentList = resp.data.data.rows
|
|
1035
1041
|
self.attachmentList.forEach(item => {
|
|
1036
|
-
const index = item.fileName.lastIndexOf(
|
|
1042
|
+
const index = item.fileName.lastIndexOf('.')
|
|
1037
1043
|
const fileType = item.fileName.substr(index + 1).toLowerCase()
|
|
1038
1044
|
const imageList = ['jpg', 'gif', 'png', 'svg']
|
|
1039
1045
|
const docList = ['doc', 'docx']
|
|
@@ -1043,7 +1049,7 @@ export default {
|
|
|
1043
1049
|
item.showPreview = typeList.indexOf(fileType) !== -1
|
|
1044
1050
|
})
|
|
1045
1051
|
}).catch(err => {
|
|
1046
|
-
console.log(err)
|
|
1052
|
+
console.log(err)
|
|
1047
1053
|
})
|
|
1048
1054
|
},
|
|
1049
1055
|
getHisAudit(taskId) {
|
|
@@ -1054,14 +1060,14 @@ export default {
|
|
|
1054
1060
|
procId: self.procId,
|
|
1055
1061
|
taskId: taskId
|
|
1056
1062
|
}
|
|
1057
|
-
ajax.get(self.smartFlowServerContext + '/manage/processTodo/getHisAudit', {params: params}).then(function (resp) {
|
|
1063
|
+
ajax.get(self.smartFlowServerContext + '/manage/processTodo/getHisAudit', { params: params }).then(function (resp) {
|
|
1058
1064
|
if (resp.data.code === '200') {
|
|
1059
1065
|
self.hisAudit = resp.data.data
|
|
1060
|
-
let uniqueDataMap = {}
|
|
1066
|
+
let uniqueDataMap = {}
|
|
1061
1067
|
self.hisAudit.forEach((item) => {
|
|
1062
|
-
uniqueDataMap[item[
|
|
1068
|
+
uniqueDataMap[item['taskNode']] = item
|
|
1063
1069
|
})
|
|
1064
|
-
self.hisNode = Object.values(uniqueDataMap)
|
|
1070
|
+
self.hisNode = Object.values(uniqueDataMap)
|
|
1065
1071
|
|
|
1066
1072
|
}
|
|
1067
1073
|
})
|
|
@@ -1074,7 +1080,7 @@ export default {
|
|
|
1074
1080
|
procId: self.procId,
|
|
1075
1081
|
taskId: taskId
|
|
1076
1082
|
}
|
|
1077
|
-
ajax.get(self.smartFlowServerContext + '/manage/processTodo/getProcessHis', {params: params}).then(function (resp) {
|
|
1083
|
+
ajax.get(self.smartFlowServerContext + '/manage/processTodo/getProcessHis', { params: params }).then(function (resp) {
|
|
1078
1084
|
if (resp.data.code === '200') {
|
|
1079
1085
|
self.processHistory = resp.data.data
|
|
1080
1086
|
}
|
|
@@ -1087,7 +1093,7 @@ export default {
|
|
|
1087
1093
|
self.submit()
|
|
1088
1094
|
},
|
|
1089
1095
|
submit() {
|
|
1090
|
-
let self = this
|
|
1096
|
+
let self = this
|
|
1091
1097
|
self.auditParams = {
|
|
1092
1098
|
procId: self.procId,
|
|
1093
1099
|
applyId: self.applyId,
|
|
@@ -1100,33 +1106,33 @@ export default {
|
|
|
1100
1106
|
selectedUserId: self.selectedUserId,
|
|
1101
1107
|
}
|
|
1102
1108
|
if (self.auditResult == '' || self.auditResult == null) {
|
|
1103
|
-
self.$Message.error(`请选择${self.handleName}结果!`)
|
|
1104
|
-
return
|
|
1109
|
+
self.$Message.error(`请选择${self.handleName}结果!`)
|
|
1110
|
+
return
|
|
1105
1111
|
}
|
|
1106
1112
|
if (self.form.auditOpinion == '' || self.form.auditOpinion == null) {
|
|
1107
|
-
if (self.auditResult === '30'){
|
|
1113
|
+
if (self.auditResult === '30') {
|
|
1108
1114
|
self.auditParams.auditOpinion = '通过'
|
|
1109
1115
|
self.businessFormSave ? self.businessFormSave(self.handleSaveResult) : self.handleSaveResult(true)
|
|
1110
|
-
return
|
|
1116
|
+
return
|
|
1111
1117
|
}
|
|
1112
1118
|
if (!self.handleButtons || self.handleButtons.includes('auditOpinion')) {
|
|
1113
1119
|
self.$Message.error(`请输入${self.handleName}意见!`)
|
|
1114
|
-
return
|
|
1120
|
+
return
|
|
1115
1121
|
} else {
|
|
1116
|
-
self.auditParams.auditOpinion = self.handleButtonsNames[self.auditResult]
|
|
1122
|
+
self.auditParams.auditOpinion = self.handleButtonsNames[self.auditResult]
|
|
1117
1123
|
}
|
|
1118
1124
|
}
|
|
1119
1125
|
self.businessFormSave ? self.businessFormSave(self.handleSaveResult) : self.handleSaveResult(true)
|
|
1120
1126
|
},
|
|
1121
1127
|
handleSaveResult(saveResult, businessParams) {
|
|
1122
1128
|
if (saveResult) {
|
|
1123
|
-
this.executeButtonAction(businessParams)
|
|
1129
|
+
this.executeButtonAction(businessParams)
|
|
1124
1130
|
} else {
|
|
1125
|
-
console.error('保存失败')
|
|
1131
|
+
console.error('保存失败')
|
|
1126
1132
|
}
|
|
1127
1133
|
},
|
|
1128
1134
|
executeButtonAction(businessParams) {
|
|
1129
|
-
const self = this
|
|
1135
|
+
const self = this
|
|
1130
1136
|
if (businessParams) {
|
|
1131
1137
|
Object.assign(self.datas, businessParams)
|
|
1132
1138
|
self.auditParams.params = JSON.stringify(self.datas)
|
|
@@ -1155,11 +1161,11 @@ export default {
|
|
|
1155
1161
|
self.$Message.warning(result.message)
|
|
1156
1162
|
//避免未提示消息直接回调
|
|
1157
1163
|
setTimeout(() => {
|
|
1158
|
-
self.executionCompleted(false, null, null, auditResult, self.curTaskId)
|
|
1164
|
+
self.executionCompleted(false, null, null, auditResult, self.curTaskId)
|
|
1159
1165
|
}, 1000)
|
|
1160
1166
|
} else if (result.code == '30010') {
|
|
1161
1167
|
self.$Modal.confirm({
|
|
1162
|
-
title:
|
|
1168
|
+
title: '提示',
|
|
1163
1169
|
content: result.message,
|
|
1164
1170
|
onOk: () => {
|
|
1165
1171
|
self.auditParams.auditResult = '70'
|
|
@@ -1169,10 +1175,10 @@ export default {
|
|
|
1169
1175
|
if (result.code == '200') {
|
|
1170
1176
|
self.loading = false
|
|
1171
1177
|
self.disable = false
|
|
1172
|
-
self.$Message.success(result.message)
|
|
1178
|
+
self.$Message.success(result.message)
|
|
1173
1179
|
//后端没有返回数据
|
|
1174
1180
|
setTimeout(() => {
|
|
1175
|
-
self.executionCompleted(true, null, null, auditResult, self.curTaskId)
|
|
1181
|
+
self.executionCompleted(true, null, null, auditResult, self.curTaskId)
|
|
1176
1182
|
}, 1000)
|
|
1177
1183
|
bus.$emit('triggerTimer')
|
|
1178
1184
|
} else {
|
|
@@ -1180,7 +1186,7 @@ export default {
|
|
|
1180
1186
|
self.disable = false
|
|
1181
1187
|
self.$Message.error(result.message)
|
|
1182
1188
|
setTimeout(() => {
|
|
1183
|
-
self.executionCompleted(false, null, null, auditResult, self.curTaskId)
|
|
1189
|
+
self.executionCompleted(false, null, null, auditResult, self.curTaskId)
|
|
1184
1190
|
}, 1000)
|
|
1185
1191
|
}
|
|
1186
1192
|
bus.$emit('triggerTimer')
|
|
@@ -1208,10 +1214,10 @@ export default {
|
|
|
1208
1214
|
if (result.code == '200') {
|
|
1209
1215
|
self.loading = false
|
|
1210
1216
|
self.disable = false
|
|
1211
|
-
self.$Message.success(result.message)
|
|
1217
|
+
self.$Message.success(result.message)
|
|
1212
1218
|
setTimeout(() => {
|
|
1213
1219
|
if (result.data) {
|
|
1214
|
-
let taskIds = result.data.map(item => item.id).join(',')
|
|
1220
|
+
let taskIds = result.data.map(item => item.id).join(',')
|
|
1215
1221
|
self.executionCompleted(true, result.data[0].processInstanceId, taskIds, auditResult, self.curTaskId)
|
|
1216
1222
|
} else {
|
|
1217
1223
|
self.executionCompleted(true, null, null, auditResult, self.curTaskId)
|
|
@@ -1222,7 +1228,7 @@ export default {
|
|
|
1222
1228
|
self.disable = false
|
|
1223
1229
|
self.$Message.error(result.message)
|
|
1224
1230
|
setTimeout(() => {
|
|
1225
|
-
self.executionCompleted(false, null, null, auditResult, self.curTaskId)
|
|
1231
|
+
self.executionCompleted(false, null, null, auditResult, self.curTaskId)
|
|
1226
1232
|
}, 1000)
|
|
1227
1233
|
}
|
|
1228
1234
|
bus.$emit('triggerTimer')
|
|
@@ -1230,7 +1236,7 @@ export default {
|
|
|
1230
1236
|
}
|
|
1231
1237
|
})
|
|
1232
1238
|
} else {
|
|
1233
|
-
if (self.auditResult === '30' && (!self.handleButtons || self.handleButtons.includes('appointHandler') || self.handleButtons.includes('appointTimeoutTime'))){
|
|
1239
|
+
if (self.auditResult === '30' && (!self.handleButtons || self.handleButtons.includes('appointHandler') || self.handleButtons.includes('appointTimeoutTime'))) {
|
|
1234
1240
|
self.getNextNodes()
|
|
1235
1241
|
self.appointBoxShow = true
|
|
1236
1242
|
} else {
|
|
@@ -1238,16 +1244,16 @@ export default {
|
|
|
1238
1244
|
}
|
|
1239
1245
|
}
|
|
1240
1246
|
},
|
|
1241
|
-
doPass(){
|
|
1242
|
-
let self = this
|
|
1247
|
+
doPass() {
|
|
1248
|
+
let self = this
|
|
1243
1249
|
this.modal = false
|
|
1244
1250
|
let auditResult = {
|
|
1245
1251
|
code: self.auditResult,
|
|
1246
1252
|
name: self.handleButtonsNames[self.auditResult]
|
|
1247
1253
|
}
|
|
1248
1254
|
if (self.auditResult === '82' && (self.targetTaskNode == '' || self.targetTaskNode == null)) {
|
|
1249
|
-
self.auditResult = ''
|
|
1250
|
-
self.$Message.error(`请选择${self.handleName}节点!`)
|
|
1255
|
+
self.auditResult = ''
|
|
1256
|
+
self.$Message.error(`请选择${self.handleName}节点!`)
|
|
1251
1257
|
} else {
|
|
1252
1258
|
self.loading = true
|
|
1253
1259
|
self.disable = true
|
|
@@ -1258,9 +1264,9 @@ export default {
|
|
|
1258
1264
|
if (result.code == '200') {
|
|
1259
1265
|
self.loading = false
|
|
1260
1266
|
self.disable = false
|
|
1261
|
-
self.$Message.success(result.message ? result.message : `${self.handleName}成功`)
|
|
1262
|
-
if (result.data){
|
|
1263
|
-
let taskIds = result.data.id ? result.data.id : result.data.map(item => item.id).join(',')
|
|
1267
|
+
self.$Message.success(result.message ? result.message : `${self.handleName}成功`)
|
|
1268
|
+
if (result.data) {
|
|
1269
|
+
let taskIds = result.data.id ? result.data.id : result.data.map(item => item.id).join(',')
|
|
1264
1270
|
setTimeout(() => {
|
|
1265
1271
|
self.executionCompleted(true, result.data.id ? result.data.processInstanceId : result.data[0].processInstanceId, taskIds, auditResult, self.curTaskId)
|
|
1266
1272
|
}, 1000)
|
|
@@ -1297,9 +1303,9 @@ export default {
|
|
|
1297
1303
|
})
|
|
1298
1304
|
}
|
|
1299
1305
|
},
|
|
1300
|
-
showUpdateMultitaskInstanceModal(updateType){
|
|
1306
|
+
showUpdateMultitaskInstanceModal(updateType) {
|
|
1301
1307
|
const self = this
|
|
1302
|
-
if (updateType === '81'){
|
|
1308
|
+
if (updateType === '81') {
|
|
1303
1309
|
this.$refs.assigneeHelpBox.toggleShowHelpBox(this.organTreeType, '', 'addMultitaskInstance')
|
|
1304
1310
|
} else if (updateType === '83') {
|
|
1305
1311
|
ajax.get(self.smartFlowServerContext + '/manage/processTodo/getUnapprovedListOfMultiNode?taskId=' + self.curTaskId).then(function (resp) {
|
|
@@ -1310,11 +1316,11 @@ export default {
|
|
|
1310
1316
|
self.$Message.error(resp.data.message)
|
|
1311
1317
|
}
|
|
1312
1318
|
}).catch(err => {
|
|
1313
|
-
console.log(err)
|
|
1319
|
+
console.log(err)
|
|
1314
1320
|
})
|
|
1315
1321
|
}
|
|
1316
1322
|
},
|
|
1317
|
-
updateMultitaskInstance(updateType, assignees){
|
|
1323
|
+
updateMultitaskInstance(updateType, assignees) {
|
|
1318
1324
|
const self = this
|
|
1319
1325
|
self.loading = true
|
|
1320
1326
|
self.disable = true
|
|
@@ -1329,24 +1335,24 @@ export default {
|
|
|
1329
1335
|
if (result.code == '200') {
|
|
1330
1336
|
self.loading = false
|
|
1331
1337
|
self.disable = false
|
|
1332
|
-
self.$Message.success(result.message)
|
|
1338
|
+
self.$Message.success(result.message)
|
|
1333
1339
|
} else {
|
|
1334
1340
|
self.loading = false
|
|
1335
1341
|
self.disable = false
|
|
1336
1342
|
self.$Message.error(result.message)
|
|
1337
1343
|
}
|
|
1338
1344
|
}).catch(err => {
|
|
1339
|
-
console.log(err)
|
|
1345
|
+
console.log(err)
|
|
1340
1346
|
})
|
|
1341
1347
|
},
|
|
1342
1348
|
//加签
|
|
1343
|
-
addMultitaskInstance(assingeeList){
|
|
1349
|
+
addMultitaskInstance(assingeeList) {
|
|
1344
1350
|
const assingees = assingeeList.join(',')
|
|
1345
1351
|
this.updateMultitaskInstance('81', assingees)
|
|
1346
1352
|
},
|
|
1347
1353
|
//减签
|
|
1348
|
-
reductionMultitaskInstance(){
|
|
1349
|
-
if (this.reductionAssigneeList.length === 0){
|
|
1354
|
+
reductionMultitaskInstance() {
|
|
1355
|
+
if (this.reductionAssigneeList.length === 0) {
|
|
1350
1356
|
this.$Message.error('请选择减签人员')
|
|
1351
1357
|
return
|
|
1352
1358
|
}
|
|
@@ -1361,25 +1367,25 @@ export default {
|
|
|
1361
1367
|
console.log(tab)
|
|
1362
1368
|
},
|
|
1363
1369
|
getAttach(row) {
|
|
1364
|
-
window.open(this.smartFlowServerContext +
|
|
1370
|
+
window.open(this.smartFlowServerContext + '/manage/oss/file/get/' + row.fileId, '_blank')
|
|
1365
1371
|
},
|
|
1366
1372
|
preViewAttach(row) {
|
|
1367
1373
|
let reg = /\.(gif|jpg|jpeg|bmp|png|PNG)$/
|
|
1368
1374
|
let regs = /\.(pdf)$/
|
|
1369
1375
|
if (reg.test(row.fileName)) {
|
|
1370
|
-
let url = this.smartFlowServerContext +
|
|
1371
|
-
this.imgPreview(url)
|
|
1376
|
+
let url = this.smartFlowServerContext + '/manage/oss/file/get/' + row.fileId
|
|
1377
|
+
this.imgPreview(url)
|
|
1372
1378
|
} else if (regs.test(row.fileName)) {
|
|
1373
|
-
window.open(this.smartFlowServerContext +
|
|
1379
|
+
window.open(this.smartFlowServerContext + '/manage/oss/file/getFileStream?fileId=' + row.fileId, '_blank')
|
|
1374
1380
|
} else {
|
|
1375
1381
|
this.modalDocx = true
|
|
1376
1382
|
axios({
|
|
1377
1383
|
method: 'get',
|
|
1378
1384
|
responseType: 'blob', // 因为是流文件,所以要指定blob类型
|
|
1379
|
-
url: this.smartFlowServerContext +
|
|
1380
|
-
}).then(({data}) => {
|
|
1385
|
+
url: this.smartFlowServerContext + '/manage/oss/file/get/' + row.fileId// 一个word下载文件的接口
|
|
1386
|
+
}).then(({ data }) => {
|
|
1381
1387
|
docx.renderAsync(data, this.$refs.file, null, {
|
|
1382
|
-
className:
|
|
1388
|
+
className: 'docx', //默认和文档样式类的类名/前缀
|
|
1383
1389
|
inWrapper: true, //启用围绕文档内容呈现包装器
|
|
1384
1390
|
ignoreWidth: false, //禁用页面的渲染宽度
|
|
1385
1391
|
ignoreHeight: false, //禁用页面的渲染高度
|
|
@@ -1398,8 +1404,8 @@ export default {
|
|
|
1398
1404
|
}
|
|
1399
1405
|
},
|
|
1400
1406
|
imgPreview(url) {
|
|
1401
|
-
this.imageUrl = url
|
|
1402
|
-
this.modalVisible = true
|
|
1407
|
+
this.imageUrl = url
|
|
1408
|
+
this.modalVisible = true
|
|
1403
1409
|
},
|
|
1404
1410
|
|
|
1405
1411
|
//打印流程图信息
|
|
@@ -1411,7 +1417,7 @@ export default {
|
|
|
1411
1417
|
procId: self.procId,
|
|
1412
1418
|
taskId: self.curTaskId,
|
|
1413
1419
|
}
|
|
1414
|
-
ajax.get(self.smartFlowServerContext + '/manage/processTodo/getPrintData', {params: params}).then(function (resp) {
|
|
1420
|
+
ajax.get(self.smartFlowServerContext + '/manage/processTodo/getPrintData', { params: params }).then(function (resp) {
|
|
1415
1421
|
let result = resp.data.data
|
|
1416
1422
|
if (resp.data.code === '200') {
|
|
1417
1423
|
let tableData = result
|
|
@@ -1430,16 +1436,16 @@ export default {
|
|
|
1430
1436
|
if (this.processHistory.length > 0) {
|
|
1431
1437
|
let task = null
|
|
1432
1438
|
this.processHistory.some(itemList => {
|
|
1433
|
-
task = itemList.find(item => item.taskId === taskId)
|
|
1434
|
-
return task !== undefined
|
|
1435
|
-
})
|
|
1439
|
+
task = itemList.find(item => item.taskId === taskId)
|
|
1440
|
+
return task !== undefined
|
|
1441
|
+
})
|
|
1436
1442
|
return task ? task.taskName : ''
|
|
1437
1443
|
}
|
|
1438
1444
|
return ''
|
|
1439
1445
|
},
|
|
1440
1446
|
cancel() {
|
|
1441
1447
|
this.modal = false
|
|
1442
|
-
this.auditResult = ''
|
|
1448
|
+
this.auditResult = ''
|
|
1443
1449
|
},
|
|
1444
1450
|
reductionModalCancel() {
|
|
1445
1451
|
this.reductionMultitaskInstanceModal = false
|
|
@@ -1458,7 +1464,7 @@ export default {
|
|
|
1458
1464
|
processDefId: self.procId,
|
|
1459
1465
|
taskId: self.curTaskId,
|
|
1460
1466
|
}
|
|
1461
|
-
ajax.get(self.smartFlowServerContext + '/manage/processTodo/getAllPreNodes', {params: params}).then(function (resp) {
|
|
1467
|
+
ajax.get(self.smartFlowServerContext + '/manage/processTodo/getAllPreNodes', { params: params }).then(function (resp) {
|
|
1462
1468
|
if (resp.data.code === '200') {
|
|
1463
1469
|
if (resp.data.data.length > 0) {
|
|
1464
1470
|
self.allNode = resp.data.data
|
|
@@ -1477,7 +1483,7 @@ export default {
|
|
|
1477
1483
|
processDefId: self.procId,
|
|
1478
1484
|
taskId: self.curTaskId,
|
|
1479
1485
|
}
|
|
1480
|
-
ajax.get(self.smartFlowServerContext + '/manage/processTodo/getNodesBehind', {params: params}).then(function (resp) {
|
|
1486
|
+
ajax.get(self.smartFlowServerContext + '/manage/processTodo/getNodesBehind', { params: params }).then(function (resp) {
|
|
1481
1487
|
if (resp.data.code === '200') {
|
|
1482
1488
|
if (resp.data.data.length > 0) {
|
|
1483
1489
|
self.allNode = resp.data.data
|
|
@@ -1491,57 +1497,57 @@ export default {
|
|
|
1491
1497
|
})
|
|
1492
1498
|
},
|
|
1493
1499
|
handleSelectedUser(userId) {
|
|
1494
|
-
this.selectedUserId = userId
|
|
1500
|
+
this.selectedUserId = userId
|
|
1495
1501
|
},
|
|
1496
1502
|
|
|
1497
1503
|
//折叠动画效果
|
|
1498
1504
|
beforeEnter(el) {
|
|
1499
|
-
el.style.height = '0'
|
|
1505
|
+
el.style.height = '0'
|
|
1500
1506
|
},
|
|
1501
1507
|
enter(el, done) {
|
|
1502
1508
|
setTimeout(() => {
|
|
1503
|
-
el.style.height = el.scrollHeight + 'px'
|
|
1504
|
-
}, 0)
|
|
1509
|
+
el.style.height = el.scrollHeight + 'px'
|
|
1510
|
+
}, 0)
|
|
1505
1511
|
|
|
1506
|
-
el.addEventListener('transitionend', done)
|
|
1512
|
+
el.addEventListener('transitionend', done)
|
|
1507
1513
|
},
|
|
1508
1514
|
beforeLeave(el) {
|
|
1509
|
-
el.style.height = el.scrollHeight + 'px'
|
|
1515
|
+
el.style.height = el.scrollHeight + 'px'
|
|
1510
1516
|
},
|
|
1511
1517
|
leave(el, done) {
|
|
1512
1518
|
setTimeout(() => {
|
|
1513
|
-
el.style.height = '0'
|
|
1514
|
-
}, 0)
|
|
1519
|
+
el.style.height = '0'
|
|
1520
|
+
}, 0)
|
|
1515
1521
|
|
|
1516
|
-
el.addEventListener('transitionend', done)
|
|
1522
|
+
el.addEventListener('transitionend', done)
|
|
1517
1523
|
},
|
|
1518
1524
|
|
|
1519
1525
|
beforeFlowInfoEnter(el) {
|
|
1520
|
-
el.style.transform = 'translateX(100%)'
|
|
1526
|
+
el.style.transform = 'translateX(100%)'
|
|
1521
1527
|
},
|
|
1522
1528
|
flowInfoEnter(el, done) {
|
|
1523
|
-
const transitionDuration = 0.5
|
|
1524
|
-
el.style.transition = `transform ${transitionDuration}s
|
|
1525
|
-
el.style.transform = 'translateX(0)'
|
|
1526
|
-
el.addEventListener('transitionend', done)
|
|
1529
|
+
const transitionDuration = 0.5
|
|
1530
|
+
el.style.transition = `transform ${transitionDuration}s`
|
|
1531
|
+
el.style.transform = 'translateX(0)'
|
|
1532
|
+
el.addEventListener('transitionend', done)
|
|
1527
1533
|
},
|
|
1528
1534
|
beforeFlowInfoLeave(el) {
|
|
1529
|
-
el.style.transform = 'translateX(0)'
|
|
1535
|
+
el.style.transform = 'translateX(0)'
|
|
1530
1536
|
},
|
|
1531
1537
|
flowInfoLeave(el, done) {
|
|
1532
|
-
const transitionDuration = 0.5
|
|
1533
|
-
el.style.transition = `transform ${transitionDuration}s
|
|
1534
|
-
el.style.transform = 'translateX(100%)'
|
|
1535
|
-
el.addEventListener('transitionend', done)
|
|
1538
|
+
const transitionDuration = 0.5
|
|
1539
|
+
el.style.transition = `transform ${transitionDuration}s`
|
|
1540
|
+
el.style.transform = 'translateX(100%)'
|
|
1541
|
+
el.addEventListener('transitionend', done)
|
|
1536
1542
|
},
|
|
1537
1543
|
uploadFile(file) {
|
|
1538
|
-
const self = this
|
|
1544
|
+
const self = this
|
|
1539
1545
|
self.fileList = []
|
|
1540
1546
|
file.forEach(item => {
|
|
1541
1547
|
self.fileList.push({
|
|
1542
1548
|
fileName: item.fileName,
|
|
1543
1549
|
fileId: item.fileCode,
|
|
1544
|
-
})
|
|
1550
|
+
})
|
|
1545
1551
|
})
|
|
1546
1552
|
},
|
|
1547
1553
|
|
|
@@ -1555,55 +1561,64 @@ export default {
|
|
|
1555
1561
|
item.assignee ? acc[item.id].assignee = item.assignee : ''
|
|
1556
1562
|
item.candidateGroups ? acc[item.id].candidateGroup = item.candidateGroups : ''
|
|
1557
1563
|
let timeLimit = 'expireTime:0D0H;warningTime:0D0H;handleType:00'
|
|
1558
|
-
if(!(item.remainDay === 0 && item.remainTime === 0 && item.inAdvanceDay === 0 && item.inAdvanceTime === 0)) {
|
|
1559
|
-
timeLimit = 'expireTime:' + parseInt(item.remainDay) +
|
|
1564
|
+
if (!(item.remainDay === 0 && item.remainTime === 0 && item.inAdvanceDay === 0 && item.inAdvanceTime === 0)) {
|
|
1565
|
+
timeLimit = 'expireTime:' + parseInt(item.remainDay) + 'D' + parseInt(item.remainTime) + 'H' + ';warningTime:' + parseInt(item.inAdvanceDay) + 'D' + parseInt(item.inAdvanceTime) + 'H;' + 'handleType:' + item.processing
|
|
1560
1566
|
acc[item.id].timeLimit = timeLimit
|
|
1561
1567
|
} else {
|
|
1562
1568
|
acc[item.id].timeLimit = ''
|
|
1563
1569
|
}
|
|
1564
1570
|
oldSettings = self.nextNodesOldSettings.filter(oldSetting => oldSetting.id === item.id)[0]
|
|
1565
|
-
if (oldSettings.assignee !== item.assignee || self.checkGroupsUpdate(oldSettings.candidates, item.candidateGroups) || self.checkTimeLimitUpdate(oldSettings.timeLimit, timeLimit)) {
|
|
1571
|
+
if (oldSettings.assignee !== item.assignee || self.checkGroupsUpdate(oldSettings.candidates, item.candidateGroups, item.isMultiInstance) || self.checkTimeLimitUpdate(oldSettings.timeLimit, timeLimit)) {
|
|
1566
1572
|
acc[item.id].needUpdate = 'true'
|
|
1567
1573
|
}
|
|
1568
|
-
return acc
|
|
1569
|
-
}, {})
|
|
1574
|
+
return acc
|
|
1575
|
+
}, {})
|
|
1570
1576
|
self.auditParams.nodeConfigMaps = JSON.stringify(params)
|
|
1571
1577
|
self.doPass((execResult, instanceId, taskIds, auditResult, curTaskId) => {
|
|
1572
1578
|
if (this.executionCompleted) {
|
|
1573
|
-
this.executionCompleted(execResult, instanceId, taskIds, auditResult, curTaskId)
|
|
1579
|
+
this.executionCompleted(execResult, instanceId, taskIds, auditResult, curTaskId)
|
|
1574
1580
|
}
|
|
1575
1581
|
})
|
|
1576
1582
|
},
|
|
1577
|
-
checkGroupsUpdate(oldSetting, newSetting) {
|
|
1583
|
+
checkGroupsUpdate(oldSetting, newSetting, isMultiInstance) {
|
|
1578
1584
|
if (oldSetting && newSetting) {
|
|
1579
1585
|
let oldIdList = []
|
|
1580
1586
|
for (let [key, value] of Object.entries(oldSetting)) {
|
|
1581
1587
|
if (value) {
|
|
1582
1588
|
value.split(',').forEach(part => {
|
|
1583
|
-
const [id] = part.split(':')
|
|
1589
|
+
const [id] = part.split(':')
|
|
1584
1590
|
if (id) {
|
|
1585
|
-
oldIdList.push(id)
|
|
1591
|
+
oldIdList.push(id)
|
|
1586
1592
|
}
|
|
1587
1593
|
})
|
|
1588
1594
|
}
|
|
1589
1595
|
}
|
|
1590
|
-
const regex = /(?:O:|U:|P:|R:|T:)([^,]+)/g
|
|
1591
|
-
let match
|
|
1592
|
-
const newIds = []
|
|
1596
|
+
const regex = /(?:O:|U:|P:|R:|T:)([^,]+)/g
|
|
1597
|
+
let match
|
|
1598
|
+
const newIds = []
|
|
1593
1599
|
while ((match = regex.exec(newSetting)) !== null) {
|
|
1594
1600
|
newIds.push(...match[1].split(';'))
|
|
1595
1601
|
}
|
|
1596
|
-
|
|
1597
|
-
|
|
1598
|
-
|
|
1602
|
+
|
|
1603
|
+
if (isMultiInstance) {
|
|
1604
|
+
//串签的情况下可能只有顺序发生了变化
|
|
1605
|
+
const oldStr = oldIdList.join(',')
|
|
1606
|
+
const newStr = newIds.join(',')
|
|
1607
|
+
return oldStr !== newStr
|
|
1608
|
+
}else {
|
|
1609
|
+
const allInString = oldIdList.every(item => newIds.includes(item));
|
|
1610
|
+
const hasExtra = newIds.some(item => !oldIdList.includes(item));
|
|
1611
|
+
return !allInString || hasExtra
|
|
1612
|
+
}
|
|
1613
|
+
|
|
1599
1614
|
}
|
|
1600
1615
|
return false
|
|
1601
1616
|
},
|
|
1602
|
-
checkTimeLimitUpdate(oldSetting, newSetting){
|
|
1603
|
-
if (oldSetting && newSetting){
|
|
1617
|
+
checkTimeLimitUpdate(oldSetting, newSetting) {
|
|
1618
|
+
if (oldSetting && newSetting) {
|
|
1604
1619
|
return oldSetting !== newSetting
|
|
1605
1620
|
}
|
|
1606
|
-
if (!oldSetting){
|
|
1621
|
+
if (!oldSetting) {
|
|
1607
1622
|
return newSetting !== 'expireTime:0D0H;warningTime:0D0H;handleType:00'
|
|
1608
1623
|
}
|
|
1609
1624
|
return false
|
|
@@ -1616,9 +1631,9 @@ export default {
|
|
|
1616
1631
|
candidateGroupsReadingRangeClick(item) {
|
|
1617
1632
|
let permScope = item.orgTreeType === this.defaultOrganTreeType ? this.permScope : 'all'
|
|
1618
1633
|
let orgTreeType = item.orgTreeType ? item.orgTreeType : this.defaultOrganTreeType
|
|
1619
|
-
this.$refs.candidateGroupsHelpBox.toggleShowHelpBox(permScope, item.candidates, orgTreeType, item.id)
|
|
1634
|
+
this.$refs.candidateGroupsHelpBox.toggleShowHelpBox(permScope, item.candidates, orgTreeType, item.id)
|
|
1620
1635
|
},
|
|
1621
|
-
updateCandGroups(newCandGroups, nameStr, detail, nodeId){
|
|
1636
|
+
updateCandGroups(newCandGroups, nameStr, detail, nodeId) {
|
|
1622
1637
|
let oldSettings = this.nextNodesOldSettings.filter(item => item.id === nodeId)[0]
|
|
1623
1638
|
if (JSON.stringify(oldSettings.candidates) != JSON.stringify(detail)) {
|
|
1624
1639
|
let node = this.nextNodesFormList.filter(item => item.id === nodeId)[0]
|
|
@@ -1626,26 +1641,26 @@ export default {
|
|
|
1626
1641
|
node.candidateNames = nameStr
|
|
1627
1642
|
node.candidates = detail
|
|
1628
1643
|
node.needUpdate = true
|
|
1629
|
-
this.$forceUpdate()
|
|
1644
|
+
this.$forceUpdate()
|
|
1630
1645
|
}
|
|
1631
1646
|
},
|
|
1632
|
-
updateNextNodeAssignee(selectedAssigneeId, selectedAssigneeName, nodeId){
|
|
1647
|
+
updateNextNodeAssignee(selectedAssigneeId, selectedAssigneeName, nodeId) {
|
|
1633
1648
|
let oldSettings = this.nextNodesOldSettings.filter(item => item.id === nodeId)[0]
|
|
1634
1649
|
if (oldSettings.assignee != selectedAssigneeId) {
|
|
1635
1650
|
let node = this.nextNodesFormList.filter(item => item.id === nodeId)[0]
|
|
1636
1651
|
node.assignee = selectedAssigneeId
|
|
1637
1652
|
node.assigneeName = selectedAssigneeName
|
|
1638
1653
|
node.needUpdate = true
|
|
1639
|
-
this.$forceUpdate()
|
|
1654
|
+
this.$forceUpdate()
|
|
1640
1655
|
}
|
|
1641
1656
|
}
|
|
1642
1657
|
},
|
|
1643
1658
|
watch: {
|
|
1644
1659
|
auditOpinionText(label) {
|
|
1645
|
-
this.form.auditOpinion = label
|
|
1660
|
+
this.form.auditOpinion = label
|
|
1646
1661
|
},
|
|
1647
1662
|
procId(val) {
|
|
1648
|
-
this.procId = val
|
|
1663
|
+
this.procId = val
|
|
1649
1664
|
this.initData()
|
|
1650
1665
|
},
|
|
1651
1666
|
}
|