bri-components 1.2.15 → 1.2.17
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/bri-components.min.js +10 -10
- package/package.json +1 -1
- package/src/abolish/DshEditPanel.vue +1 -1
- package/src/components/controls/base/DshSelect.vue +3 -3
- package/src/components/controls/senior/selectDepartments.vue +8 -44
- package/src/components/controls/senior/selectUsers/selectUsers.vue +7 -7
- package/src/components/list/BriTable.vue +5 -2
- package/src/components/list/BriTree.vue +1 -1
- package/src/components/other/BriIframe.vue +14 -19
- package/src/components/other/BriLoading.vue +11 -9
- package/src/components/small/DshModal.vue +4 -2
- package/src/styles/components/controls/senior/selectDepartments.less +7 -40
- package/src/styles/components/controls/senior/selectUsers/selectUsers.less +26 -30
- package/src/styles/components/other/BriIframe.less +1 -0
- package/src/styles/components/small/DshModal.less +137 -92
package/package.json
CHANGED
|
@@ -226,10 +226,10 @@
|
|
|
226
226
|
callback: data => {
|
|
227
227
|
this.initListData = [
|
|
228
228
|
...this.initListData,
|
|
229
|
-
...data.list.map(
|
|
229
|
+
...data.list.map(dataItem =>
|
|
230
230
|
({
|
|
231
|
-
_key:
|
|
232
|
-
name:
|
|
231
|
+
_key: dataItem[item._key || "_key"],
|
|
232
|
+
name: dataItem[item._name || "name"]
|
|
233
233
|
})
|
|
234
234
|
)
|
|
235
235
|
];
|
|
@@ -96,7 +96,6 @@
|
|
|
96
96
|
<template v-else>
|
|
97
97
|
<!-- 树形形式 -->
|
|
98
98
|
<div
|
|
99
|
-
v-if="isCascader"
|
|
100
99
|
class="list-center-tree"
|
|
101
100
|
>
|
|
102
101
|
<template v-if="allDepartmentList.length">
|
|
@@ -116,43 +115,14 @@
|
|
|
116
115
|
暂无数据……
|
|
117
116
|
</div>
|
|
118
117
|
</div>
|
|
119
|
-
|
|
120
|
-
<!-- 卡片形式 -->
|
|
121
|
-
<div
|
|
122
|
-
v-else
|
|
123
|
-
class="list-center-card"
|
|
124
|
-
>
|
|
125
|
-
<bri-card
|
|
126
|
-
:data="departmentList"
|
|
127
|
-
:changeOnSelect="changeOnSelect"
|
|
128
|
-
:multiple="multiple"
|
|
129
|
-
@on-change="changeSelect"
|
|
130
|
-
></bri-card>
|
|
131
|
-
|
|
132
|
-
<div
|
|
133
|
-
v-if="highSearch"
|
|
134
|
-
class="card-high"
|
|
135
|
-
>
|
|
136
|
-
<p class="card-high-title">高级选项</p>
|
|
137
|
-
<bri-card
|
|
138
|
-
:data="highDepartmentList"
|
|
139
|
-
:changeOnSelect="changeOnSelect"
|
|
140
|
-
:multiple="multiple"
|
|
141
|
-
@on-change="changeSelect"
|
|
142
|
-
></bri-card>
|
|
143
|
-
</div>
|
|
144
|
-
</div>
|
|
145
118
|
</template>
|
|
146
119
|
</div>
|
|
147
|
-
|
|
148
|
-
<!-- 底 按钮 -->
|
|
149
|
-
<div class="list-footer">
|
|
150
|
-
<dsh-buttons
|
|
151
|
-
:list="$getOperationList(['canCancel', 'canConfirm'])"
|
|
152
|
-
@click="$dispatchEvent($event)"
|
|
153
|
-
></dsh-buttons>
|
|
154
|
-
</div>
|
|
155
120
|
</div>
|
|
121
|
+
<dsh-buttons
|
|
122
|
+
class="bri-modal-footer"
|
|
123
|
+
:list="$getOperationList(['canCancel', 'canConfirm'])"
|
|
124
|
+
@click="$dispatchEvent($event)"
|
|
125
|
+
></dsh-buttons>
|
|
156
126
|
</dsh-modal>
|
|
157
127
|
</div>
|
|
158
128
|
</template>
|
|
@@ -207,10 +177,8 @@
|
|
|
207
177
|
return {
|
|
208
178
|
_multiple: false,
|
|
209
179
|
_highSearch: false,
|
|
210
|
-
_isCascader: true,
|
|
211
180
|
_changeOnSelect: true,
|
|
212
181
|
_searchString: "",
|
|
213
|
-
|
|
214
182
|
...this.propsObj,
|
|
215
183
|
...this.commonDealPropsObj
|
|
216
184
|
};
|
|
@@ -224,11 +192,6 @@
|
|
|
224
192
|
inputIcon () {
|
|
225
193
|
return this.multiple ? "ios-people" : "ios-person";
|
|
226
194
|
},
|
|
227
|
-
|
|
228
|
-
// 暂时没配置
|
|
229
|
-
isCascader () {
|
|
230
|
-
return this.selfPropsObj._isCascader;
|
|
231
|
-
},
|
|
232
195
|
changeOnSelect () {
|
|
233
196
|
return this.selfPropsObj._changeOnSelect;
|
|
234
197
|
},
|
|
@@ -239,7 +202,8 @@
|
|
|
239
202
|
modalPropsObj () {
|
|
240
203
|
return {
|
|
241
204
|
title: "选择部门",
|
|
242
|
-
class:
|
|
205
|
+
class: "bri-modal-center",
|
|
206
|
+
width: 600,
|
|
243
207
|
showSlotClose: false,
|
|
244
208
|
closable: true
|
|
245
209
|
};
|
|
@@ -335,7 +299,7 @@
|
|
|
335
299
|
this.$https({
|
|
336
300
|
url: {
|
|
337
301
|
module: "company",
|
|
338
|
-
name:
|
|
302
|
+
name: "compDepartCascaderAll"
|
|
339
303
|
},
|
|
340
304
|
params: {
|
|
341
305
|
search: this.searchName
|
|
@@ -167,12 +167,11 @@
|
|
|
167
167
|
</div>
|
|
168
168
|
|
|
169
169
|
<!-- footer -->
|
|
170
|
-
<
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
</div>
|
|
170
|
+
<dsh-buttons
|
|
171
|
+
class="bri-modal-footer"
|
|
172
|
+
:list="$getOperationList(['canCancel', 'canConfirm'])"
|
|
173
|
+
@click="$dispatchEvent($event)"
|
|
174
|
+
></dsh-buttons>
|
|
176
175
|
</dsh-modal>
|
|
177
176
|
</div>
|
|
178
177
|
</template>
|
|
@@ -198,7 +197,8 @@
|
|
|
198
197
|
modalPropsObj: {
|
|
199
198
|
title: "选择成员",
|
|
200
199
|
showSlotClose: false,
|
|
201
|
-
closable: true
|
|
200
|
+
closable: true,
|
|
201
|
+
class: "bri-modal-center"
|
|
202
202
|
},
|
|
203
203
|
// 筛选
|
|
204
204
|
searchData: {
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
|
|
13
13
|
<div
|
|
14
14
|
v-else
|
|
15
|
-
class="
|
|
15
|
+
class="BriIframe-nodata"
|
|
16
16
|
>
|
|
17
17
|
<img
|
|
18
18
|
:src="noData"
|
|
@@ -59,25 +59,20 @@
|
|
|
59
59
|
methods: {
|
|
60
60
|
init () {
|
|
61
61
|
let iframe = this.$refs.BriIframe;
|
|
62
|
-
if (
|
|
63
|
-
|
|
62
|
+
if (iframe) {
|
|
63
|
+
this.loading = true;
|
|
64
|
+
if (iframe.attachEvent) {
|
|
65
|
+
iframe.attachEvent("onreadystatechange", () => {
|
|
66
|
+
if (iframe.readyState === "complete" || iframe.readyState == "loaded") {
|
|
67
|
+
this.loading = false;
|
|
68
|
+
}
|
|
69
|
+
});
|
|
70
|
+
} else {
|
|
71
|
+
iframe.addEventListener("load", () => {
|
|
72
|
+
this.loading = false;
|
|
73
|
+
}, false);
|
|
74
|
+
}
|
|
64
75
|
}
|
|
65
|
-
this.loading = true;
|
|
66
|
-
if (iframe.attachEvent) {
|
|
67
|
-
iframe.attachEvent("onreadystatechange", () => {
|
|
68
|
-
if (iframe.readyState === "complete" || iframe.readyState == "loaded") {
|
|
69
|
-
this.loadingEnd();
|
|
70
|
-
}
|
|
71
|
-
});
|
|
72
|
-
} else {
|
|
73
|
-
iframe.addEventListener("load", () => {
|
|
74
|
-
this.loadingEnd();
|
|
75
|
-
}, false);
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
-
},
|
|
79
|
-
loadingEnd () {
|
|
80
|
-
this.loading = false;
|
|
81
76
|
},
|
|
82
77
|
/**
|
|
83
78
|
* 在iframe页面使用举例:
|
|
@@ -8,22 +8,24 @@
|
|
|
8
8
|
}"
|
|
9
9
|
>
|
|
10
10
|
<div class="BriLoading-main">
|
|
11
|
-
|
|
12
|
-
|
|
11
|
+
<!-- loading -->
|
|
12
|
+
<template v-if="value === 1">
|
|
13
|
+
<slot>
|
|
13
14
|
<div
|
|
14
15
|
class="BriLoading-main-loading"
|
|
15
16
|
:style="getStyle"
|
|
16
|
-
>
|
|
17
|
-
</div>
|
|
17
|
+
></div>
|
|
18
18
|
<div
|
|
19
19
|
v-if="showLoadingText"
|
|
20
20
|
class="BriLoading-main-loadingText"
|
|
21
21
|
>
|
|
22
22
|
{{ loadText }}
|
|
23
23
|
</div>
|
|
24
|
-
</
|
|
25
|
-
|
|
26
|
-
|
|
24
|
+
</slot>
|
|
25
|
+
</template>
|
|
26
|
+
<!-- nodata -->
|
|
27
|
+
<template v-else-if="value === 2">
|
|
28
|
+
<slot name="nodata">
|
|
27
29
|
<bri-svg :src="imgSrc" />
|
|
28
30
|
<div
|
|
29
31
|
v-if="noText"
|
|
@@ -31,8 +33,8 @@
|
|
|
31
33
|
>
|
|
32
34
|
{{ noText }}
|
|
33
35
|
</div>
|
|
34
|
-
</
|
|
35
|
-
</
|
|
36
|
+
</slot>
|
|
37
|
+
</template>
|
|
36
38
|
</div>
|
|
37
39
|
</div>
|
|
38
40
|
</template>
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
|
|
40
40
|
<!-- 删除按钮 -->
|
|
41
41
|
<Icon
|
|
42
|
-
v-if="selfPropsObj.showSlotClose
|
|
42
|
+
v-if="selfPropsObj.showSlotClose"
|
|
43
43
|
class="DshModal-close"
|
|
44
44
|
type="md-close"
|
|
45
45
|
size="20"
|
|
@@ -97,6 +97,8 @@
|
|
|
97
97
|
// stickyDistance: 30, // 拖拽时,自动吸附屏幕边缘的临界距离
|
|
98
98
|
// resetDragPosition: false, // Modal 再次打开时,是否重置拖拽的位置
|
|
99
99
|
transfer: true,
|
|
100
|
+
showSlotClose: true, // 显示删除
|
|
101
|
+
|
|
100
102
|
...this.propsObj,
|
|
101
103
|
class: [
|
|
102
104
|
"DshModal",
|
|
@@ -114,7 +116,7 @@
|
|
|
114
116
|
const widthOBj = {
|
|
115
117
|
default: "750",
|
|
116
118
|
small: "500",
|
|
117
|
-
middle: "
|
|
119
|
+
middle: "60%",
|
|
118
120
|
large: this.propsObj.draggable ? "100%" : "80%",
|
|
119
121
|
auto: "auto"
|
|
120
122
|
};
|
|
@@ -1,30 +1,8 @@
|
|
|
1
1
|
.selectDepartments {
|
|
2
2
|
width: 100%;
|
|
3
3
|
|
|
4
|
-
&-edit {
|
|
5
|
-
|
|
6
|
-
}
|
|
7
|
-
|
|
8
|
-
&-show {
|
|
9
|
-
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
// 传到子组件里的class!!!
|
|
13
|
-
&-modal {
|
|
14
|
-
.ivu-modal {
|
|
15
|
-
width: 800px!important;
|
|
16
|
-
}
|
|
17
|
-
}
|
|
18
|
-
// 传到子组件里的class!!!
|
|
19
|
-
&-cascaderModal {
|
|
20
|
-
.ivu-modal {
|
|
21
|
-
width: 600px !important;
|
|
22
|
-
}
|
|
23
|
-
}
|
|
24
|
-
|
|
25
4
|
&-list {
|
|
26
|
-
height:
|
|
27
|
-
padding: 15px 20px;
|
|
5
|
+
height: 500px;
|
|
28
6
|
.dsh-flex-col-start-stretch();
|
|
29
7
|
|
|
30
8
|
.list {
|
|
@@ -34,11 +12,9 @@
|
|
|
34
12
|
display: flex;
|
|
35
13
|
flex-wrap: wrap;
|
|
36
14
|
align-items: center;
|
|
37
|
-
|
|
38
|
-
&-label {
|
|
39
15
|
|
|
40
|
-
}
|
|
41
|
-
|
|
16
|
+
&-label {}
|
|
17
|
+
|
|
42
18
|
.item {
|
|
43
19
|
max-width: 230px;
|
|
44
20
|
height: 24px;
|
|
@@ -63,17 +39,17 @@
|
|
|
63
39
|
}
|
|
64
40
|
}
|
|
65
41
|
}
|
|
66
|
-
|
|
42
|
+
|
|
67
43
|
&-search {
|
|
68
44
|
padding: 10px 15px;
|
|
69
45
|
}
|
|
70
|
-
|
|
46
|
+
|
|
71
47
|
&-center {
|
|
72
48
|
flex: 1;
|
|
73
49
|
min-height: 100px;
|
|
74
50
|
padding: 5px 0 10px;
|
|
75
51
|
overflow: auto;
|
|
76
|
-
|
|
52
|
+
|
|
77
53
|
&-tree {
|
|
78
54
|
.tree {
|
|
79
55
|
&-nodata {
|
|
@@ -81,7 +57,7 @@
|
|
|
81
57
|
}
|
|
82
58
|
}
|
|
83
59
|
}
|
|
84
|
-
|
|
60
|
+
|
|
85
61
|
&-card {
|
|
86
62
|
.card {
|
|
87
63
|
&-high-title {
|
|
@@ -92,15 +68,6 @@
|
|
|
92
68
|
}
|
|
93
69
|
}
|
|
94
70
|
}
|
|
95
|
-
|
|
96
|
-
&-footer {
|
|
97
|
-
text-align: right;
|
|
98
|
-
|
|
99
|
-
.ivu-btn {
|
|
100
|
-
width: 120px;
|
|
101
|
-
height: 38px;
|
|
102
|
-
}
|
|
103
|
-
}
|
|
104
71
|
}
|
|
105
72
|
}
|
|
106
73
|
}
|
|
@@ -1,75 +1,71 @@
|
|
|
1
1
|
.selectUsers {
|
|
2
2
|
width: 100%;
|
|
3
3
|
|
|
4
|
-
&-edit {
|
|
4
|
+
&-edit {}
|
|
5
5
|
|
|
6
|
-
}
|
|
7
|
-
&-show {
|
|
8
|
-
|
|
9
|
-
}
|
|
6
|
+
&-show {}
|
|
10
7
|
|
|
11
8
|
// 弹框部分
|
|
12
9
|
&-modal {
|
|
13
10
|
&-wrap {
|
|
14
11
|
display: flex;
|
|
15
|
-
|
|
16
|
-
height: 550px;
|
|
12
|
+
height: 500px;
|
|
17
13
|
|
|
18
14
|
&-left {
|
|
19
15
|
width: 520px;
|
|
20
16
|
overflow-y: auto;
|
|
21
17
|
background: @white;
|
|
22
18
|
border: 1px solid #E5E5E5;
|
|
23
|
-
|
|
19
|
+
|
|
24
20
|
.search {
|
|
25
21
|
padding: 10px 20px;
|
|
26
22
|
}
|
|
27
|
-
|
|
23
|
+
|
|
28
24
|
.content {
|
|
29
25
|
display: flex;
|
|
30
26
|
height: calc(100% - 52px);
|
|
31
27
|
border-top: 1px solid #E5E5E5;
|
|
32
|
-
|
|
28
|
+
|
|
33
29
|
&-menu {
|
|
34
30
|
flex: 3;
|
|
35
31
|
height: 100%;
|
|
36
32
|
overflow: auto;
|
|
37
33
|
}
|
|
38
|
-
|
|
34
|
+
|
|
39
35
|
&-users {
|
|
40
36
|
flex: 2;
|
|
41
37
|
position: relative;
|
|
42
|
-
|
|
38
|
+
|
|
43
39
|
.ivu-checkbox-checked .ivu-checkbox-inner {
|
|
44
40
|
border-color: @themeColor;
|
|
45
41
|
background-color: @themeColor;
|
|
46
42
|
}
|
|
47
|
-
|
|
43
|
+
|
|
48
44
|
&-list {
|
|
49
45
|
border-left: 1px solid #E5E5E5;
|
|
50
46
|
height: 100%;
|
|
51
47
|
display: flex;
|
|
52
48
|
flex-direction: column;
|
|
53
|
-
|
|
54
|
-
|
|
49
|
+
|
|
50
|
+
|
|
55
51
|
&-checkAll {
|
|
56
52
|
height: 40px;
|
|
57
53
|
line-height: 40px;
|
|
58
54
|
border-bottom: 1px solid #E5E5E5;
|
|
59
55
|
padding-left: 15px;
|
|
60
56
|
}
|
|
61
|
-
|
|
57
|
+
|
|
62
58
|
&-selects {
|
|
63
59
|
flex: 1;
|
|
64
60
|
overflow: auto;
|
|
65
61
|
padding: 15px;
|
|
66
|
-
|
|
62
|
+
|
|
67
63
|
&-item {
|
|
68
64
|
margin-bottom: 5px;
|
|
69
65
|
}
|
|
70
66
|
}
|
|
71
67
|
}
|
|
72
|
-
|
|
68
|
+
|
|
73
69
|
&-nodata {
|
|
74
70
|
position: absolute;
|
|
75
71
|
top: 50%;
|
|
@@ -77,17 +73,17 @@
|
|
|
77
73
|
text-align: center;
|
|
78
74
|
transform: translateY(-50%);
|
|
79
75
|
}
|
|
80
|
-
|
|
76
|
+
|
|
81
77
|
}
|
|
82
78
|
}
|
|
83
79
|
}
|
|
84
|
-
|
|
80
|
+
|
|
85
81
|
&-center {
|
|
86
82
|
width: 100px;
|
|
87
83
|
display: flex;
|
|
88
84
|
justify-content: center;
|
|
89
85
|
align-items: center;
|
|
90
|
-
|
|
86
|
+
|
|
91
87
|
.icon {
|
|
92
88
|
width: 24px;
|
|
93
89
|
height: 24px;
|
|
@@ -99,7 +95,7 @@
|
|
|
99
95
|
text-align: center;
|
|
100
96
|
}
|
|
101
97
|
}
|
|
102
|
-
|
|
98
|
+
|
|
103
99
|
&-right {
|
|
104
100
|
flex: 1;
|
|
105
101
|
width: 0px;
|
|
@@ -111,12 +107,12 @@
|
|
|
111
107
|
overflow: auto;
|
|
112
108
|
display: flex;
|
|
113
109
|
flex-direction: column;
|
|
114
|
-
|
|
110
|
+
|
|
115
111
|
.list {
|
|
116
112
|
display: flex;
|
|
117
113
|
flex-wrap: wrap;
|
|
118
114
|
align-items: center;
|
|
119
|
-
|
|
115
|
+
|
|
120
116
|
&-item {
|
|
121
117
|
max-width: 150px;
|
|
122
118
|
height: 24px;
|
|
@@ -128,11 +124,11 @@
|
|
|
128
124
|
font-size: 12px;
|
|
129
125
|
display: flex;
|
|
130
126
|
align-items: center;
|
|
131
|
-
|
|
127
|
+
|
|
132
128
|
&-name {
|
|
133
129
|
.dsh-ellipsis();
|
|
134
130
|
}
|
|
135
|
-
|
|
131
|
+
|
|
136
132
|
&-delete {
|
|
137
133
|
padding: 3px;
|
|
138
134
|
margin-left: 5px;
|
|
@@ -142,15 +138,15 @@
|
|
|
142
138
|
}
|
|
143
139
|
}
|
|
144
140
|
}
|
|
145
|
-
|
|
141
|
+
|
|
146
142
|
&-footer {
|
|
147
143
|
padding-bottom: 10px;
|
|
148
|
-
|
|
144
|
+
|
|
149
145
|
.DshButtons {
|
|
150
146
|
text-align: right;
|
|
151
147
|
padding-right: 24px;
|
|
152
|
-
|
|
153
|
-
|
|
148
|
+
|
|
149
|
+
|
|
154
150
|
.ivu-btn {
|
|
155
151
|
width: 70px;
|
|
156
152
|
height: 32px;
|