eoss-ui 0.5.60 → 0.5.62
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/button-group.js +177 -87
- package/lib/button.js +14 -8
- package/lib/calendar.js +3 -3
- package/lib/card.js +6 -6
- package/lib/checkbox-group.js +14 -8
- package/lib/data-table-form.js +14 -8
- package/lib/data-table.js +129 -104
- package/lib/date-picker.js +14 -8
- package/lib/dialog.js +17 -11
- package/lib/eoss-ui.common.js +463 -311
- package/lib/flow-group.js +14 -8
- package/lib/flow-list.js +14 -8
- package/lib/flow.js +14 -8
- package/lib/form.js +14 -8
- package/lib/handle-user.js +14 -8
- package/lib/handler.js +14 -8
- package/lib/icon.js +31 -15
- package/lib/icons.js +2 -2
- package/lib/index.js +1 -1
- package/lib/input-number.js +14 -8
- package/lib/input.js +14 -8
- package/lib/login.js +26 -13
- package/lib/main.js +23 -14
- package/lib/nav.js +14 -8
- package/lib/page.js +14 -8
- package/lib/player.js +18 -12
- package/lib/qr-code.js +16 -10
- package/lib/radio-group.js +14 -8
- package/lib/retrial-auth.js +14 -8
- package/lib/select-ganged.js +14 -8
- package/lib/select.js +14 -8
- package/lib/selector-panel.js +17 -11
- package/lib/selector.js +18 -23
- package/lib/sizer.js +14 -8
- package/lib/steps.js +14 -8
- package/lib/switch.js +14 -8
- package/lib/table-form.js +14 -8
- package/lib/tabs.js +14 -8
- package/lib/theme-chalk/base.css +1 -1
- package/lib/theme-chalk/button.css +1 -1
- package/lib/theme-chalk/calendar.css +1 -0
- package/lib/theme-chalk/card.css +1 -1
- package/lib/theme-chalk/cascader.css +0 -1
- package/lib/theme-chalk/icon.css +1 -1
- package/lib/theme-chalk/index.css +1 -1
- package/lib/theme-chalk/main.css +1 -1
- package/lib/theme-chalk/menu.css +1 -1
- package/lib/theme-chalk/sizer.css +1 -1
- package/lib/theme-chalk/toolbar.css +1 -1
- package/lib/theme-chalk/upload.css +1 -1
- package/lib/tips.js +14 -8
- package/lib/toolbar.js +47 -26
- package/lib/tree-group.js +28 -11
- package/lib/tree.js +14 -8
- package/lib/upload.js +17 -11
- package/lib/utils/util.js +14 -8
- package/lib/wujie.js +14 -8
- package/lib/wxlogin.js +14 -8
- package/package.json +3 -2
- package/packages/button-group/src/main.vue +75 -37
- package/packages/calendar/src/main.vue +1 -1
- package/packages/card/src/main.vue +6 -6
- package/packages/data-table/src/main.vue +11 -2
- package/packages/icon/src/main.vue +10 -4
- package/packages/login/src/main.vue +14 -3
- package/packages/main/src/main.vue +4 -1
- package/packages/selector/src/main.vue +0 -1
- package/packages/theme-chalk/lib/base.css +1 -1
- package/packages/theme-chalk/lib/button.css +1 -1
- package/packages/theme-chalk/lib/calendar.css +1 -0
- package/packages/theme-chalk/lib/card.css +1 -1
- package/packages/theme-chalk/lib/cascader.css +0 -1
- package/packages/theme-chalk/lib/icon.css +1 -1
- package/packages/theme-chalk/lib/index.css +1 -1
- package/packages/theme-chalk/lib/main.css +1 -1
- package/packages/theme-chalk/lib/menu.css +1 -1
- package/packages/theme-chalk/lib/sizer.css +1 -1
- package/packages/theme-chalk/lib/toolbar.css +1 -1
- package/packages/theme-chalk/lib/upload.css +1 -1
- package/packages/theme-chalk/src/button.scss +3 -0
- package/packages/theme-chalk/src/calendar.scss +110 -0
- package/packages/theme-chalk/src/card.scss +5 -2
- package/packages/theme-chalk/src/cascader.scss +0 -109
- package/packages/theme-chalk/src/icon.scss +4 -3
- package/packages/theme-chalk/src/toolbar.scss +8 -0
- package/packages/toolbar/src/main.vue +60 -33
- package/packages/tree-group/src/main.vue +12 -1
- package/src/index.js +1 -1
- package/src/utils/util.js +14 -9
|
@@ -115,10 +115,13 @@ export default {
|
|
|
115
115
|
this.$emit('tabs', { item: res, index: num });
|
|
116
116
|
},
|
|
117
117
|
hanleReset() {
|
|
118
|
+
this.reset();
|
|
119
|
+
this.$emit('reset', this.searchData);
|
|
120
|
+
},
|
|
121
|
+
reset() {
|
|
118
122
|
this.$refs.filter && this.$refs.filter.resetFields();
|
|
119
123
|
this.searchData = JSON.parse(JSON.stringify(this.searchValue));
|
|
120
124
|
this.advancedData = JSON.parse(JSON.stringify(this.advanceValue));
|
|
121
|
-
this.$emit('reset', this.searchData);
|
|
122
125
|
},
|
|
123
126
|
hanleCancel() {
|
|
124
127
|
this.show = false;
|
|
@@ -134,7 +137,8 @@ export default {
|
|
|
134
137
|
let filter = [];
|
|
135
138
|
|
|
136
139
|
this.contents.forEach((items) => {
|
|
137
|
-
let { config, type, reset, multiCondition, contents, ...other } =
|
|
140
|
+
let { config, type, reset, multiCondition, contents, group, ...other } =
|
|
141
|
+
items;
|
|
138
142
|
if (type === 'text') {
|
|
139
143
|
text = [
|
|
140
144
|
h(
|
|
@@ -151,41 +155,64 @@ export default {
|
|
|
151
155
|
)
|
|
152
156
|
];
|
|
153
157
|
}
|
|
154
|
-
if (
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
158
|
+
if (
|
|
159
|
+
type === 'button' ||
|
|
160
|
+
type === 'button-group' ||
|
|
161
|
+
type === 'buttonGroup'
|
|
162
|
+
) {
|
|
163
|
+
if (type === 'button-group' || type === 'buttonGroup' || group) {
|
|
164
|
+
buttons = [
|
|
165
|
+
h('es-button-group', {
|
|
166
|
+
class: 'es-toolbar-button-group',
|
|
167
|
+
props: {
|
|
168
|
+
moreText: '更多',
|
|
169
|
+
size: 'medium',
|
|
170
|
+
...other,
|
|
171
|
+
contents: contents
|
|
172
|
+
},
|
|
173
|
+
on: {
|
|
174
|
+
handleClick: (res) => {
|
|
175
|
+
this.handleClick(res.handle);
|
|
166
176
|
}
|
|
167
|
-
}
|
|
168
|
-
)
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
177
|
+
}
|
|
178
|
+
})
|
|
179
|
+
];
|
|
180
|
+
} else {
|
|
181
|
+
contents.forEach((item) => {
|
|
182
|
+
if (!item.hide && (item.upload || (item.code && item.ownId))) {
|
|
183
|
+
buttons.push(
|
|
184
|
+
h('es-upload', {
|
|
185
|
+
class: 'el-button',
|
|
174
186
|
attrs: {
|
|
175
187
|
...item,
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
this.handleClick(item);
|
|
181
|
-
}
|
|
188
|
+
method: 'post',
|
|
189
|
+
btnSize: 'medium',
|
|
190
|
+
showFileList: false,
|
|
191
|
+
selectType: item.type ? item.type : ''
|
|
182
192
|
}
|
|
183
|
-
}
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
193
|
+
})
|
|
194
|
+
);
|
|
195
|
+
} else {
|
|
196
|
+
buttons.push(
|
|
197
|
+
h(
|
|
198
|
+
'es-button',
|
|
199
|
+
{
|
|
200
|
+
attrs: {
|
|
201
|
+
...item,
|
|
202
|
+
size: 'medium'
|
|
203
|
+
},
|
|
204
|
+
on: {
|
|
205
|
+
click: () => {
|
|
206
|
+
this.handleClick(item);
|
|
207
|
+
}
|
|
208
|
+
}
|
|
209
|
+
},
|
|
210
|
+
item.text
|
|
211
|
+
)
|
|
212
|
+
);
|
|
213
|
+
}
|
|
214
|
+
});
|
|
215
|
+
}
|
|
189
216
|
}
|
|
190
217
|
if (type === 'tabs') {
|
|
191
218
|
buttons = buttons.concat([
|
|
@@ -227,15 +227,22 @@ export default {
|
|
|
227
227
|
default: '#/empty'
|
|
228
228
|
},
|
|
229
229
|
zoom: false,
|
|
230
|
+
iframe: Boolean,
|
|
231
|
+
//点击节点作为table参数
|
|
230
232
|
clickedAsSearch: {
|
|
231
233
|
type: Boolean,
|
|
232
234
|
default: true
|
|
233
235
|
},
|
|
236
|
+
//选择节点作为table参数
|
|
234
237
|
checkedAsSearch: {
|
|
235
238
|
type: Boolean,
|
|
236
239
|
default: true
|
|
237
240
|
},
|
|
238
|
-
|
|
241
|
+
//点击节点清空table搜索参数
|
|
242
|
+
clickeResetSearch: {
|
|
243
|
+
type: Boolean,
|
|
244
|
+
default: false
|
|
245
|
+
}
|
|
239
246
|
},
|
|
240
247
|
computed: {
|
|
241
248
|
wujieName() {
|
|
@@ -467,6 +474,10 @@ export default {
|
|
|
467
474
|
this.$emit('tab-click', this.tabs[parseInt(this.active, 10)]);
|
|
468
475
|
},
|
|
469
476
|
handleNodeClick(data, node, tabs) {
|
|
477
|
+
if (this.clickeResetSearch) {
|
|
478
|
+
let ref = table.ref ? table.ref : 'esDataTable';
|
|
479
|
+
this.$refs[ref].reset();
|
|
480
|
+
}
|
|
470
481
|
if (this.clickedAsSearch) {
|
|
471
482
|
this.checkeds = data;
|
|
472
483
|
}
|
package/src/index.js
CHANGED
package/src/utils/util.js
CHANGED
|
@@ -314,7 +314,7 @@ const ajax = function ({
|
|
|
314
314
|
error.message = '未授权,请重新登录';
|
|
315
315
|
break;
|
|
316
316
|
case 403:
|
|
317
|
-
error.message = '
|
|
317
|
+
error.message = '服务器错误';
|
|
318
318
|
break;
|
|
319
319
|
case 404:
|
|
320
320
|
error.message = '网络请求不存在';
|
|
@@ -326,7 +326,7 @@ const ajax = function ({
|
|
|
326
326
|
error.message = '请求超时';
|
|
327
327
|
break;
|
|
328
328
|
case 500:
|
|
329
|
-
error.message = '
|
|
329
|
+
error.message = '服务器错误';
|
|
330
330
|
break;
|
|
331
331
|
case 501:
|
|
332
332
|
error.message = '网络未实现';
|
|
@@ -664,19 +664,23 @@ const dayOfMonth = function (date) {
|
|
|
664
664
|
* @desc:添加js内容
|
|
665
665
|
* @author huangbo
|
|
666
666
|
* @date 2022年5月7日
|
|
667
|
-
* @param {Function} [
|
|
667
|
+
* @param {Function} [callback] - 函数
|
|
668
668
|
* @param {Number} [wait] - 延迟毫秒数
|
|
669
669
|
* @param {Boolean} [immediate] - 是否首次触发执行
|
|
670
670
|
**/
|
|
671
671
|
|
|
672
|
-
const debounce = function (callback,
|
|
673
|
-
let timeout
|
|
672
|
+
const debounce = function (callback, wait) {
|
|
673
|
+
let timeout;
|
|
674
674
|
return function () {
|
|
675
|
-
|
|
676
|
-
|
|
675
|
+
let context = this;
|
|
676
|
+
let args = arguments;
|
|
677
|
+
if (timeout) clearTimeout(timeout);
|
|
678
|
+
timeout = setTimeout(() => {
|
|
679
|
+
callback.apply(context, args);
|
|
680
|
+
}, wait || 500);
|
|
677
681
|
};
|
|
678
|
-
|
|
679
682
|
};
|
|
683
|
+
|
|
680
684
|
/**
|
|
681
685
|
* delUrlParam
|
|
682
686
|
* @desc:删除url指定参数
|
|
@@ -2840,7 +2844,8 @@ const toFunction = function (str) {
|
|
|
2840
2844
|
* @param {string} [$color] - 颜色值
|
|
2841
2845
|
**/
|
|
2842
2846
|
const updateTheme = function (color, send) {
|
|
2843
|
-
color = color ? color : '#409eff';
|
|
2847
|
+
color = color && startWith(color, '#') ? color : '#409eff';
|
|
2848
|
+
|
|
2844
2849
|
if (send === undefined) {
|
|
2845
2850
|
send = true;
|
|
2846
2851
|
}
|