@zscreate/zhxy-app-component 1.0.397 → 1.0.400
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,1852 +1,1925 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<view class="evan-form-show" >
|
|
3
|
-
<evan-form :hide-required-asterisk="hideRequiredAsterisk" ref="Form" :dataObj="dataObj">
|
|
4
|
-
<template v-for="(item, index) in data.list">
|
|
5
|
-
<template v-if="item.type === 'table' && item.options.canView">
|
|
6
|
-
<view class="table-wrapper" :key="index">
|
|
7
|
-
<view class="table-header">
|
|
8
|
-
<text v-if="item.name" class="title-block"></text>
|
|
9
|
-
<text>{{ item.name }}</text>
|
|
10
|
-
</view>
|
|
11
|
-
<view class="table-container">
|
|
12
|
-
<template v-if="item.options.supportPage">
|
|
13
|
-
<view class="table-item" v-for="(table, tableCIndex) in currTablePageData(item)"
|
|
14
|
-
:key="tablePageIndex(item.model,tableCIndex)"
|
|
15
|
-
:index="tablePageIndex(item.model,tableCIndex)"
|
|
16
|
-
>
|
|
17
|
-
<view class="item" v-show="!item.options.hiddenOperateBtn">
|
|
18
|
-
<view class="index">{{table.index + 1}}</view>
|
|
19
|
-
<view class="delete icon-delete" v-if="!item.options.disabled&&!item.options.hiddenOperateBtn"
|
|
20
|
-
@click="handleDeleteRow(tablePageIndex(item.model,tableCIndex), item.model)">删除</view>
|
|
21
|
-
<view class="extend"
|
|
22
|
-
:class="{'icon-arrow-right': !tableRowsShow[item.model][tablePageIndex(item.model,tableCIndex)], 'icon-arrow-down':tableRowsShow[item.model][tablePageIndex(item.model,tableCIndex)]}"
|
|
23
|
-
@click="showTableRow(item.model, tablePageIndex(item.model,tableCIndex))">
|
|
24
|
-
{{tableRowsShow[item.model][tablePageIndex(item.model,tableCIndex)] ? '收起' : '展开'}}
|
|
25
|
-
</view>
|
|
26
|
-
</view>
|
|
27
|
-
<view class="view-port" v-show="tableRowsShow[item.model][tablePageIndex(item.model,tableCIndex)]" style="border-bottom: 1px solid #b2b2b2;">
|
|
28
|
-
<view v-for="(tableItem, tableItemIndex) in table.columns" :key="tableItemIndex" :class="'table-item-view' + (tableItemIndex % 3)">
|
|
29
|
-
<evan-form-item v-show="tableItem.options.canView"
|
|
30
|
-
:labelPosition="labelPosition"
|
|
31
|
-
@upDateWidget="data => upDateTableWidget(data, tableItemIndex, item.model, tablePageIndex(item.model,tableCIndex))" :itemkey="tableItemIndex"
|
|
32
|
-
:curLoadedPages="(tablePageInfo[item.model].current - 1) * tablePageInfo[item.model].pageSize + tablePageInfo[item.model].pageSize"
|
|
33
|
-
:parentTableKey="item.key" :tableKey="item.model" :tableIndex="tablePageIndex(item.model,tableCIndex)" :prop="tableItem.model"
|
|
34
|
-
:ref="String(Math.random()).split('.')[1]" :models.sync="models"
|
|
35
|
-
:rules="rules" :widget.sync="tableItem" :isDraft="isDraft" :formId="formId"
|
|
36
|
-
:linkage="linkage" :isApply="isApply" :applyId="applyId">
|
|
37
|
-
</evan-form-item>
|
|
38
|
-
</view>
|
|
39
|
-
</view>
|
|
40
|
-
</view>
|
|
41
|
-
<!-- #ifdef H5 -->
|
|
42
|
-
<page-pagination v-if="tablePageInfo[item.model]&&tablePageInfo[item.model].total" :total="tablePageInfo[item.model]&&tablePageInfo[item.model].total"
|
|
43
|
-
:currentPage="tablePageInfo[item.model]&&tablePageInfo[item.model].current"
|
|
44
|
-
@change="(...args) => tablePageChange(item,...args)"
|
|
45
|
-
:numAround="true" :showBorder="false"></page-pagination>
|
|
46
|
-
<!-- #endif -->
|
|
47
|
-
<!-- #ifdef MP-WEIXIN -->
|
|
48
|
-
<page-pagination v-if="tablePageInfo[item.model]&&tablePageInfo[item.model].total" :total="tablePageInfo[item.model]&&tablePageInfo[item.model].total"
|
|
49
|
-
:currentPage="tablePageInfo[item.model]&&tablePageInfo[item.model].current"
|
|
50
|
-
@change="tablePageChange(item, $event)"
|
|
51
|
-
:numAround="true" :showBorder="false"></page-pagination>
|
|
52
|
-
<!-- #endif -->
|
|
53
|
-
</template>
|
|
54
|
-
<template v-else>
|
|
55
|
-
<view class="table-item" v-for="(table, tableCIndex) in tableData[item.model]"
|
|
56
|
-
:key="tableCIndex">
|
|
57
|
-
<view class="item" v-show="!item.options.hiddenOperateBtn">
|
|
58
|
-
<view class="index">{{table.index + 1}}</view>
|
|
59
|
-
<view class="delete icon-delete" v-if="!item.options.disabled&&!item.options.hiddenOperateBtn"
|
|
60
|
-
@click="handleDeleteRow(tableCIndex, item.model)">删除</view>
|
|
61
|
-
<view class="extend"
|
|
62
|
-
:class="{'icon-arrow-right': !tableRowsShow[item.model][tableCIndex], 'icon-arrow-down':tableRowsShow[item.model][tableCIndex]}"
|
|
63
|
-
@click="showTableRow(item.model, tableCIndex)">
|
|
64
|
-
</view>
|
|
65
|
-
</view>
|
|
66
|
-
<view class="view-port" v-show="tableRowsShow[item.model][tableCIndex]" style="border-bottom: 1px solid #b2b2b2;">
|
|
67
|
-
<view v-for="(tableItem, tableItemIndex) in table.columns" :key="tableItemIndex" :class="'table-item-view' + (tableItemIndex % 3)">
|
|
68
|
-
<evan-form-item v-show="tableItem.options.canView"
|
|
69
|
-
:labelPosition="labelPosition"
|
|
70
|
-
@upDateWidget="data => upDateTableWidget(data, tableItemIndex, item.model, tableCIndex)" :itemkey="tableItemIndex"
|
|
71
|
-
:tableKey="item.model" :tableIndex="tableCIndex" :prop="tableItem.model"
|
|
72
|
-
:ref="String(Math.random()).split('.')[1]" :models.sync="models"
|
|
73
|
-
:rules="rules" :widget.sync="tableItem" :isDraft="isDraft" :formId="formId"
|
|
74
|
-
:linkage="linkage" :isApply="isApply" :applyId="applyId">
|
|
75
|
-
</evan-form-item>
|
|
76
|
-
</view>
|
|
77
|
-
</view>
|
|
78
|
-
</view>
|
|
79
|
-
</template>
|
|
80
|
-
<view class="add" v-if="isShowAdd && !item.options.disabled&&!item.options.hiddenOperateBtn" :data-data="item"
|
|
81
|
-
:data-model="item.model" data-add-model="addModel"
|
|
82
|
-
@click="addToTableData(item, item.model,'addModel')">+添加</view>
|
|
83
|
-
</view>
|
|
84
|
-
</view>
|
|
85
|
-
</template>
|
|
86
|
-
|
|
87
|
-
<view v-else-if="item.type === 'all-lay-out'" v-show="item.options.canView" class="form_layout">
|
|
88
|
-
<view v-for="(colItem, colIndex) in item.columns" :key="colIndex" class="form-item-container">
|
|
89
|
-
<view v-for="(col, itemIndex) in colItem.list" :key="itemIndex" v-show="col.options.canView">
|
|
90
|
-
<evan-form-item :isCorrect="isCorrect" :labelPosition="labelPosition" :prop="col.model"
|
|
91
|
-
:ref="String(Math.random()).split('.')[1]" :models.sync="models" :rules="rules"
|
|
92
|
-
:widget.sync="col" :isDraft="isDraft" :formId="formId" :linkage="linkage" :isApply="isApply" :applyId="applyId">
|
|
93
|
-
</evan-form-item>
|
|
94
|
-
</view>
|
|
95
|
-
</view>
|
|
96
|
-
</view>
|
|
97
|
-
|
|
98
|
-
<view v-else-if="item.type === 'grid-lay-out'" v-show="item.options.canView" class="form_layout">
|
|
99
|
-
<view v-for="(colItem, colIndex) in item.columns" :key="colIndex" class="form-item-container ">
|
|
100
|
-
<view v-for="(col, itemIndex) in colItem.list" :key="itemIndex" v-show="col.options.canView">
|
|
101
|
-
<template v-if="['hnkj-confirm', 'hnkj-verify'].includes(col.type) && item.options.canView">
|
|
102
|
-
<view class="verify">
|
|
103
|
-
<view class="verify-step">
|
|
104
|
-
<text v-if="col.name" class="title-block"></text>
|
|
105
|
-
<text>{{col.name }}</text>
|
|
106
|
-
|
|
107
|
-
</view>
|
|
108
|
-
<view class="verify-cot">
|
|
109
|
-
<m-textarea
|
|
110
|
-
:value="models[col.model].comments"
|
|
111
|
-
show-word-limit
|
|
112
|
-
:max-length="col.options.commentsLength"
|
|
113
|
-
:disabled="col.model !== verifyNode" :placeholder="col.options.placeholder"
|
|
114
|
-
@change="val => handlerText(val, col.model)">
|
|
115
|
-
</m-textarea>
|
|
116
|
-
</view>
|
|
117
|
-
<view v-if="col.model == verifyNode" class="verify-cot">
|
|
118
|
-
<view class="verify-title">{{col.options.operation}}</view>
|
|
119
|
-
<view id="suggestSelect" style="width:200rpx; flex-shrink: 0; text-align: right; font-size: 26rpx; color: #333; line-height: 60rpx;"
|
|
120
|
-
@click="openSuggestSelect(col)">
|
|
121
|
-
{{suggestType[col.model] || '请点击选择'}}
|
|
122
|
-
<text style="font-size: 24rpx; color: #999; margin-left: 4rpx;">▼</text>
|
|
123
|
-
</view>
|
|
124
|
-
</view>
|
|
125
|
-
<view v-if="col.model !== verifyNode" class="verify-cot">
|
|
126
|
-
<view class="verify-title">{{col.options.operation}}</view>
|
|
127
|
-
<view style="flex-shrink: 0">{{models[col.model].operation}}</view>
|
|
128
|
-
</view>
|
|
129
|
-
<view class="verify-cot">
|
|
130
|
-
<view class="verify-title">{{ col.options.operator }}</view>
|
|
131
|
-
<view style="flex-shrink: 0">{{ models[col.model].operator }}</view>
|
|
132
|
-
</view>
|
|
133
|
-
<view class="verify-cot">
|
|
134
|
-
<view class="verify-title">{{ col.options.operationTime }}</view>
|
|
135
|
-
<view style="flex-shrink: 0">{{ models[col.model].operationTime }}</view>
|
|
136
|
-
</view>
|
|
137
|
-
</view>
|
|
138
|
-
</template>
|
|
139
|
-
<template v-else>
|
|
140
|
-
<evan-form-item :isCorrect="isCorrect" :prop="col.model"
|
|
141
|
-
:labelPosition="labelPosition"
|
|
142
|
-
:ref="String(Math.random()).split('.')[1]" :models.sync="models" :rules="rules"
|
|
143
|
-
:widget.sync="col" :isDraft="isDraft" :formId="formId" :linkage="linkage" :isApply="isApply" :applyId="applyId">
|
|
144
|
-
</evan-form-item>
|
|
145
|
-
</template>
|
|
146
|
-
</view>
|
|
147
|
-
</view>
|
|
148
|
-
</view>
|
|
149
|
-
|
|
150
|
-
<view v-else-if="item.type === 'grid'" v-show="item.options.canView" class="form_layout">
|
|
151
|
-
<view class="form-item-container" v-for="(colItem, colIndex) in item.columns" :key="colIndex">
|
|
152
|
-
<view v-for="(col, itemIndex) in colItem.list" :key="itemIndex" v-show="col.options.canView">
|
|
153
|
-
<evan-form-item @upDateWidget="data => upDateGridWidget(data)" :isCorrect="isCorrect" :labelPosition="labelPosition" :prop="col.model"
|
|
154
|
-
:ref="String(Math.random()).split('.')[1]" :models.sync="models" :rules="rules"
|
|
155
|
-
:widget.sync="col" :isDraft="isDraft" :formId="formId" :linkage="linkage" :isApply="isApply" :applyId="applyId"
|
|
156
|
-
@changedate="changedate" :zbrqList="zbrqList" :thrqList="thrqList" :zjfmFormDesign="zjfmFormDesign" :thrqDataModalShow="thrqDataModalShow"
|
|
157
|
-
>
|
|
158
|
-
</evan-form-item>
|
|
159
|
-
</view>
|
|
160
|
-
</view>
|
|
161
|
-
</view>
|
|
162
|
-
|
|
163
|
-
<template v-else-if="['verify', 'hnkj-verify', 'hnkj-confirm'].includes(item.type)">
|
|
164
|
-
|
|
165
|
-
<view class="verify" v-if="item.options.canView">
|
|
166
|
-
<view class="verify-step">
|
|
167
|
-
<text v-if="item.name" class="title-block"></text>
|
|
168
|
-
<text>{{item.name }}</text>
|
|
169
|
-
</view>
|
|
170
|
-
<view v-if="item.options.supportMulti && (verifyLogs && verifyLogs[item.model])" >
|
|
171
|
-
<view v-for="(v_log, idx) in verifyLogsList(item.model)" :key="idx">
|
|
172
|
-
<view class="verify-cot">
|
|
173
|
-
<textarea :value="v_log.note" disabled>
|
|
174
|
-
</textarea>
|
|
175
|
-
</view>
|
|
176
|
-
<view class="verify-cot">
|
|
177
|
-
<view class="verify-title">{{item.options.operation}}</view>
|
|
178
|
-
<view style="flex-shrink: 0">{{v_log['shenpiYijian']}}</view>
|
|
179
|
-
</view>
|
|
180
|
-
<view class="verify-cot">
|
|
181
|
-
<view class="verify-title">{{item.options.operator}}</view>
|
|
182
|
-
<view style="flex-shrink: 0">{{v_log['realname']}}</view>
|
|
183
|
-
</view>
|
|
184
|
-
<view class="verify-cot">
|
|
185
|
-
<view class="verify-title">{{item.options.operationTime}}</view>
|
|
186
|
-
<view style="flex-shrink: 0">{{v_log['shenpiTime']}}</view>
|
|
187
|
-
</view>
|
|
188
|
-
</view>
|
|
189
|
-
</view>
|
|
190
|
-
<view class="verify-cot" :style="{position:item.model === verifyNode ? 'initial' : 'relative'}">
|
|
191
|
-
<m-textarea
|
|
192
|
-
v-if="models[item.model]"
|
|
193
|
-
:max-length="item.options.commentsLength"
|
|
194
|
-
show-word-limit
|
|
195
|
-
:value="models[item.model].comments"
|
|
196
|
-
:disabled="warpVerifyDisable(item)" :placeholder="item.options.placeholder"
|
|
197
|
-
@change="val => handlerText(val, item.model)">
|
|
198
|
-
</m-textarea>
|
|
199
|
-
<m-textarea
|
|
200
|
-
v-else
|
|
201
|
-
disabled
|
|
202
|
-
:placeholder="item.options.placeholder"
|
|
203
|
-
>
|
|
204
|
-
</m-textarea>
|
|
205
|
-
</view>
|
|
206
|
-
|
|
207
|
-
<view
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
</view>
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
<view
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
<view
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
<
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
<
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
},
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
}
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
this.$
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
}
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
}
|
|
430
|
-
|
|
431
|
-
this.zjfmFormDesign =
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
}
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
this.
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
this
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
},
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
//
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
this.
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
},
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
},
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
}
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
})
|
|
857
|
-
}
|
|
858
|
-
},
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
//
|
|
872
|
-
// this.
|
|
873
|
-
|
|
874
|
-
this
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
},
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
}
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
this.tableData[model].
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
|
|
936
|
-
|
|
937
|
-
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
});
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
987
|
-
|
|
988
|
-
|
|
989
|
-
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
return
|
|
1069
|
-
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
if (
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
|
|
1090
|
-
|
|
1091
|
-
|
|
1092
|
-
|
|
1093
|
-
|
|
1094
|
-
|
|
1095
|
-
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
|
|
1101
|
-
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
|
|
1118
|
-
|
|
1119
|
-
|
|
1120
|
-
|
|
1121
|
-
|
|
1122
|
-
|
|
1123
|
-
|
|
1124
|
-
|
|
1125
|
-
|
|
1126
|
-
|
|
1127
|
-
|
|
1128
|
-
|
|
1129
|
-
|
|
1130
|
-
|
|
1131
|
-
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
|
|
1136
|
-
|
|
1137
|
-
|
|
1138
|
-
|
|
1139
|
-
|
|
1140
|
-
|
|
1141
|
-
|
|
1142
|
-
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
|
|
1150
|
-
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
|
|
1158
|
-
|
|
1159
|
-
|
|
1160
|
-
|
|
1161
|
-
|
|
1162
|
-
|
|
1163
|
-
|
|
1164
|
-
|
|
1165
|
-
|
|
1166
|
-
|
|
1167
|
-
|
|
1168
|
-
|
|
1169
|
-
|
|
1170
|
-
|
|
1171
|
-
|
|
1172
|
-
|
|
1173
|
-
|
|
1174
|
-
|
|
1175
|
-
|
|
1176
|
-
|
|
1177
|
-
|
|
1178
|
-
|
|
1179
|
-
|
|
1180
|
-
|
|
1181
|
-
|
|
1182
|
-
|
|
1183
|
-
|
|
1184
|
-
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
}
|
|
1195
|
-
}
|
|
1196
|
-
|
|
1197
|
-
//
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
}
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
if (!
|
|
1206
|
-
|
|
1207
|
-
|
|
1208
|
-
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1215
|
-
|
|
1216
|
-
|
|
1217
|
-
|
|
1218
|
-
|
|
1219
|
-
|
|
1220
|
-
|
|
1221
|
-
|
|
1222
|
-
|
|
1223
|
-
|
|
1224
|
-
|
|
1225
|
-
|
|
1226
|
-
|
|
1227
|
-
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
|
|
1236
|
-
|
|
1237
|
-
|
|
1238
|
-
|
|
1239
|
-
|
|
1240
|
-
|
|
1241
|
-
|
|
1242
|
-
|
|
1243
|
-
|
|
1244
|
-
|
|
1245
|
-
|
|
1246
|
-
|
|
1247
|
-
|
|
1248
|
-
|
|
1249
|
-
|
|
1250
|
-
|
|
1251
|
-
|
|
1252
|
-
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
|
|
1264
|
-
|
|
1265
|
-
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
|
|
1274
|
-
|
|
1275
|
-
|
|
1276
|
-
|
|
1277
|
-
|
|
1278
|
-
|
|
1279
|
-
|
|
1280
|
-
|
|
1281
|
-
|
|
1282
|
-
|
|
1283
|
-
|
|
1284
|
-
|
|
1285
|
-
|
|
1286
|
-
|
|
1287
|
-
|
|
1288
|
-
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
|
|
1292
|
-
|
|
1293
|
-
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
|
|
1297
|
-
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
|
|
1315
|
-
|
|
1316
|
-
|
|
1317
|
-
|
|
1318
|
-
|
|
1319
|
-
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
|
|
1323
|
-
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
|
|
1328
|
-
|
|
1329
|
-
|
|
1330
|
-
|
|
1331
|
-
}
|
|
1332
|
-
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
|
|
1338
|
-
|
|
1339
|
-
|
|
1340
|
-
|
|
1341
|
-
|
|
1342
|
-
|
|
1343
|
-
|
|
1344
|
-
|
|
1345
|
-
|
|
1346
|
-
|
|
1347
|
-
|
|
1348
|
-
|
|
1349
|
-
|
|
1350
|
-
|
|
1351
|
-
|
|
1352
|
-
|
|
1353
|
-
|
|
1354
|
-
|
|
1355
|
-
|
|
1356
|
-
|
|
1357
|
-
|
|
1358
|
-
|
|
1359
|
-
|
|
1360
|
-
|
|
1361
|
-
|
|
1362
|
-
|
|
1363
|
-
|
|
1364
|
-
|
|
1365
|
-
|
|
1366
|
-
}
|
|
1367
|
-
|
|
1368
|
-
|
|
1369
|
-
this.$set(
|
|
1370
|
-
|
|
1371
|
-
|
|
1372
|
-
|
|
1373
|
-
|
|
1374
|
-
|
|
1375
|
-
|
|
1376
|
-
|
|
1377
|
-
|
|
1378
|
-
|
|
1379
|
-
|
|
1380
|
-
|
|
1381
|
-
|
|
1382
|
-
|
|
1383
|
-
|
|
1384
|
-
|
|
1385
|
-
|
|
1386
|
-
|
|
1387
|
-
|
|
1388
|
-
|
|
1389
|
-
|
|
1390
|
-
|
|
1391
|
-
|
|
1392
|
-
|
|
1393
|
-
|
|
1394
|
-
|
|
1395
|
-
|
|
1396
|
-
|
|
1397
|
-
|
|
1398
|
-
|
|
1399
|
-
|
|
1400
|
-
|
|
1401
|
-
|
|
1402
|
-
|
|
1403
|
-
|
|
1404
|
-
|
|
1405
|
-
|
|
1406
|
-
|
|
1407
|
-
|
|
1408
|
-
|
|
1409
|
-
|
|
1410
|
-
|
|
1411
|
-
|
|
1412
|
-
|
|
1413
|
-
|
|
1414
|
-
|
|
1415
|
-
|
|
1416
|
-
|
|
1417
|
-
|
|
1418
|
-
|
|
1419
|
-
|
|
1420
|
-
|
|
1421
|
-
|
|
1422
|
-
|
|
1423
|
-
|
|
1424
|
-
|
|
1425
|
-
|
|
1426
|
-
|
|
1427
|
-
|
|
1428
|
-
|
|
1429
|
-
|
|
1430
|
-
|
|
1431
|
-
|
|
1432
|
-
|
|
1433
|
-
//
|
|
1434
|
-
|
|
1435
|
-
|
|
1436
|
-
|
|
1437
|
-
|
|
1438
|
-
|
|
1439
|
-
|
|
1440
|
-
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
|
|
1444
|
-
|
|
1445
|
-
|
|
1446
|
-
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
-
|
|
1450
|
-
|
|
1451
|
-
|
|
1452
|
-
|
|
1453
|
-
|
|
1454
|
-
|
|
1455
|
-
|
|
1456
|
-
|
|
1457
|
-
|
|
1458
|
-
|
|
1459
|
-
|
|
1460
|
-
|
|
1461
|
-
|
|
1462
|
-
|
|
1463
|
-
|
|
1464
|
-
|
|
1465
|
-
|
|
1466
|
-
|
|
1467
|
-
|
|
1468
|
-
|
|
1469
|
-
|
|
1470
|
-
|
|
1471
|
-
|
|
1472
|
-
|
|
1473
|
-
|
|
1474
|
-
|
|
1475
|
-
|
|
1476
|
-
|
|
1477
|
-
|
|
1478
|
-
|
|
1479
|
-
|
|
1480
|
-
|
|
1481
|
-
|
|
1482
|
-
|
|
1483
|
-
|
|
1484
|
-
|
|
1485
|
-
|
|
1486
|
-
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
|
|
1492
|
-
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
|
|
1498
|
-
|
|
1499
|
-
|
|
1500
|
-
this.
|
|
1501
|
-
|
|
1502
|
-
|
|
1503
|
-
|
|
1504
|
-
|
|
1505
|
-
|
|
1506
|
-
|
|
1507
|
-
|
|
1508
|
-
|
|
1509
|
-
|
|
1510
|
-
|
|
1511
|
-
|
|
1512
|
-
|
|
1513
|
-
|
|
1514
|
-
|
|
1515
|
-
|
|
1516
|
-
|
|
1517
|
-
|
|
1518
|
-
|
|
1519
|
-
|
|
1520
|
-
|
|
1521
|
-
|
|
1522
|
-
|
|
1523
|
-
|
|
1524
|
-
|
|
1525
|
-
|
|
1526
|
-
|
|
1527
|
-
|
|
1528
|
-
|
|
1529
|
-
|
|
1530
|
-
|
|
1531
|
-
|
|
1532
|
-
|
|
1533
|
-
|
|
1534
|
-
|
|
1535
|
-
|
|
1536
|
-
|
|
1537
|
-
|
|
1538
|
-
|
|
1539
|
-
|
|
1540
|
-
|
|
1541
|
-
|
|
1542
|
-
|
|
1543
|
-
|
|
1544
|
-
|
|
1545
|
-
|
|
1546
|
-
|
|
1547
|
-
|
|
1548
|
-
|
|
1549
|
-
|
|
1550
|
-
|
|
1551
|
-
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1555
|
-
|
|
1556
|
-
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
|
|
1561
|
-
|
|
1562
|
-
|
|
1563
|
-
|
|
1564
|
-
|
|
1565
|
-
|
|
1566
|
-
|
|
1567
|
-
|
|
1568
|
-
|
|
1569
|
-
|
|
1570
|
-
|
|
1571
|
-
|
|
1572
|
-
|
|
1573
|
-
|
|
1574
|
-
|
|
1575
|
-
|
|
1576
|
-
|
|
1577
|
-
|
|
1578
|
-
|
|
1579
|
-
|
|
1580
|
-
|
|
1581
|
-
|
|
1582
|
-
|
|
1583
|
-
|
|
1584
|
-
|
|
1585
|
-
|
|
1586
|
-
|
|
1587
|
-
|
|
1588
|
-
|
|
1589
|
-
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1595
|
-
|
|
1596
|
-
}
|
|
1597
|
-
|
|
1598
|
-
|
|
1599
|
-
|
|
1600
|
-
|
|
1601
|
-
|
|
1602
|
-
|
|
1603
|
-
|
|
1604
|
-
|
|
1605
|
-
|
|
1606
|
-
|
|
1607
|
-
|
|
1608
|
-
|
|
1609
|
-
|
|
1610
|
-
|
|
1611
|
-
|
|
1612
|
-
|
|
1613
|
-
|
|
1614
|
-
|
|
1615
|
-
|
|
1616
|
-
|
|
1617
|
-
|
|
1618
|
-
|
|
1619
|
-
|
|
1620
|
-
|
|
1621
|
-
|
|
1622
|
-
|
|
1623
|
-
|
|
1624
|
-
}
|
|
1625
|
-
|
|
1626
|
-
|
|
1627
|
-
|
|
1628
|
-
|
|
1629
|
-
|
|
1630
|
-
|
|
1631
|
-
|
|
1632
|
-
|
|
1633
|
-
|
|
1634
|
-
|
|
1635
|
-
|
|
1636
|
-
|
|
1637
|
-
|
|
1638
|
-
}
|
|
1639
|
-
|
|
1640
|
-
|
|
1641
|
-
|
|
1642
|
-
|
|
1643
|
-
|
|
1644
|
-
|
|
1645
|
-
|
|
1646
|
-
|
|
1647
|
-
|
|
1648
|
-
|
|
1649
|
-
|
|
1650
|
-
|
|
1651
|
-
|
|
1652
|
-
.
|
|
1653
|
-
|
|
1654
|
-
|
|
1655
|
-
|
|
1656
|
-
|
|
1657
|
-
}
|
|
1658
|
-
|
|
1659
|
-
.
|
|
1660
|
-
|
|
1661
|
-
|
|
1662
|
-
|
|
1663
|
-
|
|
1664
|
-
|
|
1665
|
-
|
|
1666
|
-
|
|
1667
|
-
|
|
1668
|
-
|
|
1669
|
-
|
|
1670
|
-
|
|
1671
|
-
|
|
1672
|
-
|
|
1673
|
-
|
|
1674
|
-
|
|
1675
|
-
|
|
1676
|
-
|
|
1677
|
-
|
|
1678
|
-
|
|
1679
|
-
|
|
1680
|
-
|
|
1681
|
-
|
|
1682
|
-
|
|
1683
|
-
|
|
1684
|
-
|
|
1685
|
-
|
|
1686
|
-
|
|
1687
|
-
|
|
1688
|
-
|
|
1689
|
-
|
|
1690
|
-
|
|
1691
|
-
|
|
1692
|
-
|
|
1693
|
-
|
|
1694
|
-
|
|
1695
|
-
|
|
1696
|
-
|
|
1697
|
-
|
|
1698
|
-
|
|
1699
|
-
|
|
1700
|
-
|
|
1701
|
-
|
|
1702
|
-
|
|
1703
|
-
|
|
1704
|
-
|
|
1705
|
-
|
|
1706
|
-
|
|
1707
|
-
|
|
1708
|
-
|
|
1709
|
-
|
|
1710
|
-
|
|
1711
|
-
|
|
1712
|
-
|
|
1713
|
-
|
|
1714
|
-
|
|
1715
|
-
|
|
1716
|
-
|
|
1717
|
-
|
|
1718
|
-
|
|
1719
|
-
|
|
1720
|
-
|
|
1721
|
-
|
|
1722
|
-
|
|
1723
|
-
|
|
1724
|
-
|
|
1725
|
-
|
|
1726
|
-
|
|
1727
|
-
|
|
1728
|
-
|
|
1729
|
-
|
|
1730
|
-
|
|
1731
|
-
|
|
1732
|
-
|
|
1733
|
-
|
|
1734
|
-
|
|
1735
|
-
|
|
1736
|
-
|
|
1737
|
-
|
|
1738
|
-
|
|
1739
|
-
|
|
1740
|
-
|
|
1741
|
-
|
|
1742
|
-
|
|
1743
|
-
|
|
1744
|
-
|
|
1745
|
-
|
|
1746
|
-
|
|
1747
|
-
|
|
1748
|
-
|
|
1749
|
-
|
|
1750
|
-
|
|
1751
|
-
|
|
1752
|
-
|
|
1753
|
-
|
|
1754
|
-
|
|
1755
|
-
|
|
1756
|
-
|
|
1757
|
-
|
|
1758
|
-
|
|
1759
|
-
|
|
1760
|
-
|
|
1761
|
-
|
|
1762
|
-
|
|
1763
|
-
|
|
1764
|
-
|
|
1765
|
-
|
|
1766
|
-
|
|
1767
|
-
|
|
1768
|
-
|
|
1769
|
-
|
|
1770
|
-
|
|
1771
|
-
|
|
1772
|
-
|
|
1773
|
-
|
|
1774
|
-
|
|
1775
|
-
|
|
1776
|
-
|
|
1777
|
-
|
|
1778
|
-
|
|
1779
|
-
|
|
1780
|
-
|
|
1781
|
-
|
|
1782
|
-
|
|
1783
|
-
|
|
1784
|
-
|
|
1785
|
-
|
|
1786
|
-
|
|
1787
|
-
|
|
1788
|
-
|
|
1789
|
-
|
|
1790
|
-
|
|
1791
|
-
|
|
1792
|
-
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
|
|
1796
|
-
|
|
1797
|
-
|
|
1798
|
-
|
|
1799
|
-
|
|
1800
|
-
|
|
1801
|
-
|
|
1802
|
-
|
|
1803
|
-
|
|
1804
|
-
|
|
1805
|
-
|
|
1806
|
-
|
|
1807
|
-
|
|
1808
|
-
|
|
1809
|
-
|
|
1810
|
-
|
|
1811
|
-
|
|
1812
|
-
|
|
1813
|
-
|
|
1814
|
-
|
|
1815
|
-
|
|
1816
|
-
|
|
1817
|
-
|
|
1818
|
-
|
|
1819
|
-
|
|
1820
|
-
|
|
1821
|
-
|
|
1822
|
-
|
|
1823
|
-
|
|
1824
|
-
|
|
1825
|
-
|
|
1826
|
-
|
|
1827
|
-
|
|
1828
|
-
|
|
1829
|
-
|
|
1830
|
-
|
|
1831
|
-
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
|
|
1835
|
-
|
|
1836
|
-
|
|
1837
|
-
|
|
1838
|
-
|
|
1839
|
-
|
|
1840
|
-
|
|
1841
|
-
|
|
1842
|
-
|
|
1843
|
-
|
|
1844
|
-
}
|
|
1845
|
-
|
|
1846
|
-
|
|
1847
|
-
|
|
1848
|
-
|
|
1849
|
-
|
|
1850
|
-
|
|
1851
|
-
|
|
1852
|
-
|
|
1
|
+
<template>
|
|
2
|
+
<view class="evan-form-show" >
|
|
3
|
+
<evan-form :hide-required-asterisk="hideRequiredAsterisk" ref="Form" :dataObj="dataObj">
|
|
4
|
+
<template v-for="(item, index) in data.list">
|
|
5
|
+
<template v-if="item.type === 'table' && item.options.canView">
|
|
6
|
+
<view class="table-wrapper" :key="index">
|
|
7
|
+
<view class="table-header">
|
|
8
|
+
<text v-if="item.name" class="title-block"></text>
|
|
9
|
+
<text>{{ item.name }}</text>
|
|
10
|
+
</view>
|
|
11
|
+
<view class="table-container">
|
|
12
|
+
<template v-if="item.options.supportPage">
|
|
13
|
+
<view class="table-item" v-for="(table, tableCIndex) in currTablePageData(item)"
|
|
14
|
+
:key="tablePageIndex(item.model,tableCIndex)"
|
|
15
|
+
:index="tablePageIndex(item.model,tableCIndex)"
|
|
16
|
+
>
|
|
17
|
+
<view class="item" v-show="!item.options.hiddenOperateBtn">
|
|
18
|
+
<view class="index">{{table.index + 1}}</view>
|
|
19
|
+
<view class="delete icon-delete" v-if="!item.options.disabled&&!item.options.hiddenOperateBtn"
|
|
20
|
+
@click="handleDeleteRow(tablePageIndex(item.model,tableCIndex), item.model)">删除</view>
|
|
21
|
+
<view class="extend"
|
|
22
|
+
:class="{'icon-arrow-right': !tableRowsShow[item.model][tablePageIndex(item.model,tableCIndex)], 'icon-arrow-down':tableRowsShow[item.model][tablePageIndex(item.model,tableCIndex)]}"
|
|
23
|
+
@click="showTableRow(item.model, tablePageIndex(item.model,tableCIndex))">
|
|
24
|
+
{{tableRowsShow[item.model][tablePageIndex(item.model,tableCIndex)] ? '收起' : '展开'}}
|
|
25
|
+
</view>
|
|
26
|
+
</view>
|
|
27
|
+
<view class="view-port" v-show="tableRowsShow[item.model][tablePageIndex(item.model,tableCIndex)]" style="border-bottom: 1px solid #b2b2b2;">
|
|
28
|
+
<view v-for="(tableItem, tableItemIndex) in table.columns" :key="tableItemIndex" :class="'table-item-view' + (tableItemIndex % 3)">
|
|
29
|
+
<evan-form-item v-show="tableItem.options.canView"
|
|
30
|
+
:labelPosition="labelPosition"
|
|
31
|
+
@upDateWidget="data => upDateTableWidget(data, tableItemIndex, item.model, tablePageIndex(item.model,tableCIndex))" :itemkey="tableItemIndex"
|
|
32
|
+
:curLoadedPages="(tablePageInfo[item.model].current - 1) * tablePageInfo[item.model].pageSize + tablePageInfo[item.model].pageSize"
|
|
33
|
+
:parentTableKey="item.key" :tableKey="item.model" :tableIndex="tablePageIndex(item.model,tableCIndex)" :prop="tableItem.model"
|
|
34
|
+
:ref="String(Math.random()).split('.')[1]" :models.sync="models"
|
|
35
|
+
:rules="rules" :widget.sync="tableItem" :isDraft="isDraft" :formId="formId"
|
|
36
|
+
:linkage="linkage" :isApply="isApply" :applyId="applyId">
|
|
37
|
+
</evan-form-item>
|
|
38
|
+
</view>
|
|
39
|
+
</view>
|
|
40
|
+
</view>
|
|
41
|
+
<!-- #ifdef H5 -->
|
|
42
|
+
<page-pagination v-if="tablePageInfo[item.model]&&tablePageInfo[item.model].total" :total="tablePageInfo[item.model]&&tablePageInfo[item.model].total"
|
|
43
|
+
:currentPage="tablePageInfo[item.model]&&tablePageInfo[item.model].current"
|
|
44
|
+
@change="(...args) => tablePageChange(item,...args)"
|
|
45
|
+
:numAround="true" :showBorder="false"></page-pagination>
|
|
46
|
+
<!-- #endif -->
|
|
47
|
+
<!-- #ifdef MP-WEIXIN -->
|
|
48
|
+
<page-pagination v-if="tablePageInfo[item.model]&&tablePageInfo[item.model].total" :total="tablePageInfo[item.model]&&tablePageInfo[item.model].total"
|
|
49
|
+
:currentPage="tablePageInfo[item.model]&&tablePageInfo[item.model].current"
|
|
50
|
+
@change="tablePageChange(item, $event)"
|
|
51
|
+
:numAround="true" :showBorder="false"></page-pagination>
|
|
52
|
+
<!-- #endif -->
|
|
53
|
+
</template>
|
|
54
|
+
<template v-else>
|
|
55
|
+
<view class="table-item" v-for="(table, tableCIndex) in tableData[item.model]"
|
|
56
|
+
:key="tableCIndex">
|
|
57
|
+
<view class="item" v-show="!item.options.hiddenOperateBtn">
|
|
58
|
+
<view class="index">{{table.index + 1}}</view>
|
|
59
|
+
<view class="delete icon-delete" v-if="!item.options.disabled&&!item.options.hiddenOperateBtn"
|
|
60
|
+
@click="handleDeleteRow(tableCIndex, item.model)">删除</view>
|
|
61
|
+
<view class="extend"
|
|
62
|
+
:class="{'icon-arrow-right': !tableRowsShow[item.model][tableCIndex], 'icon-arrow-down':tableRowsShow[item.model][tableCIndex]}"
|
|
63
|
+
@click="showTableRow(item.model, tableCIndex)">
|
|
64
|
+
</view>
|
|
65
|
+
</view>
|
|
66
|
+
<view class="view-port" v-show="tableRowsShow[item.model][tableCIndex]" style="border-bottom: 1px solid #b2b2b2;">
|
|
67
|
+
<view v-for="(tableItem, tableItemIndex) in table.columns" :key="tableItemIndex" :class="'table-item-view' + (tableItemIndex % 3)">
|
|
68
|
+
<evan-form-item v-show="tableItem.options.canView"
|
|
69
|
+
:labelPosition="labelPosition"
|
|
70
|
+
@upDateWidget="data => upDateTableWidget(data, tableItemIndex, item.model, tableCIndex)" :itemkey="tableItemIndex"
|
|
71
|
+
:tableKey="item.model" :tableIndex="tableCIndex" :prop="tableItem.model"
|
|
72
|
+
:ref="String(Math.random()).split('.')[1]" :models.sync="models"
|
|
73
|
+
:rules="rules" :widget.sync="tableItem" :isDraft="isDraft" :formId="formId"
|
|
74
|
+
:linkage="linkage" :isApply="isApply" :applyId="applyId">
|
|
75
|
+
</evan-form-item>
|
|
76
|
+
</view>
|
|
77
|
+
</view>
|
|
78
|
+
</view>
|
|
79
|
+
</template>
|
|
80
|
+
<view class="add" v-if="isShowAdd && !item.options.disabled&&!item.options.hiddenOperateBtn" :data-data="item"
|
|
81
|
+
:data-model="item.model" data-add-model="addModel"
|
|
82
|
+
@click="addToTableData(item, item.model,'addModel')">+添加</view>
|
|
83
|
+
</view>
|
|
84
|
+
</view>
|
|
85
|
+
</template>
|
|
86
|
+
|
|
87
|
+
<view v-else-if="item.type === 'all-lay-out'" v-show="item.options.canView" class="form_layout">
|
|
88
|
+
<view v-for="(colItem, colIndex) in item.columns" :key="colIndex" class="form-item-container">
|
|
89
|
+
<view v-for="(col, itemIndex) in colItem.list" :key="itemIndex" v-show="col.options.canView">
|
|
90
|
+
<evan-form-item :isCorrect="isCorrect" :labelPosition="labelPosition" :prop="col.model"
|
|
91
|
+
:ref="String(Math.random()).split('.')[1]" :models.sync="models" :rules="rules"
|
|
92
|
+
:widget.sync="col" :isDraft="isDraft" :formId="formId" :linkage="linkage" :isApply="isApply" :applyId="applyId">
|
|
93
|
+
</evan-form-item>
|
|
94
|
+
</view>
|
|
95
|
+
</view>
|
|
96
|
+
</view>
|
|
97
|
+
|
|
98
|
+
<view v-else-if="item.type === 'grid-lay-out'" v-show="item.options.canView" class="form_layout">
|
|
99
|
+
<view v-for="(colItem, colIndex) in item.columns" :key="colIndex" class="form-item-container ">
|
|
100
|
+
<view v-for="(col, itemIndex) in colItem.list" :key="itemIndex" v-show="col.options.canView">
|
|
101
|
+
<template v-if="['hnkj-confirm', 'hnkj-verify'].includes(col.type) && item.options.canView">
|
|
102
|
+
<view class="verify">
|
|
103
|
+
<view class="verify-step">
|
|
104
|
+
<text v-if="col.name" class="title-block"></text>
|
|
105
|
+
<text>{{col.name }}</text>
|
|
106
|
+
|
|
107
|
+
</view>
|
|
108
|
+
<view class="verify-cot">
|
|
109
|
+
<m-textarea
|
|
110
|
+
:value="models[col.model].comments"
|
|
111
|
+
show-word-limit
|
|
112
|
+
:max-length="col.options.commentsLength"
|
|
113
|
+
:disabled="col.model !== verifyNode" :placeholder="col.options.placeholder"
|
|
114
|
+
@change="val => handlerText(val, col.model)">
|
|
115
|
+
</m-textarea>
|
|
116
|
+
</view>
|
|
117
|
+
<view v-if="col.model == verifyNode" class="verify-cot">
|
|
118
|
+
<view class="verify-title">{{col.options.operation}}</view>
|
|
119
|
+
<view id="suggestSelect" style="width:200rpx; flex-shrink: 0; text-align: right; font-size: 26rpx; color: #333; line-height: 60rpx;"
|
|
120
|
+
@click="openSuggestSelect(col)">
|
|
121
|
+
{{suggestType[col.model] || '请点击选择'}}
|
|
122
|
+
<text style="font-size: 24rpx; color: #999; margin-left: 4rpx;">▼</text>
|
|
123
|
+
</view>
|
|
124
|
+
</view>
|
|
125
|
+
<view v-if="col.model !== verifyNode" class="verify-cot">
|
|
126
|
+
<view class="verify-title">{{col.options.operation}}</view>
|
|
127
|
+
<view style="flex-shrink: 0">{{models[col.model].operation}}</view>
|
|
128
|
+
</view>
|
|
129
|
+
<view class="verify-cot">
|
|
130
|
+
<view class="verify-title">{{ col.options.operator }}</view>
|
|
131
|
+
<view style="flex-shrink: 0">{{ models[col.model].operator }}</view>
|
|
132
|
+
</view>
|
|
133
|
+
<view class="verify-cot">
|
|
134
|
+
<view class="verify-title">{{ col.options.operationTime }}</view>
|
|
135
|
+
<view style="flex-shrink: 0">{{ models[col.model].operationTime }}</view>
|
|
136
|
+
</view>
|
|
137
|
+
</view>
|
|
138
|
+
</template>
|
|
139
|
+
<template v-else>
|
|
140
|
+
<evan-form-item :isCorrect="isCorrect" :prop="col.model"
|
|
141
|
+
:labelPosition="labelPosition"
|
|
142
|
+
:ref="String(Math.random()).split('.')[1]" :models.sync="models" :rules="rules"
|
|
143
|
+
:widget.sync="col" :isDraft="isDraft" :formId="formId" :linkage="linkage" :isApply="isApply" :applyId="applyId">
|
|
144
|
+
</evan-form-item>
|
|
145
|
+
</template>
|
|
146
|
+
</view>
|
|
147
|
+
</view>
|
|
148
|
+
</view>
|
|
149
|
+
|
|
150
|
+
<view v-else-if="item.type === 'grid'" v-show="item.options.canView" class="form_layout">
|
|
151
|
+
<view class="form-item-container" v-for="(colItem, colIndex) in item.columns" :key="colIndex">
|
|
152
|
+
<view v-for="(col, itemIndex) in colItem.list" :key="itemIndex" v-show="col.options.canView">
|
|
153
|
+
<evan-form-item @upDateWidget="data => upDateGridWidget(data)" :isCorrect="isCorrect" :labelPosition="labelPosition" :prop="col.model"
|
|
154
|
+
:ref="String(Math.random()).split('.')[1]" :models.sync="models" :rules="rules"
|
|
155
|
+
:widget.sync="col" :isDraft="isDraft" :formId="formId" :linkage="linkage" :isApply="isApply" :applyId="applyId"
|
|
156
|
+
@changedate="changedate" :zbrqList="zbrqList" :thrqList="thrqList" :zjfmFormDesign="zjfmFormDesign" :thrqDataModalShow="thrqDataModalShow"
|
|
157
|
+
>
|
|
158
|
+
</evan-form-item>
|
|
159
|
+
</view>
|
|
160
|
+
</view>
|
|
161
|
+
</view>
|
|
162
|
+
|
|
163
|
+
<template v-else-if="['verify', 'hnkj-verify', 'hnkj-confirm'].includes(item.type)">
|
|
164
|
+
|
|
165
|
+
<view class="verify" v-if="item.options.canView">
|
|
166
|
+
<view class="verify-step">
|
|
167
|
+
<text v-if="item.name" class="title-block"></text>
|
|
168
|
+
<text>{{item.name }}</text>
|
|
169
|
+
</view>
|
|
170
|
+
<view v-if="item.options.supportMulti && (verifyLogs && verifyLogs[item.model])" >
|
|
171
|
+
<view v-for="(v_log, idx) in verifyLogsList(item.model)" :key="idx">
|
|
172
|
+
<view class="verify-cot">
|
|
173
|
+
<textarea :value="v_log.note" disabled>
|
|
174
|
+
</textarea>
|
|
175
|
+
</view>
|
|
176
|
+
<view class="verify-cot">
|
|
177
|
+
<view class="verify-title">{{item.options.operation}}</view>
|
|
178
|
+
<view style="flex-shrink: 0">{{v_log['shenpiYijian']}}</view>
|
|
179
|
+
</view>
|
|
180
|
+
<view class="verify-cot">
|
|
181
|
+
<view class="verify-title">{{item.options.operator}}</view>
|
|
182
|
+
<view style="flex-shrink: 0">{{v_log['realname']}}</view>
|
|
183
|
+
</view>
|
|
184
|
+
<view class="verify-cot">
|
|
185
|
+
<view class="verify-title">{{item.options.operationTime}}</view>
|
|
186
|
+
<view style="flex-shrink: 0">{{v_log['shenpiTime']}}</view>
|
|
187
|
+
</view>
|
|
188
|
+
</view>
|
|
189
|
+
</view>
|
|
190
|
+
<view class="verify-cot" :style="{position:item.model === verifyNode ? 'initial' : 'relative'}">
|
|
191
|
+
<m-textarea
|
|
192
|
+
v-if="models[item.model]"
|
|
193
|
+
:max-length="item.options.commentsLength"
|
|
194
|
+
show-word-limit
|
|
195
|
+
:value="models[item.model].comments"
|
|
196
|
+
:disabled="warpVerifyDisable(item)" :placeholder="item.options.placeholder"
|
|
197
|
+
@change="val => handlerText(val, item.model)">
|
|
198
|
+
</m-textarea>
|
|
199
|
+
<m-textarea
|
|
200
|
+
v-else
|
|
201
|
+
disabled
|
|
202
|
+
:placeholder="item.options.placeholder"
|
|
203
|
+
>
|
|
204
|
+
</m-textarea>
|
|
205
|
+
</view>
|
|
206
|
+
<!-- 盖章按钮 -->
|
|
207
|
+
<view v-if="item.model === verifyNode && sealCache[item.model] && !(models[item.model] && models[item.model].userSeal) && !warpVerifyDisable(item)"
|
|
208
|
+
class="verify-seal-btn" @tap="handleVerifySeal(item.model)">
|
|
209
|
+
盖章
|
|
210
|
+
</view>
|
|
211
|
+
<!-- #ifdef HBSF-MODE -->
|
|
212
|
+
<view style="display: flex;align-items: center;background-color: #fff;padding: 20rpx 30rpx;" v-if="item.model === verifyNode">
|
|
213
|
+
<view style="color: #808080;">推荐审核意见:</view>
|
|
214
|
+
<view style="display: flex;justify-content: space-between;">
|
|
215
|
+
<view class="form-input-suggest" @click="models[item.model].comments = '同意'">同意</view>
|
|
216
|
+
<view class="form-input-suggest" @click="models[item.model].comments = '情况属实'">情况属实</view>
|
|
217
|
+
<view class="form-input-suggest" @click="models[item.model].comments = '确认审核'">确认审核</view>
|
|
218
|
+
</view>
|
|
219
|
+
</view>
|
|
220
|
+
<!-- #endif -->
|
|
221
|
+
<view v-if="!warpVerifyDisable(item)" class="verify-cot">
|
|
222
|
+
<view class="verify-title">{{item.options.operation}}</view>
|
|
223
|
+
<view id="suggestSelect" style="width:200rpx; flex-shrink: 0; text-align: right; font-size: 26rpx; color: #333; line-height: 60rpx;"
|
|
224
|
+
@click="openSuggestSelect(item)">
|
|
225
|
+
{{suggestType[item.model] || '请点击选择'}}
|
|
226
|
+
<text style="font-size: 24rpx; color: #999; margin-left: 4rpx;">▼</text>
|
|
227
|
+
</view>
|
|
228
|
+
</view>
|
|
229
|
+
<view v-if="warpVerifyDisable(item)" class="verify-cot">
|
|
230
|
+
<view class="verify-title">{{item.options.operation}}</view>
|
|
231
|
+
<view style="flex-shrink: 0" v-if="models[item.model]">{{models[item.model].operationShow || models[item.model].operation}}</view>
|
|
232
|
+
</view>
|
|
233
|
+
<view class="verify-cot">
|
|
234
|
+
<view class="verify-title">{{ item.options.operator }}</view>
|
|
235
|
+
<view style="flex-shrink: 0" v-if="models[item.model]">{{ models[item.model].operator }}</view>
|
|
236
|
+
</view>
|
|
237
|
+
<view class="verify-cot">
|
|
238
|
+
<view class="verify-title">{{ item.options.operationTime }}</view>
|
|
239
|
+
<view style="flex-shrink: 0" v-if="models[item.model]">{{ models[item.model].operationTime }}</view>
|
|
240
|
+
</view>
|
|
241
|
+
<!-- 当前审核盖章 -->
|
|
242
|
+
<view v-if="item.model === verifyNode && models[item.model] && models[item.model].userSeal" class="verify-seal">
|
|
243
|
+
<image :src="resolveSealUrl(models[item.model].userSeal)" mode="aspectFit" class="verify-seal__img"></image>
|
|
244
|
+
<view v-if="!warpVerifyDisable(item)" class="verify-seal__close" @tap.stop="handleVerifySealClose(item.model)">
|
|
245
|
+
<text class="verify-seal__close-text">x</text>
|
|
246
|
+
</view>
|
|
247
|
+
</view>
|
|
248
|
+
<!-- 回显盖章 -->
|
|
249
|
+
<view v-if="item.model !== verifyNode && models[item.model] && models[item.model].userSeal" class="verify-seal">
|
|
250
|
+
<image :src="resolveSealUrl(models[item.model].userSeal)" mode="aspectFit" class="verify-seal__img"></image>
|
|
251
|
+
</view>
|
|
252
|
+
</view>
|
|
253
|
+
</template>
|
|
254
|
+
|
|
255
|
+
<template v-else>
|
|
256
|
+
<view :key="index" class="form-item-container" v-show="item.options.canView" >
|
|
257
|
+
|
|
258
|
+
<evan-form-item @upDateWidget="data => upDateWidget(data, index)" :labelPosition="labelPosition" :isCorrect="isCorrect" :prop="item.model"
|
|
259
|
+
:ref="String(Math.random()).split('.')[1]" :models.sync="models" :rules="rules"
|
|
260
|
+
:widget.sync="item" :itemkey="index" :isDraft="isDraft" :formId="formId" :linkage="linkage" :formData="value"
|
|
261
|
+
:isApply="isApply" :applyId="applyId">
|
|
262
|
+
</evan-form-item>
|
|
263
|
+
</view>
|
|
264
|
+
</template>
|
|
265
|
+
<!-- {{ item.options.canView? 1 : 0 }}-->
|
|
266
|
+
</template>
|
|
267
|
+
|
|
268
|
+
</evan-form>
|
|
269
|
+
</view>
|
|
270
|
+
</template>
|
|
271
|
+
|
|
272
|
+
<script>
|
|
273
|
+
import utils from '../evan-form/utils.js'
|
|
274
|
+
import {
|
|
275
|
+
cloneObj
|
|
276
|
+
} from "../../utils/util.js";
|
|
277
|
+
import Pubsub from 'pubsub-js'
|
|
278
|
+
import evanFormItem from "../evan-form-item/evan-form-item";
|
|
279
|
+
import pagePagination from '../page-pagination/page-pagination';
|
|
280
|
+
import evanForm from "../evan-form/evan-form";
|
|
281
|
+
import mTextarea from "../m-textarea/m-textarea";
|
|
282
|
+
import packageJson from '../../package.json'
|
|
283
|
+
import { run } from "../../utils/formula_run"
|
|
284
|
+
import moment from "../../utils/moment"
|
|
285
|
+
import {intersection, isEqual, isEqualWith, reduce, cloneDeep} from "lodash";
|
|
286
|
+
import {getRecursionWidget, cacheHttp} from "../../utils/util";
|
|
287
|
+
console.log('zhxy-app-component: ', packageJson.version)
|
|
288
|
+
function timeout(ms) {
|
|
289
|
+
return new Promise(resolve => {
|
|
290
|
+
setTimeout(() => {
|
|
291
|
+
resolve()
|
|
292
|
+
}, ms)
|
|
293
|
+
})
|
|
294
|
+
}
|
|
295
|
+
export default {
|
|
296
|
+
options: { styleIsolation: 'shared' },
|
|
297
|
+
name: 'formContainer',
|
|
298
|
+
props: ['dataObj', 'value', 'isButton', 'verifyNode', 'verifyLogs', 'suggest', 'isCorrect', 'isDraft', 'formId', 'linkage', "labelPosition",
|
|
299
|
+
'isApply','applyId'
|
|
300
|
+
],
|
|
301
|
+
components: { evanFormItem ,evanForm, mTextarea, pagePagination, },
|
|
302
|
+
provide() {
|
|
303
|
+
return {
|
|
304
|
+
formContext: this,
|
|
305
|
+
dataObj: () => this.dataObj,
|
|
306
|
+
getFormData: () => this.value,
|
|
307
|
+
}
|
|
308
|
+
},
|
|
309
|
+
data() {
|
|
310
|
+
return {
|
|
311
|
+
timer: null,
|
|
312
|
+
showVerify: false, //默认不展示审核信息
|
|
313
|
+
selectShow: {
|
|
314
|
+
|
|
315
|
+
},
|
|
316
|
+
suggestType: {},
|
|
317
|
+
selectList: {},
|
|
318
|
+
models: {
|
|
319
|
+
|
|
320
|
+
}, //models
|
|
321
|
+
rules: {}, //校验规则1
|
|
322
|
+
// value: {}, //后台返回的表单值 (通常是父组件传值过来的)
|
|
323
|
+
tableData: {},
|
|
324
|
+
tableModel: {},
|
|
325
|
+
tableIndex: {},
|
|
326
|
+
tableFlag: {
|
|
327
|
+
|
|
328
|
+
},
|
|
329
|
+
data: {},
|
|
330
|
+
userSignature: null,
|
|
331
|
+
userSignaturePromise: null,
|
|
332
|
+
sealCache: {},
|
|
333
|
+
imgUrl: '',
|
|
334
|
+
// dataObj:dataObj,
|
|
335
|
+
isScroll: true,
|
|
336
|
+
tableRowsShow: {},
|
|
337
|
+
isShowAdd: true,
|
|
338
|
+
hideRequiredAsterisk: false,
|
|
339
|
+
sexes: [{
|
|
340
|
+
name: '男',
|
|
341
|
+
value: 'man'
|
|
342
|
+
},
|
|
343
|
+
{
|
|
344
|
+
name: '女',
|
|
345
|
+
value: 'woman'
|
|
346
|
+
}
|
|
347
|
+
],
|
|
348
|
+
// 表单的内容必须初始化
|
|
349
|
+
info: {
|
|
350
|
+
name: '',
|
|
351
|
+
table: [{
|
|
352
|
+
sub: '22'
|
|
353
|
+
},
|
|
354
|
+
{
|
|
355
|
+
sub: '333'
|
|
356
|
+
}
|
|
357
|
+
]
|
|
358
|
+
},
|
|
359
|
+
info2: {
|
|
360
|
+
name: '222',
|
|
361
|
+
email: '7556@qq.com',
|
|
362
|
+
phone: '15232656598',
|
|
363
|
+
sub: '',
|
|
364
|
+
},
|
|
365
|
+
pickerIndex: 0,
|
|
366
|
+
zbrqList: null,
|
|
367
|
+
thrqList: null,
|
|
368
|
+
zjfmFormDesign: false,
|
|
369
|
+
thrqDataModalShow: '',
|
|
370
|
+
formDesignFlag: false,
|
|
371
|
+
unwatch:null,
|
|
372
|
+
publish_linkage_array:[],
|
|
373
|
+
tablePageInfo: {}
|
|
374
|
+
}
|
|
375
|
+
},
|
|
376
|
+
watch: {
|
|
377
|
+
// models(v) {
|
|
378
|
+
// // console.log('container models')
|
|
379
|
+
// // console.log(v)
|
|
380
|
+
// // console.log(this.models)
|
|
381
|
+
// this.isScroll = true;
|
|
382
|
+
// },
|
|
383
|
+
"dataObj.config"(val) {
|
|
384
|
+
if (val?.linkage_config) {
|
|
385
|
+
this.data.config = val
|
|
386
|
+
this.handleLinkAge()
|
|
387
|
+
}
|
|
388
|
+
},
|
|
389
|
+
verifyNode: {
|
|
390
|
+
handler(val) {
|
|
391
|
+
if (val) {
|
|
392
|
+
this.getUserSignature().then(res => {
|
|
393
|
+
if (res.success && res.result && res.result.userSeal) {
|
|
394
|
+
this.$set(this.sealCache, val, res.result.userSeal)
|
|
395
|
+
}
|
|
396
|
+
})
|
|
397
|
+
}
|
|
398
|
+
},
|
|
399
|
+
immediate: true
|
|
400
|
+
},
|
|
401
|
+
models: {
|
|
402
|
+
deep: true,
|
|
403
|
+
handler(v) {
|
|
404
|
+
this.isScroll = true;
|
|
405
|
+
if(v && !this.formDesignFlag) {
|
|
406
|
+
this.formDesignFlag = true
|
|
407
|
+
this.$u.get('sys/dict/getDictItems/zbb_th_app_id').then((res) => {
|
|
408
|
+
if (res.success) {
|
|
409
|
+
if(res.result && res.result.length > 0 && res.result[0].value == this.$Route.query.id) {
|
|
410
|
+
if(this.$Route.query.type && this.$Route.query.type === 'detail') {
|
|
411
|
+
|
|
412
|
+
} else {
|
|
413
|
+
this.$u.get('zhxyZbb/canOpenZbbThsq', {appId: this.$Route.query.id}).then((res) => {
|
|
414
|
+
if(!res.result) {
|
|
415
|
+
uni.showToast({
|
|
416
|
+
title: "当前无值班信息!",
|
|
417
|
+
duration: 2000,
|
|
418
|
+
icon: "none",
|
|
419
|
+
});
|
|
420
|
+
setTimeout(() => {
|
|
421
|
+
uni.navigateBack({
|
|
422
|
+
//uni.navigateTo跳转的返回,默认1为返回上一级
|
|
423
|
+
delta: 1,
|
|
424
|
+
});
|
|
425
|
+
}, 2000)
|
|
426
|
+
return
|
|
427
|
+
}
|
|
428
|
+
})
|
|
429
|
+
}
|
|
430
|
+
|
|
431
|
+
this.zjfmFormDesign = true
|
|
432
|
+
this.$u.post("zhxyZbb/zhxyZbbZbth", this.models).then((res) => {
|
|
433
|
+
if (res.success) {
|
|
434
|
+
this.zbrqList = res.result;
|
|
435
|
+
} else {
|
|
436
|
+
this.zbrqList = null
|
|
437
|
+
}
|
|
438
|
+
});
|
|
439
|
+
if(this.models.zbrq) {
|
|
440
|
+
this.getThrqList(this.models.zbrq, true)
|
|
441
|
+
}
|
|
442
|
+
if(this.models.thr) {
|
|
443
|
+
this.$u.post("zhxyZbb/zhxyZbbZbth", {value:this.models, model: 'thrq', applyId: this.$Route.query.applyId }).then((res) => {
|
|
444
|
+
if (res.success) {
|
|
445
|
+
// this.zbrqList = res.result
|
|
446
|
+
this.thrqDataModalShow = res.result.filter(item => item.gh == this.models.thr)[0].xm
|
|
447
|
+
} else {
|
|
448
|
+
this.thrqDataModalShow = ''
|
|
449
|
+
}
|
|
450
|
+
});
|
|
451
|
+
}
|
|
452
|
+
} else {
|
|
453
|
+
this.zjfmFormDesign = false
|
|
454
|
+
}
|
|
455
|
+
} else {
|
|
456
|
+
this.zjfmFormDesign = false
|
|
457
|
+
}
|
|
458
|
+
})
|
|
459
|
+
}
|
|
460
|
+
}
|
|
461
|
+
},
|
|
462
|
+
dataObj: {
|
|
463
|
+
handler(v) {
|
|
464
|
+
if (this._currObjId && this._currObjId !== this.dataObj._currObjId) return
|
|
465
|
+
this.data = v
|
|
466
|
+
if (this.dataObj && this.dataObj.list && this.dataObj.list.length > 0) {
|
|
467
|
+
this.data = v
|
|
468
|
+
this.dataObj._currObjId = this._currObjId = Math.random()
|
|
469
|
+
this.rules = {};
|
|
470
|
+
this.generateModle(this.data.list);
|
|
471
|
+
this.initFormLinkage();
|
|
472
|
+
this.updateFormDataToModels()
|
|
473
|
+
}
|
|
474
|
+
},
|
|
475
|
+
immediate: true
|
|
476
|
+
},
|
|
477
|
+
data: {
|
|
478
|
+
handler(val) {
|
|
479
|
+
this.dataObj = val
|
|
480
|
+
},
|
|
481
|
+
deep: true
|
|
482
|
+
},
|
|
483
|
+
value: {
|
|
484
|
+
handler(v) {
|
|
485
|
+
if (v) {
|
|
486
|
+
this.updateFormDataToModels()
|
|
487
|
+
}
|
|
488
|
+
},
|
|
489
|
+
immediate: true
|
|
490
|
+
},
|
|
491
|
+
suggest(v) {
|
|
492
|
+
this.$set(this.selectList, this.verifyNode, v);
|
|
493
|
+
this.$set(this.selectShow, this.verifyNode, false);
|
|
494
|
+
const item = this.dataObj.list.find(obj => obj.model === this.verifyNode)
|
|
495
|
+
if (item
|
|
496
|
+
&& !this.models[this.verifyNode].operation
|
|
497
|
+
&& item.options.operationChooseFirst) {
|
|
498
|
+
this.models[this.verifyNode].operation = this.suggest[0]
|
|
499
|
+
? this.suggest[0].value
|
|
500
|
+
: "";
|
|
501
|
+
this.$set(this.suggestType, this.verifyNode, this.models[this.verifyNode].operation)
|
|
502
|
+
this.fillVerifySignSeal(item)
|
|
503
|
+
}
|
|
504
|
+
if (item
|
|
505
|
+
&& !this.models[this.verifyNode].operation
|
|
506
|
+
&& item.options.confirmOperationChooseFirst) {
|
|
507
|
+
this.models[this.verifyNode].operation = this.suggest[0]
|
|
508
|
+
? this.suggest[0].value
|
|
509
|
+
: "";
|
|
510
|
+
this.$set(this.suggestType, this.verifyNode, this.models[this.verifyNode].operation)
|
|
511
|
+
this.fillVerifySignSeal(item)
|
|
512
|
+
}
|
|
513
|
+
},
|
|
514
|
+
tableData: {
|
|
515
|
+
handler(val) {
|
|
516
|
+
const keys = Object.keys(this.tableData)
|
|
517
|
+
keys.forEach(key => {
|
|
518
|
+
if (!this.tablePageInfo[key]) {
|
|
519
|
+
this.$set(this.tablePageInfo, key, {
|
|
520
|
+
current: 1,
|
|
521
|
+
pageSize: 10,
|
|
522
|
+
total: this.tableData[key].length
|
|
523
|
+
})
|
|
524
|
+
}
|
|
525
|
+
this.tablePageInfo[key].total = this.tableData[key].length
|
|
526
|
+
})
|
|
527
|
+
},
|
|
528
|
+
immediate: true,
|
|
529
|
+
deep: true
|
|
530
|
+
},
|
|
531
|
+
// linkage:{
|
|
532
|
+
// deep: true,
|
|
533
|
+
// handler(v){
|
|
534
|
+
// console.log(v,'12345675676575')
|
|
535
|
+
// },
|
|
536
|
+
// }
|
|
537
|
+
},
|
|
538
|
+
created() {
|
|
539
|
+
this.imgUrl = this.uniEnv?.imgUrl || this.$imgUrl || global?._CONFIG?.imgUrl || ''
|
|
540
|
+
this.updateWidget = Pubsub.subscribe("updateWidget",(key,data)=>{
|
|
541
|
+
const findKey = arr =>{
|
|
542
|
+
if(!arr || !arr.length){
|
|
543
|
+
return false;
|
|
544
|
+
}
|
|
545
|
+
let index = -1;
|
|
546
|
+
index = arr.findIndex(item=>item.model == data.model);
|
|
547
|
+
if(index > -1){
|
|
548
|
+
return true;
|
|
549
|
+
}else{
|
|
550
|
+
return false;
|
|
551
|
+
}
|
|
552
|
+
}
|
|
553
|
+
const changeWidget = arr =>{
|
|
554
|
+
return arr.map(item=>{
|
|
555
|
+
if(item.model == data.model){
|
|
556
|
+
return data;
|
|
557
|
+
}else{
|
|
558
|
+
return item;
|
|
559
|
+
}
|
|
560
|
+
})
|
|
561
|
+
}
|
|
562
|
+
if(findKey(this.data.list)){
|
|
563
|
+
this.data.list = changeWidget(this.data.list);
|
|
564
|
+
}else{
|
|
565
|
+
this.data.list.forEach(item=>{
|
|
566
|
+
if(item.columns){
|
|
567
|
+
if(findKey(item.columns)){
|
|
568
|
+
item.columns = changeWidget(item.columns);
|
|
569
|
+
}else{
|
|
570
|
+
item.columns.forEach(column=>{
|
|
571
|
+
if(findKey(column.list)){
|
|
572
|
+
column.list = changeWidget(column.list);
|
|
573
|
+
}
|
|
574
|
+
})
|
|
575
|
+
}
|
|
576
|
+
}
|
|
577
|
+
})
|
|
578
|
+
}
|
|
579
|
+
})
|
|
580
|
+
},
|
|
581
|
+
updated() {
|
|
582
|
+
|
|
583
|
+
},
|
|
584
|
+
mounted() {
|
|
585
|
+
|
|
586
|
+
// 回显关联组件
|
|
587
|
+
// setTimeout(() => {
|
|
588
|
+
// this.getchildren()
|
|
589
|
+
// }, 1000)
|
|
590
|
+
// console.log('thisdataObj', this.dataObj)
|
|
591
|
+
// this.generateModle(dataObj.list);
|
|
592
|
+
// if (this.dataObj && this.dataObj.list) {
|
|
593
|
+
// this.rules = {};
|
|
594
|
+
// this.generateModle(this.dataObj.list);
|
|
595
|
+
// }
|
|
596
|
+
|
|
597
|
+
// Pubsub.publish('randomObserve', this.models)
|
|
598
|
+
// console.log('models', this.models)
|
|
599
|
+
// console.log('tableData', this.tableData);
|
|
600
|
+
// console.log('tableModel', this.tableModel)
|
|
601
|
+
// console.log('tableIndex', this.tableIndex)
|
|
602
|
+
// 这里必须放在mounted中,不然h5,支付宝小程序等会找不到this.$refs.form
|
|
603
|
+
// console.log('rules', this.rules)
|
|
604
|
+
// this.$refs.form.setRules(this.rules);
|
|
605
|
+
// this.initPo();
|
|
606
|
+
},
|
|
607
|
+
methods: {
|
|
608
|
+
getUserSignature() {
|
|
609
|
+
if (!this.userSignaturePromise) {
|
|
610
|
+
this.userSignaturePromise = cacheHttp.get('workhall/userseal/queryById')
|
|
611
|
+
}
|
|
612
|
+
return this.userSignaturePromise
|
|
613
|
+
},
|
|
614
|
+
tablePageIndex(model,index){
|
|
615
|
+
return (this.tablePageInfo[model].current - 1) * this.tablePageInfo[model].pageSize + index
|
|
616
|
+
},
|
|
617
|
+
currTablePageData(item) {
|
|
618
|
+
// TODO 处理首次加载页面很多select需要请求远程字典问题(分页,只请求前十条)
|
|
619
|
+
const startPage = (this.tablePageInfo[item.model]?.current - 1)* this.tablePageInfo[item.model]?.pageSize
|
|
620
|
+
const endPage = (this.tablePageInfo[item.model]?.current - 1) * this.tablePageInfo[item.model]?.pageSize + this.tablePageInfo[item.model]?.pageSize
|
|
621
|
+
let pageData = this.tableData[item.model]?.slice(startPage, endPage)
|
|
622
|
+
return pageData
|
|
623
|
+
},
|
|
624
|
+
async tablePageChange(item, page) {
|
|
625
|
+
let pageSize=10;
|
|
626
|
+
await this.$nextTick()
|
|
627
|
+
if (this.tablePageInfo[item.model].pageSize !== pageSize) page = 1
|
|
628
|
+
this.tablePageInfo[item.model].pageSize = pageSize
|
|
629
|
+
await this.$nextTick()
|
|
630
|
+
this.tablePageInfo[item.model].current = page
|
|
631
|
+
await this.$nextTick()
|
|
632
|
+
},
|
|
633
|
+
// 表单联动部分组件并未放入evanFormItem,所以并未订阅相关事件,此方法将相关组件放入订阅模式
|
|
634
|
+
initFormLinkage() {
|
|
635
|
+
if(this.data?.list){
|
|
636
|
+
this.data.list.forEach(item=>{
|
|
637
|
+
if(['verify', 'hnkj-verify', 'hnkj-confirm'].includes(item.type)){
|
|
638
|
+
this.publish_linkage_array.push(Pubsub.subscribe('formLinkage_' + item.model, (key, data) => {
|
|
639
|
+
let onlyKey = key.replace("formLinkage_","");
|
|
640
|
+
if (data.type === 'show') {
|
|
641
|
+
this.data.list = this.data.list.map(l=>{
|
|
642
|
+
if(l.model == onlyKey){
|
|
643
|
+
this.$set(l.options,"canView",data.updateValue);
|
|
644
|
+
}
|
|
645
|
+
return l;
|
|
646
|
+
})
|
|
647
|
+
// this.widget.options.canView = data.updateValue
|
|
648
|
+
}
|
|
649
|
+
if(data.type === "update"){
|
|
650
|
+
if(typeof data.updateValue == "string" && data.updateValue == ""){
|
|
651
|
+
if(onlyKey.indexOf("hnkj_confirm")!=-1){
|
|
652
|
+
this.$set(this.suggestType,onlyKey,"");
|
|
653
|
+
this.models[onlyKey].comments = "";
|
|
654
|
+
this.models[onlyKey].operation = null;
|
|
655
|
+
}
|
|
656
|
+
}
|
|
657
|
+
}
|
|
658
|
+
}))
|
|
659
|
+
}
|
|
660
|
+
})
|
|
661
|
+
}
|
|
662
|
+
},
|
|
663
|
+
changedate(key,value) {
|
|
664
|
+
if(key == 'thrq') {
|
|
665
|
+
this.getThrqList(value)
|
|
666
|
+
} else {
|
|
667
|
+
this.thrqDataModalShow = ''
|
|
668
|
+
}
|
|
669
|
+
},
|
|
670
|
+
getThrqList(value, flag) {
|
|
671
|
+
this.models.zbrq = value
|
|
672
|
+
this.$u.post("zhxyZbb/zhxyZbbZbth", {value:this.models, model: 'zbrq' }).then((res) => {
|
|
673
|
+
if (res.success) {
|
|
674
|
+
this.thrqList = res.result;
|
|
675
|
+
if(!flag) this.models.zbxq = this.thrqList.zbxq
|
|
676
|
+
} else {
|
|
677
|
+
this.thrqList = null
|
|
678
|
+
if(!flag) this.models.zbrq = ''
|
|
679
|
+
if(this.$Route.query.type && this.$Route.query.type === 'detail') {
|
|
680
|
+
|
|
681
|
+
} else {
|
|
682
|
+
uni.showToast({
|
|
683
|
+
title: res.message,
|
|
684
|
+
duration: 2000,
|
|
685
|
+
icon: "none",
|
|
686
|
+
});
|
|
687
|
+
}
|
|
688
|
+
|
|
689
|
+
}
|
|
690
|
+
});
|
|
691
|
+
},
|
|
692
|
+
warpVerifyDisable(widget) {
|
|
693
|
+
if (widget.options.isConfirmComponent) return widget.options.disabled
|
|
694
|
+
return widget.model !== this.verifyNode
|
|
695
|
+
},
|
|
696
|
+
m_isCorrectAudit() {
|
|
697
|
+
return Number(this.isCorrect) === 1 && globalThis._CONFIG.JCTJBT
|
|
698
|
+
},
|
|
699
|
+
updateFormDataToModels() {
|
|
700
|
+
// 将formData 中未绑定表单key 的数据也复制到models
|
|
701
|
+
const modelsKeys = Object.keys(this.models)
|
|
702
|
+
Object.keys(this.value).forEach(key => {
|
|
703
|
+
if (!modelsKeys.includes(key)) {
|
|
704
|
+
this.models[key] = this.value[key]
|
|
705
|
+
}
|
|
706
|
+
})
|
|
707
|
+
},
|
|
708
|
+
verifyLogsList(model) {
|
|
709
|
+
const list = this.verifyLogs[model]
|
|
710
|
+
if (model !== this.verifyNode && list.length >= 1) return list.slice(0, list.length - 1)
|
|
711
|
+
return list
|
|
712
|
+
},
|
|
713
|
+
//回显关联组件的操作
|
|
714
|
+
getchildren() {
|
|
715
|
+
// console.log(this.$children[0])
|
|
716
|
+
// this.handlerelation(this.$children[0].$children)
|
|
717
|
+
},
|
|
718
|
+
// 更新所有组件的值
|
|
719
|
+
updateAllComponentValue() {
|
|
720
|
+
for(const key in this.$refs) {
|
|
721
|
+
this.$refs[key] && [].concat(this.$refs[key]).forEach(item => {
|
|
722
|
+
item.updateDataModel && item.updateDataModel()
|
|
723
|
+
item.showFormData && item.showFormData()
|
|
724
|
+
})
|
|
725
|
+
}
|
|
726
|
+
},
|
|
727
|
+
handlerelation(arr) {
|
|
728
|
+
for (let i = 0; i < arr.length; i++) {
|
|
729
|
+
const item = arr[i]
|
|
730
|
+
if (item.widget && item.widget.type == 'relateSub') {
|
|
731
|
+
if (item.tableKey) {
|
|
732
|
+
item.pulishMsg(
|
|
733
|
+
item.models[item.tableKey][item.tableIndex][item.widget.model],
|
|
734
|
+
true
|
|
735
|
+
)
|
|
736
|
+
} else {
|
|
737
|
+
item.pulishMsg(item.models[item.widget.model], true)
|
|
738
|
+
}
|
|
739
|
+
}
|
|
740
|
+
if (item.widget && item.widget.type == 'table') {
|
|
741
|
+
this.handlerelation(item.$children)
|
|
742
|
+
}
|
|
743
|
+
}
|
|
744
|
+
},
|
|
745
|
+
//更新widget 目前应用于关联组件隐藏 禁用
|
|
746
|
+
upDateWidget(widget, key) {
|
|
747
|
+
console.log(widget.options.canView)
|
|
748
|
+
this.dataObj.list.splice(key, 1, widget)
|
|
749
|
+
},
|
|
750
|
+
//更新widget 目前应用于子表单关联子组件隐藏 禁用
|
|
751
|
+
upDateTableWidget(widget, key, tableKey, tableIndex) {
|
|
752
|
+
this.tableData[tableKey][tableIndex].columns.splice(key, 1, widget)
|
|
753
|
+
},
|
|
754
|
+
//更新widget 目前应用于栅格布局关联子组件隐藏 禁用
|
|
755
|
+
upDateGridWidget(widget) {
|
|
756
|
+
this.data.list.forEach((item, index) => {
|
|
757
|
+
if(item.model == widget.parentModel) {
|
|
758
|
+
let obj = {}
|
|
759
|
+
obj = {...item}
|
|
760
|
+
let idx = obj.columns.findIndex(val => val.list[0].model == widget.model)
|
|
761
|
+
obj.columns[idx].list[0] = widget
|
|
762
|
+
this.$set(this.dataObj.list, index, obj)
|
|
763
|
+
}
|
|
764
|
+
})
|
|
765
|
+
},
|
|
766
|
+
// 打开操作类型选择
|
|
767
|
+
openSuggestSelect(item) {
|
|
768
|
+
const list = this.selectList[item.model] || this.suggest || [];
|
|
769
|
+
if (list.length === 0) return;
|
|
770
|
+
uni.showActionSheet({
|
|
771
|
+
itemList: list.map(opt => opt.label || opt.value),
|
|
772
|
+
success: (res) => {
|
|
773
|
+
this.selectConfirm([list[res.tapIndex]], item);
|
|
774
|
+
}
|
|
775
|
+
});
|
|
776
|
+
},
|
|
777
|
+
// 选择操作类型
|
|
778
|
+
selectConfirm(e, item) {
|
|
779
|
+
const { model, options, type } = item
|
|
780
|
+
let label = ''
|
|
781
|
+
e.map((val, index) => {
|
|
782
|
+
label = val.label;
|
|
783
|
+
this.$set(this.models[model], 'operation', label)
|
|
784
|
+
if (options.isConfirmComponent) {
|
|
785
|
+
this.$set(this.models[model], 'operation', val.value)
|
|
786
|
+
}
|
|
787
|
+
})
|
|
788
|
+
this.$set(this.suggestType, model, label)
|
|
789
|
+
this.fillVerifySignSeal(item)
|
|
790
|
+
|
|
791
|
+
},
|
|
792
|
+
fillVerifySignSeal(widget) {
|
|
793
|
+
const { model, options, type } = widget
|
|
794
|
+
if (options.isConfirmComponent) {
|
|
795
|
+
return this.getUserSignature().then(res => {
|
|
796
|
+
if (res.success) {
|
|
797
|
+
const { userSign } = res?.result || {}
|
|
798
|
+
if (userSign) {
|
|
799
|
+
this.models[model].userSign = userSign
|
|
800
|
+
}
|
|
801
|
+
}
|
|
802
|
+
}).finally(() => {
|
|
803
|
+
this.models[model].loadingSign = false
|
|
804
|
+
})
|
|
805
|
+
return
|
|
806
|
+
}
|
|
807
|
+
if (type === 'hnkj-verify') {
|
|
808
|
+
const select = this.selectList[widget.model].find(item => item.label === this.suggestType[model])
|
|
809
|
+
const { enableSign , enableSeal } = options
|
|
810
|
+
if (select.description === 'TIJIAO') {
|
|
811
|
+
this.models[model].loadingSign = true
|
|
812
|
+
this.getUserSignature().then(res => {
|
|
813
|
+
if (res.success) {
|
|
814
|
+
this.models[model].userSign = enableSign ? res.result.userSign : ''
|
|
815
|
+
if (res.result.userSeal) {
|
|
816
|
+
this.$set(this.sealCache, model, res.result.userSeal)
|
|
817
|
+
} else {
|
|
818
|
+
this.$set(this.sealCache, model, '')
|
|
819
|
+
}
|
|
820
|
+
}
|
|
821
|
+
}).finally(() => {
|
|
822
|
+
this.models[model].loadingSign = false
|
|
823
|
+
})
|
|
824
|
+
} else {
|
|
825
|
+
this.models[model].userSign = ''
|
|
826
|
+
this.models[model].userSeal = ''
|
|
827
|
+
this.$set(this.sealCache, model, '')
|
|
828
|
+
}
|
|
829
|
+
}
|
|
830
|
+
},
|
|
831
|
+
handleVerifySeal(model) {
|
|
832
|
+
const seal = this.sealCache[model]
|
|
833
|
+
if (!seal) return
|
|
834
|
+
this.$set(this.models[model], 'userSeal', seal)
|
|
835
|
+
this.$set(this.models[model], 'userSealPosition', { left: 519, top: 0, width: 120, height: 120 })
|
|
836
|
+
},
|
|
837
|
+
handleVerifySealClose(model) {
|
|
838
|
+
this.$set(this.models[model], 'userSeal', '')
|
|
839
|
+
this.$set(this.models[model], 'userSealPosition', null)
|
|
840
|
+
},
|
|
841
|
+
resolveSealUrl(src) {
|
|
842
|
+
if (!src) return ''
|
|
843
|
+
if (src.startsWith('data:image') || /^https?:\/\//i.test(src)) return src
|
|
844
|
+
return (this.imgUrl || '') + src
|
|
845
|
+
},
|
|
846
|
+
scrollToTop(top) {
|
|
847
|
+
const _this = this
|
|
848
|
+
this.$nextTick(function() {
|
|
849
|
+
uni.createSelectorQuery()
|
|
850
|
+
.in(_this)
|
|
851
|
+
.select('#suggestSelect').boundingClientRect(data => {
|
|
852
|
+
uni.pageScrollTo({
|
|
853
|
+
scrollTop: data.top - top,
|
|
854
|
+
duration: 200
|
|
855
|
+
});
|
|
856
|
+
}).exec()
|
|
857
|
+
})
|
|
858
|
+
},
|
|
859
|
+
//校验审核组件是否为空
|
|
860
|
+
/* checkVerify() {
|
|
861
|
+
if(this.suggestType == '') {
|
|
862
|
+
uni.showToast({
|
|
863
|
+
title: '审核操作不能为空',
|
|
864
|
+
duration: 1000,
|
|
865
|
+
icon: 'none'
|
|
866
|
+
});
|
|
867
|
+
this.scrollToTop()
|
|
868
|
+
}
|
|
869
|
+
}, */
|
|
870
|
+
bindPickerChange(e, model) {
|
|
871
|
+
// console.log('picker发送选择改变,携带值为', e.target.value)
|
|
872
|
+
// console.log(this.suggest)
|
|
873
|
+
this.pickerIndex = e.target.value
|
|
874
|
+
// this.models[model].operation = e.target.value
|
|
875
|
+
this.models[model].operation = this.suggest[e.target.value].value;
|
|
876
|
+
console.log(this.models)
|
|
877
|
+
},
|
|
878
|
+
handlerText(value, model) {
|
|
879
|
+
this.models[model].comments = value
|
|
880
|
+
},
|
|
881
|
+
/***单选修改赋值***/
|
|
882
|
+
selectorOption(picked, model) {
|
|
883
|
+
console.log(picked);
|
|
884
|
+
console.log(model)
|
|
885
|
+
this.models[model].operation = picked.value
|
|
886
|
+
},
|
|
887
|
+
/***option 数据重构**/
|
|
888
|
+
selectDataTransForm(data) {
|
|
889
|
+
|
|
890
|
+
if (!data || (data.length == 0)) {
|
|
891
|
+
return []
|
|
892
|
+
} else {
|
|
893
|
+
return data.map(item => {
|
|
894
|
+
// return {
|
|
895
|
+
// label: item.value,
|
|
896
|
+
// value: item.label
|
|
897
|
+
// }
|
|
898
|
+
return item.value
|
|
899
|
+
})
|
|
900
|
+
}
|
|
901
|
+
},
|
|
902
|
+
/**展开 收起 子表单列**/
|
|
903
|
+
showTableRow(model, index) {
|
|
904
|
+
// uni.createSelectorQuery()
|
|
905
|
+
// .in(this)
|
|
906
|
+
// .select('.table-header').boundingClientRect(data => {
|
|
907
|
+
// console.log("得到布局位置信息" + JSON.stringify(data));
|
|
908
|
+
// console.log("节点离页面顶部的距离为" + data.top);
|
|
909
|
+
// uni.pageScrollTo({
|
|
910
|
+
// scrollTop: data.top,
|
|
911
|
+
// duration: 800
|
|
912
|
+
// });
|
|
913
|
+
// }).exec()
|
|
914
|
+
// this.$set(this.tableFlag,'flag',[true])
|
|
915
|
+
// this.tableFlag.flag = [true];
|
|
916
|
+
// this.tableRowsShow[model][index] = !this.tableRowsShow[model][index];
|
|
917
|
+
this.$set(this.tableRowsShow[model], index, !this.tableRowsShow[model][index]);
|
|
918
|
+
/***解决小程序不能深度监听***/
|
|
919
|
+
var tempObj = cloneObj(this.tableRowsShow)
|
|
920
|
+
// console.log(this.tableRowsShow[model][index],index)
|
|
921
|
+
|
|
922
|
+
// console.log(this.tableRowsShow[model][index])
|
|
923
|
+
},
|
|
924
|
+
//删除子表单row
|
|
925
|
+
handleDeleteRow(index, model) {
|
|
926
|
+
console.log('删除子表单row',index, model)
|
|
927
|
+
// //更新tableData
|
|
928
|
+
//更新models
|
|
929
|
+
this.models[model].splice(index, 1);
|
|
930
|
+
this.tableData[model].splice(index, 1);
|
|
931
|
+
this.tableRowsShow[model].splice(index, 1);
|
|
932
|
+
let _index = 0;
|
|
933
|
+
this.tableData[model].forEach(item => {
|
|
934
|
+
item.index = _index++;
|
|
935
|
+
});
|
|
936
|
+
this.tableIndex[model]--;
|
|
937
|
+
},
|
|
938
|
+
//添加子表单里面的row
|
|
939
|
+
addToTableData(data, model, addModel) {
|
|
940
|
+
let dataTemp = JSON.parse(JSON.stringify(data));
|
|
941
|
+
this.tableIndex[model] === undefined ?
|
|
942
|
+
this.$set(this.tableIndex, model, 0) :
|
|
943
|
+
null;
|
|
944
|
+
dataTemp.index = this.tableIndex[model];
|
|
945
|
+
/***table row show start*/
|
|
946
|
+
this.tableRowsShow[model] === undefined ?
|
|
947
|
+
this.$set(this.tableRowsShow, model, []) :
|
|
948
|
+
null;
|
|
949
|
+
this.$set(this.tableRowsShow[model], this.tableIndex[model], true)
|
|
950
|
+
/***table row show end*/
|
|
951
|
+
this.tableIndex[model]++;
|
|
952
|
+
this.tableData[model] === undefined ?
|
|
953
|
+
this.$set(this.tableData, model, []) :
|
|
954
|
+
null;
|
|
955
|
+
if (addModel) {
|
|
956
|
+
let addModelObject = {};
|
|
957
|
+
dataTemp.columns.forEach(item => {
|
|
958
|
+
item.options.isCorrect = false;
|
|
959
|
+
let defaultValue = item.options.defaultValue
|
|
960
|
+
if (String(defaultValue).startsWith('script:')) {
|
|
961
|
+
defaultValue = ''
|
|
962
|
+
}
|
|
963
|
+
addModelObject[item.model] = item.defaultValue ?
|
|
964
|
+
item.defaultValue :
|
|
965
|
+
defaultValue;
|
|
966
|
+
});
|
|
967
|
+
if(!this.models[model]) this.models[model] = []
|
|
968
|
+
this.models[model].push(addModelObject);
|
|
969
|
+
dataTemp.options.isCorrect = false;
|
|
970
|
+
} else {
|
|
971
|
+
dataTemp.options.isCorrect = true;
|
|
972
|
+
}
|
|
973
|
+
this.tableData[model].push(dataTemp);
|
|
974
|
+
// console.log(this.tableData[model])
|
|
975
|
+
},
|
|
976
|
+
//tableData init
|
|
977
|
+
generateTableData(gen) {
|
|
978
|
+
// console.log('JSON.models',JSON.stringify(this.models))
|
|
979
|
+
// this.tableData = {};
|
|
980
|
+
// this.tableIndex = {};
|
|
981
|
+
this.isShowAdd = true;
|
|
982
|
+
if (gen.type === "table") {
|
|
983
|
+
var tableModel = gen.model;
|
|
984
|
+
if (this.tableData[tableModel] instanceof Array) {
|
|
985
|
+
this.tableData[tableModel].length = 0;
|
|
986
|
+
this.tableIndex[tableModel] = 0;
|
|
987
|
+
}
|
|
988
|
+
this.tableModel[tableModel] = gen;
|
|
989
|
+
this.tableModel[tableModel]["options"]["defaultValue"] = this.models[
|
|
990
|
+
gen.model
|
|
991
|
+
];
|
|
992
|
+
this.tableInitByModel(tableModel);
|
|
993
|
+
if (gen.options.defaultAddRow && !gen.options.disabled && (!this.models[gen.model] || (Array.isArray(this.models[gen.model]) && this.models[gen.model].length === 0))) {
|
|
994
|
+
this.addToTableData(gen, gen.model, 'addModel')
|
|
995
|
+
}
|
|
996
|
+
}
|
|
997
|
+
},
|
|
998
|
+
tableInitByModel(model) {
|
|
999
|
+
if (
|
|
1000
|
+
this.models[model] &&
|
|
1001
|
+
this.models[model] instanceof Array &&
|
|
1002
|
+
this.models[model].length > 0
|
|
1003
|
+
) {
|
|
1004
|
+
console.log('--',this.tableModel[model], model)
|
|
1005
|
+
this.models[model].forEach(async(item, index) => {
|
|
1006
|
+
this.originIndex++;
|
|
1007
|
+
await timeout(0)
|
|
1008
|
+
this.addToTableData(this.tableModel[model], model);
|
|
1009
|
+
});
|
|
1010
|
+
}
|
|
1011
|
+
// console.log('tableData',this.tableData)
|
|
1012
|
+
// console.log(this.models)
|
|
1013
|
+
},
|
|
1014
|
+
async or(...args) {
|
|
1015
|
+
for (const argsKey in args) {
|
|
1016
|
+
if (await args[argsKey]) return true
|
|
1017
|
+
}
|
|
1018
|
+
return false
|
|
1019
|
+
},
|
|
1020
|
+
async and(...args) {
|
|
1021
|
+
for (const argsKey in args) {
|
|
1022
|
+
if (!await args[argsKey]) return false
|
|
1023
|
+
}
|
|
1024
|
+
return true
|
|
1025
|
+
},
|
|
1026
|
+
async handleLinkAge() {
|
|
1027
|
+
// console.log(this.data.config.linkage_config)
|
|
1028
|
+
const that = this
|
|
1029
|
+
if (!this.data?.config?.linkage_config) return
|
|
1030
|
+
if (this.formFunctions) return
|
|
1031
|
+
this.formFunctions = {
|
|
1032
|
+
async call_func(list, models) {
|
|
1033
|
+
const widgetList = getRecursionWidget(that.data.list)
|
|
1034
|
+
const linkageWidget = widgetList.filter(item => list.map(item => item.model).includes(item.model))
|
|
1035
|
+
return list.map(item => this[item.type](models[item.model] ,item.value, linkageWidget.find(widget => widget.model === item.model)))
|
|
1036
|
+
},
|
|
1037
|
+
all_same(currVal, targetVal, widget) {
|
|
1038
|
+
if (Array.isArray(currVal) && Array.isArray(targetVal)) {
|
|
1039
|
+
return intersection(targetVal, currVal).length === targetVal.length
|
|
1040
|
+
}
|
|
1041
|
+
return false
|
|
1042
|
+
},
|
|
1043
|
+
same(currVal, targetVal, widget) {
|
|
1044
|
+
console.log(widget)
|
|
1045
|
+
const { format } = widget.options
|
|
1046
|
+
|
|
1047
|
+
if (widget.type === 'date') {
|
|
1048
|
+
return moment(currVal).format(format) === moment(targetVal).format(format)
|
|
1049
|
+
}
|
|
1050
|
+
if (Array.isArray(currVal)) {
|
|
1051
|
+
if (Array.isArray(targetVal)) {
|
|
1052
|
+
if (currVal.length !== targetVal.length) return false
|
|
1053
|
+
return isEqual(currVal.sort(), targetVal.sort()) || isEqualWith(currVal.sort(), targetVal.sort(), (a, b) => { if (!a.id) return false; return a.id === b.id})
|
|
1054
|
+
}
|
|
1055
|
+
}
|
|
1056
|
+
return currVal == targetVal
|
|
1057
|
+
},
|
|
1058
|
+
not_same(currVal, targetVal, widget) {
|
|
1059
|
+
const { format } = widget.options
|
|
1060
|
+
if (widget.type === 'date') {
|
|
1061
|
+
return moment(currVal).format(format) === moment(targetVal).format(format)
|
|
1062
|
+
}
|
|
1063
|
+
if (Array.isArray(currVal)) {
|
|
1064
|
+
return currVal.every(item => {
|
|
1065
|
+
return targetVal == item?.id || targetVal == item
|
|
1066
|
+
})
|
|
1067
|
+
}
|
|
1068
|
+
return currVal != targetVal
|
|
1069
|
+
},
|
|
1070
|
+
gt(currVal, targetVal, widget) {
|
|
1071
|
+
const { format } = widget.options
|
|
1072
|
+
if (widget.type === 'date') {
|
|
1073
|
+
return moment(currVal).isAfter(moment(targetVal))
|
|
1074
|
+
}
|
|
1075
|
+
return currVal > targetVal
|
|
1076
|
+
},
|
|
1077
|
+
gte(currVal, targetVal, widget) {
|
|
1078
|
+
const { format } = widget.options
|
|
1079
|
+
if (widget.type === 'date') {
|
|
1080
|
+
return moment(currVal).isSameOrAfter(moment(targetVal))
|
|
1081
|
+
}
|
|
1082
|
+
return currVal >= targetVal
|
|
1083
|
+
},
|
|
1084
|
+
lt(currVal, targetVal, widget) {
|
|
1085
|
+
if (widget.type === 'date') {
|
|
1086
|
+
return moment(currVal).isBefore(moment(targetVal))
|
|
1087
|
+
}
|
|
1088
|
+
return currVal < targetVal
|
|
1089
|
+
},
|
|
1090
|
+
lte(currVal, targetVal, widget) {
|
|
1091
|
+
const { format } = widget.options
|
|
1092
|
+
if (widget.type === 'date') {
|
|
1093
|
+
return moment(currVal).isSameOrBefore(moment(targetVal))
|
|
1094
|
+
}
|
|
1095
|
+
return currVal <= targetVal
|
|
1096
|
+
},
|
|
1097
|
+
same_some(currVal, targetVal, widget) {
|
|
1098
|
+
if (Array.isArray(targetVal) && targetVal.includes('[未填写]')) {
|
|
1099
|
+
targetVal = targetVal.concat(undefined, null, '')
|
|
1100
|
+
}
|
|
1101
|
+
if (Array.isArray(currVal) && !currVal.length) currVal = undefined
|
|
1102
|
+
|
|
1103
|
+
return [].concat(currVal).some(item => targetVal.includes(item))
|
|
1104
|
+
// return targetVal.includes(currVal)
|
|
1105
|
+
},
|
|
1106
|
+
not_same_some(currVal, targetVal, widget) {
|
|
1107
|
+
if (Array.isArray(targetVal) && targetVal.includes('[未填写]')) {
|
|
1108
|
+
targetVal = targetVal.concat(undefined, null, '')
|
|
1109
|
+
}
|
|
1110
|
+
if (Array.isArray(currVal) && !currVal.length) currVal = undefined
|
|
1111
|
+
return [].concat(currVal).some(item => !targetVal.includes(item))
|
|
1112
|
+
// return !targetVal.includes(currVal)
|
|
1113
|
+
},
|
|
1114
|
+
EMPTY(currVal, targetVal, widget) {
|
|
1115
|
+
if (Array.isArray(currVal)) return !currVal.length
|
|
1116
|
+
return !currVal
|
|
1117
|
+
},
|
|
1118
|
+
NOT_EMPTY(currVal, targetVal, widget) {
|
|
1119
|
+
if (Array.isArray(currVal)) return !!currVal.length
|
|
1120
|
+
return !!currVal
|
|
1121
|
+
},
|
|
1122
|
+
async include(currVal, targetVal, widget) {
|
|
1123
|
+
if ([undefined, null, ''].includes(currVal)) return false
|
|
1124
|
+
if (['checkbox', 'select', 'radio'].includes(widget.type) && global.dictData[widget.model] == null || Array.isArray(global.dictData[widget.model])) {
|
|
1125
|
+
for (let i = 0; i < 10; i++) {
|
|
1126
|
+
if (Array.isArray(global.dictData[widget.model])) {
|
|
1127
|
+
return global.dictData[widget.model].filter(item => item.value == currVal)?.some( item => item.text.includes(targetVal || undefined) || item.value.includes(targetVal || undefined))
|
|
1128
|
+
}
|
|
1129
|
+
await timeout(300)
|
|
1130
|
+
}
|
|
1131
|
+
}
|
|
1132
|
+
return currVal.includes(targetVal || undefined)
|
|
1133
|
+
},
|
|
1134
|
+
async not_include(currVal, targetVal, widget) {
|
|
1135
|
+
return !(await this.include(currVal, targetVal, widget))
|
|
1136
|
+
},
|
|
1137
|
+
}
|
|
1138
|
+
this.formFunctions._init = true
|
|
1139
|
+
await this.$nextTick()
|
|
1140
|
+
this.initLinkAge();
|
|
1141
|
+
},
|
|
1142
|
+
initLinkAge(){
|
|
1143
|
+
if(this.unwatch){
|
|
1144
|
+
this.unwatch();
|
|
1145
|
+
}
|
|
1146
|
+
this.unwatch = this.$watch('models', async (newVal, oldVal) => {
|
|
1147
|
+
await timeout(0)
|
|
1148
|
+
let diffModels = reduce(newVal, function(result, value, key) {
|
|
1149
|
+
return isEqual(value, oldVal?.[key]) ?
|
|
1150
|
+
result : result.concat(key);
|
|
1151
|
+
}, []);
|
|
1152
|
+
if (!diffModels?.length && (this.formFunctions._init && newVal && oldVal)) {
|
|
1153
|
+
diffModels = Object.keys(newVal)
|
|
1154
|
+
this.formFunctions._init = false
|
|
1155
|
+
}
|
|
1156
|
+
// const differenceObj = difference(cloneDeep(newVal), cloneDeep(oldVal))
|
|
1157
|
+
console.log('diffModels', diffModels)
|
|
1158
|
+
const widgetList = getRecursionWidget(this.data?.list)
|
|
1159
|
+
this.data?.config?.linkage_config?.forEach(item => {
|
|
1160
|
+
let { toTypeSelect, toWidgetList, typeSelect, list, updateValue, hideClearValue, forceClearValue } = item
|
|
1161
|
+
// 表单详情会导致可编辑
|
|
1162
|
+
if (['update', 'disabled'].includes(toTypeSelect) && this.$route?.query?.type === 'detail') return
|
|
1163
|
+
toWidgetList.forEach(async toWidgetModel => {
|
|
1164
|
+
const widget = widgetList.find(item => item.model === toWidgetModel)
|
|
1165
|
+
const changeModelList = list.some(item => diffModels.includes(item.model)) ? list : []
|
|
1166
|
+
if (changeModelList.length === 0) return
|
|
1167
|
+
|
|
1168
|
+
const flag = await this[typeSelect].apply(this, await this.formFunctions.call_func(changeModelList, newVal))
|
|
1169
|
+
switch (toTypeSelect) {
|
|
1170
|
+
case 'show':
|
|
1171
|
+
if (widget.parentType === 'table') {
|
|
1172
|
+
this.$set(widget.options, 'canView', flag)
|
|
1173
|
+
}
|
|
1174
|
+
Pubsub.publish('formLinkage_' + widget.model, {
|
|
1175
|
+
type: 'show',
|
|
1176
|
+
updateValue: flag,
|
|
1177
|
+
})
|
|
1178
|
+
if (!flag && hideClearValue) {
|
|
1179
|
+
/**跳过公文和编号字段的隐藏清空功能 */
|
|
1180
|
+
if(!["editorAirt","codeControl"].includes(widget.type)){
|
|
1181
|
+
Pubsub.publish('formLinkage_' + widget.model, {
|
|
1182
|
+
type: 'update',
|
|
1183
|
+
updateValue: '',
|
|
1184
|
+
})
|
|
1185
|
+
}
|
|
1186
|
+
setTimeout(() => {
|
|
1187
|
+
const isAllFlag = widgetList.filter(item => item.parentModel === widget.parentModel).every( item => item.options.canView === flag)
|
|
1188
|
+
if (!flag && isAllFlag) {
|
|
1189
|
+
// 删除所有行
|
|
1190
|
+
this.tableData = [];
|
|
1191
|
+
this.$set(this.tableIndex,widget.parentModel,0);
|
|
1192
|
+
this.$set(this.models,widget.parentModel,[]);
|
|
1193
|
+
}
|
|
1194
|
+
}, 100)
|
|
1195
|
+
}
|
|
1196
|
+
// this.$set(widget.options, 'canView', flag)
|
|
1197
|
+
// this.data.list = cloneDeep(this.data.list)
|
|
1198
|
+
break
|
|
1199
|
+
case 'required':
|
|
1200
|
+
let rules = this.rules
|
|
1201
|
+
if (widget.parentType === 'table') {
|
|
1202
|
+
if (!rules[widget.parentModel]) rules[widget.parentModel] = {}
|
|
1203
|
+
rules = rules[widget.parentModel]
|
|
1204
|
+
}
|
|
1205
|
+
if (!rules[widget.model]) rules[widget.model] = []
|
|
1206
|
+
const hasRequiredConfig = rules[widget.model].some(item => {
|
|
1207
|
+
if (item?.required !== undefined) {
|
|
1208
|
+
item.required = flag
|
|
1209
|
+
return true
|
|
1210
|
+
}
|
|
1211
|
+
return false
|
|
1212
|
+
})
|
|
1213
|
+
if (!hasRequiredConfig) {
|
|
1214
|
+
if(flag){
|
|
1215
|
+
/**当需要必填时,再推入校验数组 */
|
|
1216
|
+
rules[widget.model].push( {
|
|
1217
|
+
required: flag,
|
|
1218
|
+
trigger: 'change',
|
|
1219
|
+
message: `${(widget.name || "").replaceAll(' ', '')}必须填写`,
|
|
1220
|
+
})
|
|
1221
|
+
}
|
|
1222
|
+
}
|
|
1223
|
+
this.$set(widget.options, 'required', flag)
|
|
1224
|
+
|
|
1225
|
+
!flag && this.$refs.Form.clearValidate(widget.model)
|
|
1226
|
+
|
|
1227
|
+
this.$set(widget, 'rules', rules[widget.model])
|
|
1228
|
+
this.generateRules(widget, this.data?.list?.find(item => item.model === widget.parentModel))
|
|
1229
|
+
break
|
|
1230
|
+
case 'update':
|
|
1231
|
+
updateValue = String(updateValue)
|
|
1232
|
+
if (isNaN(updateValue)) {
|
|
1233
|
+
try {
|
|
1234
|
+
updateValue = JSON.parse(updateValue)
|
|
1235
|
+
} catch (e) {
|
|
1236
|
+
|
|
1237
|
+
}
|
|
1238
|
+
}
|
|
1239
|
+
if (widget.type === 'rate' || widget.type === "number") updateValue = !isNaN(updateValue) ? Number(updateValue) : updateValue
|
|
1240
|
+
// if (['responsibility', 'switch'].includes(widget.type)) updateValue = Boolean(updateValue) || updateValue === 'true'
|
|
1241
|
+
if (widget.parentType === 'table') {
|
|
1242
|
+
if (!Array.isArray(this.models[widget.parentModel])) this.models[widget.parentModel] = []
|
|
1243
|
+
return this.models[widget.parentModel]?.forEach((item,idx) => {
|
|
1244
|
+
this.models[widget.parentModel][idx][widget.model] = flag ? updateValue : ''
|
|
1245
|
+
})
|
|
1246
|
+
}
|
|
1247
|
+
// 不符合时, 如果 未勾选 “不符合时清除值”, 就不用清理
|
|
1248
|
+
if (!flag && !forceClearValue) break
|
|
1249
|
+
Pubsub.publish('formLinkage_' + widget.model, {
|
|
1250
|
+
type: 'update',
|
|
1251
|
+
updateValue: flag ? updateValue : '',
|
|
1252
|
+
})
|
|
1253
|
+
// setTimeout(() => {
|
|
1254
|
+
// this.$set(this.models, widget.model, flag ? updateValue : undefined)
|
|
1255
|
+
// // this.models[widget.model] = flag ? updateValue : ''
|
|
1256
|
+
// }, 1000)
|
|
1257
|
+
break
|
|
1258
|
+
case 'disabled':
|
|
1259
|
+
this.$set(widget.options, 'disabled', flag)
|
|
1260
|
+
break
|
|
1261
|
+
}
|
|
1262
|
+
// 当子表单内容column元素都隐藏时,隐藏整个子表单项
|
|
1263
|
+
this.data.list = this.data.list.map(item=>{
|
|
1264
|
+
if(item.type == "table"){
|
|
1265
|
+
const sum = item.columns.reduce((pre,current)=>{
|
|
1266
|
+
if(!current.options.canView){
|
|
1267
|
+
pre++;
|
|
1268
|
+
}
|
|
1269
|
+
return pre;
|
|
1270
|
+
},0)
|
|
1271
|
+
if(sum == item.columns.length){
|
|
1272
|
+
this.$set(item.options,"canView",false);
|
|
1273
|
+
}else{
|
|
1274
|
+
this.$set(item.options,"canView",true);
|
|
1275
|
+
}
|
|
1276
|
+
}
|
|
1277
|
+
return item;
|
|
1278
|
+
})
|
|
1279
|
+
})
|
|
1280
|
+
|
|
1281
|
+
})
|
|
1282
|
+
},
|
|
1283
|
+
{
|
|
1284
|
+
immediate: true,
|
|
1285
|
+
deep: true
|
|
1286
|
+
})
|
|
1287
|
+
},
|
|
1288
|
+
/***初始化models***/
|
|
1289
|
+
async generateModle(genList) {
|
|
1290
|
+
if (!genList || genList.length === 0) return;
|
|
1291
|
+
this.handleLinkAge()
|
|
1292
|
+
for (let i = 0; i < genList.length; i++) {
|
|
1293
|
+
if (["grid", 'grid-lay-out', 'all-lay-out', 'table'].includes(genList[i].type)) {
|
|
1294
|
+
let subscribeKey = genList[i].options.subscribeOptions ?
|
|
1295
|
+
genList[i].options.subscribeOptions.subscribeKey :
|
|
1296
|
+
'';
|
|
1297
|
+
Pubsub.subscribe(subscribeKey, (msg, data) => {
|
|
1298
|
+
console.log('layout 接受消息', data);
|
|
1299
|
+
const widget = genList[i]
|
|
1300
|
+
const list = data.msg
|
|
1301
|
+
const that = this
|
|
1302
|
+
|
|
1303
|
+
that.isWx = true
|
|
1304
|
+
let global = globalThis
|
|
1305
|
+
// #ifdef H5
|
|
1306
|
+
let operateValue = data.operateValue
|
|
1307
|
+
if(data.operateValue.includes('this.$http')) {
|
|
1308
|
+
operateValue = operateValue.replace(/this\.\$http/g, "this.$u")
|
|
1309
|
+
}
|
|
1310
|
+
eval(operateValue)
|
|
1311
|
+
return
|
|
1312
|
+
// #endif
|
|
1313
|
+
let operateValueWx = data.operateValue
|
|
1314
|
+
if(operateValueWx.includes('this.$http')) {
|
|
1315
|
+
operateValueWx = operateValueWx.replace(/this\.\$http/g, "that.$u")
|
|
1316
|
+
}
|
|
1317
|
+
console.log(run(operateValueWx, {
|
|
1318
|
+
that: this,
|
|
1319
|
+
widget,
|
|
1320
|
+
global: globalThis,
|
|
1321
|
+
list,
|
|
1322
|
+
isWx: true,
|
|
1323
|
+
uni
|
|
1324
|
+
}))
|
|
1325
|
+
});
|
|
1326
|
+
|
|
1327
|
+
}
|
|
1328
|
+
if (["grid", 'grid-lay-out', 'all-lay-out'].includes(genList[i].type)) {
|
|
1329
|
+
genList[i].columns.forEach(item => {
|
|
1330
|
+
this.generateModle(item.list);
|
|
1331
|
+
});
|
|
1332
|
+
} else {
|
|
1333
|
+
|
|
1334
|
+
if (
|
|
1335
|
+
this.value &&
|
|
1336
|
+
Object.keys(this.value).indexOf(genList[i].model) >= 0
|
|
1337
|
+
) {
|
|
1338
|
+
this.models[genList[i].model] = cloneObj(
|
|
1339
|
+
this.value[genList[i].model]
|
|
1340
|
+
);
|
|
1341
|
+
|
|
1342
|
+
console.log(genList[i].type)
|
|
1343
|
+
|
|
1344
|
+
/**审核**/
|
|
1345
|
+
if (["verify", "hnkj-verify"].includes(genList[i].type)) {
|
|
1346
|
+
this.models[genList[i].model] = this.value[genList[i].model];
|
|
1347
|
+
}
|
|
1348
|
+
|
|
1349
|
+
if (genList[i].type === "table") {
|
|
1350
|
+
this.generateTableData(genList[i]); //生成tableModel
|
|
1351
|
+
//设置rules
|
|
1352
|
+
}
|
|
1353
|
+
if (genList[i].type === "hnkj-confirm") {
|
|
1354
|
+
this.$set(this.selectShow, genList[i].model, false)
|
|
1355
|
+
const dictName = genList[i].options.dictName
|
|
1356
|
+
if(typeof this.models[genList[i].model] == "string" && this.models[genList[i].model] == ""){
|
|
1357
|
+
this.models[genList[i].model] = {};
|
|
1358
|
+
}
|
|
1359
|
+
this.$set(this.models[genList[i].model], 'dictName',dictName )
|
|
1360
|
+
if (dictName) cacheHttp.get(`/sys/dict/getDictItems/${dictName}`).then(res => {
|
|
1361
|
+
if (res.success) {
|
|
1362
|
+
this.$set(this.selectList, genList[i].model, res.result?.map(item => ({
|
|
1363
|
+
label: item.title,
|
|
1364
|
+
value: item.value,
|
|
1365
|
+
description: item.value
|
|
1366
|
+
})))
|
|
1367
|
+
const operation = this.models[genList[i].model].operation
|
|
1368
|
+
const label = this.selectList[genList[i].model].find(item => item.value === operation)?.label
|
|
1369
|
+
this.$set(this.models[genList[i].model], 'operationShow',label )
|
|
1370
|
+
this.$set(this.suggestType, genList[i].model, label)
|
|
1371
|
+
}
|
|
1372
|
+
})
|
|
1373
|
+
}
|
|
1374
|
+
} else {
|
|
1375
|
+
|
|
1376
|
+
/**审核**/
|
|
1377
|
+
if (["verify", "hnkj-verify"].includes(genList[i].type)) {
|
|
1378
|
+
this.models[genList[i].model] = genList[i].operationColumns;
|
|
1379
|
+
} else if (genList[i].type === "hnkj-confirm") {
|
|
1380
|
+
this.$set(this.selectShow, genList[i].model, false)
|
|
1381
|
+
if (genList[i].options.isConfirmComponent && !this.warpVerifyDisable(genList[i])) {
|
|
1382
|
+
const dictName = genList[i].options.dictName
|
|
1383
|
+
if (dictName) var res = await cacheHttp.get( `/sys/dict/getDictItems/${dictName}`)
|
|
1384
|
+
if (res.success) {
|
|
1385
|
+
this.$set(this.selectList ,genList[i].model, res.result?.map(item => ({ label: item.title, value: item.value, description: item.value})))
|
|
1386
|
+
}
|
|
1387
|
+
const userInfo = uni.getStorageSync('userinfo')
|
|
1388
|
+
this.$set(
|
|
1389
|
+
this.models,
|
|
1390
|
+
genList[i].model,
|
|
1391
|
+
{
|
|
1392
|
+
comments: '',
|
|
1393
|
+
operation: '',
|
|
1394
|
+
dictName,
|
|
1395
|
+
operator: userInfo.realname || userInfo.username,
|
|
1396
|
+
operationTime: moment().format('YYYY-MM-DD HH:mm:ss'),
|
|
1397
|
+
userSign: ''
|
|
1398
|
+
}
|
|
1399
|
+
)
|
|
1400
|
+
// 确认组件==确认操作默认选中第一项
|
|
1401
|
+
if (genList[i]
|
|
1402
|
+
&& !this.models[genList[i].model].operation
|
|
1403
|
+
&& genList[i].options.confirmOperationChooseFirst) {
|
|
1404
|
+
this.models[genList[i].model].operation = this.selectList[genList[i].model][0]
|
|
1405
|
+
? this.selectList[genList[i].model][0].value
|
|
1406
|
+
: "";
|
|
1407
|
+
this.$set(this.suggestType, genList[i].model, this.models[genList[i].model].operation)
|
|
1408
|
+
this.fillVerifySignSeal(genList[i])
|
|
1409
|
+
}
|
|
1410
|
+
}
|
|
1411
|
+
} else if (genList[i].type === "blank") {
|
|
1412
|
+
this.$set(
|
|
1413
|
+
this.models,
|
|
1414
|
+
genList[i].model,
|
|
1415
|
+
genList[i].options.defaultType === "String" ?
|
|
1416
|
+
"" :
|
|
1417
|
+
genList[i].options.defaultType === "Object" ? {} : []
|
|
1418
|
+
);
|
|
1419
|
+
} else if (genList[i].type === "table") {
|
|
1420
|
+
this.$set(this.models, genList[i].model, this.models[genList[i].model] ?
|
|
1421
|
+
this.models[genList[i].model] :
|
|
1422
|
+
(typeof genList[i].options.defaultValue == "string" ? [] : genList[i].options
|
|
1423
|
+
.defaultValue))
|
|
1424
|
+
this.generateTableData(genList[i]); //生成tableModel
|
|
1425
|
+
} else {
|
|
1426
|
+
// console.log('TO-JSON==',JSON.stringify(this.models));
|
|
1427
|
+
// console.log(genList[i].model);
|
|
1428
|
+
let default_value = !this.dataObj.config.status || this.dataObj.config.status == 'XZ' ? genList[i].options.defaultValue : ''
|
|
1429
|
+
if (String(default_value).startsWith('script:')) {
|
|
1430
|
+
default_value = ''
|
|
1431
|
+
}
|
|
1432
|
+
default_value = default_value ? default_value :
|
|
1433
|
+
'' // 避免默认值为null
|
|
1434
|
+
|
|
1435
|
+
this.$set(this.models, genList[i].model, this.models[genList[i].model] ?
|
|
1436
|
+
this.models[genList[i].model] : default_value
|
|
1437
|
+
)
|
|
1438
|
+
// this.models[genList[i].model] = this.models[genList[i].model] ?
|
|
1439
|
+
// this.models[genList[i].model] :
|
|
1440
|
+
// genList[i].options.defaultValue;
|
|
1441
|
+
}
|
|
1442
|
+
}
|
|
1443
|
+
if (genList[i].type === "table") {
|
|
1444
|
+
var tableRlues = {};
|
|
1445
|
+
if (genList[i].columns.length > 0) {
|
|
1446
|
+
genList[i].columns.forEach(item => {
|
|
1447
|
+
if (item.rules) {
|
|
1448
|
+
tableRlues[item.model] = [
|
|
1449
|
+
...item.rules.map(i => {
|
|
1450
|
+
return {
|
|
1451
|
+
...i
|
|
1452
|
+
};
|
|
1453
|
+
})
|
|
1454
|
+
];
|
|
1455
|
+
}
|
|
1456
|
+
});
|
|
1457
|
+
this.rules[genList[i].model] = tableRlues;
|
|
1458
|
+
}
|
|
1459
|
+
} else {
|
|
1460
|
+
if (this.rules[genList[i].model]) {
|
|
1461
|
+
if (genList[i].rules) {
|
|
1462
|
+
this.$set(this.rules, genList[i].model, [
|
|
1463
|
+
...this.rules[genList[i].model],
|
|
1464
|
+
...genList[i].rules.map(item => {
|
|
1465
|
+
return {
|
|
1466
|
+
...item
|
|
1467
|
+
};
|
|
1468
|
+
})
|
|
1469
|
+
]);
|
|
1470
|
+
// this.rules[genList[i].model] = [
|
|
1471
|
+
// ...this.rules[genList[i].model],
|
|
1472
|
+
// ...genList[i].rules.map(item => {
|
|
1473
|
+
// return {
|
|
1474
|
+
// ...item
|
|
1475
|
+
// };
|
|
1476
|
+
// })
|
|
1477
|
+
// ];
|
|
1478
|
+
}
|
|
1479
|
+
} else {
|
|
1480
|
+
if (genList[i].rules) {
|
|
1481
|
+
this.rules[genList[i].model] = [
|
|
1482
|
+
...genList[i].rules.map(item => {
|
|
1483
|
+
return {
|
|
1484
|
+
...item
|
|
1485
|
+
};
|
|
1486
|
+
})
|
|
1487
|
+
];
|
|
1488
|
+
}
|
|
1489
|
+
}
|
|
1490
|
+
}
|
|
1491
|
+
}
|
|
1492
|
+
}
|
|
1493
|
+
this.$nextTick(() => {
|
|
1494
|
+
this.$emit('formUpdated')
|
|
1495
|
+
})
|
|
1496
|
+
},
|
|
1497
|
+
generateRules(widget, parentWidget) {
|
|
1498
|
+
if (parentWidget && parentWidget.columns) {
|
|
1499
|
+
if (!this.rules[parentWidget.model]) this.rules[parentWidget.model] = {}
|
|
1500
|
+
this.rules[parentWidget.model][widget.model] = widget.rules;
|
|
1501
|
+
this.rules = cloneDeep(this.rules)
|
|
1502
|
+
return
|
|
1503
|
+
}
|
|
1504
|
+
this.$set(this.rules, widget.model, widget.rules)
|
|
1505
|
+
this.rules = cloneDeep(this.rules)
|
|
1506
|
+
},
|
|
1507
|
+
validateTable() {
|
|
1508
|
+
|
|
1509
|
+
// 查找所有的table 子表单的配置组件
|
|
1510
|
+
const findTableComponent = (list = []) => {
|
|
1511
|
+
return list.reduce((all, curr) => {
|
|
1512
|
+
if (Array.isArray(curr)) {
|
|
1513
|
+
return all.concat(findTableComponent(curr))
|
|
1514
|
+
}
|
|
1515
|
+
if (curr.type === 'table') return all.concat(curr)
|
|
1516
|
+
return all
|
|
1517
|
+
}, [])
|
|
1518
|
+
}
|
|
1519
|
+
// 判断子表单内组件有没有必填的校验
|
|
1520
|
+
const tables = findTableComponent(this.dataObj.list).filter(table => {
|
|
1521
|
+
if ([table.options.canView, !table.options.disabled].includes(false)) return
|
|
1522
|
+
const { columns = [] } = table
|
|
1523
|
+
for (let i = 0; i < columns.length; i++) {
|
|
1524
|
+
const { rules = [] } = columns[i]
|
|
1525
|
+
if (rules.some(rule => rule.required)) return true
|
|
1526
|
+
if (columns[i].options?.minValue) return true
|
|
1527
|
+
}
|
|
1528
|
+
})
|
|
1529
|
+
// 子表单有必填校验 判断有没有添加行, 没有添加行需要手动添加行, 让它触发校验
|
|
1530
|
+
// tables.forEach(table => {
|
|
1531
|
+
// if (!table.options.requiredAddDefaultRow) return
|
|
1532
|
+
// const model = this.models[table.model]
|
|
1533
|
+
// if ( !model || ( Array.isArray(model) && model.length === 0 )) {
|
|
1534
|
+
// this.addToTableData(table, table.model, 'addModel')
|
|
1535
|
+
// }
|
|
1536
|
+
// })
|
|
1537
|
+
},
|
|
1538
|
+
/**
|
|
1539
|
+
* @param {回调函数} fn 成功的回调函数
|
|
1540
|
+
* */
|
|
1541
|
+
async getData(fn) {
|
|
1542
|
+
if (typeof fn !== 'function') return
|
|
1543
|
+
this.validateTable()
|
|
1544
|
+
|
|
1545
|
+
if (this.verifyNode && this.models[this.verifyNode]?.loadingSign) {
|
|
1546
|
+
uni.showToast({
|
|
1547
|
+
title: '签名图片获取中',
|
|
1548
|
+
icon: 'none',
|
|
1549
|
+
duration: 1500
|
|
1550
|
+
})
|
|
1551
|
+
fn('failed')
|
|
1552
|
+
return
|
|
1553
|
+
}
|
|
1554
|
+
await this.$nextTick()
|
|
1555
|
+
|
|
1556
|
+
const promiseArr = []
|
|
1557
|
+
for (const i in this.$refs) {
|
|
1558
|
+
if (i === 'Form') continue
|
|
1559
|
+
const refs = this.$refs[i]
|
|
1560
|
+
const refList = (refs instanceof Array || refs?.constructor === Array) ? refs : [refs]
|
|
1561
|
+
refList.forEach(refItem => {
|
|
1562
|
+
if (!refItem?.validateInit || typeof refItem.validateInit !== 'function') return
|
|
1563
|
+
const widget = refItem._props?.widget || refItem.$props?.widget
|
|
1564
|
+
if (!widget?.options) return
|
|
1565
|
+
const { canView, disabled } = widget.options
|
|
1566
|
+
if (!canView || (disabled && !this.m_isCorrectAudit())) return
|
|
1567
|
+
promiseArr.push(refItem.validateInit().then(() => {}).catch((error) => {
|
|
1568
|
+
if (this.isScroll && error === false) {
|
|
1569
|
+
this.isScroll = false
|
|
1570
|
+
uni.createSelectorQuery()
|
|
1571
|
+
.in(this)
|
|
1572
|
+
.select('.evan-form-show').boundingClientRect(data => {
|
|
1573
|
+
refItem.scrollToTop(data.top)
|
|
1574
|
+
}).exec()
|
|
1575
|
+
}
|
|
1576
|
+
throw new Error(error)
|
|
1577
|
+
}))
|
|
1578
|
+
})
|
|
1579
|
+
}
|
|
1580
|
+
promiseArr.push(this.validateVerifyWidgets())
|
|
1581
|
+
|
|
1582
|
+
try {
|
|
1583
|
+
await Promise.all(promiseArr)
|
|
1584
|
+
fn(this.models)
|
|
1585
|
+
} catch (error) {
|
|
1586
|
+
fn('failed')
|
|
1587
|
+
console.log(error)
|
|
1588
|
+
}
|
|
1589
|
+
},
|
|
1590
|
+
validateVerifyWidgets() {
|
|
1591
|
+
return new Promise((resolve, reject) => {
|
|
1592
|
+
// 发起申请场景(processGuide/appApply)不校验审核/确认组件
|
|
1593
|
+
if (this.isApply && !this.verifyNode) {
|
|
1594
|
+
resolve()
|
|
1595
|
+
return
|
|
1596
|
+
}
|
|
1597
|
+
const widgets = (this.dataObj?.list || []).filter(obj => {
|
|
1598
|
+
if (obj.model === this.verifyNode) return true
|
|
1599
|
+
if (obj.type === 'hnkj-confirm' && obj.options.canView && !obj.options.disabled) {
|
|
1600
|
+
return !this.warpVerifyDisable(obj)
|
|
1601
|
+
}
|
|
1602
|
+
return false
|
|
1603
|
+
})
|
|
1604
|
+
if (!widgets.length) {
|
|
1605
|
+
resolve()
|
|
1606
|
+
return
|
|
1607
|
+
}
|
|
1608
|
+
let finished = 0
|
|
1609
|
+
let hasError = false
|
|
1610
|
+
widgets.forEach(widget => {
|
|
1611
|
+
const item = this.models[widget.model]
|
|
1612
|
+
if (!item) {
|
|
1613
|
+
finished++
|
|
1614
|
+
if (finished === widgets.length && !hasError) resolve()
|
|
1615
|
+
return
|
|
1616
|
+
}
|
|
1617
|
+
const rules = {
|
|
1618
|
+
comments: widget.type === 'hnkj-confirm'
|
|
1619
|
+
? (widget.options.isConfirmComponent
|
|
1620
|
+
? [{ required: widget.options.confirmOpinionRequire, message: '请输入确认意见' }]
|
|
1621
|
+
: [{ required: widget.options.required, message: widget.options.placeholder }])
|
|
1622
|
+
: [{ required: widget.options.opinionRequire, message: '请输入审批意见' }],
|
|
1623
|
+
operation: widget.type === 'hnkj-confirm'
|
|
1624
|
+
? [{ required: widget.options.required, message: `请选择${widget.options.operation}` }]
|
|
1625
|
+
: []
|
|
1626
|
+
}
|
|
1627
|
+
utils.validateField(item, rules, Object.keys(rules), (success) => {
|
|
1628
|
+
finished++
|
|
1629
|
+
if (!success) hasError = true
|
|
1630
|
+
if (finished === widgets.length) {
|
|
1631
|
+
hasError ? reject(hasError) : resolve()
|
|
1632
|
+
}
|
|
1633
|
+
}, {
|
|
1634
|
+
showMessage: true
|
|
1635
|
+
})
|
|
1636
|
+
})
|
|
1637
|
+
})
|
|
1638
|
+
},
|
|
1639
|
+
saveForm2() {
|
|
1640
|
+
|
|
1641
|
+
// this.$refs.form2.validate((res) => {
|
|
1642
|
+
// if (res) {
|
|
1643
|
+
// uni.showToast({
|
|
1644
|
+
// title: '验证通过'
|
|
1645
|
+
// })
|
|
1646
|
+
// }
|
|
1647
|
+
// })
|
|
1648
|
+
},
|
|
1649
|
+
utilsSave() {
|
|
1650
|
+
utils.validate(this.info, this.rules, (res, errors) => {
|
|
1651
|
+
if (res) {
|
|
1652
|
+
uni.showToast({
|
|
1653
|
+
title: '验证通过'
|
|
1654
|
+
})
|
|
1655
|
+
}
|
|
1656
|
+
})
|
|
1657
|
+
},
|
|
1658
|
+
hideReqired() {
|
|
1659
|
+
this.hideRequiredAsterisk = !this.hideRequiredAsterisk
|
|
1660
|
+
},
|
|
1661
|
+
},
|
|
1662
|
+
destroyed() {
|
|
1663
|
+
Pubsub.unsubscribe(this.updateWidget);
|
|
1664
|
+
if(this.publish_linkage_array.length > 0){
|
|
1665
|
+
this.publish_linkage_array.forEach(item=>{
|
|
1666
|
+
Pubsub.unsubscribe(item);
|
|
1667
|
+
})
|
|
1668
|
+
this.publish_linkage_array = [];
|
|
1669
|
+
}
|
|
1670
|
+
},
|
|
1671
|
+
}
|
|
1672
|
+
</script>
|
|
1673
|
+
|
|
1674
|
+
<style lang="scss">
|
|
1675
|
+
@import "../../static/iconfont.css";
|
|
1676
|
+
$mybottom: 0; //底部按钮
|
|
1677
|
+
|
|
1678
|
+
/**审核组件样式**/
|
|
1679
|
+
.verify {
|
|
1680
|
+
position: relative;
|
|
1681
|
+
font-size: 28upx;
|
|
1682
|
+
}
|
|
1683
|
+
|
|
1684
|
+
.verify-step {
|
|
1685
|
+
height: 90upx;
|
|
1686
|
+
line-height: 90upx;
|
|
1687
|
+
padding-left: $uni-form-padding-left;
|
|
1688
|
+
font-size: $uni-form-title-font-size;
|
|
1689
|
+
}
|
|
1690
|
+
|
|
1691
|
+
.verify-cot {
|
|
1692
|
+
background-color: #fff;
|
|
1693
|
+
padding: 20upx $uni-form-padding-left;
|
|
1694
|
+
display: flex;
|
|
1695
|
+
justify-content: space-between;
|
|
1696
|
+
align-items: center;
|
|
1697
|
+
|
|
1698
|
+
m-textarea, .textarea-wrapper {
|
|
1699
|
+
display: block;
|
|
1700
|
+
width: 100%;
|
|
1701
|
+
height: 120rpx;
|
|
1702
|
+
padding-top: 20rpx;
|
|
1703
|
+
}
|
|
1704
|
+
|
|
1705
|
+
>view {
|
|
1706
|
+
height: 50upx;
|
|
1707
|
+
line-height: 50upx;
|
|
1708
|
+
}
|
|
1709
|
+
|
|
1710
|
+
>view+view {
|
|
1711
|
+
height: 70upx;
|
|
1712
|
+
line-height: 70upx;
|
|
1713
|
+
font-size: $uni-form-content-font-size;
|
|
1714
|
+
}
|
|
1715
|
+
|
|
1716
|
+
.verify-title {
|
|
1717
|
+
// 一行
|
|
1718
|
+
overflow: hidden;
|
|
1719
|
+
margin-right: 10rpx;
|
|
1720
|
+
text-overflow: ellipsis;
|
|
1721
|
+
display: -webkit-box;
|
|
1722
|
+
-webkit-line-clamp: 1;
|
|
1723
|
+
-webkit-box-orient: vertical;
|
|
1724
|
+
// font-weight: bold;
|
|
1725
|
+
font-size: $uni-form-title-font-size;
|
|
1726
|
+
}
|
|
1727
|
+
}
|
|
1728
|
+
|
|
1729
|
+
.verify-seal {
|
|
1730
|
+
position: absolute;
|
|
1731
|
+
left: 200rpx;
|
|
1732
|
+
top: 260rpx;
|
|
1733
|
+
width: 260rpx;
|
|
1734
|
+
height: 260rpx;
|
|
1735
|
+
z-index: 10;
|
|
1736
|
+
}
|
|
1737
|
+
|
|
1738
|
+
.verify-seal__img {
|
|
1739
|
+
width: 100%;
|
|
1740
|
+
height: 100%;
|
|
1741
|
+
}
|
|
1742
|
+
|
|
1743
|
+
.verify-seal__close {
|
|
1744
|
+
position: absolute;
|
|
1745
|
+
top: -16rpx;
|
|
1746
|
+
right: -16rpx;
|
|
1747
|
+
width: 36rpx;
|
|
1748
|
+
height: 36rpx;
|
|
1749
|
+
background: rgba(0,0,0,0.4);
|
|
1750
|
+
border-radius: 50%;
|
|
1751
|
+
display: flex;
|
|
1752
|
+
align-items: center;
|
|
1753
|
+
justify-content: center;
|
|
1754
|
+
}
|
|
1755
|
+
|
|
1756
|
+
.verify-seal__close-text {
|
|
1757
|
+
color: #fff;
|
|
1758
|
+
font-size: 22rpx;
|
|
1759
|
+
line-height: 1;
|
|
1760
|
+
}
|
|
1761
|
+
|
|
1762
|
+
.verify-seal-btn {
|
|
1763
|
+
padding: 10rpx 24rpx;
|
|
1764
|
+
color: #0599d7;
|
|
1765
|
+
font-size: 26rpx;
|
|
1766
|
+
text-align: right;
|
|
1767
|
+
background-color: #fff;
|
|
1768
|
+
}
|
|
1769
|
+
|
|
1770
|
+
@include onepx('.verify-cot', 'bottom', 'after', #e6e6e6);
|
|
1771
|
+
|
|
1772
|
+
.table-header {
|
|
1773
|
+
min-height: 86upx;
|
|
1774
|
+
line-height: 86upx;
|
|
1775
|
+
padding: 0 30upx;
|
|
1776
|
+
font-weight: bold;
|
|
1777
|
+
font-size: $uni-form-title-font-size;
|
|
1778
|
+
}
|
|
1779
|
+
|
|
1780
|
+
.table-wrapper {
|
|
1781
|
+
margin: 0 auto 20upx auto;
|
|
1782
|
+
}
|
|
1783
|
+
|
|
1784
|
+
.table-container {
|
|
1785
|
+
background-color: #ffffff;
|
|
1786
|
+
font-size: $uni-form-title-font-size;
|
|
1787
|
+
|
|
1788
|
+
.view-port {}
|
|
1789
|
+
|
|
1790
|
+
.add {
|
|
1791
|
+
color: #539dfa;
|
|
1792
|
+
text-align: center;
|
|
1793
|
+
height: 90upx;
|
|
1794
|
+
line-height: 90upx;
|
|
1795
|
+
font-size: $uni-form-content-font-size;
|
|
1796
|
+
}
|
|
1797
|
+
|
|
1798
|
+
.item {
|
|
1799
|
+
display: flex;
|
|
1800
|
+
height: 90upx;
|
|
1801
|
+
line-height: 90upx;
|
|
1802
|
+
justify-content: space-around;
|
|
1803
|
+
|
|
1804
|
+
>view {
|
|
1805
|
+
line-height: 90upx;
|
|
1806
|
+
color: #9b9b9b;
|
|
1807
|
+
text-indent: 10%;
|
|
1808
|
+
font-size: $uni-form-content-font-size;
|
|
1809
|
+
flex: 1;
|
|
1810
|
+
min-width: 130rpx;
|
|
1811
|
+
}
|
|
1812
|
+
|
|
1813
|
+
>view+view {
|
|
1814
|
+
flex-shrink: 18;
|
|
1815
|
+
}
|
|
1816
|
+
}
|
|
1817
|
+
|
|
1818
|
+
@include onepx('.item', 'bottom', 'after', #eeeeee);
|
|
1819
|
+
}
|
|
1820
|
+
|
|
1821
|
+
.evan-form-show {
|
|
1822
|
+
padding-bottom: $mybottom;
|
|
1823
|
+
// padding-bottom: $mybottom;
|
|
1824
|
+
// padding: 0 30rpx;
|
|
1825
|
+
background-color: #efefef;
|
|
1826
|
+
|
|
1827
|
+
.form-input {
|
|
1828
|
+
font-size: 28rpx;
|
|
1829
|
+
color: #333;
|
|
1830
|
+
//text-align: right;
|
|
1831
|
+
width: 100%;
|
|
1832
|
+
box-sizing: border-box;
|
|
1833
|
+
|
|
1834
|
+
&.textarea {
|
|
1835
|
+
height: 240rpx;
|
|
1836
|
+
padding: 24rpx 0;
|
|
1837
|
+
text-align: left;
|
|
1838
|
+
}
|
|
1839
|
+
}
|
|
1840
|
+
|
|
1841
|
+
.form-input-placeholder {
|
|
1842
|
+
font-size: $uni-form-content-font-size;
|
|
1843
|
+
color: #999;
|
|
1844
|
+
}
|
|
1845
|
+
|
|
1846
|
+
&__button {
|
|
1847
|
+
width: 100%;
|
|
1848
|
+
height: 88rpx;
|
|
1849
|
+
border-radius: 8rpx;
|
|
1850
|
+
display: flex;
|
|
1851
|
+
align-items: center;
|
|
1852
|
+
justify-content: center;
|
|
1853
|
+
padding: 0;
|
|
1854
|
+
font-size: 36rpx;
|
|
1855
|
+
color: #fff;
|
|
1856
|
+
margin-top: 20rpx;
|
|
1857
|
+
background-color: #2D87D5;
|
|
1858
|
+
|
|
1859
|
+
&::before,
|
|
1860
|
+
&::after {
|
|
1861
|
+
border: none;
|
|
1862
|
+
}
|
|
1863
|
+
}
|
|
1864
|
+
|
|
1865
|
+
.customize-form-item {
|
|
1866
|
+
&__label {
|
|
1867
|
+
font-size: 28rpx;
|
|
1868
|
+
color: #333;
|
|
1869
|
+
margin-bottom: 16rpx;
|
|
1870
|
+
}
|
|
1871
|
+
|
|
1872
|
+
&__radio {
|
|
1873
|
+
display: flex;
|
|
1874
|
+
align-items: center;
|
|
1875
|
+
margin-bottom: 16rpx;
|
|
1876
|
+
|
|
1877
|
+
&__text {
|
|
1878
|
+
font-size: 28rpx;
|
|
1879
|
+
color: #333;
|
|
1880
|
+
}
|
|
1881
|
+
}
|
|
1882
|
+
}
|
|
1883
|
+
}
|
|
1884
|
+
|
|
1885
|
+
.fixed {
|
|
1886
|
+
position: fixed;
|
|
1887
|
+
z-index: 20;
|
|
1888
|
+
border-top: 1upx solid #eee;
|
|
1889
|
+
background-color: #539dfa;
|
|
1890
|
+
height: $mybottom;
|
|
1891
|
+
width: 100%;
|
|
1892
|
+
left: 0;
|
|
1893
|
+
bottom: 0;
|
|
1894
|
+
font-size: 30upx;
|
|
1895
|
+
color: #fff;
|
|
1896
|
+
display: flex;
|
|
1897
|
+
justify-content: center;
|
|
1898
|
+
align-items: center;
|
|
1899
|
+
}
|
|
1900
|
+
|
|
1901
|
+
cover-view button {
|
|
1902
|
+
letter-spacing: 20upx;
|
|
1903
|
+
background-color: #539dfa;
|
|
1904
|
+
font-size: 30upx;
|
|
1905
|
+
color: #fff;
|
|
1906
|
+
}
|
|
1907
|
+
|
|
1908
|
+
cover-view button::after {
|
|
1909
|
+
border: none;
|
|
1910
|
+
}
|
|
1911
|
+
|
|
1912
|
+
|
|
1913
|
+
|
|
1914
|
+
|
|
1915
|
+
.uni-input {
|
|
1916
|
+
padding: 5rpx 0;
|
|
1917
|
+
}
|
|
1918
|
+
.form-input-suggest {
|
|
1919
|
+
padding: 10rpx 22rpx;
|
|
1920
|
+
background-color: #ecf5fc;
|
|
1921
|
+
border-radius: 20rpx;
|
|
1922
|
+
color: #348cd2;
|
|
1923
|
+
margin-right: 20rpx;
|
|
1924
|
+
}
|
|
1925
|
+
</style>
|