@nocobase/client 2.0.0-alpha.4 → 2.0.0-alpha.5
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/es/index.mjs
CHANGED
|
@@ -9556,7 +9556,7 @@ function addAppVersion(e, t) {
|
|
|
9556
9556
|
addAppVersion((n = e.properties) == null ? void 0 : n[o], t);
|
|
9557
9557
|
}), e;
|
|
9558
9558
|
}
|
|
9559
|
-
const name = "@nocobase/client", version = "2.0.0-alpha.
|
|
9559
|
+
const name = "@nocobase/client", version = "2.0.0-alpha.5", license = "AGPL-3.0", main = "lib/index.js", module = "es/index.mjs", types = "es/index.d.ts", dependencies = {
|
|
9560
9560
|
"@ahooksjs/use-url-state": "3.5.1",
|
|
9561
9561
|
"@ant-design/cssinjs": "^1.11.1",
|
|
9562
9562
|
"@ant-design/icons": "^5.6.1",
|
|
@@ -9579,10 +9579,10 @@ const name = "@nocobase/client", version = "2.0.0-alpha.4", license = "AGPL-3.0"
|
|
|
9579
9579
|
"@formily/reactive-react": "^2.2.27",
|
|
9580
9580
|
"@formily/shared": "^2.2.27",
|
|
9581
9581
|
"@formily/validator": "^2.2.27",
|
|
9582
|
-
"@nocobase/evaluators": "2.0.0-alpha.
|
|
9583
|
-
"@nocobase/flow-engine": "2.0.0-alpha.
|
|
9584
|
-
"@nocobase/sdk": "2.0.0-alpha.
|
|
9585
|
-
"@nocobase/utils": "2.0.0-alpha.
|
|
9582
|
+
"@nocobase/evaluators": "2.0.0-alpha.5",
|
|
9583
|
+
"@nocobase/flow-engine": "2.0.0-alpha.5",
|
|
9584
|
+
"@nocobase/sdk": "2.0.0-alpha.5",
|
|
9585
|
+
"@nocobase/utils": "2.0.0-alpha.5",
|
|
9586
9586
|
"@tanstack/react-table": "^8.21.3",
|
|
9587
9587
|
"@types/tabulator-tables": "^6.2.6",
|
|
9588
9588
|
ahooks: "^3.7.2",
|
|
@@ -11246,7 +11246,7 @@ const Table$2 = withDynamicSchemaProps(
|
|
|
11246
11246
|
withSkeletonComponent(
|
|
11247
11247
|
observer$1((e) => {
|
|
11248
11248
|
var ye, ie;
|
|
11249
|
-
const { token: t } = useToken$1(),
|
|
11249
|
+
const { token: t } = useToken$1(), fe = omit(e, ["onBlur", "onFocus"]), { pagination: o, useProps: n } = fe, r = W(fe, ["pagination", "useProps"]), he = (n == null ? void 0 : n()) || {}, { pagination: i } = he, a = W(he, ["pagination"]), xe = f(f({}, r), a), {
|
|
11250
11250
|
dragSort: l = !1,
|
|
11251
11251
|
showIndex: c = !0,
|
|
11252
11252
|
onRowSelectionChange: u,
|
|
@@ -11258,7 +11258,7 @@ const Table$2 = withDynamicSchemaProps(
|
|
|
11258
11258
|
loading: x,
|
|
11259
11259
|
onClickRow: b,
|
|
11260
11260
|
value: y
|
|
11261
|
-
} =
|
|
11261
|
+
} = xe, S = W(xe, [
|
|
11262
11262
|
"dragSort",
|
|
11263
11263
|
"showIndex",
|
|
11264
11264
|
"onRowSelectionChange",
|
|
@@ -11285,14 +11285,14 @@ const Table$2 = withDynamicSchemaProps(
|
|
|
11285
11285
|
U.field.data.selectedRowKeys = [], L([]);
|
|
11286
11286
|
}, U.field.data.setSelectedRowKeys = L);
|
|
11287
11287
|
}, [U == null ? void 0 : U.field]);
|
|
11288
|
-
const J = useMemo(() => b ? G : "", [G, b]), Y = useMemo(() => b ? (oe,
|
|
11289
|
-
onClick: (
|
|
11290
|
-
isPortalInBody(
|
|
11288
|
+
const J = useMemo(() => b ? G : "", [G, b]), Y = useMemo(() => b ? (oe, re) => ({
|
|
11289
|
+
onClick: (le) => {
|
|
11290
|
+
isPortalInBody(le.target) || b(oe, z, q);
|
|
11291
11291
|
},
|
|
11292
|
-
rowIndex:
|
|
11292
|
+
rowIndex: re,
|
|
11293
11293
|
record: oe
|
|
11294
|
-
}) : (oe,
|
|
11295
|
-
rowIndex:
|
|
11294
|
+
}) : (oe, re) => ({
|
|
11295
|
+
rowIndex: re,
|
|
11296
11296
|
record: oe
|
|
11297
11297
|
}), [b, q]);
|
|
11298
11298
|
useDeepCompareEffect(() => {
|
|
@@ -11306,28 +11306,28 @@ const Table$2 = withDynamicSchemaProps(
|
|
|
11306
11306
|
return oe.key;
|
|
11307
11307
|
if (H.current.has(oe))
|
|
11308
11308
|
return H.current.get(oe);
|
|
11309
|
-
const
|
|
11310
|
-
return H.current.set(oe,
|
|
11309
|
+
const re = uid();
|
|
11310
|
+
return H.current.set(oe, re), re;
|
|
11311
11311
|
}, []), Z = useCallback(
|
|
11312
11312
|
(oe) => {
|
|
11313
|
-
var
|
|
11314
|
-
return Array.isArray(m) ? m.map((
|
|
11315
|
-
var
|
|
11316
|
-
return ((
|
|
11317
|
-
}).join("-") : typeof m == "string" ? oe[m] : (
|
|
11313
|
+
var re;
|
|
11314
|
+
return Array.isArray(m) ? m.map((le) => {
|
|
11315
|
+
var pe;
|
|
11316
|
+
return ((pe = oe[le]) == null ? void 0 : pe.toString()) || "";
|
|
11317
|
+
}).join("-") : typeof m == "string" ? oe[m] : (re = (m != null ? m : X)(oe)) == null ? void 0 : re.toString();
|
|
11318
11318
|
},
|
|
11319
11319
|
[JSON.stringify(m), X]
|
|
11320
11320
|
), Q = useMemo(() => (Array.isArray(y) ? y : []).filter(Boolean), [y, y == null ? void 0 : y.length]), ee = useMemo(() => (oe) => {
|
|
11321
|
-
const
|
|
11321
|
+
const re = useCallback((le) => {
|
|
11322
11322
|
var Fe, Pe, Ie, ke, Ae, Ne, Ee, Oe;
|
|
11323
|
-
if (!
|
|
11323
|
+
if (!le.active || !le.over) {
|
|
11324
11324
|
console.warn("move cancel");
|
|
11325
11325
|
return;
|
|
11326
11326
|
}
|
|
11327
|
-
const
|
|
11328
|
-
C.move(
|
|
11327
|
+
const pe = (Ie = (Pe = (Fe = le.active) == null ? void 0 : Fe.data.current) == null ? void 0 : Pe.sortable) == null ? void 0 : Ie.index, be = (Ne = (Ae = (ke = le.over) == null ? void 0 : ke.data.current) == null ? void 0 : Ae.sortable) == null ? void 0 : Ne.index, ve = ((Ee = K.current) == null ? void 0 : Ee[pe]) || le.active, Te = ((Oe = K.current) == null ? void 0 : Oe[be]) || le.over;
|
|
11328
|
+
C.move(pe, be), j({ from: ve, to: Te });
|
|
11329
11329
|
}, []);
|
|
11330
|
-
return /* @__PURE__ */ jsx(DndContext, { onDragEnd:
|
|
11330
|
+
return /* @__PURE__ */ jsx(DndContext, { onDragEnd: re, children: /* @__PURE__ */ jsx("tbody", f({}, oe)) });
|
|
11331
11331
|
}, [C, j]);
|
|
11332
11332
|
ee.displayName = "BodyWrapperComponent";
|
|
11333
11333
|
const te = useMemo(() => ({
|
|
@@ -11340,39 +11340,39 @@ const Table$2 = withDynamicSchemaProps(
|
|
|
11340
11340
|
row: BodyRowComponent$1,
|
|
11341
11341
|
cell: BodyCellComponent$1
|
|
11342
11342
|
}
|
|
11343
|
-
}), [ee]),
|
|
11343
|
+
}), [ee]), ne = useMemo(() => p, [JSON.stringify(p)]), se = useMemo(
|
|
11344
11344
|
() => ({
|
|
11345
|
-
rowSelection: $ !== !1 &&
|
|
11345
|
+
rowSelection: $ !== !1 && ne ? f({
|
|
11346
11346
|
type: "checkbox",
|
|
11347
11347
|
selectedRowKeys: M,
|
|
11348
|
-
onChange(oe,
|
|
11349
|
-
C.data = C.data || {}, C.data.selectedRowKeys = oe, C.data.selectedRowData =
|
|
11348
|
+
onChange(oe, re) {
|
|
11349
|
+
C.data = C.data || {}, C.data.selectedRowKeys = oe, C.data.selectedRowData = re, L(oe), u == null || u(oe, re, L);
|
|
11350
11350
|
},
|
|
11351
|
-
onSelect: (oe,
|
|
11351
|
+
onSelect: (oe, re, le, pe) => {
|
|
11352
11352
|
var be;
|
|
11353
|
-
U && (U.field.data = ((be = U.field) == null ? void 0 : be.data) || {}, U.field.data.selectedRecord = oe, U.field.data.selected =
|
|
11353
|
+
U && (U.field.data = ((be = U.field) == null ? void 0 : be.data) || {}, U.field.data.selectedRecord = oe, U.field.data.selected = re);
|
|
11354
11354
|
},
|
|
11355
11355
|
getCheckboxProps(oe) {
|
|
11356
11356
|
return {
|
|
11357
11357
|
"aria-label": "checkbox"
|
|
11358
11358
|
};
|
|
11359
11359
|
},
|
|
11360
|
-
renderCell: (oe,
|
|
11360
|
+
renderCell: (oe, re, le, pe) => {
|
|
11361
11361
|
if (!l && !c)
|
|
11362
|
-
return
|
|
11362
|
+
return pe;
|
|
11363
11363
|
const be = B == null ? void 0 : B.current, ve = (B == null ? void 0 : B.pageSize) || 20;
|
|
11364
|
-
return be ?
|
|
11364
|
+
return be ? le = le + (be - 1) * ve + 1 : le = le + 1, re.__index && (le = extractIndex$1(re.__index)), /* @__PURE__ */ jsxs(
|
|
11365
11365
|
"div",
|
|
11366
11366
|
{
|
|
11367
11367
|
role: "button",
|
|
11368
|
-
"aria-label": `table-index-${
|
|
11368
|
+
"aria-label": `table-index-${le}`,
|
|
11369
11369
|
className: classNames(oe ? "checked" : null, rowSelectCheckboxWrapperClass$2, {
|
|
11370
11370
|
[rowSelectCheckboxWrapperClassHover$2]: V
|
|
11371
11371
|
}),
|
|
11372
11372
|
children: [
|
|
11373
11373
|
/* @__PURE__ */ jsxs("div", { className: classNames(oe ? "checked" : null, rowSelectCheckboxContentClass$2), children: [
|
|
11374
|
-
l && /* @__PURE__ */ jsx(SortHandle$2, { id: Z(
|
|
11375
|
-
c && /* @__PURE__ */ jsx(TableIndex$4, { index:
|
|
11374
|
+
l && /* @__PURE__ */ jsx(SortHandle$2, { id: Z(re) }),
|
|
11375
|
+
c && /* @__PURE__ */ jsx(TableIndex$4, { index: le })
|
|
11376
11376
|
] }),
|
|
11377
11377
|
V && /* @__PURE__ */ jsx(
|
|
11378
11378
|
"div",
|
|
@@ -11382,17 +11382,17 @@ const Table$2 = withDynamicSchemaProps(
|
|
|
11382
11382
|
oe ? "checked" : null,
|
|
11383
11383
|
rowSelectCheckboxCheckedClassHover$2
|
|
11384
11384
|
),
|
|
11385
|
-
children:
|
|
11385
|
+
children: pe
|
|
11386
11386
|
}
|
|
11387
11387
|
)
|
|
11388
11388
|
]
|
|
11389
11389
|
}
|
|
11390
11390
|
);
|
|
11391
11391
|
}
|
|
11392
|
-
},
|
|
11392
|
+
}, ne) : void 0
|
|
11393
11393
|
}),
|
|
11394
11394
|
[
|
|
11395
|
-
|
|
11395
|
+
ne,
|
|
11396
11396
|
M,
|
|
11397
11397
|
u,
|
|
11398
11398
|
c,
|
|
@@ -11400,61 +11400,61 @@ const Table$2 = withDynamicSchemaProps(
|
|
|
11400
11400
|
C,
|
|
11401
11401
|
Z,
|
|
11402
11402
|
V,
|
|
11403
|
-
|
|
11403
|
+
ne,
|
|
11404
11404
|
B,
|
|
11405
11405
|
U,
|
|
11406
11406
|
$
|
|
11407
11407
|
]
|
|
11408
|
-
),
|
|
11408
|
+
), ae = useCallback(
|
|
11409
11409
|
({ children: oe }) => {
|
|
11410
|
-
var
|
|
11410
|
+
var re, le;
|
|
11411
11411
|
return l ? React.createElement(
|
|
11412
11412
|
SortableContext$1,
|
|
11413
11413
|
{
|
|
11414
|
-
items: ((
|
|
11414
|
+
items: ((le = (re = K.current) == null ? void 0 : re.map) == null ? void 0 : le.call(re, Z)) || []
|
|
11415
11415
|
},
|
|
11416
11416
|
oe
|
|
11417
11417
|
) : React.createElement(React.Fragment, {}, oe);
|
|
11418
11418
|
},
|
|
11419
11419
|
[l, Z]
|
|
11420
11420
|
// Don't put 'value' in dependencies, otherwise it will cause the dropdown component to disappear immediately when adding association fields to the table
|
|
11421
|
-
), { height:
|
|
11421
|
+
), { height: ce, tableSizeRefCallback: ge } = useTableSize(), ue = useMemo(() => ({
|
|
11422
11422
|
x: "max-content",
|
|
11423
|
-
y: (Q == null ? void 0 : Q.length) === 0 ? void 0 :
|
|
11423
|
+
y: (Q == null ? void 0 : Q.length) === 0 ? void 0 : ce
|
|
11424
11424
|
// 当数据为空且设置了 y 轴高度时,表格头会缩到一起。为了解决这个问题,在数据为空时,y 轴高度需要设置为 undefined
|
|
11425
|
-
}), [
|
|
11425
|
+
}), [ce, Q]), Ce = useCallback(
|
|
11426
11426
|
(oe) => q.includes(oe[m]) ? J : "",
|
|
11427
11427
|
[q, J, JSON.stringify(m)]
|
|
11428
|
-
),
|
|
11429
|
-
(oe,
|
|
11430
|
-
const
|
|
11431
|
-
N(
|
|
11428
|
+
), de = useCallback(
|
|
11429
|
+
(oe, re) => {
|
|
11430
|
+
const le = oe ? [...O, re[P.getPrimaryKey()]] : O.filter((pe) => re[P.getPrimaryKey()] !== pe);
|
|
11431
|
+
N(le), g == null || g(oe, re);
|
|
11432
11432
|
},
|
|
11433
11433
|
[O, g, P]
|
|
11434
|
-
),
|
|
11435
|
-
onExpand:
|
|
11434
|
+
), me = useMemo(() => ({
|
|
11435
|
+
onExpand: de,
|
|
11436
11436
|
expandedRowKeys: O
|
|
11437
|
-
}), [O,
|
|
11437
|
+
}), [O, de]);
|
|
11438
11438
|
return (
|
|
11439
11439
|
// If spinning is set to undefined, it will cause the subtable to always display loading, so we need to convert it here.
|
|
11440
11440
|
// We use Spin here instead of Table's loading prop because using Spin here reduces unnecessary re-renders.
|
|
11441
11441
|
/* @__PURE__ */ jsx(HighPerformanceSpin, { spinning: !!x, children: /* @__PURE__ */ jsx(BlockRequestLoadingContext.Provider, { value: !1, children: /* @__PURE__ */ jsx(
|
|
11442
11442
|
InternalNocoBaseTable$1,
|
|
11443
11443
|
I(f(f({
|
|
11444
|
-
tableHeight:
|
|
11445
|
-
SortableWrapper:
|
|
11446
|
-
tableSizeRefCallback:
|
|
11444
|
+
tableHeight: ce,
|
|
11445
|
+
SortableWrapper: ae,
|
|
11446
|
+
tableSizeRefCallback: ge,
|
|
11447
11447
|
defaultRowKey: X,
|
|
11448
11448
|
dataSource: Q
|
|
11449
|
-
}, S),
|
|
11449
|
+
}, S), se), {
|
|
11450
11450
|
paginationProps: B,
|
|
11451
11451
|
components: te,
|
|
11452
11452
|
onTableChange: d,
|
|
11453
11453
|
onRow: Y,
|
|
11454
11454
|
rowClassName: Ce,
|
|
11455
|
-
scroll:
|
|
11455
|
+
scroll: ue,
|
|
11456
11456
|
columns: R,
|
|
11457
|
-
expandable:
|
|
11457
|
+
expandable: me,
|
|
11458
11458
|
field: C,
|
|
11459
11459
|
size: F
|
|
11460
11460
|
})
|
|
@@ -11708,7 +11708,7 @@ const InternalTableBlockProvider = (e) => {
|
|
|
11708
11708
|
const Y = y(R, J), X = (Z = Y == null ? void 0 : Y.filter(
|
|
11709
11709
|
(Q) => Q.interface && !G.includes(Q.interface) && (H || O && O.includes(Q.type) || N && N.includes(Q.interface) || (L && Q.target && Q.target !== R && Array.isArray(L) ? L.includes(Q.interface) : !1))
|
|
11710
11710
|
)) == null ? void 0 : Z.map((Q) => {
|
|
11711
|
-
var te,
|
|
11711
|
+
var te, ne;
|
|
11712
11712
|
const ee = f({
|
|
11713
11713
|
value: K && U ? `${U}.${Q.name}` : Q.name,
|
|
11714
11714
|
label: x((te = Q == null ? void 0 : Q.uiSchema) == null ? void 0 : te.title) || Q.name
|
|
@@ -11719,7 +11719,7 @@ const InternalTableBlockProvider = (e) => {
|
|
|
11719
11719
|
collectionNames: [...z, Q.target],
|
|
11720
11720
|
prefixFieldValue: K ? U ? `${U}.${Q.name}` : Q.name : "",
|
|
11721
11721
|
usePrefix: K
|
|
11722
|
-
})), !((
|
|
11722
|
+
})), !((ne = ee.children) != null && ne.length)) ? null : ee;
|
|
11723
11723
|
}).filter(Boolean);
|
|
11724
11724
|
return q[R] = X, X;
|
|
11725
11725
|
},
|
|
@@ -24313,7 +24313,7 @@ function Input$1(e) {
|
|
|
24313
24313
|
} : i ? getTypedConstantOption(O, i, M) : null : null, [O, i]), q = (Y = L == null ? void 0 : L.component) != null ? Y : NullComponent, z = Array.isArray(i) ? (Z = (X = i.find((Q) => Array.isArray(Q) && Q[0] === O)) == null ? void 0 : X[1]) != null ? Z : {} : {};
|
|
24314
24314
|
let V;
|
|
24315
24315
|
t == null ? a ? n && $ ? V = ["$"] : V = [""] : n ? V = ["$"] : V = [" ", O] : V = n ? ["$"] : [" ", O], m && (V = ["$"]), useEffect(() => {
|
|
24316
|
-
const
|
|
24316
|
+
const ne = L != null ? L : {}, { component: Q } = ne, ee = W(ne, ["component"]), te = [
|
|
24317
24317
|
...a ? [
|
|
24318
24318
|
{
|
|
24319
24319
|
value: "",
|
|
@@ -24324,26 +24324,26 @@ function Input$1(e) {
|
|
|
24324
24324
|
] : [],
|
|
24325
24325
|
...L ? [v(ee)] : [],
|
|
24326
24326
|
...x ? [...x] : []
|
|
24327
|
-
].filter((
|
|
24327
|
+
].filter((se) => !se.deprecated || (N == null ? void 0 : N[0]) === se[M.value]);
|
|
24328
24328
|
A(te);
|
|
24329
24329
|
}, [x, N, L, a]);
|
|
24330
24330
|
const H = (Q) => E(this, null, function* () {
|
|
24331
24331
|
var te;
|
|
24332
24332
|
const ee = Q[Q.length - 1];
|
|
24333
24333
|
if (!((te = ee.children) != null && te.length) && !ee.isLeaf && ee.loadChildren) {
|
|
24334
|
-
let
|
|
24334
|
+
let ne;
|
|
24335
24335
|
if (N && N.length >= 2) {
|
|
24336
|
-
for (const
|
|
24337
|
-
if (
|
|
24338
|
-
|
|
24336
|
+
for (const se of N)
|
|
24337
|
+
if (se === ee[M.value]) {
|
|
24338
|
+
ne = se;
|
|
24339
24339
|
break;
|
|
24340
24340
|
}
|
|
24341
24341
|
}
|
|
24342
|
-
yield ee.loadChildren(ee,
|
|
24342
|
+
yield ee.loadChildren(ee, ne, N), A((se) => [...se]);
|
|
24343
24343
|
}
|
|
24344
24344
|
}), G = useCallback(
|
|
24345
24345
|
(Q, ee) => {
|
|
24346
|
-
var te,
|
|
24346
|
+
var te, ne, se;
|
|
24347
24347
|
if (Q[0] === "$") {
|
|
24348
24348
|
j(!0), N && o(null, ee);
|
|
24349
24349
|
return;
|
|
@@ -24354,7 +24354,7 @@ function Input$1(e) {
|
|
|
24354
24354
|
return;
|
|
24355
24355
|
}
|
|
24356
24356
|
if (Q[0] === " ") {
|
|
24357
|
-
Q[1] ? Q[1] !== O && o((
|
|
24357
|
+
Q[1] ? Q[1] !== O && o((se = (ne = (te = ConstantTypes[Q[1]]) == null ? void 0 : te.default) == null ? void 0 : ne.call(te)) != null ? se : null, ee) : N && o(null, ee);
|
|
24358
24358
|
return;
|
|
24359
24359
|
}
|
|
24360
24360
|
o(`{{${Q.join(".")}}}`, ee);
|
|
@@ -24370,19 +24370,19 @@ function Input$1(e) {
|
|
|
24370
24370
|
}, [L]);
|
|
24371
24371
|
useEffect(() => {
|
|
24372
24372
|
E(this, null, function* () {
|
|
24373
|
-
var
|
|
24373
|
+
var ne;
|
|
24374
24374
|
if (!N || T.length <= 1)
|
|
24375
24375
|
return;
|
|
24376
24376
|
let ee = null;
|
|
24377
24377
|
const te = [];
|
|
24378
|
-
for (let
|
|
24379
|
-
const
|
|
24378
|
+
for (let se = 0; se < N.length; se++) {
|
|
24379
|
+
const ae = N[se];
|
|
24380
24380
|
try {
|
|
24381
|
-
if (
|
|
24381
|
+
if (se === 0 ? ee = T.find((ce) => ce[M.value] === ae) : (ee.loadChildren && !((ne = ee.children) != null && ne.length) && (yield ee.loadChildren(ee, ae, N)), ee = ee.children.find((ce) => ce[M.value] === ae)), !ee)
|
|
24382
24382
|
return;
|
|
24383
24383
|
te.push(ee[M.label]);
|
|
24384
|
-
} catch (
|
|
24385
|
-
error(
|
|
24384
|
+
} catch (ce) {
|
|
24385
|
+
error(ce);
|
|
24386
24386
|
}
|
|
24387
24387
|
}
|
|
24388
24388
|
A([...T]), D([...te]);
|
|
@@ -27961,19 +27961,19 @@ https://requirejs.org/docs/errors.html#` + e);
|
|
|
27961
27961
|
}
|
|
27962
27962
|
}
|
|
27963
27963
|
function y(M, L, q) {
|
|
27964
|
-
var z, V, H, G, U, K, J, Y, X, Z, Q, ee, te = L && L.split("/"),
|
|
27965
|
-
if (M && (M = M.split("/"), J = M.length - 1, a.nodeIdCompat && jsSuffixRegExp.test(M[J]) && (M[J] = M[J].replace(jsSuffixRegExp, "")), M[0].charAt(0) === "." && te && (ee = te.slice(0, te.length - 1), M = ee.concat(M)), b(M), M = M.join("/")), q &&
|
|
27964
|
+
var z, V, H, G, U, K, J, Y, X, Z, Q, ee, te = L && L.split("/"), ne = a.map, se = ne && ne["*"];
|
|
27965
|
+
if (M && (M = M.split("/"), J = M.length - 1, a.nodeIdCompat && jsSuffixRegExp.test(M[J]) && (M[J] = M[J].replace(jsSuffixRegExp, "")), M[0].charAt(0) === "." && te && (ee = te.slice(0, te.length - 1), M = ee.concat(M)), b(M), M = M.join("/")), q && ne && (te || se)) {
|
|
27966
27966
|
H = M.split("/");
|
|
27967
27967
|
e:
|
|
27968
27968
|
for (G = H.length; G > 0; G -= 1) {
|
|
27969
27969
|
if (K = H.slice(0, G).join("/"), te) {
|
|
27970
27970
|
for (U = te.length; U > 0; U -= 1)
|
|
27971
|
-
if (V = getOwn(
|
|
27971
|
+
if (V = getOwn(ne, te.slice(0, U).join("/")), V && (V = getOwn(V, K), V)) {
|
|
27972
27972
|
Y = V, X = G;
|
|
27973
27973
|
break e;
|
|
27974
27974
|
}
|
|
27975
27975
|
}
|
|
27976
|
-
!Z &&
|
|
27976
|
+
!Z && se && getOwn(se, K) && (Z = getOwn(se, K), Q = G);
|
|
27977
27977
|
}
|
|
27978
27978
|
!Y && Z && (Y = Z, X = Q), Y && (H.splice(0, X, Y), M = H.join("/"));
|
|
27979
27979
|
}
|
|
@@ -28196,11 +28196,11 @@ https://requirejs.org/docs/errors.html#` + e);
|
|
|
28196
28196
|
Z && (X = Z), te && (useInteractive = !1), P(ee), hasProp(a.config, L) && (a.config[Q] = a.config[L]);
|
|
28197
28197
|
try {
|
|
28198
28198
|
req.exec(X);
|
|
28199
|
-
} catch (
|
|
28199
|
+
} catch (ne) {
|
|
28200
28200
|
return A(makeError(
|
|
28201
28201
|
"fromtexteval",
|
|
28202
|
-
"fromText eval for " + L + " failed: " +
|
|
28203
|
-
|
|
28202
|
+
"fromText eval for " + L + " failed: " + ne,
|
|
28203
|
+
ne,
|
|
28204
28204
|
[L]
|
|
28205
28205
|
));
|
|
28206
28206
|
}
|
|
@@ -29976,7 +29976,7 @@ const useStyles$a = genStyleHook("nb-markdown", (e, { isDarkTheme: t }) => {
|
|
|
29976
29976
|
}, t ? i : r)
|
|
29977
29977
|
};
|
|
29978
29978
|
}), parseMarkdown$1 = _.memoize((e) => E(void 0, null, function* () {
|
|
29979
|
-
return e && (yield import("./md-
|
|
29979
|
+
return e && (yield import("./md-BbvRKckr.mjs")).default.render(e);
|
|
29980
29980
|
}));
|
|
29981
29981
|
function useParseMarkdown$1(e) {
|
|
29982
29982
|
const [t, o] = useState(""), [n, r] = useState(!0);
|
|
@@ -40992,7 +40992,7 @@ const ActionLink = withDynamicSchemaProps(
|
|
|
40992
40992
|
forEachLinkageRule(D, (Z, Q) => {
|
|
40993
40993
|
X.push(
|
|
40994
40994
|
reaction(
|
|
40995
|
-
() => [getVariableValuesInCondition({ linkageRules: D, localVariables: R })].map((
|
|
40995
|
+
() => [getVariableValuesInCondition({ linkageRules: D, localVariables: R })].map((ne) => JSON.stringify(ne)).join(","),
|
|
40996
40996
|
() => {
|
|
40997
40997
|
F.stateOfLinkageRules = {}, linkageAction(
|
|
40998
40998
|
{
|
|
@@ -41028,12 +41028,12 @@ const ActionLink = withDynamicSchemaProps(
|
|
|
41028
41028
|
yield c == null ? void 0 : c(Y, X);
|
|
41029
41029
|
const Z = ((ee = (Q = P["x-action-settings"]) == null ? void 0 : Q.onSuccess) == null ? void 0 : ee.blocksToRefresh) || [];
|
|
41030
41030
|
Z.length > 0 && V().forEach((te) => {
|
|
41031
|
-
var
|
|
41031
|
+
var ne;
|
|
41032
41032
|
if (Z.includes(te.uid))
|
|
41033
41033
|
try {
|
|
41034
|
-
(
|
|
41035
|
-
} catch (
|
|
41036
|
-
console.error("Failed to refresh block:", te.uid,
|
|
41034
|
+
(ne = te.service) == null || ne.refresh();
|
|
41035
|
+
} catch (se) {
|
|
41036
|
+
console.error("Failed to refresh block:", te.uid, se);
|
|
41037
41037
|
}
|
|
41038
41038
|
});
|
|
41039
41039
|
})), [c, P, V]);
|
|
@@ -41072,8 +41072,8 @@ const ActionLink = withDynamicSchemaProps(
|
|
|
41072
41072
|
}),
|
|
41073
41073
|
{ displayName: "Action" }
|
|
41074
41074
|
), InternalAction = observer$1(function e(t) {
|
|
41075
|
-
var
|
|
41076
|
-
const
|
|
41075
|
+
var ue, Ce, de, me, fe;
|
|
41076
|
+
const ge = t, {
|
|
41077
41077
|
containerRefKey: o,
|
|
41078
41078
|
fieldSchema: n,
|
|
41079
41079
|
designable: r,
|
|
@@ -41101,7 +41101,7 @@ const ActionLink = withDynamicSchemaProps(
|
|
|
41101
41101
|
setSubmitted: D,
|
|
41102
41102
|
getAriaLabel: $,
|
|
41103
41103
|
parentRecordData: j
|
|
41104
|
-
} =
|
|
41104
|
+
} = ge, B = W(ge, [
|
|
41105
41105
|
"containerRefKey",
|
|
41106
41106
|
"fieldSchema",
|
|
41107
41107
|
"designable",
|
|
@@ -41129,25 +41129,25 @@ const ActionLink = withDynamicSchemaProps(
|
|
|
41129
41129
|
"setSubmitted",
|
|
41130
41130
|
"getAriaLabel",
|
|
41131
41131
|
"parentRecordData"
|
|
41132
|
-
]), [R, O] = useState(!1), { wrapSSR: N, componentCls: M, hashId: L } = useStyles$8(), [q, z] = useState(!1), V = n["x-toolbar-props"] || n["x-designer-props"], H = (
|
|
41132
|
+
]), [R, O] = useState(!1), { wrapSSR: N, componentCls: M, hashId: L } = useStyles$8(), [q, z] = useState(!1), V = n["x-toolbar-props"] || n["x-designer-props"], H = (ue = n == null ? void 0 : n["x-component-props"]) == null ? void 0 : ue.openMode, G = (Ce = n == null ? void 0 : n["x-component-props"]) == null ? void 0 : Ce.openSize, U = (de = n == null ? void 0 : n["x-component-props"]) == null ? void 0 : de.refreshDataBlockRequest, { modal: K } = App.useApp(), J = useForm(), Y = useACLActionParamsContext(), {
|
|
41133
41133
|
run: X,
|
|
41134
41134
|
element: Z,
|
|
41135
41135
|
disabled: Q,
|
|
41136
41136
|
loading: ee
|
|
41137
|
-
} = (P == null ? void 0 : P(T)) || {}, te = J.disabled || i.disabled || ((
|
|
41138
|
-
var
|
|
41137
|
+
} = (P == null ? void 0 : P(T)) || {}, te = J.disabled || i.disabled || ((me = i.data) == null ? void 0 : me.disabled) || F || Q, ne = useMemo(() => {
|
|
41138
|
+
var he;
|
|
41139
41139
|
return I(f({}, v), {
|
|
41140
|
-
opacity: r && (((
|
|
41140
|
+
opacity: r && (((he = i == null ? void 0 : i.data) == null ? void 0 : he.hidden) || !Y) && 0.1,
|
|
41141
41141
|
color: te ? "rgba(0, 0, 0, 0.25)" : v == null ? void 0 : v.color
|
|
41142
41142
|
});
|
|
41143
|
-
}, [Y, r, (
|
|
41143
|
+
}, [Y, r, (fe = i == null ? void 0 : i.data) == null ? void 0 : fe.hidden, v, te]), se = {
|
|
41144
41144
|
designable: r,
|
|
41145
41145
|
field: i,
|
|
41146
41146
|
aclCtx: Y,
|
|
41147
41147
|
icon: a,
|
|
41148
41148
|
loading: typeof ee == "boolean" ? ee : l,
|
|
41149
41149
|
disabled: te,
|
|
41150
|
-
buttonStyle:
|
|
41150
|
+
buttonStyle: ne,
|
|
41151
41151
|
handleMouseEnter: c,
|
|
41152
41152
|
tarComponent: u,
|
|
41153
41153
|
designerProps: V,
|
|
@@ -41168,18 +41168,18 @@ const ActionLink = withDynamicSchemaProps(
|
|
|
41168
41168
|
setSubmitted: D,
|
|
41169
41169
|
confirmTitle: x,
|
|
41170
41170
|
title: C
|
|
41171
|
-
},
|
|
41172
|
-
(
|
|
41173
|
-
O == null || O(
|
|
41171
|
+
}, ae = useCallback(
|
|
41172
|
+
(he) => {
|
|
41173
|
+
O == null || O(he), w == null || w(he);
|
|
41174
41174
|
},
|
|
41175
41175
|
[w]
|
|
41176
41176
|
);
|
|
41177
|
-
let
|
|
41177
|
+
let ce = /* @__PURE__ */ jsx(PopupVisibleProvider, { visible: !1, children: /* @__PURE__ */ jsxs(
|
|
41178
41178
|
ActionContextProvider,
|
|
41179
41179
|
{
|
|
41180
|
-
button: RenderButton(
|
|
41180
|
+
button: RenderButton(se),
|
|
41181
41181
|
visible: R || A,
|
|
41182
|
-
setVisible:
|
|
41182
|
+
setVisible: ae,
|
|
41183
41183
|
formValueChanged: q,
|
|
41184
41184
|
setFormValueChanged: z,
|
|
41185
41185
|
openMode: H,
|
|
@@ -41189,13 +41189,13 @@ const ActionLink = withDynamicSchemaProps(
|
|
|
41189
41189
|
setSubmitted: D,
|
|
41190
41190
|
children: [
|
|
41191
41191
|
b && /* @__PURE__ */ jsx(NocoBaseRecursionField, { basePath: i.address, onlyRenderProperties: !0, schema: n }),
|
|
41192
|
-
!b && /* @__PURE__ */ jsx(RenderButton, f({},
|
|
41192
|
+
!b && /* @__PURE__ */ jsx(RenderButton, f({}, se)),
|
|
41193
41193
|
/* @__PURE__ */ jsx(VariablePopupRecordProvider, { children: !b && t.children }),
|
|
41194
41194
|
Z
|
|
41195
41195
|
]
|
|
41196
41196
|
}
|
|
41197
41197
|
) });
|
|
41198
|
-
return isBulkEditAction(n) && (
|
|
41198
|
+
return isBulkEditAction(n) && (ce = /* @__PURE__ */ jsx(TabsContextProvider, { children: ce })), N(y ? /* @__PURE__ */ jsx(TreeRecordProvider, { parent: S, children: ce }) : ce);
|
|
41199
41199
|
});
|
|
41200
41200
|
InternalAction.displayName = "InternalAction";
|
|
41201
41201
|
Action.Popover = function e(t) {
|
|
@@ -41309,11 +41309,11 @@ const RenderButton = ({
|
|
|
41309
41309
|
);
|
|
41310
41310
|
if (!K.disabled && K.aclCtx) {
|
|
41311
41311
|
const ee = () => {
|
|
41312
|
-
var te,
|
|
41312
|
+
var te, ne;
|
|
41313
41313
|
K.onClick ? K.onClick(G, () => {
|
|
41314
|
-
var
|
|
41315
|
-
K.refreshDataBlockRequest !== !1 && ((
|
|
41316
|
-
}) : isBulkEditAction(K.fieldSchema) || !K.isPopupVisibleControlledByURL() ? (K.setVisible(!0), (te = K.run) == null || te.call(K)) : ["view", "update", "create", "customize:popup"].includes(K.fieldSchema["x-action"]) && K.fieldSchema["x-uid"] ? M.current() : (K.setVisible(!0), (
|
|
41314
|
+
var se, ae, ce;
|
|
41315
|
+
K.refreshDataBlockRequest !== !1 && ((se = K.setSubmitted) == null || se.call(K, !0), (ce = (ae = K.getDataBlockRequest()) == null ? void 0 : ae.refresh) == null || ce.call(ae));
|
|
41316
|
+
}) : isBulkEditAction(K.fieldSchema) || !K.isPopupVisibleControlledByURL() ? (K.setVisible(!0), (te = K.run) == null || te.call(K)) : ["view", "update", "create", "customize:popup"].includes(K.fieldSchema["x-action"]) && K.fieldSchema["x-uid"] ? M.current() : (K.setVisible(!0), (ne = K.run) == null || ne.call(K));
|
|
41317
41317
|
};
|
|
41318
41318
|
K.confirmEnable !== !1 && K.confirmContent ? (yield (X = q == null ? void 0 : q.submit) == null ? void 0 : X.call(q), K.modal.confirm({
|
|
41319
41319
|
title: K.t(J, { title: K.confirmTitleProp || K.title || ((Z = K.field) == null ? void 0 : Z.title) }),
|
|
@@ -41928,8 +41928,8 @@ const getValues = (e, t) => castArray(e).filter((o) => o != null).map((o) => typ
|
|
|
41928
41928
|
if ((Q = j == null ? void 0 : j.uiSchema) != null && Q.enum)
|
|
41929
41929
|
if (Array.isArray(Z))
|
|
41930
41930
|
Z = Z.map((ee, te) => {
|
|
41931
|
-
const
|
|
41932
|
-
return
|
|
41931
|
+
const ne = j.uiSchema.enum.find((se) => se.value === ee);
|
|
41932
|
+
return ne ? /* @__PURE__ */ jsx(Tag, { role: "button", color: ne.color, style: { marginRight: 3 }, children: (ne == null ? void 0 : ne.label) || ee }, te) : /* @__PURE__ */ jsx(Tag, { role: "button", children: ee }, ee);
|
|
41933
41933
|
}).reverse();
|
|
41934
41934
|
else {
|
|
41935
41935
|
const ee = j.uiSchema.enum.find((te) => te.value === Z);
|
|
@@ -46787,7 +46787,7 @@ const AssignedFieldInner = (e) => {
|
|
|
46787
46787
|
targetFieldSchema: l
|
|
46788
46788
|
}
|
|
46789
46789
|
) });
|
|
46790
|
-
}, AssignedField = (
|
|
46790
|
+
}, AssignedField = withDynamicSchemaProps(AssignedFieldInner);
|
|
46791
46791
|
function useAclCheck(e) {
|
|
46792
46792
|
return useAclCheckFn()(e);
|
|
46793
46793
|
}
|
|
@@ -47639,8 +47639,8 @@ const useColumnsDeepMemoized = (e) => {
|
|
|
47639
47639
|
InternalNocoBaseTable.displayName = "InternalNocoBaseTable";
|
|
47640
47640
|
const Table$1 = withDynamicSchemaProps(
|
|
47641
47641
|
observer$1((e) => {
|
|
47642
|
-
var
|
|
47643
|
-
const { token: t } = useToken$1(),
|
|
47642
|
+
var he, xe, ye;
|
|
47643
|
+
const { token: t } = useToken$1(), de = omit(e, ["onBlur", "onFocus", "value"]), { pagination: o, useProps: n } = de, r = W(de, ["pagination", "useProps"]), me = (n == null ? void 0 : n()) || {}, { pagination: i } = me, a = W(me, ["pagination"]), fe = f(f({}, r), a), {
|
|
47644
47644
|
dragSort: l = !1,
|
|
47645
47645
|
showIndex: c = !0,
|
|
47646
47646
|
onRowSelectionChange: u,
|
|
@@ -47652,7 +47652,7 @@ const Table$1 = withDynamicSchemaProps(
|
|
|
47652
47652
|
loading: x,
|
|
47653
47653
|
onClickRow: b,
|
|
47654
47654
|
enableIndexColumn: y
|
|
47655
|
-
} =
|
|
47655
|
+
} = fe, S = W(fe, [
|
|
47656
47656
|
"dragSort",
|
|
47657
47657
|
"showIndex",
|
|
47658
47658
|
"onRowSelectionChange",
|
|
@@ -47664,8 +47664,8 @@ const Table$1 = withDynamicSchemaProps(
|
|
|
47664
47664
|
"loading",
|
|
47665
47665
|
"onClickRow",
|
|
47666
47666
|
"enableIndexColumn"
|
|
47667
|
-
]), C = useArrayField(S), v = useFieldSchema(), { size: F = "small" } = (v == null ? void 0 : v["x-component-props"]) || {}, P = useCollection(), A = ((
|
|
47668
|
-
})), j = usePaginationProps$2(o, i), B = useTableColumns$1(S, j), [R, O] = useState(() => w ? D : []), [N, M] = useState(((
|
|
47667
|
+
]), C = useArrayField(S), v = useFieldSchema(), { size: F = "small" } = (v == null ? void 0 : v["x-component-props"]) || {}, P = useCollection(), A = ((he = v == null ? void 0 : v.parent) == null ? void 0 : he["x-decorator"]) === "TableSelectorProvider" ? useTableSelectorContext() : useTableBlockContext(), { expandFlag: w, allIncludesChildren: D } = A, $ = useMemoizedFn(S.onRowDragEnd || (() => {
|
|
47668
|
+
})), j = usePaginationProps$2(o, i), B = useTableColumns$1(S, j), [R, O] = useState(() => w ? D : []), [N, M] = useState(((xe = C == null ? void 0 : C.data) == null ? void 0 : xe.selectedRowKeys) || []), [L, q] = useState([]), z = (p == null ? void 0 : p.type) !== "none", V = useRef(/* @__PURE__ */ new Map()), H = useMemo(() => css`
|
|
47669
47669
|
& > td {
|
|
47670
47670
|
background-color: ${t.controlItemBgActive} !important;
|
|
47671
47671
|
}
|
|
@@ -47673,8 +47673,8 @@ const Table$1 = withDynamicSchemaProps(
|
|
|
47673
47673
|
background-color: ${t.controlItemBgActiveHover} !important;
|
|
47674
47674
|
}
|
|
47675
47675
|
`, [t.controlItemBgActive, t.controlItemBgActiveHover]), G = useMemo(() => b ? H : "", [H, b]), U = useMemo(() => b ? (ie, oe) => ({
|
|
47676
|
-
onClick: (
|
|
47677
|
-
isPortalInBody(
|
|
47676
|
+
onClick: (re) => {
|
|
47677
|
+
isPortalInBody(re.target) || b(ie, q, L);
|
|
47678
47678
|
},
|
|
47679
47679
|
rowIndex: oe
|
|
47680
47680
|
}) : null, [b, L]);
|
|
@@ -47694,21 +47694,21 @@ const Table$1 = withDynamicSchemaProps(
|
|
|
47694
47694
|
}, []), J = useCallback(
|
|
47695
47695
|
(ie) => {
|
|
47696
47696
|
var oe;
|
|
47697
|
-
return Array.isArray(m) ? m.map((
|
|
47698
|
-
var
|
|
47699
|
-
return ((
|
|
47697
|
+
return Array.isArray(m) ? m.map((re) => {
|
|
47698
|
+
var le;
|
|
47699
|
+
return ((le = ie[re]) == null ? void 0 : le.toString()) || "";
|
|
47700
47700
|
}).join("-") : typeof m == "string" ? ie[m] : (oe = (m != null ? m : K)(ie)) == null ? void 0 : oe.toString();
|
|
47701
47701
|
},
|
|
47702
47702
|
[JSON.stringify(m), K]
|
|
47703
47703
|
), Y = useMemo(() => (Array.isArray(C == null ? void 0 : C.value) ? C.value : []).filter(Boolean), [C == null ? void 0 : C.value, (ye = C == null ? void 0 : C.value) == null ? void 0 : ye.length]), X = useMemo(() => (ie) => {
|
|
47704
|
-
const oe = useCallback((
|
|
47704
|
+
const oe = useCallback((re) => {
|
|
47705
47705
|
var Te, Fe, Pe, Ie, ke, Ae;
|
|
47706
|
-
if (!
|
|
47706
|
+
if (!re.active || !re.over) {
|
|
47707
47707
|
console.warn("move cancel");
|
|
47708
47708
|
return;
|
|
47709
47709
|
}
|
|
47710
|
-
const
|
|
47711
|
-
C.move(
|
|
47710
|
+
const le = (Pe = (Fe = (Te = re.active) == null ? void 0 : Te.data.current) == null ? void 0 : Fe.sortable) == null ? void 0 : Pe.index, pe = (Ae = (ke = (Ie = re.over) == null ? void 0 : Ie.data.current) == null ? void 0 : ke.sortable) == null ? void 0 : Ae.index, be = C.value[le] || re.active, ve = C.value[pe] || re.over;
|
|
47711
|
+
C.move(le, pe), $({ from: be, to: ve });
|
|
47712
47712
|
}, []);
|
|
47713
47713
|
return /* @__PURE__ */ jsx(DndContext, { onDragEnd: oe, children: /* @__PURE__ */ jsx("tbody", f({}, ie)) });
|
|
47714
47714
|
}, [C, $]);
|
|
@@ -47736,22 +47736,22 @@ const Table$1 = withDynamicSchemaProps(
|
|
|
47736
47736
|
"aria-label": "checkbox"
|
|
47737
47737
|
};
|
|
47738
47738
|
},
|
|
47739
|
-
renderCell: (ie, oe,
|
|
47739
|
+
renderCell: (ie, oe, re, le) => {
|
|
47740
47740
|
if (!l && !c)
|
|
47741
|
-
return
|
|
47742
|
-
const
|
|
47743
|
-
return
|
|
47741
|
+
return le;
|
|
47742
|
+
const pe = j == null ? void 0 : j.current, be = (j == null ? void 0 : j.pageSize) || 20;
|
|
47743
|
+
return pe ? re = re + (pe - 1) * be + 1 : re = re + 1, oe.__index && (re = extractIndex$1(oe.__index)), /* @__PURE__ */ jsxs(
|
|
47744
47744
|
"div",
|
|
47745
47745
|
{
|
|
47746
47746
|
role: "button",
|
|
47747
|
-
"aria-label": `table-index-${
|
|
47747
|
+
"aria-label": `table-index-${re}`,
|
|
47748
47748
|
className: classNames(ie ? "checked" : null, rowSelectCheckboxWrapperClass$1, {
|
|
47749
47749
|
[rowSelectCheckboxWrapperClassHover$1]: z
|
|
47750
47750
|
}),
|
|
47751
47751
|
children: [
|
|
47752
47752
|
/* @__PURE__ */ jsxs("div", { className: classNames(ie ? "checked" : null, rowSelectCheckboxContentClass$1), children: [
|
|
47753
47753
|
l && /* @__PURE__ */ jsx(SortHandle$1, { id: J(oe) }),
|
|
47754
|
-
c && /* @__PURE__ */ jsx(TableIndex$3, { index:
|
|
47754
|
+
c && /* @__PURE__ */ jsx(TableIndex$3, { index: re })
|
|
47755
47755
|
] }),
|
|
47756
47756
|
z && /* @__PURE__ */ jsx(
|
|
47757
47757
|
"div",
|
|
@@ -47761,7 +47761,7 @@ const Table$1 = withDynamicSchemaProps(
|
|
|
47761
47761
|
ie ? "checked" : null,
|
|
47762
47762
|
rowSelectCheckboxCheckedClassHover$1
|
|
47763
47763
|
),
|
|
47764
|
-
children:
|
|
47764
|
+
children: le
|
|
47765
47765
|
}
|
|
47766
47766
|
)
|
|
47767
47767
|
]
|
|
@@ -47785,42 +47785,42 @@ const Table$1 = withDynamicSchemaProps(
|
|
|
47785
47785
|
]
|
|
47786
47786
|
), te = useCallback(
|
|
47787
47787
|
({ children: ie }) => {
|
|
47788
|
-
var oe,
|
|
47788
|
+
var oe, re;
|
|
47789
47789
|
return l ? React.createElement(
|
|
47790
47790
|
SortableContext$1,
|
|
47791
47791
|
{
|
|
47792
|
-
items: ((
|
|
47792
|
+
items: ((re = (oe = C.value) == null ? void 0 : oe.map) == null ? void 0 : re.call(oe, J)) || []
|
|
47793
47793
|
},
|
|
47794
47794
|
ie
|
|
47795
47795
|
) : React.createElement(React.Fragment, {}, ie);
|
|
47796
47796
|
},
|
|
47797
47797
|
[C, l, J]
|
|
47798
|
-
), { height:
|
|
47798
|
+
), { height: ne, tableSizeRefCallback: se } = useTableSize(), ae = useMemo(() => ({
|
|
47799
47799
|
x: "max-content"
|
|
47800
|
-
}), []),
|
|
47800
|
+
}), []), ce = useMemo(() => ({
|
|
47801
47801
|
x: "max-content",
|
|
47802
|
-
y: Y.length > 0 ?
|
|
47803
|
-
}), [
|
|
47802
|
+
y: Y.length > 0 ? ne : void 0
|
|
47803
|
+
}), [ne, ae, Y]), ge = useCallback(
|
|
47804
47804
|
(ie) => L.includes(ie[m]) ? G : "",
|
|
47805
47805
|
[L, G, JSON.stringify(m)]
|
|
47806
|
-
),
|
|
47806
|
+
), ue = useCallback(
|
|
47807
47807
|
(ie, oe) => {
|
|
47808
|
-
const
|
|
47809
|
-
O(
|
|
47808
|
+
const re = ie ? [...R, oe[P.getPrimaryKey()]] : R.filter((le) => oe[P.getPrimaryKey()] !== le);
|
|
47809
|
+
O(re), g == null || g(ie, oe);
|
|
47810
47810
|
},
|
|
47811
47811
|
[R, g, P]
|
|
47812
47812
|
), Ce = useMemo(() => ({
|
|
47813
|
-
onExpand:
|
|
47813
|
+
onExpand: ue,
|
|
47814
47814
|
expandedRowKeys: R
|
|
47815
|
-
}), [R,
|
|
47815
|
+
}), [R, ue]);
|
|
47816
47816
|
return (
|
|
47817
47817
|
// If spinning is set to undefined, it will cause the subtable to always display loading, so we need to convert it here
|
|
47818
47818
|
/* @__PURE__ */ jsx(Spin, { spinning: !!x, children: /* @__PURE__ */ jsx(
|
|
47819
47819
|
InternalNocoBaseTable,
|
|
47820
47820
|
I(f(f({
|
|
47821
|
-
tableHeight:
|
|
47821
|
+
tableHeight: ne,
|
|
47822
47822
|
SortableWrapper: te,
|
|
47823
|
-
tableSizeRefCallback:
|
|
47823
|
+
tableSizeRefCallback: se,
|
|
47824
47824
|
defaultRowKey: K,
|
|
47825
47825
|
dataSource: Y
|
|
47826
47826
|
}, S), ee), {
|
|
@@ -47828,8 +47828,8 @@ const Table$1 = withDynamicSchemaProps(
|
|
|
47828
47828
|
components: Z,
|
|
47829
47829
|
onTableChange: d,
|
|
47830
47830
|
onRow: U,
|
|
47831
|
-
rowClassName:
|
|
47832
|
-
scroll:
|
|
47831
|
+
rowClassName: ge,
|
|
47832
|
+
scroll: ce,
|
|
47833
47833
|
columns: B,
|
|
47834
47834
|
expandable: Ce,
|
|
47835
47835
|
field: C,
|
|
@@ -55361,10 +55361,10 @@ const useCurrentAppInfo = () => useContext(CurrentAppInfoContext), CurrentAppInf
|
|
|
55361
55361
|
mode: "tags",
|
|
55362
55362
|
value: ee,
|
|
55363
55363
|
onChange: (te) => {
|
|
55364
|
-
const
|
|
55365
|
-
new Set(te.map((
|
|
55364
|
+
const ne = Array.from(
|
|
55365
|
+
new Set(te.map((se) => String(se).trim()).filter(Boolean))
|
|
55366
55366
|
);
|
|
55367
|
-
U.value === "allow" ? P(j.key, "tlds", { allow:
|
|
55367
|
+
U.value === "allow" ? P(j.key, "tlds", { allow: ne }) : P(j.key, "tlds", { deny: ne });
|
|
55368
55368
|
},
|
|
55369
55369
|
tokenSeparators: [",", " ", `
|
|
55370
55370
|
`, " "],
|
|
@@ -66483,16 +66483,16 @@ const getKey = (e) => `${e.params.viewUid}_${e.index}`, FlowRoute = () => {
|
|
|
66483
66483
|
},
|
|
66484
66484
|
handler(e, t) {
|
|
66485
66485
|
return E(this, null, function* () {
|
|
66486
|
-
var b, y, S, C, v, F, P, T, A, w, D, $, j, B, R, O, N, M, L, q, z, V, H, G, U, K, J, Y, X, Z, Q, ee, te,
|
|
66486
|
+
var b, y, S, C, v, F, P, T, A, w, D, $, j, B, R, O, N, M, L, q, z, V, H, G, U, K, J, Y, X, Z, Q, ee, te, ne, se;
|
|
66487
66487
|
if (t != null && t.uid && t.uid !== e.model.uid) {
|
|
66488
|
-
const
|
|
66488
|
+
const ae = ((y = (b = e.model) == null ? void 0 : b.getInputArgs) == null ? void 0 : y.call(b)) || {};
|
|
66489
66489
|
yield e.openView(t.uid, I(f({}, t), {
|
|
66490
66490
|
target: e.inputArgs.target || e.layoutContentElement,
|
|
66491
|
-
dataSourceKey: (S = t.dataSourceKey) != null ? S :
|
|
66492
|
-
collectionName: (C = t.collectionName) != null ? C :
|
|
66493
|
-
associationName: (v = t.associationName) != null ? v :
|
|
66494
|
-
filterByTk: (F = t.filterByTk) != null ? F :
|
|
66495
|
-
sourceId: (P = t.sourceId) != null ? P :
|
|
66491
|
+
dataSourceKey: (S = t.dataSourceKey) != null ? S : ae.dataSourceKey,
|
|
66492
|
+
collectionName: (C = t.collectionName) != null ? C : ae.collectionName,
|
|
66493
|
+
associationName: (v = t.associationName) != null ? v : ae.associationName,
|
|
66494
|
+
filterByTk: (F = t.filterByTk) != null ? F : ae.filterByTk,
|
|
66495
|
+
sourceId: (P = t.sourceId) != null ? P : ae.sourceId,
|
|
66496
66496
|
tabUid: t.tabUid
|
|
66497
66497
|
}));
|
|
66498
66498
|
return;
|
|
@@ -66501,7 +66501,7 @@ const getKey = (e) => `${e.params.viewUid}_${e.index}`, FlowRoute = () => {
|
|
|
66501
66501
|
o.filterByTk = o.filterByTk || t.filterByTk || (n == null ? void 0 : n.filterByTk), o.sourceId = o.sourceId || t.sourceId || (n == null ? void 0 : n.sourceId), o.tabUid = o.tabuid || t.tabUid || (n == null ? void 0 : n.tabUid);
|
|
66502
66502
|
const r = (A = o.navigation) != null ? A : t.navigation;
|
|
66503
66503
|
if (r !== !1 && !e.inputArgs.navigation && (w = e.view) != null && w.navigation) {
|
|
66504
|
-
const
|
|
66504
|
+
const ae = (D = e.inputArgs) != null && D.isMobileLayout ? "embed" : (($ = e.inputArgs) == null ? void 0 : $.mode) || (t == null ? void 0 : t.mode) || "drawer", ce = I(f({}, e.inputArgs), {
|
|
66505
66505
|
dataSourceKey: (j = t.dataSourceKey) != null ? j : e.inputArgs.dataSourceKey,
|
|
66506
66506
|
collectionName: (B = t.collectionName) != null ? B : e.inputArgs.collectionName,
|
|
66507
66507
|
associationName: (R = t.associationName) != null ? R : e.inputArgs.associationName,
|
|
@@ -66509,21 +66509,21 @@ const getKey = (e) => `${e.params.viewUid}_${e.index}`, FlowRoute = () => {
|
|
|
66509
66509
|
sourceId: (N = o.sourceId) != null ? N : t.sourceId,
|
|
66510
66510
|
tabUid: (M = o.tabUid) != null ? M : t.tabUid,
|
|
66511
66511
|
viewUid: ((q = (L = e.model.context) == null ? void 0 : L.inputArgs) == null ? void 0 : q.viewUid) || e.model.uid
|
|
66512
|
-
}),
|
|
66513
|
-
type:
|
|
66514
|
-
inputArgs:
|
|
66512
|
+
}), ge = {
|
|
66513
|
+
type: ae,
|
|
66514
|
+
inputArgs: ce,
|
|
66515
66515
|
navigation: (z = e.view) == null ? void 0 : z.navigation,
|
|
66516
66516
|
preventClose: !!(t != null && t.preventClose),
|
|
66517
66517
|
engineCtx: e.engine.context
|
|
66518
66518
|
};
|
|
66519
|
-
e.model.context.defineProperty("view", { value:
|
|
66520
|
-
const
|
|
66519
|
+
e.model.context.defineProperty("view", { value: ge });
|
|
66520
|
+
const ue = {
|
|
66521
66521
|
viewUid: ((H = (V = e.model.context) == null ? void 0 : V.inputArgs) == null ? void 0 : H.viewUid) || e.model.uid,
|
|
66522
66522
|
filterByTk: (G = o.filterByTk) != null ? G : t.filterByTk,
|
|
66523
66523
|
sourceId: (U = o.sourceId) != null ? U : t.sourceId,
|
|
66524
66524
|
tabUid: (K = o.tabUid) != null ? K : t.tabUid
|
|
66525
66525
|
};
|
|
66526
|
-
e.view.navigation.navigateTo(
|
|
66526
|
+
e.view.navigation.navigateTo(ue);
|
|
66527
66527
|
return;
|
|
66528
66528
|
}
|
|
66529
66529
|
const i = {
|
|
@@ -66541,14 +66541,14 @@ const getKey = (e) => `${e.params.viewUid}_${e.index}`, FlowRoute = () => {
|
|
|
66541
66541
|
}, a = e.inputArgs.pageModelClass || t.pageModelClass || "ChildPageModel", l = e.inputArgs.mode || t.mode || "drawer", c = e.inputArgs.size || t.size || "medium";
|
|
66542
66542
|
let u = null, d = null, p = e.model.uid;
|
|
66543
66543
|
if (t.subModelKey) {
|
|
66544
|
-
const
|
|
66544
|
+
const ae = yield e.engine.loadOrCreateModel({
|
|
66545
66545
|
async: !0,
|
|
66546
66546
|
parentId: e.model.uid,
|
|
66547
66547
|
subKey: t.subModelKey,
|
|
66548
66548
|
subType: "object",
|
|
66549
66549
|
use: "FlowModel"
|
|
66550
66550
|
});
|
|
66551
|
-
|
|
66551
|
+
ae != null && ae.uid && (p = ae.uid);
|
|
66552
66552
|
}
|
|
66553
66553
|
const m = !!((J = e.inputArgs) != null && J.navigation), h = ((X = (Y = e.view) == null ? void 0 : Y.inputArgs) == null ? void 0 : X.openerUids) || o.openerUids || [], g = m ? o.openerUids || h : [...h, ((Q = (Z = e.model.context) == null ? void 0 : Z.inputArgs) == null ? void 0 : Q.viewUid) || e.model.uid], x = I(f(f({}, e.inputArgs), o), {
|
|
66554
66554
|
dataSourceKey: t.dataSourceKey,
|
|
@@ -66557,7 +66557,7 @@ const getKey = (e) => `${e.params.viewUid}_${e.index}`, FlowRoute = () => {
|
|
|
66557
66557
|
tabUid: (ee = o.tabUid) != null ? ee : t.tabUid,
|
|
66558
66558
|
openerUids: g
|
|
66559
66559
|
});
|
|
66560
|
-
x.filterByTk = (te = o.filterByTk) != null ? te : t.filterByTk, x.sourceId = (
|
|
66560
|
+
x.filterByTk = (te = o.filterByTk) != null ? te : t.filterByTk, x.sourceId = (ne = o.sourceId) != null ? ne : t.sourceId, yield e.viewer.open({
|
|
66561
66561
|
type: e.inputArgs.isMobileLayout ? "embed" : l,
|
|
66562
66562
|
// 移动端中只需要显示子页面
|
|
66563
66563
|
inputArgs: x,
|
|
@@ -66566,28 +66566,28 @@ const getKey = (e) => `${e.params.viewUid}_${e.index}`, FlowRoute = () => {
|
|
|
66566
66566
|
inheritContext: !1,
|
|
66567
66567
|
target: e.inputArgs.target || e.layoutContentElement,
|
|
66568
66568
|
width: i[l][c],
|
|
66569
|
-
content: (
|
|
66569
|
+
content: (ae) => (e.inputArgs.closeRef && (e.inputArgs.closeRef.current = ae.close), e.inputArgs.updateRef && (e.inputArgs.updateRef.current = ae.update), /* @__PURE__ */ jsx(
|
|
66570
66570
|
FlowPage,
|
|
66571
66571
|
{
|
|
66572
66572
|
parentId: p,
|
|
66573
66573
|
pageModelClass: a,
|
|
66574
|
-
onModelLoaded: (
|
|
66575
|
-
var
|
|
66576
|
-
u =
|
|
66577
|
-
const
|
|
66578
|
-
d =
|
|
66579
|
-
const
|
|
66580
|
-
|
|
66581
|
-
get: () =>
|
|
66582
|
-
}),
|
|
66583
|
-
get: () =>
|
|
66584
|
-
}),
|
|
66574
|
+
onModelLoaded: (ce, ge) => {
|
|
66575
|
+
var me, fe, he, xe, ye, ie, oe, re;
|
|
66576
|
+
u = ce;
|
|
66577
|
+
const ue = ge || e.engine.getModel(u);
|
|
66578
|
+
d = ue || null;
|
|
66579
|
+
const Ce = (xe = (he = o.defineProperties) != null ? he : (fe = (me = e.model.context) == null ? void 0 : me.inputArgs) == null ? void 0 : fe.defineProperties) != null ? xe : {}, de = (re = (oe = o.defineMethods) != null ? oe : (ie = (ye = e.model.context) == null ? void 0 : ye.inputArgs) == null ? void 0 : ie.defineMethods) != null ? re : {};
|
|
66580
|
+
ue.context.defineProperty("currentView", {
|
|
66581
|
+
get: () => ae
|
|
66582
|
+
}), ue.context.defineProperty("view", {
|
|
66583
|
+
get: () => ae
|
|
66584
|
+
}), ue.context.defineProperty("closable", {
|
|
66585
66585
|
get: () => l !== "embed"
|
|
66586
|
-
}), Object.entries(
|
|
66587
|
-
|
|
66588
|
-
}), Object.entries(
|
|
66589
|
-
|
|
66590
|
-
}),
|
|
66586
|
+
}), Object.entries(Ce).forEach(([le, pe]) => {
|
|
66587
|
+
ue.context.defineProperty(le, pe);
|
|
66588
|
+
}), Object.entries(de).forEach(([le, pe]) => {
|
|
66589
|
+
ue.context.defineMethod(le, pe);
|
|
66590
|
+
}), ue.invalidateAutoFlowCache(!0), ue._rerunLastAutoRun();
|
|
66591
66591
|
}
|
|
66592
66592
|
}
|
|
66593
66593
|
)),
|
|
@@ -66601,16 +66601,16 @@ const getKey = (e) => `${e.params.viewUid}_${e.index}`, FlowRoute = () => {
|
|
|
66601
66601
|
}
|
|
66602
66602
|
},
|
|
66603
66603
|
onClose: () => {
|
|
66604
|
-
var
|
|
66605
|
-
const
|
|
66604
|
+
var ce, ge;
|
|
66605
|
+
const ae = ((ce = e.inputArgs) == null ? void 0 : ce.navigation) || ((ge = e.view) == null ? void 0 : ge.navigation);
|
|
66606
66606
|
if (u) {
|
|
66607
|
-
const
|
|
66608
|
-
|
|
66607
|
+
const ue = d || e.model.flowEngine.getModel(u);
|
|
66608
|
+
ue == null || ue.invalidateAutoFlowCache(!0);
|
|
66609
66609
|
}
|
|
66610
|
-
r !== !1 &&
|
|
66610
|
+
r !== !1 && ae != null && ae.back && ae.back();
|
|
66611
66611
|
},
|
|
66612
66612
|
onOpen: e.inputArgs.onOpen
|
|
66613
|
-
});
|
|
66613
|
+
}), yield (se = e.resource) == null ? void 0 : se.refresh();
|
|
66614
66614
|
});
|
|
66615
66615
|
}
|
|
66616
66616
|
}), InjectableRendingEventTrigger = (n) => {
|
|
@@ -67807,7 +67807,7 @@ const CodeEditor = (e) => {
|
|
|
67807
67807
|
});
|
|
67808
67808
|
}
|
|
67809
67809
|
}), parseMarkdown = _.memoize((e) => E(void 0, null, function* () {
|
|
67810
|
-
return e && (yield import("./md-
|
|
67810
|
+
return e && (yield import("./md-oH2RssNY.mjs")).default.render(e);
|
|
67811
67811
|
}));
|
|
67812
67812
|
function useParseMarkdown(e) {
|
|
67813
67813
|
const [t, o] = useState(""), [n, r] = useState(!0);
|
|
@@ -68775,7 +68775,7 @@ const displayFieldComponent = defineAction({
|
|
|
68775
68775
|
},
|
|
68776
68776
|
handler(e, t) {
|
|
68777
68777
|
return E(this, null, function* () {
|
|
68778
|
-
t.use !== e.model.subModels.field.use &&
|
|
68778
|
+
t.use !== e.model.subModels.field.use && e.model.setStepParams(e.flowKey, "model", { use: e.model.subModels.field.use });
|
|
68779
68779
|
});
|
|
68780
68780
|
}
|
|
68781
68781
|
}), fieldComponent = defineAction({
|
|
@@ -69026,7 +69026,7 @@ const validation = defineAction({
|
|
|
69026
69026
|
}
|
|
69027
69027
|
return p(T), () => {
|
|
69028
69028
|
var ee, te;
|
|
69029
|
-
(te = (ee = T.subModels.fields).forEach) == null || te.call(ee, (
|
|
69029
|
+
(te = (ee = T.subModels.fields).forEach) == null || te.call(ee, (ne) => ne.remove()), T.remove();
|
|
69030
69030
|
};
|
|
69031
69031
|
}, [r, i, a, l, u, n]), React.useEffect(() => {
|
|
69032
69032
|
var v, F, P, T;
|
|
@@ -72738,7 +72738,6 @@ FormSubmitActionModel.registerFlow({
|
|
|
72738
72738
|
saveResource: {
|
|
72739
72739
|
handler(e, t) {
|
|
72740
72740
|
return E(this, null, function* () {
|
|
72741
|
-
var i;
|
|
72742
72741
|
if (!(e != null && e.resource))
|
|
72743
72742
|
throw new Error("Resource is not initialized");
|
|
72744
72743
|
if (!e.blockModel)
|
|
@@ -72746,28 +72745,26 @@ FormSubmitActionModel.registerFlow({
|
|
|
72746
72745
|
const o = e.resource, n = e.blockModel;
|
|
72747
72746
|
try {
|
|
72748
72747
|
yield n.form.validateFields();
|
|
72749
|
-
const
|
|
72748
|
+
const r = n.form.getFieldsValue();
|
|
72750
72749
|
if (o instanceof SingleRecordResource) {
|
|
72751
72750
|
if (n instanceof EditFormModel) {
|
|
72752
|
-
const
|
|
72753
|
-
|
|
72751
|
+
const i = o.getMeta("currentFilterByTk");
|
|
72752
|
+
i ? o.setFilterByTk(i) : o.isNewRecord = !0;
|
|
72754
72753
|
}
|
|
72755
|
-
yield o.save(
|
|
72754
|
+
yield o.save(r, t.requestConfig), n instanceof EditFormModel ? (o.isNewRecord = !1, yield o.refresh()) : (n.form.resetFields(), n.emitter.emit("onFieldReset"));
|
|
72756
72755
|
} else if (o instanceof MultiRecordResource) {
|
|
72757
|
-
const
|
|
72758
|
-
if (!
|
|
72756
|
+
const i = o.getMeta("currentFilterByTk");
|
|
72757
|
+
if (!i) {
|
|
72759
72758
|
e.message.error(e.t("No filterByTk found for multi-record resource."));
|
|
72760
72759
|
return;
|
|
72761
72760
|
}
|
|
72762
|
-
yield o.update(
|
|
72761
|
+
yield o.update(i, r, t.requestConfig);
|
|
72763
72762
|
}
|
|
72764
|
-
} catch (
|
|
72765
|
-
e.message.error(e.t("Save failed")), console.error("Form submission error:",
|
|
72763
|
+
} catch (r) {
|
|
72764
|
+
e.message.error(e.t("Save failed")), console.error("Form submission error:", r);
|
|
72766
72765
|
return;
|
|
72767
72766
|
}
|
|
72768
|
-
e.message.success(e.t("Saved successfully"));
|
|
72769
|
-
const r = (i = e.currentFlow) == null ? void 0 : i.blockModel;
|
|
72770
|
-
r && r.resource.refresh(), e.view && e.view.close();
|
|
72767
|
+
e.message.success(e.t("Saved successfully")), e.view && e.view.close();
|
|
72771
72768
|
});
|
|
72772
72769
|
}
|
|
72773
72770
|
}
|
|
@@ -73769,10 +73766,10 @@ class AssignFormItemModel extends FormItemModel {
|
|
|
73769
73766
|
var y, S, C, v, F, P, T;
|
|
73770
73767
|
const [u, d] = React.useState(null);
|
|
73771
73768
|
React.useEffect(() => {
|
|
73772
|
-
var V, H, G, U, K, J, Y, X, Z, Q, ee, te,
|
|
73769
|
+
var V, H, G, U, K, J, Y, X, Z, Q, ee, te, ne, se, ae, ce, ge, ue, Ce;
|
|
73773
73770
|
if (!a)
|
|
73774
73771
|
return;
|
|
73775
|
-
const w = (((V = n == null ? void 0 : n.getFields) == null ? void 0 : V.call(n)) || []).find((
|
|
73772
|
+
const w = (((V = n == null ? void 0 : n.getFields) == null ? void 0 : V.call(n)) || []).find((de) => (de == null ? void 0 : de.name) === a);
|
|
73776
73773
|
n.getField(a);
|
|
73777
73774
|
const D = EditableItemModel.getDefaultBindingByField(o, w);
|
|
73778
73775
|
if (!D)
|
|
@@ -73801,23 +73798,23 @@ class AssignFormItemModel extends FormItemModel {
|
|
|
73801
73798
|
enumerable: !0,
|
|
73802
73799
|
get: () => O == null ? void 0 : O.resource
|
|
73803
73800
|
});
|
|
73804
|
-
const N = (
|
|
73805
|
-
if ((
|
|
73801
|
+
const N = (se = (ne = j == null ? void 0 : j.subModels) == null ? void 0 : ne.fields) == null ? void 0 : se[0], M = (ae = n == null ? void 0 : n.getField) == null ? void 0 : ae.call(n, r == null ? void 0 : r.fieldPath), L = M == null ? void 0 : M.type, q = M == null ? void 0 : M.interface, z = L === "belongsToMany" || L === "hasMany" || L === "belongsToArray" || q === "m2m" || q === "o2m" || q === "mbm";
|
|
73802
|
+
if ((ce = N == null ? void 0 : N.setProps) == null || ce.call(N, {
|
|
73806
73803
|
disabled: !1,
|
|
73807
73804
|
readPretty: !1,
|
|
73808
73805
|
pattern: "editable",
|
|
73809
73806
|
updateAssociation: !1,
|
|
73810
73807
|
multiple: z
|
|
73811
|
-
}), (
|
|
73812
|
-
const
|
|
73813
|
-
(Ce = N == null ? void 0 : N.setProps) == null || Ce.call(N, { fieldNames: { label:
|
|
73808
|
+
}), (ge = N == null ? void 0 : N.applyAutoFlows) == null || ge.call(N), ensureOptionsFromUiSchemaEnumIfAbsent(N, M), !((ue = N == null ? void 0 : N.props) != null && ue.fieldNames) && (M != null && M.targetCollection)) {
|
|
73809
|
+
const de = M.targetCollection, me = (M == null ? void 0 : M.targetKey) || (de == null ? void 0 : de.filterTargetKey) || "id";
|
|
73810
|
+
(Ce = N == null ? void 0 : N.setProps) == null || Ce.call(N, { fieldNames: { label: de == null ? void 0 : de.titleField, value: me } });
|
|
73814
73811
|
}
|
|
73815
73812
|
return d(j), () => {
|
|
73816
|
-
var
|
|
73817
|
-
(
|
|
73813
|
+
var de, me, fe, he;
|
|
73814
|
+
(fe = (me = (de = j == null ? void 0 : j.subModels) == null ? void 0 : de.fields) == null ? void 0 : me.forEach) == null || fe.call(me, (xe) => {
|
|
73818
73815
|
var ye;
|
|
73819
|
-
return (ye =
|
|
73820
|
-
}), (
|
|
73816
|
+
return (ye = xe == null ? void 0 : xe.remove) == null ? void 0 : ye.call(xe);
|
|
73817
|
+
}), (he = j == null ? void 0 : j.remove) == null || he.call(j);
|
|
73821
73818
|
};
|
|
73822
73819
|
}, []);
|
|
73823
73820
|
const p = (A) => (React.useEffect(() => {
|
|
@@ -76560,7 +76557,7 @@ TableColumnModel.registerFlow({
|
|
|
76560
76557
|
use: "titleField",
|
|
76561
76558
|
title: escapeT("Label field"),
|
|
76562
76559
|
beforeParamsSave: (e, t, o) => E(void 0, null, function* () {
|
|
76563
|
-
if (!e.collectionField.isAssociationField())
|
|
76560
|
+
if (!e.collectionField || !e.collectionField.isAssociationField())
|
|
76564
76561
|
return null;
|
|
76565
76562
|
if (t.label !== o.label) {
|
|
76566
76563
|
const n = e.collectionField.targetCollection, r = n.getField(t.label), i = e.model.constructor.getDefaultBindingByField(
|
|
@@ -76587,6 +76584,8 @@ TableColumnModel.registerFlow({
|
|
|
76587
76584
|
}),
|
|
76588
76585
|
handler(e, t) {
|
|
76589
76586
|
var o, n;
|
|
76587
|
+
if (!e.collectionField || !e.collectionField.isAssociationField())
|
|
76588
|
+
return null;
|
|
76590
76589
|
e.model.setProps(f({
|
|
76591
76590
|
titleField: t.label
|
|
76592
76591
|
}, (n = (o = e.collectionField.targetCollection) == null ? void 0 : o.getField(t.label)) == null ? void 0 : n.getComponentProps()));
|