yahee-components 0.0.87 → 0.0.88

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.
Files changed (49) hide show
  1. package/es/annex-upload/annex-upload.vue.js +51 -154
  2. package/es/annex-upload/annex-upload.vue2.js +119 -2
  3. package/es/annex-upload/index.js +3 -3
  4. package/es/border-wrap/border-wrap.vue.js +64 -95
  5. package/es/border-wrap/border-wrap.vue2.js +46 -2
  6. package/es/common-import/common-import.vue.js +369 -666
  7. package/es/common-import/common-import.vue2.js +337 -2
  8. package/es/common-import/index.js +3 -3
  9. package/es/complex-search/complex-search.vue.js +17 -17
  10. package/es/copy/copy.vue.js +37 -55
  11. package/es/copy/copy.vue2.js +34 -2
  12. package/es/copy/index.js +3 -3
  13. package/es/country-platform-shop-condition/country-platform-shop-condition.vue.js +114 -213
  14. package/es/country-platform-shop-condition/country-platform-shop-condition.vue2.js +125 -2
  15. package/es/drop-down-condition/drop-down-condition.vue.js +115 -215
  16. package/es/drop-down-condition/drop-down-condition.vue2.js +127 -2
  17. package/es/echart-gauge/echart-gauge.vue.js +12 -140
  18. package/es/echart-gauge/echart-gauge.vue2.js +147 -2
  19. package/es/echart-gauge/index.js +3 -3
  20. package/es/image-upload/image-upload.vue.js +109 -170
  21. package/es/image-upload/image-upload.vue2.js +91 -2
  22. package/es/image-upload/index.js +3 -3
  23. package/es/input/index.js +3 -3
  24. package/es/input/input.vue.js +17 -38
  25. package/es/input/input.vue2.js +33 -2
  26. package/es/left-condition/index.js +3 -3
  27. package/es/left-condition/left-condition-sub.vue.js +32 -91
  28. package/es/left-condition/left-condition-sub.vue2.js +76 -2
  29. package/es/left-condition/left-condition.vue.js +70 -218
  30. package/es/left-condition/left-condition.vue2.js +160 -2
  31. package/es/left-condition-enum/index.js +3 -3
  32. package/es/left-condition-enum/left-condition-enum.vue.js +20 -49
  33. package/es/left-condition-enum/left-condition-enum.vue2.js +40 -2
  34. package/es/operation-log/operation-log-content.vue.js +71 -92
  35. package/es/operation-log/operation-log-content.vue2.js +39 -2
  36. package/es/operation-log/operation-log-dialog.vue.js +45 -67
  37. package/es/operation-log/operation-log-dialog.vue2.js +38 -2
  38. package/es/operation-log/operation-log-form.vue.js +108 -183
  39. package/es/operation-log/operation-log-form.vue2.js +104 -2
  40. package/es/operation-log/operation-log.vue.js +119 -228
  41. package/es/operation-log/operation-log.vue2.js +135 -2
  42. package/es/packages/components/api/log-server.js +6 -6
  43. package/es/packages/components/api/upload-server.js +1 -1
  44. package/es/packages/components/hooks/useEcharts.js +19 -19
  45. package/es/packages/components/hooks/useImg.js +8 -8
  46. package/es/scale-screen/index.js +4 -4
  47. package/es/scale-screen/scale-screen.vue.js +19 -126
  48. package/es/scale-screen/scale-screen.vue2.js +125 -2
  49. package/package.json +1 -1
