n20-common-lib 3.0.78 → 3.0.79
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 +1 -1
- package/src/assets/css/page-header.scss +0 -1
- package/src/assets/css/table.scss +244 -249
- package/src/components/ProFilterView/index.vue +17 -0
- package/src/components/TableOperate/index.vue +32 -16
- package/src/components/v3/TablePro/index.vue +63 -8
- package/style/index.css +1 -1
- package/theme/blue.css +1 -1
- package/theme/cctcRed.css +1 -1
- package/theme/green.css +1 -1
- package/theme/lightBlue.css +1 -1
- package/theme/orange.css +1 -1
- package/theme/purple.css +1 -1
- package/theme/red.css +1 -1
- package/theme/yellow.css +1 -1
package/package.json
CHANGED
|
@@ -1,249 +1,244 @@
|
|
|
1
|
-
.el-table--small {
|
|
2
|
-
font-size: 14px;
|
|
3
|
-
}
|
|
4
|
-
|
|
5
|
-
.el-table--mini {
|
|
6
|
-
font-size: 12px;
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
.el-table th {
|
|
10
|
-
font-weight: $--font-weight-primary;
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
.el-table--small .el-table__cell {
|
|
14
|
-
padding: 8px 0;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
.el-table .cell {
|
|
18
|
-
padding-left: 8px;
|
|
19
|
-
padding-right: 8px;
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
.el-table--small,
|
|
23
|
-
.el-table--mini {
|
|
24
|
-
.el-table__cell {
|
|
25
|
-
.el-button--text {
|
|
26
|
-
padding-top: 2px;
|
|
27
|
-
padding-bottom: 2px;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
.el-link {
|
|
31
|
-
line-height: initial;
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
.el-table--mini {
|
|
37
|
-
.el-table__cell {
|
|
38
|
-
padding: 2px 0;
|
|
39
|
-
|
|
40
|
-
.cell {
|
|
41
|
-
padding-left: 4px;
|
|
42
|
-
padding-right: 4px;
|
|
43
|
-
// line-height: 18px;
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
.el-button--mini,
|
|
47
|
-
.el-link {
|
|
48
|
-
font-size: 12px;
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
.el-table {
|
|
54
|
-
/* 排序 */
|
|
55
|
-
.caret-wrapper {
|
|
56
|
-
display: inline-flex;
|
|
57
|
-
flex-direction: row-reverse;
|
|
58
|
-
align-items: center;
|
|
59
|
-
width: 16px;
|
|
60
|
-
height: 16px;
|
|
61
|
-
line-height: 16px;
|
|
62
|
-
vertical-align: middle;
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
.sort-caret.ascending,
|
|
66
|
-
.sort-caret.descending {
|
|
67
|
-
width: 8px;
|
|
68
|
-
height: 16px;
|
|
69
|
-
border: none;
|
|
70
|
-
font-style: normal;
|
|
71
|
-
position: static;
|
|
72
|
-
|
|
73
|
-
&:hover {
|
|
74
|
-
color: $--color-primary-light-6;
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
&:before {
|
|
78
|
-
content: '\e61c';
|
|
79
|
-
font-family: 'core-lib-iconfont';
|
|
80
|
-
font-size: 12px;
|
|
81
|
-
line-height: 12px;
|
|
82
|
-
position: relative;
|
|
83
|
-
right: 3px;
|
|
84
|
-
bottom: 1px;
|
|
85
|
-
}
|
|
86
|
-
}
|
|
87
|
-
|
|
88
|
-
.sort-caret.descending:before {
|
|
89
|
-
content: '\e61d';
|
|
90
|
-
position: relative;
|
|
91
|
-
right: 1px;
|
|
92
|
-
bottom: 1px;
|
|
93
|
-
}
|
|
94
|
-
|
|
95
|
-
.ascending .sort-caret.ascending,
|
|
96
|
-
.descending .sort-caret.descending {
|
|
97
|
-
color: $--color-primary;
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
|
-
|
|
101
|
-
/* 过滤 */
|
|
102
|
-
.el-table-filter__bottom {
|
|
103
|
-
text-align: center;
|
|
104
|
-
}
|
|
105
|
-
|
|
106
|
-
.el-table__column-filter-trigger {
|
|
107
|
-
height: 16px;
|
|
108
|
-
line-height: 16px;
|
|
109
|
-
vertical-align: middle;
|
|
110
|
-
position: relative;
|
|
111
|
-
bottom: 1px;
|
|
112
|
-
|
|
113
|
-
i {
|
|
114
|
-
font-size: 16px;
|
|
115
|
-
transform: scale(1);
|
|
116
|
-
}
|
|
117
|
-
}
|
|
118
|
-
|
|
119
|
-
.table-header-popover.el-popover {
|
|
120
|
-
padding: 16px;
|
|
121
|
-
}
|
|
122
|
-
|
|
123
|
-
/* 附件上传hover颜色 */
|
|
124
|
-
.base-table_default {
|
|
125
|
-
.el-table__body .hover-active:hover > td {
|
|
126
|
-
background-color: #ff3c2f10 !important;
|
|
127
|
-
}
|
|
128
|
-
}
|
|
129
|
-
|
|
130
|
-
.vxe-table .vxe-cell--sort {
|
|
131
|
-
display: inline-flex !important;
|
|
132
|
-
flex-direction: row-reverse !important;
|
|
133
|
-
align-items: center !important;
|
|
134
|
-
width: 16px !important;
|
|
135
|
-
height: 16px !important;
|
|
136
|
-
line-height: 16px !important;
|
|
137
|
-
vertical-align: middle !important;
|
|
138
|
-
cursor: pointer;
|
|
139
|
-
padding-right: 4px !important;
|
|
140
|
-
.vxe-sort--asc-btn,
|
|
141
|
-
.vxe-sort--desc-btn {
|
|
142
|
-
width: 6px;
|
|
143
|
-
height: 10px;
|
|
144
|
-
color: #333;
|
|
145
|
-
border: none;
|
|
146
|
-
font-style: normal;
|
|
147
|
-
position: static;
|
|
148
|
-
}
|
|
149
|
-
}
|
|
150
|
-
|
|
151
|
-
.vxe-header--row {
|
|
152
|
-
color: #333;
|
|
153
|
-
background-color: #f5f5f5;
|
|
154
|
-
}
|
|
155
|
-
|
|
156
|
-
.vxe-cell--filter .vxe-filter--btn {
|
|
157
|
-
color: #666;
|
|
158
|
-
font-weight: $--font-weight-primary;
|
|
159
|
-
cursor: pointer;
|
|
160
|
-
font-size: 16px;
|
|
161
|
-
}
|
|
162
|
-
|
|
163
|
-
.is--filter-active .vxe-cell--filter .vxe-filter--btn {
|
|
164
|
-
color: $--color-primary;
|
|
165
|
-
}
|
|
166
|
-
|
|
167
|
-
.is--filter-active .vxe-cell--title {
|
|
168
|
-
color: $--color-primary;
|
|
169
|
-
}
|
|
170
|
-
|
|
171
|
-
.vxe-table--render-default.size--small {
|
|
172
|
-
font-size: 14px !important;
|
|
173
|
-
}
|
|
174
|
-
|
|
175
|
-
.vxe-table--render-default.size--mini {
|
|
176
|
-
font-size: 14px !important;
|
|
177
|
-
}
|
|
178
|
-
|
|
179
|
-
.vxe-header--row th,
|
|
180
|
-
th.vxe-header--column {
|
|
181
|
-
position: relative;
|
|
182
|
-
font-weight: $--font-weight-primary;
|
|
183
|
-
}
|
|
184
|
-
|
|
185
|
-
.vxe-table--tooltip-wrapper {
|
|
186
|
-
z-index: 9999 !important;
|
|
187
|
-
}
|
|
188
|
-
|
|
189
|
-
.cell-default-set-- .vxe-table--body-wrapper .vxe-body--row .vxe-body--column .vxe-cell .vxe-cell--label:empty::before {
|
|
190
|
-
content: '--';
|
|
191
|
-
}
|
|
192
|
-
|
|
193
|
-
.n20-table-pro.vxe-table--render-default {
|
|
194
|
-
font-family: PingFang SC, Microsoft YaHei, Arial, sans-serif !important;
|
|
195
|
-
color: #333;
|
|
196
|
-
}
|
|
197
|
-
|
|
198
|
-
.vxe-table-custom-wrap.vxe-body--column.col--ellipsis:not(.col--actived) > .vxe-cell,
|
|
199
|
-
.vxe-table--render-default .vxe-table-custom-wrap.vxe-footer--column.col--ellipsis:not(.col--actived) > .vxe-cell,
|
|
200
|
-
.vxe-table--render-default .vxe-table-custom-wrap.vxe-header--column.col--ellipsis:not(.col--actived) > .vxe-cell {
|
|
201
|
-
overflow: hidden;
|
|
202
|
-
text-overflow: ellipsis;
|
|
203
|
-
white-space: wrap !important;
|
|
204
|
-
}
|
|
205
|
-
|
|
206
|
-
.vxe-table--render-default.size--small .vxe-table-custom-wrap.vxe-body--column.col--ellipsis > .vxe-cell,
|
|
207
|
-
.vxe-table--render-default.size--small .vxe-table-custom-wrap.vxe-footer--column.col--ellipsis > .vxe-cell,
|
|
208
|
-
.vxe-table--render-default.size--small .vxe-table-custom-wrap.vxe-header--column.col--ellipsis > .vxe-cell {
|
|
209
|
-
max-height: 100%;
|
|
210
|
-
}
|
|
211
|
-
|
|
212
|
-
.vxe-header--column {
|
|
213
|
-
.vxe-cell {
|
|
214
|
-
justify-content: center !important;
|
|
215
|
-
}
|
|
216
|
-
}
|
|
217
|
-
|
|
218
|
-
.vxe-table--body-
|
|
219
|
-
.vxe-table--
|
|
220
|
-
.vxe-table--
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
.
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
.
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
.el-table th.el-table__cell > .cell {
|
|
246
|
-
overflow: hidden;
|
|
247
|
-
text-overflow: ellipsis;
|
|
248
|
-
white-space: nowrap;
|
|
249
|
-
}
|
|
1
|
+
.el-table--small {
|
|
2
|
+
font-size: 14px;
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
.el-table--mini {
|
|
6
|
+
font-size: 12px;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.el-table th {
|
|
10
|
+
font-weight: $--font-weight-primary;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.el-table--small .el-table__cell {
|
|
14
|
+
padding: 8px 0;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
.el-table .cell {
|
|
18
|
+
padding-left: 8px;
|
|
19
|
+
padding-right: 8px;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
.el-table--small,
|
|
23
|
+
.el-table--mini {
|
|
24
|
+
.el-table__cell {
|
|
25
|
+
.el-button--text {
|
|
26
|
+
padding-top: 2px;
|
|
27
|
+
padding-bottom: 2px;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.el-link {
|
|
31
|
+
line-height: initial;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
.el-table--mini {
|
|
37
|
+
.el-table__cell {
|
|
38
|
+
padding: 2px 0;
|
|
39
|
+
|
|
40
|
+
.cell {
|
|
41
|
+
padding-left: 4px;
|
|
42
|
+
padding-right: 4px;
|
|
43
|
+
// line-height: 18px;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.el-button--mini,
|
|
47
|
+
.el-link {
|
|
48
|
+
font-size: 12px;
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
.el-table {
|
|
54
|
+
/* 排序 */
|
|
55
|
+
.caret-wrapper {
|
|
56
|
+
display: inline-flex;
|
|
57
|
+
flex-direction: row-reverse;
|
|
58
|
+
align-items: center;
|
|
59
|
+
width: 16px;
|
|
60
|
+
height: 16px;
|
|
61
|
+
line-height: 16px;
|
|
62
|
+
vertical-align: middle;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
.sort-caret.ascending,
|
|
66
|
+
.sort-caret.descending {
|
|
67
|
+
width: 8px;
|
|
68
|
+
height: 16px;
|
|
69
|
+
border: none;
|
|
70
|
+
font-style: normal;
|
|
71
|
+
position: static;
|
|
72
|
+
|
|
73
|
+
&:hover {
|
|
74
|
+
color: $--color-primary-light-6;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
&:before {
|
|
78
|
+
content: '\e61c';
|
|
79
|
+
font-family: 'core-lib-iconfont';
|
|
80
|
+
font-size: 12px;
|
|
81
|
+
line-height: 12px;
|
|
82
|
+
position: relative;
|
|
83
|
+
right: 3px;
|
|
84
|
+
bottom: 1px;
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
.sort-caret.descending:before {
|
|
89
|
+
content: '\e61d';
|
|
90
|
+
position: relative;
|
|
91
|
+
right: 1px;
|
|
92
|
+
bottom: 1px;
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
.ascending .sort-caret.ascending,
|
|
96
|
+
.descending .sort-caret.descending {
|
|
97
|
+
color: $--color-primary;
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
/* 过滤 */
|
|
102
|
+
.el-table-filter__bottom {
|
|
103
|
+
text-align: center;
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
.el-table__column-filter-trigger {
|
|
107
|
+
height: 16px;
|
|
108
|
+
line-height: 16px;
|
|
109
|
+
vertical-align: middle;
|
|
110
|
+
position: relative;
|
|
111
|
+
bottom: 1px;
|
|
112
|
+
|
|
113
|
+
i {
|
|
114
|
+
font-size: 16px;
|
|
115
|
+
transform: scale(1);
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
.table-header-popover.el-popover {
|
|
120
|
+
padding: 16px;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
/* 附件上传hover颜色 */
|
|
124
|
+
.base-table_default {
|
|
125
|
+
.el-table__body .hover-active:hover > td {
|
|
126
|
+
background-color: #ff3c2f10 !important;
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
.vxe-table .vxe-cell--sort {
|
|
131
|
+
display: inline-flex !important;
|
|
132
|
+
flex-direction: row-reverse !important;
|
|
133
|
+
align-items: center !important;
|
|
134
|
+
width: 16px !important;
|
|
135
|
+
height: 16px !important;
|
|
136
|
+
line-height: 16px !important;
|
|
137
|
+
vertical-align: middle !important;
|
|
138
|
+
cursor: pointer;
|
|
139
|
+
padding-right: 4px !important;
|
|
140
|
+
.vxe-sort--asc-btn,
|
|
141
|
+
.vxe-sort--desc-btn {
|
|
142
|
+
width: 6px;
|
|
143
|
+
height: 10px;
|
|
144
|
+
color: #333;
|
|
145
|
+
border: none;
|
|
146
|
+
font-style: normal;
|
|
147
|
+
position: static;
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
.vxe-header--row {
|
|
152
|
+
color: #333;
|
|
153
|
+
background-color: #f5f5f5;
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
.vxe-cell--filter .vxe-filter--btn {
|
|
157
|
+
color: #666;
|
|
158
|
+
font-weight: $--font-weight-primary;
|
|
159
|
+
cursor: pointer;
|
|
160
|
+
font-size: 16px;
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
.is--filter-active .vxe-cell--filter .vxe-filter--btn {
|
|
164
|
+
color: $--color-primary;
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
.is--filter-active .vxe-cell--title {
|
|
168
|
+
color: $--color-primary;
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
.vxe-table--render-default.size--small {
|
|
172
|
+
font-size: 14px !important;
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
.vxe-table--render-default.size--mini {
|
|
176
|
+
font-size: 14px !important;
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
.vxe-header--row th,
|
|
180
|
+
th.vxe-header--column {
|
|
181
|
+
position: relative;
|
|
182
|
+
font-weight: $--font-weight-primary;
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
.vxe-table--tooltip-wrapper {
|
|
186
|
+
z-index: 9999 !important;
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
.cell-default-set-- .vxe-table--body-wrapper .vxe-body--row .vxe-body--column .vxe-cell .vxe-cell--label:empty::before {
|
|
190
|
+
content: '--';
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
.n20-table-pro.vxe-table--render-default {
|
|
194
|
+
font-family: PingFang SC, Microsoft YaHei, Arial, sans-serif !important;
|
|
195
|
+
color: #333;
|
|
196
|
+
}
|
|
197
|
+
|
|
198
|
+
.vxe-table-custom-wrap.vxe-body--column.col--ellipsis:not(.col--actived) > .vxe-cell,
|
|
199
|
+
.vxe-table--render-default .vxe-table-custom-wrap.vxe-footer--column.col--ellipsis:not(.col--actived) > .vxe-cell,
|
|
200
|
+
.vxe-table--render-default .vxe-table-custom-wrap.vxe-header--column.col--ellipsis:not(.col--actived) > .vxe-cell {
|
|
201
|
+
overflow: hidden;
|
|
202
|
+
text-overflow: ellipsis;
|
|
203
|
+
white-space: wrap !important;
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
.vxe-table--render-default.size--small .vxe-table-custom-wrap.vxe-body--column.col--ellipsis > .vxe-cell,
|
|
207
|
+
.vxe-table--render-default.size--small .vxe-table-custom-wrap.vxe-footer--column.col--ellipsis > .vxe-cell,
|
|
208
|
+
.vxe-table--render-default.size--small .vxe-table-custom-wrap.vxe-header--column.col--ellipsis > .vxe-cell {
|
|
209
|
+
max-height: 100%;
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
.vxe-header--column {
|
|
213
|
+
.vxe-cell {
|
|
214
|
+
justify-content: center !important;
|
|
215
|
+
}
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
.vxe-table--body-wrapper,
|
|
219
|
+
.vxe-table--fixed-left-body-wrapper,
|
|
220
|
+
.vxe-table--fixed-right-body-wrapper,
|
|
221
|
+
.vxe-table--footer-wrapper,
|
|
222
|
+
.vxe-table--header-wrapper {
|
|
223
|
+
overflow: hidden;
|
|
224
|
+
outline: 0;
|
|
225
|
+
scrollbar-width: auto !important;
|
|
226
|
+
-webkit-overflow-scrolling: touch;
|
|
227
|
+
}
|
|
228
|
+
@import '../../components/TableSetSize/style.scss';
|
|
229
|
+
|
|
230
|
+
.el-table-set-size-item {
|
|
231
|
+
.icon-mini {
|
|
232
|
+
background-image: url('../../components/TableSetSize/small.png');
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
.icon-mini {
|
|
236
|
+
background-image: url('../../components/TableSetSize/mini.png');
|
|
237
|
+
}
|
|
238
|
+
}
|
|
239
|
+
|
|
240
|
+
.el-table th.el-table__cell > .cell {
|
|
241
|
+
overflow: hidden;
|
|
242
|
+
text-overflow: ellipsis;
|
|
243
|
+
white-space: nowrap;
|
|
244
|
+
}
|
|
@@ -597,6 +597,23 @@ export default {
|
|
|
597
597
|
}
|
|
598
598
|
this.searchForm = { ...this.getInitialSearchValue }
|
|
599
599
|
}
|
|
600
|
+
},
|
|
601
|
+
/**
|
|
602
|
+
* 重置组件状态到初始值
|
|
603
|
+
* 供下游调用以恢复组件初始状态
|
|
604
|
+
*/
|
|
605
|
+
resetState() {
|
|
606
|
+
this.val = ''
|
|
607
|
+
this.selectedItem = '无视图'
|
|
608
|
+
this.selectItem = ''
|
|
609
|
+
this.searchValue = { ...this.getInitialSearchValue, ...this.initialValue }
|
|
610
|
+
this.searchForm = { ...this.getInitialSearchValue }
|
|
611
|
+
this.conditionGroups = []
|
|
612
|
+
this.multiple = this.defaultExpanded
|
|
613
|
+
this.checkData = []
|
|
614
|
+
this.keyIds = []
|
|
615
|
+
this.viewId = undefined
|
|
616
|
+
this._savedViewConfigs = {}
|
|
600
617
|
}
|
|
601
618
|
}
|
|
602
619
|
}
|
|
@@ -11,19 +11,14 @@
|
|
|
11
11
|
></i>
|
|
12
12
|
</div>
|
|
13
13
|
<div v-if="showSetsize" class="el-table-set-size-item m-r-0">
|
|
14
|
-
<
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
<el-dropdown-menu slot="dropdown">
|
|
23
|
-
<el-dropdown-item command="small">{{ _lang === 'zh' ? '默认' : 'small' }}</el-dropdown-item>
|
|
24
|
-
<el-dropdown-item command="mini">{{ _lang === 'zh' ? '紧凑' : 'mini' }}</el-dropdown-item>
|
|
25
|
-
</el-dropdown-menu>
|
|
26
|
-
</el-dropdown>
|
|
14
|
+
<i
|
|
15
|
+
v-title="sizeC === 'mini' ? $lc('默认') : $lc('紧凑')"
|
|
16
|
+
class="pointer color-white"
|
|
17
|
+
:class="['v3-icon-auto-height', hoverIconKey === 'height' ? 'color-white' : '']"
|
|
18
|
+
@mouseenter="hoverIconKey = 'height'"
|
|
19
|
+
@mouseleave="hoverIconKey = null"
|
|
20
|
+
@click="setSize(sizeC === 'mini' ? 'small' : 'mini')"
|
|
21
|
+
></i>
|
|
27
22
|
</div>
|
|
28
23
|
<div v-if="hasExpand" class="el-table-set-size-item m-r-0">
|
|
29
24
|
<i
|
|
@@ -38,6 +33,19 @@
|
|
|
38
33
|
@click="$emit('toggle-expand')"
|
|
39
34
|
></i>
|
|
40
35
|
</div>
|
|
36
|
+
<div v-if="showPinBtn" class="el-table-set-size-item m-r-0">
|
|
37
|
+
<i
|
|
38
|
+
v-title="isOperateFixed ? $lc('取消固定') : $lc('固定操作列')"
|
|
39
|
+
class="pointer"
|
|
40
|
+
:class="[
|
|
41
|
+
isOperateFixed ? 'v3-icon-unlock' : 'v3-icon-lock',
|
|
42
|
+
hoverIconKey === 'pinOperate' ? 'color-white' : ''
|
|
43
|
+
]"
|
|
44
|
+
@mouseenter="hoverIconKey = 'pinOperate'"
|
|
45
|
+
@mouseleave="hoverIconKey = null"
|
|
46
|
+
@click="$emit('toggle-operate-fixed', !isOperateFixed)"
|
|
47
|
+
></i>
|
|
48
|
+
</div>
|
|
41
49
|
</div>
|
|
42
50
|
</template>
|
|
43
51
|
|
|
@@ -53,6 +61,14 @@ export default {
|
|
|
53
61
|
type: Boolean,
|
|
54
62
|
default: true
|
|
55
63
|
},
|
|
64
|
+
showPinBtn: {
|
|
65
|
+
type: Boolean,
|
|
66
|
+
default: false
|
|
67
|
+
},
|
|
68
|
+
isOperateFixed: {
|
|
69
|
+
type: Boolean,
|
|
70
|
+
default: false
|
|
71
|
+
},
|
|
56
72
|
size: {
|
|
57
73
|
type: String,
|
|
58
74
|
default: 'small'
|
|
@@ -62,7 +78,7 @@ export default {
|
|
|
62
78
|
default: () => ({
|
|
63
79
|
border: false,
|
|
64
80
|
size: 'mini',
|
|
65
|
-
stripe:
|
|
81
|
+
stripe: false
|
|
66
82
|
})
|
|
67
83
|
},
|
|
68
84
|
small: {
|
|
@@ -81,11 +97,11 @@ export default {
|
|
|
81
97
|
},
|
|
82
98
|
// 当前可见操作项数量
|
|
83
99
|
activeItemCount() {
|
|
84
|
-
return [this.showColumn, this.showSetsize, this.hasExpand].filter(Boolean).length
|
|
100
|
+
return [this.showColumn, this.showSetsize, this.hasExpand, this.showPinBtn].filter(Boolean).length
|
|
85
101
|
},
|
|
86
102
|
// 根据可见项数动态计算宽度
|
|
87
103
|
hoverWidth() {
|
|
88
|
-
const widthMap = { 3: '
|
|
104
|
+
const widthMap = { 4: '136px', 3: '132px', 2: '88px', 1: '40px', 0: '0px' }
|
|
89
105
|
return widthMap[this.activeItemCount] || '0px'
|
|
90
106
|
}
|
|
91
107
|
},
|