@dazhicheng/ui 1.6.79 → 1.6.81
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/api/supplier.d.ts +16 -0
- package/dist/api/supplier.js +39 -12
- package/dist/assets/svg/download.svg.js +1 -1
- package/dist/components/tt-area/TtArea.vue.js +1 -1
- package/dist/components/tt-button/index.d.ts +28 -28
- package/dist/components/tt-button/index.vue.d.ts +16 -16
- package/dist/components/tt-custom-export-modal/src/assets/search.svg.js +5 -5
- package/dist/components/tt-custom-export-modal/src/assets/star.svg.js +3 -3
- package/dist/components/tt-custom-export-modal/src/assets/trash.svg.js +7 -7
- package/dist/components/tt-custom-export-modal/src/components/FieldGridSection.vue.js +1 -1
- package/dist/components/tt-drawer/index.d.ts +109 -109
- package/dist/components/tt-drawer/src/RenderDrawer.vue.d.ts +60 -60
- package/dist/components/tt-drawer/src/components/DrawerHeader.vue.js +2 -2
- package/dist/components/tt-empty/index.d.ts +4 -4
- package/dist/components/tt-form/src/components/FormElInput.vue.d.ts +10 -10
- package/dist/components/tt-icon/index.vue.js +2 -2
- package/dist/components/tt-image/index.d.ts +29 -29
- package/dist/components/tt-image/src/components/ImageViewer.d.ts +20 -20
- package/dist/components/tt-image/tt-image.d.ts +29 -29
- package/dist/components/tt-input-textarea/index.vue.d.ts +40 -40
- package/dist/components/tt-loading/src/loading.vue.js +2 -2
- package/dist/components/tt-modal/index.d.ts +150 -150
- package/dist/components/tt-modal/src/RenderModal.vue.d.ts +42 -42
- package/dist/components/tt-modal/src/hooks/useModalRender.d.ts +17 -17
- package/dist/components/tt-panel-select/src/components/PanelMiddle.vue.d.ts +5 -5
- package/dist/components/tt-panel-select/src/components/PanelMiddle.vue.js +133 -122
- package/dist/components/tt-panel-select/src/components/PanelRight.vue.js +77 -66
- package/dist/components/tt-panel-select/src/hooks/usePanelData.d.ts +2 -0
- package/dist/components/tt-panel-select/src/hooks/usePanelData.js +14 -14
- package/dist/components/tt-panel-select/src/index.vue.d.ts +7 -5
- package/dist/components/tt-panel-select/src/index.vue.js +300 -219
- package/dist/components/tt-panel-select/src/types.d.ts +12 -0
- package/dist/components/tt-table/index.js +6 -5
- package/dist/components/tt-table/src/TableForm.vue.js +3 -2
- package/dist/components/tt-table/src/hooks/useQuery.js +52 -50
- package/dist/components/tt-upload/index.d.ts +60 -60
- package/dist/components/tt-upload/src/TtUpload.vue.d.ts +37 -37
- package/dist/components/tt-upload/src/typing.d.ts +17 -17
- package/dist/hooks/basicDataCodes.d.ts +5 -0
- package/dist/hooks/basicDataCodes.js +61 -60
- package/dist/hooks/missingOptionsCache.d.ts +53 -0
- package/dist/hooks/missingOptionsCache.js +133 -0
- package/dist/hooks/panelSelectEchoFields.d.ts +12 -0
- package/dist/hooks/panelSelectEchoFields.js +46 -0
- package/dist/hooks/useBasicDataOptions.d.ts +2 -0
- package/dist/hooks/useBasicDataOptions.js +85 -78
- package/dist/hooks/useDataPermissionOptions.d.ts +10 -0
- package/dist/hooks/useDataPermissionOptions.js +83 -66
- package/dist/hooks/useFormSchemasLink.js +240 -194
- package/dist/hooks/usePanelSelectSchemas.d.ts +11 -0
- package/dist/hooks/usePanelSelectSchemas.js +158 -122
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -1,158 +1,165 @@
|
|
|
1
|
-
import { ref as b, watchEffect as
|
|
1
|
+
import { ref as b, watchEffect as B, unref as q, computed as j } from "vue";
|
|
2
2
|
import { useRoute as H } from "vue-router";
|
|
3
3
|
import { useOwnerRoutePath as I } from "./useOwnerRoutePath.js";
|
|
4
4
|
import { clearUserListCache as U } from "./userListCache.js";
|
|
5
|
-
import { GEO_LEVEL_CODES as
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
import { GEO_LEVEL_CODES as L, canDeriveGeoLevel as x, deriveRegionLevelOptionsFromGeoSource as Y, resolveHighestGeoLevelCode as A, isGeoLevelCode as M, CODE_REGISTRY as k } from "./basicDataCodes.js";
|
|
6
|
+
import { missingOptionsEchoVersion as J, getMergedOptions as N } from "./missingOptionsCache.js";
|
|
7
|
+
const a = /* @__PURE__ */ new Map(), g = /* @__PURE__ */ new Map(), w = /* @__PURE__ */ new Map(), m = /* @__PURE__ */ new Map(), C = /* @__PURE__ */ new Map();
|
|
8
|
+
function y(r) {
|
|
8
9
|
return Array.isArray(r) ? r : [];
|
|
9
10
|
}
|
|
10
|
-
function
|
|
11
|
-
|
|
11
|
+
function ne(r, o) {
|
|
12
|
+
var c;
|
|
13
|
+
return y((c = a.get(r)) == null ? void 0 : c[o]);
|
|
12
14
|
}
|
|
13
|
-
function
|
|
14
|
-
return
|
|
15
|
+
function Q(r) {
|
|
16
|
+
return r.reduce((o, c) => (o[c] = [], o), {});
|
|
17
|
+
}
|
|
18
|
+
function D(r, o) {
|
|
19
|
+
return Object.prototype.hasOwnProperty.call(r, o);
|
|
15
20
|
}
|
|
16
21
|
function F(r) {
|
|
17
|
-
return A(
|
|
22
|
+
return A(L.filter((o) => D(r, o)));
|
|
18
23
|
}
|
|
19
|
-
function
|
|
20
|
-
const
|
|
21
|
-
if (!
|
|
22
|
-
const
|
|
23
|
-
if (!Array.isArray(
|
|
24
|
+
function O(r) {
|
|
25
|
+
const o = F(r);
|
|
26
|
+
if (!o) return r;
|
|
27
|
+
const c = r[o];
|
|
28
|
+
if (!Array.isArray(c)) return r;
|
|
24
29
|
const d = { ...r };
|
|
25
|
-
let
|
|
26
|
-
return
|
|
27
|
-
x(
|
|
28
|
-
}),
|
|
30
|
+
let u = !1;
|
|
31
|
+
return L.forEach((f) => {
|
|
32
|
+
x(o, f) && (D(d, f) || (d[f] = Y(c, f), u = !0));
|
|
33
|
+
}), u ? d : r;
|
|
29
34
|
}
|
|
30
|
-
function
|
|
31
|
-
const
|
|
32
|
-
return
|
|
35
|
+
function W(r, o) {
|
|
36
|
+
const c = F(o), d = r.filter(M), u = c || A(d) || void 0;
|
|
37
|
+
return u ? r.filter((f) => M(f) ? !(x(u, f) || f === u && D(o, u)) : !0) : r;
|
|
33
38
|
}
|
|
34
|
-
function
|
|
35
|
-
const
|
|
36
|
-
function
|
|
39
|
+
function se(r) {
|
|
40
|
+
const o = H(), c = I(), d = b({});
|
|
41
|
+
function u(t = {}) {
|
|
37
42
|
d.value = r.codes.reduce(
|
|
38
|
-
(e, n) => (e[n] =
|
|
43
|
+
(e, n) => (e[n] = y(t[n]), e),
|
|
39
44
|
{}
|
|
40
45
|
);
|
|
41
46
|
}
|
|
42
|
-
|
|
47
|
+
u();
|
|
43
48
|
function f(t) {
|
|
44
|
-
|
|
49
|
+
a.delete(t), m.delete(t);
|
|
45
50
|
}
|
|
46
|
-
function
|
|
51
|
+
function V(t) {
|
|
47
52
|
const e = g.get(t) || /* @__PURE__ */ new Set(), n = e.size;
|
|
48
|
-
r.codes.forEach((s) => e.add(s)), g.set(t, e), e.size !== n &&
|
|
53
|
+
r.codes.forEach((s) => e.add(s)), g.set(t, e), e.size !== n && E(t);
|
|
49
54
|
}
|
|
50
|
-
function
|
|
51
|
-
|
|
55
|
+
function _(t) {
|
|
56
|
+
u(a.get(t));
|
|
52
57
|
}
|
|
53
|
-
function
|
|
58
|
+
function E(t) {
|
|
54
59
|
const e = m.get(t);
|
|
55
60
|
if (e) return e;
|
|
56
|
-
const n = Promise.resolve().then(() =>
|
|
61
|
+
const n = Promise.resolve().then(() => P());
|
|
57
62
|
return m.set(t, n), n.finally(() => {
|
|
58
63
|
m.get(t) === n && m.delete(t);
|
|
59
64
|
}), n;
|
|
60
65
|
}
|
|
61
|
-
async function
|
|
66
|
+
async function z(t) {
|
|
62
67
|
var s;
|
|
63
|
-
const e = (s =
|
|
68
|
+
const e = (s = o.meta) == null ? void 0 : s.permissionOnlyCode;
|
|
64
69
|
return (await Promise.allSettled(
|
|
65
70
|
t.map(async (i) => {
|
|
66
71
|
try {
|
|
67
|
-
const
|
|
68
|
-
return [i,
|
|
72
|
+
const p = await k[i].fetchOptions({ permissionOnlyCode: e });
|
|
73
|
+
return [i, y(p)];
|
|
69
74
|
} catch {
|
|
70
75
|
return [i, []];
|
|
71
76
|
}
|
|
72
77
|
})
|
|
73
|
-
)).reduce((i, l,
|
|
74
|
-
const
|
|
75
|
-
return l.status === "fulfilled" ? i[l.value[0]] =
|
|
78
|
+
)).reduce((i, l, p) => {
|
|
79
|
+
const S = t[p];
|
|
80
|
+
return l.status === "fulfilled" ? i[l.value[0]] = y(l.value[1]) : i[S] = [], i;
|
|
76
81
|
}, {});
|
|
77
82
|
}
|
|
78
|
-
async function
|
|
79
|
-
const e =
|
|
83
|
+
async function P(t = !1) {
|
|
84
|
+
const e = c;
|
|
80
85
|
try {
|
|
81
86
|
const n = q(r.dataSource);
|
|
82
87
|
if (n) {
|
|
83
|
-
let s = { ...
|
|
84
|
-
s =
|
|
88
|
+
let s = { ...a.get(e) || {}, ...n };
|
|
89
|
+
s = O(s), a.set(e, s), u(s);
|
|
85
90
|
return;
|
|
86
91
|
}
|
|
87
92
|
for (; ; ) {
|
|
88
|
-
const s =
|
|
89
|
-
s !== (
|
|
90
|
-
const i = [...g.get(e) || r.codes], l = t ? i : i.filter((
|
|
93
|
+
const s = O(a.get(e) || {});
|
|
94
|
+
s !== (a.get(e) || {}) && a.set(e, s);
|
|
95
|
+
const i = [...g.get(e) || r.codes], l = t ? i : i.filter((h) => !D(s, h));
|
|
91
96
|
if (t = !1, !l.length) {
|
|
92
|
-
|
|
97
|
+
u(s);
|
|
93
98
|
return;
|
|
94
99
|
}
|
|
95
|
-
const
|
|
96
|
-
if (
|
|
100
|
+
const p = w.get(e);
|
|
101
|
+
if (p)
|
|
97
102
|
try {
|
|
98
|
-
await
|
|
103
|
+
await p;
|
|
99
104
|
continue;
|
|
100
105
|
} catch {
|
|
101
106
|
}
|
|
102
|
-
const
|
|
103
|
-
if (!
|
|
104
|
-
const
|
|
105
|
-
|
|
107
|
+
const S = W(l, s);
|
|
108
|
+
if (!S.length) {
|
|
109
|
+
const h = O(s);
|
|
110
|
+
a.set(e, h), u(h);
|
|
106
111
|
return;
|
|
107
112
|
}
|
|
108
|
-
const G =
|
|
109
|
-
|
|
113
|
+
const G = z(S), R = (C.get(e) || 0) + 1;
|
|
114
|
+
C.set(e, R), w.set(e, G);
|
|
110
115
|
try {
|
|
111
|
-
const
|
|
112
|
-
if (
|
|
116
|
+
const h = await G;
|
|
117
|
+
if (C.get(e) !== R)
|
|
113
118
|
continue;
|
|
114
119
|
let v = {
|
|
115
|
-
...
|
|
116
|
-
...
|
|
120
|
+
...a.get(e) || {},
|
|
121
|
+
...h
|
|
117
122
|
};
|
|
118
|
-
v =
|
|
123
|
+
v = O(v), a.set(e, v), u(v);
|
|
119
124
|
} finally {
|
|
120
|
-
|
|
125
|
+
C.get(e) === R && w.delete(e);
|
|
121
126
|
}
|
|
122
127
|
}
|
|
123
128
|
} catch {
|
|
124
|
-
const n = [...g.get(e) || r.codes], s =
|
|
125
|
-
|
|
129
|
+
const n = [...g.get(e) || r.codes], s = Q(n), l = { ...a.get(e) || {}, ...s };
|
|
130
|
+
a.set(e, l), u(l);
|
|
126
131
|
}
|
|
127
132
|
}
|
|
128
|
-
async function
|
|
129
|
-
const t =
|
|
130
|
-
|
|
133
|
+
async function T() {
|
|
134
|
+
const t = c, e = new Set(g.get(t) || r.codes);
|
|
135
|
+
w.clear(), m.clear(), a.clear(), g.clear(), C.clear(), U(), g.set(t, e), f(t), await P(!0);
|
|
131
136
|
}
|
|
132
|
-
return
|
|
137
|
+
return B(() => {
|
|
133
138
|
const t = q(r.dataSource);
|
|
134
139
|
if (!t) return;
|
|
135
|
-
const e =
|
|
136
|
-
let n = { ...
|
|
137
|
-
n =
|
|
138
|
-
}),
|
|
139
|
-
dataSource:
|
|
140
|
+
const e = c;
|
|
141
|
+
let n = { ...a.get(e) || {}, ...t };
|
|
142
|
+
n = O(n), a.set(e, n), u(n);
|
|
143
|
+
}), V(c), E(c).then(() => _(c)), {
|
|
144
|
+
dataSource: j(() => {
|
|
145
|
+
J.value;
|
|
140
146
|
const t = r.codes.reduce(
|
|
141
|
-
(e, n) => (e[n] =
|
|
147
|
+
(e, n) => (e[n] = N(c, n, y(d.value[n])), e),
|
|
142
148
|
{}
|
|
143
149
|
);
|
|
144
150
|
return new Proxy(t, {
|
|
145
151
|
get(e, n) {
|
|
146
|
-
return typeof n != "string" ? [] :
|
|
152
|
+
return typeof n != "string" ? [] : y(t[n]);
|
|
147
153
|
},
|
|
148
154
|
set() {
|
|
149
155
|
return !1;
|
|
150
156
|
}
|
|
151
157
|
});
|
|
152
158
|
}),
|
|
153
|
-
reload:
|
|
159
|
+
reload: T
|
|
154
160
|
};
|
|
155
161
|
}
|
|
156
162
|
export {
|
|
157
|
-
|
|
163
|
+
ne as getBasicDataMainOptions,
|
|
164
|
+
se as useBasicDataOptions
|
|
158
165
|
};
|
|
@@ -17,6 +17,16 @@ export interface UseBusinessDataOptions {
|
|
|
17
17
|
/** 是否在选项列表头部插入「全部」选项。传 boolean 对所有 code 生效,传对象可按 code 单独控制 */
|
|
18
18
|
showAll?: boolean | Partial<Record<BusinessDataType, boolean>>;
|
|
19
19
|
}
|
|
20
|
+
/**
|
|
21
|
+
* 读取路由级数据权限主列表(已归一化 label/value,不含缺码 echo),
|
|
22
|
+
* 供 ensureMissing 算差集(如 purchasePlaceId ↔ CODES.PURCHASE_PLACE)。
|
|
23
|
+
*/
|
|
24
|
+
export declare function getDataPermissionMainOptions(routePath: string, code: BusinessDataType): DataPermissionOptionItem[];
|
|
25
|
+
/**
|
|
26
|
+
* 等待路由级数据权限主列表就绪(含 microtask 已排程的首拉)。
|
|
27
|
+
* 表格 ensureMissing 若早于权限缓存落地,会把整页 code 误判为缺码。
|
|
28
|
+
*/
|
|
29
|
+
export declare function awaitDataPermissionReady(routePath: string, codes?: BusinessDataType[]): Promise<void>;
|
|
20
30
|
/**
|
|
21
31
|
* 获取当前用户的数据权限下拉选项(平台 / 店铺 / 采购地 / 业务类型 / 锁单人 / 用户)。
|
|
22
32
|
*
|
|
@@ -1,103 +1,120 @@
|
|
|
1
1
|
import { queryDataPermissionDetailDataTypeContext as M } from "../api/dataTypeContext.js";
|
|
2
|
-
import { fetchUserListOnce as
|
|
3
|
-
import {
|
|
4
|
-
import { useOwnerRoutePath as
|
|
5
|
-
const
|
|
2
|
+
import { fetchUserListOnce as R, clearUserListCache as N } from "./userListCache.js";
|
|
3
|
+
import { ref as S, computed as D, unref as A } from "vue";
|
|
4
|
+
import { useOwnerRoutePath as F } from "./useOwnerRoutePath.js";
|
|
5
|
+
const T = { label: "全部", value: "all" }, q = {
|
|
6
6
|
platformId: ["platformName", "platformId"],
|
|
7
7
|
shopId: ["shopName", "shopId"],
|
|
8
8
|
purchasePlaceId: ["purchasePlaceName", "purchasePlaceCode"],
|
|
9
9
|
businessType: ["itemName", "itemCode"],
|
|
10
10
|
lockUserId: ["userName", "userId"],
|
|
11
11
|
userId: ["fullName", "id"]
|
|
12
|
-
},
|
|
13
|
-
function
|
|
14
|
-
let
|
|
15
|
-
return
|
|
12
|
+
}, d = /* @__PURE__ */ new Map(), f = /* @__PURE__ */ new Map(), m = /* @__PURE__ */ new Map(), w = /* @__PURE__ */ new Set(), I = /* @__PURE__ */ new Map(), g = /* @__PURE__ */ new Map(), v = /* @__PURE__ */ new WeakMap();
|
|
13
|
+
function O(e) {
|
|
14
|
+
let t = I.get(e);
|
|
15
|
+
return t || (t = S(0), I.set(e, t)), t;
|
|
16
16
|
}
|
|
17
|
-
function
|
|
18
|
-
|
|
17
|
+
function x(e) {
|
|
18
|
+
O(e).value++;
|
|
19
19
|
}
|
|
20
|
-
function
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
const
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
20
|
+
function _(e, t) {
|
|
21
|
+
const n = d.get(e);
|
|
22
|
+
if (!n || !Object.hasOwn(n, t)) return [];
|
|
23
|
+
const o = n[t];
|
|
24
|
+
return o != null && o.length ? C(t, o) : [];
|
|
25
|
+
}
|
|
26
|
+
async function z(e, t = ["purchasePlaceId"]) {
|
|
27
|
+
await Promise.resolve();
|
|
28
|
+
const n = f.get(e);
|
|
29
|
+
n && await n;
|
|
30
|
+
const o = m.get(e) ?? /* @__PURE__ */ new Set();
|
|
31
|
+
t.forEach((r) => o.add(r)), m.set(e, o);
|
|
32
|
+
const a = d.get(e) ?? {};
|
|
33
|
+
t.some((r) => !Object.hasOwn(a, r)) && await h(e);
|
|
34
|
+
}
|
|
35
|
+
function C(e, t = []) {
|
|
36
|
+
let n = v.get(t);
|
|
37
|
+
n || (n = /* @__PURE__ */ new Map(), v.set(t, n));
|
|
38
|
+
const o = n.get(e);
|
|
39
|
+
if (o) return o.slice();
|
|
40
|
+
const [a, r] = q[e], i = t.map((s) => {
|
|
41
|
+
const c = e === "purchasePlaceId" ? s.purchaseInfo || {} : s;
|
|
42
|
+
return { ...s, label: c[a], value: c[r] };
|
|
28
43
|
});
|
|
29
|
-
return
|
|
44
|
+
return n.set(e, i), i.slice();
|
|
30
45
|
}
|
|
31
46
|
async function L(e) {
|
|
32
|
-
const
|
|
33
|
-
|
|
34
|
-
(
|
|
47
|
+
const t = e.filter((s) => s !== "userId"), n = e.includes("userId"), [o, a] = await Promise.allSettled([
|
|
48
|
+
t.length ? M({ dataTypeName: t }).then(
|
|
49
|
+
(s) => s
|
|
35
50
|
) : Promise.resolve([]),
|
|
36
|
-
|
|
51
|
+
n ? R() : Promise.resolve(void 0)
|
|
37
52
|
]), r = {};
|
|
38
|
-
if (
|
|
39
|
-
for (const
|
|
40
|
-
r[
|
|
41
|
-
for (const
|
|
42
|
-
const
|
|
43
|
-
|
|
53
|
+
if (o.status === "fulfilled") {
|
|
54
|
+
for (const s of t)
|
|
55
|
+
r[s] = [];
|
|
56
|
+
for (const s of o.value) {
|
|
57
|
+
const c = s == null ? void 0 : s.dataTypeCode;
|
|
58
|
+
c && (r[c] = s.originalItems || []);
|
|
44
59
|
}
|
|
45
60
|
}
|
|
46
|
-
const
|
|
47
|
-
return
|
|
61
|
+
const i = a.status === "fulfilled" ? a.value : void 0;
|
|
62
|
+
return i != null && i.length && (r.userId = i), r;
|
|
48
63
|
}
|
|
49
|
-
async function
|
|
50
|
-
const
|
|
51
|
-
|
|
52
|
-
const
|
|
64
|
+
async function h(e, t = !1) {
|
|
65
|
+
const n = f.get(e);
|
|
66
|
+
n && await n;
|
|
67
|
+
const o = d.get(e) ?? {}, a = [...m.get(e) ?? []], r = t ? a : a.filter((c) => !Object.hasOwn(o, c));
|
|
53
68
|
if (!r.length) return;
|
|
54
|
-
const
|
|
55
|
-
const
|
|
56
|
-
if ((
|
|
57
|
-
const
|
|
58
|
-
|
|
69
|
+
const i = g.get(e) ?? 0, s = (async () => {
|
|
70
|
+
const c = await L(r);
|
|
71
|
+
if ((g.get(e) ?? 0) !== i) return;
|
|
72
|
+
const p = { ...d.get(e) ?? {}, ...c };
|
|
73
|
+
d.set(e, p), x(e);
|
|
59
74
|
})();
|
|
60
|
-
|
|
75
|
+
f.set(e, s);
|
|
61
76
|
try {
|
|
62
|
-
await
|
|
77
|
+
await s;
|
|
63
78
|
} finally {
|
|
64
|
-
|
|
79
|
+
f.get(e) === s && f.delete(e);
|
|
65
80
|
}
|
|
66
81
|
}
|
|
67
82
|
function U(e) {
|
|
68
|
-
|
|
69
|
-
|
|
83
|
+
w.has(e) || (w.add(e), Promise.resolve().then(() => {
|
|
84
|
+
w.delete(e), h(e);
|
|
70
85
|
}));
|
|
71
86
|
}
|
|
72
|
-
function
|
|
73
|
-
const
|
|
74
|
-
e.codes.forEach((
|
|
75
|
-
function
|
|
76
|
-
var
|
|
77
|
-
return typeof e.showAll == "boolean" ? e.showAll : ((
|
|
87
|
+
function k(e) {
|
|
88
|
+
const t = F(), n = O(t), o = m.get(t) ?? /* @__PURE__ */ new Set();
|
|
89
|
+
e.codes.forEach((s) => o.add(s)), m.set(t, o), U(t);
|
|
90
|
+
function a(s) {
|
|
91
|
+
var c;
|
|
92
|
+
return typeof e.showAll == "boolean" ? e.showAll : ((c = e.showAll) == null ? void 0 : c[s]) ?? !1;
|
|
78
93
|
}
|
|
79
|
-
const r =
|
|
80
|
-
|
|
81
|
-
const
|
|
82
|
-
for (const
|
|
83
|
-
const u =
|
|
84
|
-
|
|
94
|
+
const r = D(() => {
|
|
95
|
+
n.value;
|
|
96
|
+
const s = A(e.dataSource), c = d.get(t) ?? {}, y = s ? { ...c, ...s } : c, p = {};
|
|
97
|
+
for (const l of e.codes) {
|
|
98
|
+
const u = C(l, y[l]);
|
|
99
|
+
p[l] = a(l) ? [T, ...u] : u;
|
|
85
100
|
}
|
|
86
|
-
return new Proxy(
|
|
87
|
-
get(
|
|
88
|
-
return typeof u == "symbol" ? Reflect.get(
|
|
101
|
+
return new Proxy(p, {
|
|
102
|
+
get(l, u, b) {
|
|
103
|
+
return typeof u == "symbol" ? Reflect.get(l, u, b) : l[u] ?? [];
|
|
89
104
|
},
|
|
90
|
-
set(
|
|
105
|
+
set(l, u) {
|
|
91
106
|
return !0;
|
|
92
107
|
}
|
|
93
108
|
});
|
|
94
109
|
});
|
|
95
|
-
async function
|
|
96
|
-
const
|
|
97
|
-
|
|
110
|
+
async function i() {
|
|
111
|
+
const s = (g.get(t) ?? 0) + 1;
|
|
112
|
+
g.set(t, s), d.delete(t), f.delete(t), N(), await h(t, !0);
|
|
98
113
|
}
|
|
99
|
-
return { dataSource: r, reload:
|
|
114
|
+
return { dataSource: r, reload: i };
|
|
100
115
|
}
|
|
101
116
|
export {
|
|
102
|
-
|
|
117
|
+
z as awaitDataPermissionReady,
|
|
118
|
+
_ as getDataPermissionMainOptions,
|
|
119
|
+
k as useDataPermissionOptions
|
|
103
120
|
};
|