@@ -1,219 +1,120 @@
1
- import { defineComponent as A, toRefs as I, reactive as z, ref as G, watch as ee, createElementBlock as f, openBlock as s, createVNode as E, unref as c, withCtx as V, createElementVNode as i, normalizeStyle as b, Fragment as g, renderList as C, toDisplayString as k, createBlock as D, createTextVNode as L } from "vue";
2
- import { stylesUtils as le } from "../utils/style.js";
3
- import { M2 as N } from "../utils/translate.js";
4
- import R from "../_virtual/lodash.js";
5
- import { ElPopover as oe, ElCheckboxGroup as te, ElCheckbox as ue, ElButton as U } from "element-plus";
6
- import "element-plus/theme-chalk/src/base.scss";
7
- import "element-plus/theme-chalk/src/button.scss";
8
- import "element-plus/theme-chalk/src/checkbox.scss";
9
- import "element-plus/theme-chalk/src/checkbox-group.scss";
10
- import "element-plus/theme-chalk/src/popper.scss";
11
- import "element-plus/theme-chalk/src/popover.scss";
12
- const ae = { class: "yahee-country-platform-shop-condition" }, re = { class: "popover-table" }, ne = { id: "all" }, se = ["onClick"], ce = { id: "y" }, ie = ["onClick"], pe = { style: { display: "flex", "align-items": "center", outline: "none" } }, ke = /* @__PURE__ */ A({
13
- name: "YaheeCountryPlatformShopCondition",
14
- __name: "country-platform-shop-condition",
15
- props: {
16
- xyFilters: {},
17
- filterKey: {}
18
- },
19
- emits: ["filterChange"],
20
- setup(H, { emit: P }) {
21
- const q = H, { filterKey: M, xyFilters: r } = I(q), Y = P, u = z({});
22
- let w = z({});
23
- const m = G({}), _ = G({}), y = G(!0), x = G({}), S = G({}), K = G();
24
- r.value && (K.value = [...r.value.xGroup]);
25
- function J(o, a) {
26
- var e;
27
- return (e = r.value) == null ? void 0 : e.items.filter((l) => l.xGroupValue === o && l.yGroupValue === a);
28
- }
29
- function F(o) {
30
- var e;
31
- const a = o.xGroupValue;
32
- if (x.value[a]) {
33
- for (const l in u)
34
- l.startsWith(a) && delete u[l];
35
- x.value[a] = !1;
36
- } else {
37
- for (const l of (e = r.value) == null ? void 0 : e.items)
38
- if (l.xGroupValue === a) {
39
- let t = u[`${l.xGroupValue}-${l.yGroupValue}`];
40
- t ? (t.push(l.value), t = [...new Set(t)]) : t = [l.value], u[`${l.xGroupValue}-${l.yGroupValue}`] = t;
41
- }
42
- x.value[a] = !0;
43
- }
44
- }
45
- const T = (o) => le.getBackgroundColor(o), Q = () => {
46
- R.isEqual(w, u) || Y("filterChange", [
47
- {
48
- filterKey: M.value,
49
- checkedValues: Object.values(Object.values(u)).flat()
50
- }
51
- ]);
52
- }, X = () => {
53
- w = R.cloneDeep(u);
54
- };
55
- function j() {
56
- if (y.value)
57
- y.value = !1, Object.keys(u).forEach((o) => {
58
- delete u[o];
59
- });
60
- else {
61
- y.value = !0;
62
- for (const o of r.value.items) {
63
- let a = u[`${o.xGroupValue}-${o.yGroupValue}`];
64
- a ? a.push(o.value) : a = [o.value], u[`${o.xGroupValue}-${o.yGroupValue}`] = a;
65
- }
66
- }
67
- console.log(u);
68
- }
69
- function Z(o) {
70
- const a = o.yGroupValue;
71
- if (S.value[a]) {
72
- for (const e in u)
73
- e.endsWith(a) && delete u[e];
74
- S.value[a] = !1;
75
- } else {
76
- for (const e of r.value.items)
77
- if (e.yGroupValue === a) {
78
- let l = u[`${e.xGroupValue}-${e.yGroupValue}`];
79
- l ? (l.push(e.value), l = [...new Set(l)]) : l = [e.value], u[`${e.xGroupValue}-${e.yGroupValue}`] = l;
80
- }
81
- S.value[a] = !0;
82
- }
83
- }
84
- return ee(
85
- u,
86
- (o, a) => {
87
- var p, B, O, W;
88
- Object.keys(o).forEach((n) => {
89
- Array.isArray(o[n]) && o[n].length === 0 && delete o[n];
90
- }), console.log("新的数组:", o), console.log("旧的数组:", a);
91
- const e = { backgroundColor: "#3366CC", color: "#fff", borderColor: "#3366CC" }, l = { backgroundColor: "#00bfff", borderColor: "#00bfff" }, t = {}, h = (p = r.value) == null ? void 0 : p.xGroup.length, v = (B = r.value) == null ? void 0 : B.yGroup.length;
92
- (O = r.value) == null || O.xGroup.forEach((n) => {
93
- let d = 0;
94
- for (const $ in u)
95
- $.startsWith(n.xGroupValue) && d++;
96
- d === 0 ? m.value[n.xGroupValue] = t : d === v ? m.value[n.xGroupValue] = e : m.value[n.xGroupValue] = l;
97
- }), (W = r.value) == null || W.yGroup.forEach((n) => {
98
- let d = 0;
99
- for (const $ in u)
100
- $.endsWith(n.yGroupValue) && d++;
101
- d === 0 ? _.value[n.yGroupValue] = t : d === h ? _.value[n.yGroupValue] = e : _.value[n.yGroupValue] = l;
102
- }), y.value = Object.keys(o).length === h * v;
103
- },
104
- { deep: !0 }
105
- ), (o, a) => (s(), f("div", ae, [
106
- E(c(oe), {
107
- placement: "bottom",
108
- trigger: "hover",
109
- width: "'auto'",
110
- "popper-class": "custom-popover",
111
- onHide: Q,
112
- onShow: X
113
- }, {
114
- reference: V(() => [
115
- i("div", pe, [
116
- E(c(U), {
117
- size: "small",
118
- class: "el-button custom-total-button",
119
- style: b(T(y.value)),
120
- onClick: j
121
- }, {
122
- default: V(() => [
123
- L(k(c(N)("全部")), 1)
124
- ]),
125
- _: 1
126
- }, 8, ["style"]),
127
- (s(!0), f(g, null, C(K.value, (e) => (s(), D(c(U), {
128
- key: e,
129
- style: b(m.value[e.xGroupValue]),
130
- class: "custom-button",
131
- onClick: (l) => F(e)
132
- }, {
133
- default: V(() => [
134
- L(k(c(N)(e.xGroupText)), 1)
135
- ]),
136
- _: 2
137
- }, 1032, ["style", "onClick"]))), 128))
138
- ])
139
- ]),
140
- default: V(() => {
141
- var e, l;
142
- return [
143
- i("table", re, [
144
- i("thead", null, [
145
- i("tr", null, [
146
- i("th", ne, [
147
- i("span", {
148
- style: b(T(y.value)),
149
- class: "el-button el-button--small custom-button",
150
- onClick: j
151
- }, " 全部 ", 4)
1
+ import f from "./country-platform-shop-condition.vue2.js";
2
+ import { createElementBlock as n, openBlock as o, createVNode as p, withCtx as c, createElementVNode as t, normalizeStyle as d, Fragment as i, renderList as s, toDisplayString as y, createBlock as m, createTextVNode as b } from "vue";
3
+ import k from "../_virtual/_plugin-vue_export-helper.js";
4
+ const G = { class: "yahee-country-platform-shop-condition" }, V = { class: "popover-table" }, S = { id: "all" }, C = ["onClick"], g = { id: "y" }, v = ["onClick"], w = { style: { display: "flex", "align-items": "center", outline: "none" } };
5
+ function x(E, T, B, l, F, L) {
6
+ return o(), n("div", G, [
7
+ p(l.ElPopover, {
8
+ placement: "bottom",
9
+ trigger: "hover",
10
+ width: "'auto'",
11
+ "popper-class": "custom-popover",
12
+ onHide: l.handleHide,
13
+ onShow: l.handleShow
14
+ }, {
15
+ reference: c(() => [
16
+ t("div", w, [
17
+ p(l.ElButton, {
18
+ size: "small",
19
+ class: "el-button custom-total-button",
20
+ style: d(l.getDefaultSelectedAllStyle(l.isSelectedAll)),
21
+ onClick: l.selectAll
22
+ }, {
23
+ default: c(() => [
24
+ b(y(l.M2("全部")), 1)
25
+ ]),
26
+ _: 1
27
+ }, 8, ["style"]),
28
+ (o(!0), n(i, null, s(l.selectList, (r) => (o(), m(l.ElButton, {
29
+ key: r,
30
+ style: d(l.rowTitleStyle[r.xGroupValue]),
31
+ class: "custom-button",
32
+ onClick: (h) => l.toggleRowSelection(r)
33
+ }, {
34
+ default: c(() => [
35
+ b(y(l.M2(r.xGroupText)), 1)
36
+ ]),
37
+ _: 2
38
+ }, 1032, ["style", "onClick"]))), 128))
39
+ ])
40
+ ]),
41
+ default: c(() => {
42
+ var r, h;
43
+ return [
44
+ t("table", V, [
45
+ t("thead", null, [
46
+ t("tr", null, [
47
+ t("th", S, [
48
+ t("span", {
49
+ style: d(l.getDefaultSelectedAllStyle(l.isSelectedAll)),
50
+ class: "el-button el-button--small custom-button",
51
+ onClick: l.selectAll
52
+ }, " 全部 ", 4)
53
+ ]),
54
+ (o(!0), n(i, null, s((r = l.xyFilters) == null ? void 0 : r.xGroup, (e) => (o(), n("th", {
55
+ id: "x",
56
+ key: e.xGroupValue
57
+ }, [
58
+ t("span", {
59
+ style: d({ ...l.rowTitleStyle[e.xGroupValue], width: "100%" }),
60
+ class: "el-button--small el-button custom-button",
61
+ onClick: (_) => l.toggleRowSelection(e)
62
+ }, y(e.xGroupText), 13, C)
63
+ ]))), 128))
64
+ ])
65
+ ]),
66
+ t("tbody", null, [
67
+ (o(!0), n(i, null, s((h = l.xyFilters) == null ? void 0 : h.yGroup, (e) => {
68
+ var _;
69
+ return o(), n("tr", {
70
+ key: e.yGroupValue
71
+ }, [
72
+ t("th", g, [
73
+ t("span", {
74
+ style: d({ ...l.columnTitleStyle[e.yGroupValue], width: "100%" }),
75
+ class: "el-button--small el-button custom-button",
76
+ onClick: (u) => l.toggleColumnSelection(e)
77
+ }, y(e.yGroupText), 13, v)
152
78
  ]),
153
- (s(!0), f(g, null, C((e = c(r)) == null ? void 0 : e.xGroup, (t) => (s(), f("th", {
154
- id: "x",
155
- key: t.xGroupValue
79
+ (o(!0), n(i, null, s((_ = l.xyFilters) == null ? void 0 : _.xGroup, (u) => (o(), n("td", {
80
+ key: u.xGroupValue
156
81
  }, [
157
- i("span", {
158
- style: b({ ...m.value[t.xGroupValue], width: "100%" }),
159
- class: "el-button--small el-button custom-button",
160
- onClick: (h) => F(t)
161
- }, k(t.xGroupText), 13, se)
82
+ p(l.ElCheckboxGroup, {
83
+ modelValue: l.checkList[u.xGroupValue + "-" + e.yGroupValue],
84
+ "onUpdate:modelValue": (a) => l.checkList[u.xGroupValue + "-" + e.yGroupValue] = a
85
+ }, {
86
+ default: c(() => [
87
+ (o(!0), n(i, null, s(l.getContentForCell(
88
+ u.xGroupValue,
89
+ e.yGroupValue
90
+ ), (a) => (o(), m(l.ElCheckbox, {
91
+ key: a.value,
92
+ border: "",
93
+ class: "el-button el-button-small custom-button",
94
+ label: a.text,
95
+ value: a.value,
96
+ size: "small"
97
+ }, {
98
+ default: c(() => [
99
+ b(y(a.text), 1)
100
+ ]),
101
+ _: 2
102
+ }, 1032, ["label", "value"]))), 128))
103
+ ]),
104
+ _: 2
105
+ }, 1032, ["modelValue", "onUpdate:modelValue"])
162
106
  ]))), 128))
163
- ])
164
- ]),
165
- i("tbody", null, [
166
- (s(!0), f(g, null, C((l = c(r)) == null ? void 0 : l.yGroup, (t) => {
167
- var h;
168
- return s(), f("tr", {
169
- key: t.yGroupValue
170
- }, [
171
- i("th", ce, [
172
- i("span", {
173
- style: b({ ..._.value[t.yGroupValue], width: "100%" }),
174
- class: "el-button--small el-button custom-button",
175
- onClick: (v) => Z(t)
176
- }, k(t.yGroupText), 13, ie)
177
- ]),
178
- (s(!0), f(g, null, C((h = c(r)) == null ? void 0 : h.xGroup, (v) => (s(), f("td", {
179
- key: v.xGroupValue
180
- }, [
181
- E(c(te), {
182
- modelValue: u[v.xGroupValue + "-" + t.yGroupValue],
183
- "onUpdate:modelValue": (p) => u[v.xGroupValue + "-" + t.yGroupValue] = p
184
- }, {
185
- default: V(() => [
186
- (s(!0), f(g, null, C(J(
187
- v.xGroupValue,
188
- t.yGroupValue
189
- ), (p) => (s(), D(c(ue), {
190
- key: p.value,
191
- border: "",
192
- class: "el-button el-button-small custom-button",
193
- label: p.text,
194
- value: p.value,
195
- size: "small"
196
- }, {
197
- default: V(() => [
198
- L(k(p.text), 1)
199
- ]),
200
- _: 2
201
- }, 1032, ["label", "value"]))), 128))
202
- ]),
203
- _: 2
204
- }, 1032, ["modelValue", "onUpdate:modelValue"])
205
- ]))), 128))
206
- ]);
207
- }), 128))
208
- ])
107
+ ]);
108
+ }), 128))
209
109
  ])
210
- ];
211
- }),
212
- _: 1
213
- })
214
- ]));
215
- }
216
- });
110
+ ])
111
+ ];
112
+ }),
113
+ _: 1
114
+ })
115
+ ]);
116
+ }
117
+ const H = /* @__PURE__ */ k(f, [["render", x], ["__file", "E:/工作/项目代码/common_componentsweb/packages/components/src/country-platform-shop-condition/country-platform-shop-condition.vue"]]);
217
118
  export {
218
- ke as default
119
+ H as default
219
120
  };
@@ -1,4 +1,127 @@
1
- import f from "./country-platform-shop-condition.vue.js";
1
+ import { defineComponent as R, toRefs as D, reactive as _, ref as c, watch as M } from "vue";
2
+ import { stylesUtils as T } from "../utils/style.js";
3
+ import { M2 as H } from "../utils/translate.js";
4
+ import L from "../_virtual/lodash.js";
5
+ import { ElPopover as U, ElCheckboxGroup as Y, ElCheckbox as z, ElButton as I } from "element-plus";
6
+ import "element-plus/theme-chalk/src/base.scss";
7
+ import "element-plus/theme-chalk/src/button.scss";
8
+ import "element-plus/theme-chalk/src/checkbox.scss";
9
+ import "element-plus/theme-chalk/src/checkbox-group.scss";
10
+ import "element-plus/theme-chalk/src/popper.scss";
11
+ import "element-plus/theme-chalk/src/popover.scss";
12
+ const ae = /* @__PURE__ */ R({
13
+ name: "YaheeCountryPlatformShopCondition",
14
+ __name: "country-platform-shop-condition",
15
+ props: {
16
+ xyFilters: { type: Object, required: !1 },
17
+ filterKey: { type: String, required: !0 }
18
+ },
19
+ emits: ["filterChange"],
20
+ setup(j, { expose: K, emit: O }) {
21
+ K();
22
+ const G = j, { filterKey: m, xyFilters: a } = D(G), d = O, t = _({});
23
+ let f = _({});
24
+ const p = c({}), v = c({}), i = c(!0), y = c({}), h = c({}), x = c();
25
+ a.value && (x.value = [...a.value.xGroup]);
26
+ function A(e, o) {
27
+ var u;
28
+ return (u = a.value) == null ? void 0 : u.items.filter((l) => l.xGroupValue === e && l.yGroupValue === o);
29
+ }
30
+ function F(e) {
31
+ var u;
32
+ const o = e.xGroupValue;
33
+ if (y.value[o]) {
34
+ for (const l in t)
35
+ l.startsWith(o) && delete t[l];
36
+ y.value[o] = !1;
37
+ } else {
38
+ for (const l of (u = a.value) == null ? void 0 : u.items)
39
+ if (l.xGroupValue === o) {
40
+ let n = t[`${l.xGroupValue}-${l.yGroupValue}`];
41
+ n ? (n.push(l.value), n = [...new Set(n)]) : n = [l.value], t[`${l.xGroupValue}-${l.yGroupValue}`] = n;
42
+ }
43
+ y.value[o] = !0;
44
+ }
45
+ }
46
+ const P = (e) => T.getBackgroundColor(e), W = () => {
47
+ L.isEqual(f, t) || d("filterChange", [
48
+ {
49
+ filterKey: m.value,
50
+ checkedValues: Object.values(Object.values(t)).flat()
51
+ }
52
+ ]);
53
+ }, q = () => {
54
+ f = L.cloneDeep(t);
55
+ };
56
+ function w() {
57
+ if (i.value)
58
+ i.value = !1, Object.keys(t).forEach((e) => {
59
+ delete t[e];
60
+ });
61
+ else {
62
+ i.value = !0;
63
+ for (const e of a.value.items) {
64
+ let o = t[`${e.xGroupValue}-${e.yGroupValue}`];
65
+ o ? o.push(e.value) : o = [e.value], t[`${e.xGroupValue}-${e.yGroupValue}`] = o;
66
+ }
67
+ }
68
+ console.log(t);
69
+ }
70
+ function B(e) {
71
+ const o = e.yGroupValue;
72
+ if (h.value[o]) {
73
+ for (const u in t)
74
+ u.endsWith(o) && delete t[u];
75
+ h.value[o] = !1;
76
+ } else {
77
+ for (const u of a.value.items)
78
+ if (u.yGroupValue === o) {
79
+ let l = t[`${u.xGroupValue}-${u.yGroupValue}`];
80
+ l ? (l.push(u.value), l = [...new Set(l)]) : l = [u.value], t[`${u.xGroupValue}-${u.yGroupValue}`] = l;
81
+ }
82
+ h.value[o] = !0;
83
+ }
84
+ }
85
+ M(
86
+ t,
87
+ (e, o) => {
88
+ var S, k, E, $;
89
+ Object.keys(e).forEach((r) => {
90
+ Array.isArray(e[r]) && e[r].length === 0 && delete e[r];
91
+ }), console.log("新的数组:", e), console.log("旧的数组:", o);
92
+ const u = { backgroundColor: "#3366CC", color: "#fff", borderColor: "#3366CC" }, l = { backgroundColor: "#00bfff", borderColor: "#00bfff" }, n = {}, V = (S = a.value) == null ? void 0 : S.xGroup.length, b = (k = a.value) == null ? void 0 : k.yGroup.length;
93
+ (E = a.value) == null || E.xGroup.forEach((r) => {
94
+ let s = 0;
95
+ for (const g in t)
96
+ g.startsWith(r.xGroupValue) && s++;
97
+ s === 0 ? p.value[r.xGroupValue] = n : s === b ? p.value[r.xGroupValue] = u : p.value[r.xGroupValue] = l;
98
+ }), ($ = a.value) == null || $.yGroup.forEach((r) => {
99
+ let s = 0;
100
+ for (const g in t)
101
+ g.endsWith(r.yGroupValue) && s++;
102
+ s === 0 ? v.value[r.yGroupValue] = n : s === V ? v.value[r.yGroupValue] = u : v.value[r.yGroupValue] = l;
103
+ }), i.value = Object.keys(e).length === V * b;
104
+ },
105
+ { deep: !0 }
106
+ );
107
+ const C = { props: G, filterKey: m, xyFilters: a, emit: d, checkList: t, get backupCheckList() {
108
+ return f;
109
+ }, set backupCheckList(e) {
110
+ f = e;
111
+ }, rowTitleStyle: p, columnTitleStyle: v, isSelectedAll: i, toggleRowSelectionFlags: y, toggleColumnSelectionFlags: h, selectList: x, getContentForCell: A, toggleRowSelection: F, getDefaultSelectedAllStyle: P, handleHide: W, handleShow: q, selectAll: w, toggleColumnSelection: B, get M2() {
112
+ return H;
113
+ }, get ElButton() {
114
+ return I;
115
+ }, get ElCheckbox() {
116
+ return z;
117
+ }, get ElCheckboxGroup() {
118
+ return Y;
119
+ }, get ElPopover() {
120
+ return U;
121
+ } };
122
+ return Object.defineProperty(C, "__isScriptSetup", { enumerable: !1, value: !0 }), C;
123
+ }
124
+ });
2
125
  export {
3
- f as default
126
+ ae as default
4
127
  };