vue2-client 1.14.66 → 1.14.67

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.
@@ -1,90 +1,47 @@
1
- <template>
2
- <a-card :bordered="false">
3
- <x-form-table
4
- title="示例页面"
5
- :queryParamsName="queryParamsName"
6
- :fixed-query-form="{
7
- users_f_handler_id: currUser.id,
8
- }"
9
- @action="toDetail">
10
- <template slot="button">
11
- <a-button @click="add">
12
- <a-icon type="plus"/>
13
- 发起报建
14
- </a-button>
15
- </template>
16
- </x-form-table>
17
- <a-modal
18
- v-model="applyAddFlag"
19
- :footer="null"
20
- :dialog-style="{ top: '5rem' }"
21
- :z-index="1001"
22
- title="发起报建"
23
- :destroyOnClose="true">
24
- <x-add-native-form ref="xForm" @onSubmit="applySubmit"/>
25
- </a-modal>
26
- <WorkflowDetail ref="workFlow" @success="success"></WorkflowDetail>
27
- </a-card>
28
- </template>
29
-
30
1
  <script>
31
2
  import WorkflowDetail from '@vue2-client/pages/WorkflowDetail/WorkflowDetail.vue'
32
- import XFormTable from '@vue2-client/base-client/components/common/XFormTable/XFormTable'
33
- import XAddNativeForm from '@vue2-client/base-client/components/common/XAddNativeForm/XAddNativeForm.vue'
34
- import { getConfigByName, runLogic } from '@vue2-client/services/api/common'
35
- import { mapState } from 'vuex'
36
3
 
37
4
  export default {
38
- name: 'Apply',
39
- components: {
40
- XFormTable,
41
- XAddNativeForm,
42
- WorkflowDetail
43
- },
44
- data () {
45
- return {
46
- // 查询配置文件名
47
- queryParamsName: 'applyCRUD',
48
- // 发起报建弹框控制
49
- applyAddFlag: false
50
- }
51
- },
52
- computed: {
53
- ...mapState('account', { currUser: 'user' }),
5
+ name: 'WorkFlowDemo',
6
+ components: { WorkflowDetail },
7
+ mounted () {
8
+ this.$refs.workFlow.init({
9
+ workflowId: '54'
10
+ })
54
11
  },
55
12
  methods: {
56
- add () {
57
- this.applyAddFlag = true
58
- this.$nextTick(
59
- () => {
60
- getConfigByName('addApplyForm', 'af-apply', (res) => {
61
- this.$refs.xForm.init({
62
- businessType: '新增',
63
- title: '发起报建',
64
- ...res
65
- })
66
- })
67
- }
68
- )
69
- },
70
- applySubmit (formData) {
71
- runLogic('addApply', formData).then(
72
- res => {
73
- this.$message.success('发起报建成功')
74
- this.applyAddFlag = false
75
- }
76
- ).catch(() => {
77
- this.applyAddFlag = false
78
- })
13
+ /**
14
+ * 流程详情页成功
15
+ * @param note 备注信息
16
+ * @param form 表单信息
17
+ * @param workflowId
18
+ */
19
+ success ({ note, form, workflowId }) {
20
+ console.log('success', note, form, workflowId)
79
21
  },
80
- success () {
81
- console.log('完工')
82
- },
83
- toDetail (record, id) {
84
- this.$refs.workFlow.init({
85
- workflowId: record.twf_id
86
- })
22
+ /**
23
+ * 流程详情页成功
24
+ * @param note 备注信息
25
+ * @param form 表单信息
26
+ * @param workflowId 工作流id
27
+ * @param fromStepId 起ID
28
+ * @param toStepId 往ID
29
+ * @param successStepId 完成步骤id
30
+ * @param successStep 完成步骤名称
31
+ * @param fromStep 起步骤名称
32
+ * @param toStep 往步骤名称
33
+ */
34
+ nextClick ({ note, form, workflowId, fromStepId, toStepId, fromStep, toStep, successStepId, successStep }) {
35
+ console.log('success', note, form, workflowId, fromStepId, toStepId, fromStep, toStep, successStepId, successStep)
87
36
  }
88
37
  }
89
38
  }
90
39
  </script>
40
+
41
+ <template>
42
+ <WorkflowDetail ref="workFlow" @success="success" @nextClick="nextClick"></WorkflowDetail>
43
+ </template>
44
+
45
+ <style scoped lang="less">
46
+
47
+ </style>
@@ -87,13 +87,11 @@
87
87
  </a-tab-pane>
88
88
 
89
89
  <!-- 查看附件标签页 -->
90
- <!-- <a-tab-pane key="5" tab="查看附件">-->
91
- <!-- <template v-if="details">-->
92
- <!-- <XUploadFilesView-->
93
- <!-- :currUserInfo="{ f_userinfo_id: 90613 }"-->
94
- <!-- />-->
95
- <!-- </template>-->
96
- <!-- </a-tab-pane>-->
90
+ <a-tab-pane key="5" tab="查看附件">
91
+ <template v-if="activeKey === '5' && details">
92
+ <file-item-group @search="getWorkFlowFiles"/>
93
+ </template>
94
+ </a-tab-pane>
97
95
  </a-tabs>
98
96
  </a-card>
99
97
  </div>
@@ -111,10 +109,12 @@ import { workFlowViewApi } from '@vue2-client/services/api/workFlow'
111
109
  import WorkflowLog from './WorkflowPageDetail/WorkflowLog.vue'
112
110
  import LeaveMessage from './WorkflowPageDetail/LeaveMessage'
113
111
  import XUploadFilesView from '@vue2-client/base-client/components/common/XUploadFilesView/index.vue'
112
+ import FileItemGroup from '@vue2-client/components/FileImageItem/FileItemGroup.vue'
114
113
 
115
114
  export default {
116
115
  name: 'WorkflowDetail',
117
116
  components: {
117
+ FileItemGroup,
118
118
  workflowBaseInformation,
119
119
  WorkFlowHandle,
120
120
  XFormTable,
@@ -208,6 +208,15 @@ export default {
208
208
  console.log(err)
209
209
  })
210
210
  },
211
+ // 获取附件列表
212
+ getWorkFlowFiles (date, callback, errorCallback) {
213
+ postByServiceName(workFlowViewApi.getWorkFlowAttachments, {
214
+ workflowId: this.workflowId,
215
+ uploadDate: date
216
+ })
217
+ .then(res => callback(res))
218
+ .catch((e) => errorCallback(e))
219
+ },
211
220
  async reload () {
212
221
  await this.getSteps()
213
222
  await this.getBaseInfo()