htui-yllkbz 1.3.32 → 1.3.34
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/htui.common.js +110 -102
- package/lib/htui.common.js.gz +0 -0
- package/lib/htui.css +1 -1
- package/lib/htui.umd.js +110 -102
- package/lib/htui.umd.js.gz +0 -0
- package/lib/htui.umd.min.js +2 -2
- package/lib/htui.umd.min.js.gz +0 -0
- package/package.json +1 -1
- package/src/packages/HtBaseData/index.vue +240 -194
- package/src/packages/HtSelectBaseData/index.vue +39 -33
- package/src/packages/HtSelectOrg/index.vue +26 -22
- package/src/packages/HtSelectUser/index.vue +26 -22
|
@@ -1,24 +1,26 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div>
|
|
3
|
-
|
|
4
3
|
<!-- 选择部门 -->
|
|
5
|
-
<template
|
|
4
|
+
<template
|
|
5
|
+
v-if="
|
|
6
6
|
state.configJson['departmentId'] &&
|
|
7
|
-
|
|
8
|
-
"
|
|
7
|
+
state.configJson['departmentId'].show
|
|
8
|
+
"
|
|
9
|
+
>
|
|
9
10
|
<!-- multiple: state.configJson['departmentId'].multiple, -->
|
|
10
|
-
<el-cascader
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
11
|
+
<el-cascader
|
|
12
|
+
v-if="!state.configJson['departmentId'].panel"
|
|
13
|
+
:disabled="!!disabled"
|
|
14
|
+
class="component-item"
|
|
15
|
+
:class="comClass"
|
|
16
|
+
:style="comStyle || ''"
|
|
17
|
+
:filterable="!state.configJson['departmentId'].multiple"
|
|
18
|
+
:clearable="state.configJson['departmentId'].clearable"
|
|
19
|
+
:placeholder="`请选择部门`"
|
|
20
|
+
:collapse-tags="state.configJson['departmentId'].collapseTags"
|
|
21
|
+
v-model="state.selectVal['departmentId']"
|
|
22
|
+
:show-all-levels="state.configJson['departmentId'].showAllLevels"
|
|
23
|
+
:props="{
|
|
22
24
|
label: 'name',
|
|
23
25
|
value: 'id',
|
|
24
26
|
children: 'children',
|
|
@@ -27,18 +29,20 @@
|
|
|
27
29
|
checkStrictly: state.configJson['departmentId'].checkStrictly,
|
|
28
30
|
multiple: state.configJson['departmentId'].multiple,
|
|
29
31
|
}"
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
32
|
+
@click.native="selectClick($event)"
|
|
33
|
+
ref="departmentId"
|
|
34
|
+
@change="setSelctData('departmentId', $event)"
|
|
35
|
+
:options="organizationUsersTree"
|
|
36
|
+
>
|
|
34
37
|
</el-cascader>
|
|
35
|
-
<el-cascader-panel
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
38
|
+
<el-cascader-panel
|
|
39
|
+
v-if="state.configJson['departmentId'].panel"
|
|
40
|
+
class="component-item"
|
|
41
|
+
:class="comClass"
|
|
42
|
+
:style="comStyle || ''"
|
|
43
|
+
:placeholder="`请选择部门`"
|
|
44
|
+
v-model="state.selectVal['departmentId']"
|
|
45
|
+
:props="{
|
|
42
46
|
label: 'name',
|
|
43
47
|
value: 'id',
|
|
44
48
|
children: 'children',
|
|
@@ -47,43 +51,52 @@
|
|
|
47
51
|
checkStrictly: state.configJson['departmentId'].checkStrictly,
|
|
48
52
|
multiple: state.configJson['departmentId'].multiple,
|
|
49
53
|
}"
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
54
|
+
ref="departmentId"
|
|
55
|
+
@change="setSelctData('departmentId', $event)"
|
|
56
|
+
:options="organizationUsersTree"
|
|
57
|
+
>
|
|
53
58
|
<template slot-scope="{ data }">
|
|
54
59
|
<span>{{ data.label }}</span>
|
|
55
60
|
</template>
|
|
56
61
|
</el-cascader-panel>
|
|
57
62
|
</template>
|
|
58
63
|
<!-- 选择人员 -->
|
|
59
|
-
<el-select
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
64
|
+
<el-select
|
|
65
|
+
v-model="state.selectVal['userId']"
|
|
66
|
+
placeholder="请选择人员"
|
|
67
|
+
:filterable="!state.configJson['userId'].multiple"
|
|
68
|
+
:disabled="!!disabled"
|
|
69
|
+
:style="comStyle || ''"
|
|
70
|
+
class="component-item"
|
|
71
|
+
@click.native="selectClick($event)"
|
|
72
|
+
v-if="state.configJson['userId'] && state.configJson['userId'].show"
|
|
73
|
+
:multiple="state.configJson['userId'].multiple"
|
|
74
|
+
>
|
|
75
|
+
<el-option
|
|
76
|
+
v-for="item in userDataList"
|
|
77
|
+
:key="item.id"
|
|
78
|
+
:label="item.value"
|
|
79
|
+
:value="item.id"
|
|
80
|
+
:title="`所在部门:${item.organizationNames}`"
|
|
81
|
+
>
|
|
73
82
|
<span>
|
|
74
|
-
<p
|
|
75
|
-
|
|
83
|
+
<p
|
|
84
|
+
class="ht-user-dot"
|
|
85
|
+
:class="
|
|
76
86
|
item.dutyOfficer && !item.dutyOfficer.status
|
|
77
87
|
? 'ht-user-dot-disabled'
|
|
78
88
|
: ''
|
|
79
89
|
"
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
90
|
+
v-if="item.dutyOfficer"
|
|
91
|
+
></p>
|
|
92
|
+
<p
|
|
93
|
+
class="ht-user-name"
|
|
94
|
+
:class="
|
|
83
95
|
item.dutyOfficer && !item.dutyOfficer.status
|
|
84
96
|
? 'ht-user-disabled'
|
|
85
97
|
: ''
|
|
86
|
-
"
|
|
98
|
+
"
|
|
99
|
+
>
|
|
87
100
|
{{ item.value
|
|
88
101
|
}}<span v-if="item.phoneNumber"> ({{ item.phoneNumber }}) </span>
|
|
89
102
|
</p>
|
|
@@ -91,22 +104,25 @@
|
|
|
91
104
|
</el-option>
|
|
92
105
|
</el-select>
|
|
93
106
|
<!-- 选择部门下人员 -->
|
|
94
|
-
<template
|
|
107
|
+
<template
|
|
108
|
+
v-if="
|
|
95
109
|
state.configJson['departmentUser'] &&
|
|
96
|
-
|
|
97
|
-
"
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
+
state.configJson['departmentUser'].show
|
|
111
|
+
"
|
|
112
|
+
>
|
|
113
|
+
<el-cascader
|
|
114
|
+
v-if="!state.configJson['departmentUser'].panel"
|
|
115
|
+
:disabled="!!disabled"
|
|
116
|
+
class="component-item"
|
|
117
|
+
:filterable="!state.configJson['departmentUser'].multiple"
|
|
118
|
+
:class="comClass"
|
|
119
|
+
:style="comStyle || ''"
|
|
120
|
+
:clearable="state.configJson['departmentUser'].clearable"
|
|
121
|
+
:placeholder="`请选择部门下人员`"
|
|
122
|
+
:collapse-tags="state.configJson['departmentUser'].collapseTags"
|
|
123
|
+
v-model="state.selectVal['departmentUser']"
|
|
124
|
+
:show-all-levels="state.configJson['departmentUser'].showAllLevels"
|
|
125
|
+
:props="{
|
|
110
126
|
label: 'name',
|
|
111
127
|
value: 'id',
|
|
112
128
|
children: 'childrenList',
|
|
@@ -115,13 +131,15 @@
|
|
|
115
131
|
checkStrictly: state.configJson['departmentUser'].checkStrictly,
|
|
116
132
|
multiple: state.configJson['departmentUser'].multiple,
|
|
117
133
|
}"
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
134
|
+
ref="departmentUser"
|
|
135
|
+
@click.native="selectClick($event)"
|
|
136
|
+
@change="setSelctData('departmentUser', $event)"
|
|
137
|
+
:options="organizationUsersTreeUser"
|
|
138
|
+
>
|
|
122
139
|
<template slot-scope="{ data }">
|
|
123
|
-
<p
|
|
124
|
-
|
|
140
|
+
<p
|
|
141
|
+
class="ht-user-dot"
|
|
142
|
+
style="
|
|
125
143
|
padding: 0;
|
|
126
144
|
margin: 0;
|
|
127
145
|
float: left;
|
|
@@ -133,28 +151,32 @@
|
|
|
133
151
|
border-radius: 10px;
|
|
134
152
|
margin-right: 4px;
|
|
135
153
|
"
|
|
136
|
-
|
|
154
|
+
:style="
|
|
137
155
|
data.dutyOfficer && !data.dutyOfficer.status
|
|
138
156
|
? 'background: #ccc;'
|
|
139
157
|
: ''
|
|
140
158
|
"
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
159
|
+
v-if="data.dutyOfficer"
|
|
160
|
+
></p>
|
|
161
|
+
<p
|
|
162
|
+
class="ht-user-name"
|
|
163
|
+
style="padding: 0; margin: 0; float: left"
|
|
164
|
+
:style="
|
|
145
165
|
data.dutyOfficer && !data.dutyOfficer.status ? 'color:#ddd' : ''
|
|
146
|
-
"
|
|
166
|
+
"
|
|
167
|
+
>
|
|
147
168
|
{{ data.label }}
|
|
148
169
|
</p>
|
|
149
170
|
</template>
|
|
150
171
|
</el-cascader>
|
|
151
|
-
<el-cascader-panel
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
172
|
+
<el-cascader-panel
|
|
173
|
+
v-else
|
|
174
|
+
:style="panStyle"
|
|
175
|
+
:filterable="!state.configJson['departmentUser'].multiple"
|
|
176
|
+
class="component-item"
|
|
177
|
+
:placeholder="`请选择部门下人员`"
|
|
178
|
+
v-model="state.selectVal['departmentUser']"
|
|
179
|
+
:props="{
|
|
158
180
|
label: 'name',
|
|
159
181
|
value: 'id',
|
|
160
182
|
children: 'childrenList',
|
|
@@ -163,12 +185,14 @@
|
|
|
163
185
|
checkStrictly: state.configJson['departmentUser'].checkStrictly,
|
|
164
186
|
multiple: state.configJson['departmentUser'].multiple,
|
|
165
187
|
}"
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
188
|
+
ref="departmentUser"
|
|
189
|
+
@change="setSelctData('departmentUser', $event)"
|
|
190
|
+
:options="organizationUsersTreeUser"
|
|
191
|
+
>
|
|
169
192
|
<template slot-scope="{ data }">
|
|
170
|
-
<p
|
|
171
|
-
|
|
193
|
+
<p
|
|
194
|
+
class="ht-user-dot"
|
|
195
|
+
style="
|
|
172
196
|
padding: 0;
|
|
173
197
|
margin: 0;
|
|
174
198
|
float: left;
|
|
@@ -180,17 +204,20 @@
|
|
|
180
204
|
border-radius: 10px;
|
|
181
205
|
margin-right: 4px;
|
|
182
206
|
"
|
|
183
|
-
|
|
207
|
+
:style="
|
|
184
208
|
data.dutyOfficer && !data.dutyOfficer.status
|
|
185
209
|
? 'background: #ccc;'
|
|
186
210
|
: ''
|
|
187
211
|
"
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
212
|
+
v-if="data.dutyOfficer"
|
|
213
|
+
></p>
|
|
214
|
+
<p
|
|
215
|
+
class="ht-user-name"
|
|
216
|
+
style="padding: 0; margin: 0; float: left"
|
|
217
|
+
:style="
|
|
192
218
|
data.dutyOfficer && !data.dutyOfficer.status ? 'color:#ddd' : ''
|
|
193
|
-
"
|
|
219
|
+
"
|
|
220
|
+
>
|
|
194
221
|
{{ data.label }}
|
|
195
222
|
</p>
|
|
196
223
|
</template>
|
|
@@ -200,27 +227,33 @@
|
|
|
200
227
|
<template v-for="item in state.resData.dictionaryCategory.items">
|
|
201
228
|
<!-- 选择严重等级 -->
|
|
202
229
|
<template v-if="item.code == 'SeverityLevel'">
|
|
203
|
-
<el-select
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
230
|
+
<el-select
|
|
231
|
+
v-if="state.configJson[item.code] && state.configJson[item.code].show"
|
|
232
|
+
v-model="state.selectVal[item.code]"
|
|
233
|
+
:disabled="!!disabled"
|
|
234
|
+
:key="item.id"
|
|
235
|
+
:style="comStyle || ''"
|
|
236
|
+
placeholder="请选择严重等级"
|
|
237
|
+
:filterable="!state.configJson[item.code].multiple"
|
|
238
|
+
class="component-item"
|
|
239
|
+
@click.native="selectClick($event)"
|
|
240
|
+
@change="setSelctItem(item.code)"
|
|
241
|
+
>
|
|
242
|
+
<el-option
|
|
243
|
+
v-for="item in SeverityLevel"
|
|
244
|
+
:key="item.id"
|
|
245
|
+
:style="panStyle"
|
|
246
|
+
:label="hideCode ? item.name : `${item.name}(${item.value})`"
|
|
247
|
+
:value="`${item.value}`"
|
|
248
|
+
:title="`${item.name}(${item.value})`"
|
|
249
|
+
>
|
|
219
250
|
<span>
|
|
220
|
-
<b
|
|
221
|
-
|
|
251
|
+
<b
|
|
252
|
+
class="item-origin"
|
|
253
|
+
:style="{
|
|
222
254
|
'border-color': `${item.color}`,
|
|
223
|
-
}"
|
|
255
|
+
}"
|
|
256
|
+
></b>
|
|
224
257
|
{{ item.name }}
|
|
225
258
|
</span>
|
|
226
259
|
<span v-if="item.phoneNumber"> ({{ item.phoneNumber }}) </span>
|
|
@@ -229,28 +262,34 @@
|
|
|
229
262
|
</template>
|
|
230
263
|
<!-- 选择响应列表 -->
|
|
231
264
|
<template v-else-if="item.code == 'ResponseList'">
|
|
232
|
-
<el-select
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
265
|
+
<el-select
|
|
266
|
+
v-if="state.configJson[item.code] && state.configJson[item.code].show"
|
|
267
|
+
v-model="state.selectVal[item.code]"
|
|
268
|
+
:key="item.id"
|
|
269
|
+
:disabled="!!disabled"
|
|
270
|
+
:style="comStyle || ''"
|
|
271
|
+
placeholder="请选择响应列表"
|
|
272
|
+
:filterable="!state.configJson[item.code].multiple"
|
|
273
|
+
class="component-item"
|
|
274
|
+
@click.native="selectClick($event)"
|
|
275
|
+
@change="setSelctItem(item.code)"
|
|
276
|
+
>
|
|
277
|
+
<el-option
|
|
278
|
+
v-for="item in ResponseList"
|
|
279
|
+
:key="item.id"
|
|
280
|
+
:style="panStyle"
|
|
281
|
+
:label="hideCode ? item.name : `${item.name}(${item.value})`"
|
|
282
|
+
:value="item.value"
|
|
283
|
+
:title="`${item.name}(${item.value})`"
|
|
284
|
+
>
|
|
248
285
|
<span>
|
|
249
|
-
<b
|
|
250
|
-
|
|
251
|
-
|
|
286
|
+
<b
|
|
287
|
+
v-if="item.color"
|
|
288
|
+
class="item-origin"
|
|
289
|
+
:style="{
|
|
252
290
|
'border-color': `${item.color}`,
|
|
253
|
-
}"
|
|
291
|
+
}"
|
|
292
|
+
></b>
|
|
254
293
|
{{ item.name }}
|
|
255
294
|
</span>
|
|
256
295
|
<span v-if="item.phoneNumber"> ({{ item.phoneNumber }}) </span>
|
|
@@ -259,21 +298,24 @@
|
|
|
259
298
|
</template>
|
|
260
299
|
<!-- 基础数据级联选择 -->
|
|
261
300
|
<template v-else>
|
|
262
|
-
<template
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
301
|
+
<template
|
|
302
|
+
v-if="state.configJson[item.code] && state.configJson[item.code].show"
|
|
303
|
+
>
|
|
304
|
+
<el-cascader
|
|
305
|
+
v-if="!state.configJson[item.code].panel"
|
|
306
|
+
:placeholder="`请选择${item.name}`"
|
|
307
|
+
:disabled="!!disabled"
|
|
308
|
+
class="component-item"
|
|
309
|
+
:style="comStyle || ''"
|
|
310
|
+
:key="item.id"
|
|
311
|
+
:filterable="!state.configJson[item.code].multiple"
|
|
312
|
+
:clearable="state.configJson[item.code].clearable"
|
|
313
|
+
@click.native="selectClick($event)"
|
|
314
|
+
v-model="state.selectVal[item.code]"
|
|
315
|
+
:collapse-tags="state.configJson[item.code].collapseTags"
|
|
316
|
+
:show-all-levels="state.configJson[item.code].showAllLevels"
|
|
317
|
+
:props="{
|
|
318
|
+
label: hideCode ? 'name' : 'label',
|
|
277
319
|
value: 'id',
|
|
278
320
|
children: 'children',
|
|
279
321
|
expandTrigger: 'click',
|
|
@@ -281,18 +323,20 @@
|
|
|
281
323
|
checkStrictly: state.configJson[item.code].checkStrictly,
|
|
282
324
|
multiple: state.configJson[item.code].multiple,
|
|
283
325
|
}"
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
326
|
+
:ref="`${item.code}`"
|
|
327
|
+
@change="setSelctData(item.code, $event)"
|
|
328
|
+
:options="getbaseDataInfo[item.id]"
|
|
329
|
+
></el-cascader>
|
|
330
|
+
<el-cascader-panel
|
|
331
|
+
v-else
|
|
332
|
+
@click.native="selectClick($event)"
|
|
333
|
+
:placeholder="`请选择${item.name}`"
|
|
334
|
+
class="component-item"
|
|
335
|
+
:key="item.id"
|
|
336
|
+
:style="panStyle"
|
|
337
|
+
v-model="state.selectVal[item.code]"
|
|
338
|
+
:props="{
|
|
339
|
+
label: hideCode ? 'name' : 'label',
|
|
296
340
|
value: 'id',
|
|
297
341
|
children: 'children',
|
|
298
342
|
expandTrigger: 'click',
|
|
@@ -300,9 +344,10 @@
|
|
|
300
344
|
checkStrictly: state.configJson[item.code].checkStrictly,
|
|
301
345
|
multiple: state.configJson[item.code].multiple,
|
|
302
346
|
}"
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
347
|
+
:ref="`${item.code}`"
|
|
348
|
+
@change="setSelctData(item.code, $event)"
|
|
349
|
+
:options="getbaseDataInfo[item.id]"
|
|
350
|
+
></el-cascader-panel>
|
|
306
351
|
</template>
|
|
307
352
|
</template>
|
|
308
353
|
</template>
|
|
@@ -317,21 +362,21 @@
|
|
|
317
362
|
</template>
|
|
318
363
|
|
|
319
364
|
<script lang="ts">
|
|
320
|
-
import { Vue, Prop, Emit, Component, Watch } from
|
|
365
|
+
import { Vue, Prop, Emit, Component, Watch } from 'vue-property-decorator';
|
|
321
366
|
|
|
322
367
|
import {
|
|
323
368
|
BaseDataDto,
|
|
324
369
|
DictionaryCategoryDto,
|
|
325
370
|
DictionaryDataDto,
|
|
326
371
|
SeverityLevelDto,
|
|
327
|
-
} from
|
|
372
|
+
} from '@/plugins/commonApi';
|
|
328
373
|
/* eslint-disable @typescript-eslint/camelcase */
|
|
329
374
|
import {
|
|
330
375
|
ListResultDto_1OfOfOrganizationUnitWithUsersAndContractsAnd_0AndCulture_neutralAndPublicKeyToken_null,
|
|
331
376
|
OrganizationUnitWithDetailsDto,
|
|
332
377
|
OrganizationUnitDto,
|
|
333
|
-
} from
|
|
334
|
-
import { _axios, baseConfig } from
|
|
378
|
+
} from '@/plugins/Auth';
|
|
379
|
+
import { _axios, baseConfig } from 'vue-kst-auth';
|
|
335
380
|
interface Inuser {
|
|
336
381
|
concurrencyStamp: string;
|
|
337
382
|
email: string;
|
|
@@ -470,7 +515,7 @@ interface State {
|
|
|
470
515
|
};
|
|
471
516
|
}
|
|
472
517
|
@Component({
|
|
473
|
-
name:
|
|
518
|
+
name: 'HtBaseData',
|
|
474
519
|
components: {},
|
|
475
520
|
})
|
|
476
521
|
export default class CommonDatas extends Vue {
|
|
@@ -478,6 +523,8 @@ export default class CommonDatas extends Vue {
|
|
|
478
523
|
@Prop() configJson?: string;
|
|
479
524
|
/** 自定义class */
|
|
480
525
|
@Prop() comClass?: string;
|
|
526
|
+
/** 隐藏编码 */
|
|
527
|
+
@Prop() hideCode?: boolean;
|
|
481
528
|
/** 自定义style */
|
|
482
529
|
@Prop() comStyle?: string;
|
|
483
530
|
/** 自定义style */
|
|
@@ -504,10 +551,9 @@ export default class CommonDatas extends Vue {
|
|
|
504
551
|
users: {
|
|
505
552
|
items: [],
|
|
506
553
|
},
|
|
507
|
-
SessionState:
|
|
554
|
+
SessionState: '',
|
|
508
555
|
userInOrganiza: [],
|
|
509
|
-
organizationUsers:
|
|
510
|
-
new ListResultDto_1OfOfOrganizationUnitWithUsersAndContractsAnd_0AndCulture_neutralAndPublicKeyToken_null(),
|
|
556
|
+
organizationUsers: new ListResultDto_1OfOfOrganizationUnitWithUsersAndContractsAnd_0AndCulture_neutralAndPublicKeyToken_null(),
|
|
511
557
|
},
|
|
512
558
|
selectVal: {},
|
|
513
559
|
selectValData: {},
|
|
@@ -519,7 +565,7 @@ export default class CommonDatas extends Vue {
|
|
|
519
565
|
if (!baseConfig.getLoginState()) {
|
|
520
566
|
return;
|
|
521
567
|
}
|
|
522
|
-
const data = window.localStorage.getItem(
|
|
568
|
+
const data = window.localStorage.getItem('commonDatas');
|
|
523
569
|
if (data) {
|
|
524
570
|
this.state.resData = Object.assign(this.state.resData, JSON.parse(data));
|
|
525
571
|
}
|
|
@@ -530,31 +576,31 @@ export default class CommonDatas extends Vue {
|
|
|
530
576
|
const { items } = this.state.resData.dictionaryCategory;
|
|
531
577
|
let configJson: any = {
|
|
532
578
|
departmentId: {
|
|
533
|
-
name:
|
|
579
|
+
name: '部门树结构',
|
|
534
580
|
show: true,
|
|
535
581
|
showAllLevels: false,
|
|
536
582
|
multiple: false,
|
|
537
|
-
code:
|
|
583
|
+
code: 'departmentId',
|
|
538
584
|
data: {},
|
|
539
585
|
checkStrictly: true,
|
|
540
586
|
panel: false,
|
|
541
587
|
},
|
|
542
588
|
departmentUser: {
|
|
543
|
-
name:
|
|
589
|
+
name: '部门下人员',
|
|
544
590
|
show: true,
|
|
545
591
|
showAllLevels: false,
|
|
546
592
|
multiple: false,
|
|
547
|
-
code:
|
|
593
|
+
code: 'departmentUser',
|
|
548
594
|
data: {},
|
|
549
595
|
checkStrictly: false,
|
|
550
596
|
panel: false,
|
|
551
597
|
},
|
|
552
598
|
userId: {
|
|
553
|
-
name:
|
|
599
|
+
name: '部门人员',
|
|
554
600
|
show: true,
|
|
555
601
|
showAllLevels: false,
|
|
556
602
|
multiple: false,
|
|
557
|
-
code:
|
|
603
|
+
code: 'userId',
|
|
558
604
|
data: {},
|
|
559
605
|
checkStrictly: false,
|
|
560
606
|
panel: false,
|
|
@@ -573,7 +619,7 @@ export default class CommonDatas extends Vue {
|
|
|
573
619
|
data: {},
|
|
574
620
|
checkStrictly: true,
|
|
575
621
|
panel: false,
|
|
576
|
-
key:
|
|
622
|
+
key: 'a1c72763-0ed5-0ba8-5131-39fdf96dfe9a',
|
|
577
623
|
},
|
|
578
624
|
};
|
|
579
625
|
});
|
|
@@ -594,7 +640,7 @@ export default class CommonDatas extends Vue {
|
|
|
594
640
|
if (Object.prototype.hasOwnProperty.call(this.state.configJson, key)) {
|
|
595
641
|
const element = this.state.configJson[key];
|
|
596
642
|
|
|
597
|
-
this.$set(this.state.selectVal, key, element.key ||
|
|
643
|
+
this.$set(this.state.selectVal, key, element.key || '');
|
|
598
644
|
}
|
|
599
645
|
}
|
|
600
646
|
}
|
|
@@ -602,7 +648,7 @@ export default class CommonDatas extends Vue {
|
|
|
602
648
|
/** 重写window的一个方法,解决web components组件获取样式报错问题 */
|
|
603
649
|
rewriteGetComputedStyle() {
|
|
604
650
|
const getComputedStyle = window.getComputedStyle;
|
|
605
|
-
window.getComputedStyle = function
|
|
651
|
+
window.getComputedStyle = function(element: any, property) {
|
|
606
652
|
return getComputedStyle(element.host || element, property);
|
|
607
653
|
};
|
|
608
654
|
}
|
|
@@ -611,15 +657,15 @@ export default class CommonDatas extends Vue {
|
|
|
611
657
|
const code = this.state.selectVal[key];
|
|
612
658
|
let codelist: string[];
|
|
613
659
|
if (!Array.isArray(code)) {
|
|
614
|
-
codelist = code ? code.toString().split(
|
|
660
|
+
codelist = code ? code.toString().split(',') : [];
|
|
615
661
|
}
|
|
616
662
|
switch (key) {
|
|
617
|
-
case
|
|
663
|
+
case 'SeverityLevel':
|
|
618
664
|
this.state.selectValData[key] = this.SeverityLevel.filter((item) =>
|
|
619
665
|
codelist.some((val) => val == item.value?.toString())
|
|
620
666
|
);
|
|
621
667
|
break;
|
|
622
|
-
case
|
|
668
|
+
case 'ResponseList':
|
|
623
669
|
this.state.selectValData[key] = this.SeverityLevel.filter((item) =>
|
|
624
670
|
codelist.some((val) => val == item.id)
|
|
625
671
|
);
|
|
@@ -632,7 +678,7 @@ export default class CommonDatas extends Vue {
|
|
|
632
678
|
/** 动态设置显示面板位置 */
|
|
633
679
|
|
|
634
680
|
selectClick(e: any) {
|
|
635
|
-
console.log(
|
|
681
|
+
console.log('ee', e);
|
|
636
682
|
// 下拉选择框列表
|
|
637
683
|
//const list = window.document.getElementsByClassName("el-select-dropdown");
|
|
638
684
|
// (list as any).forEach((element: any) => {
|
|
@@ -681,7 +727,7 @@ export default class CommonDatas extends Vue {
|
|
|
681
727
|
this.state.selectValData[key] = [];
|
|
682
728
|
checkNodes.forEach(
|
|
683
729
|
(item: { data?: { id: string; name: string } } | undefined) => {
|
|
684
|
-
const { data } = item || { data:
|
|
730
|
+
const { data } = item || { data: '' };
|
|
685
731
|
if (data && !this.state.selectValData[key].includes(data)) {
|
|
686
732
|
this.state.selectValData[key].push(data);
|
|
687
733
|
}
|
|
@@ -692,7 +738,7 @@ export default class CommonDatas extends Vue {
|
|
|
692
738
|
this.state.selectValData[key] = [];
|
|
693
739
|
}
|
|
694
740
|
this.$emit(
|
|
695
|
-
|
|
741
|
+
'change',
|
|
696
742
|
this.state.selectValData[key] ? this.state.selectValData : { [key]: [] }
|
|
697
743
|
);
|
|
698
744
|
}
|
|
@@ -715,9 +761,9 @@ export default class CommonDatas extends Vue {
|
|
|
715
761
|
/** 获取基础数据列表 */
|
|
716
762
|
const { items: baseItems } = this.state.resData.baseData;
|
|
717
763
|
this.state.resData.dictionaryCategory.items.forEach((item) => {
|
|
718
|
-
body[item.id ||
|
|
764
|
+
body[item.id || ''] = [];
|
|
719
765
|
if (this.org) {
|
|
720
|
-
body[item.id ||
|
|
766
|
+
body[item.id || ''] = this.recursion(
|
|
721
767
|
baseItems.filter(
|
|
722
768
|
(val) =>
|
|
723
769
|
val.category == item.code &&
|
|
@@ -725,7 +771,7 @@ export default class CommonDatas extends Vue {
|
|
|
725
771
|
)
|
|
726
772
|
);
|
|
727
773
|
} else {
|
|
728
|
-
body[item.id ||
|
|
774
|
+
body[item.id || ''] = this.recursion(
|
|
729
775
|
baseItems.filter((val) => val.category == item.code)
|
|
730
776
|
);
|
|
731
777
|
}
|
|
@@ -736,7 +782,7 @@ export default class CommonDatas extends Vue {
|
|
|
736
782
|
get ResponseList() {
|
|
737
783
|
return (
|
|
738
784
|
this.state.resData.dictionaryData.filter(
|
|
739
|
-
(val) => val.categoryCode ==
|
|
785
|
+
(val) => val.categoryCode == 'ResponseList'
|
|
740
786
|
) || []
|
|
741
787
|
);
|
|
742
788
|
}
|
|
@@ -826,7 +872,7 @@ export default class CommonDatas extends Vue {
|
|
|
826
872
|
|
|
827
873
|
return recursion(this.organizationUsersTree);
|
|
828
874
|
}
|
|
829
|
-
@Watch(
|
|
875
|
+
@Watch('configJson', { deep: true })
|
|
830
876
|
watchCongiJson(val: any, old: any) {
|
|
831
877
|
this.state.configJson = JSON.parse(val);
|
|
832
878
|
if (val !== old) {
|
|
@@ -834,7 +880,7 @@ export default class CommonDatas extends Vue {
|
|
|
834
880
|
if (Object.prototype.hasOwnProperty.call(this.state.configJson, key)) {
|
|
835
881
|
const element = this.state.configJson[key];
|
|
836
882
|
|
|
837
|
-
this.$set(this.state.selectVal, key, element.key ||
|
|
883
|
+
this.$set(this.state.selectVal, key, element.key || '');
|
|
838
884
|
}
|
|
839
885
|
}
|
|
840
886
|
}
|