@jeecg/online 3.5.3-beta3 → 3.6.0-beta
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/AuthButtonConfig-b6a674fa.mjs +125 -0
- package/AuthButtonTree-09e57bc4.mjs +156 -0
- package/AuthDataConfig-6e7e61ec.mjs +212 -0
- package/AuthDataTree-e83286c5.mjs +139 -0
- package/AuthFieldConfig-f1ec2708.mjs +139 -0
- package/AuthFieldTree-bb72e21f.mjs +232 -0
- package/AuthManagerDrawer-28a2d108.mjs +114 -0
- package/AuthSetterModal-2990d553.mjs +261 -0
- package/CgformCopyList-36a4cbf0.mjs +246 -0
- package/CgformModal-7399a5ac.mjs +611 -0
- package/CgreportModal-2eb9c9e1.mjs +13 -0
- package/CgreportModal.vue_vue_type_script_setup_true_lang-c2ceb064.mjs +566 -0
- package/CheckDictTable-3a8a54b3.mjs +211 -0
- package/CodeFileListModal-72f0d3bb.mjs +158 -0
- package/CodeFileViewModal-9eb88c47.mjs +244 -0
- package/CodeGeneratorModal-a89958f5.mjs +233 -0
- package/CustomButtonList-c44aec5a.mjs +363 -0
- package/DBAttributeTable-7d285e8d.mjs +473 -0
- package/DbToOnlineModal-d23cbeb1.mjs +160 -0
- package/DetailForm-2901d215.mjs +461 -0
- package/EnhanceJavaModal-153899a9.mjs +264 -0
- package/EnhanceJsHistory-7f5db3b1.mjs +184 -0
- package/EnhanceJsModal-c2fb75b8.mjs +311 -0
- package/EnhanceSqlModal-965e9b0a.mjs +268 -0
- package/ExtendConfigModal-8f08466f.mjs +111 -0
- package/FieldExtendJsonModal-adfcf5a7.mjs +219 -0
- package/FileSelectModal-432d4521.mjs +103 -0
- package/ForeignKeyTable-faab7ccf.mjs +69 -0
- package/IndexTable-0a2d3718.mjs +89 -0
- package/JModalTip-e1938b49.mjs +46 -0
- package/JOnlineSearchSelect-7e908492.mjs +95 -0
- package/LeftDepart-54f245b3.mjs +82 -0
- package/LeftRole-c138f892.mjs +86 -0
- package/LeftUser-9c812f8a.mjs +105 -0
- package/LinkTableConfigModal-c2c5c7e6.mjs +230 -0
- package/LinkTableFieldConfigModal-a3553b1f.mjs +176 -0
- package/LinkTableListPiece-7f793b08.mjs +34 -0
- package/ModalFormDemo-65685b0e.mjs +78 -0
- package/OnlCgformErpList-52c87ed3.mjs +449 -0
- package/OnlCgformErpSubTable-6e7fb17b.mjs +398 -0
- package/OnlCgformInnerSubTable-f0727b8f.mjs +248 -0
- package/OnlCgformInnerTableList-9f89c173.mjs +430 -0
- package/OnlCgformTabList-15516315.mjs +390 -0
- package/OnlineAutoList-63a0224f.mjs +474 -0
- package/OnlineAutoModal-ffe19c3f.mjs +206 -0
- package/OnlineAutoTreeList-317c7105.mjs +495 -0
- package/OnlineCustomModal-3939ce78.mjs +227 -0
- package/OnlineDetailModal-bfb1375f.mjs +177 -0
- package/OnlineForm-069f6092.mjs +749 -0
- package/OnlineFormDetail-ad5735fb.mjs +296 -0
- package/OnlineQueryForm-0771c80f.mjs +385 -0
- package/OnlineSearchFormItem-0db5834f.mjs +348 -0
- package/OnlineSelectCascade-a05c30f4.mjs +159 -0
- package/OnlineSubFormDetail-583d01eb.mjs +142 -0
- package/OnlineTabAutoModal-747e071d.mjs +253 -0
- package/OnlineTabDetailModal-887f0174.mjs +222 -0
- package/OnlineTabForm-b1dcd4b4.mjs +765 -0
- package/OnlineTabFormDetail-8e494a96.mjs +323 -0
- package/PageAttributeTable-5966b201.mjs +404 -0
- package/ProcessOnlineForm-4382bea7.mjs +177 -0
- package/QueryTable-6e8053ad.mjs +115 -0
- package/README.md +2 -1
- package/SuperQuery-78db6998.mjs +841 -0
- package/SuperQueryValComponent-471110b5.mjs +8 -0
- package/SuperQueryValComponent.vue_vue_type_script_lang-e3ad7ee8.mjs +101 -0
- package/auth.api-d3a6c4b3.mjs +39 -0
- package/auth.data-8be5c9e3.mjs +141 -0
- package/{cgform.data.js → cgform.data-cbdd88c3.mjs} +93 -62
- package/constant-754f1a9d.mjs +9 -0
- package/enhance.api-138e6826.mjs +104 -0
- package/enhance.data-efc7e155.mjs +175 -0
- package/index-0a93652b.mjs +237 -0
- package/index-7e9a23f2.mjs +1494 -0
- package/index-b70302f2.mjs +56 -0
- package/main.index.js +7 -1
- package/package.json +1 -1
- package/style.css +1 -1
- package/useCgformList-0c603af1.mjs +424 -0
- package/useCustomHook-acb00837.mjs +53 -0
- package/useExtendComponent-aa1cdfc8.mjs +3917 -0
- package/useListButton-0f18bf6a.mjs +671 -0
- package/useOnlinePopEvent-687070b7.mjs +19 -0
- package/useOnlineTest-e4bd8be3.mjs +42 -0
- package/useSchemas-43429d80.mjs +685 -0
- package/useTableSync-774c3774.mjs +87 -0
- package/AuthButtonConfig.js +0 -147
- package/AuthButtonTree.js +0 -183
- package/AuthDataConfig.js +0 -246
- package/AuthDataTree.js +0 -160
- package/AuthFieldConfig.js +0 -170
- package/AuthFieldTree.js +0 -281
- package/AuthManagerDrawer.js +0 -125
- package/AuthSetterModal.js +0 -316
- package/CgformCopyList.js +0 -266
- package/CgformModal.js +0 -780
- package/CgreportModal.js +0 -667
- package/CheckDictTable.js +0 -242
- package/CodeFileListModal.js +0 -175
- package/CodeFileViewModal.js +0 -325
- package/CodeGeneratorModal.js +0 -297
- package/CustomButtonList.js +0 -410
- package/DBAttributeTable.js +0 -526
- package/DbToOnlineModal.js +0 -192
- package/DetailForm.js +0 -608
- package/EnhanceJavaModal.js +0 -298
- package/EnhanceJsHistory.js +0 -229
- package/EnhanceJsModal.js +0 -293
- package/EnhanceSqlModal.js +0 -299
- package/ExtendConfigModal.js +0 -151
- package/FieldExtendJsonModal.js +0 -283
- package/FileSelectModal.js +0 -102
- package/ForeignKeyTable.js +0 -79
- package/IndexTable.js +0 -97
- package/JModalTip.js +0 -54
- package/JOnlineSearchSelect.js +0 -115
- package/LICENSE +0 -9
- package/LeftDepart.js +0 -96
- package/LeftRole.js +0 -98
- package/LeftUser.js +0 -117
- package/LinkTableConfigModal.js +0 -289
- package/LinkTableFieldConfigModal.js +0 -218
- package/LinkTableListPiece.js +0 -36
- package/ModalFormDemo.js +0 -85
- package/OnlineAutoList.js +0 -523
- package/OnlineAutoModal.js +0 -226
- package/OnlineAutoTreeList.js +0 -552
- package/OnlineCustomModal.js +0 -286
- package/OnlineDetailModal.js +0 -190
- package/OnlineForm.js +0 -1016
- package/OnlineFormDetail.js +0 -347
- package/OnlineQueryForm.js +0 -484
- package/OnlineSearchFormItem.js +0 -436
- package/OnlineSelectCascade.js +0 -228
- package/OnlineSubFormDetail.js +0 -166
- package/PageAttributeTable.js +0 -486
- package/ProcessOnlineForm.js +0 -208
- package/QueryTable.js +0 -129
- package/SuperQuery.js +0 -1020
- package/SuperQueryValComponent.js +0 -8
- package/SuperQueryValComponent.vue_vue_type_script_lang.js +0 -168
- package/_arrayPush.js +0 -278
- package/_baseClone.js +0 -471
- package/_baseSlice.js +0 -18
- package/_commonjsHelpers.js +0 -5
- package/_flatRest.js +0 -174
- package/auth.api.js +0 -43
- package/auth.data.js +0 -142
- package/clipboard.js +0 -565
- package/enhance.api.js +0 -129
- package/enhance.data.js +0 -196
- package/index.js +0 -87
- package/index2.js +0 -340
- package/index3.js +0 -264
- package/isArray.js +0 -47
- package/omit.js +0 -60
- package/pick.js +0 -68
- package/toString.js +0 -31
- package/useCgformList.js +0 -470
- package/useExtendComponent.js +0 -5205
- package/useListButton.js +0 -923
- package/useOnlineTest.js +0 -44
- package/useSchemas.js +0 -653
- package/useTableSync.js +0 -117
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
var f = (n, r, o) => new Promise((s, c) => {
|
|
2
|
+
var i = (e) => {
|
|
3
|
+
try {
|
|
4
|
+
a(o.next(e));
|
|
5
|
+
} catch (t) {
|
|
6
|
+
c(t);
|
|
7
|
+
}
|
|
8
|
+
}, d = (e) => {
|
|
9
|
+
try {
|
|
10
|
+
a(o.throw(e));
|
|
11
|
+
} catch (t) {
|
|
12
|
+
c(t);
|
|
13
|
+
}
|
|
14
|
+
}, a = (e) => e.done ? s(e.value) : Promise.resolve(e.value).then(i, d);
|
|
15
|
+
a((o = o.apply(n, r)).next());
|
|
16
|
+
});
|
|
17
|
+
import { defineComponent as h, ref as u, resolveComponent as m, openBlock as y, createElementBlock as K, createBlock as _, withCtx as D, createVNode as v, normalizeStyle as S, createCommentVNode as k } from "vue";
|
|
18
|
+
import { queryTreeList as x } from "/@/api/common/api";
|
|
19
|
+
import { _ as C } from "./index-b70302f2.mjs";
|
|
20
|
+
import "/@/components/jeecg/OnLine/JPopupOnlReport.vue";
|
|
21
|
+
import "/@/hooks/web/useMessage";
|
|
22
|
+
import "vue-router";
|
|
23
|
+
const N = h({
|
|
24
|
+
name: "LeftDepart",
|
|
25
|
+
emits: ["select"],
|
|
26
|
+
setup(n, { emit: r }) {
|
|
27
|
+
const o = u([]), s = u([]), c = u([]);
|
|
28
|
+
function i(t, l) {
|
|
29
|
+
let p = l.node.dataRef;
|
|
30
|
+
s.value = [p.key], r("select", p.id);
|
|
31
|
+
}
|
|
32
|
+
d();
|
|
33
|
+
function d() {
|
|
34
|
+
return f(this, null, function* () {
|
|
35
|
+
let t = yield x();
|
|
36
|
+
o.value = [], t.forEach((l) => a(l));
|
|
37
|
+
});
|
|
38
|
+
}
|
|
39
|
+
function a(t, l = 1) {
|
|
40
|
+
if (t.slots = { icon: "depIcon" }, l === 1 && (o.value.push(t), c.value.push(t.id)), t.children && t.children.length > 0)
|
|
41
|
+
for (const p of t.children)
|
|
42
|
+
a(p, l + 1);
|
|
43
|
+
}
|
|
44
|
+
function e() {
|
|
45
|
+
s.value = [];
|
|
46
|
+
}
|
|
47
|
+
return {
|
|
48
|
+
treeData: o,
|
|
49
|
+
expandedKeys: c,
|
|
50
|
+
selectedKeys: s,
|
|
51
|
+
clearSelected: e,
|
|
52
|
+
onSelect: i
|
|
53
|
+
};
|
|
54
|
+
}
|
|
55
|
+
});
|
|
56
|
+
function $(n, r, o, s, c, i) {
|
|
57
|
+
const d = m("a-icon"), a = m("a-tree");
|
|
58
|
+
return y(), K("div", null, [
|
|
59
|
+
n.treeData.length > 0 ? (y(), _(a, {
|
|
60
|
+
key: 0,
|
|
61
|
+
showIcon: "",
|
|
62
|
+
autoExpandParent: "",
|
|
63
|
+
treeData: n.treeData,
|
|
64
|
+
selectedKeys: n.selectedKeys,
|
|
65
|
+
expandedKeys: n.expandedKeys,
|
|
66
|
+
"onUpdate:expandedKeys": r[0] || (r[0] = (e) => n.expandedKeys = e),
|
|
67
|
+
onSelect: n.onSelect
|
|
68
|
+
}, {
|
|
69
|
+
depIcon: D(({ selected: e }) => [
|
|
70
|
+
v(d, {
|
|
71
|
+
style: S({ color: e ? "blue" : "" }),
|
|
72
|
+
type: "apartment"
|
|
73
|
+
}, null, 8, ["style"])
|
|
74
|
+
]),
|
|
75
|
+
_: 1
|
|
76
|
+
}, 8, ["treeData", "selectedKeys", "expandedKeys", "onSelect"])) : k("", !0)
|
|
77
|
+
]);
|
|
78
|
+
}
|
|
79
|
+
const V = /* @__PURE__ */ C(N, [["render", $]]);
|
|
80
|
+
export {
|
|
81
|
+
V as default
|
|
82
|
+
};
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
var m = (r, l, o) => new Promise((i, n) => {
|
|
2
|
+
var c = (e) => {
|
|
3
|
+
try {
|
|
4
|
+
a(o.next(e));
|
|
5
|
+
} catch (t) {
|
|
6
|
+
n(t);
|
|
7
|
+
}
|
|
8
|
+
}, s = (e) => {
|
|
9
|
+
try {
|
|
10
|
+
a(o.throw(e));
|
|
11
|
+
} catch (t) {
|
|
12
|
+
n(t);
|
|
13
|
+
}
|
|
14
|
+
}, a = (e) => e.done ? i(e.value) : Promise.resolve(e.value).then(c, s);
|
|
15
|
+
a((o = o.apply(r, l)).next());
|
|
16
|
+
});
|
|
17
|
+
import { defineComponent as g, resolveComponent as _, openBlock as w, createBlock as b, withCtx as S, createElementVNode as T } from "vue";
|
|
18
|
+
import { defHttp as h } from "/@/utils/http/axios";
|
|
19
|
+
import { BasicTable as C } from "/@/components/Table";
|
|
20
|
+
import { useListPage as R } from "/@/hooks/system/useListPage";
|
|
21
|
+
import { _ as x } from "./index-b70302f2.mjs";
|
|
22
|
+
import "/@/components/jeecg/OnLine/JPopupOnlReport.vue";
|
|
23
|
+
import "/@/hooks/web/useMessage";
|
|
24
|
+
import "vue-router";
|
|
25
|
+
const B = g({
|
|
26
|
+
name: "LeftRole",
|
|
27
|
+
components: { BasicTable: C },
|
|
28
|
+
emits: ["select"],
|
|
29
|
+
setup(r, { emit: l }) {
|
|
30
|
+
const { tableContext: o, createMessage: i } = R({
|
|
31
|
+
tableProps: {
|
|
32
|
+
api: a,
|
|
33
|
+
rowKey: "id",
|
|
34
|
+
size: "small",
|
|
35
|
+
bordered: !0,
|
|
36
|
+
columns: [
|
|
37
|
+
{ title: "角色编码", align: "center", dataIndex: "roleCode" },
|
|
38
|
+
{ title: "角色名称", align: "center", dataIndex: "roleName" }
|
|
39
|
+
],
|
|
40
|
+
rowSelection: {
|
|
41
|
+
type: "radio",
|
|
42
|
+
onChange(t) {
|
|
43
|
+
t.length > 0 && l("select", t[0]);
|
|
44
|
+
}
|
|
45
|
+
},
|
|
46
|
+
canResize: !1,
|
|
47
|
+
clickToRowSelect: !0,
|
|
48
|
+
useSearchForm: !1,
|
|
49
|
+
showActionColumn: !1,
|
|
50
|
+
showTableSetting: !1
|
|
51
|
+
}
|
|
52
|
+
}), [n, { clearSelectedRowKeys: c }, { rowSelection: s }] = o;
|
|
53
|
+
function a(t) {
|
|
54
|
+
return m(this, null, function* () {
|
|
55
|
+
let { code: p, success: f, result: u, message: d } = yield h.get(
|
|
56
|
+
{
|
|
57
|
+
url: "/sys/role/list",
|
|
58
|
+
params: t
|
|
59
|
+
},
|
|
60
|
+
{ isTransformResponse: !1 }
|
|
61
|
+
);
|
|
62
|
+
return f ? u : (p === 510 && i.warning(d), {});
|
|
63
|
+
});
|
|
64
|
+
}
|
|
65
|
+
function e() {
|
|
66
|
+
c();
|
|
67
|
+
}
|
|
68
|
+
return { rowSelection: s, registerTable: n, clearSelected: e };
|
|
69
|
+
}
|
|
70
|
+
}), $ = /* @__PURE__ */ T("span", null, null, -1);
|
|
71
|
+
function y(r, l, o, i, n, c) {
|
|
72
|
+
const s = _("BasicTable");
|
|
73
|
+
return w(), b(s, {
|
|
74
|
+
onRegister: r.registerTable,
|
|
75
|
+
rowSelection: r.rowSelection
|
|
76
|
+
}, {
|
|
77
|
+
tableTop: S(() => [
|
|
78
|
+
$
|
|
79
|
+
]),
|
|
80
|
+
_: 1
|
|
81
|
+
}, 8, ["onRegister", "rowSelection"]);
|
|
82
|
+
}
|
|
83
|
+
const E = /* @__PURE__ */ x(B, [["render", y]]);
|
|
84
|
+
export {
|
|
85
|
+
E as default
|
|
86
|
+
};
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
var m = (n, l, o) => new Promise((i, r) => {
|
|
2
|
+
var c = (e) => {
|
|
3
|
+
try {
|
|
4
|
+
a(o.next(e));
|
|
5
|
+
} catch (t) {
|
|
6
|
+
r(t);
|
|
7
|
+
}
|
|
8
|
+
}, s = (e) => {
|
|
9
|
+
try {
|
|
10
|
+
a(o.throw(e));
|
|
11
|
+
} catch (t) {
|
|
12
|
+
r(t);
|
|
13
|
+
}
|
|
14
|
+
}, a = (e) => e.done ? i(e.value) : Promise.resolve(e.value).then(c, s);
|
|
15
|
+
a((o = o.apply(n, l)).next());
|
|
16
|
+
});
|
|
17
|
+
import { defineComponent as g, resolveComponent as w, openBlock as _, createBlock as b, withCtx as h, createElementVNode as S } from "vue";
|
|
18
|
+
import { defHttp as T } from "/@/utils/http/axios";
|
|
19
|
+
import { BasicTable as C } from "/@/components/Table";
|
|
20
|
+
import { useListPage as x } from "/@/hooks/system/useListPage";
|
|
21
|
+
import { _ as B } from "./index-b70302f2.mjs";
|
|
22
|
+
import "/@/components/jeecg/OnLine/JPopupOnlReport.vue";
|
|
23
|
+
import "/@/hooks/web/useMessage";
|
|
24
|
+
import "vue-router";
|
|
25
|
+
const R = g({
|
|
26
|
+
name: "LeftUser",
|
|
27
|
+
components: { BasicTable: C },
|
|
28
|
+
emits: ["select"],
|
|
29
|
+
setup(n, { emit: l }) {
|
|
30
|
+
const { tableContext: o, createMessage: i } = x({
|
|
31
|
+
tableProps: {
|
|
32
|
+
api: a,
|
|
33
|
+
rowKey: "id",
|
|
34
|
+
size: "small",
|
|
35
|
+
bordered: !0,
|
|
36
|
+
columns: [
|
|
37
|
+
{ title: "账号", dataIndex: "username", width: 200 },
|
|
38
|
+
{ title: "姓名", dataIndex: "realname", width: 200 }
|
|
39
|
+
],
|
|
40
|
+
rowSelection: {
|
|
41
|
+
type: "radio",
|
|
42
|
+
onChange(t) {
|
|
43
|
+
t.length > 0 && l("select", t[0]);
|
|
44
|
+
}
|
|
45
|
+
},
|
|
46
|
+
formConfig: {
|
|
47
|
+
schemas: [
|
|
48
|
+
{
|
|
49
|
+
label: "账号",
|
|
50
|
+
field: "username",
|
|
51
|
+
component: "JInput",
|
|
52
|
+
componentProps: {
|
|
53
|
+
placeholder: "输入账号模糊查询"
|
|
54
|
+
}
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
label: "姓名",
|
|
58
|
+
field: "realname",
|
|
59
|
+
component: "JInput",
|
|
60
|
+
componentProps: {
|
|
61
|
+
placeholder: "输入姓名模糊查询"
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
]
|
|
65
|
+
},
|
|
66
|
+
canResize: !1,
|
|
67
|
+
clickToRowSelect: !0,
|
|
68
|
+
showActionColumn: !1,
|
|
69
|
+
showTableSetting: !1
|
|
70
|
+
}
|
|
71
|
+
}), [r, { clearSelectedRowKeys: c }, { rowSelection: s }] = o;
|
|
72
|
+
function a(t) {
|
|
73
|
+
return m(this, null, function* () {
|
|
74
|
+
let { code: p, success: f, result: d, message: u } = yield T.get(
|
|
75
|
+
{
|
|
76
|
+
url: "/sys/user/list",
|
|
77
|
+
params: t
|
|
78
|
+
},
|
|
79
|
+
{ isTransformResponse: !1 }
|
|
80
|
+
);
|
|
81
|
+
return f ? d : (p === 510 && i.warning(u), {});
|
|
82
|
+
});
|
|
83
|
+
}
|
|
84
|
+
function e() {
|
|
85
|
+
c();
|
|
86
|
+
}
|
|
87
|
+
return { rowSelection: s, registerTable: r, clearSelected: e };
|
|
88
|
+
}
|
|
89
|
+
}), $ = /* @__PURE__ */ S("span", null, null, -1);
|
|
90
|
+
function y(n, l, o, i, r, c) {
|
|
91
|
+
const s = w("BasicTable");
|
|
92
|
+
return _(), b(s, {
|
|
93
|
+
onRegister: n.registerTable,
|
|
94
|
+
rowSelection: n.rowSelection
|
|
95
|
+
}, {
|
|
96
|
+
tableTop: h(() => [
|
|
97
|
+
$
|
|
98
|
+
]),
|
|
99
|
+
_: 1
|
|
100
|
+
}, 8, ["onRegister", "rowSelection"]);
|
|
101
|
+
}
|
|
102
|
+
const D = /* @__PURE__ */ B(R, [["render", y]]);
|
|
103
|
+
export {
|
|
104
|
+
D as default
|
|
105
|
+
};
|
|
@@ -0,0 +1,230 @@
|
|
|
1
|
+
var I = Object.defineProperty;
|
|
2
|
+
var w = Object.getOwnPropertySymbols;
|
|
3
|
+
var L = Object.prototype.hasOwnProperty, R = Object.prototype.propertyIsEnumerable;
|
|
4
|
+
var C = (o, a, l) => a in o ? I(o, a, { enumerable: !0, configurable: !0, writable: !0, value: l }) : o[a] = l, y = (o, a) => {
|
|
5
|
+
for (var l in a || (a = {}))
|
|
6
|
+
L.call(a, l) && C(o, l, a[l]);
|
|
7
|
+
if (w)
|
|
8
|
+
for (var l of w(a))
|
|
9
|
+
R.call(a, l) && C(o, l, a[l]);
|
|
10
|
+
return o;
|
|
11
|
+
};
|
|
12
|
+
var m = (o, a, l) => new Promise((r, n) => {
|
|
13
|
+
var b = (t) => {
|
|
14
|
+
try {
|
|
15
|
+
s(l.next(t));
|
|
16
|
+
} catch (d) {
|
|
17
|
+
n(d);
|
|
18
|
+
}
|
|
19
|
+
}, f = (t) => {
|
|
20
|
+
try {
|
|
21
|
+
s(l.throw(t));
|
|
22
|
+
} catch (d) {
|
|
23
|
+
n(d);
|
|
24
|
+
}
|
|
25
|
+
}, s = (t) => t.done ? r(t.value) : Promise.resolve(t.value).then(b, f);
|
|
26
|
+
s((l = l.apply(o, a)).next());
|
|
27
|
+
});
|
|
28
|
+
import { BasicModal as J, useModalInner as q } from "/@/components/Modal";
|
|
29
|
+
import { ref as u, computed as G, resolveComponent as h, openBlock as H, createBlock as K, mergeProps as z, withCtx as k, createVNode as S } from "vue";
|
|
30
|
+
import { BasicForm as A, useForm as $ } from "/@/components/Form/index";
|
|
31
|
+
import { defHttp as j } from "/@/utils/http/axios";
|
|
32
|
+
import { omit as D } from "lodash-es";
|
|
33
|
+
import { _ as E } from "./index-b70302f2.mjs";
|
|
34
|
+
import "/@/components/jeecg/OnLine/JPopupOnlReport.vue";
|
|
35
|
+
import "/@/hooks/web/useMessage";
|
|
36
|
+
import "vue-router";
|
|
37
|
+
const Q = {
|
|
38
|
+
name: "LinkTableConfigModal",
|
|
39
|
+
emits: ["success", "register"],
|
|
40
|
+
components: {
|
|
41
|
+
BasicModal: J,
|
|
42
|
+
BasicForm: A
|
|
43
|
+
},
|
|
44
|
+
setup(o, { emit: a }) {
|
|
45
|
+
const l = u(!1), r = u("");
|
|
46
|
+
let n = {};
|
|
47
|
+
const [b, { closeModal: f }] = q((e) => m(this, null, function* () {
|
|
48
|
+
n = y({}, e.record), yield v({ dictTable: e.record.dictTable }), setTimeout(() => m(this, null, function* () {
|
|
49
|
+
let c = D(e.record, "dictTable");
|
|
50
|
+
yield v(c), yield P();
|
|
51
|
+
}), 200), r.value = e.fieldName;
|
|
52
|
+
})), s = u(""), t = u(""), d = u([]), F = u([]);
|
|
53
|
+
function T(e) {
|
|
54
|
+
return m(this, null, function* () {
|
|
55
|
+
if (e) {
|
|
56
|
+
const c = "/online/cgform/field/listByHeadCode", p = yield j.get({ url: c, params: { headCode: e } });
|
|
57
|
+
if (p && p.length > 0) {
|
|
58
|
+
let g = p.filter((i) => i.dbFieldName != "id" && i.dbIsPersist == 1);
|
|
59
|
+
g.length > 0 ? d.value = g.map((i) => ({
|
|
60
|
+
text: i.dbFieldTxt,
|
|
61
|
+
value: i.dbFieldName
|
|
62
|
+
})) : d.value = [];
|
|
63
|
+
let _ = p.filter((i) => i.dbFieldName != "id" && i.fieldShowType == "image" && i.dbIsPersist == 1);
|
|
64
|
+
_.length > 0 ? F.value = _.map((i) => ({
|
|
65
|
+
text: i.dbFieldTxt,
|
|
66
|
+
value: i.dbFieldName
|
|
67
|
+
})) : F.value = [{ text: "无图片字段可以选择", value: "", key: "", disabled: !0 }];
|
|
68
|
+
} else
|
|
69
|
+
d.value = [], F.value = [{ text: "无图片字段可以选择", value: "", key: "", disabled: !0 }];
|
|
70
|
+
}
|
|
71
|
+
});
|
|
72
|
+
}
|
|
73
|
+
function x(e) {
|
|
74
|
+
return m(this, null, function* () {
|
|
75
|
+
s.value = "", t.value = "", yield T(e);
|
|
76
|
+
});
|
|
77
|
+
}
|
|
78
|
+
const V = G(() => {
|
|
79
|
+
let e = d.value, c = s.value, p = t.value;
|
|
80
|
+
return e.filter((g) => g.value != c && g.value != p);
|
|
81
|
+
}), N = [
|
|
82
|
+
{
|
|
83
|
+
label: "rowKey",
|
|
84
|
+
field: "rowKey",
|
|
85
|
+
component: "Input",
|
|
86
|
+
show: !1
|
|
87
|
+
},
|
|
88
|
+
{
|
|
89
|
+
label: "dictField",
|
|
90
|
+
field: "dictField",
|
|
91
|
+
component: "Input",
|
|
92
|
+
defaultValue: "id",
|
|
93
|
+
show: !1
|
|
94
|
+
},
|
|
95
|
+
{
|
|
96
|
+
label: "字段描述",
|
|
97
|
+
field: "dbFieldTxt",
|
|
98
|
+
component: "Input",
|
|
99
|
+
required: !0
|
|
100
|
+
},
|
|
101
|
+
{
|
|
102
|
+
label: "关联表",
|
|
103
|
+
field: "dictTable",
|
|
104
|
+
component: "JSearchSelect",
|
|
105
|
+
required: !0,
|
|
106
|
+
componentProps: ({ formActionType: e }) => ({
|
|
107
|
+
dict: "onl_cgform_head where copy_type = 0,table_txt,table_name",
|
|
108
|
+
pageSize: 10,
|
|
109
|
+
async: !0,
|
|
110
|
+
immediateChange: !0,
|
|
111
|
+
popContainer: ".link-table-config-modal",
|
|
112
|
+
params: { order: "desc", column: "create_time" },
|
|
113
|
+
onChange: (c) => m(this, null, function* () {
|
|
114
|
+
(n.titleField || n.otherFields) && (yield e.setFieldsValue({
|
|
115
|
+
titleField: "",
|
|
116
|
+
otherFields: "",
|
|
117
|
+
imageField: ""
|
|
118
|
+
}), yield e.clearValidate()), yield x(c);
|
|
119
|
+
})
|
|
120
|
+
})
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
label: "标题字段",
|
|
124
|
+
field: "titleField",
|
|
125
|
+
component: "JSearchSelect",
|
|
126
|
+
required: !0,
|
|
127
|
+
componentProps: {
|
|
128
|
+
async: !1,
|
|
129
|
+
popContainer: ".link-table-config-modal",
|
|
130
|
+
dictOptions: d,
|
|
131
|
+
immediateChange: !0,
|
|
132
|
+
onChange: (e) => {
|
|
133
|
+
s.value = e, n.titleField = e;
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
},
|
|
137
|
+
{
|
|
138
|
+
label: "封面图片",
|
|
139
|
+
field: "imageField",
|
|
140
|
+
component: "JSearchSelect",
|
|
141
|
+
componentProps: {
|
|
142
|
+
async: !1,
|
|
143
|
+
popContainer: ".link-table-config-modal",
|
|
144
|
+
dictOptions: F,
|
|
145
|
+
immediateChange: !0,
|
|
146
|
+
onChange: (e) => {
|
|
147
|
+
t.value = e, n.imageFieldName = e;
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
},
|
|
151
|
+
{
|
|
152
|
+
label: "其他字段",
|
|
153
|
+
field: "otherFields",
|
|
154
|
+
component: "JSelectMultiple",
|
|
155
|
+
componentProps: {
|
|
156
|
+
popContainer: ".link-table-config-modal",
|
|
157
|
+
options: V,
|
|
158
|
+
onChange: (e) => {
|
|
159
|
+
n.otherFields = e;
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
},
|
|
163
|
+
{
|
|
164
|
+
label: "显示方式",
|
|
165
|
+
field: "showType",
|
|
166
|
+
component: "Select",
|
|
167
|
+
defaultValue: "card",
|
|
168
|
+
componentProps: {
|
|
169
|
+
options: [
|
|
170
|
+
{ label: "卡片", value: "card" },
|
|
171
|
+
{ label: "下拉框", value: "select" }
|
|
172
|
+
]
|
|
173
|
+
}
|
|
174
|
+
},
|
|
175
|
+
{
|
|
176
|
+
label: "是否多选",
|
|
177
|
+
field: "multiSelect",
|
|
178
|
+
component: "RadioGroup",
|
|
179
|
+
defaultValue: !1,
|
|
180
|
+
componentProps: {
|
|
181
|
+
options: [
|
|
182
|
+
{ label: "否", value: !1 },
|
|
183
|
+
{ label: "是", value: !0 }
|
|
184
|
+
]
|
|
185
|
+
}
|
|
186
|
+
}
|
|
187
|
+
], [B, { validate: M, setFieldsValue: v, clearValidate: P, resetFields: W }] = $({
|
|
188
|
+
schemas: N,
|
|
189
|
+
showActionButtonGroup: !1,
|
|
190
|
+
labelAlign: "right"
|
|
191
|
+
});
|
|
192
|
+
function O() {
|
|
193
|
+
return m(this, null, function* () {
|
|
194
|
+
let e = yield M();
|
|
195
|
+
e.fieldName = r.value, a("success", e), f();
|
|
196
|
+
});
|
|
197
|
+
}
|
|
198
|
+
return {
|
|
199
|
+
registerModal: b,
|
|
200
|
+
spinningLoading: l,
|
|
201
|
+
registerForm: B,
|
|
202
|
+
handleSubmit: O
|
|
203
|
+
};
|
|
204
|
+
}
|
|
205
|
+
};
|
|
206
|
+
function U(o, a, l, r, n, b) {
|
|
207
|
+
const f = h("BasicForm"), s = h("a-spin"), t = h("BasicModal");
|
|
208
|
+
return H(), K(t, z({ wrapClassName: "link-table-config-modal" }, o.$attrs, {
|
|
209
|
+
title: "关联记录配置",
|
|
210
|
+
onRegister: r.registerModal,
|
|
211
|
+
keyboard: "",
|
|
212
|
+
canFullscreen: !1,
|
|
213
|
+
cancelText: "关闭",
|
|
214
|
+
onOk: r.handleSubmit
|
|
215
|
+
}), {
|
|
216
|
+
default: k(() => [
|
|
217
|
+
S(s, { spinning: r.spinningLoading }, {
|
|
218
|
+
default: k(() => [
|
|
219
|
+
S(f, { onRegister: r.registerForm }, null, 8, ["onRegister"])
|
|
220
|
+
]),
|
|
221
|
+
_: 1
|
|
222
|
+
}, 8, ["spinning"])
|
|
223
|
+
]),
|
|
224
|
+
_: 1
|
|
225
|
+
}, 16, ["onRegister", "onOk"]);
|
|
226
|
+
}
|
|
227
|
+
const re = /* @__PURE__ */ E(Q, [["render", U]]);
|
|
228
|
+
export {
|
|
229
|
+
re as default
|
|
230
|
+
};
|
|
@@ -0,0 +1,176 @@
|
|
|
1
|
+
var R = Object.defineProperty;
|
|
2
|
+
var F = Object.getOwnPropertySymbols;
|
|
3
|
+
var q = Object.prototype.hasOwnProperty, I = Object.prototype.propertyIsEnumerable;
|
|
4
|
+
var w = (o, a, t) => a in o ? R(o, a, { enumerable: !0, configurable: !0, writable: !0, value: t }) : o[a] = t, T = (o, a) => {
|
|
5
|
+
for (var t in a || (a = {}))
|
|
6
|
+
q.call(a, t) && w(o, t, a[t]);
|
|
7
|
+
if (F)
|
|
8
|
+
for (var t of F(a))
|
|
9
|
+
I.call(a, t) && w(o, t, a[t]);
|
|
10
|
+
return o;
|
|
11
|
+
};
|
|
12
|
+
var p = (o, a, t) => new Promise((i, s) => {
|
|
13
|
+
var r = (n) => {
|
|
14
|
+
try {
|
|
15
|
+
d(t.next(n));
|
|
16
|
+
} catch (f) {
|
|
17
|
+
s(f);
|
|
18
|
+
}
|
|
19
|
+
}, c = (n) => {
|
|
20
|
+
try {
|
|
21
|
+
d(t.throw(n));
|
|
22
|
+
} catch (f) {
|
|
23
|
+
s(f);
|
|
24
|
+
}
|
|
25
|
+
}, d = (n) => n.done ? i(n.value) : Promise.resolve(n.value).then(r, c);
|
|
26
|
+
d((t = t.apply(o, a)).next());
|
|
27
|
+
});
|
|
28
|
+
import { BasicModal as P, useModalInner as H } from "/@/components/Modal";
|
|
29
|
+
import { ref as b, resolveComponent as h, openBlock as J, createBlock as K, mergeProps as N, withCtx as k, createVNode as x } from "vue";
|
|
30
|
+
import { BasicForm as $, useForm as j } from "/@/components/Form/index";
|
|
31
|
+
import { defHttp as G } from "/@/utils/http/axios";
|
|
32
|
+
import { omit as z } from "lodash-es";
|
|
33
|
+
import { useMessage as D } from "/@/hooks/web/useMessage";
|
|
34
|
+
import { _ as E } from "./index-b70302f2.mjs";
|
|
35
|
+
import "/@/components/jeecg/OnLine/JPopupOnlReport.vue";
|
|
36
|
+
import "vue-router";
|
|
37
|
+
const Q = {
|
|
38
|
+
name: "LinkTableFieldConfigModal",
|
|
39
|
+
emits: ["success", "register"],
|
|
40
|
+
components: {
|
|
41
|
+
BasicModal: P,
|
|
42
|
+
BasicForm: $
|
|
43
|
+
},
|
|
44
|
+
setup(o, { emit: a }) {
|
|
45
|
+
const t = b(!1), i = b([]), s = b([]);
|
|
46
|
+
let r = {}, c = {};
|
|
47
|
+
const { createMessage: d } = D(), [n, { closeModal: f }] = H((e) => p(this, null, function* () {
|
|
48
|
+
c = T({}, e.record), r = e.tableAndFieldsMap, yield y(), yield _({ dictTable: e.record.dictTable }), setTimeout(() => p(this, null, function* () {
|
|
49
|
+
let l = z(e.record, "dictTable");
|
|
50
|
+
yield _(l), yield B();
|
|
51
|
+
}), 200);
|
|
52
|
+
}));
|
|
53
|
+
function y() {
|
|
54
|
+
return p(this, null, function* () {
|
|
55
|
+
let e = Object.keys(r);
|
|
56
|
+
if (!e || e.length == 0)
|
|
57
|
+
i.value = [];
|
|
58
|
+
else {
|
|
59
|
+
let l = [];
|
|
60
|
+
for (let m of e)
|
|
61
|
+
l.push({
|
|
62
|
+
text: r[m].title,
|
|
63
|
+
value: m
|
|
64
|
+
});
|
|
65
|
+
i.value = l;
|
|
66
|
+
}
|
|
67
|
+
});
|
|
68
|
+
}
|
|
69
|
+
function C(e) {
|
|
70
|
+
return p(this, null, function* () {
|
|
71
|
+
if (e) {
|
|
72
|
+
const { table: l, fields: m } = r[e];
|
|
73
|
+
if (!l) {
|
|
74
|
+
d.warning("请先完善字段[" + e + "]关联记录的配置");
|
|
75
|
+
return;
|
|
76
|
+
}
|
|
77
|
+
const V = "/online/cgform/field/listByHeadCode", g = yield G.get({ url: V, params: { headCode: l } });
|
|
78
|
+
if (g && g.length > 0) {
|
|
79
|
+
let L = g.map((u) => ({
|
|
80
|
+
text: u.dbFieldTxt,
|
|
81
|
+
value: u.dbFieldName
|
|
82
|
+
})), A = m.split(",");
|
|
83
|
+
s.value = L.filter((u) => A.indexOf(u.value) > 0);
|
|
84
|
+
} else
|
|
85
|
+
s.value = [];
|
|
86
|
+
}
|
|
87
|
+
});
|
|
88
|
+
}
|
|
89
|
+
const M = [
|
|
90
|
+
{
|
|
91
|
+
label: "rowKey",
|
|
92
|
+
field: "rowKey",
|
|
93
|
+
component: "Input",
|
|
94
|
+
show: !1
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
label: "字段描述",
|
|
98
|
+
field: "dbFieldTxt",
|
|
99
|
+
component: "Input",
|
|
100
|
+
required: !0
|
|
101
|
+
},
|
|
102
|
+
{
|
|
103
|
+
label: "关联记录",
|
|
104
|
+
field: "dictTable",
|
|
105
|
+
component: "JSearchSelect",
|
|
106
|
+
required: !0,
|
|
107
|
+
componentProps: ({ formActionType: e }) => ({
|
|
108
|
+
async: !1,
|
|
109
|
+
popContainer: ".link-table-field-config-modal",
|
|
110
|
+
dictOptions: i.value,
|
|
111
|
+
immediateChange: !0,
|
|
112
|
+
onChange: (m) => p(this, null, function* () {
|
|
113
|
+
c.dictText && (yield e.setFieldsValue({
|
|
114
|
+
dictText: ""
|
|
115
|
+
}), yield e.clearValidate()), C(m);
|
|
116
|
+
})
|
|
117
|
+
})
|
|
118
|
+
},
|
|
119
|
+
{
|
|
120
|
+
label: "显示字段",
|
|
121
|
+
field: "dictText",
|
|
122
|
+
component: "JSearchSelect",
|
|
123
|
+
required: !0,
|
|
124
|
+
componentProps: {
|
|
125
|
+
async: !1,
|
|
126
|
+
popContainer: ".link-table-field-config-modal",
|
|
127
|
+
dictOptions: s,
|
|
128
|
+
onChange: (e) => {
|
|
129
|
+
c.dictText = e;
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
], [O, { validate: v, setFieldsValue: _, clearValidate: B }] = j({
|
|
134
|
+
schemas: M,
|
|
135
|
+
showActionButtonGroup: !1,
|
|
136
|
+
labelAlign: "right"
|
|
137
|
+
});
|
|
138
|
+
function S() {
|
|
139
|
+
return p(this, null, function* () {
|
|
140
|
+
const e = yield v();
|
|
141
|
+
a("success", e), f();
|
|
142
|
+
});
|
|
143
|
+
}
|
|
144
|
+
return {
|
|
145
|
+
registerModal: n,
|
|
146
|
+
spinningLoading: t,
|
|
147
|
+
registerForm: O,
|
|
148
|
+
handleSubmit: S
|
|
149
|
+
};
|
|
150
|
+
}
|
|
151
|
+
};
|
|
152
|
+
function U(o, a, t, i, s, r) {
|
|
153
|
+
const c = h("BasicForm"), d = h("a-spin"), n = h("BasicModal");
|
|
154
|
+
return J(), K(n, N({ wrapClassName: "link-table-field-config-modal" }, o.$attrs, {
|
|
155
|
+
title: "他表字段配置",
|
|
156
|
+
onRegister: i.registerModal,
|
|
157
|
+
keyboard: "",
|
|
158
|
+
canFullscreen: !1,
|
|
159
|
+
cancelText: "关闭",
|
|
160
|
+
onOk: i.handleSubmit
|
|
161
|
+
}), {
|
|
162
|
+
default: k(() => [
|
|
163
|
+
x(d, { spinning: i.spinningLoading }, {
|
|
164
|
+
default: k(() => [
|
|
165
|
+
x(c, { onRegister: i.registerForm }, null, 8, ["onRegister"])
|
|
166
|
+
]),
|
|
167
|
+
_: 1
|
|
168
|
+
}, 8, ["spinning"])
|
|
169
|
+
]),
|
|
170
|
+
_: 1
|
|
171
|
+
}, 16, ["onRegister", "onOk"]);
|
|
172
|
+
}
|
|
173
|
+
const le = /* @__PURE__ */ E(Q, [["render", U]]);
|
|
174
|
+
export {
|
|
175
|
+
le as default
|
|
176
|
+
};
|