@ximatai/muyun-web-app 0.26.4 → 0.26.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/dist/{EmployeeDetailWorkspaceView-BySbWjCV.js → EmployeeDetailWorkspaceView-rm9ujeiQ.js} +1 -1
- package/dist/{EmployeeManagementView-DvmDPxzN.js → EmployeeManagementView-DyYMWQ64.js} +486 -486
- package/dist/{MetadataOrchestrationView-2JxJkFEC.js → MetadataOrchestrationView-DaPNQML7.js} +203 -203
- package/dist/ModuleActionManagementView-BFoPGqzC.js +597 -0
- package/dist/{RoleAuthorizationView-CK6Vfdup.js → RoleAuthorizationView-qQvn7M75.js} +68 -68
- package/dist/{RoleDetailWorkspaceView-BPZcZy-r.js → RoleDetailWorkspaceView-C-vaKeZM.js} +1 -1
- package/dist/{RoleManagementView-B7TzzVOm.js → RoleManagementView-C3nxfub2.js} +486 -486
- package/dist/{SystemUserDetailWorkspaceView-BtEDyU-k.js → SystemUserDetailWorkspaceView-FIbfff00.js} +1 -1
- package/dist/SystemUserManagementView-m6vwJDxI.js +761 -0
- package/dist/{UserDetailWorkspaceView-B6fGrnQ7.js → UserDetailWorkspaceView-M--ndn6x.js} +1 -1
- package/dist/{UserManagementView-4IJeDSQS.js → UserManagementView-MSXf4fno.js} +302 -302
- package/dist/index.css +1 -1
- package/dist/index.js +2237 -2237
- package/dist/{pageRealtime-CJriNmzP.js → pageRealtime-4LXXvVW7.js} +14 -14
- package/dist/{platform-components-CgMBopmF.js → platform-components-_3KlZZf5.js} +1166 -1168
- package/dist/types/consumer/index.d.ts +1 -2
- package/dist/types/dynamic-page-runtime/dynamicModuleDetailStateModel.d.ts +12 -0
- package/dist/types/platform-components/RecordModeDrawer.vue.d.ts +14 -0
- package/dist/types/platform-components/recordFormFieldModel.d.ts +1 -1
- package/dist/{useUserSessionRows-DHsyr2Vy.js → useUserSessionRows-iAqK_cUy.js} +2 -2
- package/dist/workspaceViewSessions-DW0wbyQ_.js +1448 -0
- package/package.json +1 -1
- package/dist/ModuleActionManagementView-DRtYMXOK.js +0 -597
- package/dist/SystemUserManagementView-TKqj92zG.js +0 -761
- package/dist/workspaceViewSessions-BMbyO9O4.js +0 -1571
package/dist/{MetadataOrchestrationView-2JxJkFEC.js → MetadataOrchestrationView-DaPNQML7.js}
RENAMED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { $
|
|
2
|
-
import { Fragment as
|
|
1
|
+
import { $ as e, C as t, E as n, Et as r, F as i, J as a, K as o, P as s, St as c, V as l, X as u, _ as d, dt as f, ft as p, g as m, ht as h, it as g, mt as _, pt as v, q as y, rt as b, st as x, ut as S, z as C } from "./platform-components-_3KlZZf5.js";
|
|
2
|
+
import { Fragment as ee, computed as w, createBlock as T, createCommentVNode as te, createElementBlock as ne, createElementVNode as E, createTextVNode as D, createVNode as O, defineComponent as k, onMounted as re, openBlock as A, ref as j, toDisplayString as M, unref as N, watch as ie, withCtx as P, withModifiers as F } from "vue";
|
|
3
3
|
//#region src/views/metadataOrchestrationState.ts
|
|
4
|
-
function
|
|
5
|
-
let e =
|
|
4
|
+
function I() {
|
|
5
|
+
let e = j([]), t = j({}), n = j(), r = j([]), i = j([]), a = j("view"), o = j(L()), s = j(z()), c = w(() => e.value.find((e) => e.id === n.value)), l = w(() => c.value?.metadataId ? t.value[c.value.metadataId] : void 0), u = w(() => e.value.some((e) => e.relationRole === "MAIN")), d = w(() => a.value === "create-main"), f = w(() => a.value === "create-field" || a.value === "edit-field"), p = w(() => H(i.value));
|
|
6
6
|
function m(t) {
|
|
7
7
|
e.value = t;
|
|
8
8
|
let r = new Set(t.map((e) => e.id).filter(Boolean));
|
|
@@ -15,7 +15,7 @@ function ie() {
|
|
|
15
15
|
});
|
|
16
16
|
}
|
|
17
17
|
function g(e) {
|
|
18
|
-
r.value =
|
|
18
|
+
r.value = V(e);
|
|
19
19
|
}
|
|
20
20
|
function _(e) {
|
|
21
21
|
i.value = e;
|
|
@@ -30,10 +30,10 @@ function ie() {
|
|
|
30
30
|
o.value = L(), a.value = "create-main";
|
|
31
31
|
}
|
|
32
32
|
function x() {
|
|
33
|
-
l.value?.id && (s.value =
|
|
33
|
+
l.value?.id && (s.value = z(), a.value = "create-field");
|
|
34
34
|
}
|
|
35
35
|
function S(e) {
|
|
36
|
-
l.value?.id && (s.value =
|
|
36
|
+
l.value?.id && (s.value = B(e), a.value = "edit-field");
|
|
37
37
|
}
|
|
38
38
|
function C() {
|
|
39
39
|
a.value = "view";
|
|
@@ -83,10 +83,10 @@ function R(e) {
|
|
|
83
83
|
tableName: e.tableName.trim()
|
|
84
84
|
};
|
|
85
85
|
}
|
|
86
|
-
function
|
|
86
|
+
function ae(e) {
|
|
87
87
|
return !!(e.alias.trim() && e.title.trim());
|
|
88
88
|
}
|
|
89
|
-
function
|
|
89
|
+
function z() {
|
|
90
90
|
return {
|
|
91
91
|
fieldName: "",
|
|
92
92
|
columnName: "",
|
|
@@ -102,13 +102,13 @@ function B() {
|
|
|
102
102
|
enabled: !0
|
|
103
103
|
};
|
|
104
104
|
}
|
|
105
|
-
function
|
|
105
|
+
function B(e) {
|
|
106
106
|
return { ...e };
|
|
107
107
|
}
|
|
108
|
-
function
|
|
108
|
+
function oe(e) {
|
|
109
109
|
return !!(e.fieldName?.trim() && e.columnName?.trim() && e.fieldSpecAlias);
|
|
110
110
|
}
|
|
111
|
-
function
|
|
111
|
+
function se(e) {
|
|
112
112
|
return {
|
|
113
113
|
...e,
|
|
114
114
|
fieldName: e.fieldName?.trim(),
|
|
@@ -116,39 +116,39 @@ function oe(e) {
|
|
|
116
116
|
title: e.title?.trim()
|
|
117
117
|
};
|
|
118
118
|
}
|
|
119
|
-
function
|
|
119
|
+
function V(e) {
|
|
120
120
|
return e.filter((e) => e.fieldOwnership === "BUSINESS" && e.fieldForm === "PHYSICAL" && e.systemManaged !== !0);
|
|
121
121
|
}
|
|
122
|
-
function
|
|
122
|
+
function H(e) {
|
|
123
123
|
return e.filter((e) => e.enabled !== !1).map((e) => ({
|
|
124
124
|
value: e.alias ?? e.id ?? "",
|
|
125
125
|
label: e.title ?? e.alias ?? e.id ?? "未命名字段规格"
|
|
126
126
|
})).filter((e) => e.value);
|
|
127
127
|
}
|
|
128
|
-
function
|
|
128
|
+
function U(e, t) {
|
|
129
129
|
return t?.title ?? e.relationAlias ?? "未命名实体";
|
|
130
130
|
}
|
|
131
|
-
function
|
|
131
|
+
function W(e) {
|
|
132
132
|
if (e === "MAIN") return "主实体";
|
|
133
133
|
if (e === "CHILD") return "子实体";
|
|
134
134
|
}
|
|
135
|
-
function
|
|
136
|
-
let n =
|
|
135
|
+
function G(e, t) {
|
|
136
|
+
let n = U(e, t), r = t?.alias ?? e.relationAlias;
|
|
137
137
|
return {
|
|
138
138
|
title: n,
|
|
139
139
|
secondary: r && r !== n ? r : void 0,
|
|
140
|
-
tag:
|
|
140
|
+
tag: W(e.relationRole),
|
|
141
141
|
muted: t?.enabled === !1 ? !0 : void 0
|
|
142
142
|
};
|
|
143
143
|
}
|
|
144
|
-
function
|
|
144
|
+
function ce(e) {
|
|
145
145
|
if (!e) return;
|
|
146
146
|
let t = e.tableName ? `${e.schemaName ?? "public"}.${e.tableName}` : void 0;
|
|
147
147
|
return [e.alias, t].filter(Boolean).join(" · ") || void 0;
|
|
148
148
|
}
|
|
149
149
|
//#endregion
|
|
150
150
|
//#region src/views/MetadataOrchestrationView.vue?vue&type=script&setup=true&lang.ts
|
|
151
|
-
var
|
|
151
|
+
var K = { class: "entity-overview" }, le = { class: "field-section" }, ue = { class: "orchestration-form-flags" }, q = 200, J = /*#__PURE__*/ h(/* @__PURE__ */ k({
|
|
152
152
|
name: "MetadataOrchestrationView",
|
|
153
153
|
__name: "MetadataOrchestrationView",
|
|
154
154
|
props: {
|
|
@@ -156,8 +156,8 @@ var ce = { class: "entity-overview" }, le = { class: "field-section" }, ue = { c
|
|
|
156
156
|
moduleTitle: {},
|
|
157
157
|
title: {}
|
|
158
158
|
},
|
|
159
|
-
setup(
|
|
160
|
-
let
|
|
159
|
+
setup(h) {
|
|
160
|
+
let w = h, k = c({ moduleAlias: "platform.module" }), L = r(k.http, "/platform.metadata"), z = I(), B = j(!1), V = j(!1), H = j(""), W = [
|
|
161
161
|
{
|
|
162
162
|
key: "title",
|
|
163
163
|
title: "字段"
|
|
@@ -183,168 +183,168 @@ var ce = { class: "entity-overview" }, le = { class: "field-section" }, ue = { c
|
|
|
183
183
|
width: 70
|
|
184
184
|
}
|
|
185
185
|
];
|
|
186
|
-
|
|
186
|
+
ie(() => w.moduleAlias, () => void J(), { immediate: !0 }), re(() => void de());
|
|
187
187
|
async function J() {
|
|
188
|
-
|
|
188
|
+
B.value = !0;
|
|
189
189
|
try {
|
|
190
|
-
|
|
190
|
+
z.handleRelationsLoaded(await $(Q("/query"))), await Y();
|
|
191
191
|
} catch (e) {
|
|
192
|
-
|
|
192
|
+
o(e, {
|
|
193
193
|
source: "metadata-orchestration",
|
|
194
194
|
phase: "load"
|
|
195
195
|
});
|
|
196
196
|
} finally {
|
|
197
|
-
|
|
197
|
+
B.value = !1;
|
|
198
198
|
}
|
|
199
199
|
}
|
|
200
200
|
async function de() {
|
|
201
201
|
try {
|
|
202
|
-
|
|
202
|
+
z.handleFieldSpecsLoaded(await $("/platform.field_spec/query"));
|
|
203
203
|
} catch (e) {
|
|
204
|
-
|
|
204
|
+
o(e, {
|
|
205
205
|
source: "metadata-orchestration",
|
|
206
206
|
phase: "load"
|
|
207
207
|
});
|
|
208
208
|
}
|
|
209
209
|
}
|
|
210
210
|
async function fe(e) {
|
|
211
|
-
|
|
211
|
+
z.selectRelation(e) && await Y();
|
|
212
212
|
}
|
|
213
213
|
async function Y() {
|
|
214
|
-
let e =
|
|
215
|
-
if (
|
|
214
|
+
let e = z.selectedRelation.value?.metadataId;
|
|
215
|
+
if (z.handleFieldsLoaded([]), e) try {
|
|
216
216
|
let t = await L.view(e);
|
|
217
|
-
|
|
217
|
+
z.handleMetadataLoaded(t), z.handleFieldsLoaded(await $(`/platform.metadata/${encodeURIComponent(e)}/fields/query`));
|
|
218
218
|
} catch (e) {
|
|
219
|
-
|
|
219
|
+
o(e, {
|
|
220
220
|
source: "metadata-orchestration",
|
|
221
221
|
phase: "load"
|
|
222
222
|
});
|
|
223
223
|
}
|
|
224
224
|
}
|
|
225
225
|
async function X() {
|
|
226
|
-
let e = R(
|
|
227
|
-
if (!
|
|
228
|
-
|
|
226
|
+
let e = R(z.mainMetadataDraft.value);
|
|
227
|
+
if (!ae(e)) {
|
|
228
|
+
y("请填写实体 alias 和名称", {
|
|
229
229
|
source: "metadata-orchestration",
|
|
230
230
|
phase: "validation"
|
|
231
231
|
});
|
|
232
232
|
return;
|
|
233
233
|
}
|
|
234
|
-
|
|
234
|
+
V.value = !0;
|
|
235
235
|
try {
|
|
236
|
-
let t = await
|
|
236
|
+
let t = await k.http.request({
|
|
237
237
|
method: "POST",
|
|
238
238
|
path: Q("/create-main-metadata"),
|
|
239
239
|
body: e
|
|
240
240
|
});
|
|
241
|
-
|
|
241
|
+
z.cancelEditor(), await J(), z.focusRelation(t.relation.id), await Y(), await l({
|
|
242
242
|
success: !0,
|
|
243
243
|
message: "主实体已创建"
|
|
244
244
|
}, { source: "metadata-orchestration" });
|
|
245
245
|
} catch (e) {
|
|
246
|
-
|
|
246
|
+
o(e, {
|
|
247
247
|
source: "metadata-orchestration",
|
|
248
248
|
phase: "action"
|
|
249
249
|
});
|
|
250
250
|
} finally {
|
|
251
|
-
|
|
251
|
+
V.value = !1;
|
|
252
252
|
}
|
|
253
253
|
}
|
|
254
254
|
async function Z() {
|
|
255
|
-
let e =
|
|
255
|
+
let e = z.selectedMetadata.value?.id;
|
|
256
256
|
if (!e) return;
|
|
257
|
-
let
|
|
258
|
-
if (!
|
|
259
|
-
|
|
257
|
+
let t = se(z.fieldDraft.value);
|
|
258
|
+
if (!oe(t)) {
|
|
259
|
+
y("请填写字段名、物理列名和字段规格", {
|
|
260
260
|
source: "metadata-orchestration",
|
|
261
261
|
phase: "validation"
|
|
262
262
|
});
|
|
263
263
|
return;
|
|
264
264
|
}
|
|
265
|
-
|
|
265
|
+
V.value = !0;
|
|
266
266
|
try {
|
|
267
|
-
let
|
|
268
|
-
...
|
|
267
|
+
let n = {
|
|
268
|
+
...t,
|
|
269
269
|
metadataId: e,
|
|
270
270
|
fieldOwnership: "BUSINESS",
|
|
271
271
|
fieldForm: "PHYSICAL"
|
|
272
272
|
};
|
|
273
|
-
|
|
273
|
+
n.id ? await k.http.request({
|
|
274
274
|
method: "POST",
|
|
275
|
-
path: `/platform.metadata/${encodeURIComponent(e)}/fields/update/${encodeURIComponent(
|
|
276
|
-
body:
|
|
277
|
-
}) : await
|
|
275
|
+
path: `/platform.metadata/${encodeURIComponent(e)}/fields/update/${encodeURIComponent(n.id)}`,
|
|
276
|
+
body: n
|
|
277
|
+
}) : await k.http.request({
|
|
278
278
|
method: "POST",
|
|
279
279
|
path: `/platform.metadata/${encodeURIComponent(e)}/fields/insert`,
|
|
280
|
-
body:
|
|
281
|
-
}),
|
|
280
|
+
body: n
|
|
281
|
+
}), z.cancelEditor(), await Y(), await l({
|
|
282
282
|
success: !0,
|
|
283
283
|
message: "字段已保存"
|
|
284
284
|
}, { source: "metadata-orchestration" });
|
|
285
285
|
} catch (e) {
|
|
286
|
-
|
|
286
|
+
o(e, {
|
|
287
287
|
source: "metadata-orchestration",
|
|
288
288
|
phase: "action"
|
|
289
289
|
});
|
|
290
290
|
} finally {
|
|
291
|
-
|
|
291
|
+
V.value = !1;
|
|
292
292
|
}
|
|
293
293
|
}
|
|
294
294
|
async function pe(e) {
|
|
295
|
-
let t =
|
|
296
|
-
if (!(!t || !e.id || !await
|
|
295
|
+
let t = z.selectedMetadata.value?.id;
|
|
296
|
+
if (!(!t || !e.id || !await u({
|
|
297
297
|
title: "删除字段",
|
|
298
298
|
content: `确认删除字段“${e.title ?? e.fieldName}”?`,
|
|
299
299
|
okText: "删除",
|
|
300
300
|
danger: !0
|
|
301
301
|
}))) {
|
|
302
|
-
|
|
302
|
+
V.value = !0;
|
|
303
303
|
try {
|
|
304
|
-
await
|
|
304
|
+
await k.http.request({
|
|
305
305
|
method: "POST",
|
|
306
306
|
path: `/platform.metadata/${encodeURIComponent(t)}/fields/delete/${encodeURIComponent(e.id)}`,
|
|
307
307
|
body: { version: e.version }
|
|
308
308
|
}), await Y();
|
|
309
309
|
} catch (e) {
|
|
310
|
-
|
|
310
|
+
o(e, {
|
|
311
311
|
source: "metadata-orchestration",
|
|
312
312
|
phase: "action"
|
|
313
313
|
});
|
|
314
314
|
} finally {
|
|
315
|
-
|
|
315
|
+
V.value = !1;
|
|
316
316
|
}
|
|
317
317
|
}
|
|
318
318
|
}
|
|
319
319
|
async function me() {
|
|
320
|
-
let e =
|
|
320
|
+
let e = z.selectedRelation.value;
|
|
321
321
|
if (e?.id) {
|
|
322
|
-
|
|
322
|
+
V.value = !0;
|
|
323
323
|
try {
|
|
324
|
-
await
|
|
324
|
+
await k.http.request({
|
|
325
325
|
method: "POST",
|
|
326
326
|
path: Q(`/${encodeURIComponent(e.id)}/fields/ensure`)
|
|
327
|
-
}), await
|
|
327
|
+
}), await l({
|
|
328
328
|
success: !0,
|
|
329
329
|
message: "模块字段配置已同步"
|
|
330
330
|
}, { source: "metadata-orchestration" });
|
|
331
331
|
} catch (e) {
|
|
332
|
-
|
|
332
|
+
o(e, {
|
|
333
333
|
source: "metadata-orchestration",
|
|
334
334
|
phase: "action"
|
|
335
335
|
});
|
|
336
336
|
} finally {
|
|
337
|
-
|
|
337
|
+
V.value = !1;
|
|
338
338
|
}
|
|
339
339
|
}
|
|
340
340
|
}
|
|
341
341
|
function Q(e) {
|
|
342
|
-
return `/platform.module/${encodeURIComponent(
|
|
342
|
+
return `/platform.module/${encodeURIComponent(w.moduleAlias)}/metadata-relations${e}`;
|
|
343
343
|
}
|
|
344
344
|
async function $(e) {
|
|
345
345
|
let t = [];
|
|
346
346
|
for (let n = 1;; n += 1) {
|
|
347
|
-
let r = await
|
|
347
|
+
let r = await k.http.request({
|
|
348
348
|
method: "POST",
|
|
349
349
|
path: e,
|
|
350
350
|
body: { page: {
|
|
@@ -356,46 +356,46 @@ var ce = { class: "entity-overview" }, le = { class: "field-section" }, ue = { c
|
|
|
356
356
|
}
|
|
357
357
|
}
|
|
358
358
|
function he(e) {
|
|
359
|
-
return e.metadataId ?
|
|
359
|
+
return e.metadataId ? z.metadataById.value[e.metadataId] : void 0;
|
|
360
360
|
}
|
|
361
361
|
function ge(e) {
|
|
362
362
|
let t = e;
|
|
363
|
-
return
|
|
363
|
+
return G(t, he(t));
|
|
364
364
|
}
|
|
365
365
|
function _e(e, t) {
|
|
366
366
|
let n = t;
|
|
367
367
|
return e.key === "required" ? n.required ? "是" : "否" : e.key === "enabled" ? n.enabled === !1 ? "停用" : "启用" : String(n[e.key] ?? "");
|
|
368
368
|
}
|
|
369
|
-
return (
|
|
370
|
-
|
|
369
|
+
return (r, o) => (A(), ne(ee, null, [
|
|
370
|
+
O(N(i), {
|
|
371
371
|
class: "metadata-orchestration-workspace",
|
|
372
372
|
"explorer-count": 1
|
|
373
373
|
}, {
|
|
374
|
-
default:
|
|
375
|
-
default:
|
|
376
|
-
"search-keyword":
|
|
377
|
-
"onUpdate:searchKeyword":
|
|
374
|
+
default: P(() => [O(N(s), null, {
|
|
375
|
+
default: P(() => [O(N(t), {
|
|
376
|
+
"search-keyword": H.value,
|
|
377
|
+
"onUpdate:searchKeyword": o[0] ||= (e) => H.value = e,
|
|
378
378
|
title: "实体",
|
|
379
379
|
"search-placeholder": "搜索实体名称或 alias",
|
|
380
380
|
onRefresh: J
|
|
381
381
|
}, {
|
|
382
|
-
actions:
|
|
382
|
+
actions: P(() => [N(z).hasMainMetadata.value ? te("v-if", !0) : (A(), T(N(_), {
|
|
383
383
|
key: 0,
|
|
384
384
|
class: "record-panel-create-button",
|
|
385
385
|
type: "primary",
|
|
386
386
|
"icon-name": "plus",
|
|
387
387
|
title: "新建主实体",
|
|
388
|
-
disabled:
|
|
389
|
-
onClick:
|
|
388
|
+
disabled: B.value || V.value,
|
|
389
|
+
onClick: N(z).startCreateMain
|
|
390
390
|
}, null, 8, ["disabled", "onClick"]))]),
|
|
391
|
-
default:
|
|
391
|
+
default: P(() => [B.value ? (A(), T(N(e), {
|
|
392
392
|
key: 0,
|
|
393
393
|
tip: "加载实体"
|
|
394
|
-
})) :
|
|
394
|
+
})) : N(z).relations.value.length ? (A(), T(N(a), {
|
|
395
395
|
key: 2,
|
|
396
|
-
records:
|
|
397
|
-
"selected-id":
|
|
398
|
-
keyword:
|
|
396
|
+
records: N(z).relations.value,
|
|
397
|
+
"selected-id": N(z).selectedRelationId.value,
|
|
398
|
+
keyword: H.value,
|
|
399
399
|
"empty-description": "暂无实体",
|
|
400
400
|
"item-of": ge,
|
|
401
401
|
onSelect: fe
|
|
@@ -403,137 +403,137 @@ var ce = { class: "entity-overview" }, le = { class: "field-section" }, ue = { c
|
|
|
403
403
|
"records",
|
|
404
404
|
"selected-id",
|
|
405
405
|
"keyword"
|
|
406
|
-
])) : (
|
|
406
|
+
])) : (A(), T(N(g), {
|
|
407
407
|
key: 1,
|
|
408
408
|
description: "请先创建动态模块的主实体"
|
|
409
409
|
}))]),
|
|
410
410
|
_: 1
|
|
411
411
|
}, 8, ["search-keyword"])]),
|
|
412
412
|
_: 1
|
|
413
|
-
}),
|
|
413
|
+
}), N(z).selectedMetadata.value && N(z).selectedRelation.value ? (A(), T(N(n), {
|
|
414
414
|
key: 0,
|
|
415
|
-
title:
|
|
416
|
-
subtitle:
|
|
415
|
+
title: N(U)(N(z).selectedRelation.value, N(z).selectedMetadata.value),
|
|
416
|
+
subtitle: N(ce)(N(z).selectedMetadata.value)
|
|
417
417
|
}, {
|
|
418
|
-
actions:
|
|
418
|
+
actions: P(() => [O(N(v), {
|
|
419
419
|
emphasis: "quiet",
|
|
420
|
-
disabled:
|
|
420
|
+
disabled: V.value || B.value,
|
|
421
421
|
onClick: me
|
|
422
422
|
}, {
|
|
423
|
-
default:
|
|
423
|
+
default: P(() => [...o[16] ||= [D(" 同步模块字段配置 ", -1)]]),
|
|
424
424
|
_: 1
|
|
425
|
-
}, 8, ["disabled"]),
|
|
425
|
+
}, 8, ["disabled"]), O(N(v), {
|
|
426
426
|
emphasis: "primary",
|
|
427
|
-
disabled:
|
|
428
|
-
onClick:
|
|
427
|
+
disabled: V.value || B.value,
|
|
428
|
+
onClick: N(z).startCreateField
|
|
429
429
|
}, {
|
|
430
|
-
default:
|
|
430
|
+
default: P(() => [...o[17] ||= [D(" 新增字段 ", -1)]]),
|
|
431
431
|
_: 1
|
|
432
432
|
}, 8, ["disabled", "onClick"])]),
|
|
433
|
-
default:
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
433
|
+
default: P(() => [
|
|
434
|
+
E("dl", K, [
|
|
435
|
+
E("div", null, [o[18] ||= E("dt", null, "实体 alias", -1), E("dd", null, M(N(z).selectedMetadata.value.alias ?? "-"), 1)]),
|
|
436
|
+
E("div", null, [o[19] ||= E("dt", null, "物理表", -1), E("dd", null, M(N(z).selectedMetadata.value.tableName ? `${N(z).selectedMetadata.value.schemaName ?? "public"}.${N(z).selectedMetadata.value.tableName}` : "-"), 1)]),
|
|
437
|
+
E("div", null, [o[20] ||= E("dt", null, "数据权限范围", -1), E("dd", null, M(N(z).selectedMetadata.value.dataScopeEnabled ? "已启用" : "未启用"), 1)])
|
|
438
438
|
]),
|
|
439
|
-
|
|
439
|
+
E("section", le, [o[23] ||= E("header", { class: "field-section-header" }, [E("h3", null, "业务字段")], -1), B.value ? (A(), T(N(e), {
|
|
440
440
|
key: 0,
|
|
441
441
|
tip: "加载字段"
|
|
442
|
-
})) :
|
|
442
|
+
})) : N(z).fields.value.length ? (A(), T(N(b), {
|
|
443
443
|
key: 2,
|
|
444
|
-
columns:
|
|
445
|
-
rows:
|
|
444
|
+
columns: W,
|
|
445
|
+
rows: N(z).fields.value,
|
|
446
446
|
"show-action-column": "",
|
|
447
447
|
"action-column-title": "操作"
|
|
448
448
|
}, {
|
|
449
|
-
cell:
|
|
450
|
-
rowActions:
|
|
449
|
+
cell: P(({ column: e, record: t }) => [D(M(_e(e, t)), 1)]),
|
|
450
|
+
rowActions: P(({ record: e }) => [O(N(v), {
|
|
451
451
|
emphasis: "quiet",
|
|
452
452
|
density: "compact",
|
|
453
|
-
onClick: (t) =>
|
|
453
|
+
onClick: (t) => N(z).startEditField(e)
|
|
454
454
|
}, {
|
|
455
|
-
default:
|
|
455
|
+
default: P(() => [...o[21] ||= [D(" 编辑 ", -1)]]),
|
|
456
456
|
_: 1
|
|
457
|
-
}, 8, ["onClick"]),
|
|
457
|
+
}, 8, ["onClick"]), O(N(v), {
|
|
458
458
|
emphasis: "quiet",
|
|
459
459
|
density: "compact",
|
|
460
460
|
intent: "danger",
|
|
461
|
-
disabled:
|
|
461
|
+
disabled: V.value,
|
|
462
462
|
onClick: (t) => pe(e)
|
|
463
463
|
}, {
|
|
464
|
-
default:
|
|
464
|
+
default: P(() => [...o[22] ||= [D(" 删除 ", -1)]]),
|
|
465
465
|
_: 1
|
|
466
466
|
}, 8, ["disabled", "onClick"])]),
|
|
467
467
|
_: 1
|
|
468
|
-
}, 8, ["rows"])) : (
|
|
468
|
+
}, 8, ["rows"])) : (A(), T(N(g), {
|
|
469
469
|
key: 1,
|
|
470
470
|
description: "暂无业务字段,点击右上角新增字段"
|
|
471
471
|
}))]),
|
|
472
|
-
|
|
472
|
+
O(N(d), { record: N(z).selectedMetadata.value }, null, 8, ["record"])
|
|
473
473
|
]),
|
|
474
474
|
_: 1
|
|
475
|
-
}, 8, ["title", "subtitle"])) : (
|
|
475
|
+
}, 8, ["title", "subtitle"])) : (A(), T(N(n), {
|
|
476
476
|
key: 1,
|
|
477
477
|
title: "字段编排"
|
|
478
478
|
}, {
|
|
479
|
-
default:
|
|
479
|
+
default: P(() => [O(N(g), { description: "从左侧选择实体后开始字段编排" })]),
|
|
480
480
|
_: 1
|
|
481
481
|
}))]),
|
|
482
482
|
_: 1
|
|
483
483
|
}),
|
|
484
|
-
|
|
485
|
-
open:
|
|
484
|
+
O(N(m), {
|
|
485
|
+
open: N(z).mainEditorOpen.value,
|
|
486
486
|
title: "新建主实体",
|
|
487
|
-
subtitle:
|
|
487
|
+
subtitle: h.moduleTitle ?? h.moduleAlias,
|
|
488
488
|
mode: "create",
|
|
489
|
-
onClose:
|
|
489
|
+
onClose: N(z).cancelEditor
|
|
490
490
|
}, {
|
|
491
|
-
form:
|
|
491
|
+
form: P(() => [E("form", {
|
|
492
492
|
class: "orchestration-form",
|
|
493
|
-
onSubmit:
|
|
493
|
+
onSubmit: F(X, ["prevent"])
|
|
494
494
|
}, [
|
|
495
|
-
|
|
496
|
-
value:
|
|
497
|
-
"onUpdate:value":
|
|
495
|
+
E("label", null, [o[24] ||= E("span", null, "实体 alias", -1), O(N(S), {
|
|
496
|
+
value: N(z).mainMetadataDraft.value.alias,
|
|
497
|
+
"onUpdate:value": o[1] ||= (e) => N(z).mainMetadataDraft.value.alias = e,
|
|
498
498
|
placeholder: "例如 customer"
|
|
499
499
|
}, null, 8, ["value"])]),
|
|
500
|
-
|
|
501
|
-
value:
|
|
502
|
-
"onUpdate:value":
|
|
500
|
+
E("label", null, [o[25] ||= E("span", null, "实体名称", -1), O(N(S), {
|
|
501
|
+
value: N(z).mainMetadataDraft.value.title,
|
|
502
|
+
"onUpdate:value": o[2] ||= (e) => N(z).mainMetadataDraft.value.title = e,
|
|
503
503
|
placeholder: "例如 客户"
|
|
504
504
|
}, null, 8, ["value"])]),
|
|
505
|
-
|
|
506
|
-
value:
|
|
507
|
-
"onUpdate:value":
|
|
505
|
+
E("label", null, [o[26] ||= E("span", null, "Schema(可选)", -1), O(N(S), {
|
|
506
|
+
value: N(z).mainMetadataDraft.value.schemaName,
|
|
507
|
+
"onUpdate:value": o[3] ||= (e) => N(z).mainMetadataDraft.value.schemaName = e,
|
|
508
508
|
placeholder: "默认 public"
|
|
509
509
|
}, null, 8, ["value"])]),
|
|
510
|
-
|
|
511
|
-
value:
|
|
512
|
-
"onUpdate:value":
|
|
510
|
+
E("label", null, [o[27] ||= E("span", null, "物理表名(可选)", -1), O(N(S), {
|
|
511
|
+
value: N(z).mainMetadataDraft.value.tableName,
|
|
512
|
+
"onUpdate:value": o[4] ||= (e) => N(z).mainMetadataDraft.value.tableName = e,
|
|
513
513
|
placeholder: "默认按应用和 alias 生成"
|
|
514
514
|
}, null, 8, ["value"])]),
|
|
515
|
-
|
|
516
|
-
checked:
|
|
517
|
-
"onUpdate:checked":
|
|
515
|
+
O(N(p), {
|
|
516
|
+
checked: N(z).mainMetadataDraft.value.dataScopeEnabled,
|
|
517
|
+
"onUpdate:checked": o[5] ||= (e) => N(z).mainMetadataDraft.value.dataScopeEnabled = e
|
|
518
518
|
}, {
|
|
519
|
-
default:
|
|
519
|
+
default: P(() => [...o[28] ||= [D(" 启用数据权限范围 ", -1)]]),
|
|
520
520
|
_: 1
|
|
521
521
|
}, 8, ["checked"])
|
|
522
522
|
], 32)]),
|
|
523
|
-
operation:
|
|
524
|
-
default:
|
|
525
|
-
disabled:
|
|
526
|
-
onClick:
|
|
523
|
+
operation: P(() => [O(N(C), null, {
|
|
524
|
+
default: P(() => [O(N(v), {
|
|
525
|
+
disabled: V.value,
|
|
526
|
+
onClick: N(z).cancelEditor
|
|
527
527
|
}, {
|
|
528
|
-
default:
|
|
528
|
+
default: P(() => [...o[29] ||= [D("取消", -1)]]),
|
|
529
529
|
_: 1
|
|
530
|
-
}, 8, ["disabled", "onClick"]),
|
|
530
|
+
}, 8, ["disabled", "onClick"]), O(N(v), {
|
|
531
531
|
emphasis: "primary",
|
|
532
532
|
submit: "",
|
|
533
|
-
loading:
|
|
533
|
+
loading: V.value,
|
|
534
534
|
onClick: X
|
|
535
535
|
}, {
|
|
536
|
-
default:
|
|
536
|
+
default: P(() => [...o[30] ||= [D(" 创建 ", -1)]]),
|
|
537
537
|
_: 1
|
|
538
538
|
}, 8, ["loading"])]),
|
|
539
539
|
_: 1
|
|
@@ -544,99 +544,99 @@ var ce = { class: "entity-overview" }, le = { class: "field-section" }, ue = { c
|
|
|
544
544
|
"subtitle",
|
|
545
545
|
"onClose"
|
|
546
546
|
]),
|
|
547
|
-
|
|
548
|
-
open:
|
|
549
|
-
title:
|
|
550
|
-
subtitle:
|
|
547
|
+
O(N(m), {
|
|
548
|
+
open: N(z).fieldEditorOpen.value,
|
|
549
|
+
title: N(z).mode.value === "edit-field" ? "编辑字段" : "新增字段",
|
|
550
|
+
subtitle: N(z).selectedMetadata.value?.title,
|
|
551
551
|
mode: "create",
|
|
552
|
-
onClose:
|
|
552
|
+
onClose: N(z).cancelEditor
|
|
553
553
|
}, {
|
|
554
|
-
form:
|
|
554
|
+
form: P(() => [E("form", {
|
|
555
555
|
class: "orchestration-form",
|
|
556
|
-
onSubmit:
|
|
556
|
+
onSubmit: F(Z, ["prevent"])
|
|
557
557
|
}, [
|
|
558
|
-
|
|
559
|
-
value:
|
|
560
|
-
"onUpdate:value":
|
|
561
|
-
disabled: !!
|
|
558
|
+
E("label", null, [o[31] ||= E("span", null, "字段名称", -1), O(N(S), {
|
|
559
|
+
value: N(z).fieldDraft.value.fieldName,
|
|
560
|
+
"onUpdate:value": o[6] ||= (e) => N(z).fieldDraft.value.fieldName = e,
|
|
561
|
+
disabled: !!N(z).fieldDraft.value.id,
|
|
562
562
|
placeholder: "例如 customerName"
|
|
563
563
|
}, null, 8, ["value", "disabled"])]),
|
|
564
|
-
|
|
565
|
-
value:
|
|
566
|
-
"onUpdate:value":
|
|
567
|
-
disabled: !!
|
|
564
|
+
E("label", null, [o[32] ||= E("span", null, "物理列名", -1), O(N(S), {
|
|
565
|
+
value: N(z).fieldDraft.value.columnName,
|
|
566
|
+
"onUpdate:value": o[7] ||= (e) => N(z).fieldDraft.value.columnName = e,
|
|
567
|
+
disabled: !!N(z).fieldDraft.value.id,
|
|
568
568
|
placeholder: "例如 customer_name"
|
|
569
569
|
}, null, 8, ["value", "disabled"])]),
|
|
570
|
-
|
|
571
|
-
value:
|
|
572
|
-
"onUpdate:value":
|
|
570
|
+
E("label", null, [o[33] ||= E("span", null, "显示名称", -1), O(N(S), {
|
|
571
|
+
value: N(z).fieldDraft.value.title,
|
|
572
|
+
"onUpdate:value": o[8] ||= (e) => N(z).fieldDraft.value.title = e,
|
|
573
573
|
placeholder: "例如 客户名称"
|
|
574
574
|
}, null, 8, ["value"])]),
|
|
575
|
-
|
|
576
|
-
value:
|
|
577
|
-
"onUpdate:value":
|
|
578
|
-
options:
|
|
575
|
+
E("label", null, [o[34] ||= E("span", null, "字段规格", -1), O(N(f), {
|
|
576
|
+
value: N(z).fieldDraft.value.fieldSpecAlias,
|
|
577
|
+
"onUpdate:value": o[9] ||= (e) => N(z).fieldDraft.value.fieldSpecAlias = e,
|
|
578
|
+
options: N(z).fieldSpecOptions.value,
|
|
579
579
|
placeholder: "选择字段规格",
|
|
580
580
|
style: { width: "100%" }
|
|
581
581
|
}, null, 8, ["value", "options"])]),
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
checked:
|
|
585
|
-
"onUpdate:checked":
|
|
582
|
+
E("div", ue, [
|
|
583
|
+
O(N(p), {
|
|
584
|
+
checked: N(z).fieldDraft.value.required,
|
|
585
|
+
"onUpdate:checked": o[10] ||= (e) => N(z).fieldDraft.value.required = e
|
|
586
586
|
}, {
|
|
587
|
-
default:
|
|
587
|
+
default: P(() => [...o[35] ||= [D("必填", -1)]]),
|
|
588
588
|
_: 1
|
|
589
589
|
}, 8, ["checked"]),
|
|
590
|
-
|
|
591
|
-
checked:
|
|
592
|
-
"onUpdate:checked":
|
|
590
|
+
O(N(p), {
|
|
591
|
+
checked: N(z).fieldDraft.value.uniqueField,
|
|
592
|
+
"onUpdate:checked": o[11] ||= (e) => N(z).fieldDraft.value.uniqueField = e
|
|
593
593
|
}, {
|
|
594
|
-
default:
|
|
594
|
+
default: P(() => [...o[36] ||= [D("唯一", -1)]]),
|
|
595
595
|
_: 1
|
|
596
596
|
}, 8, ["checked"]),
|
|
597
|
-
|
|
598
|
-
checked:
|
|
599
|
-
"onUpdate:checked":
|
|
597
|
+
O(N(p), {
|
|
598
|
+
checked: N(z).fieldDraft.value.indexed,
|
|
599
|
+
"onUpdate:checked": o[12] ||= (e) => N(z).fieldDraft.value.indexed = e
|
|
600
600
|
}, {
|
|
601
|
-
default:
|
|
601
|
+
default: P(() => [...o[37] ||= [D("建立索引", -1)]]),
|
|
602
602
|
_: 1
|
|
603
603
|
}, 8, ["checked"]),
|
|
604
|
-
|
|
605
|
-
checked:
|
|
606
|
-
"onUpdate:checked":
|
|
604
|
+
O(N(p), {
|
|
605
|
+
checked: N(z).fieldDraft.value.sortableField,
|
|
606
|
+
"onUpdate:checked": o[13] ||= (e) => N(z).fieldDraft.value.sortableField = e
|
|
607
607
|
}, {
|
|
608
|
-
default:
|
|
608
|
+
default: P(() => [...o[38] ||= [D("排序字段", -1)]]),
|
|
609
609
|
_: 1
|
|
610
610
|
}, 8, ["checked"]),
|
|
611
|
-
|
|
612
|
-
checked:
|
|
613
|
-
"onUpdate:checked":
|
|
611
|
+
O(N(p), {
|
|
612
|
+
checked: N(z).fieldDraft.value.titleField,
|
|
613
|
+
"onUpdate:checked": o[14] ||= (e) => N(z).fieldDraft.value.titleField = e
|
|
614
614
|
}, {
|
|
615
|
-
default:
|
|
615
|
+
default: P(() => [...o[39] ||= [D("标题字段", -1)]]),
|
|
616
616
|
_: 1
|
|
617
617
|
}, 8, ["checked"]),
|
|
618
|
-
|
|
619
|
-
checked:
|
|
620
|
-
"onUpdate:checked":
|
|
618
|
+
O(N(x), {
|
|
619
|
+
checked: N(z).fieldDraft.value.enabled,
|
|
620
|
+
"onUpdate:checked": o[15] ||= (e) => N(z).fieldDraft.value.enabled = e,
|
|
621
621
|
"checked-children": "启用",
|
|
622
622
|
"un-checked-children": "停用"
|
|
623
623
|
}, null, 8, ["checked"])
|
|
624
624
|
])
|
|
625
625
|
], 32)]),
|
|
626
|
-
operation:
|
|
627
|
-
default:
|
|
628
|
-
disabled:
|
|
629
|
-
onClick:
|
|
626
|
+
operation: P(() => [O(N(C), null, {
|
|
627
|
+
default: P(() => [O(N(v), {
|
|
628
|
+
disabled: V.value,
|
|
629
|
+
onClick: N(z).cancelEditor
|
|
630
630
|
}, {
|
|
631
|
-
default:
|
|
631
|
+
default: P(() => [...o[40] ||= [D("取消", -1)]]),
|
|
632
632
|
_: 1
|
|
633
|
-
}, 8, ["disabled", "onClick"]),
|
|
633
|
+
}, 8, ["disabled", "onClick"]), O(N(v), {
|
|
634
634
|
emphasis: "primary",
|
|
635
635
|
submit: "",
|
|
636
|
-
loading:
|
|
636
|
+
loading: V.value,
|
|
637
637
|
onClick: Z
|
|
638
638
|
}, {
|
|
639
|
-
default:
|
|
639
|
+
default: P(() => [...o[41] ||= [D("保存", -1)]]),
|
|
640
640
|
_: 1
|
|
641
641
|
}, 8, ["loading"])]),
|
|
642
642
|
_: 1
|