eoss-ui 0.5.45 → 0.5.47
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.js +137 -144
- package/lib/calendar.js +769 -0
- package/lib/cascader.js +2 -2
- package/lib/checkbox-group.js +4 -2
- package/lib/clients.js +2 -2
- package/lib/data-table-form.js +36 -13
- package/lib/data-table.js +39 -37
- package/lib/date-picker.js +2 -2
- package/lib/dialog.js +10 -13
- package/lib/enterprise.js +2 -2
- package/lib/eoss-ui.common.js +1265 -721
- package/lib/error-page.js +2 -2
- package/lib/flow-group.js +9 -21
- package/lib/flow-list.js +2 -2
- package/lib/form.js +215 -231
- package/lib/handle-user.js +5 -11
- package/lib/handler.js +2 -2
- package/lib/icons.js +2 -2
- package/lib/index.js +1 -1
- package/lib/input-number.js +2 -2
- package/lib/input.js +2 -2
- package/lib/label.js +2 -2
- package/lib/menu.js +2 -2
- package/lib/nav.js +5 -5
- package/lib/notify.js +2 -2
- package/lib/page.js +2 -2
- package/lib/pagination.js +2 -2
- package/lib/player.js +2 -2
- package/lib/qr-code.js +2 -2
- package/lib/radio-group.js +2 -2
- package/lib/retrial-auth.js +2 -2
- package/lib/select-ganged.js +2 -2
- package/lib/select.js +2 -2
- package/lib/selector.js +2 -2
- package/lib/sizer.js +9 -9
- package/lib/steps.js +2 -2
- package/lib/switch.js +2 -2
- package/lib/table-form.js +2 -2
- package/lib/tabs-panel.js +2 -2
- package/lib/tabs.js +2 -2
- package/lib/theme-chalk/cascader.css +1 -0
- package/lib/theme-chalk/data-table-form.css +1 -1
- package/lib/theme-chalk/index.css +1 -1
- package/lib/theme-chalk/toolbar.css +1 -1
- package/lib/tips.js +2 -2
- package/lib/toolbar.js +22 -37
- package/lib/tree-group.js +2 -2
- package/lib/tree.js +2 -2
- package/lib/wujie.js +2 -2
- package/lib/wxlogin.js +2 -2
- package/package.json +1 -1
- package/packages/button/src/main.vue +2 -9
- package/packages/calendar/index.js +5 -0
- package/packages/calendar/src/main.vue +386 -0
- package/packages/data-table/src/main.vue +40 -28
- package/packages/data-table-form/src/main.vue +30 -23
- package/packages/data-table-form/src/table.vue +16 -3
- package/packages/dialog/src/main.vue +5 -9
- package/packages/flow-group/src/main.vue +5 -17
- package/packages/handle-user/src/main.vue +1 -7
- package/packages/nav/src/main.vue +1 -1
- package/packages/theme-chalk/gulpfile.js +25 -0
- package/packages/theme-chalk/src/cascader.scss +93 -0
- package/packages/theme-chalk/src/data-table-form.scss +11 -0
- package/packages/theme-chalk/src/index.scss +2 -1
- package/packages/theme-chalk/src/toolbar.scss +13 -11
- package/packages/toolbar/src/main.vue +39 -52
- package/src/index.js +7 -4
- package/CHANGELOG.md +0 -929
- package/packages/theme-chalk/lib/base.css +0 -1
- package/packages/theme-chalk/lib/button-group.css +0 -1
- package/packages/theme-chalk/lib/button.css +0 -1
- package/packages/theme-chalk/lib/card.css +0 -1
- package/packages/theme-chalk/lib/checkbox-group.css +0 -1
- package/packages/theme-chalk/lib/clients.css +0 -1
- package/packages/theme-chalk/lib/data-table-form.css +0 -1
- package/packages/theme-chalk/lib/data-table.css +0 -1
- package/packages/theme-chalk/lib/date-picker.css +0 -1
- package/packages/theme-chalk/lib/dialog.css +0 -1
- package/packages/theme-chalk/lib/enterprise.css +0 -1
- package/packages/theme-chalk/lib/error-page.css +0 -1
- package/packages/theme-chalk/lib/flow-group.css +0 -1
- package/packages/theme-chalk/lib/flow-list.css +0 -1
- package/packages/theme-chalk/lib/flow.css +0 -1
- package/packages/theme-chalk/lib/fonts/iconfont.ttf +0 -0
- package/packages/theme-chalk/lib/fonts/iconfont.woff +0 -0
- package/packages/theme-chalk/lib/form.css +0 -1
- package/packages/theme-chalk/lib/handle-user.css +0 -1
- package/packages/theme-chalk/lib/handler.css +0 -1
- package/packages/theme-chalk/lib/icon.css +0 -1
- package/packages/theme-chalk/lib/icons.css +0 -1
- package/packages/theme-chalk/lib/index.css +0 -1
- package/packages/theme-chalk/lib/input-number.css +0 -0
- package/packages/theme-chalk/lib/input.css +0 -1
- package/packages/theme-chalk/lib/label.css +0 -1
- package/packages/theme-chalk/lib/layout.css +0 -1
- package/packages/theme-chalk/lib/login.css +0 -1
- package/packages/theme-chalk/lib/main.css +0 -1
- package/packages/theme-chalk/lib/mainComp.css +0 -0
- package/packages/theme-chalk/lib/menu.css +0 -1
- package/packages/theme-chalk/lib/nav.css +0 -1
- package/packages/theme-chalk/lib/notify.css +0 -0
- package/packages/theme-chalk/lib/page.css +0 -1
- package/packages/theme-chalk/lib/pagination.css +0 -1
- package/packages/theme-chalk/lib/player.css +0 -1
- package/packages/theme-chalk/lib/qr-code.css +0 -1
- package/packages/theme-chalk/lib/radio-group.css +0 -1
- package/packages/theme-chalk/lib/retrial-auth.css +0 -1
- package/packages/theme-chalk/lib/select-ganged.css +0 -1
- package/packages/theme-chalk/lib/select.css +0 -1
- package/packages/theme-chalk/lib/selector-panel.css +0 -1
- package/packages/theme-chalk/lib/selector.css +0 -1
- package/packages/theme-chalk/lib/sizer.css +0 -1
- package/packages/theme-chalk/lib/steps.css +0 -1
- package/packages/theme-chalk/lib/switch.css +0 -1
- package/packages/theme-chalk/lib/table-form.css +0 -0
- package/packages/theme-chalk/lib/tabs-panel.css +0 -0
- package/packages/theme-chalk/lib/tabs.css +0 -1
- package/packages/theme-chalk/lib/tips.css +0 -1
- package/packages/theme-chalk/lib/toolbar.css +0 -1
- package/packages/theme-chalk/lib/tree-group.css +0 -1
- package/packages/theme-chalk/lib/tree.css +0 -1
- package/packages/theme-chalk/lib/upload.css +0 -1
- package/packages/theme-chalk/lib/wujie.css +0 -0
- package/packages/theme-chalk/lib/wxlogin.css +0 -1
- /package/{packages/theme-chalk/lib/cascader.css → lib/theme-chalk/calendar.css} +0 -0
- /package/packages/theme-chalk/{lib/flow-chart.css → src/calendar.scss} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
@charset "UTF-8";.es-toolbar{padding:6px 12px;border-bottom:1px solid #d9d9d9;position:relative;background-color:#fff}.es-toolbar .es-toolbar-content{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:end;-ms-flex-pack:end;justify-content:flex-end}.es-toolbar .es-toolbar-content .es-button-content{-webkit-box-flex:1;-ms-flex:1;flex:1}.es-toolbar .es-toolbar-content .es-button-content .el-button{padding:4px 8px}.es-toolbar .es-toolbar-content .es-button-content .el-button+.el-button,.es-toolbar .es-toolbar-content .es-button-content .el-button+.es-button-badge,.es-toolbar .es-toolbar-content .es-button-content .es-button-badge+.el-button{margin-left:6px}.es-toolbar .es-toolbar-content .es-form{background:0 0}.es-toolbar .es-toolbar-content .es-form .es-form-content{padding:0}.es-toolbar .es-toolbar-content .es-form .el-form-item{margin-bottom:0}.es-toolbar .es-toolbar-content .es-advanced-btn{margin-left:6px;height:32px}.es-toolbar .es-toolbar-content .es-advanced-btn .es-advanced-icon{margin-right:-8px}.es-toolbar .es-toolbar-content .es-toolbar-text{line-height:32px}.es-toolbar .es-toolbar-content .es-toolbar-info{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.es-toolbar .es-toolbar-content .es-toolbar-info .es-info{font-size:13px;margin-left:20px}.es-toolbar .es-toolbar-content .el-menu--horizontal{border-bottom:0;position:relative;bottom:-6px}.es-toolbar .es-toolbar-content .el-menu-item{height:32px;line-height:24px}.es-toolbar .es-toolbar-content .el-input__inner,.es-toolbar .es-toolbar-content .es-checkbox-group{height:32px;line-height:32px}.es-toolbar .es-toolbar-content .es-radio-group,.es-toolbar .es-toolbar-content .es-switch-content{line-height:32px}.es-toolbar .es-toolbar-content .el-switch{top:-2px}.es-toolbar .es-toolbar-content .el-button span{line-height:14px}.es-toolbar .es-toolbar-content .el-checkbox:not(:last-child),.es-toolbar .es-toolbar-content .el-radio:not(:last-child){margin-right:8px}.es-toolbar .es-toolbar-content .el-form-item.es-toolbar-item-checkbox+.el-form-item,.es-toolbar .es-toolbar-content .el-form-item.es-toolbar-item-radio+.el-form-item,.es-toolbar .es-toolbar-content .el-form-item.es-toolbar-item-switch+.el-form-item{margin-left:16px}.es-toolbar .es-toolbar-content .el-form-item .el-input__icon{line-height:32px;vertical-align:top}.es-toolbar .es-toolbar-content .es-form-search-small .el-input__inner{width:100%;max-width:156px}.es-toolbar .es-toolbar-content .es-form-search-small .el-input__inner.el-date-editor--daterange{max-width:300px}.es-toolbar .es-toolbar-content .es-form-search-small .el-input__inner.el-date-editor--daterange .el-input__icon,.es-toolbar .es-toolbar-content .es-form-search-small .el-input__inner.el-date-editor--daterange .el-range-separator{line-height:24px}.es-toolbar .es-advanced-filter{margin-top:20px;z-index:9}.es-toolbar .es-advanced-filter.es-absolute{position:absolute;left:0;top:45px;right:0;margin-top:0;-webkit-box-shadow:0 1px 10px rgba(0,0,0,.05),0 4px 5px rgba(0,0,0,.08),0 2px 4px -1px rgba(0,0,0,.12);box-shadow:0 1px 10px rgba(0,0,0,.05),0 4px 5px rgba(0,0,0,.08),0 2px 4px -1px rgba(0,0,0,.12);border-bottom-left-radius:6px;border-bottom-right-radius:6px}.es-toolbar .es-advanced-filter.es-absolute .es-form{background-color:#fff;border:1px solid #d9d9d9;border-bottom-left-radius:6px;border-bottom-right-radius:6px;border-top:0;padding:20px 20px 20px 10px}
|
|
1
|
+
@charset "UTF-8";.es-toolbar{padding:6px 12px;border-bottom:1px solid #d9d9d9;position:relative;background-color:#fff}.es-toolbar .es-toolbar-content{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:end;-ms-flex-pack:end;justify-content:flex-end}.es-toolbar .es-toolbar-content .es-button-content{-webkit-box-flex:1;-ms-flex:1;flex:1}.es-toolbar .es-toolbar-content .es-button-content .el-button{padding:4px 8px}.es-toolbar .es-toolbar-content .es-button-content .el-button+.el-button,.es-toolbar .es-toolbar-content .es-button-content .el-button+.es-button-badge,.es-toolbar .es-toolbar-content .es-button-content .es-button-badge+.el-button{margin-left:6px}.es-toolbar .es-toolbar-content .es-form{background:0 0}.es-toolbar .es-toolbar-content .es-form .es-form-content{padding:0}.es-toolbar .es-toolbar-content .es-form .el-form-item{margin-bottom:0}.es-toolbar .es-toolbar-content .es-advanced-btn{margin-left:6px;height:32px}.es-toolbar .es-toolbar-content .es-advanced-btn .es-advanced-icon{margin-right:-8px}.es-toolbar .es-toolbar-content .es-toolbar-text{line-height:32px}.es-toolbar .es-toolbar-content .es-toolbar-info{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.es-toolbar .es-toolbar-content .es-toolbar-info .es-info{font-size:13px;margin-left:20px}.es-toolbar .es-toolbar-content .el-menu--horizontal{border-bottom:0;position:relative;bottom:-6px}.es-toolbar .es-toolbar-content .el-menu-item{height:32px;line-height:24px}.es-toolbar .es-toolbar-content .el-input__inner,.es-toolbar .es-toolbar-content .es-checkbox-group{height:32px;line-height:32px}.es-toolbar .es-toolbar-content .es-radio-group,.es-toolbar .es-toolbar-content .es-switch-content{line-height:32px}.es-toolbar .es-toolbar-content .el-switch{top:-2px}.es-toolbar .es-toolbar-content .el-button span{line-height:14px}.es-toolbar .es-toolbar-content .el-checkbox:not(:last-child),.es-toolbar .es-toolbar-content .el-radio:not(:last-child){margin-right:8px}.es-toolbar .es-toolbar-content .el-form-item.es-toolbar-item-checkbox+.el-form-item,.es-toolbar .es-toolbar-content .el-form-item.es-toolbar-item-radio+.el-form-item,.es-toolbar .es-toolbar-content .el-form-item.es-toolbar-item-switch+.el-form-item{margin-left:16px}.es-toolbar .es-toolbar-content .el-form-item .el-input__icon{line-height:32px;vertical-align:top}.es-toolbar .es-toolbar-content .es-form-search-small .el-input__inner{width:100%;max-width:156px}.es-toolbar .es-toolbar-content .es-form-search-small .el-input__inner.el-date-editor--daterange{max-width:300px}.es-toolbar .es-toolbar-content .es-form-search-small .el-input__inner.el-date-editor--daterange .el-input__icon,.es-toolbar .es-toolbar-content .es-form-search-small .el-input__inner.el-date-editor--daterange .el-range-separator{line-height:24px}.es-toolbar .es-form-search-small .el-form-item__content{line-height:32px!important}.es-toolbar .es-form-search-small .el-form-item__label{line-height:32px!important;height:32px}.es-toolbar .el-button.es-upload{padding:0!important;border:0!important}.es-toolbar .es-advanced-filter{margin-top:20px;z-index:9}.es-toolbar .es-advanced-filter.es-absolute{position:absolute;left:0;top:45px;right:0;margin-top:0;-webkit-box-shadow:0 1px 10px rgba(0,0,0,.05),0 4px 5px rgba(0,0,0,.08),0 2px 4px -1px rgba(0,0,0,.12);box-shadow:0 1px 10px rgba(0,0,0,.05),0 4px 5px rgba(0,0,0,.08),0 2px 4px -1px rgba(0,0,0,.12);border-bottom-left-radius:6px;border-bottom-right-radius:6px}.es-toolbar .es-advanced-filter.es-absolute .es-form{background-color:#fff;border:1px solid #d9d9d9;border-bottom-left-radius:6px;border-bottom-right-radius:6px;border-top:0;padding:20px 20px 20px 10px}
|
package/lib/tips.js
CHANGED
|
@@ -82,7 +82,7 @@ module.exports =
|
|
|
82
82
|
/******/
|
|
83
83
|
/******/
|
|
84
84
|
/******/ // Load entry module and return exports
|
|
85
|
-
/******/ return __webpack_require__(__webpack_require__.s =
|
|
85
|
+
/******/ return __webpack_require__(__webpack_require__.s = 64);
|
|
86
86
|
/******/ })
|
|
87
87
|
/************************************************************************/
|
|
88
88
|
/******/ ({
|
|
@@ -3565,7 +3565,7 @@ module.exports = require("json-bigint");
|
|
|
3565
3565
|
|
|
3566
3566
|
/***/ }),
|
|
3567
3567
|
|
|
3568
|
-
/***/
|
|
3568
|
+
/***/ 64:
|
|
3569
3569
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
3570
3570
|
|
|
3571
3571
|
"use strict";
|
package/lib/toolbar.js
CHANGED
|
@@ -82,7 +82,7 @@ module.exports =
|
|
|
82
82
|
/******/
|
|
83
83
|
/******/
|
|
84
84
|
/******/ // Load entry module and return exports
|
|
85
|
-
/******/ return __webpack_require__(__webpack_require__.s =
|
|
85
|
+
/******/ return __webpack_require__(__webpack_require__.s = 80);
|
|
86
86
|
/******/ })
|
|
87
87
|
/************************************************************************/
|
|
88
88
|
/******/ ({
|
|
@@ -192,7 +192,7 @@ function normalizeComponent(
|
|
|
192
192
|
|
|
193
193
|
/***/ }),
|
|
194
194
|
|
|
195
|
-
/***/
|
|
195
|
+
/***/ 80:
|
|
196
196
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
197
197
|
|
|
198
198
|
"use strict";
|
|
@@ -256,41 +256,25 @@ function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in ob
|
|
|
256
256
|
default: 'auto'
|
|
257
257
|
}
|
|
258
258
|
},
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
if (this.contents[i].type === 'search') {
|
|
265
|
-
value = this.contents[i].value || this.contents[i].searchValue;
|
|
266
|
-
break;
|
|
267
|
-
}
|
|
268
|
-
}
|
|
269
|
-
return value ? value : this.searchValue;
|
|
270
|
-
},
|
|
271
|
-
set: function set(val) {
|
|
272
|
-
return val;
|
|
259
|
+
watch: {
|
|
260
|
+
searchValue: {
|
|
261
|
+
deep: true,
|
|
262
|
+
handler: function handler(val) {
|
|
263
|
+
this.searchData = JSON.parse(JSON.stringify(val));
|
|
273
264
|
}
|
|
274
265
|
},
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
if (this.contents[i].type === 'filter') {
|
|
280
|
-
value = this.contents[i].value || this.contents[i].searchValue;
|
|
281
|
-
break;
|
|
282
|
-
}
|
|
283
|
-
}
|
|
284
|
-
return value ? value : this.advanceValue;
|
|
285
|
-
},
|
|
286
|
-
set: function set(val) {
|
|
287
|
-
return val;
|
|
266
|
+
advanceValue: {
|
|
267
|
+
deep: true,
|
|
268
|
+
handler: function handler(val) {
|
|
269
|
+
this.advancedData = JSON.parse(JSON.stringify(val));
|
|
288
270
|
}
|
|
289
271
|
}
|
|
290
272
|
},
|
|
291
273
|
data: function data() {
|
|
292
274
|
return {
|
|
293
|
-
show: false
|
|
275
|
+
show: false,
|
|
276
|
+
searchData: JSON.parse(JSON.stringify(this.searchValue)),
|
|
277
|
+
advancedData: JSON.parse(JSON.stringify(this.advanceValue))
|
|
294
278
|
};
|
|
295
279
|
},
|
|
296
280
|
created: function created() {
|
|
@@ -340,13 +324,14 @@ function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in ob
|
|
|
340
324
|
},
|
|
341
325
|
hanleReset: function hanleReset() {
|
|
342
326
|
this.$refs.filter && this.$refs.filter.resetFields();
|
|
343
|
-
this.searchData =
|
|
344
|
-
this.advancedData =
|
|
345
|
-
this.$emit('reset');
|
|
327
|
+
this.searchData = JSON.parse(JSON.stringify(this.searchValue));
|
|
328
|
+
this.advancedData = JSON.parse(JSON.stringify(this.advanceValue));
|
|
329
|
+
this.$emit('reset', this.searchData);
|
|
346
330
|
},
|
|
347
331
|
hanleCancel: function hanleCancel() {
|
|
348
332
|
this.show = false;
|
|
349
|
-
this
|
|
333
|
+
this.advancedData = JSON.parse(JSON.stringify(this.advanceValue));
|
|
334
|
+
this.$emit('cancel', this.advancedData);
|
|
350
335
|
}
|
|
351
336
|
},
|
|
352
337
|
render: function render(h) {
|
|
@@ -483,8 +468,8 @@ function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in ob
|
|
|
483
468
|
name: 'show',
|
|
484
469
|
value: _this2.show
|
|
485
470
|
}]
|
|
486
|
-
}, [h('es-form', {
|
|
487
|
-
class: 'es-form-
|
|
471
|
+
}, [_this2.show ? h('es-form', {
|
|
472
|
+
class: 'es-form-advanced-filter',
|
|
488
473
|
ref: 'filter',
|
|
489
474
|
props: _extends({}, other, config || {}, {
|
|
490
475
|
size: 'medium',
|
|
@@ -496,7 +481,7 @@ function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in ob
|
|
|
496
481
|
submit: _this2.hanleSubmit,
|
|
497
482
|
reset: _this2.hanleCancel
|
|
498
483
|
}
|
|
499
|
-
}, [])])]);
|
|
484
|
+
}, []) : ''])]);
|
|
500
485
|
}
|
|
501
486
|
});
|
|
502
487
|
var box = [h('div', {
|
package/lib/tree-group.js
CHANGED
|
@@ -82,7 +82,7 @@ module.exports =
|
|
|
82
82
|
/******/
|
|
83
83
|
/******/
|
|
84
84
|
/******/ // Load entry module and return exports
|
|
85
|
-
/******/ return __webpack_require__(__webpack_require__.s =
|
|
85
|
+
/******/ return __webpack_require__(__webpack_require__.s = 66);
|
|
86
86
|
/******/ })
|
|
87
87
|
/************************************************************************/
|
|
88
88
|
/******/ ({
|
|
@@ -3565,7 +3565,7 @@ module.exports = require("json-bigint");
|
|
|
3565
3565
|
|
|
3566
3566
|
/***/ }),
|
|
3567
3567
|
|
|
3568
|
-
/***/
|
|
3568
|
+
/***/ 66:
|
|
3569
3569
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
3570
3570
|
|
|
3571
3571
|
"use strict";
|
package/lib/tree.js
CHANGED
|
@@ -82,7 +82,7 @@ module.exports =
|
|
|
82
82
|
/******/
|
|
83
83
|
/******/
|
|
84
84
|
/******/ // Load entry module and return exports
|
|
85
|
-
/******/ return __webpack_require__(__webpack_require__.s =
|
|
85
|
+
/******/ return __webpack_require__(__webpack_require__.s = 65);
|
|
86
86
|
/******/ })
|
|
87
87
|
/************************************************************************/
|
|
88
88
|
/******/ ({
|
|
@@ -3565,7 +3565,7 @@ module.exports = require("json-bigint");
|
|
|
3565
3565
|
|
|
3566
3566
|
/***/ }),
|
|
3567
3567
|
|
|
3568
|
-
/***/
|
|
3568
|
+
/***/ 65:
|
|
3569
3569
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
3570
3570
|
|
|
3571
3571
|
"use strict";
|
package/lib/wujie.js
CHANGED
|
@@ -82,7 +82,7 @@ module.exports =
|
|
|
82
82
|
/******/
|
|
83
83
|
/******/
|
|
84
84
|
/******/ // Load entry module and return exports
|
|
85
|
-
/******/ return __webpack_require__(__webpack_require__.s =
|
|
85
|
+
/******/ return __webpack_require__(__webpack_require__.s = 68);
|
|
86
86
|
/******/ })
|
|
87
87
|
/************************************************************************/
|
|
88
88
|
/******/ ({
|
|
@@ -3565,7 +3565,7 @@ module.exports = require("json-bigint");
|
|
|
3565
3565
|
|
|
3566
3566
|
/***/ }),
|
|
3567
3567
|
|
|
3568
|
-
/***/
|
|
3568
|
+
/***/ 68:
|
|
3569
3569
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
3570
3570
|
|
|
3571
3571
|
"use strict";
|
package/lib/wxlogin.js
CHANGED
|
@@ -82,7 +82,7 @@ module.exports =
|
|
|
82
82
|
/******/
|
|
83
83
|
/******/
|
|
84
84
|
/******/ // Load entry module and return exports
|
|
85
|
-
/******/ return __webpack_require__(__webpack_require__.s =
|
|
85
|
+
/******/ return __webpack_require__(__webpack_require__.s = 69);
|
|
86
86
|
/******/ })
|
|
87
87
|
/************************************************************************/
|
|
88
88
|
/******/ ({
|
|
@@ -3565,7 +3565,7 @@ module.exports = require("json-bigint");
|
|
|
3565
3565
|
|
|
3566
3566
|
/***/ }),
|
|
3567
3567
|
|
|
3568
|
-
/***/
|
|
3568
|
+
/***/ 69:
|
|
3569
3569
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
3570
3570
|
|
|
3571
3571
|
"use strict";
|
package/package.json
CHANGED
|
@@ -70,15 +70,8 @@ export default {
|
|
|
70
70
|
evt.preventDefault();
|
|
71
71
|
let width = 0;
|
|
72
72
|
let height = 0;
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
util.win.top.document;
|
|
76
|
-
win = util.win.top;
|
|
77
|
-
} catch (error) {
|
|
78
|
-
win = util.getMyWinTop();
|
|
79
|
-
}
|
|
80
|
-
width = win.screen.availWidth - 10;
|
|
81
|
-
height = win.screen.availHeight - 60;
|
|
73
|
+
width = util.win.top.screen.availWidth - 10;
|
|
74
|
+
height = util.win.top.screen.availHeight - 60;
|
|
82
75
|
let flag = true;
|
|
83
76
|
if (this.esForm) {
|
|
84
77
|
let params = util.getParams({ url: this.link });
|
|
@@ -0,0 +1,386 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="es-calendar">
|
|
3
|
+
<div class="es-calendar-title" v-show="showTitle">
|
|
4
|
+
<i class="es-calendar-prev es-icon-pointer-left" @click="prev"></i>
|
|
5
|
+
<div class="es-title" @click="resetDate">
|
|
6
|
+
<slot name="title" :year="year" :month="month">
|
|
7
|
+
{{ year }}年{{ month }}月
|
|
8
|
+
</slot>
|
|
9
|
+
</div>
|
|
10
|
+
<i class="es-calendar-next es-icon-pointer-right" @click="next"></i>
|
|
11
|
+
</div>
|
|
12
|
+
<ul class="es-calendar-weeks">
|
|
13
|
+
<li v-for="(item, index) in weeks" :key="index" class="es-week">
|
|
14
|
+
{{ item }}
|
|
15
|
+
</li>
|
|
16
|
+
</ul>
|
|
17
|
+
<ul class="es-calendar-days">
|
|
18
|
+
<li
|
|
19
|
+
class="es-day"
|
|
20
|
+
@click="handleClick(item)"
|
|
21
|
+
v-for="(item, index) in lists"
|
|
22
|
+
:key="`${item.year}-${item.month}-${item.date}`"
|
|
23
|
+
>
|
|
24
|
+
<div
|
|
25
|
+
class="es-day-item"
|
|
26
|
+
:class="{
|
|
27
|
+
'es-disabled-day': item.type == 0,
|
|
28
|
+
'es-today': isSelect(item, today) && mark,
|
|
29
|
+
'es-select': isSelect(item, select)
|
|
30
|
+
}"
|
|
31
|
+
>
|
|
32
|
+
{{ item.date }}
|
|
33
|
+
<slot name="mark" :data="item"></slot>
|
|
34
|
+
</div>
|
|
35
|
+
</li>
|
|
36
|
+
</ul>
|
|
37
|
+
<div class="es-calendar-switch" v-show="fold">
|
|
38
|
+
<i
|
|
39
|
+
class="es-icon-pointer-up es-switch-icon"
|
|
40
|
+
name=""
|
|
41
|
+
@click="handleHide"
|
|
42
|
+
v-show="all"
|
|
43
|
+
></i>
|
|
44
|
+
<i
|
|
45
|
+
class="es-icon-pointer-down es-switch-icon"
|
|
46
|
+
@click="handleShow"
|
|
47
|
+
v-show="!all"
|
|
48
|
+
></i>
|
|
49
|
+
</div>
|
|
50
|
+
</div>
|
|
51
|
+
</template>
|
|
52
|
+
|
|
53
|
+
<script>
|
|
54
|
+
export default {
|
|
55
|
+
name: 'esCalendar',
|
|
56
|
+
props: {
|
|
57
|
+
//显示title
|
|
58
|
+
showTitle: {
|
|
59
|
+
type: Boolean,
|
|
60
|
+
default: true
|
|
61
|
+
},
|
|
62
|
+
//指定日期
|
|
63
|
+
date: [String, Number],
|
|
64
|
+
//是否只显示本周
|
|
65
|
+
brief: Boolean,
|
|
66
|
+
//是否等指定日期传入后再渲染
|
|
67
|
+
wait: Boolean,
|
|
68
|
+
//是否显示收起展开按钮
|
|
69
|
+
fold: {
|
|
70
|
+
type: Boolean,
|
|
71
|
+
default: true
|
|
72
|
+
},
|
|
73
|
+
mark: Boolean
|
|
74
|
+
},
|
|
75
|
+
watch: {
|
|
76
|
+
date: {
|
|
77
|
+
immediate: true,
|
|
78
|
+
handler(val) {
|
|
79
|
+
if (this.wait) {
|
|
80
|
+
val && this.init();
|
|
81
|
+
} else {
|
|
82
|
+
this.init();
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
},
|
|
86
|
+
brief: {
|
|
87
|
+
immediate: true,
|
|
88
|
+
handler(val) {
|
|
89
|
+
this.all = !val;
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
},
|
|
93
|
+
computed: {
|
|
94
|
+
lists() {
|
|
95
|
+
if (this.all) {
|
|
96
|
+
return this.daysList;
|
|
97
|
+
}
|
|
98
|
+
return this.daysList.filter((item) => {
|
|
99
|
+
for (let i = 0; i < this.weekDate.length; i++) {
|
|
100
|
+
let ele = this.weekDate[i];
|
|
101
|
+
if (
|
|
102
|
+
item.year == ele.year &&
|
|
103
|
+
item.month == ele.month &&
|
|
104
|
+
item.date == ele.date
|
|
105
|
+
) {
|
|
106
|
+
return true;
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
});
|
|
110
|
+
}
|
|
111
|
+
},
|
|
112
|
+
data() {
|
|
113
|
+
return {
|
|
114
|
+
year: '',
|
|
115
|
+
_month: '',
|
|
116
|
+
weeks: ['日', '一', '二', '三', '四', '五', '六'],
|
|
117
|
+
weekDate: [],
|
|
118
|
+
week7: '',
|
|
119
|
+
today: '',
|
|
120
|
+
select: '',
|
|
121
|
+
selectDate: '',
|
|
122
|
+
daysList: [],
|
|
123
|
+
all: true,
|
|
124
|
+
week: 0,
|
|
125
|
+
prevMonthDays: 0,
|
|
126
|
+
nextMonthDays: 0,
|
|
127
|
+
days: 0
|
|
128
|
+
};
|
|
129
|
+
},
|
|
130
|
+
mounted() {},
|
|
131
|
+
methods: {
|
|
132
|
+
resetDate() {
|
|
133
|
+
this.week = 0;
|
|
134
|
+
this.init();
|
|
135
|
+
},
|
|
136
|
+
init(res) {
|
|
137
|
+
this.daysList = [];
|
|
138
|
+
let dates = this.getDays(res ? res : this.date);
|
|
139
|
+
let {
|
|
140
|
+
year,
|
|
141
|
+
month,
|
|
142
|
+
today,
|
|
143
|
+
daysList,
|
|
144
|
+
weekDate,
|
|
145
|
+
prevMonthDays,
|
|
146
|
+
nextMonthDays,
|
|
147
|
+
days
|
|
148
|
+
} = dates;
|
|
149
|
+
if (!res) {
|
|
150
|
+
this.today = `${year}/${month}/${today}`;
|
|
151
|
+
this.selectDate = today;
|
|
152
|
+
this.select = `${year}/${month}/${today}`;
|
|
153
|
+
this.$emit('select', { year, month, date: today, type: 1 });
|
|
154
|
+
}
|
|
155
|
+
this.prevMonthDays = prevMonthDays;
|
|
156
|
+
this.nextMonthDays = nextMonthDays;
|
|
157
|
+
this.days = days;
|
|
158
|
+
this.daysList = daysList;
|
|
159
|
+
this.year = year;
|
|
160
|
+
this.month = month;
|
|
161
|
+
if (!this.weekDate.length) {
|
|
162
|
+
this.weekDate = weekDate;
|
|
163
|
+
}
|
|
164
|
+
this.$emit('init', dates);
|
|
165
|
+
return dates;
|
|
166
|
+
},
|
|
167
|
+
isShow(res) {
|
|
168
|
+
if (this.all) {
|
|
169
|
+
return true;
|
|
170
|
+
}
|
|
171
|
+
return this.weekDate.filter((item) => {
|
|
172
|
+
return (
|
|
173
|
+
item.year == res.year &&
|
|
174
|
+
item.month == res.month &&
|
|
175
|
+
item.date == res.date
|
|
176
|
+
);
|
|
177
|
+
}).length;
|
|
178
|
+
},
|
|
179
|
+
isSelect(res, target) {
|
|
180
|
+
let { year, month, date } = res;
|
|
181
|
+
return target == `${year}/${month}/${date}`;
|
|
182
|
+
},
|
|
183
|
+
handleClick(res) {
|
|
184
|
+
let { year, month, date } = res;
|
|
185
|
+
this.selectDate = date;
|
|
186
|
+
this.select = `${year}/${month}/${date}`;
|
|
187
|
+
this.$emit('select', res);
|
|
188
|
+
},
|
|
189
|
+
prev() {
|
|
190
|
+
if (this.all) {
|
|
191
|
+
this.weekDate = [];
|
|
192
|
+
this.prevMonth();
|
|
193
|
+
} else {
|
|
194
|
+
this.weekDate = this.getWeekDay(-1);
|
|
195
|
+
this.$emit('prev', this.weekDate, 'week');
|
|
196
|
+
}
|
|
197
|
+
},
|
|
198
|
+
next() {
|
|
199
|
+
if (this.all) {
|
|
200
|
+
this.weekDate = [];
|
|
201
|
+
this.nextMonth();
|
|
202
|
+
} else {
|
|
203
|
+
this.weekDate = this.getWeekDay(1);
|
|
204
|
+
this.$emit('next', this.weekDate, 'week');
|
|
205
|
+
}
|
|
206
|
+
},
|
|
207
|
+
prevMonth() {
|
|
208
|
+
let year = this.year;
|
|
209
|
+
let month = this.month;
|
|
210
|
+
let dates = this.select.split('/');
|
|
211
|
+
if (month == 1) {
|
|
212
|
+
year -= 1;
|
|
213
|
+
month = 12;
|
|
214
|
+
} else {
|
|
215
|
+
month -= 1;
|
|
216
|
+
}
|
|
217
|
+
let date =
|
|
218
|
+
year == dates[0] && month == dates[1] ? dates[2] : this.prevMonthDays;
|
|
219
|
+
date = date.toString().padStart(2, '0');
|
|
220
|
+
month = month.toString().padStart(2, '0');
|
|
221
|
+
let res = this.init(`${year}/${month}/${date}`);
|
|
222
|
+
this.$emit('prev', res, 'month');
|
|
223
|
+
},
|
|
224
|
+
nextMonth() {
|
|
225
|
+
let year = this.year;
|
|
226
|
+
let month = this.month;
|
|
227
|
+
let dates = this.select.split('/');
|
|
228
|
+
if (month == 12) {
|
|
229
|
+
year += 1;
|
|
230
|
+
month = 1;
|
|
231
|
+
} else {
|
|
232
|
+
month += 1;
|
|
233
|
+
}
|
|
234
|
+
let date = year == dates[0] && month == dates[1] ? dates[2] : 1;
|
|
235
|
+
date = date.toString().padStart(2, '0');
|
|
236
|
+
month = month.toString().padStart(2, '0');
|
|
237
|
+
let res = this.init(`${year}/${month}/${date}`);
|
|
238
|
+
this.$emit('next', res, 'month');
|
|
239
|
+
},
|
|
240
|
+
//获取当月或指定日期所在月天数
|
|
241
|
+
getDays(res) {
|
|
242
|
+
const date = res ? new Date(res) : new Date();
|
|
243
|
+
const year = date.getFullYear();
|
|
244
|
+
const month = date.getMonth();
|
|
245
|
+
const today = date.getDate();
|
|
246
|
+
const week = date.getDay();
|
|
247
|
+
//此月天数
|
|
248
|
+
const days = new Date(year, month + 1, 0).getDate();
|
|
249
|
+
//此月第一天周几
|
|
250
|
+
const stratDay = new Date(year, month, 1).getDay();
|
|
251
|
+
//此月最后一天周几
|
|
252
|
+
const endDay = new Date(year, month, days).getDay();
|
|
253
|
+
//上月天数
|
|
254
|
+
const prevMonthDays =
|
|
255
|
+
month == 0
|
|
256
|
+
? new Date(year - 1, 11, 0).getDate()
|
|
257
|
+
: new Date(year, month, 0).getDate();
|
|
258
|
+
//下月天数
|
|
259
|
+
const nextMonthDays =
|
|
260
|
+
month == 11
|
|
261
|
+
? new Date(year + 1, 1, 0).getDate()
|
|
262
|
+
: new Date(year, month + 2, 0).getDate();
|
|
263
|
+
//当前日期所在的周
|
|
264
|
+
const weekDate = [{ date: today, year: year, month: month + 1 }];
|
|
265
|
+
for (let i = 0; i < week; i++) {
|
|
266
|
+
let d = i + 1;
|
|
267
|
+
if (today - d > 1) {
|
|
268
|
+
weekDate.unshift({
|
|
269
|
+
date: today - d,
|
|
270
|
+
year: year,
|
|
271
|
+
month: month + 1
|
|
272
|
+
});
|
|
273
|
+
} else {
|
|
274
|
+
weekDate.unshift({
|
|
275
|
+
date: prevMonthDays - i,
|
|
276
|
+
year: month == 0 ? year - 1 : year,
|
|
277
|
+
month: month == 0 ? 12 : month
|
|
278
|
+
});
|
|
279
|
+
}
|
|
280
|
+
}
|
|
281
|
+
for (let i = 0; i < 6 - week; i++) {
|
|
282
|
+
let d = i + 1;
|
|
283
|
+
if (today + d <= days) {
|
|
284
|
+
weekDate.unshift({
|
|
285
|
+
date: today + d,
|
|
286
|
+
year: year,
|
|
287
|
+
month: month + 1
|
|
288
|
+
});
|
|
289
|
+
} else {
|
|
290
|
+
weekDate.push({
|
|
291
|
+
date: today + d - days,
|
|
292
|
+
year: month == 11 ? year + 1 : year,
|
|
293
|
+
month: month == 11 ? 1 : month + 2
|
|
294
|
+
});
|
|
295
|
+
}
|
|
296
|
+
}
|
|
297
|
+
|
|
298
|
+
let daysList = [];
|
|
299
|
+
//本月前加入数组
|
|
300
|
+
if (stratDay > 0) {
|
|
301
|
+
for (let i = prevMonthDays; i > prevMonthDays - stratDay; i--) {
|
|
302
|
+
daysList.unshift({
|
|
303
|
+
date: i,
|
|
304
|
+
type: 0,
|
|
305
|
+
year: month == 0 ? year - 1 : year,
|
|
306
|
+
month: month == 0 ? 12 : month
|
|
307
|
+
});
|
|
308
|
+
}
|
|
309
|
+
}
|
|
310
|
+
//本月加入数组
|
|
311
|
+
for (let i = 1; i <= days; i++) {
|
|
312
|
+
daysList.push({
|
|
313
|
+
date: i,
|
|
314
|
+
type: 1,
|
|
315
|
+
year: year,
|
|
316
|
+
month: month + 1,
|
|
317
|
+
row: week < 6 && today + week > days
|
|
318
|
+
});
|
|
319
|
+
}
|
|
320
|
+
//本月后加入数组
|
|
321
|
+
if (endDay < 6) {
|
|
322
|
+
for (var i = 1; i < 6 - endDay + 1; i++) {
|
|
323
|
+
daysList.push({
|
|
324
|
+
date: i,
|
|
325
|
+
type: 0,
|
|
326
|
+
year: month == 11 ? year + 1 : year,
|
|
327
|
+
month: month == 11 ? 1 : month + 2
|
|
328
|
+
});
|
|
329
|
+
}
|
|
330
|
+
}
|
|
331
|
+
return {
|
|
332
|
+
days: days,
|
|
333
|
+
prevMonthDays: prevMonthDays,
|
|
334
|
+
nextMonthDays: nextMonthDays,
|
|
335
|
+
stratDay: stratDay,
|
|
336
|
+
endDay: endDay,
|
|
337
|
+
weekDate: weekDate,
|
|
338
|
+
year: year,
|
|
339
|
+
month: month + 1,
|
|
340
|
+
today: today,
|
|
341
|
+
week: week,
|
|
342
|
+
daysList: daysList
|
|
343
|
+
};
|
|
344
|
+
},
|
|
345
|
+
getWeekDay(val) {
|
|
346
|
+
let flag = true;
|
|
347
|
+
let weekDate = JSON.parse(JSON.stringify(this.weekDate));
|
|
348
|
+
let days = weekDate.map((item) => {
|
|
349
|
+
let { date, month, year } = item;
|
|
350
|
+
date += val * 7;
|
|
351
|
+
if (date < 1) {
|
|
352
|
+
date += this.prevMonthDays;
|
|
353
|
+
month -= 1;
|
|
354
|
+
if (month == 0) {
|
|
355
|
+
month = 12;
|
|
356
|
+
year -= 1;
|
|
357
|
+
}
|
|
358
|
+
} else if (date > this.days) {
|
|
359
|
+
date -= this.days;
|
|
360
|
+
month += 1;
|
|
361
|
+
if (month > 12) {
|
|
362
|
+
month = 1;
|
|
363
|
+
year += 1;
|
|
364
|
+
}
|
|
365
|
+
}
|
|
366
|
+
if (this.month == month) {
|
|
367
|
+
flag = false;
|
|
368
|
+
}
|
|
369
|
+
return { date, month, year };
|
|
370
|
+
});
|
|
371
|
+
if (flag) {
|
|
372
|
+
val == 1 ? this.nextMonth() : this.prevMonth();
|
|
373
|
+
}
|
|
374
|
+
return days;
|
|
375
|
+
},
|
|
376
|
+
handleShow() {
|
|
377
|
+
this.all = true;
|
|
378
|
+
this.$emit('show', true);
|
|
379
|
+
},
|
|
380
|
+
handleHide() {
|
|
381
|
+
this.all = false;
|
|
382
|
+
this.$emit('show', false);
|
|
383
|
+
}
|
|
384
|
+
}
|
|
385
|
+
};
|
|
386
|
+
</script>
|