@cimom-ui/standard-ui 1.1.9 → 1.1.12
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/README.md +36 -4
- package/dist/standard-ui.common.js +451 -100
- package/dist/standard-ui.umd.js +451 -100
- package/dist/standard-ui.umd.min.js +2 -2
- package/package.json +1 -1
|
@@ -3087,7 +3087,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
3087
3087
|
|
|
3088
3088
|
var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default()((_node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default()));
|
|
3089
3089
|
// Module
|
|
3090
|
-
___CSS_LOADER_EXPORT___.push([module.id, `body .el-dialog__wrapper{display:flex;align-items:center;justify-content:center}body .el-dialog{border-radius:12px;overflow:hidden;margin:0!important;max-height:90vh;display:flex;flex-direction:column}body .el-dialog.is-fullscreen{max-height:100vh;height:100%;border-radius:0}body .el-dialog__header{background:#fff;border-bottom:1px solid #e8edf4;padding:16px 24px;flex-shrink:0}body .el-dialog__title{font-size:17px;font-weight:600;color:#1f497d}body .el-dialog__body{background:#fff;flex:1;overflow-y:auto}body .el-dialog__footer{background:#fff;border-top:1px solid #e8edf4;padding:12px 24px;flex-shrink:0}body .el-dialog .el-button{padding:7px 15px;font-size:12px;border-radius:3px}body .el-dialog .el-form-item{margin-bottom:3px}body .el-dialog .el-form-item__label{float:none;display:inline-block;text-align:left;padding:0}body .el-dialog .el-form-item__content{margin-left:0!important}.standard-dialog .el-dialog{width:-moz-fit-content;width:fit-content;min-width:300px;max-width:80vw;max-height:80vh;display:flex;flex-direction:column;overflow:hidden}.standard-dialog .el-dialog__footer,.standard-dialog .el-dialog__header{flex-shrink:0}.standard-dialog .el-dialog__wrapper{overflow:hidden}.el-dialog.is-draggable .el-dialog__header,.standard-dialog.is-draggable .el-dialog__header{cursor:move;-webkit-user-select:none;-moz-user-select:none;user-select:none}.el-dialog.is-draggable .el-dialog__headerbtn,.standard-dialog.is-draggable .el-dialog__headerbtn{cursor:pointer}.standard-dialog .el-dialog__body{flex:1;min-height:0;overflow-y:auto;padding:6px 12px!important}`, ""]);
|
|
3090
|
+
___CSS_LOADER_EXPORT___.push([module.id, `body .el-dialog__wrapper{display:flex;align-items:center;justify-content:center}body .el-dialog{border-radius:12px;overflow:hidden;margin:0!important;max-height:90vh;display:flex;flex-direction:column}body .el-dialog.is-fullscreen{max-height:100vh;height:100%;border-radius:0}body .el-dialog__header{background:#fff;border-bottom:1px solid #e8edf4;padding:16px 24px;flex-shrink:0}body .el-dialog__title{font-size:17px;font-weight:600;color:#1f497d}body .el-dialog__body{background:#fff;flex:1;overflow-y:auto}body .el-dialog__footer{background:#fff;border-top:1px solid #e8edf4;padding:12px 24px;flex-shrink:0}body .el-dialog .el-button{padding:7px 15px;font-size:12px;border-radius:3px}body .el-dialog .el-form-item{margin-bottom:3px}body .el-dialog .el-form-item__label{float:none;display:inline-block;text-align:left;padding:0}body .el-dialog .el-form-item__content{margin-left:0!important}.standard-dialog .el-dialog{width:-moz-fit-content;width:fit-content;min-width:300px;max-width:80vw;max-height:80vh;display:flex;flex-direction:column;overflow:hidden}.el-dialog.standard-dialog__panel.is-fullscreen,.standard-dialog .el-dialog.is-fullscreen{width:100%;min-width:0;max-width:none;height:100%;max-height:100vh;border-radius:0}.standard-dialog .el-dialog__footer,.standard-dialog .el-dialog__header{flex-shrink:0}.standard-dialog .el-dialog__wrapper{overflow:hidden}.el-dialog.is-draggable .el-dialog__header,.standard-dialog.is-draggable .el-dialog__header{cursor:move;-webkit-user-select:none;-moz-user-select:none;user-select:none}.el-dialog.is-draggable .el-dialog__headerbtn,.standard-dialog.is-draggable .el-dialog__headerbtn{cursor:pointer}.el-dialog.has-fullscreen-btn .el-dialog__header{padding-right:72px}.el-dialog.has-fullscreen-btn.is-close-hidden .el-dialog__header{padding-right:48px}.standard-dialog__fullscreen{position:absolute;top:20px;right:48px;padding:0;border:none;outline:none;background:transparent;cursor:pointer;font-size:16px;line-height:1;color:#909399}.standard-dialog__fullscreen:focus,.standard-dialog__fullscreen:hover{color:#409eff}.el-dialog.is-close-hidden .standard-dialog__fullscreen{right:20px}.standard-dialog .el-dialog__body{flex:1;min-height:0;overflow-y:auto;padding:6px 12px!important}`, ""]);
|
|
3091
3091
|
// Exports
|
|
3092
3092
|
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (___CSS_LOADER_EXPORT___);
|
|
3093
3093
|
|
|
@@ -3137,7 +3137,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
3137
3137
|
|
|
3138
3138
|
var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default()((_node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default()));
|
|
3139
3139
|
// Module
|
|
3140
|
-
___CSS_LOADER_EXPORT___.push([module.id, `.normal-report-table-panel{flex:1 1 0%;min-width:0;min-height:0;background:#fff;border:1px solid #e8edf4;border-radius:10px;box-shadow:0 6px 18px rgba(31,73,125,.06);height:100%;overflow:hidden;display:flex;flex-direction:column}.normal-report-table-wrap{flex:1;min-height:0;display:flex;flex-direction:column;padding:0 12px}.normal-report-table-wrap .el-table,.normal-report-table-wrap .vxe-table{flex:1;min-height:0}.normal-report-table-actions{flex-shrink:0;display:flex;align-items:center;gap:6px;padding:10px 12px;border-bottom:1px solid #edf1f6;margin-bottom:10px}.normal-report-table-actions .el-button+.el-button{margin-left:0}.normal-report-table-actions-left{flex:1 1 auto;min-width:0;display:flex;align-items:center;gap:6px}.normal-report-table-actions-right{flex-shrink:0;margin-left:auto;display:flex;align-items:center;gap:6px}.standard-toolbar-left,.standard-toolbar-right{display:flex;align-items:center;gap:6px;min-width:0}.standard-toolbar-left .el-button+.el-button,.standard-toolbar-right .el-button+.el-button{margin-left:0}.normal-report-column-setting-entry,.normal-report-column-setting-entry .el-popover__reference-wrapper{display:inline-flex;align-items:center}.normal-report-column-setting{min-width:270px}.normal-report-column-setting-header{padding-bottom:8px;border-bottom:1px solid #ebeef5}.normal-report-column-setting-list{max-height:300px;overflow-y:auto;padding:4px 0}.normal-report-column-setting-item{display:flex;align-items:center;gap:2px;padding:5px 4px;border-radius:4px}.normal-report-column-setting-item .el-checkbox{flex:1;min-width:0;margin-right:0;display:flex;align-items:center}.normal-report-column-setting-item .el-checkbox__input{display:flex;align-items:center;flex-shrink:0}.normal-report-column-setting-item .normal-report-column-setting-item-title{cursor:grab}.normal-report-column-setting-item .normal-report-column-setting-item-title:active{cursor:grabbing}.normal-report-column-setting-item .el-checkbox,.normal-report-column-setting-item .el-checkbox__label{-webkit-user-select:none;-moz-user-select:none;user-select:none}.normal-report-column-setting-item .normal-report-column-setting-item-title .el-checkbox__label{flex-shrink:0;width:var(--normal-report-title-width);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.normal-report-column-setting-item .normal-report-column-setting-item-width{flex-shrink:0;width:92px}.normal-report-column-setting-item .el-button+.el-button{margin-left:0}.normal-report-column-setting-item .is-pinned{color:#409eff}.normal-report-column-setting-item .is-sort-off,.normal-report-column-setting-item .is-sort-off:focus,.normal-report-column-setting-item .is-sort-off:hover{color:#c0c4cc}.normal-report-column-setting-item.drag-over{background:#ecf5ff}.normal-report-column-setting-footer{margin-top:8px;padding-top:8px;border-top:1px solid #ebeef5;text-align:right}.normal-report-table-footer{flex-shrink:0;box-sizing:border-box;min-height:49px;display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:10px;padding:8px 12px;border-top:1px solid #edf1f6}.normal-report-table-footer .normal-report-table-pagination{padding-top:0}.normal-report-table-footer.is-only-pagination{justify-content:flex-end}.normal-report-footer-empty{margin-top:10px}.normal-report-toolbar-empty{margin-bottom:10px}.normal-report-update-time{font-size:13px;color:#909399;flex-shrink:0}.vxe-table--context-menu-wrapper .vxe-context-menu--option-wrapper+.vxe-context-menu--option-wrapper,.vxe-table--context-menu-wrapper .vxe-table--context-menu-group-wrapper+.vxe-table--context-menu-group-wrapper{border-top:1px solid #e8eaec;margin-top:2px;padding-top:2px}.normal-report-table-pagination{flex-shrink:0;padding-top:10px;text-align:right}.normal-report-op-more{margin-left:10px}.normal-report-main-table.vxe-table .vxe-body--row{transition:transform .22s ease,filter .22s ease}.normal-report-main-table.vxe-table .vxe-body--row:hover{transform:translateY(-3px);filter:drop-shadow(0 8px 16px rgba(31,73,125,.22))}.vxe-table--footer-wrapper::-webkit-scrollbar{width:8px!important;height:8px!important}.vxe-table--footer-wrapper::-webkit-scrollbar-track{background-color:#fff!important}.vxe-table--footer-wrapper::-webkit-scrollbar-thumb{background-color:#dddee0!important;border-radius:5px!important;border:1px solid #f1f1f1!important}.vxe-table--footer-wrapper::-webkit-scrollbar-thumb:hover{background-color:#a8a8a8!important}.vxe-table--footer-wrapper::-webkit-scrollbar-thumb:active{background-color:#dddee0!important}.vxe-table--footer-wrapper::-webkit-scrollbar-corner{background-color:#fff!important}.vxe-table--body-wrapper::-webkit-scrollbar{width:8px!important;height:8px!important}.vxe-table--body-wrapper::-webkit-scrollbar-track{background-color:#fff!important}.vxe-table--body-wrapper::-webkit-scrollbar-thumb{background-color:#dddee0!important;border-radius:5px!important;border:1px solid #f1f1f1!important}.vxe-table--body-wrapper::-webkit-scrollbar-thumb:active,.vxe-table--body-wrapper::-webkit-scrollbar-thumb:hover{background-color:#dddee0!important}.vxe-table--body-wrapper::-webkit-scrollbar-corner{background-color:#fff!important}.vxe-table .vxe-header--row{height:
|
|
3140
|
+
___CSS_LOADER_EXPORT___.push([module.id, `.normal-report-table-panel{flex:1 1 0%;min-width:0;min-height:0;background:#fff;border:1px solid #e8edf4;border-radius:10px;box-shadow:0 6px 18px rgba(31,73,125,.06);height:100%;overflow:hidden;display:flex;flex-direction:column}.normal-report-table-wrap{flex:1;min-height:0;display:flex;flex-direction:column;padding:0 12px}.normal-report-table-wrap .el-table,.normal-report-table-wrap .vxe-table{flex:1;min-height:0}.normal-report-table-actions{flex-shrink:0;display:flex;align-items:center;gap:6px;padding:10px 12px;border-bottom:1px solid #edf1f6;margin-bottom:10px}.normal-report-table-actions .el-button+.el-button{margin-left:0}.normal-report-table-actions-left{flex:1 1 auto;min-width:0;display:flex;align-items:center;gap:6px}.normal-report-table-actions-right{flex-shrink:0;margin-left:auto;display:flex;align-items:center;gap:6px}.standard-toolbar-left,.standard-toolbar-query,.standard-toolbar-right{display:flex;align-items:center;gap:6px;min-width:0}.standard-toolbar-left .el-button+.el-button,.standard-toolbar-query .el-button+.el-button,.standard-toolbar-right .el-button+.el-button{margin-left:0}.normal-report-column-setting-entry,.normal-report-column-setting-entry .el-popover__reference-wrapper{display:inline-flex;align-items:center}.normal-report-column-setting{min-width:270px}.normal-report-column-setting-header{padding-bottom:8px;border-bottom:1px solid #ebeef5}.normal-report-column-setting-list{max-height:300px;overflow-y:auto;padding:4px 0}.normal-report-column-setting-item{display:flex;align-items:center;gap:2px;padding:5px 4px;border-radius:4px}.normal-report-column-setting-item .el-checkbox{flex:1;min-width:0;margin-right:0;display:flex;align-items:center}.normal-report-column-setting-item .el-checkbox__input{display:flex;align-items:center;flex-shrink:0}.normal-report-column-setting-item .normal-report-column-setting-item-title{cursor:grab}.normal-report-column-setting-item .normal-report-column-setting-item-title:active{cursor:grabbing}.normal-report-column-setting-item .el-checkbox,.normal-report-column-setting-item .el-checkbox__label{-webkit-user-select:none;-moz-user-select:none;user-select:none}.normal-report-column-setting-item .normal-report-column-setting-item-title .el-checkbox__label{flex-shrink:0;width:var(--normal-report-title-width);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.normal-report-column-setting-item .normal-report-column-setting-item-width{flex-shrink:0;width:92px}.normal-report-column-setting-item .el-button+.el-button{margin-left:0}.normal-report-column-setting-item .is-pinned{color:#409eff}.normal-report-column-setting-item .is-sort-off,.normal-report-column-setting-item .is-sort-off:focus,.normal-report-column-setting-item .is-sort-off:hover{color:#c0c4cc}.normal-report-column-setting-item.drag-over{background:#ecf5ff}.normal-report-column-setting-footer{margin-top:8px;padding-top:8px;border-top:1px solid #ebeef5;text-align:right}.normal-report-table-footer{flex-shrink:0;box-sizing:border-box;min-height:49px;display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:10px;padding:8px 12px;border-top:1px solid #edf1f6}.normal-report-table-footer .normal-report-table-pagination{padding-top:0}.normal-report-table-footer.is-only-pagination{justify-content:flex-end}.normal-report-footer-empty{margin-top:10px}.normal-report-toolbar-empty{margin-bottom:10px}.normal-report-update-time{font-size:13px;color:#909399;flex-shrink:0}.vxe-table--context-menu-wrapper .vxe-context-menu--option-wrapper+.vxe-context-menu--option-wrapper,.vxe-table--context-menu-wrapper .vxe-table--context-menu-group-wrapper+.vxe-table--context-menu-group-wrapper{border-top:1px solid #e8eaec;margin-top:2px;padding-top:2px}.normal-report-table-pagination{flex-shrink:0;padding-top:10px;text-align:right}.normal-report-op-more{margin-left:10px}.normal-report-main-table.vxe-table .vxe-body--row{transition:transform .22s ease,filter .22s ease}.normal-report-main-table.vxe-table .vxe-body--row:hover{transform:translateY(-3px);filter:drop-shadow(0 8px 16px rgba(31,73,125,.22))}.vxe-table--footer-wrapper::-webkit-scrollbar{width:8px!important;height:8px!important}.vxe-table--footer-wrapper::-webkit-scrollbar-track{background-color:#fff!important}.vxe-table--footer-wrapper::-webkit-scrollbar-thumb{background-color:#dddee0!important;border-radius:5px!important;border:1px solid #f1f1f1!important}.vxe-table--footer-wrapper::-webkit-scrollbar-thumb:hover{background-color:#a8a8a8!important}.vxe-table--footer-wrapper::-webkit-scrollbar-thumb:active{background-color:#dddee0!important}.vxe-table--footer-wrapper::-webkit-scrollbar-corner{background-color:#fff!important}.vxe-table--body-wrapper::-webkit-scrollbar{width:8px!important;height:8px!important}.vxe-table--body-wrapper::-webkit-scrollbar-track{background-color:#fff!important}.vxe-table--body-wrapper::-webkit-scrollbar-thumb{background-color:#dddee0!important;border-radius:5px!important;border:1px solid #f1f1f1!important}.vxe-table--body-wrapper::-webkit-scrollbar-thumb:active,.vxe-table--body-wrapper::-webkit-scrollbar-thumb:hover{background-color:#dddee0!important}.vxe-table--body-wrapper::-webkit-scrollbar-corner{background-color:#fff!important}.vxe-table .vxe-header--row{height:36px!important}.vxe-table .vxe-header--column{padding:0!important;color:#636364!important;font-weight:600!important;font-size:13px!important;background-color:#f5f7fa!important}.vxe-table .vxe-header--column,.vxe-table .vxe-header--column>.vxe-cell{height:36px!important;max-height:36px!important;line-height:36px!important}.vxe-table .vxe-header--column>.vxe-cell{padding-top:0!important;padding-bottom:0!important}.vxe-table .vxe-body--row{height:34px!important}.vxe-table .vxe-body--row td.vxe-body--column{font-size:12px!important}.vxe-table .vxe-body--column>.vxe-cell,.vxe-table .vxe-body--row td.vxe-body--column{height:34px!important;max-height:34px!important;line-height:34px!important;padding-top:0!important;padding-bottom:0!important}.vxe-table .vxe-tree-cell{display:flex;align-items:center;height:34px;line-height:34px;overflow:hidden}.vxe-table .vxe-body--column .el-tag--mini{height:26px;line-height:24px;padding:0 4px;font-size:12px;vertical-align:middle}.vxe-table .vxe-body--column .el-button--mini{height:26px;line-height:24px;padding:0 2px;font-size:12px;vertical-align:middle}.vxe-table .vxe-body--column.col--active>.vxe-cell{overflow:visible!important;line-height:normal!important}.vxe-table .vxe-body--column.col--active .el-input,.vxe-table .vxe-body--column.col--active .el-input__inner,.vxe-table .vxe-body--column.col--active .vxe-default-input,.vxe-table .vxe-body--column.col--active .vxe-default-select,.vxe-table .vxe-body--column.col--active .vxe-default-textarea,.vxe-table .vxe-body--column.col--active .vxe-input{width:100%;height:34px!important;max-height:34px!important;line-height:32px!important;font-size:12px!important;box-sizing:border-box}.vxe-header--column.nr-header-drag-source{opacity:.45}.vxe-header--column.nr-header-drag-target{background-color:rgba(64,158,255,.08);box-shadow:inset 2px 0 0 #409eff}body.nr-header-dragging{-webkit-user-select:none;-moz-user-select:none;user-select:none}body.nr-header-dragging .vxe-header--column{cursor:grab}`, ""]);
|
|
3141
3141
|
// Exports
|
|
3142
3142
|
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (___CSS_LOADER_EXPORT___);
|
|
3143
3143
|
|
|
@@ -118476,8 +118476,8 @@ var component = normalizeComponent(
|
|
|
118476
118476
|
)
|
|
118477
118477
|
|
|
118478
118478
|
/* harmony default export */ const StandardButton = (component.exports);
|
|
118479
|
-
;// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??ruleSet[1].rules[3]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./src/components/StandardDialog/index.vue?vue&type=template&id=
|
|
118480
|
-
var
|
|
118479
|
+
;// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??ruleSet[1].rules[3]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./src/components/StandardDialog/index.vue?vue&type=template&id=3b8fc166
|
|
118480
|
+
var StandardDialogvue_type_template_id_3b8fc166_render = function render() {
|
|
118481
118481
|
var _vm = this,
|
|
118482
118482
|
_c = _vm._self._c;
|
|
118483
118483
|
return _c('section', {
|
|
@@ -118490,6 +118490,7 @@ var StandardDialogvue_type_template_id_02bdeb78_render = function render() {
|
|
|
118490
118490
|
attrs: {
|
|
118491
118491
|
"visible": _vm.dialogVisible,
|
|
118492
118492
|
"title": _vm.title,
|
|
118493
|
+
"fullscreen": _vm.fullscreenActive,
|
|
118493
118494
|
"custom-class": _vm.dialogCustomClass,
|
|
118494
118495
|
"close-on-click-modal": _vm.closeOnClickModal
|
|
118495
118496
|
},
|
|
@@ -118499,7 +118500,25 @@ var StandardDialogvue_type_template_id_02bdeb78_render = function render() {
|
|
|
118499
118500
|
},
|
|
118500
118501
|
"opened": _vm.markDraggable
|
|
118501
118502
|
}
|
|
118502
|
-
}, 'el-dialog', _vm.$attrs, false), _vm.$listeners), [
|
|
118503
|
+
}, 'el-dialog', _vm.$attrs, false), _vm.$listeners), [_c('template', {
|
|
118504
|
+
slot: "title"
|
|
118505
|
+
}, [_c('span', {
|
|
118506
|
+
staticClass: "el-dialog__title"
|
|
118507
|
+
}, [_vm._v(_vm._s(_vm.title))]), _vm.fullscreenButtonVisible ? _c('button', {
|
|
118508
|
+
staticClass: "standard-dialog__fullscreen",
|
|
118509
|
+
attrs: {
|
|
118510
|
+
"type": "button",
|
|
118511
|
+
"aria-label": _vm.fullscreenActive ? '退出全屏' : '全屏'
|
|
118512
|
+
},
|
|
118513
|
+
on: {
|
|
118514
|
+
"click": function click($event) {
|
|
118515
|
+
$event.stopPropagation();
|
|
118516
|
+
return _vm.toggleFullscreen.apply(null, arguments);
|
|
118517
|
+
}
|
|
118518
|
+
}
|
|
118519
|
+
}, [_c('i', {
|
|
118520
|
+
"class": _vm.fullscreenActive ? 'el-icon-c-scale-to-original' : 'el-icon-full-screen'
|
|
118521
|
+
})]) : _vm._e()]), _vm._t("default"), _c('template', {
|
|
118503
118522
|
slot: "footer"
|
|
118504
118523
|
}, [_vm.showCancel ? _c('el-button', {
|
|
118505
118524
|
attrs: {
|
|
@@ -118519,7 +118538,7 @@ var StandardDialogvue_type_template_id_02bdeb78_render = function render() {
|
|
|
118519
118538
|
}
|
|
118520
118539
|
}, [_vm._v("确定")]) : _vm._e()], 1)], 2)], 1);
|
|
118521
118540
|
};
|
|
118522
|
-
var
|
|
118541
|
+
var StandardDialogvue_type_template_id_3b8fc166_staticRenderFns = [];
|
|
118523
118542
|
|
|
118524
118543
|
;// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./src/components/StandardDialog/index.vue?vue&type=script&lang=js
|
|
118525
118544
|
/* harmony default export */ const StandardDialogvue_type_script_lang_js = ({
|
|
@@ -118564,8 +118583,29 @@ var StandardDialogvue_type_template_id_02bdeb78_staticRenderFns = [];
|
|
|
118564
118583
|
draggable: {
|
|
118565
118584
|
type: Boolean,
|
|
118566
118585
|
"default": true
|
|
118586
|
+
},
|
|
118587
|
+
// 是否显示右上角全屏切换按钮(默认不显示,避免已有弹窗多出一个按钮)
|
|
118588
|
+
showFullscreen: {
|
|
118589
|
+
type: Boolean,
|
|
118590
|
+
"default": false
|
|
118591
|
+
},
|
|
118592
|
+
// 是否默认全屏。为 true 时打开即全屏,且全屏切换按钮固定显示
|
|
118593
|
+
defaultFullscreen: {
|
|
118594
|
+
type: Boolean,
|
|
118595
|
+
"default": false
|
|
118596
|
+
},
|
|
118597
|
+
// 打开时是否全屏。声明为 prop 后不再经 $attrs 透传,由内部状态接管 el-dialog
|
|
118598
|
+
fullscreen: {
|
|
118599
|
+
type: Boolean,
|
|
118600
|
+
"default": false
|
|
118567
118601
|
}
|
|
118568
118602
|
},
|
|
118603
|
+
data: function data() {
|
|
118604
|
+
return {
|
|
118605
|
+
// 本次打开期间的全屏状态。关闭再打开时按 fullscreen / default-fullscreen 重新取值
|
|
118606
|
+
fullscreenActive: false
|
|
118607
|
+
};
|
|
118608
|
+
},
|
|
118569
118609
|
computed: {
|
|
118570
118610
|
// v-model 双向桥接:内部 visible.sync 改动时同步回父组件
|
|
118571
118611
|
dialogVisible: {
|
|
@@ -118578,20 +118618,39 @@ var StandardDialogvue_type_template_id_02bdeb78_staticRenderFns = [];
|
|
|
118578
118618
|
},
|
|
118579
118619
|
// 全屏弹窗铺满视口,拖拽没有意义
|
|
118580
118620
|
canDrag: function canDrag() {
|
|
118581
|
-
return this.draggable && !this.
|
|
118621
|
+
return this.draggable && !this.fullscreenActive;
|
|
118622
|
+
},
|
|
118623
|
+
// 默认全屏时切换按钮固定显示,不再依赖 show-fullscreen
|
|
118624
|
+
fullscreenButtonVisible: function fullscreenButtonVisible() {
|
|
118625
|
+
return this.showFullscreen || this.defaultFullscreen;
|
|
118626
|
+
},
|
|
118627
|
+
// 打开时的全屏状态:fullscreen 或 default-fullscreen 任一为真即全屏
|
|
118628
|
+
initialFullscreen: function initialFullscreen() {
|
|
118629
|
+
return this.fullscreen || this.defaultFullscreen;
|
|
118582
118630
|
},
|
|
118583
|
-
//
|
|
118631
|
+
// 未传 show-close 时 Element 默认显示关闭按钮
|
|
118632
|
+
showCloseButton: function showCloseButton() {
|
|
118633
|
+
var attrs = this.$attrs || {};
|
|
118634
|
+
var value = attrs.showClose !== undefined ? attrs.showClose : attrs["show-close"];
|
|
118635
|
+
if (value === undefined) return true;
|
|
118636
|
+
return value !== false && value !== "false";
|
|
118637
|
+
},
|
|
118638
|
+
// 标题栏光标与全屏按钮占位。合并外部 custom-class,避免 v-bind="$attrs" 把外部类名冲掉
|
|
118584
118639
|
dialogCustomClass: function dialogCustomClass() {
|
|
118585
118640
|
var passed = this.$attrs.customClass || this.$attrs["custom-class"] || "";
|
|
118586
|
-
|
|
118587
|
-
|
|
118641
|
+
var classes = [passed, "standard-dialog__panel"];
|
|
118642
|
+
if (this.canDrag) classes.push("is-draggable");
|
|
118643
|
+
if (this.fullscreenButtonVisible) classes.push("has-fullscreen-btn");
|
|
118644
|
+
if (!this.showCloseButton) classes.push("is-close-hidden");
|
|
118645
|
+
return classes.filter(Boolean).join(" ");
|
|
118588
118646
|
}
|
|
118589
118647
|
},
|
|
118590
118648
|
watch: {
|
|
118591
118649
|
visible: function visible(val) {
|
|
118592
118650
|
var _this = this;
|
|
118593
118651
|
if (val) {
|
|
118594
|
-
//
|
|
118652
|
+
// 每次打开按全屏参数恢复,清掉上次拖拽留下的 fixed 定位
|
|
118653
|
+
this.fullscreenActive = this.initialFullscreen;
|
|
118595
118654
|
this.resetDragPosition();
|
|
118596
118655
|
this.$nextTick(function () {
|
|
118597
118656
|
return _this.markDraggable();
|
|
@@ -118611,6 +118670,7 @@ var StandardDialogvue_type_template_id_02bdeb78_staticRenderFns = [];
|
|
|
118611
118670
|
created: function created() {
|
|
118612
118671
|
this._dragging = false;
|
|
118613
118672
|
this._dialogEl = null;
|
|
118673
|
+
this.fullscreenActive = this.initialFullscreen;
|
|
118614
118674
|
},
|
|
118615
118675
|
mounted: function mounted() {
|
|
118616
118676
|
var _this2 = this;
|
|
@@ -118634,10 +118694,16 @@ var StandardDialogvue_type_template_id_02bdeb78_staticRenderFns = [];
|
|
|
118634
118694
|
handleConfirm: function handleConfirm() {
|
|
118635
118695
|
this.$emit("confirm");
|
|
118636
118696
|
},
|
|
118637
|
-
//
|
|
118638
|
-
|
|
118639
|
-
var
|
|
118640
|
-
|
|
118697
|
+
// 进入全屏前清掉拖拽留下的 left / top / width,退出时恢复居中
|
|
118698
|
+
toggleFullscreen: function toggleFullscreen() {
|
|
118699
|
+
var _this3 = this;
|
|
118700
|
+
this.stopDrag();
|
|
118701
|
+
this.resetDragPosition();
|
|
118702
|
+
this.fullscreenActive = !this.fullscreenActive;
|
|
118703
|
+
this.$emit("update:fullscreen", this.fullscreenActive);
|
|
118704
|
+
this.$nextTick(function () {
|
|
118705
|
+
return _this3.markDraggable();
|
|
118706
|
+
});
|
|
118641
118707
|
},
|
|
118642
118708
|
// el-dialog 根节点是 wrapper。append-to-body 后节点会离开 section,仍以组件实例上的 $el 为准
|
|
118643
118709
|
getWrapperEl: function getWrapperEl() {
|
|
@@ -118791,8 +118857,8 @@ var StandardDialogvue_type_style_index_0_prod_lang_scss_external = __webpack_req
|
|
|
118791
118857
|
|
|
118792
118858
|
var StandardDialog_component = normalizeComponent(
|
|
118793
118859
|
components_StandardDialogvue_type_script_lang_js,
|
|
118794
|
-
|
|
118795
|
-
|
|
118860
|
+
StandardDialogvue_type_template_id_3b8fc166_render,
|
|
118861
|
+
StandardDialogvue_type_template_id_3b8fc166_staticRenderFns,
|
|
118796
118862
|
false,
|
|
118797
118863
|
null,
|
|
118798
118864
|
null,
|
|
@@ -121033,8 +121099,8 @@ var StandardTimePick_component = normalizeComponent(
|
|
|
121033
121099
|
)
|
|
121034
121100
|
|
|
121035
121101
|
/* harmony default export */ const StandardTimePick = (StandardTimePick_component.exports);
|
|
121036
|
-
;// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??ruleSet[1].rules[3]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./src/components/StandardTable/index.vue?vue&type=template&id=
|
|
121037
|
-
var
|
|
121102
|
+
;// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??ruleSet[1].rules[3]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./src/components/StandardTable/index.vue?vue&type=template&id=a9e9136a
|
|
121103
|
+
var StandardTablevue_type_template_id_a9e9136a_render = function render() {
|
|
121038
121104
|
var _vm = this,
|
|
121039
121105
|
_c = _vm._self._c;
|
|
121040
121106
|
return _c('section', {
|
|
@@ -121270,6 +121336,7 @@ var StandardTablevue_type_template_id_03577217_render = function render() {
|
|
|
121270
121336
|
"row-config": _vm.rowConfig,
|
|
121271
121337
|
"header-cell-config": _vm.headerCellConfig,
|
|
121272
121338
|
"cell-config": _vm.cellConfig,
|
|
121339
|
+
"edit-config": _vm.resolvedEditConfig,
|
|
121273
121340
|
"tree-config": _vm.treeConfig,
|
|
121274
121341
|
"column-config": {
|
|
121275
121342
|
resizable: true
|
|
@@ -121286,14 +121353,16 @@ var StandardTablevue_type_template_id_03577217_render = function render() {
|
|
|
121286
121353
|
"checkbox-change": _vm.handleCheckboxChange,
|
|
121287
121354
|
"checkbox-all": _vm.handleCheckboxChange,
|
|
121288
121355
|
"current-change": _vm.handleCurrentRowChange,
|
|
121289
|
-
"toggle-tree-expand": _vm.handleToggleTreeExpand
|
|
121356
|
+
"toggle-tree-expand": _vm.handleToggleTreeExpand,
|
|
121357
|
+
"edit-activated": _vm.onEditActivated,
|
|
121358
|
+
"edit-closed": _vm.onEditClosed
|
|
121290
121359
|
},
|
|
121291
121360
|
nativeOn: {
|
|
121292
121361
|
"mousedown": function mousedown($event) {
|
|
121293
121362
|
return _vm.onTableMousedown.apply(null, arguments);
|
|
121294
121363
|
}
|
|
121295
121364
|
}
|
|
121296
|
-
}, [_vm.showCheckbox ? _c('vxe-column', {
|
|
121365
|
+
}, [_vm.columnsReady && _vm.showCheckbox ? _c('vxe-column', {
|
|
121297
121366
|
attrs: {
|
|
121298
121367
|
"type": "checkbox",
|
|
121299
121368
|
"width": "50",
|
|
@@ -121302,7 +121371,7 @@ var StandardTablevue_type_template_id_03577217_render = function render() {
|
|
|
121302
121371
|
"align": "center",
|
|
121303
121372
|
"resizable": false
|
|
121304
121373
|
}
|
|
121305
|
-
}) : _vm._e(), _vm._l(_vm.
|
|
121374
|
+
}) : _vm._e(), _vm._l(_vm.renderedColumns, function (col) {
|
|
121306
121375
|
return _c('vxe-column', {
|
|
121307
121376
|
key: col.key,
|
|
121308
121377
|
attrs: {
|
|
@@ -121318,7 +121387,8 @@ var StandardTablevue_type_template_id_03577217_render = function render() {
|
|
|
121318
121387
|
"sort-by": col.sortBy,
|
|
121319
121388
|
"show-overflow": col.showOverflow,
|
|
121320
121389
|
"resizable": col.resizable,
|
|
121321
|
-
"tree-node": col.treeNode
|
|
121390
|
+
"tree-node": col.treeNode,
|
|
121391
|
+
"edit-render": col.editRender || undefined
|
|
121322
121392
|
},
|
|
121323
121393
|
scopedSlots: _vm._u([{
|
|
121324
121394
|
key: "default",
|
|
@@ -121330,7 +121400,18 @@ var StandardTablevue_type_template_id_03577217_render = function render() {
|
|
|
121330
121400
|
}
|
|
121331
121401
|
})];
|
|
121332
121402
|
}
|
|
121333
|
-
}
|
|
121403
|
+
}, col.hasEditSlot ? {
|
|
121404
|
+
key: "edit",
|
|
121405
|
+
fn: function fn(scope) {
|
|
121406
|
+
return [_c('normal-report-cell', {
|
|
121407
|
+
attrs: {
|
|
121408
|
+
"col": col,
|
|
121409
|
+
"scope": scope,
|
|
121410
|
+
"edit": ""
|
|
121411
|
+
}
|
|
121412
|
+
})];
|
|
121413
|
+
}
|
|
121414
|
+
} : null], null, true)
|
|
121334
121415
|
});
|
|
121335
121416
|
})], 2)], 1), _vm.getFooterVisible() ? _c('div', {
|
|
121336
121417
|
staticClass: "normal-report-table-footer",
|
|
@@ -121353,7 +121434,7 @@ var StandardTablevue_type_template_id_03577217_render = function render() {
|
|
|
121353
121434
|
}
|
|
121354
121435
|
}) : _vm.getFooterEmptyVisible() ? _c('standard-footer-empty') : _vm._e()], 1);
|
|
121355
121436
|
};
|
|
121356
|
-
var
|
|
121437
|
+
var StandardTablevue_type_template_id_a9e9136a_staticRenderFns = [];
|
|
121357
121438
|
|
|
121358
121439
|
;// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./src/components/StandardTable/ToolbarEmpty.vue?vue&type=script&lang=js
|
|
121359
121440
|
/**
|
|
@@ -121494,15 +121575,22 @@ var NormalReportCell = {
|
|
|
121494
121575
|
"default": function _default() {
|
|
121495
121576
|
return {};
|
|
121496
121577
|
}
|
|
121578
|
+
},
|
|
121579
|
+
edit: {
|
|
121580
|
+
type: Boolean,
|
|
121581
|
+
"default": false
|
|
121497
121582
|
}
|
|
121498
121583
|
},
|
|
121499
121584
|
render: function render(h, ctx) {
|
|
121500
121585
|
var _ctx$props = ctx.props,
|
|
121501
121586
|
col = _ctx$props.col,
|
|
121502
|
-
scope = _ctx$props.scope
|
|
121587
|
+
scope = _ctx$props.scope,
|
|
121588
|
+
edit = _ctx$props.edit;
|
|
121503
121589
|
var parent = ctx.parent;
|
|
121504
121590
|
if (!col || !parent || typeof parent.renderCell !== 'function') return null;
|
|
121505
|
-
|
|
121591
|
+
// 把本次渲染的 h 传下去:操作列按钮必须在当前渲染里创建,
|
|
121592
|
+
// 不能用表格实例上预先生成的 VNode,否则 vxe 调用插槽时按钮挂不上
|
|
121593
|
+
var result = parent.renderCell(col, scope, edit, h);
|
|
121506
121594
|
if (result == null || result === '') return null;
|
|
121507
121595
|
if (Array.isArray(result)) {
|
|
121508
121596
|
return result.map(function (item) {
|
|
@@ -121611,6 +121699,13 @@ var NormalReportSlotView = {
|
|
|
121611
121699
|
type: Object,
|
|
121612
121700
|
"default": null
|
|
121613
121701
|
},
|
|
121702
|
+
// 单元格编辑配置(vxe-table edit-config):
|
|
121703
|
+
// 不传时,只要有列设置了 editable / edit-render / #edit,自动按点击单元格编辑;
|
|
121704
|
+
// 传 false 关闭编辑;传对象则原样交给 vxe-table(如 { trigger: 'dblclick', mode: 'row' })
|
|
121705
|
+
editConfig: {
|
|
121706
|
+
type: [Object, Boolean],
|
|
121707
|
+
"default": null
|
|
121708
|
+
},
|
|
121614
121709
|
// 表格首列是否显示多选框
|
|
121615
121710
|
showCheckbox: {
|
|
121616
121711
|
type: Boolean,
|
|
@@ -121686,12 +121781,17 @@ var NormalReportSlotView = {
|
|
|
121686
121781
|
// ===== 其它 =====
|
|
121687
121782
|
updateTime: '--',
|
|
121688
121783
|
// 数据更新时间(tableData 变化时自动刷新)
|
|
121689
|
-
// 表头行高
|
|
121784
|
+
// 表头行高 36px、内容行高 34px:交给 vxe-table 计算行高,和样式保持一致
|
|
121690
121785
|
headerCellConfig: {
|
|
121691
|
-
height:
|
|
121786
|
+
height: 36
|
|
121692
121787
|
},
|
|
121693
121788
|
cellConfig: {
|
|
121694
|
-
height:
|
|
121789
|
+
height: 34
|
|
121790
|
+
},
|
|
121791
|
+
// 有可编辑列且未传 edit-config 时使用,保持对象引用稳定,避免表格反复重置编辑状态
|
|
121792
|
+
defaultEditConfig: {
|
|
121793
|
+
trigger: 'click',
|
|
121794
|
+
mode: 'cell'
|
|
121695
121795
|
},
|
|
121696
121796
|
// ===== 表头右键菜单 / 拖拽换列 =====
|
|
121697
121797
|
headerMenuCtx: null,
|
|
@@ -121720,7 +121820,9 @@ var NormalReportSlotView = {
|
|
|
121720
121820
|
// ResizeObserver 实例(监听表格容器尺寸变化)
|
|
121721
121821
|
resizeTimer: null,
|
|
121722
121822
|
// 尺寸变化防抖定时器
|
|
121723
|
-
|
|
121823
|
+
// 首屏先让 standard-column 在 created 中注册完,再渲染 vxe-column。
|
|
121824
|
+
// 否则第一次往往只有操作列,vxe-table 会固化它的插槽,随后数据列插入后操作列变空白
|
|
121825
|
+
columnsReady: false
|
|
121724
121826
|
};
|
|
121725
121827
|
},
|
|
121726
121828
|
computed: {
|
|
@@ -121888,10 +121990,19 @@ var NormalReportSlotView = {
|
|
|
121888
121990
|
// 是否显示排序功能:优先取列设置弹层设置的值,未设置时取列组件声明
|
|
121889
121991
|
sortable: st && st.sortable != null ? st.sortable : !!comp.sortable,
|
|
121890
121992
|
showOverflow: comp.showOverflow,
|
|
121891
|
-
resizable: comp.resizable
|
|
121993
|
+
resizable: comp.resizable,
|
|
121994
|
+
// 编辑:edit-render 优先;editable 默认文本输入;仅有 #edit 插槽时用空配置打开编辑
|
|
121995
|
+
editRender: comp.editRender || (comp.editable ? {
|
|
121996
|
+
name: 'input'
|
|
121997
|
+
} : comp.$scopedSlots && comp.$scopedSlots.edit ? {} : null),
|
|
121998
|
+
hasEditSlot: !!(comp.$scopedSlots && comp.$scopedSlots.edit)
|
|
121892
121999
|
};
|
|
121893
122000
|
}).filter(Boolean);
|
|
121894
122001
|
},
|
|
122002
|
+
// 实际交给 vxe-table 的列:列注册完成前不输出,避免操作列先挂载
|
|
122003
|
+
renderedColumns: function renderedColumns() {
|
|
122004
|
+
return this.columnsReady ? this.vxeColumns : [];
|
|
122005
|
+
},
|
|
121895
122006
|
// vxe-table 列配置(用户列 + 操作列;多选框列在模板中单独以 <vxe-column> 声明)
|
|
121896
122007
|
// 注意:vxe-table 3.x 不消费 columns 配置对象,本计算属性仅供模板 v-for 生成 <vxe-column> 子组件
|
|
121897
122008
|
vxeColumns: function vxeColumns() {
|
|
@@ -121929,6 +122040,8 @@ var NormalReportSlotView = {
|
|
|
121929
122040
|
} : undefined,
|
|
121930
122041
|
showOverflow: c.showOverflow !== false,
|
|
121931
122042
|
resizable: c.resizable !== false,
|
|
122043
|
+
editRender: c.editRender || null,
|
|
122044
|
+
hasEditSlot: !!c.hasEditSlot,
|
|
121932
122045
|
comp: c.comp,
|
|
121933
122046
|
isSeq: isSeq,
|
|
121934
122047
|
isOp: false
|
|
@@ -121965,6 +122078,15 @@ var NormalReportSlotView = {
|
|
|
121965
122078
|
return col.visible;
|
|
121966
122079
|
});
|
|
121967
122080
|
return some && !this.columnAllVisible;
|
|
122081
|
+
},
|
|
122082
|
+
// 未显式传入 edit-config 时,存在可编辑列才打开点击编辑,避免影响普通表格的点击行为
|
|
122083
|
+
resolvedEditConfig: function resolvedEditConfig() {
|
|
122084
|
+
if (this.editConfig === false) return null;
|
|
122085
|
+
if (this.editConfig) return this.editConfig;
|
|
122086
|
+
var editable = this.vxeColumns.some(function (col) {
|
|
122087
|
+
return col.editRender;
|
|
122088
|
+
});
|
|
122089
|
+
return editable ? this.defaultEditConfig : null;
|
|
121968
122090
|
}
|
|
121969
122091
|
},
|
|
121970
122092
|
watch: {
|
|
@@ -121979,9 +122101,22 @@ var NormalReportSlotView = {
|
|
|
121979
122101
|
}
|
|
121980
122102
|
},
|
|
121981
122103
|
mounted: function mounted() {
|
|
122104
|
+
var _this4 = this;
|
|
121982
122105
|
this.initResizeObserver();
|
|
121983
122106
|
// 表头拖拽排序结束后抑制一次 click(document 捕获阶段拦截,防止拖拽结束触发排序切换)
|
|
121984
122107
|
document.addEventListener('click', this.onDocumentClickCapture, true);
|
|
122108
|
+
// 本次 patch 中 standard-column 的 created 已经完成注册,此刻再放行列
|
|
122109
|
+
this.columnsReady = true;
|
|
122110
|
+
// 列挂载后再重算。height="100%" 要等浏览器完成 flex 布局才有父容器高度,
|
|
122111
|
+
// 只在 nextTick 里算会把表体高度当成内容高度,滚动条不再出现
|
|
122112
|
+
this.$nextTick(function () {
|
|
122113
|
+
_this4.resizeRecalculate();
|
|
122114
|
+
if (typeof requestAnimationFrame === 'function') {
|
|
122115
|
+
requestAnimationFrame(function () {
|
|
122116
|
+
return _this4.resizeRecalculate();
|
|
122117
|
+
});
|
|
122118
|
+
}
|
|
122119
|
+
});
|
|
121985
122120
|
},
|
|
121986
122121
|
beforeDestroy: function beforeDestroy() {
|
|
121987
122122
|
this.destroyResizeObserver();
|
|
@@ -122006,51 +122141,51 @@ var NormalReportSlotView = {
|
|
|
122006
122141
|
},
|
|
122007
122142
|
// 工具栏左侧子组件 vnode(渲染到操作区左侧)
|
|
122008
122143
|
getToolbarLeftVNodes: function getToolbarLeftVNodes() {
|
|
122009
|
-
var
|
|
122144
|
+
var _this5 = this;
|
|
122010
122145
|
return this.getDefaultSlotVNodes().filter(function (v) {
|
|
122011
|
-
return
|
|
122146
|
+
return _this5.isVNodeOfType(v, TOOLBAR_LEFT_TYPES);
|
|
122012
122147
|
});
|
|
122013
122148
|
},
|
|
122014
122149
|
// 工具栏右侧子组件 vnode(渲染到操作区右侧)
|
|
122015
122150
|
getToolbarRightVNodes: function getToolbarRightVNodes() {
|
|
122016
|
-
var
|
|
122151
|
+
var _this6 = this;
|
|
122017
122152
|
return this.getDefaultSlotVNodes().filter(function (v) {
|
|
122018
|
-
return
|
|
122153
|
+
return _this6.isVNodeOfType(v, TOOLBAR_RIGHT_TYPES);
|
|
122019
122154
|
});
|
|
122020
122155
|
},
|
|
122021
122156
|
// 底部栏左侧子组件 vnode(渲染到底部栏左侧)
|
|
122022
122157
|
getFooterLeftVNodes: function getFooterLeftVNodes() {
|
|
122023
|
-
var
|
|
122158
|
+
var _this7 = this;
|
|
122024
122159
|
return this.getDefaultSlotVNodes().filter(function (v) {
|
|
122025
|
-
return
|
|
122160
|
+
return _this7.isVNodeOfType(v, FOOTER_LEFT_TYPES);
|
|
122026
122161
|
});
|
|
122027
122162
|
},
|
|
122028
122163
|
// 底部栏右侧分页子组件 vnode(渲染到底部栏右侧)
|
|
122029
122164
|
getFooterRightVNodes: function getFooterRightVNodes() {
|
|
122030
|
-
var
|
|
122165
|
+
var _this8 = this;
|
|
122031
122166
|
return this.getDefaultSlotVNodes().filter(function (v) {
|
|
122032
|
-
return
|
|
122167
|
+
return _this8.isVNodeOfType(v, FOOTER_RIGHT_TYPES);
|
|
122033
122168
|
});
|
|
122034
122169
|
},
|
|
122035
122170
|
// 底部空占位子组件 vnode(页面声明时渲染,未声明时使用内置默认占位)
|
|
122036
122171
|
getFooterEmptyVNodes: function getFooterEmptyVNodes() {
|
|
122037
|
-
var
|
|
122172
|
+
var _this9 = this;
|
|
122038
122173
|
return this.getDefaultSlotVNodes().filter(function (v) {
|
|
122039
|
-
return
|
|
122174
|
+
return _this9.isVNodeOfType(v, FOOTER_EMPTY_TYPES);
|
|
122040
122175
|
});
|
|
122041
122176
|
},
|
|
122042
122177
|
// 工具栏空占位子组件 vnode(页面声明时渲染,未声明时使用内置默认占位)
|
|
122043
122178
|
getToolbarEmptyVNodes: function getToolbarEmptyVNodes() {
|
|
122044
|
-
var
|
|
122179
|
+
var _this0 = this;
|
|
122045
122180
|
return this.getDefaultSlotVNodes().filter(function (v) {
|
|
122046
|
-
return
|
|
122181
|
+
return _this0.isVNodeOfType(v, TOOLBAR_EMPTY_TYPES);
|
|
122047
122182
|
});
|
|
122048
122183
|
},
|
|
122049
122184
|
// 隐藏注册区 vnode:默认插槽中除区域子组件(工具栏/底部栏功能区 + 空占位)之外的内容
|
|
122050
122185
|
getHiddenSlotVNodes: function getHiddenSlotVNodes() {
|
|
122051
|
-
var
|
|
122186
|
+
var _this1 = this;
|
|
122052
122187
|
return this.getDefaultSlotVNodes().filter(function (v) {
|
|
122053
|
-
return !
|
|
122188
|
+
return !_this1.isVNodeOfType(v, TOOLBAR_LEFT_TYPES) && !_this1.isVNodeOfType(v, TOOLBAR_RIGHT_TYPES) && !_this1.isVNodeOfType(v, FOOTER_LEFT_TYPES) && !_this1.isVNodeOfType(v, FOOTER_RIGHT_TYPES) && !_this1.isVNodeOfType(v, FOOTER_EMPTY_TYPES) && !_this1.isVNodeOfType(v, TOOLBAR_EMPTY_TYPES);
|
|
122054
122189
|
});
|
|
122055
122190
|
},
|
|
122056
122191
|
// 操作区是否显示
|
|
@@ -122140,17 +122275,21 @@ var NormalReportSlotView = {
|
|
|
122140
122275
|
},
|
|
122141
122276
|
// ===== 单元格渲染 =====
|
|
122142
122277
|
// 渲染单元格内容(统一分发):seq 序号 / 操作列按钮 / 列组件插槽与字段值
|
|
122143
|
-
renderCell: function renderCell(col, scope) {
|
|
122278
|
+
renderCell: function renderCell(col, scope, isEdit, h) {
|
|
122144
122279
|
// 内置序号列:vxe 插槽参数 seq 即显示序号
|
|
122145
122280
|
if (col.isSeq) {
|
|
122146
122281
|
return String(scope.seq != null ? scope.seq : '');
|
|
122147
122282
|
}
|
|
122148
|
-
//
|
|
122283
|
+
// 操作列:渲染操作按钮(使用单元格本次渲染的 h)
|
|
122149
122284
|
if (col.isOp) {
|
|
122150
|
-
return this.renderOpCell(scope.row);
|
|
122285
|
+
return this.renderOpCell(scope.row, h);
|
|
122151
122286
|
}
|
|
122152
122287
|
var comp = col.comp;
|
|
122153
122288
|
if (!comp) return '';
|
|
122289
|
+
// 编辑态优先走列的 #edit 插槽
|
|
122290
|
+
if (isEdit && comp.$scopedSlots && typeof comp.$scopedSlots.edit === 'function') {
|
|
122291
|
+
return comp.$scopedSlots.edit(scope);
|
|
122292
|
+
}
|
|
122154
122293
|
// 作用域插槽 > 普通插槽 > formatter > 原始字段值
|
|
122155
122294
|
if (comp.$scopedSlots && typeof comp.$scopedSlots["default"] === 'function') {
|
|
122156
122295
|
return comp.$scopedSlots["default"](scope);
|
|
@@ -122168,7 +122307,7 @@ var NormalReportSlotView = {
|
|
|
122168
122307
|
// 渲染单个操作按钮:active 为 false 时不再隐藏(原按 v-if 消失),
|
|
122169
122308
|
// 改为渲染 disabled 按钮(变灰不可操作)
|
|
122170
122309
|
renderOpButton: function renderOpButton(h, row, btn, idx) {
|
|
122171
|
-
var
|
|
122310
|
+
var _this10 = this;
|
|
122172
122311
|
var active = this.isOpActive(btn, row);
|
|
122173
122312
|
var data = {
|
|
122174
122313
|
key: idx,
|
|
@@ -122179,7 +122318,7 @@ var NormalReportSlotView = {
|
|
|
122179
122318
|
},
|
|
122180
122319
|
on: {
|
|
122181
122320
|
click: function click() {
|
|
122182
|
-
return
|
|
122321
|
+
return _this10.handleOpClick(row, btn);
|
|
122183
122322
|
}
|
|
122184
122323
|
},
|
|
122185
122324
|
// 阻止点击事件冒泡到表格单元格:
|
|
@@ -122201,7 +122340,7 @@ var NormalReportSlotView = {
|
|
|
122201
122340
|
// 超出按钮渲染为 el-dropdown-item,点击后走与直接按钮一致的 handleOpClick;
|
|
122202
122341
|
// active 为 false 的按钮以 disabled 形式变灰展示
|
|
122203
122342
|
renderOpMore: function renderOpMore(h, row, restButtons) {
|
|
122204
|
-
var
|
|
122343
|
+
var _this11 = this;
|
|
122205
122344
|
return h('el-dropdown', {
|
|
122206
122345
|
key: '__normal_report_op_more__',
|
|
122207
122346
|
"class": 'normal-report-op-more',
|
|
@@ -122211,7 +122350,7 @@ var NormalReportSlotView = {
|
|
|
122211
122350
|
},
|
|
122212
122351
|
on: {
|
|
122213
122352
|
command: function command(btn) {
|
|
122214
|
-
return
|
|
122353
|
+
return _this11.handleOpClick(row, btn);
|
|
122215
122354
|
}
|
|
122216
122355
|
},
|
|
122217
122356
|
nativeOn: {
|
|
@@ -122229,7 +122368,7 @@ var NormalReportSlotView = {
|
|
|
122229
122368
|
})]), h('el-dropdown-menu', {
|
|
122230
122369
|
slot: 'dropdown'
|
|
122231
122370
|
}, restButtons.map(function (btn, idx) {
|
|
122232
|
-
var active =
|
|
122371
|
+
var active = _this11.isOpActive(btn, row);
|
|
122233
122372
|
return h('el-dropdown-item', {
|
|
122234
122373
|
key: idx,
|
|
122235
122374
|
props: {
|
|
@@ -122244,20 +122383,20 @@ var NormalReportSlotView = {
|
|
|
122244
122383
|
},
|
|
122245
122384
|
// 渲染操作列:按钮 ≤ 3 个时全部直接渲染;超过 3 个时前 3 个直接渲染,
|
|
122246
122385
|
// 其余统一收纳进“更多”下拉菜单;active 为 false 的按钮渲染为 disabled(变灰)
|
|
122247
|
-
renderOpCell: function renderOpCell(row) {
|
|
122248
|
-
var
|
|
122249
|
-
var
|
|
122386
|
+
renderOpCell: function renderOpCell(row, h) {
|
|
122387
|
+
var _this12 = this;
|
|
122388
|
+
var createElement = h || this.$createElement;
|
|
122250
122389
|
var btns = this.opButtons;
|
|
122251
122390
|
if (!btns.length) return null;
|
|
122252
122391
|
if (btns.length <= OP_MAX_DIRECT_COUNT) {
|
|
122253
122392
|
return btns.map(function (btn, idx) {
|
|
122254
|
-
return
|
|
122393
|
+
return _this12.renderOpButton(createElement, row, btn, idx);
|
|
122255
122394
|
});
|
|
122256
122395
|
}
|
|
122257
122396
|
var nodes = btns.slice(0, OP_MAX_DIRECT_COUNT).map(function (btn, idx) {
|
|
122258
|
-
return
|
|
122397
|
+
return _this12.renderOpButton(createElement, row, btn, idx);
|
|
122259
122398
|
});
|
|
122260
|
-
nodes.push(this.renderOpMore(
|
|
122399
|
+
nodes.push(this.renderOpMore(createElement, row, btns.slice(OP_MAX_DIRECT_COUNT)));
|
|
122261
122400
|
return nodes;
|
|
122262
122401
|
},
|
|
122263
122402
|
// 操作按钮是否有效:active 可为布尔值或 (row, btn) => boolean 函数
|
|
@@ -122338,12 +122477,12 @@ var NormalReportSlotView = {
|
|
|
122338
122477
|
},
|
|
122339
122478
|
// 复制文本到剪贴板:优先使用现代 API,失败时降级 execCommand
|
|
122340
122479
|
copyTextToClipboard: function copyTextToClipboard(text) {
|
|
122341
|
-
var
|
|
122480
|
+
var _this13 = this;
|
|
122342
122481
|
if (navigator.clipboard && window.isSecureContext) {
|
|
122343
122482
|
navigator.clipboard.writeText(text).then(function () {
|
|
122344
|
-
|
|
122483
|
+
_this13.$message && _this13.$message.success('复制成功:' + text);
|
|
122345
122484
|
})["catch"](function () {
|
|
122346
|
-
|
|
122485
|
+
_this13.fallbackCopyText(text);
|
|
122347
122486
|
});
|
|
122348
122487
|
} else {
|
|
122349
122488
|
this.fallbackCopyText(text);
|
|
@@ -122429,25 +122568,32 @@ var NormalReportSlotView = {
|
|
|
122429
122568
|
// 切换列的排序开关:sortable 已纳入列 key,修改后强制重建列,
|
|
122430
122569
|
// 再由 applyColumnOrder 恢复列顺序(重建会打乱 staticColumns 顺序)
|
|
122431
122570
|
toggleHeaderColumnSort: function toggleHeaderColumnSort(uid) {
|
|
122432
|
-
var
|
|
122571
|
+
var _this14 = this;
|
|
122433
122572
|
var st = this.columnStates[uid];
|
|
122434
122573
|
if (!st) return;
|
|
122435
122574
|
this.$set(st, 'sortable', !st.sortable);
|
|
122436
122575
|
this.$nextTick(function () {
|
|
122437
|
-
return
|
|
122576
|
+
return _this14.applyColumnOrder();
|
|
122438
122577
|
});
|
|
122439
122578
|
},
|
|
122440
122579
|
// 切换列的固定状态(左/右固定互斥,再次点击同侧即取消):
|
|
122441
122580
|
// fixed 同样纳入列 key,重建后 vxe-table 重新解析固定列分组
|
|
122442
122581
|
toggleHeaderColumnFixed: function toggleHeaderColumnFixed(uid, side) {
|
|
122443
|
-
var
|
|
122582
|
+
var _this15 = this;
|
|
122444
122583
|
var st = this.columnStates[uid];
|
|
122445
122584
|
if (!st) return;
|
|
122446
122585
|
this.$set(st, 'fixed', st.fixed === side ? '' : side);
|
|
122447
122586
|
this.$nextTick(function () {
|
|
122448
|
-
return
|
|
122587
|
+
return _this15.applyColumnOrder();
|
|
122449
122588
|
});
|
|
122450
122589
|
},
|
|
122590
|
+
// ===== 单元格编辑 =====
|
|
122591
|
+
onEditActivated: function onEditActivated(params, evnt) {
|
|
122592
|
+
this.$emit('edit-activated', params, evnt);
|
|
122593
|
+
},
|
|
122594
|
+
onEditClosed: function onEditClosed(params, evnt) {
|
|
122595
|
+
this.$emit('edit-closed', params, evnt);
|
|
122596
|
+
},
|
|
122451
122597
|
// ===== 表头拖拽换列 =====
|
|
122452
122598
|
// 通过 vxe-table 根元素原生 mousedown(冒泡)捕获表头按下:
|
|
122453
122599
|
// 排除列宽拖拽手柄与内置列(多选框/操作列),
|
|
@@ -122554,7 +122700,7 @@ var NormalReportSlotView = {
|
|
|
122554
122700
|
},
|
|
122555
122701
|
// 交换列顺序(columnOrder 重排后强制同步 vxe-table 内部列配置)
|
|
122556
122702
|
moveColumnOrder: function moveColumnOrder(fromUid, toUid) {
|
|
122557
|
-
var
|
|
122703
|
+
var _this16 = this;
|
|
122558
122704
|
var from = this.columnOrder.indexOf(fromUid);
|
|
122559
122705
|
var to = this.columnOrder.indexOf(toUid);
|
|
122560
122706
|
if (from < 0 || to < 0 || from === to) return;
|
|
@@ -122563,7 +122709,7 @@ var NormalReportSlotView = {
|
|
|
122563
122709
|
order.splice(to, 0, moved);
|
|
122564
122710
|
this.columnOrder = order;
|
|
122565
122711
|
this.$nextTick(function () {
|
|
122566
|
-
return
|
|
122712
|
+
return _this16.applyColumnOrder();
|
|
122567
122713
|
});
|
|
122568
122714
|
},
|
|
122569
122715
|
// ===== 对外方法(父组件通过 ref 调用) =====
|
|
@@ -122583,9 +122729,10 @@ var NormalReportSlotView = {
|
|
|
122583
122729
|
getSelection: function getSelection() {
|
|
122584
122730
|
return this.$refs.xTable ? this.$refs.xTable.getCheckboxRecords() : [];
|
|
122585
122731
|
},
|
|
122586
|
-
//
|
|
122732
|
+
// 表格重新布局(扩展:外层容器尺寸变化后调用)。
|
|
122733
|
+
// 必须完整重算:否则父容器高度变化后表体高度不更新,内容超出也不出滚动条
|
|
122587
122734
|
recalculate: function recalculate() {
|
|
122588
|
-
if (this.$refs.xTable) this.$refs.xTable.recalculate();
|
|
122735
|
+
if (this.$refs.xTable) this.$refs.xTable.recalculate(true);
|
|
122589
122736
|
},
|
|
122590
122737
|
// 树形表格:设置所有节点展开/收起(供页面“展开全部/收起全部”按钮使用)
|
|
122591
122738
|
setAllTreeExpand: function setAllTreeExpand(expanded) {
|
|
@@ -122600,18 +122747,14 @@ var NormalReportSlotView = {
|
|
|
122600
122747
|
// 表现为固定列行与数据行错位。此处监听表格容器尺寸变化,防抖后
|
|
122601
122748
|
// 重新计算布局并调用 refreshScroll() 强制同步各滚动层位置。
|
|
122602
122749
|
initResizeObserver: function initResizeObserver() {
|
|
122603
|
-
var
|
|
122750
|
+
var _this17 = this;
|
|
122604
122751
|
var wrapEl = this.$refs.tableWrap;
|
|
122605
122752
|
if (!wrapEl) return;
|
|
122606
122753
|
if (typeof ResizeObserver !== 'undefined') {
|
|
122607
|
-
|
|
122754
|
+
// 首次通知也要重算。挂载时容器往往已有高度,但还不是 flex 约束后的高度,
|
|
122755
|
+
// 跳过这次就会把“内容撑开的高度”当成可视高度,滚动条不再出现
|
|
122608
122756
|
this.resizeObserver = new ResizeObserver(function () {
|
|
122609
|
-
|
|
122610
|
-
if (_this16.resizeSkipFirst) {
|
|
122611
|
-
_this16.resizeSkipFirst = false;
|
|
122612
|
-
return;
|
|
122613
|
-
}
|
|
122614
|
-
_this16.scheduleTableRecalculate();
|
|
122757
|
+
_this17.scheduleTableRecalculate();
|
|
122615
122758
|
});
|
|
122616
122759
|
this.resizeObserver.observe(wrapEl);
|
|
122617
122760
|
} else {
|
|
@@ -122619,27 +122762,30 @@ var NormalReportSlotView = {
|
|
|
122619
122762
|
window.addEventListener('resize', this.handleWindowResize);
|
|
122620
122763
|
}
|
|
122621
122764
|
},
|
|
122622
|
-
//
|
|
122765
|
+
// 防抖:连续尺寸变化(如拖拽分割线)停稳后再重算,读到的是最终宽高
|
|
122623
122766
|
scheduleTableRecalculate: function scheduleTableRecalculate() {
|
|
122624
|
-
var
|
|
122625
|
-
if (this.resizeTimer)
|
|
122767
|
+
var _this18 = this;
|
|
122768
|
+
if (this.resizeTimer) clearTimeout(this.resizeTimer);
|
|
122626
122769
|
this.resizeTimer = setTimeout(function () {
|
|
122627
|
-
|
|
122628
|
-
|
|
122629
|
-
},
|
|
122770
|
+
_this18.resizeTimer = null;
|
|
122771
|
+
_this18.resizeRecalculate();
|
|
122772
|
+
}, 50);
|
|
122630
122773
|
},
|
|
122631
|
-
//
|
|
122774
|
+
// 重新计算布局,并在重算完成后强制同步固定列与主表体的滚动位置。
|
|
122775
|
+
// 容器还没有宽度时 vxe 会直接跳过滚动计算,等下一次尺寸通知再算
|
|
122632
122776
|
resizeRecalculate: function resizeRecalculate() {
|
|
122633
|
-
var
|
|
122777
|
+
var _this19 = this;
|
|
122634
122778
|
var xTable = this.$refs.xTable;
|
|
122779
|
+
var wrapEl = this.$refs.tableWrap;
|
|
122635
122780
|
if (!xTable) return;
|
|
122781
|
+
if (wrapEl && wrapEl.clientWidth === 0) return;
|
|
122636
122782
|
var restore = function restore() {
|
|
122637
|
-
|
|
122783
|
+
_this19.$nextTick(function () {
|
|
122638
122784
|
if (xTable.refreshScroll) xTable.refreshScroll();
|
|
122639
122785
|
});
|
|
122640
122786
|
};
|
|
122641
122787
|
if (xTable.recalculate) {
|
|
122642
|
-
var result = xTable.recalculate();
|
|
122788
|
+
var result = xTable.recalculate(true);
|
|
122643
122789
|
if (result && typeof result.then === 'function') {
|
|
122644
122790
|
result.then(restore);
|
|
122645
122791
|
} else {
|
|
@@ -122695,13 +122841,13 @@ var NormalReportSlotView = {
|
|
|
122695
122841
|
});
|
|
122696
122842
|
xTable.staticColumns = next;
|
|
122697
122843
|
this.$nextTick(function () {
|
|
122698
|
-
xTable.recalculate && xTable.recalculate();
|
|
122844
|
+
xTable.recalculate && xTable.recalculate(true);
|
|
122699
122845
|
});
|
|
122700
122846
|
},
|
|
122701
122847
|
// ===== 列设置弹层 =====
|
|
122702
122848
|
// 打开列设置:以当前注册列生成工作副本(每次打开都重新初始化)
|
|
122703
122849
|
openColumnSetting: function openColumnSetting() {
|
|
122704
|
-
var
|
|
122850
|
+
var _this20 = this;
|
|
122705
122851
|
var compMap = {};
|
|
122706
122852
|
this.columnComps.forEach(function (comp) {
|
|
122707
122853
|
compMap[comp._uid] = comp;
|
|
@@ -122729,7 +122875,7 @@ var NormalReportSlotView = {
|
|
|
122729
122875
|
// 列标题宽度:按最长列名称计算(中文 25px/字 + 英文 15px/字 + 30px 余量),
|
|
122730
122876
|
// 各列标题统一按该宽度显示,保证输入框与按钮对齐
|
|
122731
122877
|
this.columnTitleWidth = this.columnDraft.reduce(function (max, c) {
|
|
122732
|
-
return Math.max(max,
|
|
122878
|
+
return Math.max(max, _this20.calcColumnTitleWidth(c.title));
|
|
122733
122879
|
}, 0);
|
|
122734
122880
|
},
|
|
122735
122881
|
// 计算单个列标题的显示宽度(px):中文 25px/字 + 英文 15px/字 + 30px 余量
|
|
@@ -122821,10 +122967,10 @@ var NormalReportSlotView = {
|
|
|
122821
122967
|
},
|
|
122822
122968
|
// 确认:将面板副本应用到列状态并刷新表格
|
|
122823
122969
|
confirmColumnSetting: function confirmColumnSetting() {
|
|
122824
|
-
var
|
|
122970
|
+
var _this21 = this;
|
|
122825
122971
|
var order = [];
|
|
122826
122972
|
this.columnDraft.forEach(function (d) {
|
|
122827
|
-
|
|
122973
|
+
_this21.$set(_this21.columnStates, d.uid, {
|
|
122828
122974
|
visible: d.visible,
|
|
122829
122975
|
fixed: d.fixed || '',
|
|
122830
122976
|
minWidth: d.minWidth != null ? d.minWidth : null,
|
|
@@ -122835,7 +122981,7 @@ var NormalReportSlotView = {
|
|
|
122835
122981
|
this.columnOrder = order;
|
|
122836
122982
|
this.columnSettingVisible = false;
|
|
122837
122983
|
this.$nextTick(function () {
|
|
122838
|
-
|
|
122984
|
+
_this21.applyColumnOrder();
|
|
122839
122985
|
});
|
|
122840
122986
|
}
|
|
122841
122987
|
}
|
|
@@ -122857,8 +123003,8 @@ var StandardTablevue_type_style_index_0_prod_lang_scss_external = __webpack_requ
|
|
|
122857
123003
|
|
|
122858
123004
|
var StandardTable_component = normalizeComponent(
|
|
122859
123005
|
components_StandardTablevue_type_script_lang_js,
|
|
122860
|
-
|
|
122861
|
-
|
|
123006
|
+
StandardTablevue_type_template_id_a9e9136a_render,
|
|
123007
|
+
StandardTablevue_type_template_id_a9e9136a_staticRenderFns,
|
|
122862
123008
|
false,
|
|
122863
123009
|
null,
|
|
122864
123010
|
null,
|
|
@@ -122887,6 +123033,9 @@ var StandardTable_component = normalizeComponent(
|
|
|
122887
123033
|
* 自动计算最小列宽(中文 15px/个、英文 10px/个,另加 40px 留白);
|
|
122888
123034
|
* 5. tree-node 属性:为 true 时对应 vxe-table 列渲染树节点展开/收起图标
|
|
122889
123035
|
* (配合 vxe-table tree-config 使用)。
|
|
123036
|
+
* 6. 单元格编辑:editable 开启后点击单元格进入输入;
|
|
123037
|
+
* 也可用 edit-render 指定 vxe 编辑器(input / textarea / select 等),
|
|
123038
|
+
* 或用 #edit 插槽自定义编辑内容。
|
|
122890
123039
|
*/
|
|
122891
123040
|
/* harmony default export */ const Columnvue_type_script_lang_js = ({
|
|
122892
123041
|
name: 'StandardColumn',
|
|
@@ -122953,6 +123102,17 @@ var StandardTable_component = normalizeComponent(
|
|
|
122953
123102
|
formatter: {
|
|
122954
123103
|
type: Function,
|
|
122955
123104
|
"default": null
|
|
123105
|
+
},
|
|
123106
|
+
// 是否可编辑(点击单元格进入文本输入)。未传 edit-render 时按 input 处理
|
|
123107
|
+
editable: {
|
|
123108
|
+
type: Boolean,
|
|
123109
|
+
"default": false
|
|
123110
|
+
},
|
|
123111
|
+
// vxe-table 编辑渲染配置(选填),如 { name: 'input' }、{ name: 'select', options }
|
|
123112
|
+
// 传入后优先于 editable
|
|
123113
|
+
editRender: {
|
|
123114
|
+
type: Object,
|
|
123115
|
+
"default": null
|
|
122956
123116
|
}
|
|
122957
123117
|
},
|
|
122958
123118
|
computed: {
|
|
@@ -123140,12 +123300,13 @@ var ToolbarLeft_component = normalizeComponent(
|
|
|
123140
123300
|
* 工具栏右侧子组件(双标签组件):
|
|
123141
123301
|
*
|
|
123142
123302
|
* <standard-toolbar-right show-adjustment>
|
|
123143
|
-
* <
|
|
123303
|
+
* <standard-toolbar-query query-method="onQuery" export-method="onExport" />
|
|
123144
123304
|
* </standard-toolbar-right>
|
|
123145
123305
|
*
|
|
123146
123306
|
* 说明:
|
|
123147
|
-
* 1. 必须放在 <standard-table>
|
|
123148
|
-
*
|
|
123307
|
+
* 1. 必须放在 <standard-table> 默认插槽内,标签内部内容(按钮、standard-toolbar-query 等)
|
|
123308
|
+
* 由主组件就地渲染到表格操作区右侧(“调整”列设置按钮之前);
|
|
123309
|
+
* standard-toolbar-query 只能放在本组件内部;
|
|
123149
123310
|
* 2. showAdjustment(模板写法 show-adjustment):是否显示“调整”列设置按钮。
|
|
123150
123311
|
* 列设置弹层仍由主组件 StandardTable 渲染,本组件仅声明开关;
|
|
123151
123312
|
* 主组件自身的 showAdjustment 属性继续有效(任一为 true 即显示“调整”按钮);
|
|
@@ -123216,6 +123377,192 @@ var ToolbarRight_component = normalizeComponent(
|
|
|
123216
123377
|
)
|
|
123217
123378
|
|
|
123218
123379
|
/* harmony default export */ const ToolbarRight = (ToolbarRight_component.exports);
|
|
123380
|
+
;// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??ruleSet[1].rules[3]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./src/components/StandardTable/ToolbarQuery.vue?vue&type=template&id=d3cc2f7c
|
|
123381
|
+
var ToolbarQueryvue_type_template_id_d3cc2f7c_render = function render() {
|
|
123382
|
+
var _vm = this,
|
|
123383
|
+
_c = _vm._self._c;
|
|
123384
|
+
return _vm.placedCorrectly ? _c('div', {
|
|
123385
|
+
staticClass: "standard-toolbar-query"
|
|
123386
|
+
}, [_c('standard-input', {
|
|
123387
|
+
attrs: {
|
|
123388
|
+
"value": _vm.keyword,
|
|
123389
|
+
"placeholder": _vm.placeholder
|
|
123390
|
+
},
|
|
123391
|
+
on: {
|
|
123392
|
+
"input": _vm.onInput,
|
|
123393
|
+
"enter": _vm.onQuery
|
|
123394
|
+
}
|
|
123395
|
+
}), _c('standard-button', {
|
|
123396
|
+
attrs: {
|
|
123397
|
+
"type": "primary",
|
|
123398
|
+
"icon": "el-icon-search",
|
|
123399
|
+
"label": "查询",
|
|
123400
|
+
"loading": _vm.loading
|
|
123401
|
+
},
|
|
123402
|
+
on: {
|
|
123403
|
+
"click": _vm.onQuery
|
|
123404
|
+
}
|
|
123405
|
+
}), _c('standard-button', {
|
|
123406
|
+
attrs: {
|
|
123407
|
+
"icon": "el-icon-upload2",
|
|
123408
|
+
"label": "导出"
|
|
123409
|
+
},
|
|
123410
|
+
on: {
|
|
123411
|
+
"click": _vm.onExport
|
|
123412
|
+
}
|
|
123413
|
+
})], 1) : _vm._e();
|
|
123414
|
+
};
|
|
123415
|
+
var ToolbarQueryvue_type_template_id_d3cc2f7c_staticRenderFns = [];
|
|
123416
|
+
|
|
123417
|
+
;// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./src/components/StandardTable/ToolbarQuery.vue?vue&type=script&lang=js
|
|
123418
|
+
|
|
123419
|
+
|
|
123420
|
+
|
|
123421
|
+
/**
|
|
123422
|
+
* 工具栏右侧查询子组件(单标签):
|
|
123423
|
+
*
|
|
123424
|
+
* <standard-toolbar-right>
|
|
123425
|
+
* <standard-toolbar-query
|
|
123426
|
+
* v-model="keyword"
|
|
123427
|
+
* placeholder="请输入关键字"
|
|
123428
|
+
* query-method="onQuery"
|
|
123429
|
+
* export-method="onExport"
|
|
123430
|
+
* />
|
|
123431
|
+
* </standard-toolbar-right>
|
|
123432
|
+
*
|
|
123433
|
+
* 说明:
|
|
123434
|
+
* 1. 只能作为 standard-toolbar-right 的子组件使用,放在其它位置时不渲染并给出警告;
|
|
123435
|
+
* 2. 默认包含输入框、查询按钮、导出按钮(从左到右);输入框回车与点击查询等效;
|
|
123436
|
+
* 3. queryMethod / exportMethod(模板写法 query-method / export-method)
|
|
123437
|
+
* 支持函数(直接调用)与字符串(沿父组件链查找页面方法),入参为当前关键字;
|
|
123438
|
+
* 4. 同时派发 query / export 事件,参数同样为当前关键字。
|
|
123439
|
+
*/
|
|
123440
|
+
/* harmony default export */ const ToolbarQueryvue_type_script_lang_js = ({
|
|
123441
|
+
name: 'StandardToolbarQuery',
|
|
123442
|
+
components: {
|
|
123443
|
+
StandardInput: StandardInput,
|
|
123444
|
+
StandardButton: StandardButton
|
|
123445
|
+
},
|
|
123446
|
+
model: {
|
|
123447
|
+
prop: 'value',
|
|
123448
|
+
event: 'input'
|
|
123449
|
+
},
|
|
123450
|
+
props: {
|
|
123451
|
+
// v-model 绑定的查询关键字
|
|
123452
|
+
value: {
|
|
123453
|
+
type: [String, Number],
|
|
123454
|
+
"default": ''
|
|
123455
|
+
},
|
|
123456
|
+
// 输入框占位文案
|
|
123457
|
+
placeholder: {
|
|
123458
|
+
type: String,
|
|
123459
|
+
"default": '请输入关键字'
|
|
123460
|
+
},
|
|
123461
|
+
// 查询方法:函数直接调用,字符串则沿父组件链查找同名方法
|
|
123462
|
+
queryMethod: {
|
|
123463
|
+
type: [Function, String],
|
|
123464
|
+
"default": ''
|
|
123465
|
+
},
|
|
123466
|
+
// 导出方法:函数直接调用,字符串则沿父组件链查找同名方法
|
|
123467
|
+
exportMethod: {
|
|
123468
|
+
type: [Function, String],
|
|
123469
|
+
"default": ''
|
|
123470
|
+
},
|
|
123471
|
+
// 查询按钮加载态
|
|
123472
|
+
loading: {
|
|
123473
|
+
type: Boolean,
|
|
123474
|
+
"default": false
|
|
123475
|
+
}
|
|
123476
|
+
},
|
|
123477
|
+
data: function data() {
|
|
123478
|
+
return {
|
|
123479
|
+
// 未确认父级前先渲染,挂载后若不在 toolbar-right 内再隐藏,避免正确用法被误伤
|
|
123480
|
+
placedCorrectly: true,
|
|
123481
|
+
keyword: this.value == null ? '' : String(this.value)
|
|
123482
|
+
};
|
|
123483
|
+
},
|
|
123484
|
+
watch: {
|
|
123485
|
+
value: function value(val) {
|
|
123486
|
+
this.keyword = val == null ? '' : String(val);
|
|
123487
|
+
}
|
|
123488
|
+
},
|
|
123489
|
+
mounted: function mounted() {
|
|
123490
|
+
this.validatePlacement();
|
|
123491
|
+
},
|
|
123492
|
+
methods: {
|
|
123493
|
+
// 沿父组件链查找 StandardToolbarRight(插槽内容的 $parent 为实际渲染它的组件)
|
|
123494
|
+
findToolbarRight: function findToolbarRight() {
|
|
123495
|
+
var parent = this.$parent;
|
|
123496
|
+
while (parent) {
|
|
123497
|
+
if (parent.$options && parent.$options.name === 'StandardToolbarRight') return parent;
|
|
123498
|
+
parent = parent.$parent;
|
|
123499
|
+
}
|
|
123500
|
+
return null;
|
|
123501
|
+
},
|
|
123502
|
+
// 父组件链与 DOM 宿主双重确认:任一命中即视为放在 standard-toolbar-right 内
|
|
123503
|
+
validatePlacement: function validatePlacement() {
|
|
123504
|
+
var el = this.$el;
|
|
123505
|
+
var byDom = !!(el && el.nodeType === 1 && el.parentElement && el.parentElement.closest('.standard-toolbar-right'));
|
|
123506
|
+
if (this.findToolbarRight() || byDom) return;
|
|
123507
|
+
this.placedCorrectly = false;
|
|
123508
|
+
console.warn('[StandardToolbarQuery] 只能放在 standard-toolbar-right 内部');
|
|
123509
|
+
},
|
|
123510
|
+
onInput: function onInput(val) {
|
|
123511
|
+
this.keyword = val == null ? '' : String(val);
|
|
123512
|
+
this.$emit('input', this.keyword);
|
|
123513
|
+
},
|
|
123514
|
+
// method 为函数时直接调用;为字符串时沿父组件链查找同名方法
|
|
123515
|
+
invokeMethod: function invokeMethod(method, keyword) {
|
|
123516
|
+
if (typeof method === 'function') {
|
|
123517
|
+
method(keyword);
|
|
123518
|
+
return;
|
|
123519
|
+
}
|
|
123520
|
+
if (typeof method === 'string' && method) {
|
|
123521
|
+
var parent = this.$parent;
|
|
123522
|
+
while (parent) {
|
|
123523
|
+
if (typeof parent[method] === 'function') {
|
|
123524
|
+
parent[method](keyword);
|
|
123525
|
+
return;
|
|
123526
|
+
}
|
|
123527
|
+
parent = parent.$parent;
|
|
123528
|
+
}
|
|
123529
|
+
console.warn("[StandardToolbarQuery] \u672A\u627E\u5230\u65B9\u6CD5 ".concat(method));
|
|
123530
|
+
}
|
|
123531
|
+
},
|
|
123532
|
+
onQuery: function onQuery() {
|
|
123533
|
+
var keyword = this.keyword;
|
|
123534
|
+
this.invokeMethod(this.queryMethod, keyword);
|
|
123535
|
+
this.$emit('query', keyword);
|
|
123536
|
+
},
|
|
123537
|
+
onExport: function onExport() {
|
|
123538
|
+
var keyword = this.keyword;
|
|
123539
|
+
this.invokeMethod(this.exportMethod, keyword);
|
|
123540
|
+
this.$emit('export', keyword);
|
|
123541
|
+
}
|
|
123542
|
+
}
|
|
123543
|
+
});
|
|
123544
|
+
;// ./src/components/StandardTable/ToolbarQuery.vue?vue&type=script&lang=js
|
|
123545
|
+
/* harmony default export */ const StandardTable_ToolbarQueryvue_type_script_lang_js = (ToolbarQueryvue_type_script_lang_js);
|
|
123546
|
+
;// ./src/components/StandardTable/ToolbarQuery.vue
|
|
123547
|
+
|
|
123548
|
+
|
|
123549
|
+
|
|
123550
|
+
|
|
123551
|
+
|
|
123552
|
+
/* normalize component */
|
|
123553
|
+
;
|
|
123554
|
+
var ToolbarQuery_component = normalizeComponent(
|
|
123555
|
+
StandardTable_ToolbarQueryvue_type_script_lang_js,
|
|
123556
|
+
ToolbarQueryvue_type_template_id_d3cc2f7c_render,
|
|
123557
|
+
ToolbarQueryvue_type_template_id_d3cc2f7c_staticRenderFns,
|
|
123558
|
+
false,
|
|
123559
|
+
null,
|
|
123560
|
+
null,
|
|
123561
|
+
null
|
|
123562
|
+
|
|
123563
|
+
)
|
|
123564
|
+
|
|
123565
|
+
/* harmony default export */ const ToolbarQuery = (ToolbarQuery_component.exports);
|
|
123219
123566
|
;// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./src/components/StandardTable/FooterLeft.vue?vue&type=script&lang=js
|
|
123220
123567
|
/**
|
|
123221
123568
|
* 底部栏左侧子组件(单标签组件):
|
|
@@ -123397,6 +123744,7 @@ var FooterRight_component = normalizeComponent(
|
|
|
123397
123744
|
* 'standard-column': StandardTable.Column,
|
|
123398
123745
|
* 'standard-toolbar-left': StandardTable.ToolbarLeft,
|
|
123399
123746
|
* 'standard-toolbar-right': StandardTable.ToolbarRight,
|
|
123747
|
+
* 'standard-toolbar-query': StandardTable.ToolbarQuery,
|
|
123400
123748
|
* 'standard-footer-left': StandardTable.FooterLeft,
|
|
123401
123749
|
* 'standard-footer-right': StandardTable.FooterRight,
|
|
123402
123750
|
* 'standard-footer-empty': StandardTable.FooterEmpty,
|
|
@@ -123418,10 +123766,12 @@ var FooterRight_component = normalizeComponent(
|
|
|
123418
123766
|
|
|
123419
123767
|
|
|
123420
123768
|
|
|
123769
|
+
|
|
123421
123770
|
// 将各子组件挂载为静态属性,方便引用方统一引入注册
|
|
123422
123771
|
StandardTable.Column = Column;
|
|
123423
123772
|
StandardTable.ToolbarLeft = ToolbarLeft;
|
|
123424
123773
|
StandardTable.ToolbarRight = ToolbarRight;
|
|
123774
|
+
StandardTable.ToolbarQuery = ToolbarQuery;
|
|
123425
123775
|
StandardTable.FooterLeft = FooterLeft;
|
|
123426
123776
|
StandardTable.FooterRight = FooterRight;
|
|
123427
123777
|
StandardTable.FooterEmpty = FooterEmpty;
|
|
@@ -123433,6 +123783,7 @@ StandardTable.install = function (Vue) {
|
|
|
123433
123783
|
Vue.component(Column.name, Column);
|
|
123434
123784
|
Vue.component(ToolbarLeft.name, ToolbarLeft);
|
|
123435
123785
|
Vue.component(ToolbarRight.name, ToolbarRight);
|
|
123786
|
+
Vue.component(ToolbarQuery.name, ToolbarQuery);
|
|
123436
123787
|
Vue.component(FooterLeft.name, FooterLeft);
|
|
123437
123788
|
Vue.component(FooterRight.name, FooterRight);
|
|
123438
123789
|
Vue.component(FooterEmpty.name, FooterEmpty);
|