eoss 0.1.0-alpha.21 → 0.1.0-alpha.22

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.
Files changed (195) hide show
  1. package/lib/account-login.js +129 -129
  2. package/lib/alert.js +2 -2
  3. package/lib/aside.js +2 -2
  4. package/lib/autocomplete.js +216 -216
  5. package/lib/avatar.js +2 -2
  6. package/lib/backtop.js +2 -2
  7. package/lib/badge.js +2 -2
  8. package/lib/breadcrumb.js +2 -2
  9. package/lib/ca-login.js +6 -6
  10. package/lib/calendar.js +2 -2
  11. package/lib/card.js +2 -2
  12. package/lib/carousel-item.js +21 -21
  13. package/lib/carousel.js +16 -16
  14. package/lib/cascader-panel.js +6 -6
  15. package/lib/cascader.js +230 -230
  16. package/lib/checkbox-group.js +138 -138
  17. package/lib/col.js +2 -2
  18. package/lib/collapse-item.js +423 -410
  19. package/lib/collapse.js +426 -412
  20. package/lib/color-picker.js +23 -23
  21. package/lib/container.js +2 -2
  22. package/lib/cron.js +2 -2
  23. package/lib/data-table.js +123 -123
  24. package/lib/date-picker.js +233 -233
  25. package/lib/dialog.js +8 -8
  26. package/lib/divider.js +2 -2
  27. package/lib/drawer.js +4 -4
  28. package/lib/dropdown-item.js +2 -2
  29. package/lib/dropdown-menu.js +6 -6
  30. package/lib/dropdown.js +13 -13
  31. package/lib/email-login.js +124 -124
  32. package/lib/empty.js +2 -2
  33. package/lib/eoss.common.js +21948 -21788
  34. package/lib/flip.js +2 -2
  35. package/lib/flow-group.js +251 -251
  36. package/lib/flow.js +15934 -18947
  37. package/lib/flows.js +9195 -0
  38. package/lib/footer.js +2 -2
  39. package/lib/form-item.js +28 -17
  40. package/lib/form.js +426 -412
  41. package/lib/header.js +2 -2
  42. package/lib/icon.js +128 -128
  43. package/lib/icons.js +2 -2
  44. package/lib/image-viewer.js +6 -6
  45. package/lib/image.js +2 -2
  46. package/lib/index.js +1 -1
  47. package/lib/infinite-scroll.js +2 -2
  48. package/lib/input.js +4 -4
  49. package/lib/link.js +2 -2
  50. package/lib/loading.js +4 -4
  51. package/lib/login.js +190 -156
  52. package/lib/lowcode.js +562 -272
  53. package/lib/main.js +348 -282
  54. package/lib/marquee.js +6 -6
  55. package/lib/menu.js +209 -209
  56. package/lib/message-box.js +8 -8
  57. package/lib/message.js +8 -8
  58. package/lib/notification.js +8 -8
  59. package/lib/option-group.js +2 -2
  60. package/lib/option.js +4 -4
  61. package/lib/page-header.js +2 -2
  62. package/lib/pagination.js +6 -6
  63. package/lib/phone-login.js +124 -124
  64. package/lib/popconfirm.js +2 -2
  65. package/lib/popover.js +209 -209
  66. package/lib/progress.js +2 -2
  67. package/lib/qr-code.js +2 -2
  68. package/lib/qrcode-login.js +123 -123
  69. package/lib/radio-group.js +121 -121
  70. package/lib/rate.js +4 -4
  71. package/lib/row.js +2 -2
  72. package/lib/scrollbar.js +6 -6
  73. package/lib/select.js +470 -457
  74. package/lib/selector-panel.js +141 -141
  75. package/lib/selector.js +130 -130
  76. package/lib/step.js +426 -412
  77. package/lib/steps.js +6 -6
  78. package/lib/submenu.js +4 -4
  79. package/lib/switch.js +4 -4
  80. package/lib/tab-pane.js +2 -2
  81. package/lib/table-column.js +6 -6
  82. package/lib/table.js +460 -460
  83. package/lib/tabs.js +6 -6
  84. package/lib/tag.js +2 -2
  85. package/lib/theme-chalk/autocomplete.css +1 -1
  86. package/lib/theme-chalk/base.css +1 -1
  87. package/lib/theme-chalk/cascader-panel.css +1 -1
  88. package/lib/theme-chalk/cascader.css +1 -1
  89. package/lib/theme-chalk/checkbox-group.css +1 -1
  90. package/lib/theme-chalk/date-picker.css +1 -1
  91. package/lib/theme-chalk/descriptions-item.css +1 -1
  92. package/lib/theme-chalk/descriptions.css +1 -1
  93. package/lib/theme-chalk/empty.css +1 -1
  94. package/lib/theme-chalk/flow.css +1 -1
  95. package/lib/theme-chalk/flows.css +1 -0
  96. package/lib/theme-chalk/form.css +1 -1
  97. package/lib/theme-chalk/index.css +1 -1
  98. package/lib/theme-chalk/input-number.css +1 -1
  99. package/lib/theme-chalk/input.css +1 -1
  100. package/lib/theme-chalk/lowcode.css +1 -1
  101. package/lib/theme-chalk/main.css +1 -1
  102. package/lib/theme-chalk/menu.css +1 -1
  103. package/lib/theme-chalk/message-box.css +1 -1
  104. package/lib/theme-chalk/message.css +1 -1
  105. package/lib/theme-chalk/notification.css +1 -1
  106. package/lib/theme-chalk/pagination.css +1 -1
  107. package/lib/theme-chalk/scrollbar.css +1 -1
  108. package/lib/theme-chalk/select.css +1 -1
  109. package/lib/theme-chalk/selector-panel.css +1 -1
  110. package/lib/theme-chalk/selector.css +1 -1
  111. package/lib/theme-chalk/slider.css +1 -1
  112. package/lib/theme-chalk/table.css +1 -1
  113. package/lib/theme-chalk/tabs.css +1 -1
  114. package/lib/theme-chalk/time-picker.css +1 -1
  115. package/lib/theme-chalk/time-select.css +1 -1
  116. package/lib/theme-chalk/timeline-item.css +1 -1
  117. package/lib/theme-chalk/transfer.css +1 -1
  118. package/lib/theme-chalk/tree.css +1 -1
  119. package/lib/theme-chalk/upload.css +1 -1
  120. package/lib/time-picker.js +8 -8
  121. package/lib/time-select.js +6 -6
  122. package/lib/timeline-item.js +2 -2
  123. package/lib/timeline.js +2 -2
  124. package/lib/tips.js +124 -124
  125. package/lib/toolbar.js +4 -4
  126. package/lib/tooltip.js +209 -209
  127. package/lib/transfer.js +4 -4
  128. package/lib/tree-group.js +122 -122
  129. package/lib/tree.js +121 -121
  130. package/lib/upload.js +131 -131
  131. package/package.json +1 -1
  132. package/packages/carousel/src/carousel.vue +2 -2
  133. package/packages/flow/index.js +4 -4
  134. package/packages/flow/src/component/FreeCirculation.vue +4 -3
  135. package/packages/flow/src/component/SendMsg.vue +2 -4
  136. package/packages/flow/src/component/opinions.vue +203 -226
  137. package/packages/flow/src/component/taskUnionExamine.vue +2 -4
  138. package/packages/flow/src/freeStartFlow.vue +2 -2
  139. package/packages/flow/src/selectUser.vue +36 -1
  140. package/packages/flow/src/supervise.vue +4 -2
  141. package/packages/flows/index.js +7 -0
  142. package/packages/flows/readme.md +600 -0
  143. package/packages/flows/src/components/basis.vue +108 -0
  144. package/packages/flows/src/components/distribute.vue +42 -0
  145. package/packages/flows/src/components/opinions-file.vue +123 -0
  146. package/packages/{flow-copy/src/component → flows/src/components}/opinions.vue +227 -204
  147. package/packages/flows/src/components/quick-actions.vue +64 -0
  148. package/packages/flows/src/components/reject.vue +83 -0
  149. package/packages/flows/src/components/start-flow.vue +210 -0
  150. package/packages/flows/src/flow.vue +510 -0
  151. package/packages/{flow/src/flow.vue → flows/src/flows.vue} +40 -1327
  152. package/packages/form/src/form-item.vue +9 -2
  153. package/packages/form/src/label-wrap.vue +4 -1
  154. package/packages/login/src/login.vue +61 -32
  155. package/packages/lowcode/src/lowcode.vue +141 -40
  156. package/packages/lowcode/src/pages.vue +27 -7
  157. package/packages/lowcode/src/toolbar.vue +3 -18
  158. package/packages/main/src/components/pages.vue +97 -65
  159. package/packages/main/src/components/router-page.vue +0 -2
  160. package/packages/main/src/gzw.vue +3 -2
  161. package/packages/main/src/minxs.js +71 -51
  162. package/packages/select/src/select.vue +5 -0
  163. package/packages/theme-chalk/src/base.scss +6 -0
  164. package/packages/theme-chalk/src/checkbox-group.scss +1 -0
  165. package/packages/theme-chalk/src/common/var.scss +1 -1
  166. package/packages/theme-chalk/src/flow.scss +7 -4
  167. package/packages/theme-chalk/src/flows.scss +141 -0
  168. package/packages/theme-chalk/src/form.scss +1 -1
  169. package/packages/theme-chalk/src/index.scss +1 -0
  170. package/packages/theme-chalk/src/input.scss +1 -0
  171. package/packages/theme-chalk/src/select.scss +3 -1
  172. package/packages/theme-chalk/src/selector.scss +1 -1
  173. package/src/index.js +4 -1
  174. package/packages/flow/src/component/quick-actions.vue +0 -1168
  175. package/packages/flow-copy/index.js +0 -7
  176. package/packages/flow-copy/src/component/Circulate.vue +0 -452
  177. package/packages/flow-copy/src/component/CustomPreset.vue +0 -333
  178. package/packages/flow-copy/src/component/FreeCirculation.vue +0 -275
  179. package/packages/flow-copy/src/component/Preset.vue +0 -273
  180. package/packages/flow-copy/src/component/SendMsg.vue +0 -290
  181. package/packages/flow-copy/src/component/TimeLimit.vue +0 -205
  182. package/packages/flow-copy/src/component/taskUnionExamine.vue +0 -818
  183. package/packages/flow-copy/src/freeStartFlow.vue +0 -2912
  184. package/packages/flow-copy/src/processForm.vue +0 -1411
  185. package/packages/flow-copy/src/processReject.vue +0 -319
  186. package/packages/flow-copy/src/reset.vue +0 -944
  187. package/packages/flow-copy/src/selectUser.vue +0 -513
  188. package/packages/flow-copy/src/startTaskRead.vue +0 -723
  189. package/packages/flow-copy/src/supervise.vue +0 -182
  190. package/packages/flow-copy/src/table.vue +0 -65
  191. /package/packages/{flow-copy → flow}/src/component/FileList.vue +0 -0
  192. /package/packages/{flow-copy → flow}/src/main.vue +0 -0
  193. /package/packages/{flow-copy/src → flows/src/components}/form.vue +0 -0
  194. /package/packages/{flow/src/component → flows/src/components}/message.vue +0 -0
  195. /package/packages/{flow/src/component → flows/src/components}/opinions-list.vue +0 -0
