@web-utils/component 2.0.12 → 2.0.14
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/dist/chunks/3a79781b.js +75 -0
- package/dist/chunks/{44b78389.js → 41a066be.js} +8 -8
- package/dist/chunks/{e1939731.js → 5a78e0db.js} +5 -6
- package/dist/chunks/5d4282fb.js +30 -0
- package/dist/chunks/{822300f3.js → 61ad06b2.js} +3 -3
- package/dist/chunks/76680a03.js +24 -0
- package/dist/chunks/8c0142e0.js +81 -0
- package/dist/chunks/97652d86.js +26 -0
- package/dist/chunks/b4acd3a6.js +126 -0
- package/dist/chunks/f71045fc.js +184 -0
- package/dist/components/address-input/index.js +43 -56
- package/dist/components/address-input/style.css +1 -15
- package/dist/components/aside-menu/index.js +30 -36
- package/dist/components/aside-menu/style.css +1 -9
- package/dist/components/awesome-button/index.js +32 -35
- package/dist/components/base.css +1 -66
- package/dist/components/capsule-tab/index.js +27 -33
- package/dist/components/capsule-tab/style.css +1 -32
- package/dist/components/chunk-file-uploader/index.js +54 -88
- package/dist/components/chunk-file-uploader/style.css +1 -4
- package/dist/components/chunk-file-uploader-button/index.js +25 -31
- package/dist/components/chunk-file-uploader-button/style.css +1 -17
- package/dist/components/chunk-file-uploader-drop/index.js +28 -42
- package/dist/components/chunk-file-uploader-drop/style.css +1 -12
- package/dist/components/chunk-file-uploader-file/index.js +134 -212
- package/dist/components/chunk-file-uploader-file/style.css +1 -125
- package/dist/components/chunk-file-uploader-files/index.js +28 -34
- package/dist/components/chunk-file-uploader-files/style.css +1 -9
- package/dist/components/chunk-file-uploader-list/index.js +29 -35
- package/dist/components/chunk-file-uploader-list/style.css +1 -9
- package/dist/components/chunk-file-uploader-un-support/index.js +30 -38
- package/dist/components/chunk-file-uploader-un-support/style.css +1 -6
- package/dist/components/code-mirror-editor/index.js +153 -181
- package/dist/components/code-mirror-editor/style.css +1 -17
- package/dist/components/color-picker/index.js +49 -68
- package/dist/components/confirm-button/index.js +19 -21
- package/dist/components/confirmable/index.js +18 -19
- package/dist/components/context-menu/index.js +108 -130
- package/dist/components/context-menu/style.css +1 -88
- package/dist/components/custom-scrollbar/index.js +49 -67
- package/dist/components/data-table-picker/index.js +62 -81
- package/dist/components/dynamic-table/index.js +89 -113
- package/dist/components/dynamic-table/style.css +1 -30
- package/dist/components/e-charts/index.js +120 -201
- package/dist/components/e-charts/style.css +1 -10
- package/dist/components/editable-progress/index.js +60 -93
- package/dist/components/editable-progress/style.css +1 -37
- package/dist/components/editable-tree/index.js +423 -638
- package/dist/components/editable-tree/style.css +1 -82
- package/dist/components/egd-collapse/index.js +33 -46
- package/dist/components/egd-collapse-item/index.js +60 -76
- package/dist/components/element-dialog/index.js +95 -147
- package/dist/components/element-dialog/style.css +1 -102
- package/dist/components/empty-view/index.js +28 -34
- package/dist/components/empty-view/style.css +1 -17
- package/dist/components/error-view/index.js +26 -32
- package/dist/components/error-view/style.css +1 -17
- package/dist/components/flex-column/index.js +25 -40
- package/dist/components/flex-item/index.js +29 -57
- package/dist/components/flex-row/index.js +25 -40
- package/dist/components/flex-scroller/index.js +26 -32
- package/dist/components/flex-scroller/style.css +1 -20
- package/dist/components/form-button/index.js +34 -38
- package/dist/components/form-cascader/index.js +71 -81
- package/dist/components/form-checkbox-group/index.js +88 -113
- package/dist/components/form-checkbox-group/style.css +1 -51
- package/dist/components/form-date-picker/index.js +70 -132
- package/dist/components/form-holder/index.js +32 -39
- package/dist/components/form-input/index.js +56 -62
- package/dist/components/form-input-email/index.js +48 -60
- package/dist/components/form-input-id-card/index.js +53 -59
- package/dist/components/form-input-number/index.js +61 -68
- package/dist/components/form-input-number/style.css +1 -12
- package/dist/components/form-input-phone-number/index.js +49 -55
- package/dist/components/form-input-time/index.js +53 -59
- package/dist/components/form-item/index.js +80 -123
- package/dist/components/form-item/style.css +1 -11
- package/dist/components/form-item-config-provider/index.js +25 -26
- package/dist/components/form-item-group/index.js +85 -111
- package/dist/components/form-item-group/style.css +1 -30
- package/dist/components/form-radio-group/index.js +85 -104
- package/dist/components/form-radio-group/style.css +1 -53
- package/dist/components/form-select/index.js +76 -91
- package/dist/components/form-switch/index.js +51 -57
- package/dist/components/form-textarea/index.js +51 -57
- package/dist/components/form-view/index.js +165 -232
- package/dist/components/form-view/style.css +1 -158
- package/dist/components/guide-steps/index.js +44 -58
- package/dist/components/guide-steps/style.css +1 -34
- package/dist/components/icon-card/index.js +29 -35
- package/dist/components/icon-card/style.css +1 -56
- package/dist/components/iframe-window/index.js +29 -35
- package/dist/components/iframe-window/style.css +1 -20
- package/dist/components/image-viewer/index.js +48 -66
- package/dist/components/image-viewer/style.css +1 -21
- package/dist/components/input-number/index.js +127 -193
- package/dist/components/input-number/style.css +1 -15
- package/dist/components/input-number-range/index.js +45 -57
- package/dist/components/input-number-range/style.css +1 -12
- package/dist/components/j-s-x-component/index.js +4 -4
- package/dist/components/keep-view-alive/index.js +73 -120
- package/dist/components/loading-view/index.js +26 -32
- package/dist/components/loading-view/style.css +1 -17
- package/dist/components/nav-bar/index.js +27 -37
- package/dist/components/nav-bar/style.css +1 -17
- package/dist/components/not-implement/index.js +23 -31
- package/dist/components/not-implement/style.css +1 -15
- package/dist/components/page/index.js +22 -28
- package/dist/components/page/style.css +1 -12
- package/dist/components/page-header/index.js +30 -36
- package/dist/components/page-header/style.css +1 -14
- package/dist/components/page-index/index.js +62 -83
- package/dist/components/page-index/style.css +1 -23
- package/dist/components/page-index-top/index.js +53 -68
- package/dist/components/page-skeleton/index.js +31 -37
- package/dist/components/page-skeleton/style.css +1 -23
- package/dist/components/page-skeleton-new/index.js +42 -48
- package/dist/components/page-skeleton-new/style.css +1 -42
- package/dist/components/pageable-table/index.js +186 -253
- package/dist/components/pageable-table/style.css +1 -72
- package/dist/components/pageable-view/index.js +129 -199
- package/dist/components/pageable-view/style.css +1 -69
- package/dist/components/photo-swipe/index.js +110 -151
- package/dist/components/photo-swipe/style.css +1 -20
- package/dist/components/resize-observer/index.js +34 -68
- package/dist/components/resize-observer/style.css +1 -31
- package/dist/components/search-popover/index.js +153 -211
- package/dist/components/search-popover/style.css +1 -93
- package/dist/components/sign-panel/index.js +92 -142
- package/dist/components/sign-panel/style.css +1 -97
- package/dist/components/split-pane/index.js +101 -162
- package/dist/components/split-pane/style.css +1 -100
- package/dist/components/stateful/index.js +31 -34
- package/dist/components/stateful/style.css +1 -33
- package/dist/components/static-pageable-table/index.js +37 -44
- package/dist/components/static-pageable-table/style.css +1 -9
- package/dist/components/swiper/index.js +85 -150
- package/dist/components/swiper/style.css +1 -43
- package/dist/components/tab/index.js +54 -72
- package/dist/components/tab/style.css +1 -122
- package/dist/components/tab-item/index.js +30 -35
- package/dist/components/table-column/index.js +30 -32
- package/dist/components/table-view/index.js +156 -227
- package/dist/components/table-view/style.css +1 -95
- package/dist/components/tag-render/index.js +44 -58
- package/dist/components/tag-render/style.css +1 -33
- package/dist/components/tinymce-editor/index.js +79 -95
- package/dist/components/tinymce-editor/style.css +1 -43
- package/dist/components/tinymce-wrapper/index.js +92 -121
- package/dist/components/tinymce-wrapper/style.css +1 -36
- package/dist/components/toolbar/index.js +63 -84
- package/dist/components/toolbar/style.css +1 -39
- package/dist/components/toolbar-button/index.js +41 -48
- package/dist/components/toolbar-button/style.css +1 -21
- package/dist/components/trigger/index.js +29 -36
- package/dist/components/vue-tags-input/index.js +188 -308
- package/dist/components/vue-tags-input/style.css +1 -682
- package/dist/components/watermark/index.js +25 -37
- package/dist/components/watermark/style.css +1 -11
- package/dist/components/x-dialog/index.js +67 -93
- package/dist/components/x-dialog/style.css +1 -15
- package/dist/index.css +193 -1105
- package/dist/index.es.js +4790 -7243
- package/package.json +1 -2
- package/web-types.json +1 -1
- package/dist/chunks/3d28cc08.js +0 -57
- package/dist/chunks/5d33812d.js +0 -147
- package/dist/chunks/9d848bf6.js +0 -99
- package/dist/chunks/a0bb327b.js +0 -96
- package/dist/chunks/a8891d2c.js +0 -30
- package/dist/chunks/c69d5628.js +0 -248
- package/dist/chunks/de9fe802.js +0 -24
|
@@ -1,185 +1,161 @@
|
|
|
1
|
-
import { isString, isArray, trace, warning, merge, toStringArray, isFunction, hasOwn } from "@web-utils/core";
|
|
2
|
-
import { k as
|
|
3
|
-
import { n as
|
|
4
|
-
var
|
|
5
|
-
var
|
|
6
|
-
|
|
7
|
-
var _c = _vm._self._c || _h;
|
|
8
|
-
return _c("div", {
|
|
1
|
+
import { isString as o, isArray as d, trace as n, warning as f, merge as i, toStringArray as p, isFunction as u, hasOwn as c } from "@web-utils/core";
|
|
2
|
+
import { k as b } from "../../chunks/f71045fc.js";
|
|
3
|
+
import { n as m } from "../../chunks/5d4282fb.js";
|
|
4
|
+
var _ = function() {
|
|
5
|
+
var e = this, r = e.$createElement, t = e._self._c || r;
|
|
6
|
+
return t("div", {
|
|
9
7
|
staticClass: "table-view"
|
|
10
|
-
}, [
|
|
8
|
+
}, [t("Toolbar", e._g(e._b({
|
|
11
9
|
on: {
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
10
|
+
search: e.toggleSearch,
|
|
11
|
+
del: e.del,
|
|
12
|
+
create: e.create,
|
|
13
|
+
reload: e.reloadTable,
|
|
14
|
+
imp: function(s) {
|
|
15
|
+
e.importDialogVisible = !0;
|
|
18
16
|
}
|
|
19
17
|
},
|
|
20
|
-
scopedSlots:
|
|
18
|
+
scopedSlots: e._u([{
|
|
21
19
|
key: "default",
|
|
22
20
|
fn: function() {
|
|
23
|
-
return [
|
|
21
|
+
return [e._t("toolbar-button")];
|
|
24
22
|
},
|
|
25
|
-
proxy:
|
|
26
|
-
},
|
|
23
|
+
proxy: !0
|
|
24
|
+
}, e._l(e.buttonSlots, function(s) {
|
|
27
25
|
return {
|
|
28
|
-
key:
|
|
26
|
+
key: s,
|
|
29
27
|
fn: function() {
|
|
30
|
-
return [
|
|
28
|
+
return [e._t(s)];
|
|
31
29
|
},
|
|
32
|
-
proxy:
|
|
30
|
+
proxy: !0
|
|
33
31
|
};
|
|
34
|
-
})], null,
|
|
35
|
-
}, "Toolbar",
|
|
32
|
+
})], null, !0)
|
|
33
|
+
}, "Toolbar", e.toolbarProps, !1), e.toolbarListeners)), t("div", {
|
|
36
34
|
staticClass: "table-view-content-wrapper"
|
|
37
|
-
}, [
|
|
35
|
+
}, [t("div", {
|
|
38
36
|
staticClass: "table-view-content"
|
|
39
|
-
}, [
|
|
37
|
+
}, [e.treeProps.show ? t("div", {
|
|
40
38
|
ref: "treeScroller",
|
|
41
39
|
staticClass: "table-view-sidebar",
|
|
42
40
|
on: {
|
|
43
|
-
|
|
41
|
+
scroll: e.onTreeScroll
|
|
44
42
|
}
|
|
45
|
-
}, [
|
|
43
|
+
}, [t("div", {
|
|
46
44
|
staticStyle: {
|
|
47
45
|
"font-size": "16px"
|
|
48
46
|
}
|
|
49
|
-
}, [
|
|
47
|
+
}, [e._v(" 视图导航 ")]), t("EditableTree", e._g(e._b({
|
|
50
48
|
ref: "tree",
|
|
51
49
|
attrs: {
|
|
52
|
-
|
|
50
|
+
readonly: ""
|
|
53
51
|
},
|
|
54
|
-
scopedSlots:
|
|
52
|
+
scopedSlots: e._u([{
|
|
55
53
|
key: "default",
|
|
56
|
-
fn: function(
|
|
57
|
-
var
|
|
58
|
-
return [
|
|
59
|
-
return [
|
|
54
|
+
fn: function(s) {
|
|
55
|
+
var l = s.node, a = s.data;
|
|
56
|
+
return [e._t("tree-node", function() {
|
|
57
|
+
return [t("span", [t("i", {
|
|
60
58
|
staticClass: "node-icon",
|
|
61
|
-
class:
|
|
62
|
-
}),
|
|
63
|
-
return [
|
|
59
|
+
class: l.childNodes.length > 0 ? l.expanded ? "el-icon-folder-opened" : "el-icon-folder" : "el-icon-tickets"
|
|
60
|
+
}), e._t("tree-label", function() {
|
|
61
|
+
return [e._v(e._s(l.label))];
|
|
64
62
|
}, {
|
|
65
|
-
|
|
66
|
-
|
|
63
|
+
node: l,
|
|
64
|
+
data: a
|
|
67
65
|
})], 2)];
|
|
68
66
|
}, {
|
|
69
|
-
|
|
70
|
-
|
|
67
|
+
node: l,
|
|
68
|
+
data: a
|
|
71
69
|
})];
|
|
72
70
|
}
|
|
73
|
-
}], null,
|
|
74
|
-
}, "EditableTree",
|
|
71
|
+
}], null, !0)
|
|
72
|
+
}, "EditableTree", e.treeProps, !1), e.treeListeners))], 1) : e._e(), t("div", {
|
|
75
73
|
staticClass: "table-view-table"
|
|
76
|
-
}, [
|
|
74
|
+
}, [t("PageableTable", e._g(e._b({
|
|
77
75
|
ref: "table",
|
|
78
76
|
class: [{
|
|
79
|
-
"border-top":
|
|
80
|
-
"border-bottom":
|
|
81
|
-
"border-left":
|
|
82
|
-
"border-right":
|
|
77
|
+
"border-top": e.borderTop,
|
|
78
|
+
"border-bottom": e.borderBottom,
|
|
79
|
+
"border-left": e.borderLeft || e.treeAttrs && e.treeAttrs.show,
|
|
80
|
+
"border-right": e.borderRight
|
|
83
81
|
}],
|
|
84
82
|
attrs: {
|
|
85
|
-
|
|
83
|
+
border: e.border
|
|
86
84
|
},
|
|
87
85
|
on: {
|
|
88
|
-
"row-dblclick":
|
|
89
|
-
"selection-change":
|
|
86
|
+
"row-dblclick": e.rowDbClick,
|
|
87
|
+
"selection-change": e.onSelectionChange
|
|
90
88
|
}
|
|
91
|
-
}, "PageableTable",
|
|
89
|
+
}, "PageableTable", e.tableProps, !1), e.tableListeners), [e._t("columns")], 2)], 1)]), e.toolbarProps.searchable ? t("div", {
|
|
92
90
|
staticClass: "slide-panel",
|
|
93
91
|
style: {
|
|
94
|
-
right: `${
|
|
95
|
-
width: `${
|
|
92
|
+
right: `${e.right}px`,
|
|
93
|
+
width: `${e.searchPanelProps.width}px`
|
|
96
94
|
}
|
|
97
|
-
}, [
|
|
95
|
+
}, [e._m(0), t("div", {
|
|
98
96
|
staticClass: "slide-panel-content"
|
|
99
|
-
}, [
|
|
97
|
+
}, [t("ElForm", {
|
|
100
98
|
ref: "form",
|
|
101
99
|
attrs: {
|
|
102
100
|
"label-position": "right",
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
"label-width":
|
|
101
|
+
model: e.searchModel || e.searchPanelProps.model,
|
|
102
|
+
size: "mini",
|
|
103
|
+
"label-width": e.labelWidth
|
|
106
104
|
},
|
|
107
105
|
nativeOn: {
|
|
108
|
-
"!submit": function(
|
|
109
|
-
|
|
110
|
-
return _vm.onSearchClick.apply(null, arguments);
|
|
106
|
+
"!submit": function(s) {
|
|
107
|
+
return s.preventDefault(), e.onSearchClick.apply(null, arguments);
|
|
111
108
|
}
|
|
112
109
|
}
|
|
113
|
-
}, [
|
|
110
|
+
}, [t("FormItemConfigProvider", {
|
|
114
111
|
attrs: {
|
|
115
|
-
|
|
116
|
-
"wrap-col":
|
|
112
|
+
block: "",
|
|
113
|
+
"wrap-col": !1
|
|
117
114
|
}
|
|
118
|
-
}, [
|
|
115
|
+
}, [t("ElRow", {
|
|
119
116
|
attrs: {
|
|
120
|
-
|
|
117
|
+
gutter: 0
|
|
121
118
|
}
|
|
122
|
-
}, [
|
|
123
|
-
return [
|
|
124
|
-
})], 2)], 1),
|
|
119
|
+
}, [e._t("search-form", function() {
|
|
120
|
+
return [t("p", [e._v("请添加搜索条件!")])];
|
|
121
|
+
})], 2)], 1), t("ElFormItem", {
|
|
125
122
|
attrs: {
|
|
126
123
|
"label-width": "0"
|
|
127
124
|
}
|
|
128
|
-
}, [
|
|
125
|
+
}, [t("div", {
|
|
129
126
|
staticClass: "slide-panel-actions"
|
|
130
|
-
}, [
|
|
127
|
+
}, [t("ElButton", {
|
|
131
128
|
attrs: {
|
|
132
|
-
|
|
129
|
+
type: "primary",
|
|
133
130
|
"native-type": "submit",
|
|
134
|
-
|
|
131
|
+
size: "mini"
|
|
135
132
|
}
|
|
136
|
-
}, [
|
|
133
|
+
}, [e._v(" 开始搜索 ")]), t("ElButton", {
|
|
137
134
|
attrs: {
|
|
138
|
-
|
|
135
|
+
size: "mini"
|
|
139
136
|
},
|
|
140
137
|
on: {
|
|
141
|
-
|
|
138
|
+
click: e.onClearClick
|
|
142
139
|
}
|
|
143
|
-
}, [
|
|
144
|
-
}
|
|
145
|
-
var
|
|
146
|
-
|
|
147
|
-
var _h = _vm.$createElement;
|
|
148
|
-
var _c = _vm._self._c || _h;
|
|
149
|
-
return _c("div", {
|
|
140
|
+
}, [e._v(" 清除条件 ")])], 1)])], 1)], 1)]) : e._e()]), e._t("default")], 2);
|
|
141
|
+
}, g = [function() {
|
|
142
|
+
var e = this, r = e.$createElement, t = e._self._c || r;
|
|
143
|
+
return t("div", {
|
|
150
144
|
staticClass: "slide-panel-line"
|
|
151
|
-
}, [
|
|
145
|
+
}, [t("div", {
|
|
152
146
|
staticClass: "slide-panel-line-indicator"
|
|
153
147
|
})]);
|
|
154
148
|
}];
|
|
155
|
-
const
|
|
156
|
-
const builtInButtons = ["back", "create", "save", "withdraw", "edit", "submit", "publish", "agree", "disagree", "reject", "finish", "cancel", "enable", "exp", "imp", "del", "disabled", "reload", "slot"];
|
|
157
|
-
const __vue2_script = {
|
|
149
|
+
const w = ["back", "create", "save", "withdraw", "edit", "submit", "publish", "agree", "disagree", "reject", "finish", "cancel", "enable", "exp", "imp", "del", "disabled", "reload", "slot"], v = {
|
|
158
150
|
name: "TableView",
|
|
159
151
|
bus: {
|
|
160
|
-
reloadTableView(
|
|
161
|
-
if (
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
viewIds = viewIds.split(",");
|
|
168
|
-
}
|
|
169
|
-
if (this._viewIds.some((value) => viewIds.includes(value))) {
|
|
170
|
-
if (!tree) {
|
|
171
|
-
trace.call(this.$parent || {}, "reloadTable");
|
|
172
|
-
this.reloadTable();
|
|
173
|
-
} else {
|
|
174
|
-
if (this.$refs.tree) {
|
|
175
|
-
trace.call(this.$parent || {}, "reloadTree");
|
|
176
|
-
this.refreshTree();
|
|
177
|
-
}
|
|
178
|
-
}
|
|
179
|
-
}
|
|
180
|
-
} else {
|
|
181
|
-
warning.call(this.$parent || {}, "`viewId`的类型必须是字符串或数组");
|
|
182
|
-
}
|
|
152
|
+
reloadTableView(e, r) {
|
|
153
|
+
if (this._viewIds)
|
|
154
|
+
if (o(e) || d(e)) {
|
|
155
|
+
let t = e;
|
|
156
|
+
o(t) && (t = t.split(",")), this._viewIds.some((s) => t.includes(s)) && (r ? this.$refs.tree && (n.call(this.$parent || {}, "reloadTree"), this.refreshTree()) : (n.call(this.$parent || {}, "reloadTable"), this.reloadTable()));
|
|
157
|
+
} else
|
|
158
|
+
f.call(this.$parent || {}, "`viewId`的类型必须是字符串或数组");
|
|
183
159
|
}
|
|
184
160
|
},
|
|
185
161
|
props: {
|
|
@@ -227,7 +203,7 @@ const __vue2_script = {
|
|
|
227
203
|
borderRight: Boolean,
|
|
228
204
|
border: {
|
|
229
205
|
type: Boolean,
|
|
230
|
-
default:
|
|
206
|
+
default: !0
|
|
231
207
|
},
|
|
232
208
|
labelWidth: {
|
|
233
209
|
type: String,
|
|
@@ -238,132 +214,93 @@ const __vue2_script = {
|
|
|
238
214
|
}
|
|
239
215
|
},
|
|
240
216
|
data() {
|
|
241
|
-
var
|
|
217
|
+
var e;
|
|
242
218
|
return {
|
|
243
|
-
importDialogVisible:
|
|
244
|
-
right: -(((
|
|
219
|
+
importDialogVisible: !1,
|
|
220
|
+
right: -(((e = this.searchPanelAttrs) == null ? void 0 : e.width) || 350),
|
|
245
221
|
selectedRows: []
|
|
246
222
|
};
|
|
247
223
|
},
|
|
248
224
|
computed: {
|
|
249
225
|
buttonSlots() {
|
|
250
|
-
return
|
|
226
|
+
return w.filter((e) => this.$scopedSlots[e]);
|
|
251
227
|
},
|
|
252
228
|
toolbarProps() {
|
|
253
|
-
var
|
|
254
|
-
const
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
buttons = buttons || [];
|
|
258
|
-
if (!buttons.includes("reload")) {
|
|
259
|
-
buttons = [...buttons, "reload"];
|
|
260
|
-
}
|
|
261
|
-
toolbarAttrs.buttons = buttons;
|
|
262
|
-
toolbarAttrs.buttons = toStringArray(toolbarAttrs.buttons);
|
|
263
|
-
toolbarAttrs.searchable = !!((_b = (_a = this.$scopedSlots)["search-form"]) == null ? void 0 : _b.call(_a));
|
|
264
|
-
return toolbarAttrs;
|
|
229
|
+
var s, l;
|
|
230
|
+
const e = {}, r = i(this.toolbarAttrs, e);
|
|
231
|
+
let t = (r == null ? void 0 : r.buttons) || this.$parent.buttons;
|
|
232
|
+
return t = t || [], t.includes("reload") || (t = [...t, "reload"]), r.buttons = t, r.buttons = p(r.buttons), r.searchable = !!((l = (s = this.$scopedSlots)["search-form"]) != null && l.call(s)), r;
|
|
265
233
|
},
|
|
266
234
|
treeProps() {
|
|
267
|
-
const
|
|
235
|
+
const e = {
|
|
268
236
|
treeProps: {
|
|
269
237
|
children: "children",
|
|
270
238
|
label: "label",
|
|
271
|
-
isLeaf: (
|
|
272
|
-
if (hasOwn(data, "hasChildren")) {
|
|
273
|
-
return !data.hasChildren;
|
|
274
|
-
} else if (hasOwn(data, "hasChild")) {
|
|
275
|
-
return !data.hasChild;
|
|
276
|
-
} else {
|
|
277
|
-
return true;
|
|
278
|
-
}
|
|
279
|
-
}
|
|
239
|
+
isLeaf: (r) => c(r, "hasChildren") ? !r.hasChildren : c(r, "hasChild") ? !r.hasChild : !0
|
|
280
240
|
},
|
|
281
|
-
show:
|
|
282
|
-
lazy:
|
|
283
|
-
readonly:
|
|
241
|
+
show: !1,
|
|
242
|
+
lazy: !0,
|
|
243
|
+
readonly: !0,
|
|
284
244
|
data: [],
|
|
285
|
-
"expand-first-node":
|
|
286
|
-
"default-expand-all":
|
|
245
|
+
"expand-first-node": !1,
|
|
246
|
+
"default-expand-all": !1
|
|
287
247
|
};
|
|
288
|
-
return
|
|
248
|
+
return i(this.treeAttrs, e);
|
|
289
249
|
},
|
|
290
250
|
tableProps() {
|
|
291
|
-
const
|
|
292
|
-
const defaultProps = {
|
|
251
|
+
const e = this.tableAttrs.api || this.$parent.getPage, r = {
|
|
293
252
|
model: this.searchModel || {},
|
|
294
253
|
height: "auto",
|
|
295
|
-
"highlight-current-row":
|
|
296
|
-
api
|
|
254
|
+
"highlight-current-row": !0,
|
|
255
|
+
api: e
|
|
297
256
|
};
|
|
298
|
-
return
|
|
257
|
+
return i(this.tableAttrs, r);
|
|
299
258
|
},
|
|
300
259
|
searchPanelProps() {
|
|
301
|
-
const
|
|
260
|
+
const e = {
|
|
302
261
|
width: 350,
|
|
303
262
|
model: this.searchModel || {}
|
|
304
263
|
};
|
|
305
|
-
return
|
|
264
|
+
return i(this.searchPanelAttrs, e);
|
|
306
265
|
}
|
|
307
266
|
},
|
|
308
267
|
created() {
|
|
309
|
-
this._viewIds = [];
|
|
310
|
-
if (this.viewId) {
|
|
311
|
-
this._viewIds.push(this.viewId);
|
|
312
|
-
}
|
|
313
|
-
if (!this._viewIds.includes(this.$parent.$options.name)) {
|
|
314
|
-
this._viewIds.push(this.$parent.$options.name);
|
|
315
|
-
}
|
|
268
|
+
this._viewIds = [], this.viewId && this._viewIds.push(this.viewId), this._viewIds.includes(this.$parent.$options.name) || this._viewIds.push(this.$parent.$options.name);
|
|
316
269
|
},
|
|
317
270
|
async activated() {
|
|
318
|
-
|
|
319
|
-
if (this.treeScrollTop) {
|
|
320
|
-
this.$refs.treeScroller.scrollTop = this.treeScrollTop;
|
|
321
|
-
}
|
|
322
|
-
if (this.treeScrollLeft) {
|
|
323
|
-
this.$refs.treeScroller.scrollLeft = this.treeScrollLeft;
|
|
324
|
-
}
|
|
325
|
-
}
|
|
271
|
+
this.$refs.treeScroller && (this.treeScrollTop && (this.$refs.treeScroller.scrollTop = this.treeScrollTop), this.treeScrollLeft && (this.$refs.treeScroller.scrollLeft = this.treeScrollLeft));
|
|
326
272
|
},
|
|
327
273
|
methods: {
|
|
328
274
|
onTreeScroll() {
|
|
329
|
-
this.treeScrollTop = this.$refs.treeScroller.scrollTop;
|
|
330
|
-
this.treeScrollLeft = this.$refs.treeScroller.scrollLeft;
|
|
275
|
+
this.treeScrollTop = this.$refs.treeScroller.scrollTop, this.treeScrollLeft = this.$refs.treeScroller.scrollLeft;
|
|
331
276
|
},
|
|
332
277
|
toggleSearch() {
|
|
333
278
|
this.right = this.right === 0 ? -this.searchPanelProps.width : 0;
|
|
334
279
|
},
|
|
335
280
|
async onSearchClick() {
|
|
336
|
-
this.$refs.table.setModel(this.searchModel || this.searchPanelProps.model);
|
|
337
|
-
await this.refreshTable();
|
|
281
|
+
this.$refs.table.setModel(this.searchModel || this.searchPanelProps.model), await this.refreshTable();
|
|
338
282
|
},
|
|
339
283
|
async onClearClick() {
|
|
340
|
-
this.$emit("reset");
|
|
341
|
-
this.$refs.form.resetFields();
|
|
342
|
-
this.$refs.table.setModel(this.searchModel || this.searchPanelProps.model);
|
|
343
|
-
await this.refreshTable();
|
|
344
|
-
},
|
|
345
|
-
openFrom(row) {
|
|
346
|
-
this.$router.push(fillPath(this.formPath, row));
|
|
347
|
-
},
|
|
348
|
-
rowDbClick(row) {
|
|
349
|
-
var _a;
|
|
350
|
-
if (!((_a = this.tableListeners) == null ? void 0 : _a["row-dblclick"]) && this.formPath) {
|
|
351
|
-
this.openFrom(row);
|
|
352
|
-
}
|
|
284
|
+
this.$emit("reset"), this.$refs.form.resetFields(), this.$refs.table.setModel(this.searchModel || this.searchPanelProps.model), await this.refreshTable();
|
|
353
285
|
},
|
|
354
|
-
|
|
355
|
-
this.
|
|
286
|
+
openFrom(e) {
|
|
287
|
+
this.$router.push(b(this.formPath, e));
|
|
288
|
+
},
|
|
289
|
+
rowDbClick(e) {
|
|
290
|
+
var r;
|
|
291
|
+
!((r = this.tableListeners) != null && r["row-dblclick"]) && this.formPath && this.openFrom(e);
|
|
292
|
+
},
|
|
293
|
+
onSelectionChange(e) {
|
|
294
|
+
this.selectedRows = e;
|
|
356
295
|
},
|
|
357
296
|
create() {
|
|
358
|
-
var
|
|
359
|
-
|
|
360
|
-
this.openFrom();
|
|
361
|
-
}
|
|
297
|
+
var e;
|
|
298
|
+
!((e = this.toolbarListeners) != null && e.create) && this.formPath && this.openFrom();
|
|
362
299
|
},
|
|
363
300
|
async del() {
|
|
364
|
-
var
|
|
365
|
-
const
|
|
366
|
-
if (!((
|
|
301
|
+
var r;
|
|
302
|
+
const e = this.deleteApi || this.$parent.del;
|
|
303
|
+
if (!((r = this.toolbarListeners) != null && r.del) && u(e)) {
|
|
367
304
|
if (!this.selectedRows.length) {
|
|
368
305
|
this.$message.warning("请选择要删除的记录!");
|
|
369
306
|
return;
|
|
@@ -373,34 +310,28 @@ const __vue2_script = {
|
|
|
373
310
|
"系统提示",
|
|
374
311
|
{
|
|
375
312
|
type: "warning",
|
|
376
|
-
modal:
|
|
377
|
-
dangerouslyUseHTMLString:
|
|
378
|
-
closeOnClickModal:
|
|
379
|
-
beforeClose: async (
|
|
380
|
-
if (
|
|
313
|
+
modal: !0,
|
|
314
|
+
dangerouslyUseHTMLString: !0,
|
|
315
|
+
closeOnClickModal: !1,
|
|
316
|
+
beforeClose: async (t, s, l) => {
|
|
317
|
+
if (t === "confirm")
|
|
381
318
|
try {
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
await api.call(this, this.selectedRows.map((value) => value.id).join(","));
|
|
385
|
-
this.$message.success("删除成功");
|
|
386
|
-
await this.reloadTable();
|
|
387
|
-
await this.refreshTree();
|
|
388
|
-
} catch (_) {
|
|
319
|
+
s.confirmButtonLoading = !0, s.confirmButtonText = "删除...", await e.call(this, this.selectedRows.map((a) => a.id).join(",")), this.$message.success("删除成功"), await this.reloadTable(), await this.refreshTree();
|
|
320
|
+
} catch {
|
|
389
321
|
}
|
|
390
|
-
|
|
391
|
-
done();
|
|
322
|
+
l();
|
|
392
323
|
}
|
|
393
324
|
}
|
|
394
|
-
).catch((
|
|
325
|
+
).catch((t) => t);
|
|
395
326
|
}
|
|
396
327
|
},
|
|
397
328
|
reloadTable() {
|
|
398
|
-
var
|
|
399
|
-
(
|
|
329
|
+
var e;
|
|
330
|
+
(e = this.$refs.table) == null || e.reload();
|
|
400
331
|
},
|
|
401
332
|
async refreshTable() {
|
|
402
|
-
var
|
|
403
|
-
await ((
|
|
333
|
+
var e;
|
|
334
|
+
await ((e = this.$refs.table) == null ? void 0 : e.getPage());
|
|
404
335
|
},
|
|
405
336
|
refreshTree() {
|
|
406
337
|
this.$refs.tree.reloadTree();
|
|
@@ -409,26 +340,24 @@ const __vue2_script = {
|
|
|
409
340
|
return this.searchPanelProps.model;
|
|
410
341
|
}
|
|
411
342
|
}
|
|
412
|
-
};
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
__vue2_injectStyles,
|
|
343
|
+
}, h = {};
|
|
344
|
+
var y = /* @__PURE__ */ m(
|
|
345
|
+
v,
|
|
346
|
+
_,
|
|
347
|
+
g,
|
|
348
|
+
!1,
|
|
349
|
+
P,
|
|
420
350
|
null,
|
|
421
351
|
null,
|
|
422
352
|
null
|
|
423
353
|
);
|
|
424
|
-
function
|
|
425
|
-
for (let
|
|
426
|
-
this[
|
|
427
|
-
}
|
|
354
|
+
function P(e) {
|
|
355
|
+
for (let r in h)
|
|
356
|
+
this[r] = h[r];
|
|
428
357
|
}
|
|
429
|
-
const
|
|
430
|
-
return
|
|
358
|
+
const C = /* @__PURE__ */ function() {
|
|
359
|
+
return y.exports;
|
|
431
360
|
}();
|
|
432
361
|
export {
|
|
433
|
-
|
|
362
|
+
C as default
|
|
434
363
|
};
|
|
@@ -1,95 +1 @@
|
|
|
1
|
-
|
|
2
|
-
/* 应用头部高度 */
|
|
3
|
-
/* 页面宽度 */
|
|
4
|
-
/* 侧栏宽度 */
|
|
5
|
-
/* 标签高度 */
|
|
6
|
-
/* 页面头部工具条高度 */
|
|
7
|
-
.table-view {
|
|
8
|
-
display: flex;
|
|
9
|
-
flex-direction: column;
|
|
10
|
-
height: 100%;
|
|
11
|
-
}
|
|
12
|
-
.table-view .el-table--border {
|
|
13
|
-
border: none;
|
|
14
|
-
}
|
|
15
|
-
.table-view .border-top .el-table--border {
|
|
16
|
-
border-top: 1px solid #ebeef5;
|
|
17
|
-
}
|
|
18
|
-
.table-view .border-bottom .el-table--border {
|
|
19
|
-
border-bottom: 1px solid #ebeef5;
|
|
20
|
-
}
|
|
21
|
-
.table-view .border-left .el-table--border, .table-view .border-left .el-pagination {
|
|
22
|
-
border-left: 1px solid #ebeef5;
|
|
23
|
-
}
|
|
24
|
-
.table-view .border-right .el-table--border {
|
|
25
|
-
border-right: 1px solid #ebeef5;
|
|
26
|
-
}
|
|
27
|
-
.table-view .table-view-content-wrapper {
|
|
28
|
-
position: relative;
|
|
29
|
-
flex: 1;
|
|
30
|
-
overflow: hidden;
|
|
31
|
-
}
|
|
32
|
-
.table-view .table-view-content {
|
|
33
|
-
position: absolute;
|
|
34
|
-
top: 0;
|
|
35
|
-
left: 0;
|
|
36
|
-
display: flex;
|
|
37
|
-
width: 100%;
|
|
38
|
-
height: 100%;
|
|
39
|
-
background-color: white;
|
|
40
|
-
}
|
|
41
|
-
.table-view .table-view-sidebar {
|
|
42
|
-
flex-shrink: 0;
|
|
43
|
-
width: 240px;
|
|
44
|
-
height: 100%;
|
|
45
|
-
padding: 10px;
|
|
46
|
-
overflow: auto;
|
|
47
|
-
}
|
|
48
|
-
.table-view .table-view-sidebar .et-tree-wrapper {
|
|
49
|
-
display: table;
|
|
50
|
-
overflow: visible;
|
|
51
|
-
}
|
|
52
|
-
.table-view .table-view-table {
|
|
53
|
-
flex: 1 1 auto;
|
|
54
|
-
height: 100%;
|
|
55
|
-
}
|
|
56
|
-
.table-view .slide-panel {
|
|
57
|
-
position: absolute;
|
|
58
|
-
top: 0;
|
|
59
|
-
right: 0;
|
|
60
|
-
bottom: 0;
|
|
61
|
-
z-index: 5;
|
|
62
|
-
display: flex;
|
|
63
|
-
background-color: white;
|
|
64
|
-
transition: right 200ms ease;
|
|
65
|
-
}
|
|
66
|
-
.table-view .slide-panel .slide-panel-line {
|
|
67
|
-
position: relative;
|
|
68
|
-
width: 3px;
|
|
69
|
-
height: 100%;
|
|
70
|
-
background-color: #ddd;
|
|
71
|
-
flex-shrink: 0;
|
|
72
|
-
}
|
|
73
|
-
.table-view .slide-panel .slide-panel-line-indicator {
|
|
74
|
-
position: absolute;
|
|
75
|
-
top: 50%;
|
|
76
|
-
left: 0;
|
|
77
|
-
width: 100%;
|
|
78
|
-
height: 50px;
|
|
79
|
-
background-color: #aaa;
|
|
80
|
-
transform: translateY(-50%);
|
|
81
|
-
}
|
|
82
|
-
.table-view .slide-panel .slide-panel-actions {
|
|
83
|
-
display: flex;
|
|
84
|
-
align-items: center;
|
|
85
|
-
justify-content: center;
|
|
86
|
-
margin-top: 10px;
|
|
87
|
-
}
|
|
88
|
-
.table-view .slide-panel .slide-panel-content {
|
|
89
|
-
flex: 1;
|
|
90
|
-
padding: 10px;
|
|
91
|
-
overflow: auto;
|
|
92
|
-
}
|
|
93
|
-
.table-view .slide-panel .slide-panel-content .el-date-editor {
|
|
94
|
-
width: 100%;
|
|
95
|
-
}
|
|
1
|
+
.table-view{display:flex;flex-direction:column;height:100%}.table-view .el-table--border{border:none}.table-view .border-top .el-table--border{border-top:1px solid #ebeef5}.table-view .border-bottom .el-table--border{border-bottom:1px solid #ebeef5}.table-view .border-left .el-table--border,.table-view .border-left .el-pagination{border-left:1px solid #ebeef5}.table-view .border-right .el-table--border{border-right:1px solid #ebeef5}.table-view .table-view-content-wrapper{position:relative;flex:1;overflow:hidden}.table-view .table-view-content{position:absolute;top:0;left:0;display:flex;width:100%;height:100%;background-color:#fff}.table-view .table-view-sidebar{flex-shrink:0;width:240px;height:100%;padding:10px;overflow:auto}.table-view .table-view-sidebar .et-tree-wrapper{display:table;overflow:visible}.table-view .table-view-table{flex:1 1 auto;height:100%}.table-view .slide-panel{position:absolute;top:0;right:0;bottom:0;z-index:5;display:flex;background-color:#fff;transition:right .2s ease}.table-view .slide-panel .slide-panel-line{position:relative;width:3px;height:100%;background-color:#ddd;flex-shrink:0}.table-view .slide-panel .slide-panel-line-indicator{position:absolute;top:50%;left:0;width:100%;height:50px;background-color:#aaa;transform:translateY(-50%)}.table-view .slide-panel .slide-panel-actions{display:flex;align-items:center;justify-content:center;margin-top:10px}.table-view .slide-panel .slide-panel-content{flex:1;padding:10px;overflow:auto}.table-view .slide-panel .slide-panel-content .el-date-editor{width:100%}
|