eoss-ui 0.6.54 → 0.6.56

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 (284) hide show
  1. package/lib/button-group.js +266 -212
  2. package/lib/button.js +403 -347
  3. package/lib/checkbox-group.js +273 -219
  4. package/lib/data-table-form.js +269 -215
  5. package/lib/data-table.js +277 -228
  6. package/lib/date-picker.js +403 -347
  7. package/lib/dialog.js +268 -219
  8. package/lib/enable-drag.js +8 -8
  9. package/lib/eoss-ui.common.js +1049 -894
  10. package/lib/flow-group.js +272 -216
  11. package/lib/flow-list.js +699 -626
  12. package/lib/flow.js +548 -499
  13. package/lib/form.js +274 -225
  14. package/lib/handle-user.js +503 -429
  15. package/lib/handler.js +272 -216
  16. package/lib/icon.js +272 -216
  17. package/lib/index.js +1 -1
  18. package/lib/input-number.js +403 -347
  19. package/lib/input.js +406 -350
  20. package/lib/login.js +273 -224
  21. package/lib/main.js +550 -431
  22. package/lib/menu.js +48 -12
  23. package/lib/nav.js +274 -218
  24. package/lib/page.js +272 -216
  25. package/lib/pagination.js +272 -216
  26. package/lib/player.js +494 -416
  27. package/lib/qr-code.js +285 -229
  28. package/lib/radio-group.js +279 -223
  29. package/lib/retrial-auth.js +272 -216
  30. package/lib/select-ganged.js +406 -350
  31. package/lib/select.js +410 -352
  32. package/lib/selector-panel.js +271 -217
  33. package/lib/selector.js +272 -216
  34. package/lib/sizer.js +269 -220
  35. package/lib/steps.js +277 -221
  36. package/lib/switch.js +272 -216
  37. package/lib/table-form.js +272 -216
  38. package/lib/tabs.js +272 -216
  39. package/lib/theme-chalk/index.css +1 -1
  40. package/lib/theme-chalk/main.css +1 -1
  41. package/lib/theme-chalk/simplicity.css +1 -1
  42. package/lib/tips.js +277 -221
  43. package/lib/tree-group.js +272 -216
  44. package/lib/tree.js +277 -221
  45. package/lib/upload.js +290 -233
  46. package/lib/utils/util.js +231 -182
  47. package/lib/wujie.js +272 -216
  48. package/lib/wxlogin.js +404 -348
  49. package/package.json +159 -159
  50. package/packages/.DS_Store +0 -0
  51. package/packages/button/index.js +5 -5
  52. package/packages/button/src/main.vue +418 -418
  53. package/packages/button-group/index.js +5 -5
  54. package/packages/button-group/src/main.vue +298 -298
  55. package/packages/calendar/index.js +5 -5
  56. package/packages/card/index.js +5 -5
  57. package/packages/card/src/main.vue +156 -156
  58. package/packages/cascader/index.js +5 -5
  59. package/packages/cascader/src/main.vue +168 -168
  60. package/packages/checkbox-group/index.js +5 -5
  61. package/packages/checkbox-group/src/main.vue +333 -333
  62. package/packages/clients/index.js +5 -5
  63. package/packages/clients/src/main.vue +144 -144
  64. package/packages/data-table/.DS_Store +0 -0
  65. package/packages/data-table/index.js +5 -5
  66. package/packages/data-table/src/children.vue +39 -39
  67. package/packages/data-table/src/column.vue +989 -989
  68. package/packages/data-table/src/main.vue +1822 -1822
  69. package/packages/data-table/src/sizer.vue +195 -195
  70. package/packages/data-table-form/.DS_Store +0 -0
  71. package/packages/data-table-form/index.js +5 -5
  72. package/packages/data-table-form/src/checkbox.vue +101 -101
  73. package/packages/data-table-form/src/colgroup.vue +17 -17
  74. package/packages/data-table-form/src/main.vue +181 -181
  75. package/packages/data-table-form/src/radio.vue +65 -65
  76. package/packages/data-table-form/src/table.vue +233 -233
  77. package/packages/data-table-form/src/tbody.vue +336 -336
  78. package/packages/data-table-form/src/thead.vue +68 -68
  79. package/packages/date-picker/index.js +5 -5
  80. package/packages/date-picker/src/main.vue +236 -236
  81. package/packages/dialog/index.js +5 -5
  82. package/packages/enable-drag/index.js +5 -5
  83. package/packages/enterprise/index.js +5 -5
  84. package/packages/enterprise/src/main.vue +66 -66
  85. package/packages/error-page/.DS_Store +0 -0
  86. package/packages/error-page/index.js +5 -5
  87. package/packages/error-page/src/main.vue +44 -44
  88. package/packages/flow/.DS_Store +0 -0
  89. package/packages/flow/index.js +5 -5
  90. package/packages/flow/src/component/CommonOpinions.vue +345 -345
  91. package/packages/flow/src/component/CustomPreset.vue +322 -322
  92. package/packages/flow/src/component/FileList.vue +99 -99
  93. package/packages/flow/src/component/Preset.vue +255 -255
  94. package/packages/flow/src/component/SendMsg.vue +229 -229
  95. package/packages/flow/src/component/TimeLimit.vue +190 -190
  96. package/packages/flow/src/component/taskUnionExamine.vue +611 -611
  97. package/packages/flow/src/form.vue +121 -121
  98. package/packages/flow/src/freeStartFlow.vue +2843 -2843
  99. package/packages/flow/src/main.vue +3131 -3131
  100. package/packages/flow/src/processForm.vue +1031 -1031
  101. package/packages/flow/src/processReject.vue +293 -293
  102. package/packages/flow/src/reset.vue +900 -900
  103. package/packages/flow/src/startTaskRead.vue +641 -641
  104. package/packages/flow/src/supervise.vue +138 -138
  105. package/packages/flow/src/table.vue +58 -58
  106. package/packages/flow-group/.DS_Store +0 -0
  107. package/packages/flow-group/index.js +5 -5
  108. package/packages/flow-group/src/main.vue +688 -688
  109. package/packages/flow-list/index.js +5 -5
  110. package/packages/flow-list/src/main.vue +1437 -1437
  111. package/packages/form/.DS_Store +0 -0
  112. package/packages/form/index.js +5 -5
  113. package/packages/form/src/main.vue +3583 -3583
  114. package/packages/form/src/table.vue +1426 -1426
  115. package/packages/handle-user/index.js +5 -5
  116. package/packages/handle-user/src/main.vue +138 -138
  117. package/packages/handler/.DS_Store +0 -0
  118. package/packages/handler/index.js +5 -5
  119. package/packages/handler/src/main.vue +493 -493
  120. package/packages/icon/index.js +5 -5
  121. package/packages/icon/src/main.vue +101 -101
  122. package/packages/icons/index.js +5 -5
  123. package/packages/icons/src/main.vue +81 -81
  124. package/packages/input/index.js +5 -5
  125. package/packages/input/src/main.vue +356 -356
  126. package/packages/input-number/index.js +5 -5
  127. package/packages/input-number/src/main.vue +106 -106
  128. package/packages/label/index.js +5 -5
  129. package/packages/label/src/main.vue +457 -457
  130. package/packages/layout/index.js +5 -5
  131. package/packages/layout/src/item.vue +152 -152
  132. package/packages/layout/src/main.vue +31 -31
  133. package/packages/login/.DS_Store +0 -0
  134. package/packages/login/index.js +5 -5
  135. package/packages/login/src/main.vue +1935 -1935
  136. package/packages/login/src/resetPassword.vue +562 -562
  137. package/packages/main/.DS_Store +0 -0
  138. package/packages/main/index.js +5 -5
  139. package/packages/main/src/.DS_Store +0 -0
  140. package/packages/main/src/default/message.vue +249 -249
  141. package/packages/main/src/default/notice.vue +157 -157
  142. package/packages/main/src/default/userinfo.vue +503 -503
  143. package/packages/main/src/public/online.vue +89 -89
  144. package/packages/main/src/public/search.vue +462 -466
  145. package/packages/main/src/public/settings.vue +221 -221
  146. package/packages/main/src/simplicity/apps.vue +388 -388
  147. package/packages/main/src/simplicity/avatar.vue +82 -82
  148. package/packages/main/src/simplicity/handler.vue +259 -259
  149. package/packages/main/src/simplicity/index.vue +2076 -2064
  150. package/packages/main/src/simplicity/lists.vue +84 -84
  151. package/packages/main/src/simplicity/menu-list.vue +135 -128
  152. package/packages/main/src/simplicity/message.vue +259 -259
  153. package/packages/main/src/simplicity/notice.vue +190 -190
  154. package/packages/main/src/simplicity/router-page.vue +45 -45
  155. package/packages/main/src/simplicity/sub-menu.vue +263 -241
  156. package/packages/main/src/simplicity/user.vue +257 -257
  157. package/packages/main/src/simplicity/userinfo.vue +312 -312
  158. package/packages/menu/index.js +5 -5
  159. package/packages/menu/src/main.vue +580 -536
  160. package/packages/nav/index.js +5 -5
  161. package/packages/nav/src/main.vue +351 -351
  162. package/packages/notify/index.js +5 -5
  163. package/packages/notify/src/main.vue +538 -538
  164. package/packages/page/index.js +5 -5
  165. package/packages/page/src/main.vue +167 -167
  166. package/packages/pagination/index.js +5 -5
  167. package/packages/pagination/src/main.vue +96 -96
  168. package/packages/player/index.js +5 -5
  169. package/packages/player/src/main.vue +194 -194
  170. package/packages/qr-code/index.js +5 -5
  171. package/packages/qr-code/src/main.vue +170 -170
  172. package/packages/radio-group/index.js +6 -6
  173. package/packages/radio-group/src/main.vue +319 -319
  174. package/packages/retrial-auth/.DS_Store +0 -0
  175. package/packages/retrial-auth/index.js +5 -5
  176. package/packages/retrial-auth/src/main.vue +280 -280
  177. package/packages/select/.DS_Store +0 -0
  178. package/packages/select/index.js +5 -5
  179. package/packages/select/src/main.vue +778 -776
  180. package/packages/select-ganged/index.js +5 -5
  181. package/packages/select-ganged/src/main.vue +724 -724
  182. package/packages/selector/.DS_Store +0 -0
  183. package/packages/selector/index.js +5 -5
  184. package/packages/selector/src/main.vue +687 -687
  185. package/packages/selector-panel/.DS_Store +0 -0
  186. package/packages/selector-panel/index.js +5 -5
  187. package/packages/selector-panel/src/main.vue +1027 -1027
  188. package/packages/selector-panel/src/selection.vue +177 -177
  189. package/packages/selector-panel/src/tree.vue +129 -129
  190. package/packages/sizer/.DS_Store +0 -0
  191. package/packages/sizer/index.js +5 -5
  192. package/packages/sizer/src/main.vue +254 -254
  193. package/packages/steps/index.js +5 -5
  194. package/packages/steps/src/main.vue +181 -181
  195. package/packages/switch/index.js +5 -5
  196. package/packages/switch/src/main.vue +154 -154
  197. package/packages/table-form/index.js +5 -5
  198. package/packages/tabs/.DS_Store +0 -0
  199. package/packages/tabs/index.js +5 -5
  200. package/packages/tabs/src/main.vue +788 -788
  201. package/packages/tabs-panel/index.js +5 -5
  202. package/packages/tabs-panel/src/main.vue +29 -29
  203. package/packages/theme-chalk/lib/index.css +1 -1
  204. package/packages/theme-chalk/lib/main.css +1 -1
  205. package/packages/theme-chalk/lib/simplicity.css +1 -1
  206. package/packages/theme-chalk/src/.DS_Store +0 -0
  207. package/packages/theme-chalk/src/base.scss +260 -260
  208. package/packages/theme-chalk/src/button-group.scss +175 -175
  209. package/packages/theme-chalk/src/button.scss +24 -24
  210. package/packages/theme-chalk/src/calendar.scss +113 -113
  211. package/packages/theme-chalk/src/card.scss +99 -99
  212. package/packages/theme-chalk/src/checkbox-group.scss +8 -8
  213. package/packages/theme-chalk/src/clients.scss +87 -87
  214. package/packages/theme-chalk/src/data-table-form.scss +67 -67
  215. package/packages/theme-chalk/src/data-table.scss +293 -293
  216. package/packages/theme-chalk/src/date-picker.scss +7 -7
  217. package/packages/theme-chalk/src/dialog.scss +77 -77
  218. package/packages/theme-chalk/src/enable-drag.scss +181 -181
  219. package/packages/theme-chalk/src/enterprise.scss +5 -5
  220. package/packages/theme-chalk/src/error-page.scss +18 -18
  221. package/packages/theme-chalk/src/flow-group.scss +110 -110
  222. package/packages/theme-chalk/src/flow-list.scss +36 -36
  223. package/packages/theme-chalk/src/flow.scss +336 -336
  224. package/packages/theme-chalk/src/form.scss +496 -496
  225. package/packages/theme-chalk/src/handle-user.scss +40 -40
  226. package/packages/theme-chalk/src/handler.scss +143 -143
  227. package/packages/theme-chalk/src/icon.scss +1789 -1789
  228. package/packages/theme-chalk/src/icons.scss +99 -99
  229. package/packages/theme-chalk/src/input.scss +9 -9
  230. package/packages/theme-chalk/src/label.scss +24 -24
  231. package/packages/theme-chalk/src/layout.scss +46 -46
  232. package/packages/theme-chalk/src/login.scss +969 -969
  233. package/packages/theme-chalk/src/main.scss +663 -663
  234. package/packages/theme-chalk/src/menu.scss +222 -222
  235. package/packages/theme-chalk/src/mixins/color.scss +117 -117
  236. package/packages/theme-chalk/src/nav.scss +111 -111
  237. package/packages/theme-chalk/src/page.scss +3 -3
  238. package/packages/theme-chalk/src/pagination.scss +29 -29
  239. package/packages/theme-chalk/src/player.scss +9 -9
  240. package/packages/theme-chalk/src/qr-code.scss +17 -17
  241. package/packages/theme-chalk/src/radio-group.scss +9 -9
  242. package/packages/theme-chalk/src/retrial-auth.scss +38 -38
  243. package/packages/theme-chalk/src/select-ganged.scss +8 -8
  244. package/packages/theme-chalk/src/select.scss +8 -8
  245. package/packages/theme-chalk/src/selector-panel.scss +204 -204
  246. package/packages/theme-chalk/src/selector.scss +91 -91
  247. package/packages/theme-chalk/src/simplicity.scss +1351 -1265
  248. package/packages/theme-chalk/src/sizer.scss +36 -36
  249. package/packages/theme-chalk/src/steps.scss +88 -88
  250. package/packages/theme-chalk/src/switch.scss +3 -3
  251. package/packages/theme-chalk/src/table-form.scss +1 -1
  252. package/packages/theme-chalk/src/tabs.scss +87 -87
  253. package/packages/theme-chalk/src/tips.scss +7 -7
  254. package/packages/theme-chalk/src/toolbar.scss +179 -179
  255. package/packages/theme-chalk/src/tree-group.scss +72 -72
  256. package/packages/theme-chalk/src/tree.scss +165 -165
  257. package/packages/theme-chalk/src/upload.scss +168 -168
  258. package/packages/theme-chalk/src/wxlogin.scss +3 -3
  259. package/packages/tips/index.js +5 -5
  260. package/packages/tips/src/main.vue +141 -141
  261. package/packages/toolbar/index.js +5 -5
  262. package/packages/toolbar/src/main.vue +430 -430
  263. package/packages/tree/index.js +5 -5
  264. package/packages/tree/src/main.vue +2 -2
  265. package/packages/tree-group/index.js +5 -5
  266. package/packages/upload/.DS_Store +0 -0
  267. package/packages/upload/index.js +5 -5
  268. package/packages/upload/src/main.vue +1347 -1343
  269. package/packages/upload/src/picture.js +15 -15
  270. package/packages/wujie/index.js +5 -5
  271. package/packages/wujie/src/main.vue +145 -145
  272. package/packages/wxlogin/index.js +5 -5
  273. package/packages/wxlogin/src/main.vue +128 -128
  274. package/src/.DS_Store +0 -0
  275. package/src/config/api.js +281 -281
  276. package/src/config/image.js +2 -2
  277. package/src/index.js +160 -160
  278. package/src/utils/bus.js +3 -3
  279. package/src/utils/date-util.js +312 -312
  280. package/src/utils/http.js +50 -50
  281. package/src/utils/rules.js +18 -18
  282. package/src/utils/store.js +21 -21
  283. package/src/utils/util.js +2 -2
  284. package/src/utils/webSocket.js +107 -107
