@dazhicheng/ui 1.5.247 → 1.5.248
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/components/tt-area/TtArea.vue.js +1 -1
- package/dist/components/tt-drawer/src/components/DrawerHeader.vue.js +2 -2
- package/dist/components/tt-icon/index.vue.js +2 -2
- package/dist/components/tt-loading/src/loading.vue.js +2 -2
- package/dist/components/tt-select/src/Select.vue.d.ts +4 -4
- package/dist/components/tt-select/src/components/Table.vue.d.ts +4 -4
- package/dist/components/tt-table/index.d.ts +12 -12
- package/dist/components/tt-table/src/Table.vue.d.ts +4 -4
- package/dist/components/tt-table/src/TableForm.vue.d.ts +4 -8
- package/dist/components/tt-table/src/TableForm.vue.js +180 -185
- package/dist/components/tt-table/src/components/TableColumnModal.vue.d.ts +6 -8
- package/dist/components/tt-table/src/components/TableColumnModal.vue2.js +156 -183
- package/dist/hooks/useFormSchemasLink.js +14 -15
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import { TtIcon as
|
|
5
|
-
import { TtText as
|
|
1
|
+
import { defineComponent as Q, ref as x, computed as b, createBlock as F, openBlock as f, unref as e, normalizeClass as a, createSlots as W, withCtx as s, createElementVNode as c, createVNode as r, createTextVNode as h, toDisplayString as $, createElementBlock as C, Fragment as w, renderList as T, createCommentVNode as X, withModifiers as Y, renderSlot as V } from "vue";
|
|
2
|
+
import Z from "../../../../assets/svg/close.svg.js";
|
|
3
|
+
import ee from "../../../../assets/svg/drag.svg.js";
|
|
4
|
+
import { TtIcon as P } from "../../../tt-icon/index.js";
|
|
5
|
+
import { TtText as le } from "../../../tt-text/index.js";
|
|
6
6
|
import "../../../tt-modal/index.js";
|
|
7
|
-
import { TtButton as
|
|
7
|
+
import { TtButton as te } from "../../../tt-button/index.js";
|
|
8
8
|
import "../../../../node_modules/.pnpm/vue-types@5.1.3_vue@3.5.21_typescript@5.9.3_/node_modules/vue-types/shim/index.modern.js";
|
|
9
|
-
import { useDesign as
|
|
9
|
+
import { useDesign as oe } from "../../../../packages/hooks/src/useDesign.js";
|
|
10
10
|
import "axios";
|
|
11
|
-
import { ElScrollbar as
|
|
11
|
+
import { ElScrollbar as B, ElCheckbox as N, ElCheckboxGroup as ne, ElTooltip as ie } from "element-plus";
|
|
12
12
|
import "dayjs";
|
|
13
13
|
import "xe-utils";
|
|
14
14
|
import "dayjs/plugin/utc";
|
|
@@ -18,231 +18,204 @@ import "../../../../node_modules/.pnpm/crypto-js@4.2.0/node_modules/crypto-js/ae
|
|
|
18
18
|
import "../../../../node_modules/.pnpm/crypto-js@4.2.0/node_modules/crypto-js/enc-utf8.js";
|
|
19
19
|
import "../../../../node_modules/.pnpm/crypto-js@4.2.0/node_modules/crypto-js/mode-ecb.js";
|
|
20
20
|
import "../../../../node_modules/.pnpm/crypto-js@4.2.0/node_modules/crypto-js/pad-pkcs7.js";
|
|
21
|
-
import
|
|
22
|
-
import
|
|
23
|
-
import { useModalRender as
|
|
24
|
-
const
|
|
21
|
+
import "lodash-es";
|
|
22
|
+
import ae from "sortablejs";
|
|
23
|
+
import { useModalRender as se } from "../../../tt-modal/src/hooks/useModalRender.js";
|
|
24
|
+
const re = ["aria-label", "onClick"], Pe = /* @__PURE__ */ Q({
|
|
25
25
|
__name: "TableColumnModal",
|
|
26
26
|
props: {
|
|
27
27
|
openColumn: { type: Function },
|
|
28
28
|
openExport: { type: Function }
|
|
29
29
|
},
|
|
30
30
|
emits: ["on-submit"],
|
|
31
|
-
setup(
|
|
32
|
-
const
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
const p = C(() => l.allColumns.filter((e) => e.field)), O = C(() => p.value.filter((e) => !e.disabled)), P = C(() => {
|
|
40
|
-
const e = O.value.length;
|
|
41
|
-
return e === 0 ? !0 : l.checkedFields.filter((t) => !l.disabledColumnField.includes(t)).length === e;
|
|
42
|
-
}), q = C(() => {
|
|
43
|
-
const e = [.../* @__PURE__ */ new Set([...l.checkedFields, ...l.disabledColumnField])];
|
|
44
|
-
return e.length > 0 && e.length < p.value.length;
|
|
45
|
-
});
|
|
46
|
-
function G(e) {
|
|
47
|
-
const o = p.value;
|
|
48
|
-
l.checkedFields = e ? o.map((t) => t.field) : o.filter((t) => l.disabledColumnField.includes(t.field)).map((t) => t.field);
|
|
31
|
+
setup(z, { expose: A, emit: I }) {
|
|
32
|
+
const m = z, D = I, { prefixCls: i } = oe("table-column-modal"), [L, g] = se(), u = x([]), n = x([]), y = x(!1);
|
|
33
|
+
let p = null;
|
|
34
|
+
const E = b(
|
|
35
|
+
() => n.value.map((t) => u.value.find((l) => l.field === t)).filter(Boolean)
|
|
36
|
+
), R = b(() => u.value.filter((t) => !t.locked)), G = b(() => n.value.filter((t) => !M(t))), S = b(() => G.value.length === R.value.length), O = b(() => n.value.length > 0 && !S.value);
|
|
37
|
+
function M(t) {
|
|
38
|
+
return u.value.some((l) => l.field === t && l.locked);
|
|
49
39
|
}
|
|
50
|
-
function
|
|
51
|
-
|
|
40
|
+
function U(t) {
|
|
41
|
+
n.value = u.value.filter((l) => l.locked ? n.value.includes(l.field) : !!t).map((l) => l.field);
|
|
52
42
|
}
|
|
53
|
-
function
|
|
54
|
-
|
|
43
|
+
function j(t) {
|
|
44
|
+
n.value = n.value.filter((l) => l !== t);
|
|
55
45
|
}
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
46
|
+
function q() {
|
|
47
|
+
n.value = n.value.filter(M);
|
|
48
|
+
}
|
|
49
|
+
function _() {
|
|
50
|
+
D("on-submit", {
|
|
51
|
+
checkedModel: [...n.value],
|
|
52
|
+
modalApi: g,
|
|
53
|
+
isExport: y.value
|
|
61
54
|
});
|
|
62
|
-
};
|
|
63
|
-
function H({ columns: e, displayFields: o = [], disabledColumnField: t, isExport: n }) {
|
|
64
|
-
k.value = n ?? !1, x.openModal();
|
|
65
|
-
const Q = re(e).filter((i) => i.field);
|
|
66
|
-
l.disabledColumnField = t, l.allColumns = Q.map((i) => ({ ...i, disabled: t.includes(i.field) }));
|
|
67
|
-
const W = new Set(l.allColumns.map((i) => i.field)), w = o.filter((i) => i && W.has(i));
|
|
68
|
-
l.checkedFields = [...w], l.selectedColumns = w.map((i) => l.allColumns.find((X) => X.field === i)).filter(Boolean), g = setTimeout(J, 100);
|
|
69
55
|
}
|
|
70
|
-
function
|
|
71
|
-
|
|
72
|
-
const
|
|
73
|
-
|
|
56
|
+
function H({ columns: t, displayFields: l = [], disabledColumnField: o, isExport: v }) {
|
|
57
|
+
y.value = v ?? !1, u.value = t.filter((d) => d.field).map((d) => ({ ...d, locked: o.includes(d.field) }));
|
|
58
|
+
const k = new Set(u.value.map((d) => d.field));
|
|
59
|
+
n.value = [...new Set(l.filter((d) => k.has(d)))], g.openModal();
|
|
60
|
+
}
|
|
61
|
+
function J(t) {
|
|
62
|
+
p == null || p.destroy(), p = null, t && (p = ae.create(t, {
|
|
74
63
|
animation: 300,
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
64
|
+
onStart: (l) => l.item.style.opacity = "0",
|
|
65
|
+
onEnd(l) {
|
|
66
|
+
l.item.style.opacity = "1";
|
|
67
|
+
const { oldIndex: o, newIndex: v } = l;
|
|
68
|
+
if (o == null || v == null) return;
|
|
69
|
+
const k = [...n.value];
|
|
70
|
+
k.splice(v, 0, ...k.splice(o, 1)), n.value = k;
|
|
81
71
|
}
|
|
82
72
|
}));
|
|
83
73
|
}
|
|
84
|
-
T(
|
|
85
|
-
() => l.checkedFields,
|
|
86
|
-
(e) => {
|
|
87
|
-
const o = new Set(e);
|
|
88
|
-
l.selectedColumns = l.selectedColumns.filter((n) => o.has(n.field || ""));
|
|
89
|
-
const t = new Set(l.selectedColumns.map((n) => n.field || ""));
|
|
90
|
-
l.selectedColumns.push(
|
|
91
|
-
...l.allColumns.filter((n) => o.has(n.field || "") && !t.has(n.field || ""))
|
|
92
|
-
);
|
|
93
|
-
},
|
|
94
|
-
{ deep: !0 }
|
|
95
|
-
), T(
|
|
96
|
-
() => {
|
|
97
|
-
var e;
|
|
98
|
-
return (e = x.getVisible) == null ? void 0 : e.value;
|
|
99
|
-
},
|
|
100
|
-
(e) => {
|
|
101
|
-
e || (g && clearTimeout(g), f == null || f.destroy(), f = null, Object.assign(l, { allColumns: [], checkedFields: [], selectedColumns: [] }));
|
|
102
|
-
}
|
|
103
|
-
);
|
|
104
74
|
function K() {
|
|
105
|
-
var
|
|
106
|
-
|
|
75
|
+
var t, l;
|
|
76
|
+
y.value ? (t = m.openExport) == null || t.call(m, !0) : (l = m.openColumn) == null || l.call(m, !0);
|
|
107
77
|
}
|
|
108
|
-
return
|
|
109
|
-
handleSubmit:
|
|
78
|
+
return A({
|
|
79
|
+
handleSubmit: _,
|
|
110
80
|
openModal: H,
|
|
111
|
-
setModalProps(
|
|
112
|
-
|
|
81
|
+
setModalProps(t) {
|
|
82
|
+
g.setModalProps(t);
|
|
113
83
|
}
|
|
114
|
-
}), (
|
|
84
|
+
}), (t, l) => (f(), F(e(L), {
|
|
115
85
|
width: "720",
|
|
116
|
-
class:
|
|
117
|
-
onOk:
|
|
118
|
-
},
|
|
119
|
-
beforeFooter:
|
|
120
|
-
c("div",
|
|
121
|
-
a(
|
|
122
|
-
|
|
123
|
-
|
|
86
|
+
class: a(e(i)),
|
|
87
|
+
onOk: _
|
|
88
|
+
}, W({
|
|
89
|
+
beforeFooter: s(() => [
|
|
90
|
+
c("div", {
|
|
91
|
+
class: a(`${e(i)}-footer-left`)
|
|
92
|
+
}, [
|
|
93
|
+
r(e(te), { onClick: K }, {
|
|
94
|
+
default: s(() => [...l[1] || (l[1] = [
|
|
95
|
+
h("重置", -1)
|
|
124
96
|
])]),
|
|
125
97
|
_: 1
|
|
126
98
|
}),
|
|
127
|
-
V(
|
|
128
|
-
])
|
|
99
|
+
V(t.$slots, "beforeFooter")
|
|
100
|
+
], 2)
|
|
129
101
|
]),
|
|
130
|
-
default:
|
|
102
|
+
default: s(() => [
|
|
131
103
|
c("div", {
|
|
132
|
-
|
|
133
|
-
ref: _,
|
|
134
|
-
class: "flex h-[400px]"
|
|
104
|
+
class: a(`${e(i)}-body`)
|
|
135
105
|
}, [
|
|
136
|
-
|
|
137
|
-
a(
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
106
|
+
r(e(B), {
|
|
107
|
+
class: a(`${e(i)}-source`)
|
|
108
|
+
}, {
|
|
109
|
+
default: s(() => [
|
|
110
|
+
r(e(N), {
|
|
111
|
+
class: a(`${e(i)}-all`),
|
|
112
|
+
"model-value": S.value,
|
|
113
|
+
indeterminate: O.value,
|
|
114
|
+
onChange: U
|
|
115
|
+
}, {
|
|
116
|
+
default: s(() => [
|
|
117
|
+
h(" 全部(" + $(n.value.length) + "/" + $(u.value.length) + ") ", 1)
|
|
118
|
+
]),
|
|
119
|
+
_: 1
|
|
120
|
+
}, 8, ["class", "model-value", "indeterminate"]),
|
|
121
|
+
r(e(ne), {
|
|
122
|
+
modelValue: n.value,
|
|
123
|
+
"onUpdate:modelValue": l[0] || (l[0] = (o) => n.value = o),
|
|
124
|
+
class: a(`${e(i)}-group`)
|
|
125
|
+
}, {
|
|
126
|
+
default: s(() => [
|
|
127
|
+
(f(!0), C(w, null, T(u.value, (o) => (f(), F(e(N), {
|
|
128
|
+
key: o.field,
|
|
129
|
+
value: o.field,
|
|
130
|
+
disabled: o.locked
|
|
145
131
|
}, {
|
|
146
|
-
default:
|
|
147
|
-
|
|
132
|
+
default: s(() => [
|
|
133
|
+
r(e(ie), {
|
|
134
|
+
content: o.title || "",
|
|
135
|
+
"show-after": 400,
|
|
136
|
+
placement: "top"
|
|
137
|
+
}, {
|
|
138
|
+
default: s(() => [
|
|
139
|
+
h($(o.title || ""), 1)
|
|
140
|
+
]),
|
|
141
|
+
_: 2
|
|
142
|
+
}, 1032, ["content"])
|
|
148
143
|
]),
|
|
149
|
-
_:
|
|
150
|
-
},
|
|
144
|
+
_: 2
|
|
145
|
+
}, 1032, ["value", "disabled"]))), 128))
|
|
151
146
|
]),
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
"onUpdate:modelValue": o[0] || (o[0] = (t) => l.checkedFields = t),
|
|
155
|
-
class: "mb-10px w-full"
|
|
156
|
-
}, {
|
|
157
|
-
default: d(() => [
|
|
158
|
-
(m(!0), v(M, null, $(p.value, (t) => (m(), E(s(R), {
|
|
159
|
-
key: t.field,
|
|
160
|
-
value: t.field,
|
|
161
|
-
disabled: t.disabled
|
|
162
|
-
}, {
|
|
163
|
-
default: d(() => [
|
|
164
|
-
a(s(ae), {
|
|
165
|
-
"show-after": 400,
|
|
166
|
-
content: t.title || "",
|
|
167
|
-
placement: "top"
|
|
168
|
-
}, {
|
|
169
|
-
default: d(() => [
|
|
170
|
-
F(h(t.title || ""), 1)
|
|
171
|
-
]),
|
|
172
|
-
_: 2
|
|
173
|
-
}, 1032, ["content"])
|
|
174
|
-
]),
|
|
175
|
-
_: 2
|
|
176
|
-
}, 1032, ["value", "disabled"]))), 128))
|
|
177
|
-
]),
|
|
178
|
-
_: 1
|
|
179
|
-
}, 8, ["modelValue"])
|
|
180
|
-
]),
|
|
181
|
-
_: 1
|
|
182
|
-
})
|
|
183
|
-
]),
|
|
184
|
-
c("div", xe, [
|
|
185
|
-
c("div", Ce, [
|
|
186
|
-
c("span", null, "已选 " + h(l.selectedColumns.length) + " 列", 1),
|
|
187
|
-
c("span", {
|
|
188
|
-
class: "cursor-pointer text-(--el-color-primary)",
|
|
189
|
-
onClick: U
|
|
190
|
-
}, "清空")
|
|
147
|
+
_: 1
|
|
148
|
+
}, 8, ["modelValue", "class"])
|
|
191
149
|
]),
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
150
|
+
_: 1
|
|
151
|
+
}, 8, ["class"]),
|
|
152
|
+
c("div", {
|
|
153
|
+
class: a(`${e(i)}-picked`)
|
|
154
|
+
}, [
|
|
155
|
+
c("header", {
|
|
156
|
+
class: a(`${e(i)}-picked-head`)
|
|
157
|
+
}, [
|
|
158
|
+
c("span", null, "已选 " + $(E.value.length) + " 列", 1),
|
|
159
|
+
c("span", {
|
|
160
|
+
class: a(`${e(i)}-clear`),
|
|
161
|
+
onClick: q
|
|
162
|
+
}, "清空", 2)
|
|
163
|
+
], 2),
|
|
164
|
+
r(e(B), null, {
|
|
165
|
+
default: s(() => [
|
|
166
|
+
c("ul", {
|
|
167
|
+
ref: J,
|
|
168
|
+
class: a(`${e(i)}-list`)
|
|
196
169
|
}, [
|
|
197
|
-
(
|
|
198
|
-
key:
|
|
199
|
-
class:
|
|
200
|
-
`${s(u)}-item-move`,
|
|
201
|
-
"flex h-36px items-center justify-between pr-12px py-2 cursor-pointer"
|
|
202
|
-
])
|
|
170
|
+
(f(!0), C(w, null, T(E.value, (o) => (f(), C("li", {
|
|
171
|
+
key: o.field,
|
|
172
|
+
class: a(`${e(i)}-item`)
|
|
203
173
|
}, [
|
|
204
|
-
c("
|
|
205
|
-
a(
|
|
206
|
-
|
|
174
|
+
c("span", {
|
|
175
|
+
class: a(`${e(i)}-item-main`)
|
|
176
|
+
}, [
|
|
177
|
+
r(e(P), {
|
|
178
|
+
class: a(`${e(i)}-item-drag`),
|
|
207
179
|
size: 14,
|
|
208
|
-
icon:
|
|
180
|
+
icon: e(ee),
|
|
209
181
|
"is-custom-svg": ""
|
|
210
|
-
}, null, 8, ["icon"]),
|
|
211
|
-
|
|
182
|
+
}, null, 8, ["class", "icon"]),
|
|
183
|
+
r(e(le), {
|
|
212
184
|
"tool-tip": !1,
|
|
213
|
-
class:
|
|
185
|
+
class: a(`${e(i)}-item-title`)
|
|
214
186
|
}, {
|
|
215
|
-
default:
|
|
216
|
-
|
|
187
|
+
default: s(() => [
|
|
188
|
+
h($(o.title || ""), 1)
|
|
217
189
|
]),
|
|
218
190
|
_: 2
|
|
219
|
-
},
|
|
220
|
-
]),
|
|
221
|
-
|
|
191
|
+
}, 1032, ["class"])
|
|
192
|
+
], 2),
|
|
193
|
+
o.locked ? X("", !0) : (f(), C("button", {
|
|
222
194
|
key: 0,
|
|
223
|
-
|
|
224
|
-
|
|
195
|
+
type: "button",
|
|
196
|
+
class: a(`${e(i)}-item-remove`),
|
|
197
|
+
"aria-label": `移除${o.title || ""}`,
|
|
198
|
+
onClick: Y((v) => j(o.field), ["stop"])
|
|
225
199
|
}, [
|
|
226
|
-
|
|
227
|
-
class: "text-[var(--el-text-color-secondary)]",
|
|
200
|
+
r(e(P), {
|
|
228
201
|
size: 12,
|
|
229
|
-
"icon-font":
|
|
202
|
+
"icon-font": e(Z)
|
|
230
203
|
}, null, 8, ["icon-font"])
|
|
231
|
-
], 10,
|
|
204
|
+
], 10, re))
|
|
232
205
|
], 2))), 128))
|
|
233
206
|
], 2)
|
|
234
207
|
]),
|
|
235
208
|
_: 1
|
|
236
209
|
})
|
|
237
|
-
])
|
|
238
|
-
],
|
|
210
|
+
], 2)
|
|
211
|
+
], 2)
|
|
239
212
|
]),
|
|
240
213
|
_: 2
|
|
241
214
|
}, [
|
|
242
|
-
|
|
215
|
+
t.$slots.title ? {
|
|
243
216
|
name: "header",
|
|
244
|
-
fn:
|
|
245
|
-
V(
|
|
217
|
+
fn: s(() => [
|
|
218
|
+
V(t.$slots, "title")
|
|
246
219
|
]),
|
|
247
220
|
key: "0"
|
|
248
221
|
} : void 0
|
|
@@ -250,5 +223,5 @@ const fe = { class: "flex-1" }, pe = { class: "cb flex items-center" }, he = { c
|
|
|
250
223
|
}
|
|
251
224
|
});
|
|
252
225
|
export {
|
|
253
|
-
|
|
226
|
+
Pe as default
|
|
254
227
|
};
|
|
@@ -106,8 +106,7 @@ function no(r = {}, u = z) {
|
|
|
106
106
|
function G(o) {
|
|
107
107
|
const e = /* @__PURE__ */ new Map();
|
|
108
108
|
return o.forEach((n) => {
|
|
109
|
-
const t = n.purchaseInfo, l = t == null ? void 0 : t.supplierSubType;
|
|
110
|
-
if (l == null) return;
|
|
109
|
+
const t = n.purchaseInfo, l = (t == null ? void 0 : t.supplierSubType) ?? "其他";
|
|
111
110
|
let s = e.get(l);
|
|
112
111
|
s || (s = {
|
|
113
112
|
label: String(l),
|
|
@@ -152,8 +151,8 @@ function no(r = {}, u = z) {
|
|
|
152
151
|
}
|
|
153
152
|
function x(o, e, n, t, l) {
|
|
154
153
|
const s = f(o), P = l ? t.filter((i) => {
|
|
155
|
-
var
|
|
156
|
-
return (
|
|
154
|
+
var m;
|
|
155
|
+
return (m = e[s]) == null ? void 0 : m.includes(i.value);
|
|
157
156
|
}) || [] : t.find((i) => i.value === e[s]);
|
|
158
157
|
return {
|
|
159
158
|
values: e,
|
|
@@ -165,7 +164,7 @@ function no(r = {}, u = z) {
|
|
|
165
164
|
};
|
|
166
165
|
}
|
|
167
166
|
function k(o, e, n, t, l) {
|
|
168
|
-
const s = g(o), P = oo(s.componentProps, e, n, t), i = F(o), { onChange:
|
|
167
|
+
const s = g(o), P = oo(s.componentProps, e, n, t), i = F(o), { onChange: m, ...h } = P, d = q(s.customOptions) ? s.customOptions(e, t) : t, p = S(o) === "TtPanelSelect", a = p && o === "shopId" ? J(d) : p && o === "purchasePlaceId" ? G(d) : d, w = p ? D(a) : d;
|
|
169
168
|
return p ? {
|
|
170
169
|
multiple: i,
|
|
171
170
|
showAll: s.showAll ?? (o === "shopId" && c === "action" ? O(e[f("platformId")]).length > 0 : !0),
|
|
@@ -190,7 +189,7 @@ function no(r = {}, u = z) {
|
|
|
190
189
|
showOriginMode: !1,
|
|
191
190
|
showPinyinMode: !0,
|
|
192
191
|
...h,
|
|
193
|
-
options:
|
|
192
|
+
options: d,
|
|
194
193
|
onChange(R) {
|
|
195
194
|
j(
|
|
196
195
|
R,
|
|
@@ -211,11 +210,11 @@ function no(r = {}, u = z) {
|
|
|
211
210
|
dependencies: _(o),
|
|
212
211
|
componentProps: (n, t) => {
|
|
213
212
|
var h;
|
|
214
|
-
const l = N(o), s = f(o), P = F(o), i = b(o),
|
|
215
|
-
return k(o, n, t, l, (
|
|
213
|
+
const l = N(o), s = f(o), P = F(o), i = b(o), m = ((h = n[s]) == null ? void 0 : h.at(-1)) !== i;
|
|
214
|
+
return k(o, n, t, l, (d) => {
|
|
216
215
|
if (S(o) !== "TtPanelSelect") {
|
|
217
216
|
const p = n[s];
|
|
218
|
-
P && (
|
|
217
|
+
P && (m && O(d).at(-1) === i ? n[s] = [i] : n[s] = p == null ? void 0 : p.filter((a) => a !== i));
|
|
219
218
|
}
|
|
220
219
|
});
|
|
221
220
|
}
|
|
@@ -229,12 +228,12 @@ function no(r = {}, u = z) {
|
|
|
229
228
|
label: M("platformId"),
|
|
230
229
|
rules: C("platformId"),
|
|
231
230
|
componentProps: (o, e) => {
|
|
232
|
-
var
|
|
233
|
-
const n = "platformId", t = f(n), l = f("shopId"), s = F(n), P = F("shopId"), i = N(n),
|
|
231
|
+
var d;
|
|
232
|
+
const n = "platformId", t = f(n), l = f("shopId"), s = F(n), P = F("shopId"), i = N(n), m = b(n), h = ((d = o[t]) == null ? void 0 : d.at(-1)) !== m;
|
|
234
233
|
return k(n, o, e, i, (p) => {
|
|
235
234
|
if (S(n) !== "TtPanelSelect") {
|
|
236
235
|
const a = o[t];
|
|
237
|
-
s && (h && O(p).at(-1) ===
|
|
236
|
+
s && (h && O(p).at(-1) === m ? o[t] = [m] : o[t] = a == null ? void 0 : a.filter((w) => w !== m));
|
|
238
237
|
}
|
|
239
238
|
o[l] = P ? [] : void 0;
|
|
240
239
|
});
|
|
@@ -247,11 +246,11 @@ function no(r = {}, u = z) {
|
|
|
247
246
|
label: M("shopId"),
|
|
248
247
|
componentProps: (o, e) => {
|
|
249
248
|
var h;
|
|
250
|
-
const n = "shopId", t = f(n), l = o[f("platformId")], s = Q(l), P = F(n), i = b(n),
|
|
251
|
-
return k(n, o, e, s, (
|
|
249
|
+
const n = "shopId", t = f(n), l = o[f("platformId")], s = Q(l), P = F(n), i = b(n), m = ((h = o[t]) == null ? void 0 : h.at(-1)) !== i;
|
|
250
|
+
return k(n, o, e, s, (d) => {
|
|
252
251
|
if (S(n) !== "TtPanelSelect") {
|
|
253
252
|
const p = o[t];
|
|
254
|
-
P && (
|
|
253
|
+
P && (m && O(d).at(-1) === i ? o[t] = [i] : o[t] = p == null ? void 0 : p.filter((a) => a !== i));
|
|
255
254
|
}
|
|
256
255
|
});
|
|
257
256
|
},
|