@@ -1,273 +0,0 @@
1
- <template>
2
- <es-collapse v-model="parserActive" accordion>
3
- <es-collapse-item :title="'预设办理人信息'" name="1">
4
- <div v-for="(item, index) of nodeList" :key="index">
5
- <es-form-item prop="flow" :label="`➤ 节点`">
6
- <es-select
7
- v-model="item.name"
8
- @change="changePreset($event, null, index)"
9
- >
10
- <es-option
11
- v-for="items in item.option"
12
- :key="items.nodeId"
13
- :label="items.nodeName"
14
- :value="items.nodeId"
15
- ></es-option>
16
- </es-select>
17
- </es-form-item>
18
- <es-form-item v-if="item.name != 'endEvent'" prop="user" label="办理人">
19
- <SelectUser
20
- ref="selectUser"
21
- :showUser="true"
22
- :nextUser="item.nextUser"
23
- :radioList="item.radioList"
24
- :multiple="item.multiple"
25
- :isCustomUser="item.isCustomUser"
26
- :options="item.options"
27
- :presetEdit="item.presetEdit"
28
- :selectUserList="item.selectUserList"
29
- @change="changePresetUser($event, index)"
30
- :types="['employee', 'persongroup']"
31
- :params="item.params"
32
- />
33
- </es-form-item>
34
- </div>
35
- </es-collapse-item>
36
- </es-collapse>
37
- </template>
38
-
39
- <script>
40
- import { getPresetNodeInfo } from 'eoss/src/config/api';
41
- import SelectUser from '../selectUser.vue';
42
- import { success, error } from 'eoss/src/utils/util';
43
- import { ajax } from 'eoss/src/utils/ajax';
44
- import { getStorage } from 'eoss/src/utils/storage';
45
- export default {
46
- name: 'Parser',
47
- components: {
48
- [SelectUser.name]: SelectUser
49
- },
50
- data() {
51
- return {
52
- nodeList: [],
53
- nextNodeId: '',
54
- parserActive: ''
55
- };
56
- },
57
- props: {
58
- /**
59
- * 默认选中子节点
60
- */
61
- processDefinitionId: {
62
- type: String,
63
- default: ''
64
- },
65
- /**
66
- *
67
- */
68
- presetTaskNodeKeyStr: {
69
- type: String,
70
- default: ''
71
- },
72
- /**
73
- *
74
- */
75
- customPresetHintMessage: {
76
- type: String,
77
- default: ''
78
- },
79
- /**
80
- * 预设节点信息
81
- */
82
- presetTaskNodeMap: {
83
- type: Object,
84
- default: () => {}
85
- },
86
- /**
87
- * 待办ID
88
- */
89
- pendingId: {
90
- type: String,
91
- default: ''
92
- },
93
- /**
94
- * 业务ID
95
- */
96
- businessId: {
97
- type: String,
98
- default: ''
99
- },
100
- /**
101
- * 流程节点ID
102
- */
103
- nodeId: {
104
- type: String,
105
- default: ''
106
- }
107
- },
108
- watch: {
109
- presetTaskNodeKeyStr: {
110
- handler(val) {
111
- this.getNodeList();
112
- },
113
- deep: true,
114
- immediate: true
115
- },
116
- parserActive: {
117
- handler(val) {
118
- if (val === '1') {
119
- this.getNodeUser();
120
- }
121
- },
122
- deep: true,
123
- immediate: true
124
- }
125
- },
126
- methods: {
127
- changeSelectData() {
128
- let presetUserJson = [];
129
- this.nodeList.map((item) => {
130
- presetUserJson.push({
131
- name: item.name,
132
- value: item.multiple ? item.nextUser.join(',') : item.nextUser
133
- });
134
- });
135
- this.$emit('changePreset', presetUserJson);
136
- this.$emit('change-preset', presetUserJson);
137
- },
138
- changePresetUser(val, index) {
139
- const { nextUser } = val;
140
- this.nodeList[index].nextUser = nextUser;
141
- this.changeSelectData();
142
- },
143
- getNodeList() {
144
- for (let key in this.presetTaskNodeMap) {
145
- this.nextNodeId = this.nextNodeId
146
- ? this.nextNodeId + ',' + key
147
- : this.nextNodeId + key;
148
- this.nodeList.push({
149
- name: key,
150
- option: [{ nodeId: key, nodeName: this.presetTaskNodeMap[key] }]
151
- });
152
- }
153
- },
154
- getNodeUser() {
155
- this.$emit('loadingStart');
156
- this.$emit('loading-start');
157
- const { nextNodeId, processDefinitionId, businessId, pendingId, nodeId } =
158
- this;
159
- let params = {
160
- url: getPresetNodeInfo,
161
- data: {
162
- nextNodeId,
163
- processDefinitionId,
164
- businessId,
165
- pendingId,
166
- nodeId
167
- },
168
- method: 'post'
169
- };
170
- ajax(params)
171
- .then((res) => {
172
- const { status, message, data } = res;
173
- if (status == 'success') {
174
- if (data) {
175
- this.nodeList.map((item) => {
176
- for (let key in data) {
177
- if (item.name === key) {
178
- item.configInfo = data[key];
179
- }
180
- }
181
- });
182
- this.getConfig();
183
- }
184
- } else {
185
- error(message || '系统错误,请联系管理员!');
186
- }
187
- })
188
- .catch((err) => {});
189
- },
190
- getConfig() {
191
- this.nodeList = this.nodeList.filter(
192
- (item) => item.name.indexOf(this.nodeId) == -1
193
- );
194
- this.nodeList.map((item, index) => {
195
- const { multiple, params } = this.isMultiple(
196
- item.configInfo.nodeExtAttr.userSelectionType
197
- );
198
- item.multiple = multiple;
199
- item.params = params;
200
- item.presetEdit = item.configInfo.nodeExtAttr.presetEdit;
201
- item.nextUser = [];
202
- item.options = [];
203
- item.radioList = [];
204
- item.selectUserList = [];
205
- item.isDefSelectedObj = item.configInfo.nodeExtAttr.isDefSelectedObj;
206
- item.configInfo.nextUserList.map((items) => {
207
- if (item.multiple && item.isDefSelectedObj == 1) {
208
- item.nextUser.push(items.userId);
209
- item.selectUserList.push({
210
- showname: items.username,
211
- showid: items.userId
212
- });
213
- }
214
- item.options.push({
215
- showname: items.username,
216
- showid: items.userId
217
- });
218
- });
219
- if (
220
- !item.multiple &&
221
- item.configInfo.nextUserList.length > 0 &&
222
- item.isDefSelectedObj == 1
223
- ) {
224
- item.nextUser = item.configInfo.nextUserList[0].userId;
225
- item.selectUserList.push({
226
- showname: item.configInfo.nextUserList[0].username,
227
- showid: item.configInfo.nextUserList[0].userId
228
- });
229
- }
230
- if (!item.multiple && item.isDefSelectedObj != 1) item.nextUser = '';
231
- item.presetEdit != 0 && (item.radioList = item.options);
232
- this.$refs.selectUser[index].changeInfo(item);
233
- });
234
- this.changeSelectData();
235
- this.$emit('loadingEnd');
236
- this.$emit('loading-end');
237
- },
238
- isMultiple(val, choiceOrgId, choiceDeptId, pOrgId) {
239
- let multiple = false;
240
- let params = {};
241
- if (val == 2 || val == 4 || val == 6 || val == 16) {
242
- multiple = true;
243
- }
244
- if (val == 1 || val == 2 || val == 5) {
245
- params.filid = getStorage('orgId');
246
- params.only_filid = true;
247
- if (choiceOrgId) {
248
- params.filid = choiceOrgId;
249
- }
250
- }
251
- if (val == 5 || val == 6) {
252
- params.filid = getStorage('orgId');
253
- params.deptid = getStorage('orgId');
254
- if (choiceDeptId) {
255
- params.deptid = choiceDeptId;
256
- }
257
- if (choiceOrgId) {
258
- params.filid = choiceOrgId;
259
- }
260
- }
261
- if (val == 15 || val == 16) {
262
- params.filid = getStorage('orgId');
263
- if (pOrgId) {
264
- params.filid = pOrgId;
265
- }
266
- }
267
- return { multiple, params };
268
- }
269
- }
270
- };
271
- </script>
272
-
273
- <style></style>
@@ -1,290 +0,0 @@
1
- <template>
2
- <div v-loading="loading === true" class="sendForm">
3
- <es-form
4
- ref="sendForm"
5
- :model="sendInfo"
6
- class="demo-dynamic"
7
- label-width="150px"
8
- >
9
- <es-form-item prop="nodeName" label="标题">
10
- <div>{{ sendInfo.title }}</div>
11
- </es-form-item>
12
- <!-- :rules="[
13
- { required: false, message: `请选择通知方式`, trigger: 'blur' }
14
- ]" -->
15
- <es-form-item
16
- prop="notificationType"
17
- label="通知方式"
18
- v-show="notificationList.length != 0"
19
- >
20
- <es-checkbox-group
21
- v-model="sendInfo.notificationType"
22
- style="display: contents"
23
- >
24
- <es-checkbox
25
- v-for="item of notificationList"
26
- :key="item.cciValue"
27
- :label="item.cciValue"
28
- :disabled="
29
- readOnlyNotificationType
30
- ? readOnlyNotificationType.indexOf(item.cciValue) != -1
31
- : false
32
- "
33
- >
34
- {{ item.shortName }}
35
- </es-checkbox>
36
- </es-checkbox-group>
37
- </es-form-item>
38
- <es-form-item
39
- prop="nextNode"
40
- label="通知消息"
41
- v-show="notificationList.length != 0"
42
- >
43
- <es-input
44
- type="textarea"
45
- autosize
46
- v-model="sendInfo.notificationMsg"
47
- :readonly="notificationMessageReadOnly"
48
- />
49
- </es-form-item>
50
- <es-table
51
- ref="multipleTable"
52
- :data="sendTable"
53
- tooltip-effect="dark"
54
- style="width: 100%"
55
- height="250"
56
- :cell-class-name="cellcb"
57
- @selection-change="handleSelectionChange"
58
- >
59
- <es-table-column type="selection" width="55"> </es-table-column>
60
- <es-table-column type="index" label="序号" width="50">
61
- </es-table-column>
62
- <es-table-column prop="userid" label="经办人" width="120">
63
- </es-table-column>
64
- <es-table-column prop="itemname" label="步骤" show-overflow-tooltip>
65
- </es-table-column>
66
- <es-table-column label="状态" show-overflow-tooltip>
67
- <template slot-scope="scope"
68
- ><span
69
- :style="`${
70
- scope.row.pendstate == 0
71
- ? 'color:red'
72
- : scope.row.pendstate == 1
73
- ? 'color:green'
74
- : ''
75
- }`"
76
- >{{ scope.row.querykeywords }}</span
77
- ></template
78
- >
79
- </es-table-column>
80
- <es-table-column label="日期">
81
- <template slot-scope="scope">{{
82
- scope.row.statechangetime | date
83
- }}</template>
84
- </es-table-column>
85
- </es-table>
86
- <es-form-item v-show="showBtn">
87
- <div style="text-align: right">
88
- <es-button type="primary" size="small" @click="subProcess">
89
- 确定
90
- </es-button>
91
- <es-button @click="quit" size="small"> 取消 </es-button>
92
- </div>
93
- </es-form-item>
94
- </es-form>
95
- <!-- <div v-show="notificationList.length != 0">
96
- <div class="news" >
97
- <span class="news-item">消息通知</span>
98
-
99
- </div>
100
- <es-checkbox-group
101
- v-model="sendInfo.notificationType"
102
- style="display: contents"
103
- >
104
- <es-checkbox
105
- v-for="item of notificationList"
106
- :key="item.cciValue"
107
- :label="item.cciValue"
108
- :disabled="
109
- readOnlyNotificationType
110
- ? readOnlyNotificationType.indexOf(item.cciValue) != -1
111
- : false
112
- "
113
- >
114
- {{ item.shortName }}
115
- </es-checkbox>
116
- </es-checkbox-group>
117
- <es-input
118
- type="textarea"
119
- autosize
120
- v-model="sendInfo.notificationMsg"
121
- :readonly="notificationMessageReadOnly"
122
- />
123
- </div> -->
124
- </div>
125
- </template>
126
-
127
- <script>
128
- import { formatDate } from 'eoss/src/utils/date';
129
- import { success, error } from 'eoss/src/utils/util';
130
- import { ajax } from 'eoss/src/utils/ajax';
131
- import { getStorage } from 'eoss/src/utils/storage';
132
- import { toSendMsg, sendMsg } from 'eoss/src/config/api.js';
133
- export default {
134
- name: 'SendMsg',
135
- data() {
136
- return {
137
- sendInfo: {
138
- title: '',
139
- notificationType: ['0', '3'],
140
- notificationMsg: ''
141
- },
142
- appId: '',
143
- notificationMessageReadOnly: true,
144
- readOnlyNotificationType: '',
145
- loading: false,
146
- pendHistoryIds: '',
147
- notificationList: [],
148
- sendTable: []
149
- };
150
- },
151
- props: {
152
- /**
153
- * 通知类型列表
154
- */
155
- newsList: {
156
- type: Array,
157
- default: () => []
158
- },
159
- /**
160
- * 流程提交成功后是否展示弹窗确认
161
- */
162
- simpleTips: {
163
- type: Boolean,
164
- default: true
165
- },
166
- /**
167
- * 是否显示提交按钮
168
- */
169
- showBtn: {
170
- type: Boolean,
171
- default: false
172
- }
173
- },
174
- mounted() {
175
- this.getSendMsg();
176
- this.notificationList = JSON.parse(JSON.stringify(this.newsList));
177
- },
178
- filters: {
179
- date(val) {
180
- return formatDate(val, 'yyyy-MM-dd HH:mm');
181
- }
182
- },
183
- methods: {
184
- subProcess() {
185
- this.loading = true;
186
- const {
187
- pendHistoryIds,
188
- appId,
189
- sendInfo: { notificationMsg, notificationType }
190
- } = this;
191
- const params = {
192
- url: sendMsg,
193
- headers: { Accept: 'application/json,text/plain' },
194
- method: 'post',
195
- data: {
196
- pendHistoryIds,
197
- appId,
198
- notificationMsg,
199
- notificationType: notificationType.join(',')
200
- }
201
- };
202
- ajax(params)
203
- .then((res) => {
204
- const { message, status } = res;
205
- this.loading = false;
206
- if (status === 'success') {
207
- this.simpleTips &&
208
- this.$message({
209
- message: '操作成功',
210
- type: 'success'
211
- });
212
- this.quit(true);
213
- } else {
214
- this.$message({
215
- message: message || '系统错误,请联系管理员!',
216
- type: 'error'
217
- });
218
- }
219
- })
220
- .catch((err) => {
221
- this.loading = false;
222
- });
223
- },
224
- quit(val) {
225
- if (val === true) return this.$emit('cancel', val);
226
- this.$emit('cancel');
227
- },
228
- cellcb(row) {
229
- if (row.row.pendstate != 2) {
230
- return 'no-checked';
231
- }
232
- },
233
- checkList() {
234
- this.$nextTick(() => {
235
- let rows = this.sendTable.filter(
236
- (item, index) => item.pendstate == 2 && index == 0
237
- );
238
- rows.forEach((row) => {
239
- this.$refs.multipleTable.toggleRowSelection(row);
240
- });
241
- });
242
- },
243
- handleSelectionChange(val) {
244
- let ids = val.map((item) => {
245
- if (item.pendstate == 2) {
246
- return item.id;
247
- }
248
- });
249
- this.pendHistoryIds = ids.join(',');
250
- },
251
- getSendMsg() {
252
- this.loading = true;
253
- ajax({
254
- url: toSendMsg,
255
- params: { pendingId: this.$attrs.pendingId }
256
- })
257
- .then((res) => {
258
- const {
259
- status,
260
- message,
261
- data: {
262
- title,
263
- wfHistoryList,
264
- appId,
265
- notificationMessageReadOnly,
266
- readOnlyNotificationType
267
- }
268
- } = res;
269
- this.loading = false;
270
- if (status === 'success') {
271
- this.sendInfo.title = title;
272
- this.readOnlyNotificationType = readOnlyNotificationType;
273
- this.notificationMessageReadOnly =
274
- notificationMessageReadOnly == 'true';
275
- this.appId = appId;
276
- this.sendTable = wfHistoryList;
277
- this.checkList();
278
- } else {
279
- error(message || '系统错误,请联系管理员!');
280
- }
281
- })
282
- .catch((err) => {
283
- this.loading = false;
284
- });
285
- }
286
- }
287
- };
288
- </script>
289
-
290
- <style></style>