@@ -1,611 +1,611 @@
1
- <template>
2
- <div class="es-flow-index task-union-examine" v-loading="loading">
3
- <el-form
4
- ref="infoList"
5
- :model="infoList"
6
- class="demo-dynamic"
7
- label-width="100px"
8
- >
9
- <el-form-item v-if="isSinglePage" prop="opinion" label="意见">
10
- <CommonOpinions @change="(val) => (opinion = val)" />
11
- </el-form-item>
12
- <el-form-item
13
- v-if="isHideCurrentOrg == 0"
14
- :prop="type != 'takeAdvice' ? 'nextOtherOrgObj' : 'nextCurrentOrgObj'"
15
- :label="
16
- type == 'takeAdvice'
17
- ? currentOrgName
18
- ? currentOrgName
19
- : '本单位'
20
- : type == 'startDraf'
21
- ? '呈送单位'
22
- : type === 'taskReview'
23
- ? '复核人'
24
- : type === 'twoOfficesDispatch'
25
- ? '报送单位'
26
- : '联合单位'
27
- "
28
- >
29
- <SelectUser
30
- :nextUser="
31
- type != 'takeAdvice'
32
- ? infoList.nextOtherOrgObj
33
- : infoList.nextCurrentOrgObj
34
- "
35
- :multiple="newMultiple"
36
- :mix="currentMix"
37
- @change="
38
- changeSelectUser(
39
- $event,
40
- type != 'takeAdvice' ? 'nextOtherOrgObj' : 'nextCurrentOrgObj'
41
- )
42
- "
43
- :types="
44
- type == 'takeAdvice'
45
- ? currentOrgTabs.length > 0
46
- ? currentOrgTabs
47
- : ['department', 'employee']
48
- : type == 'startDraf'
49
- ? ['enterprise', 'employee']
50
- : ['enterprise']
51
- "
52
- :params="params"
53
- :tabs="currentOrgTabsParam"
54
- :disabled="disabled"
55
- :onlyName="onlyName"
56
- />
57
- </el-form-item>
58
- <el-form-item
59
- prop="nextOtherOrgObj"
60
- v-if="isHideOtherOrg == 0 && type == 'takeAdvice'"
61
- :label="otherOrgName ? otherOrgName : '外单位'"
62
- >
63
- <SelectUser
64
- :nextUser="infoList.nextOtherOrgObj"
65
- :multiple="newMultiple"
66
- @change="changeSelectUser($event, 'nextOtherOrgObj')"
67
- :mix="otherMix"
68
- :types="
69
- foreignOrgTabs.length > 0
70
- ? foreignOrgTabs
71
- : isChoiceOtherOrgDept == 'true'
72
- ? ['enterprise', 'department']
73
- : ['enterprise']
74
- "
75
- :params="otherParams"
76
- :tabs="foreignOrgTabsParam"
77
- />
78
- </el-form-item>
79
- <el-form-item
80
- prop="noticeType"
81
- label="通知方式"
82
- :rules="[
83
- { required: false, message: `请选择通知方式`, trigger: 'blur' }
84
- ]"
85
- >
86
- <el-checkbox-group
87
- v-model="infoList.noticeType"
88
- style="display: contents"
89
- >
90
- <el-checkbox
91
- v-for="item of infoList.noticeList"
92
- :key="item.cciValue"
93
- :label="item.cciValue"
94
- :disabled="
95
- readOnlyNotificationType
96
- ? readOnlyNotificationType.indexOf(item.cciValue) != -1
97
- : false
98
- "
99
- >
100
- {{ item.shortName }}
101
- </el-checkbox>
102
- </el-checkbox-group>
103
- </el-form-item>
104
- <el-form-item
105
- v-show="infoList.noticeType.length != 0"
106
- prop="noticeInfo"
107
- label="通知消息"
108
- >
109
- <es-input
110
- style="
111
- border-color: #ccc;
112
- padding: 5px;
113
- border-radius: 5px;
114
- font-size: 13px;
115
- "
116
- type="textarea"
117
- v-model="infoList.noticeInfo"
118
- :readonly="notificationMessageReadOnly"
119
- />
120
- <!-- <span>{{ infoList.noticeInfo }}</span> -->
121
- </el-form-item>
122
- </el-form>
123
- <div style="text-align: right">
124
- <el-button type="primary" size="small" @click="subMit"> 确定 </el-button>
125
- <el-button @click="quit" size="small"> 取消 </el-button>
126
- </div>
127
- </div>
128
- </template>
129
-
130
- <script>
131
- import CommonOpinions from './CommonOpinions.vue';
132
- import SelectUser from '../selectUser.vue';
133
- import {
134
- findSysCodes,
135
- getNotificationMsg,
136
- toTaskTakeAdvice,
137
- findCodeValues,
138
- toTaskStartDraft,
139
- toTaskReview,
140
- taskStartDraft,
141
- toTaskUnionSeal,
142
- taskReview,
143
- toTwoOfficesDispatch,
144
- taskUnionSeal,
145
- twoOfficesDispatch,
146
- taskUnionExamine,
147
- taskTakeAdvice,
148
- toTaskUnionExamine
149
- } from 'eoss-ui/src/config/api';
150
- import util from 'eoss-ui/src/utils/util.js';
151
- export default {
152
- name: 'TaskUnionExamine',
153
- components: {
154
- [CommonOpinions.name]: CommonOpinions,
155
- [SelectUser.name]: SelectUser
156
- },
157
- props: {
158
- pendingId: { type: String, default: '' },
159
- type: { type: String, default: '' },
160
- defaultOpinion: { type: String, default: '' },
161
- disabled: { type: Boolean, default: false },
162
- multiple: { type: Boolean, default: true }
163
- },
164
- inheritAttrs: false,
165
- data() {
166
- return {
167
- opinion: '', //办理意见
168
- readOnlyNotificationType: '',
169
- notificationMessageReadOnly: false,
170
- otherMix: false,
171
- currentMix: false,
172
- infoList: {
173
- nextOtherOrgObj: [],
174
- nextCurrentOrgObj: [],
175
- noticeType: [],
176
- noticeInfo: '',
177
- opinion: ''
178
- },
179
- onlyName: '',
180
- currentOrgTabs: [],
181
- foreignOrgTabs: [],
182
- foreignOrgTabsParam: {},
183
- currentOrgTabsParam: {},
184
- currentOrgProcessKey: '',
185
- isSubFlow: true,
186
- choiceDeptId: '',
187
- choiceOrgId: '',
188
- isSinglePage: false,
189
- isChoiceOtherOrgDept: '',
190
- currentOrgName: '',
191
- otherOrgName: '',
192
- newMultiple: true,
193
- params: { filid: 'all' },
194
- isHideOtherOrg: '',
195
- isHideCurrentOrg: 0,
196
- isOpinionRequired: 0,
197
- otherParams: { filid: 'other' },
198
- loading: false
199
- };
200
- },
201
- mounted() {
202
- this.loading = true;
203
- this.newMultiple = this.multiple;
204
- this.getNodeType();
205
- if (this.type === 'taskReview') return this.getTaskReview();
206
- this.getInfo();
207
- },
208
- methods: {
209
- isMultiple(val) {
210
- if (val == 7 || val == 9 || val == 11) {
211
- this.newMultiple = false;
212
- }
213
- },
214
- subTaskReview() {
215
- let {
216
- infoList: { nextOtherOrgObj, noticeType, noticeInfo },
217
- businessId,
218
- opinion,
219
- isSubFlow,
220
- currentOrgProcessKey,
221
- pendingId
222
- } = this;
223
- let params = {
224
- url: taskReview,
225
- data: {
226
- nextUserId: nextOtherOrgObj.join(','),
227
- notificationType: noticeType.join(','),
228
- notificationMsg: noticeInfo,
229
- opinion,
230
- isSubFlow,
231
- businessId,
232
- currentOrgProcessKey,
233
- pendingId
234
- },
235
- method: 'POST'
236
- };
237
- this.loading = true;
238
- util
239
- .ajax(params)
240
- .then((res) => {
241
- const { message, status } = res;
242
- this.loading = false;
243
- if (status === 'success') {
244
- this.$message.success('提交成功');
245
- this.quit(true);
246
- } else {
247
- this.$message.error(message || '系统错误,请联系管理员!');
248
- }
249
- })
250
- .catch((err) => {
251
- this.loading = false;
252
- if (err.message && err.message !== 'canceled') {
253
- this.$message.error(err.message);
254
- }
255
- });
256
- },
257
- getTaskReview() {
258
- let params = {
259
- url: toTaskReview,
260
- params: { pendingId: this.pendingId }
261
- };
262
- util
263
- .ajax(params)
264
- .then((res) => {
265
- const { status, message } = res;
266
- this.loading = false;
267
- if (status === 'success') {
268
- const {
269
- data: { initiatorUser, taskExamine }
270
- } = res;
271
- this.opinion = taskExamine.opinion;
272
- this.infoList.nextOtherOrgObj.push(initiatorUser.userId);
273
- this.onlyName = initiatorUser.username;
274
- this.isSubFlow = taskExamine.isSubFlow;
275
- this.currentOrgProcessKey = taskExamine.currentOrgProcessKey;
276
- this.getFind();
277
- this.getMessage();
278
- } else {
279
- this.$message.error(message || '系统错误,请联系管理员!');
280
- }
281
- })
282
- .catch((err) => {
283
- this.loading = false;
284
- if (err.message && err.message !== 'canceled') {
285
- this.$message.error(err.message);
286
- }
287
- });
288
- },
289
- getInfo() {
290
- let params = {
291
- url:
292
- this.type == 'takeAdvice'
293
- ? toTaskTakeAdvice
294
- : this.type === 'startDraf'
295
- ? toTaskStartDraft
296
- : this.type == 'unionSeal'
297
- ? toTaskUnionSeal
298
- : this.type == 'twoOfficesDispatch'
299
- ? toTwoOfficesDispatch
300
- : toTaskUnionExamine,
301
- params: { pendingId: this.pendingId },
302
- headers: { Accept: 'application/json,text/plain' }
303
- };
304
- util
305
- .ajax(params)
306
- .then((res) => {
307
- const { message, status } = res;
308
- this.loading = false;
309
- if (status == 'success') {
310
- const {
311
- data: {
312
- choiceDeptId,
313
- choiceOrgId,
314
- taskExamine,
315
- unionDispatchOrgName,
316
- readOnlyNotificationType,
317
- notificationMessageReadOnly,
318
- unionDispatchOrgId,
319
- orgNames,
320
- nodeInfoMap: {
321
- nodeExtAttr: {
322
- userSelectionType,
323
- isHideOtherOrg,
324
- isHideCurrentOrg,
325
- isOpinionRequired
326
- }
327
- }
328
- }
329
- } = res;
330
- if (res.data.customizedConfig) {
331
- if (res.data.customizedConfig.currentOrgSelectorCustomized) {
332
- this.currentMix =
333
- res.data.customizedConfig.currentOrgSelectorSelectMix ==
334
- 'true';
335
- this.currentOrgTabs =
336
- res.data.customizedConfig.currentOrgSelectorItemList.split(
337
- ','
338
- );
339
- let param =
340
- res.data.customizedConfig.currentOrgSelectorRangeList.split(
341
- ','
342
- );
343
- this.currentOrgTabs.map((x, i) => {
344
- this.params[x] = {
345
- filid:
346
- param[i] == 'my'
347
- ? (this.params.filid = JSON.parse(
348
- sessionStorage.getItem('mainConfig')
349
- ).userModel.orgId)
350
- : param[i]
351
- };
352
- });
353
- } else {
354
- if (this.type == 'takeAdvice') {
355
- this.params.filid = JSON.parse(
356
- sessionStorage.getItem('mainConfig')
357
- ).userModel.orgId;
358
- }
359
- }
360
- if (res.data.customizedConfig.foreignOrgSelectorCustomized) {
361
- this.otherMix =
362
- res.data.customizedConfig.foreignOrgSelectorSelectMix ==
363
- 'true';
364
- this.foreignOrgTabs =
365
- res.data.customizedConfig.foreignOrgSelectorItemList.split(
366
- ','
367
- );
368
- let param =
369
- res.data.customizedConfig.foreignOrgSelectorRangeList.split(
370
- ','
371
- );
372
- this.foreignOrgTabs.map((x, i) => {
373
- this.otherParams[x] = { filid: param[i] };
374
- });
375
- }
376
- }
377
- this.readOnlyNotificationType = readOnlyNotificationType;
378
- this.notificationMessageReadOnly =
379
- notificationMessageReadOnly == 'true';
380
- this.isSinglePage = taskExamine.isSinglePage;
381
- this.isSubFlow = taskExamine.isSubFlow;
382
- this.opinion = taskExamine.opinion;
383
- this.choiceDeptId = choiceDeptId;
384
- this.choiceOrgId = choiceOrgId;
385
- if (this.type == 'takeAdvice' || this.type == 'startDraf') {
386
- this.currentOrgName = res.data.currentOrgName;
387
- this.otherOrgName = res.data.otherOrgName;
388
- this.isChoiceOtherOrgDept = res.data.isChoiceOtherOrgDept;
389
- this.isHideOtherOrg = isHideOtherOrg;
390
- this.isHideCurrentOrg = isHideCurrentOrg;
391
- }
392
- this.isOpinionRequired = isOpinionRequired;
393
- if (this.type == 'unionSeal') {
394
- this.onlyName = unionDispatchOrgName;
395
- this.infoList.nextOtherOrgObj.push(unionDispatchOrgId);
396
- }
397
- if (this.type == 'twoOfficesDispatch') {
398
- this.onlyName = orgNames;
399
- this.infoList.nextOtherOrgObj.push(taskExamine.nextOtherOrgObj);
400
- }
401
- this.isMultiple(userSelectionType);
402
- this.getFind();
403
- this.getMessage();
404
- } else {
405
- this.$message.error(message || '系统错误,请联系管理员!');
406
- }
407
- })
408
- .catch((err) => {
409
- this.loading = false;
410
- if (err.message && err.message !== 'canceled') {
411
- this.$message.error(err.message);
412
- }
413
- });
414
- },
415
- subMit() {
416
- // if (
417
- // this.infoList.nextOtherOrgObjName == '' ||
418
- // this.infoList.nextOtherOrgObjName.length == 0
419
- // )
420
- // return this.$message.warning('请选择联合单位');
421
- if (this.type === 'taskReview') return this.subTaskReview();
422
- let {
423
- infoList: {
424
- nextCurrentOrgObj,
425
- nextOtherOrgObj,
426
- noticeType,
427
- noticeInfo
428
- },
429
- isOpinionRequired,
430
- opinion,
431
- type,
432
- isHideOtherOrg,
433
- choiceDeptId,
434
- choiceOrgId,
435
- isHideCurrentOrg,
436
- isSubFlow,
437
- pendingId
438
- } = this;
439
- if (
440
- type == 'takeAdvice' &&
441
- !nextCurrentOrgObj &&
442
- isHideCurrentOrg == 0 &&
443
- isHideOtherOrg == 0 &&
444
- !nextOtherOrgObj
445
- ) {
446
- return this.$message.warning('请选择处理对象!');
447
- } else if (
448
- isHideCurrentOrg == 0 &&
449
- !nextOtherOrgObj &&
450
- !nextCurrentOrgObj
451
- ) {
452
- return this.$message.warning('请选择处理对象!');
453
- }
454
-
455
- if (isOpinionRequired == 1 && (opinion == '' || opinion == null)) {
456
- return this.$message.warning('当前步骤必须输入意见!');
457
- }
458
- // if (this.type != 'startDraf' && this.type != 'unionSeal' && this.type != 'twoOfficesDispatch')
459
- // return this.$message.warning('暂未开放,敬请期待!');
460
- const param = {
461
- url:
462
- this.type === 'startDraf'
463
- ? taskStartDraft
464
- : this.type == 'unionSeal'
465
- ? taskUnionSeal
466
- : this.type === 'twoOfficesDispatch'
467
- ? twoOfficesDispatch
468
- : this.type == 'takeAdvice'
469
- ? taskTakeAdvice
470
- : taskUnionExamine,
471
- data: {
472
- opinion,
473
- pendingId,
474
- nextOtherOrgObj: Array.isArray(nextOtherOrgObj)
475
- ? nextOtherOrgObj.join(',')
476
- : nextOtherOrgObj,
477
- nextCurrentOrgObj: Array.isArray(nextCurrentOrgObj)
478
- ? nextCurrentOrgObj.join(',')
479
- : nextCurrentOrgObj,
480
- notificationMsg: noticeInfo,
481
- notificationType: noticeType.join(','),
482
- choiceDeptId,
483
- isSubFlow,
484
- choiceOrgId
485
- },
486
- headers: { Accept: 'application/json,text/plain' },
487
- method: 'POST'
488
- };
489
- this.loading = true;
490
- util
491
- .ajax(param)
492
- .then((res) => {
493
- const { message, status } = res;
494
- this.loading = false;
495
- if (status == 'success') {
496
- this.$message.success('提交成功');
497
- this.quit(true);
498
- } else {
499
- this.$message.error(message || '系统错误,请联系管理员!');
500
- }
501
- })
502
- .catch((err) => {
503
- this.loading = false;
504
- if (err.message && err.message !== 'canceled') {
505
- this.$message.error(err.message);
506
- }
507
- });
508
- },
509
- quit(val) {
510
- if (val === true) return this.$emit('cancel', val);
511
- this.$emit('cancel');
512
- },
513
- changeSelectUser(val, type) {
514
- const { nextUser, options } = val;
515
- let newNextUser = [];
516
- let obj = {};
517
- options.map((item) => {
518
- if (obj[item.stype]) {
519
- obj[item.stype].push(item.id);
520
- } else {
521
- obj[item.stype] = [item.id];
522
- }
523
- // if (newNextUser) {
524
- // newNextUser += `,${item.stype}-${item.id}`;
525
- // } else {
526
- // newNextUser = `${item.stype}-${item.id}`;
527
- // }
528
- });
529
- for (let key in obj) {
530
- newNextUser.push(`${key}-${obj[key].join(',')}`);
531
- }
532
-
533
- this.infoList[type] = newNextUser.join('|');
534
- },
535
- getNodeType() {
536
- util
537
- .ajax({
538
- url: findCodeValues,
539
- params: {
540
- ccCode: 'notification_type',
541
- userId: util.getStorage('userId')
542
- }
543
- })
544
- .then((res) => {
545
- const { status, data } = res;
546
- this.loading = false;
547
- if (status === 'success') {
548
- this.infoList.noticeList = data;
549
- }
550
- })
551
- .catch((err) => {
552
- this.loading = false;
553
- if (err.message && err.message !== 'canceled') {
554
- this.$message.error(err.message);
555
- }
556
- });
557
- },
558
- //获取通知信息
559
- getMessage() {
560
- let params = {
561
- pendingId: this.pendingId
562
- };
563
- util
564
- .ajax({ url: getNotificationMsg, params, methods: 'post' })
565
- .then((res) => {
566
- if (res.status === 'success') {
567
- this.infoList.noticeInfo = res.message;
568
- }
569
- this.loading = false;
570
- })
571
- .catch((err) => {
572
- this.loading = false;
573
- if (err.message && err.message !== 'canceled') {
574
- this.$message.error(err.message);
575
- }
576
- });
577
- },
578
- getFind() {
579
- util
580
- .ajax({
581
- url: findSysCodes
582
- })
583
- .then((res) => {
584
- const { status, message } = res;
585
- if (status === 'success') {
586
- this.infoList.noticeType = message.split(',');
587
- let arr = [];
588
- this.infoList.noticeList.map((item) => {
589
- this.infoList.noticeType.map((x) => {
590
- if (x == item.cciValue) {
591
- arr.push(x);
592
- }
593
- });
594
- });
595
- this.infoList.noticeType = arr;
596
- } else {
597
- this.$message.error(message || '系统错误,请联系管理员!');
598
- }
599
- })
600
- .catch((err) => {
601
- this.loading = false;
602
- if (err.message && err.message !== 'canceled') {
603
- this.$message.error(err.message);
604
- }
605
- });
606
- }
607
- }
608
- };
609
- </script>
610
-
611
- <style></style>
1
+ <template>
2
+ <div class="es-flow-index task-union-examine" v-loading="loading">
3
+ <el-form
4
+ ref="infoList"
5
+ :model="infoList"
6
+ class="demo-dynamic"
7
+ label-width="100px"
8
+ >
9
+ <el-form-item v-if="isSinglePage" prop="opinion" label="意见">
10
+ <CommonOpinions @change="(val) => (opinion = val)" />
11
+ </el-form-item>
12
+ <el-form-item
13
+ v-if="isHideCurrentOrg == 0"
14
+ :prop="type != 'takeAdvice' ? 'nextOtherOrgObj' : 'nextCurrentOrgObj'"
15
+ :label="
16
+ type == 'takeAdvice'
17
+ ? currentOrgName
18
+ ? currentOrgName
19
+ : '本单位'
20
+ : type == 'startDraf'
21
+ ? '呈送单位'
22
+ : type === 'taskReview'
23
+ ? '复核人'
24
+ : type === 'twoOfficesDispatch'
25
+ ? '报送单位'
26
+ : '联合单位'
27
+ "
28
+ >
29
+ <SelectUser
30
+ :nextUser="
31
+ type != 'takeAdvice'
32
+ ? infoList.nextOtherOrgObj
33
+ : infoList.nextCurrentOrgObj
34
+ "
35
+ :multiple="newMultiple"
36
+ :mix="currentMix"
37
+ @change="
38
+ changeSelectUser(
39
+ $event,
40
+ type != 'takeAdvice' ? 'nextOtherOrgObj' : 'nextCurrentOrgObj'
41
+ )
42
+ "
43
+ :types="
44
+ type == 'takeAdvice'
45
+ ? currentOrgTabs.length > 0
46
+ ? currentOrgTabs
47
+ : ['department', 'employee']
48
+ : type == 'startDraf'
49
+ ? ['enterprise', 'employee']
50
+ : ['enterprise']
51
+ "
52
+ :params="params"
53
+ :tabs="currentOrgTabsParam"
54
+ :disabled="disabled"
55
+ :onlyName="onlyName"
56
+ />
57
+ </el-form-item>
58
+ <el-form-item
59
+ prop="nextOtherOrgObj"
60
+ v-if="isHideOtherOrg == 0 && type == 'takeAdvice'"
61
+ :label="otherOrgName ? otherOrgName : '外单位'"
62
+ >
63
+ <SelectUser
64
+ :nextUser="infoList.nextOtherOrgObj"
65
+ :multiple="newMultiple"
66
+ @change="changeSelectUser($event, 'nextOtherOrgObj')"
67
+ :mix="otherMix"
68
+ :types="
69
+ foreignOrgTabs.length > 0
70
+ ? foreignOrgTabs
71
+ : isChoiceOtherOrgDept == 'true'
72
+ ? ['enterprise', 'department']
73
+ : ['enterprise']
74
+ "
75
+ :params="otherParams"
76
+ :tabs="foreignOrgTabsParam"
77
+ />
78
+ </el-form-item>
79
+ <el-form-item
80
+ prop="noticeType"
81
+ label="通知方式"
82
+ :rules="[
83
+ { required: false, message: `请选择通知方式`, trigger: 'blur' }
84
+ ]"
85
+ >
86
+ <el-checkbox-group
87
+ v-model="infoList.noticeType"
88
+ style="display: contents"
89
+ >
90
+ <el-checkbox
91
+ v-for="item of infoList.noticeList"
92
+ :key="item.cciValue"
93
+ :label="item.cciValue"
94
+ :disabled="
95
+ readOnlyNotificationType
96
+ ? readOnlyNotificationType.indexOf(item.cciValue) != -1
97
+ : false
98
+ "
99
+ >
100
+ {{ item.shortName }}
101
+ </el-checkbox>
102
+ </el-checkbox-group>
103
+ </el-form-item>
104
+ <el-form-item
105
+ v-show="infoList.noticeType.length != 0"
106
+ prop="noticeInfo"
107
+ label="通知消息"
108
+ >
109
+ <es-input
110
+ style="
111
+ border-color: #ccc;
112
+ padding: 5px;
113
+ border-radius: 5px;
114
+ font-size: 13px;
115
+ "
116
+ type="textarea"
117
+ v-model="infoList.noticeInfo"
118
+ :readonly="notificationMessageReadOnly"
119
+ />
120
+ <!-- <span>{{ infoList.noticeInfo }}</span> -->
121
+ </el-form-item>
122
+ </el-form>
123
+ <div style="text-align: right">
124
+ <el-button type="primary" size="small" @click="subMit"> 确定 </el-button>
125
+ <el-button @click="quit" size="small"> 取消 </el-button>
126
+ </div>
127
+ </div>
128
+ </template>
129
+
130
+ <script>
131
+ import CommonOpinions from './CommonOpinions.vue';
132
+ import SelectUser from '../selectUser.vue';
133
+ import {
134
+ findSysCodes,
135
+ getNotificationMsg,
136
+ toTaskTakeAdvice,
137
+ findCodeValues,
138
+ toTaskStartDraft,
139
+ toTaskReview,
140
+ taskStartDraft,
141
+ toTaskUnionSeal,
142
+ taskReview,
143
+ toTwoOfficesDispatch,
144
+ taskUnionSeal,
145
+ twoOfficesDispatch,
146
+ taskUnionExamine,
147
+ taskTakeAdvice,
148
+ toTaskUnionExamine
149
+ } from 'eoss-ui/src/config/api';
150
+ import util from 'eoss-ui/src/utils/util.js';
151
+ export default {
152
+ name: 'TaskUnionExamine',
153
+ components: {
154
+ [CommonOpinions.name]: CommonOpinions,
155
+ [SelectUser.name]: SelectUser
156
+ },
157
+ props: {
158
+ pendingId: { type: String, default: '' },
159
+ type: { type: String, default: '' },
160
+ defaultOpinion: { type: String, default: '' },
161
+ disabled: { type: Boolean, default: false },
162
+ multiple: { type: Boolean, default: true }
163
+ },
164
+ inheritAttrs: false,
165
+ data() {
166
+ return {
167
+ opinion: '', //办理意见
168
+ readOnlyNotificationType: '',
169
+ notificationMessageReadOnly: false,
170
+ otherMix: false,
171
+ currentMix: false,
172
+ infoList: {
173
+ nextOtherOrgObj: [],
174
+ nextCurrentOrgObj: [],
175
+ noticeType: [],
176
+ noticeInfo: '',
177
+ opinion: ''
178
+ },
179
+ onlyName: '',
180
+ currentOrgTabs: [],
181
+ foreignOrgTabs: [],
182
+ foreignOrgTabsParam: {},
183
+ currentOrgTabsParam: {},
184
+ currentOrgProcessKey: '',
185
+ isSubFlow: true,
186
+ choiceDeptId: '',
187
+ choiceOrgId: '',
188
+ isSinglePage: false,
189
+ isChoiceOtherOrgDept: '',
190
+ currentOrgName: '',
191
+ otherOrgName: '',
192
+ newMultiple: true,
193
+ params: { filid: 'all' },
194
+ isHideOtherOrg: '',
195
+ isHideCurrentOrg: 0,
196
+ isOpinionRequired: 0,
197
+ otherParams: { filid: 'other' },
198
+ loading: false
199
+ };
200
+ },
201
+ mounted() {
202
+ this.loading = true;
203
+ this.newMultiple = this.multiple;
204
+ this.getNodeType();
205
+ if (this.type === 'taskReview') return this.getTaskReview();
206
+ this.getInfo();
207
+ },
208
+ methods: {
209
+ isMultiple(val) {
210
+ if (val == 7 || val == 9 || val == 11) {
211
+ this.newMultiple = false;
212
+ }
213
+ },
214
+ subTaskReview() {
215
+ let {
216
+ infoList: { nextOtherOrgObj, noticeType, noticeInfo },
217
+ businessId,
218
+ opinion,
219
+ isSubFlow,
220
+ currentOrgProcessKey,
221
+ pendingId
222
+ } = this;
223
+ let params = {
224
+ url: taskReview,
225
+ data: {
226
+ nextUserId: nextOtherOrgObj.join(','),
227
+ notificationType: noticeType.join(','),
228
+ notificationMsg: noticeInfo,
229
+ opinion,
230
+ isSubFlow,
231
+ businessId,
232
+ currentOrgProcessKey,
233
+ pendingId
234
+ },
235
+ method: 'POST'
236
+ };
237
+ this.loading = true;
238
+ util
239
+ .ajax(params)
240
+ .then((res) => {
241
+ const { message, status } = res;
242
+ this.loading = false;
243
+ if (status === 'success') {
244
+ this.$message.success('提交成功');
245
+ this.quit(true);
246
+ } else {
247
+ this.$message.error(message || '系统错误,请联系管理员!');
248
+ }
249
+ })
250
+ .catch((err) => {
251
+ this.loading = false;
252
+ if (err.message && err.message !== 'canceled') {
253
+ this.$message.error(err.message);
254
+ }
255
+ });
256
+ },
257
+ getTaskReview() {
258
+ let params = {
259
+ url: toTaskReview,
260
+ params: { pendingId: this.pendingId }
261
+ };
262
+ util
263
+ .ajax(params)
264
+ .then((res) => {
265
+ const { status, message } = res;
266
+ this.loading = false;
267
+ if (status === 'success') {
268
+ const {
269
+ data: { initiatorUser, taskExamine }
270
+ } = res;
271
+ this.opinion = taskExamine.opinion;
272
+ this.infoList.nextOtherOrgObj.push(initiatorUser.userId);
273
+ this.onlyName = initiatorUser.username;
274
+ this.isSubFlow = taskExamine.isSubFlow;
275
+ this.currentOrgProcessKey = taskExamine.currentOrgProcessKey;
276
+ this.getFind();
277
+ this.getMessage();
278
+ } else {
279
+ this.$message.error(message || '系统错误,请联系管理员!');
280
+ }
281
+ })
282
+ .catch((err) => {
283
+ this.loading = false;
284
+ if (err.message && err.message !== 'canceled') {
285
+ this.$message.error(err.message);
286
+ }
287
+ });
288
+ },
289
+ getInfo() {
290
+ let params = {
291
+ url:
292
+ this.type == 'takeAdvice'
293
+ ? toTaskTakeAdvice
294
+ : this.type === 'startDraf'
295
+ ? toTaskStartDraft
296
+ : this.type == 'unionSeal'
297
+ ? toTaskUnionSeal
298
+ : this.type == 'twoOfficesDispatch'
299
+ ? toTwoOfficesDispatch
300
+ : toTaskUnionExamine,
301
+ params: { pendingId: this.pendingId },
302
+ headers: { Accept: 'application/json,text/plain' }
303
+ };
304
+ util
305
+ .ajax(params)
306
+ .then((res) => {
307
+ const { message, status } = res;
308
+ this.loading = false;
309
+ if (status == 'success') {
310
+ const {
311
+ data: {
312
+ choiceDeptId,
313
+ choiceOrgId,
314
+ taskExamine,
315
+ unionDispatchOrgName,
316
+ readOnlyNotificationType,
317
+ notificationMessageReadOnly,
318
+ unionDispatchOrgId,
319
+ orgNames,
320
+ nodeInfoMap: {
321
+ nodeExtAttr: {
322
+ userSelectionType,
323
+ isHideOtherOrg,
324
+ isHideCurrentOrg,
325
+ isOpinionRequired
326
+ }
327
+ }
328
+ }
329
+ } = res;
330
+ if (res.data.customizedConfig) {
331
+ if (res.data.customizedConfig.currentOrgSelectorCustomized) {
332
+ this.currentMix =
333
+ res.data.customizedConfig.currentOrgSelectorSelectMix ==
334
+ 'true';
335
+ this.currentOrgTabs =
336
+ res.data.customizedConfig.currentOrgSelectorItemList.split(
337
+ ','
338
+ );
339
+ let param =
340
+ res.data.customizedConfig.currentOrgSelectorRangeList.split(
341
+ ','
342
+ );
343
+ this.currentOrgTabs.map((x, i) => {
344
+ this.params[x] = {
345
+ filid:
346
+ param[i] == 'my'
347
+ ? (this.params.filid = JSON.parse(
348
+ sessionStorage.getItem('mainConfig')
349
+ ).userModel.orgId)
350
+ : param[i]
351
+ };
352
+ });
353
+ } else {
354
+ if (this.type == 'takeAdvice') {
355
+ this.params.filid = JSON.parse(
356
+ sessionStorage.getItem('mainConfig')
357
+ ).userModel.orgId;
358
+ }
359
+ }
360
+ if (res.data.customizedConfig.foreignOrgSelectorCustomized) {
361
+ this.otherMix =
362
+ res.data.customizedConfig.foreignOrgSelectorSelectMix ==
363
+ 'true';
364
+ this.foreignOrgTabs =
365
+ res.data.customizedConfig.foreignOrgSelectorItemList.split(
366
+ ','
367
+ );
368
+ let param =
369
+ res.data.customizedConfig.foreignOrgSelectorRangeList.split(
370
+ ','
371
+ );
372
+ this.foreignOrgTabs.map((x, i) => {
373
+ this.otherParams[x] = { filid: param[i] };
374
+ });
375
+ }
376
+ }
377
+ this.readOnlyNotificationType = readOnlyNotificationType;
378
+ this.notificationMessageReadOnly =
379
+ notificationMessageReadOnly == 'true';
380
+ this.isSinglePage = taskExamine.isSinglePage;
381
+ this.isSubFlow = taskExamine.isSubFlow;
382
+ this.opinion = taskExamine.opinion;
383
+ this.choiceDeptId = choiceDeptId;
384
+ this.choiceOrgId = choiceOrgId;
385
+ if (this.type == 'takeAdvice' || this.type == 'startDraf') {
386
+ this.currentOrgName = res.data.currentOrgName;
387
+ this.otherOrgName = res.data.otherOrgName;
388
+ this.isChoiceOtherOrgDept = res.data.isChoiceOtherOrgDept;
389
+ this.isHideOtherOrg = isHideOtherOrg;
390
+ this.isHideCurrentOrg = isHideCurrentOrg;
391
+ }
392
+ this.isOpinionRequired = isOpinionRequired;
393
+ if (this.type == 'unionSeal') {
394
+ this.onlyName = unionDispatchOrgName;
395
+ this.infoList.nextOtherOrgObj.push(unionDispatchOrgId);
396
+ }
397
+ if (this.type == 'twoOfficesDispatch') {
398
+ this.onlyName = orgNames;
399
+ this.infoList.nextOtherOrgObj.push(taskExamine.nextOtherOrgObj);
400
+ }
401
+ this.isMultiple(userSelectionType);
402
+ this.getFind();
403
+ this.getMessage();
404
+ } else {
405
+ this.$message.error(message || '系统错误,请联系管理员!');
406
+ }
407
+ })
408
+ .catch((err) => {
409
+ this.loading = false;
410
+ if (err.message && err.message !== 'canceled') {
411
+ this.$message.error(err.message);
412
+ }
413
+ });
414
+ },
415
+ subMit() {
416
+ // if (
417
+ // this.infoList.nextOtherOrgObjName == '' ||
418
+ // this.infoList.nextOtherOrgObjName.length == 0
419
+ // )
420
+ // return this.$message.warning('请选择联合单位');
421
+ if (this.type === 'taskReview') return this.subTaskReview();
422
+ let {
423
+ infoList: {
424
+ nextCurrentOrgObj,
425
+ nextOtherOrgObj,
426
+ noticeType,
427
+ noticeInfo
428
+ },
429
+ isOpinionRequired,
430
+ opinion,
431
+ type,
432
+ isHideOtherOrg,
433
+ choiceDeptId,
434
+ choiceOrgId,
435
+ isHideCurrentOrg,
436
+ isSubFlow,
437
+ pendingId
438
+ } = this;
439
+ if (
440
+ type == 'takeAdvice' &&
441
+ !nextCurrentOrgObj &&
442
+ isHideCurrentOrg == 0 &&
443
+ isHideOtherOrg == 0 &&
444
+ !nextOtherOrgObj
445
+ ) {
446
+ return this.$message.warning('请选择处理对象!');
447
+ } else if (
448
+ isHideCurrentOrg == 0 &&
449
+ !nextOtherOrgObj &&
450
+ !nextCurrentOrgObj
451
+ ) {
452
+ return this.$message.warning('请选择处理对象!');
453
+ }
454
+
455
+ if (isOpinionRequired == 1 && (opinion == '' || opinion == null)) {
456
+ return this.$message.warning('当前步骤必须输入意见!');
457
+ }
458
+ // if (this.type != 'startDraf' && this.type != 'unionSeal' && this.type != 'twoOfficesDispatch')
459
+ // return this.$message.warning('暂未开放,敬请期待!');
460
+ const param = {
461
+ url:
462
+ this.type === 'startDraf'
463
+ ? taskStartDraft
464
+ : this.type == 'unionSeal'
465
+ ? taskUnionSeal
466
+ : this.type === 'twoOfficesDispatch'
467
+ ? twoOfficesDispatch
468
+ : this.type == 'takeAdvice'
469
+ ? taskTakeAdvice
470
+ : taskUnionExamine,
471
+ data: {
472
+ opinion,
473
+ pendingId,
474
+ nextOtherOrgObj: Array.isArray(nextOtherOrgObj)
475
+ ? nextOtherOrgObj.join(',')
476
+ : nextOtherOrgObj,
477
+ nextCurrentOrgObj: Array.isArray(nextCurrentOrgObj)
478
+ ? nextCurrentOrgObj.join(',')
479
+ : nextCurrentOrgObj,
480
+ notificationMsg: noticeInfo,
481
+ notificationType: noticeType.join(','),
482
+ choiceDeptId,
483
+ isSubFlow,
484
+ choiceOrgId
485
+ },
486
+ headers: { Accept: 'application/json,text/plain' },
487
+ method: 'POST'
488
+ };
489
+ this.loading = true;
490
+ util
491
+ .ajax(param)
492
+ .then((res) => {
493
+ const { message, status } = res;
494
+ this.loading = false;
495
+ if (status == 'success') {
496
+ this.$message.success('提交成功');
497
+ this.quit(true);
498
+ } else {
499
+ this.$message.error(message || '系统错误,请联系管理员!');
500
+ }
501
+ })
502
+ .catch((err) => {
503
+ this.loading = false;
504
+ if (err.message && err.message !== 'canceled') {
505
+ this.$message.error(err.message);
506
+ }
507
+ });
508
+ },
509
+ quit(val) {
510
+ if (val === true) return this.$emit('cancel', val);
511
+ this.$emit('cancel');
512
+ },
513
+ changeSelectUser(val, type) {
514
+ const { nextUser, options } = val;
515
+ let newNextUser = [];
516
+ let obj = {};
517
+ options.map((item) => {
518
+ if (obj[item.stype]) {
519
+ obj[item.stype].push(item.id);
520
+ } else {
521
+ obj[item.stype] = [item.id];
522
+ }
523
+ // if (newNextUser) {
524
+ // newNextUser += `,${item.stype}-${item.id}`;
525
+ // } else {
526
+ // newNextUser = `${item.stype}-${item.id}`;
527
+ // }
528
+ });
529
+ for (let key in obj) {
530
+ newNextUser.push(`${key}-${obj[key].join(',')}`);
531
+ }
532
+
533
+ this.infoList[type] = newNextUser.join('|');
534
+ },
535
+ getNodeType() {
536
+ util
537
+ .ajax({
538
+ url: findCodeValues,
539
+ params: {
540
+ ccCode: 'notification_type',
541
+ userId: util.getStorage('userId')
542
+ }
543
+ })
544
+ .then((res) => {
545
+ const { status, data } = res;
546
+ this.loading = false;
547
+ if (status === 'success') {
548
+ this.infoList.noticeList = data;
549
+ }
550
+ })
551
+ .catch((err) => {
552
+ this.loading = false;
553
+ if (err.message && err.message !== 'canceled') {
554
+ this.$message.error(err.message);
555
+ }
556
+ });
557
+ },
558
+ //获取通知信息
559
+ getMessage() {
560
+ let params = {
561
+ pendingId: this.pendingId
562
+ };
563
+ util
564
+ .ajax({ url: getNotificationMsg, params, methods: 'post' })
565
+ .then((res) => {
566
+ if (res.status === 'success') {
567
+ this.infoList.noticeInfo = res.message;
568
+ }
569
+ this.loading = false;
570
+ })
571
+ .catch((err) => {
572
+ this.loading = false;
573
+ if (err.message && err.message !== 'canceled') {
574
+ this.$message.error(err.message);
575
+ }
576
+ });
577
+ },
578
+ getFind() {
579
+ util
580
+ .ajax({
581
+ url: findSysCodes
582
+ })
583
+ .then((res) => {
584
+ const { status, message } = res;
585
+ if (status === 'success') {
586
+ this.infoList.noticeType = message.split(',');
587
+ let arr = [];
588
+ this.infoList.noticeList.map((item) => {
589
+ this.infoList.noticeType.map((x) => {
590
+ if (x == item.cciValue) {
591
+ arr.push(x);
592
+ }
593
+ });
594
+ });
595
+ this.infoList.noticeType = arr;
596
+ } else {
597
+ this.$message.error(message || '系统错误,请联系管理员!');
598
+ }
599
+ })
600
+ .catch((err) => {
601
+ this.loading = false;
602
+ if (err.message && err.message !== 'canceled') {
603
+ this.$message.error(err.message);
604
+ }
605
+ });
606
+ }
607
+ }
608
+ };
609
+ </script>
610
+
611
+ <style></style>