bri-components 1.2.49 → 1.2.51
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/package.json +2 -2
- package/src/components/controls/BriControlInput.vue +13 -9
- package/src/components/controls/base/DshCascader/DshCascader.vue +40 -23
- package/src/components/controls/base/DshCascader/InfoCascader.vue +7 -15
- package/src/components/controls/base/DshDate/DshDate.vue +146 -0
- package/src/components/controls/base/{DshDaterange.vue → DshDate/DshDaterange.vue} +74 -64
- package/src/components/controls/base/DshEditor.vue +1 -1
- package/src/components/controls/base/{BriInputs.vue → DshInput/BriInputs.vue} +1 -1
- package/src/components/controls/base/{DshInput.vue → DshInput/DshInput.vue} +21 -4
- package/src/components/controls/base/DshNumber/DshNumber.vue +33 -2
- package/src/components/controls/base/{DshNumberange.vue → DshNumber/DshNumberange.vue} +37 -2
- package/src/components/controls/base/DshSelect/DshCheckbox.vue +280 -0
- package/src/components/controls/base/DshSelect/DshSelect.vue +319 -0
- package/src/components/controls/base/DshSelect/selectMixin.js +239 -0
- package/src/components/controls/base/DshSwitch/DshSwitch.vue +79 -0
- package/src/components/controls/base/DshSwitch/switchMixin.js +73 -0
- package/src/components/controls/controlMap.js +8 -11
- package/src/components/controls/controlMixin.js +38 -6
- package/src/components/controls/senior/BriLabels.vue +1 -1
- package/src/components/controls/senior/selectDepartments.vue +9 -13
- package/src/components/controls/senior/selectUsers/selectUsers.vue +23 -21
- package/src/components/controls/special/DshBack.vue +1 -1
- package/src/components/controls/special/DshUndeveloped.vue +1 -1
- package/src/components/form/DshAdvSearch.vue +155 -3
- package/src/components/form/DshDefaultSearch.vue +84 -40
- package/src/components/form/DshForm.vue +24 -0
- package/src/components/form/searchMixin.js +5 -18
- package/src/components/other/BriGantt.vue +2 -2
- package/src/components/unit/DshFormUnit.vue +111 -2
- package/src/components/unit/DshListUnit.vue +6 -0
- package/src/index.js +10 -10
- package/src/styles/components/controls/base/DshInput.less +0 -16
- package/src/styles/components/index.less +0 -14
- package/src/styles/components/other/BriGantt.less +1 -12
- package/src/styles/index.less +5 -3
- package/src/styles/reset-iview-controls.less +104 -0
- package/src/abolish/BriTransfer.less +0 -65
- package/src/abolish/BriTransfer.vue +0 -71
- package/src/abolish/BriTree.less +0 -57
- package/src/abolish/DshCascaders.less +0 -11
- package/src/abolish/DshCascaders.vue +0 -151
- package/src/abolish/DshCrumbs.less +0 -0
- package/src/abolish/DshCrumbs.vue +0 -62
- package/src/abolish/DshCrumbsItem.vue +0 -109
- package/src/abolish/DshEditPanel.less +0 -70
- package/src/abolish/DshEditPanel.vue +0 -152
- package/src/abolish/DshFileShow.less +0 -61
- package/src/abolish/DshFileShow.vue +0 -0
- package/src/abolish/DshFlatTable.less +0 -93
- package/src/abolish/DshFlatTable.vue +0 -605
- package/src/abolish/DshMenu.less +0 -37
- package/src/abolish/DshMenu.vue +0 -133
- package/src/abolish/DshTexts.less +0 -13
- package/src/abolish/DshTexts.vue +0 -89
- package/src/components/controls/base/DshCheckbox.vue +0 -213
- package/src/components/controls/base/DshDate.vue +0 -122
- package/src/components/controls/base/DshSelect.vue +0 -242
- package/src/components/controls/base/DshSwitch.vue +0 -70
- package/src/components/controls/base/selectMixin.js +0 -110
- package/src/styles/components/controls/base/DshCheckbox.less +0 -115
- package/src/styles/components/controls/base/DshDate.less +0 -15
- package/src/styles/components/controls/base/DshDaterange.less +0 -49
- package/src/styles/components/controls/base/DshNumber.less +0 -55
- package/src/styles/components/controls/base/DshNumberange.less +0 -29
- package/src/styles/components/controls/base/DshSelect.less +0 -190
- package/src/styles/components/form/DshAdvSearch.less +0 -149
- package/src/styles/components/form/DshDefaultSearch.less +0 -82
- package/src/styles/components/form/DshForm.less +0 -18
- package/src/styles/components/unit/DshFormUnit.less +0 -105
- package/src/styles/components/unit/DshListUnit.less +0 -3
- /package/src/{abolish/DshCrumbItem.less → styles/reset-iview-other.less} +0 -0
- /package/src/styles/{reset-iview.less → reset-iview-variables.less} +0 -0
|
@@ -120,7 +120,7 @@
|
|
|
120
120
|
>
|
|
121
121
|
<!-- 上 全选 -->
|
|
122
122
|
<div
|
|
123
|
-
v-if="
|
|
123
|
+
v-if="multipleMode"
|
|
124
124
|
class="content-users-list-checkAll"
|
|
125
125
|
>
|
|
126
126
|
<Checkbox
|
|
@@ -292,15 +292,11 @@
|
|
|
292
292
|
...this.commonDealPropsObj
|
|
293
293
|
};
|
|
294
294
|
},
|
|
295
|
-
|
|
296
|
-
multiple () {
|
|
297
|
-
return this.selfPropsObj._multiple;
|
|
298
|
-
},
|
|
299
295
|
highSearch () {
|
|
300
|
-
return this.selfPropsObj._highSearch;
|
|
296
|
+
return this.isOnSearch ? true : this.selfPropsObj._highSearch;
|
|
301
297
|
},
|
|
302
298
|
inputIcon () {
|
|
303
|
-
return this.
|
|
299
|
+
return this.multipleMode ? "ios-people" : "ios-person";
|
|
304
300
|
},
|
|
305
301
|
|
|
306
302
|
curCheckAll () {
|
|
@@ -379,7 +375,7 @@
|
|
|
379
375
|
}
|
|
380
376
|
},
|
|
381
377
|
clickSelectUserItem (curUserItem, bool) {
|
|
382
|
-
if (this.
|
|
378
|
+
if (this.multipleMode) {
|
|
383
379
|
if (this.newValList.some(newItem => newItem._key === curUserItem._key)) {
|
|
384
380
|
this.newValList = this.newValList.filter(newItem => newItem._key !== curUserItem._key);
|
|
385
381
|
} else {
|
|
@@ -442,21 +438,27 @@
|
|
|
442
438
|
searchString: this.propsObj.searchString
|
|
443
439
|
},
|
|
444
440
|
callback: data => {
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
441
|
+
this.departmentList = [
|
|
442
|
+
...(
|
|
443
|
+
this.highSearch
|
|
444
|
+
? [
|
|
445
|
+
{
|
|
446
|
+
is_leaf: true,
|
|
447
|
+
level: 1,
|
|
448
|
+
name: "高级选项",
|
|
449
|
+
_key: "_highSearch"
|
|
450
|
+
}
|
|
451
|
+
]
|
|
452
|
+
: []
|
|
453
|
+
),
|
|
454
|
+
{
|
|
453
455
|
is_leaf: true,
|
|
454
456
|
level: 1,
|
|
455
|
-
name: "
|
|
456
|
-
_key: "
|
|
457
|
-
}
|
|
458
|
-
|
|
459
|
-
|
|
457
|
+
name: "全部",
|
|
458
|
+
_key: ""
|
|
459
|
+
},
|
|
460
|
+
...data.list
|
|
461
|
+
];
|
|
460
462
|
}
|
|
461
463
|
});
|
|
462
464
|
}
|
|
@@ -71,18 +71,17 @@
|
|
|
71
71
|
</template>
|
|
72
72
|
|
|
73
73
|
<!-- 动态筛选字段,出现是有条件的 -->
|
|
74
|
-
<dsh-
|
|
74
|
+
<dsh-checkbox
|
|
75
75
|
v-else-if="conditionItem.parameterType === 'dynamicText'"
|
|
76
76
|
class="DshAdvSearch-conditions-item-control"
|
|
77
77
|
:value="conditionItem"
|
|
78
78
|
:propsObj="{
|
|
79
79
|
_name: `${conditionItem.formItem._name}的动态参数`,
|
|
80
80
|
_key: 'fieldParams',
|
|
81
|
-
_multiple: true,
|
|
82
81
|
_data: conditionItem.dynamicList
|
|
83
82
|
}"
|
|
84
83
|
@change="change(conditionItem, arguments)"
|
|
85
|
-
></dsh-
|
|
84
|
+
></dsh-checkbox>
|
|
86
85
|
|
|
87
86
|
<!-- 为空和不为空时 啥不显示 -->
|
|
88
87
|
<div
|
|
@@ -350,3 +349,156 @@
|
|
|
350
349
|
}
|
|
351
350
|
};
|
|
352
351
|
</script>
|
|
352
|
+
|
|
353
|
+
<style lang="less" scoped>
|
|
354
|
+
.DshAdvSearch {
|
|
355
|
+
#title {
|
|
356
|
+
font-weight: 400;
|
|
357
|
+
color: #999999;
|
|
358
|
+
font-size: 14px;
|
|
359
|
+
}
|
|
360
|
+
|
|
361
|
+
&-title {
|
|
362
|
+
#title();
|
|
363
|
+
}
|
|
364
|
+
|
|
365
|
+
&-logic {
|
|
366
|
+
margin: 5px 0px 10px;
|
|
367
|
+
.dsh-flex-row-start-center();
|
|
368
|
+
|
|
369
|
+
&-title {
|
|
370
|
+
#title();
|
|
371
|
+
}
|
|
372
|
+
&-option {
|
|
373
|
+
flex: 1;
|
|
374
|
+
min-width: 100px;
|
|
375
|
+
margin-left: 20px;
|
|
376
|
+
}
|
|
377
|
+
}
|
|
378
|
+
|
|
379
|
+
&-conditions {
|
|
380
|
+
&-delete {
|
|
381
|
+
display: none;
|
|
382
|
+
padding: 3px;
|
|
383
|
+
position: absolute;
|
|
384
|
+
top: 6px;
|
|
385
|
+
right: 2px;
|
|
386
|
+
color: red;
|
|
387
|
+
}
|
|
388
|
+
|
|
389
|
+
&-loop,
|
|
390
|
+
&-item {
|
|
391
|
+
position: relative;
|
|
392
|
+
|
|
393
|
+
&:hover,
|
|
394
|
+
&-active {
|
|
395
|
+
.DshAdvSearch-conditions-delete {
|
|
396
|
+
display: inline-block;
|
|
397
|
+
}
|
|
398
|
+
}
|
|
399
|
+
}
|
|
400
|
+
|
|
401
|
+
&-loop {
|
|
402
|
+
padding: 10px;
|
|
403
|
+
margin: 6px;
|
|
404
|
+
border: 1px solid @placeholderColor;
|
|
405
|
+
background-color: #F4F8FF;
|
|
406
|
+
}
|
|
407
|
+
|
|
408
|
+
&-item {
|
|
409
|
+
padding: 0!important;
|
|
410
|
+
margin-bottom: 10px!important;
|
|
411
|
+
cursor: pointer;
|
|
412
|
+
|
|
413
|
+
.DshFormUnit-label-right {
|
|
414
|
+
flex: 6;
|
|
415
|
+
}
|
|
416
|
+
|
|
417
|
+
&-loading {
|
|
418
|
+
margin: 5px 0px;
|
|
419
|
+
text-align: center;
|
|
420
|
+
font-size: 16px;
|
|
421
|
+
color: @textColor;
|
|
422
|
+
}
|
|
423
|
+
|
|
424
|
+
&-control {
|
|
425
|
+
.dsh-margin-bottom5();
|
|
426
|
+
}
|
|
427
|
+
|
|
428
|
+
&-blank {
|
|
429
|
+
text-align: center;
|
|
430
|
+
line-height: 30px;
|
|
431
|
+
color: @placeholderColor;
|
|
432
|
+
}
|
|
433
|
+
|
|
434
|
+
&-extra {
|
|
435
|
+
text-align: right;
|
|
436
|
+
padding-right: 10px;
|
|
437
|
+
|
|
438
|
+
.extra {
|
|
439
|
+
&-dynamic {
|
|
440
|
+
width: 90px;
|
|
441
|
+
display: inline-block;
|
|
442
|
+
}
|
|
443
|
+
|
|
444
|
+
&-operator {
|
|
445
|
+
.dsh-margin-right10();
|
|
446
|
+
|
|
447
|
+
&-wrap {
|
|
448
|
+
display: inline-block;
|
|
449
|
+
padding: 5px;
|
|
450
|
+
|
|
451
|
+
&:hover {
|
|
452
|
+
background-color: #E8F3FD;
|
|
453
|
+
}
|
|
454
|
+
}
|
|
455
|
+
|
|
456
|
+
&-name {
|
|
457
|
+
display: inline-block;
|
|
458
|
+
min-width: 36px;
|
|
459
|
+
}
|
|
460
|
+
|
|
461
|
+
&-icon {
|
|
462
|
+
.dsh-margin-left5();
|
|
463
|
+
}
|
|
464
|
+
}
|
|
465
|
+
}
|
|
466
|
+
}
|
|
467
|
+
}
|
|
468
|
+
}
|
|
469
|
+
|
|
470
|
+
&-btns {
|
|
471
|
+
width: 100%;
|
|
472
|
+
margin-top: 15px;
|
|
473
|
+
.dsh-flex-row-start-center();
|
|
474
|
+
|
|
475
|
+
&-field {
|
|
476
|
+
flex: 3;
|
|
477
|
+
|
|
478
|
+
&-list {
|
|
479
|
+
width: 330px;
|
|
480
|
+
}
|
|
481
|
+
|
|
482
|
+
&-create {
|
|
483
|
+
#btn-style();
|
|
484
|
+
}
|
|
485
|
+
}
|
|
486
|
+
|
|
487
|
+
&-loop {
|
|
488
|
+
flex: 1;
|
|
489
|
+
margin-left: 12px;
|
|
490
|
+
|
|
491
|
+
&-create {
|
|
492
|
+
#btn-style();
|
|
493
|
+
}
|
|
494
|
+
}
|
|
495
|
+
}
|
|
496
|
+
|
|
497
|
+
&-nodata {
|
|
498
|
+
margin: 20px 0px;
|
|
499
|
+
text-align: center;
|
|
500
|
+
font-size: 16px;
|
|
501
|
+
color: #B8BECC;
|
|
502
|
+
}
|
|
503
|
+
}
|
|
504
|
+
</style>
|
|
@@ -1,10 +1,5 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<div
|
|
3
|
-
class="DshDefaultSearch bri-scrollbar6"
|
|
4
|
-
:style="{
|
|
5
|
-
'margin-bottom': canUseFold ? '20px' : undefined
|
|
6
|
-
}"
|
|
7
|
-
>
|
|
2
|
+
<div class="DshDefaultSearch">
|
|
8
3
|
<!-- 筛选表单 -->
|
|
9
4
|
<div
|
|
10
5
|
class="DshDefaultSearch-form"
|
|
@@ -15,34 +10,34 @@
|
|
|
15
10
|
>
|
|
16
11
|
<Row :gutter="10">
|
|
17
12
|
<template v-for="conditionItem in conditionList">
|
|
18
|
-
<
|
|
13
|
+
<i-col
|
|
19
14
|
:key="conditionItem._id"
|
|
20
15
|
:span="conditionItem.formItem._span"
|
|
21
16
|
>
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
>
|
|
32
|
-
<span
|
|
33
|
-
slot="label"
|
|
34
|
-
class="DshDefaultSearch-item-name"
|
|
17
|
+
<dsh-form-unit
|
|
18
|
+
:key="conditionItem._id"
|
|
19
|
+
class="DshDefaultSearch-form-item"
|
|
20
|
+
:formData="conditionItem"
|
|
21
|
+
:formItem="conditionItem.formItem"
|
|
22
|
+
height="46"
|
|
23
|
+
:labelStyle="labelStyle"
|
|
24
|
+
:rowStyle="rowStyle"
|
|
25
|
+
@change="change(conditionItem, arguments)"
|
|
35
26
|
>
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
27
|
+
<span
|
|
28
|
+
slot="label"
|
|
29
|
+
class="DshDefaultSearch-form-item-name"
|
|
30
|
+
>
|
|
31
|
+
{{ conditionItem.formItem._name }}
|
|
32
|
+
</span>
|
|
33
|
+
</dsh-form-unit>
|
|
34
|
+
</i-col>
|
|
40
35
|
|
|
41
36
|
<!-- 换行 -->
|
|
42
37
|
<div
|
|
43
38
|
v-if="conditionItem.formItem._wrap"
|
|
44
39
|
:key="conditionItem._id + '_wrap'"
|
|
45
|
-
style="width:100%"
|
|
40
|
+
style="width: 100%"
|
|
46
41
|
></div>
|
|
47
42
|
</template>
|
|
48
43
|
</Row>
|
|
@@ -53,11 +48,10 @@
|
|
|
53
48
|
v-if="canUseFold"
|
|
54
49
|
class="DshDefaultSearch-fold"
|
|
55
50
|
>
|
|
56
|
-
<!-- <div class="DshDefaultSearch-fold-zhanwei"></div> -->
|
|
57
51
|
<Icon
|
|
58
52
|
:class="[
|
|
59
53
|
'DshDefaultSearch-fold-icon',
|
|
60
|
-
isSpreadStatus ? '
|
|
54
|
+
`DshDefaultSearch-fold-icon-${isSpreadStatus ? 'up' : 'down'}`
|
|
61
55
|
]"
|
|
62
56
|
custom="bico-font bico-shuangjiantou"
|
|
63
57
|
@click="toggleSpreadStatus"
|
|
@@ -99,16 +93,16 @@
|
|
|
99
93
|
width: "calc(100% - 12px)"
|
|
100
94
|
},
|
|
101
95
|
labelStyle: {
|
|
102
|
-
|
|
96
|
+
width: this.labelWidth + "px",
|
|
97
|
+
height: "32px",
|
|
103
98
|
margin: 0,
|
|
104
|
-
color: "#666666",
|
|
105
|
-
border: "1px solid rgba(229, 229, 229, 1)",
|
|
106
|
-
background: "rgba(245, 245, 245, 1)",
|
|
107
99
|
padding: "5px 10px",
|
|
100
|
+
border: "1px solid rgba(229, 229, 229, 1)",
|
|
108
101
|
borderRight: "none",
|
|
109
|
-
|
|
102
|
+
backgroundColor: "rgba(245, 245, 245, 1)",
|
|
110
103
|
boxSizing: "border-box",
|
|
111
|
-
|
|
104
|
+
textAlign: "center",
|
|
105
|
+
color: "#666666"
|
|
112
106
|
}
|
|
113
107
|
};
|
|
114
108
|
},
|
|
@@ -141,7 +135,7 @@
|
|
|
141
135
|
},
|
|
142
136
|
// 判断是否符合折叠情形,showRowNum为null时候不使用展开/收合,为0时候就是一行不露出来
|
|
143
137
|
canUseFold () {
|
|
144
|
-
return this.showRowNum ==
|
|
138
|
+
return this.showRowNum == undefined
|
|
145
139
|
? false
|
|
146
140
|
: this.allRowNum > this.showRowNum;
|
|
147
141
|
}
|
|
@@ -165,9 +159,11 @@
|
|
|
165
159
|
getFormItem (formItem) {
|
|
166
160
|
return {
|
|
167
161
|
...this.formatFormItem(formItem),
|
|
162
|
+
onDftSearch: true,
|
|
168
163
|
|
|
169
164
|
_line: true,
|
|
170
165
|
_useColor: false,
|
|
166
|
+
_optionKind: "dropdown",
|
|
171
167
|
|
|
172
168
|
...(
|
|
173
169
|
// date、daterange类型的(formItem._type基本不会为daterange)
|
|
@@ -175,12 +171,6 @@
|
|
|
175
171
|
? {
|
|
176
172
|
_useShortcuts: false
|
|
177
173
|
}
|
|
178
|
-
// select、checkbox、以及switch(都会转成checkbox)类型的
|
|
179
|
-
: ["switch", "select", "checkbox"].includes(formItem._type)
|
|
180
|
-
? {
|
|
181
|
-
_optionKind: "dropdown",
|
|
182
|
-
_useColor: false
|
|
183
|
-
}
|
|
184
174
|
// labels类型的
|
|
185
175
|
: ["labels"].includes(formItem._type)
|
|
186
176
|
? {
|
|
@@ -201,3 +191,57 @@
|
|
|
201
191
|
}
|
|
202
192
|
};
|
|
203
193
|
</script>
|
|
194
|
+
|
|
195
|
+
<style lang="less" scoped>
|
|
196
|
+
.DshDefaultSearch {
|
|
197
|
+
background: #fff;
|
|
198
|
+
.dsh-flex-col-start-stretch();
|
|
199
|
+
|
|
200
|
+
&-form {
|
|
201
|
+
z-index: 2;
|
|
202
|
+
|
|
203
|
+
&-item {
|
|
204
|
+
padding: 6px 0px;
|
|
205
|
+
margin-top: 0px;
|
|
206
|
+
margin-bottom: 0px;
|
|
207
|
+
|
|
208
|
+
&-name {}
|
|
209
|
+
}
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
&-fold {
|
|
213
|
+
text-align: center;
|
|
214
|
+
|
|
215
|
+
&-icon {
|
|
216
|
+
width: 48px;
|
|
217
|
+
height: 20px;
|
|
218
|
+
background: #fff;
|
|
219
|
+
box-shadow: 0 0 16px 0 rgba(51, 51, 51, 0.1);
|
|
220
|
+
text-align: center;
|
|
221
|
+
line-height: 20px;
|
|
222
|
+
font-size: 14px;
|
|
223
|
+
color: #999999;
|
|
224
|
+
cursor: pointer;
|
|
225
|
+
|
|
226
|
+
&-up {
|
|
227
|
+
transform: rotate(180deg);
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
&-down {
|
|
231
|
+
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
</style>
|
|
237
|
+
<style lang="less">
|
|
238
|
+
.DshDefaultSearch {
|
|
239
|
+
input,
|
|
240
|
+
.ivu-select-selection,
|
|
241
|
+
.ivu-input-number,
|
|
242
|
+
.BriControlInput,
|
|
243
|
+
.DshDaterange-item {
|
|
244
|
+
border-radius: 0px!important;
|
|
245
|
+
}
|
|
246
|
+
}
|
|
247
|
+
</style>
|
|
@@ -392,3 +392,27 @@
|
|
|
392
392
|
}
|
|
393
393
|
};
|
|
394
394
|
</script>
|
|
395
|
+
|
|
396
|
+
<style lang="less" scoped>
|
|
397
|
+
.DshForm {
|
|
398
|
+
padding-bottom: 5px;
|
|
399
|
+
|
|
400
|
+
&-item-FormItem {
|
|
401
|
+
margin-bottom: 0px;
|
|
402
|
+
}
|
|
403
|
+
}
|
|
404
|
+
</style>
|
|
405
|
+
<style lang="less">
|
|
406
|
+
.DshForm {
|
|
407
|
+
.ivu-form-item-content {
|
|
408
|
+
line-height: normal;
|
|
409
|
+
|
|
410
|
+
.ivu-form-item-error-tip {
|
|
411
|
+
top: calc(100% - 8px);
|
|
412
|
+
left: 16px;
|
|
413
|
+
padding-top: 0px;
|
|
414
|
+
font-size: 12px;
|
|
415
|
+
}
|
|
416
|
+
}
|
|
417
|
+
}
|
|
418
|
+
</style>
|
|
@@ -131,33 +131,20 @@ export default {
|
|
|
131
131
|
},
|
|
132
132
|
// 格式化表单配置,适合需要
|
|
133
133
|
formatFormItem (formItem) {
|
|
134
|
-
const fieldData = this.fieldMap[formItem._type];
|
|
135
|
-
|
|
136
134
|
return {
|
|
137
135
|
...formItem,
|
|
138
|
-
|
|
136
|
+
onSearch: true,
|
|
137
|
+
|
|
139
138
|
_key: "fieldValue",
|
|
140
139
|
__realKey__: formItem._key,
|
|
141
140
|
_description: undefined,
|
|
142
141
|
_required: false,
|
|
143
142
|
_br: false,
|
|
144
143
|
_wrap: false,
|
|
144
|
+
|
|
145
|
+
_multiple: true,
|
|
145
146
|
_enterType: undefined,
|
|
146
|
-
canEdit: true
|
|
147
|
-
_data: ["switch"].includes(formItem._type)
|
|
148
|
-
? [
|
|
149
|
-
{
|
|
150
|
-
_key: "true",
|
|
151
|
-
name: formItem._openText,
|
|
152
|
-
color: "#87e8de"
|
|
153
|
-
},
|
|
154
|
-
{
|
|
155
|
-
_key: "false",
|
|
156
|
-
name: formItem._closeText,
|
|
157
|
-
color: "#87e8de"
|
|
158
|
-
}
|
|
159
|
-
]
|
|
160
|
-
: formItem._data
|
|
147
|
+
canEdit: true
|
|
161
148
|
};
|
|
162
149
|
},
|
|
163
150
|
|
|
@@ -238,8 +238,8 @@
|
|
|
238
238
|
</div>
|
|
239
239
|
|
|
240
240
|
<!-- 底部滚动条 -->
|
|
241
|
-
<!-- <div class="briGantt-
|
|
242
|
-
<div class="briGantt-
|
|
241
|
+
<!-- <div class="briGantt-scroll">
|
|
242
|
+
<div class="briGantt-scroll-main"
|
|
243
243
|
ref="briGanttScrollbar"
|
|
244
244
|
:style="{ width: clientWidth + 'px' }"
|
|
245
245
|
v-on:scroll="handleScroll($event, [{ ref: 'briGanttTimer', direction: 'scrollLeft' }, { ref:'briGanttArea', direction:'scrollLeft' }, { ref:'briGanttBlue', direction:'scrollLeft' }])">
|
|
@@ -59,12 +59,13 @@
|
|
|
59
59
|
>
|
|
60
60
|
<slot name="extra">
|
|
61
61
|
<bri-tooltip
|
|
62
|
+
v-if="formItem._description"
|
|
62
63
|
:content="formItem._description"
|
|
63
64
|
transfer
|
|
64
65
|
style="height: 14px;"
|
|
65
66
|
>
|
|
66
|
-
<span class="DshFormUnit-label-description
|
|
67
|
-
{{
|
|
67
|
+
<span class="DshFormUnit-label-description">
|
|
68
|
+
{{ `* ${formItem._description}` }}
|
|
68
69
|
</span>
|
|
69
70
|
</bri-tooltip>
|
|
70
71
|
</slot>
|
|
@@ -158,3 +159,111 @@
|
|
|
158
159
|
}
|
|
159
160
|
};
|
|
160
161
|
</script>
|
|
162
|
+
|
|
163
|
+
<style lang="less" scoped>
|
|
164
|
+
.DshFormUnit {
|
|
165
|
+
margin: 3px 6px; // 不可轻易改margin的左右值,上面style的width根据他calc
|
|
166
|
+
padding: 0px 10px 10px;
|
|
167
|
+
|
|
168
|
+
&-label {
|
|
169
|
+
min-width: 0px;
|
|
170
|
+
padding: 5px 0px 5px;
|
|
171
|
+
line-height: 20px;
|
|
172
|
+
font-size: @smallSize;
|
|
173
|
+
display: flex;
|
|
174
|
+
align-items: center;
|
|
175
|
+
|
|
176
|
+
&-left {
|
|
177
|
+
flex: 2;
|
|
178
|
+
min-width: 150px;
|
|
179
|
+
position: relative;
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
&-right {
|
|
183
|
+
flex: 1;
|
|
184
|
+
min-width: 0px;
|
|
185
|
+
text-align: right;
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
&-name {
|
|
189
|
+
font-size: @textSize;
|
|
190
|
+
.dsh-ellipsis();
|
|
191
|
+
|
|
192
|
+
&-edit {
|
|
193
|
+
color: @textColor;
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
&-show {
|
|
197
|
+
color: @contentColor;
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
&-sign {
|
|
201
|
+
#dsh-sign-change();
|
|
202
|
+
}
|
|
203
|
+
}
|
|
204
|
+
|
|
205
|
+
&-description {
|
|
206
|
+
.dsh-ellipsis();
|
|
207
|
+
color: #60c0ec;
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
&-control {
|
|
212
|
+
min-height: 32px;
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
&-line {
|
|
216
|
+
display: flex;
|
|
217
|
+
justify-content: space-between;
|
|
218
|
+
align-items: center;
|
|
219
|
+
|
|
220
|
+
.DshFormUnit-label {
|
|
221
|
+
max-width: 280px;
|
|
222
|
+
font-size: @textSize;
|
|
223
|
+
overflow: hidden;
|
|
224
|
+
margin: 0px;
|
|
225
|
+
margin-right: 8px;
|
|
226
|
+
|
|
227
|
+
// fixedbug:line模式下显示必填
|
|
228
|
+
margin-left: -10px;
|
|
229
|
+
padding-left: 10px;
|
|
230
|
+
|
|
231
|
+
&-left {
|
|
232
|
+
flex: 1;
|
|
233
|
+
min-width: 40px;
|
|
234
|
+
}
|
|
235
|
+
|
|
236
|
+
&-right {
|
|
237
|
+
flex: none;
|
|
238
|
+
max-width: 50%;
|
|
239
|
+
min-width: 0px;
|
|
240
|
+
text-align: right;
|
|
241
|
+
}
|
|
242
|
+
}
|
|
243
|
+
|
|
244
|
+
.DshFormUnit-control {
|
|
245
|
+
flex: 1;
|
|
246
|
+
min-width: 50px;
|
|
247
|
+
display: flex;
|
|
248
|
+
justify-content: flex-end;
|
|
249
|
+
align-items: center;
|
|
250
|
+
}
|
|
251
|
+
}
|
|
252
|
+
|
|
253
|
+
&-required {
|
|
254
|
+
.DshFormUnit-label-name:before {
|
|
255
|
+
position: absolute;
|
|
256
|
+
left: -10px;
|
|
257
|
+
|
|
258
|
+
content: '*';
|
|
259
|
+
display: inline-block;
|
|
260
|
+
width: 6px;
|
|
261
|
+
line-height: 1.5;
|
|
262
|
+
font-family: SimSun;
|
|
263
|
+
font-weight: 500;
|
|
264
|
+
font-size: @textSize;
|
|
265
|
+
color: #E94829;
|
|
266
|
+
}
|
|
267
|
+
}
|
|
268
|
+
}
|
|
269
|
+
</style>
|