@jeecg/online 3.7.4 → 3.9.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/{AccountLoginForm-d2fed52f.mjs → AccountLoginForm-cbc75a49.mjs} +1 -1
- package/{AiModal-fbe4b68a.mjs → AiModal-5bec5218.mjs} +1 -1
- package/{AppForgetPassword-3b3bec82.mjs → AppForgetPassword-dbc8377e.mjs} +2 -2
- package/{AppLogin-cd2e2a87.mjs → AppLogin-786949d3.mjs} +9 -9
- package/{AppLoginHeader-9b5be678.mjs → AppLoginHeader-37034b2f.mjs} +1 -1
- package/{AppNameEmail-b4e32ae8.mjs → AppNameEmail-7c6a1406.mjs} +2 -2
- package/{AppRegister-7117b66a.mjs → AppRegister-29a00a9d.mjs} +3 -3
- package/{AppTenant-5817729b.mjs → AppTenant-92890383.mjs} +2 -2
- package/{AppThirdForm-d14fb5e5.mjs → AppThirdForm-760064e5.mjs} +1 -1
- package/{AuthButtonConfig-5e3b6d72.mjs → AuthButtonConfig-78180aec.mjs} +50 -46
- package/{AuthButtonTree-7b4ec967.mjs → AuthButtonTree-62c8e70c.mjs} +2 -2
- package/{AuthDataConfig-48ee9228.mjs → AuthDataConfig-c978c469.mjs} +2 -2
- package/{AuthDataTree-02b3ba05.mjs → AuthDataTree-0647a06c.mjs} +1 -1
- package/{AuthFieldConfig-562cc6b6.mjs → AuthFieldConfig-558283bc.mjs} +2 -2
- package/{AuthFieldTree-2d458c0c.mjs → AuthFieldTree-106db4e2.mjs} +1 -1
- package/{AuthManagerDrawer-38299230.mjs → AuthManagerDrawer-ec5190d2.mjs} +5 -5
- package/{AuthSetterModal-78b06703.mjs → AuthSetterModal-90a76886.mjs} +8 -8
- package/CgformAddressModal-690b8940.mjs +263 -0
- package/CgformCopyList-af9c99a4.mjs +260 -0
- package/{CgformModal-12951453.mjs → CgformModal-b04a492a.mjs} +73 -70
- package/CgreportAigcModal-8fdcbd31.mjs +211 -0
- package/{CgreportModal-bfeb93ed.mjs → CgreportModal-da62724c.mjs} +123 -119
- package/{CheckDictTable-3c1e59e0.mjs → CheckDictTable-7320189b.mjs} +2 -2
- package/{CodeFileListModal-71752603.mjs → CodeFileListModal-e5ec210d.mjs} +2 -2
- package/CodeFileViewModal-09053f3a.mjs +269 -0
- package/CodeGeneratorModal-aba790e3.mjs +298 -0
- package/{CustomButtonList-22b5cdb3.mjs → CustomButtonList-704e6d1c.mjs} +1 -1
- package/{DBAttributeTable-eb25565c.mjs → DBAttributeTable-4a65c897.mjs} +176 -131
- package/{DbToOnlineModal-049b4bbd.mjs → DbToOnlineModal-cc398c70.mjs} +1 -1
- package/{DetailForm-c127c27f.mjs → DetailForm-a2bf8c33.mjs} +165 -153
- package/{DropMenuItem-b1a8f47d.mjs → DropMenuItem-884f9464.mjs} +1 -1
- package/{EnhanceJavaModal-1a4d696b.mjs → EnhanceJavaModal-fe8d475d.mjs} +1 -1
- package/{EnhanceJsHistory-48cf43ad.mjs → EnhanceJsHistory-95ca545c.mjs} +2 -2
- package/{EnhanceJsModal-0e1f15f8.mjs → EnhanceJsModal-742b0ee2.mjs} +17 -16
- package/{EnhanceSqlModal-6a1aa471.mjs → EnhanceSqlModal-6e36bc4f.mjs} +1 -1
- package/{ExtendConfigModal-37af21a5.mjs → ExtendConfigModal-74d657c7.mjs} +2 -2
- package/{FieldExtendJsonModal-9441e08e.mjs → FieldExtendJsonModal-fe7f7902.mjs} +2 -2
- package/{FileSelectModal-04490919.mjs → FileSelectModal-cf41604b.mjs} +1 -1
- package/{ForeignKeyTable-06300a47.mjs → ForeignKeyTable-4a59ded1.mjs} +2 -2
- package/{IndexTable-79bddd5c.mjs → IndexTable-87d67830.mjs} +2 -2
- package/{JModalTip-192fafa1.mjs → JModalTip-5401f43d.mjs} +1 -1
- package/{JOnlineSearchSelect-9abcf657.mjs → JOnlineSearchSelect-d8c57973.mjs} +1 -1
- package/{LeftDepart-35d78655.mjs → LeftDepart-463bf432.mjs} +1 -1
- package/{LeftRole-9d88976d.mjs → LeftRole-1631d3d4.mjs} +1 -1
- package/{LeftUser-04c89aea.mjs → LeftUser-5774a5db.mjs} +1 -1
- package/{LinkTableConfigModal-5f94ef13.mjs → LinkTableConfigModal-1bab1423.mjs} +1 -1
- package/{LinkTableFieldConfigModal-40753de5.mjs → LinkTableFieldConfigModal-49470140.mjs} +1 -1
- package/{LinkTableListPiece-179035c7.mjs → LinkTableListPiece-47f4286c.mjs} +1 -1
- package/{ModalFormDemo-3a85920c.mjs → ModalFormDemo-dbd0aa28.mjs} +1 -1
- package/OnlCgformErpList-35ad1d6e.mjs +528 -0
- package/{OnlCgformErpSubTable-3515150b.mjs → OnlCgformErpSubTable-5093d438.mjs} +45 -42
- package/{OnlCgformInnerSubTable-13e888c6.mjs → OnlCgformInnerSubTable-f1dc90db.mjs} +108 -103
- package/{OnlCgformInnerTableList-2e8f853c.mjs → OnlCgformInnerTableList-1b82a7da.mjs} +163 -155
- package/{OnlCgformTabList-583ac15f.mjs → OnlCgformTabList-d66d1261.mjs} +163 -155
- package/OnlineAutoList-fbba2a52.mjs +559 -0
- package/{OnlineAutoModal-c0743caf.mjs → OnlineAutoModal-68909692.mjs} +11 -10
- package/OnlineAutoTreeList-5153f09d.mjs +533 -0
- package/OnlineCustomModal-b5f8c799.mjs +247 -0
- package/{OnlineDetailModal-785e848e.mjs → OnlineDetailModal-ac078a9a.mjs} +45 -43
- package/OnlineForm-20604e4f.mjs +1080 -0
- package/OnlineFormDetail-719118b6.mjs +350 -0
- package/{OnlineFormUrlAdd-905bf251.mjs → OnlineFormUrlAdd-5b675f48.mjs} +14 -12
- package/{OnlineFormUrlDetail-a9dd2bfa.mjs → OnlineFormUrlDetail-91156bf2.mjs} +22 -19
- package/{OnlineFormUrlEdit-b8941f05.mjs → OnlineFormUrlEdit-fb810de6.mjs} +14 -12
- package/{OnlineFormUrlSuccess-ecaf6a21.mjs → OnlineFormUrlSuccess-302ecb21.mjs} +1 -1
- package/{OnlineQueryForm-ca6186a3.mjs → OnlineQueryForm-5eeceb51.mjs} +120 -120
- package/{OnlineSearchFormItem-5c503a51.mjs → OnlineSearchFormItem-5536a1a6.mjs} +2 -2
- package/{OnlineSelectCascade-a3e686b3.mjs → OnlineSelectCascade-180e8c9a.mjs} +61 -55
- package/{OnlineSubFormDetail-be1ad3b9.mjs → OnlineSubFormDetail-4d64e7be.mjs} +48 -44
- package/{OnlineTabAutoModal-fb59b573.mjs → OnlineTabAutoModal-c127ed50.mjs} +10 -9
- package/{OnlineTabDetailModal-4b9c4838.mjs → OnlineTabDetailModal-e4e9f7e3.mjs} +39 -37
- package/{OnlineTabForm-89389384.mjs → OnlineTabForm-827e7089.mjs} +26 -25
- package/OnlineTabFormDetail-0f96377e.mjs +329 -0
- package/{PageAttributeTable-345b97fe.mjs → PageAttributeTable-5703e2f1.mjs} +6 -6
- package/{PhoneLoginForm-8ca7e2d4.mjs → PhoneLoginForm-15dc68ed.mjs} +52 -52
- package/ProcessOnlineForm-1fcbe0af.mjs +219 -0
- package/{QueryTable-f0a88d78.mjs → QueryTable-26c9ee22.mjs} +2 -2
- package/{SetSwitchOptions-cdcb22a1.mjs → SetSwitchOptions-a3428177.mjs} +1 -1
- package/{ShareAddView-f713c0a5.mjs → ShareAddView-0512e884.mjs} +25 -22
- package/{ShareEditView-691764ad.mjs → ShareEditView-b89dfbd3.mjs} +25 -22
- package/{ShareView-df344a8d.mjs → ShareView-faf1a0ab.mjs} +23 -20
- package/{ShareView.vue_vue_type_script_setup_true_lang-560459c9.mjs → ShareView.vue_vue_type_script_setup_true_lang-d1597c0d.mjs} +2 -2
- package/{SingleView-ad0287d6.mjs → SingleView-21d3a558.mjs} +18 -15
- package/{SingleView.vue_vue_type_style_index_0_lang-ce96670b.mjs → SingleView.vue_vue_type_style_index_0_lang-914483d0.mjs} +4 -4
- package/{SuperQuery-2b293e3b.mjs → SuperQuery-c95f86ee.mjs} +69 -67
- package/TaskOpinionList-73ecb3c8.mjs +101 -0
- package/aiModal-b44fa135.mjs +175 -0
- package/{auth.data-626c5083.mjs → auth.data-e44c7975.mjs} +10 -9
- package/button.data-fe45d43b.mjs +12 -0
- package/dayjs.min-eea532a3.mjs +301 -0
- package/{index-d6f9ada7.mjs → index-02f6dc7d.mjs} +2 -2
- package/{index-bef7fe2d.mjs → index-22a99f2e.mjs} +1 -1
- package/{index-181f8344.mjs → index-26940246.mjs} +3 -3
- package/{index-3c7392a4.mjs → index-30da2fc0.mjs} +136 -128
- package/index-391aec04.mjs +268 -0
- package/index-94b6319e.mjs +57 -0
- package/{index-93341e02.mjs → index-abbfd327.mjs} +2 -2
- package/main.index.js +1 -1
- package/package.json +1 -1
- package/style.css +1 -1
- package/useCgformList-aaa30c8c.mjs +410 -0
- package/{useCustomHook-acb00837.mjs → useCustomHook-3a17a690.mjs} +11 -9
- package/useExtendComponent-ad499dff.mjs +4164 -0
- package/useListButton-308458cd.mjs +765 -0
- package/{useSchemas-f1819e54.mjs → useSchemas-b074f3a1.mjs} +72 -72
- package/{useTableSync-075826a1.mjs → useTableSync-dbfba20e.mjs} +31 -31
- package/CgformAddressModal-1b9cbe19.mjs +0 -260
- package/CgformCopyList-580bba0f.mjs +0 -252
- package/CodeFileViewModal-eb803769.mjs +0 -253
- package/CodeGeneratorModal-2fe1e920.mjs +0 -281
- package/OnlCgformErpList-8fd15fc1.mjs +0 -488
- package/OnlineAutoList-36ec0957.mjs +0 -513
- package/OnlineAutoTreeList-1cd718be.mjs +0 -523
- package/OnlineCustomModal-661ee850.mjs +0 -232
- package/OnlineForm-c1fb38eb.mjs +0 -1012
- package/OnlineFormDetail-50186870.mjs +0 -342
- package/OnlineTabFormDetail-72173ae4.mjs +0 -327
- package/ProcessOnlineForm-485b5679.mjs +0 -188
- package/README.md +0 -26
- package/index-3ccda826.mjs +0 -239
- package/index-f3683351.mjs +0 -57
- package/useCgformList-13c8aab7.mjs +0 -378
- package/useExtendComponent-3f5734ca.mjs +0 -4459
- package/useListButton-ee23874a.mjs +0 -719
- /package/{OnlineForm.vue_vue_type_style_index_0_scoped_3f26e7bd_lang-4ed993c7.mjs → OnlineForm.vue_vue_type_style_index_0_scoped_60bd1850_lang-4ed993c7.mjs} +0 -0
|
@@ -0,0 +1,765 @@
|
|
|
1
|
+
var Re = Object.defineProperty, ke = Object.defineProperties;
|
|
2
|
+
var _e = Object.getOwnPropertyDescriptors;
|
|
3
|
+
var we = Object.getOwnPropertySymbols;
|
|
4
|
+
var Be = Object.prototype.hasOwnProperty, Fe = Object.prototype.propertyIsEnumerable;
|
|
5
|
+
var ve = (l, m, s) => m in l ? Re(l, m, { enumerable: !0, configurable: !0, writable: !0, value: s }) : l[m] = s, M = (l, m) => {
|
|
6
|
+
for (var s in m || (m = {}))
|
|
7
|
+
Be.call(m, s) && ve(l, s, m[s]);
|
|
8
|
+
if (we)
|
|
9
|
+
for (var s of we(m))
|
|
10
|
+
Fe.call(m, s) && ve(l, s, m[s]);
|
|
11
|
+
return l;
|
|
12
|
+
}, re = (l, m) => ke(l, _e(m));
|
|
13
|
+
var V = (l, m, s) => new Promise((B, R) => {
|
|
14
|
+
var k = (D) => {
|
|
15
|
+
try {
|
|
16
|
+
v(s.next(D));
|
|
17
|
+
} catch (O) {
|
|
18
|
+
R(O);
|
|
19
|
+
}
|
|
20
|
+
}, g = (D) => {
|
|
21
|
+
try {
|
|
22
|
+
v(s.throw(D));
|
|
23
|
+
} catch (O) {
|
|
24
|
+
R(O);
|
|
25
|
+
}
|
|
26
|
+
}, v = (D) => D.done ? B(D.value) : Promise.resolve(D.value).then(k, g);
|
|
27
|
+
v((s = s.apply(l, m)).next());
|
|
28
|
+
});
|
|
29
|
+
import { E as ae, r as Ie } from "./useExtendComponent-ad499dff.mjs";
|
|
30
|
+
import { useRoute as Me } from "vue-router";
|
|
31
|
+
import { router as De } from "/@/router";
|
|
32
|
+
import { ref as w, provide as Ce, onBeforeUnmount as Ne, toRaw as C, nextTick as Se, reactive as ne, computed as $e } from "vue";
|
|
33
|
+
import { defHttp as _ } from "/@/utils/http/axios";
|
|
34
|
+
import { useMessage as Te } from "/@/hooks/web/useMessage";
|
|
35
|
+
import { filterObj as Oe } from "/@/utils/common/compUtils";
|
|
36
|
+
import { u as Ue, G as Qe } from "./useCustomHook-3a17a690.mjs";
|
|
37
|
+
import { onMountedOrActivated as Ve } from "/@/hooks/core/onMountedOrActivated";
|
|
38
|
+
import { useModal as J } from "/@/components/Modal";
|
|
39
|
+
import { E as le } from "./constant-fa63bd66.mjs";
|
|
40
|
+
import { useMultipleTabStore as Ke } from "/@/store/modules/multipleTab";
|
|
41
|
+
import { u as je } from "./cgformState-d9f8ec42.mjs";
|
|
42
|
+
import { getMenus as Le } from "/@/router/menus";
|
|
43
|
+
import { pick as ze } from "lodash-es";
|
|
44
|
+
import { Modal as He } from "ant-design-vue";
|
|
45
|
+
import { useMethods as Je } from "/@/hooks/system/useMethods";
|
|
46
|
+
import { getToken as Ae } from "/@/utils/auth";
|
|
47
|
+
import { goJmReportViewPage as qe } from "/@/utils";
|
|
48
|
+
const Xe = {
|
|
49
|
+
acceptHrefParams: "<p> 跳转时获取的参数信息",
|
|
50
|
+
currentPage: "<p> 当前页数",
|
|
51
|
+
currentTableName: "<p> 当前表名",
|
|
52
|
+
description: "<p> 当前表描述",
|
|
53
|
+
hasChildrenField: "<p> 是否有子节点的字段名,仅树形表单下有效",
|
|
54
|
+
isDesForm: "<p> xx",
|
|
55
|
+
isTree: "<m> 是否是树形表单 ",
|
|
56
|
+
loadData: "<m> 加载列表数据",
|
|
57
|
+
pageSize: "<p> 每一页显示条数",
|
|
58
|
+
queryParam: "<p> 查询条件对象,每次点击查询后才会更新此数据",
|
|
59
|
+
selectedRowKeys: "<p> 选中的行的id数组",
|
|
60
|
+
sortField: "<p> 排序字段",
|
|
61
|
+
sortType: "<p> 排序规则",
|
|
62
|
+
total: "<p> 总页数",
|
|
63
|
+
foreignKeyValue: "<p> Erp一对多子表外键选中对应主表字段的值",
|
|
64
|
+
isErpSubTable: "<p> 是否Erp一对多子表",
|
|
65
|
+
foreignKeyField: "<p> Erp一对多子表外键字段",
|
|
66
|
+
themeTemplate: "<p> 主题模板",
|
|
67
|
+
isInnerSubTable: "<p> 是否内嵌一对多子表",
|
|
68
|
+
innerSubTableId: "<p>内嵌一对多子表ID",
|
|
69
|
+
innerSubTableName: "<p> 内嵌一对多子表名",
|
|
70
|
+
mTableSelectedRcordId: "<p>内嵌主表展开行的id",
|
|
71
|
+
innerSubTableFk: "<p>内嵌子表的外键字段",
|
|
72
|
+
loading: "<p> 设置/获取loading"
|
|
73
|
+
}, Ge = {
|
|
74
|
+
getColumns: "/online/cgform/api/getColumns/",
|
|
75
|
+
getQueryInfo: "/online/cgform/api/getQueryInfo/",
|
|
76
|
+
getData: "/online/cgform/api/getData/",
|
|
77
|
+
getTreeData: "/online/cgform/api/getTreeData/",
|
|
78
|
+
optPre: "/online/cgform/api/form/",
|
|
79
|
+
buttonAction: "/online/cgform/api/doButton",
|
|
80
|
+
exportXls: "/online/cgform/api/exportXlsOld/",
|
|
81
|
+
importXls: "/online/cgform/api/importXls/",
|
|
82
|
+
startProcess: "/act/process/extActProcess/startMutilProcess",
|
|
83
|
+
getErpColumns: "/online/cgform/api/getErpColumns/",
|
|
84
|
+
// 内嵌主题一对多子表数据请求接口
|
|
85
|
+
list: "/online/cgform/api/subform/list/"
|
|
86
|
+
};
|
|
87
|
+
let We = {
|
|
88
|
+
sortField: "id",
|
|
89
|
+
sortType: "asc",
|
|
90
|
+
currentPage: 1,
|
|
91
|
+
pageSize: 10,
|
|
92
|
+
total: 0,
|
|
93
|
+
selectedRowKeys: [],
|
|
94
|
+
queryParam: {},
|
|
95
|
+
acceptHrefParams: {},
|
|
96
|
+
description: "",
|
|
97
|
+
currentTableName: "",
|
|
98
|
+
isDesForm: !1,
|
|
99
|
+
desFormCode: "",
|
|
100
|
+
cache: !1,
|
|
101
|
+
isTree: !1,
|
|
102
|
+
hasChildrenField: ""
|
|
103
|
+
};
|
|
104
|
+
const Ee = {
|
|
105
|
+
current: 1,
|
|
106
|
+
pageSize: 10,
|
|
107
|
+
pageSizeOptions: ["10", "20", "30"],
|
|
108
|
+
showTotal: (l, m) => m[0] + "-" + m[1] + " 共" + l + "条",
|
|
109
|
+
showQuickJumper: !0,
|
|
110
|
+
showSizeChanger: !0,
|
|
111
|
+
total: 0
|
|
112
|
+
}, { createMessage: H, createErrorModal: Ye } = Te();
|
|
113
|
+
function yt(l = {}) {
|
|
114
|
+
var te;
|
|
115
|
+
const m = (te = l.code) != null ? te : "", s = w(m);
|
|
116
|
+
Ce("tableId", s);
|
|
117
|
+
const B = Me(), R = w(), k = w(), g = w(!1), v = w([]), D = w(!0), O = w(), A = je(), ie = Ke(), h = w(!1), S = w(!1);
|
|
118
|
+
let P = {};
|
|
119
|
+
const F = {
|
|
120
|
+
execButtonEnhance: function(r, n) {
|
|
121
|
+
if (i[ae][r])
|
|
122
|
+
if (Ie === r)
|
|
123
|
+
b(r);
|
|
124
|
+
else {
|
|
125
|
+
let u = C(n);
|
|
126
|
+
return i[ae][r].call(i, i, u);
|
|
127
|
+
}
|
|
128
|
+
else if (i[ae][r + "_hook"])
|
|
129
|
+
if (n) {
|
|
130
|
+
let u = C(n);
|
|
131
|
+
b(r + "_hook", u);
|
|
132
|
+
} else
|
|
133
|
+
b(r + "_hook");
|
|
134
|
+
},
|
|
135
|
+
/**
|
|
136
|
+
* get 是否是树形表单
|
|
137
|
+
* @param status 如果有值 则视为set方法
|
|
138
|
+
*/
|
|
139
|
+
isTree: function(r) {
|
|
140
|
+
return typeof r == "boolean" ? (i.isTreeTable = r, r) : i.isTreeTable;
|
|
141
|
+
}
|
|
142
|
+
};
|
|
143
|
+
function b(r, n) {
|
|
144
|
+
let f = i[ae][r].toLocaleString().match(Qe);
|
|
145
|
+
if (f.length > 1) {
|
|
146
|
+
let p = f[1];
|
|
147
|
+
oe(p, n);
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
const i = new Proxy(Xe, {
|
|
151
|
+
get(r, n) {
|
|
152
|
+
if (typeof F[n] == "function")
|
|
153
|
+
return F[n];
|
|
154
|
+
{
|
|
155
|
+
let u = P[s.value];
|
|
156
|
+
return u == null ? u : Reflect.get(u, n);
|
|
157
|
+
}
|
|
158
|
+
},
|
|
159
|
+
set(r, n, u) {
|
|
160
|
+
let f = ue();
|
|
161
|
+
return Reflect.set(typeof u == "function" ? F : f, n, u);
|
|
162
|
+
},
|
|
163
|
+
deleteProperty(r, n) {
|
|
164
|
+
return n === s.value ? (delete P[n], !0) : !1;
|
|
165
|
+
}
|
|
166
|
+
}), { executeJsEnhanced: oe } = Ue({}, i);
|
|
167
|
+
function se() {
|
|
168
|
+
let r = B.params.id;
|
|
169
|
+
return r || (r = ""), r;
|
|
170
|
+
}
|
|
171
|
+
Ve(({ type: r }) => {
|
|
172
|
+
!m && ee(), r === "activated" && A.checkIsChanged(s.value) && ie.refreshPage(De), s.value && A.removeChangedTable(s.value);
|
|
173
|
+
}), Ne(() => {
|
|
174
|
+
delete P[s.value];
|
|
175
|
+
});
|
|
176
|
+
function ue() {
|
|
177
|
+
let r = P[s.value];
|
|
178
|
+
if (!r) {
|
|
179
|
+
let n = Object.assign({}, We, { onlineUrl: Ge });
|
|
180
|
+
r = JSON.parse(JSON.stringify(n)), l.themeTemplate == le && (r.pageSize = 5), r.loading = S, P[s.value] = r;
|
|
181
|
+
}
|
|
182
|
+
return r;
|
|
183
|
+
}
|
|
184
|
+
function N() {
|
|
185
|
+
let r = {}, n = B.query;
|
|
186
|
+
n && (Object.keys(n).map((u) => {
|
|
187
|
+
r[u] = n[u];
|
|
188
|
+
}), i.acceptHrefParams = r);
|
|
189
|
+
}
|
|
190
|
+
function q(r = "") {
|
|
191
|
+
let n;
|
|
192
|
+
return r == le ? n = `${i.onlineUrl.getErpColumns}${s.value}` : n = `${i.onlineUrl.getColumns}${s.value}`, i.isInnerSubTable === !0 && (n = n + "?tabletype=3"), new Promise((u, f) => {
|
|
193
|
+
_.get(
|
|
194
|
+
{
|
|
195
|
+
url: n
|
|
196
|
+
},
|
|
197
|
+
{ isTransformResponse: !1 }
|
|
198
|
+
).then((p) => {
|
|
199
|
+
p.success ? u(p.result) : (H.warning(p.message), f());
|
|
200
|
+
}).catch(() => {
|
|
201
|
+
f();
|
|
202
|
+
});
|
|
203
|
+
});
|
|
204
|
+
}
|
|
205
|
+
function $(r = {}) {
|
|
206
|
+
const { delNum: n } = r;
|
|
207
|
+
return new Promise((u, f) => {
|
|
208
|
+
if (n != null) {
|
|
209
|
+
const { total: t, pageSize: a, current: o } = g.value, c = Math.ceil(t / a);
|
|
210
|
+
o === c && (g.value.current = Math.ceil((t - n) / a));
|
|
211
|
+
}
|
|
212
|
+
let p = X(), e = `${i.onlineUrl.getData}${s.value}`;
|
|
213
|
+
if (i.isTree() === !0 ? e = `${i.onlineUrl.getTreeData}${s.value}` : i.isInnerSubTable === !0 && (e = `${i.onlineUrl.getData}${i.innerSubTableId}`, p = { pageSize: -521 }, i.innerSubTableFk && i.mTableSelectedRcordId && (p[i.innerSubTableFk] = i.mTableSelectedRcordId), e = e + "?tabletype=3"), i.isErpSubTable === !0) {
|
|
214
|
+
if (i.foreignKeyValue == null)
|
|
215
|
+
return;
|
|
216
|
+
p[i.foreignKeyField] = i.foreignKeyValue, p.tabletype = 3, delete p.hasQuery;
|
|
217
|
+
}
|
|
218
|
+
_.get({ url: e, params: p }, { isTransformResponse: !1 }).then((t) => {
|
|
219
|
+
t.success ? (ce(t.result), u(!0)) : (t.message === "NO_DB_SYNC" ? Ye({
|
|
220
|
+
title: "数据库未同步",
|
|
221
|
+
content: "请先同步数据库再查看此页面!",
|
|
222
|
+
// 点击确定后自动返回上一页
|
|
223
|
+
onOk: () => De.back()
|
|
224
|
+
}) : H.warning(t.message), f(!1));
|
|
225
|
+
}).catch(() => {
|
|
226
|
+
let t = "请求列表数据异常!";
|
|
227
|
+
H.warning(t), f(!1);
|
|
228
|
+
});
|
|
229
|
+
});
|
|
230
|
+
}
|
|
231
|
+
function X() {
|
|
232
|
+
const { sortField: r, sortType: n, acceptHrefParams: u, queryParam: f } = i, p = {
|
|
233
|
+
hasQuery: "true"
|
|
234
|
+
};
|
|
235
|
+
i.isTree() === !0 && (f || Object.keys(f).length <= 0) && (p.hasQuery = "false");
|
|
236
|
+
let e = Object.assign({}, p, u, f, { column: r, order: n });
|
|
237
|
+
g.value ? (e.pageNo = g.value.current, e.pageSize = g.value.pageSize) : e.pageSize = -521;
|
|
238
|
+
let t = me();
|
|
239
|
+
return e.superQueryMatchType = t.matchType || "", e.superQueryParams = t.params || "", Oe(e);
|
|
240
|
+
}
|
|
241
|
+
function ce(r) {
|
|
242
|
+
let n = 0;
|
|
243
|
+
Number(r.total) > 0 ? (i.isTree() === !0 ? (v.value = j(r.records), Se(() => {
|
|
244
|
+
de(v.value);
|
|
245
|
+
})) : (v.value = [], Se(() => {
|
|
246
|
+
v.value = r.records;
|
|
247
|
+
})), n = Number(r.total)) : v.value = [], g.value && (g.value = re(M({}, g.value), { total: n }));
|
|
248
|
+
}
|
|
249
|
+
function G(r, n, u) {
|
|
250
|
+
u && u.order ? (i.sortField = u.field, i.sortType = u.order == "ascend" ? "asc" : "desc") : (i.sortField = "id", i.sortType = "asc"), g.value && (g.value = r), $();
|
|
251
|
+
}
|
|
252
|
+
function W(r) {
|
|
253
|
+
i.description = r.description, i.currentTableName = r.currentTableName, i.isDesForm = r.isDesForm, i.desFormCode = r.desFormCode, i.ID = s.value;
|
|
254
|
+
let { acceptHrefParams: n, queryParam: u, superQuery: f, currentPage: p, pageSize: e } = i;
|
|
255
|
+
if (N(), u ? R.value && R.value.initDefaultValues(u, n) : i.queryParam = {}, f ? k.value && k.value.initDefaultValues(f) : i.superQuery = { params: "", matchType: "" }, r.paginationFlag == "Y") {
|
|
256
|
+
let t = Ee.pageSizeOptions;
|
|
257
|
+
l.themeTemplate == le && (t = ["5", "10", "30"]), g.value = re(M({}, Ee), { current: p, pageSize: e, pageSizeOptions: t });
|
|
258
|
+
} else
|
|
259
|
+
g.value = !1;
|
|
260
|
+
}
|
|
261
|
+
function fe() {
|
|
262
|
+
return V(this, null, function* () {
|
|
263
|
+
D.value = !0, yield Se(), D.value = !1;
|
|
264
|
+
});
|
|
265
|
+
}
|
|
266
|
+
const K = {
|
|
267
|
+
loadData: $,
|
|
268
|
+
getLoadDataParams: X,
|
|
269
|
+
reloadTable: fe
|
|
270
|
+
};
|
|
271
|
+
Object.keys(K).map((r) => {
|
|
272
|
+
i[r] = K[r];
|
|
273
|
+
});
|
|
274
|
+
let Y = w(!1);
|
|
275
|
+
function pe() {
|
|
276
|
+
return V(this, arguments, function* (r = {}) {
|
|
277
|
+
g.value && (g.value = re(M({}, g.value), { current: r.mode == "search" || !g.value.current ? 1 : g.value.current })), l.themeTemplate !== le && i.clearSelectedRow(), yield $();
|
|
278
|
+
});
|
|
279
|
+
}
|
|
280
|
+
function j(r) {
|
|
281
|
+
if (r)
|
|
282
|
+
return r.map((n) => {
|
|
283
|
+
let u = i.hasChildrenField;
|
|
284
|
+
if (n[u] == "1") {
|
|
285
|
+
let f = { id: n.id + "_loadChild", name: "loading...", isLoading: !0 };
|
|
286
|
+
f.jeecg_row_key = f.id, n.children = [f];
|
|
287
|
+
}
|
|
288
|
+
return n;
|
|
289
|
+
});
|
|
290
|
+
}
|
|
291
|
+
const L = w([]);
|
|
292
|
+
function z(r) {
|
|
293
|
+
L.value = r;
|
|
294
|
+
}
|
|
295
|
+
function de(r) {
|
|
296
|
+
let n = L.value;
|
|
297
|
+
if (n.length > 0) {
|
|
298
|
+
const { sortField: u, sortType: f, pidField: p } = i;
|
|
299
|
+
let e = Object.assign({}, { column: u, order: f });
|
|
300
|
+
e.hasQuery = "in";
|
|
301
|
+
let t = Object.assign({});
|
|
302
|
+
t.rule = "in", t.type = "text", t.val = n.join(","), t.field = p, t = [t], e.superQueryParams = encodeURI(JSON.stringify(t)), e.superQueryMatchType = "and", e.batchFlag = "true";
|
|
303
|
+
let a = `${i.onlineUrl.getTreeData}${s.value}`;
|
|
304
|
+
_.get({ url: a, params: e }, { isTransformResponse: !1 }).then((o) => {
|
|
305
|
+
if (o.success && o.result.records && o.result.records.length > 0) {
|
|
306
|
+
let c = o.result.records;
|
|
307
|
+
const d = /* @__PURE__ */ new Map();
|
|
308
|
+
for (let E of c) {
|
|
309
|
+
let T = E[p];
|
|
310
|
+
if (n.join(",").includes(T)) {
|
|
311
|
+
let Q = d.get(T);
|
|
312
|
+
Q == null && (Q = []), Q.push(E), d.set(T, Q);
|
|
313
|
+
}
|
|
314
|
+
}
|
|
315
|
+
let y = d, I = (E) => {
|
|
316
|
+
E && E.forEach((T) => {
|
|
317
|
+
n.includes(T.id) && (T.children = j(y.get(T.id)), I(T.children));
|
|
318
|
+
});
|
|
319
|
+
};
|
|
320
|
+
I(r);
|
|
321
|
+
}
|
|
322
|
+
}).catch(() => {
|
|
323
|
+
let o = "loadDataByExpandedRows请求列表数据异常!";
|
|
324
|
+
H.warning(o);
|
|
325
|
+
});
|
|
326
|
+
} else
|
|
327
|
+
return Promise.resolve();
|
|
328
|
+
}
|
|
329
|
+
function me() {
|
|
330
|
+
if (!i.superQuery)
|
|
331
|
+
return {};
|
|
332
|
+
const {
|
|
333
|
+
superQuery: { params: r, matchType: n },
|
|
334
|
+
currentTableName: u
|
|
335
|
+
} = i;
|
|
336
|
+
let f = u + "@", p = [];
|
|
337
|
+
if (r.length > 0)
|
|
338
|
+
for (let t of r) {
|
|
339
|
+
let a = M({}, t), o = a.field;
|
|
340
|
+
o.startsWith(f) && (a.field = o.replace(f, "")), p.push(a);
|
|
341
|
+
}
|
|
342
|
+
let e = p.length > 0 ? JSON.stringify(p) : "";
|
|
343
|
+
return {
|
|
344
|
+
params: encodeURIComponent(e),
|
|
345
|
+
matchType: n
|
|
346
|
+
};
|
|
347
|
+
}
|
|
348
|
+
const U = w(!1);
|
|
349
|
+
function Z(r, n) {
|
|
350
|
+
i.superQuery = {
|
|
351
|
+
params: r,
|
|
352
|
+
matchType: n
|
|
353
|
+
}, r.length == 0 || r.length == null ? U.value = !1 : U.value = !0, g.value.current = 1, $();
|
|
354
|
+
}
|
|
355
|
+
const [ge, { openModal: he }] = J();
|
|
356
|
+
function x(r) {
|
|
357
|
+
if (r || (r = {}), !r.row) {
|
|
358
|
+
let n = i.selectedRows;
|
|
359
|
+
if (!n || n.length == 0 || n.length > 1) {
|
|
360
|
+
H.warning("请选择一条数据");
|
|
361
|
+
return;
|
|
362
|
+
}
|
|
363
|
+
r.row = n[0];
|
|
364
|
+
}
|
|
365
|
+
r.code = s.value, he(!0, r);
|
|
366
|
+
}
|
|
367
|
+
i.openCustomModal = x;
|
|
368
|
+
function ee() {
|
|
369
|
+
let r = se();
|
|
370
|
+
s.value = r;
|
|
371
|
+
}
|
|
372
|
+
!m && !s.value && ee();
|
|
373
|
+
function be(r) {
|
|
374
|
+
let n = r.head.extConfigJson;
|
|
375
|
+
n && (O.value = JSON.parse(n));
|
|
376
|
+
}
|
|
377
|
+
function ye() {
|
|
378
|
+
return V(this, null, function* () {
|
|
379
|
+
const r = (p, e) => {
|
|
380
|
+
var t;
|
|
381
|
+
for (let a = 0, o = p.length; a < o; a++) {
|
|
382
|
+
const c = p[a];
|
|
383
|
+
if (c.path === e && !c.redirect && !c.paramPath)
|
|
384
|
+
return !0;
|
|
385
|
+
if ((t = c.children) != null && t.length) {
|
|
386
|
+
const d = r(c.children, e);
|
|
387
|
+
if (d)
|
|
388
|
+
return d;
|
|
389
|
+
}
|
|
390
|
+
}
|
|
391
|
+
return !1;
|
|
392
|
+
}, n = B.path, u = yield Le(), f = r(u, n);
|
|
393
|
+
h.value = f;
|
|
394
|
+
});
|
|
395
|
+
}
|
|
396
|
+
return ye(), M({
|
|
397
|
+
ID: s,
|
|
398
|
+
onlineQueryFormOuter: R,
|
|
399
|
+
superQueryButtonRef: k,
|
|
400
|
+
loading: Y,
|
|
401
|
+
reload: pe,
|
|
402
|
+
dataSource: v,
|
|
403
|
+
pagination: g,
|
|
404
|
+
tableReloading: D,
|
|
405
|
+
handleSpecialConfig: W,
|
|
406
|
+
onlineTableContext: i,
|
|
407
|
+
handleChangeInTable: G,
|
|
408
|
+
getColumnList: q,
|
|
409
|
+
getTreeDataByResult: j,
|
|
410
|
+
expandedRowKeys: L,
|
|
411
|
+
handleExpandedRowsChange: z,
|
|
412
|
+
onlineExtConfigJson: O,
|
|
413
|
+
handleFormConfig: be,
|
|
414
|
+
superQueryStatus: U,
|
|
415
|
+
handleSuperQuery: Z,
|
|
416
|
+
registerCustomModal: ge,
|
|
417
|
+
isConfigCurRoute: h,
|
|
418
|
+
pageLoading: S
|
|
419
|
+
}, K);
|
|
420
|
+
}
|
|
421
|
+
const Pe = "onl_";
|
|
422
|
+
function St(l, m, s = {}) {
|
|
423
|
+
const B = {
|
|
424
|
+
add: !0,
|
|
425
|
+
addSub: !0,
|
|
426
|
+
// edit = 编辑按钮的code
|
|
427
|
+
edit: !0,
|
|
428
|
+
// update = 编辑按钮的老code
|
|
429
|
+
update: !0,
|
|
430
|
+
delete: !0,
|
|
431
|
+
batch_delete: !0,
|
|
432
|
+
import: !0,
|
|
433
|
+
export: !0,
|
|
434
|
+
detail: !0,
|
|
435
|
+
query: !0,
|
|
436
|
+
reset: !0,
|
|
437
|
+
super_query: !0,
|
|
438
|
+
bpm: !0,
|
|
439
|
+
form_confirm: !0,
|
|
440
|
+
// 子表新增
|
|
441
|
+
form_sub_add: !0,
|
|
442
|
+
// 子表删除
|
|
443
|
+
form_sub_batch_delete: !0,
|
|
444
|
+
// 子表新增
|
|
445
|
+
form_sub_open_add: !0,
|
|
446
|
+
// 子表编辑
|
|
447
|
+
form_sub_open_edit: !0,
|
|
448
|
+
// 生成测试数据
|
|
449
|
+
aigc_mock_data: !0
|
|
450
|
+
}, [R, { openModal: k }] = J(), [g, { openModal: v }] = J(), [D, { openModal: O }] = J(), [A, { openModal: ie }] = J(), { createMessage: h } = Te(), S = ne(B), P = ne([]), F = ne([]), b = ne({}), i = (e) => $e(() => S[e] === !0 ? b[e] : { enabled: !1 }), oe = i("query"), se = i("reset"), ue = i("form_confirm"), N = w(!1), q = w(!0);
|
|
451
|
+
setTimeout(() => {
|
|
452
|
+
q.value = !1;
|
|
453
|
+
}, 4e3);
|
|
454
|
+
function $(e) {
|
|
455
|
+
if (P.length = 0, F.length = 0, e && e.length > 0)
|
|
456
|
+
for (let t = 0; t < e.length; t++) {
|
|
457
|
+
let a = ze(e[t], "buttonCode", "buttonName", "buttonStyle", "optType", "exp", "buttonIcon", "buttonStatus", "enabled");
|
|
458
|
+
a.buttonStyle == "button" ? F.push(a) : a.buttonStyle == "link" ? P.push(a) : a.buttonStyle == "built-in" && (a.buttonIcon && (a.buttonIcon = "ant-design:" + a.buttonIcon), a.enabled = a.buttonStatus === "1", b[a.buttonCode] = a);
|
|
459
|
+
}
|
|
460
|
+
}
|
|
461
|
+
function X(e) {
|
|
462
|
+
Object.keys(S).forEach((t) => {
|
|
463
|
+
S[t] = !0;
|
|
464
|
+
}), e && e.length > 0 && Object.keys(S).forEach((t) => {
|
|
465
|
+
e.indexOf(t) >= 0 && (S[t] = !1);
|
|
466
|
+
});
|
|
467
|
+
}
|
|
468
|
+
function ce(e) {
|
|
469
|
+
let t = { isUpdate: !1 };
|
|
470
|
+
e && (t.param = e), k(!0, t);
|
|
471
|
+
}
|
|
472
|
+
function G(e) {
|
|
473
|
+
l.beforeEdit(e).then(() => {
|
|
474
|
+
k(!0, {
|
|
475
|
+
isUpdate: !0,
|
|
476
|
+
record: e
|
|
477
|
+
});
|
|
478
|
+
}).catch((t) => {
|
|
479
|
+
h.warning(t);
|
|
480
|
+
});
|
|
481
|
+
}
|
|
482
|
+
const W = (e) => ({
|
|
483
|
+
label: b.delete.buttonName,
|
|
484
|
+
ifShow: () => b.delete.enabled,
|
|
485
|
+
popConfirm: {
|
|
486
|
+
title: "是否删除?",
|
|
487
|
+
confirm: fe.bind(null, e)
|
|
488
|
+
}
|
|
489
|
+
});
|
|
490
|
+
function fe(e) {
|
|
491
|
+
l.beforeDelete(e).then(() => {
|
|
492
|
+
Z(e.id, !1);
|
|
493
|
+
}).catch((t) => {
|
|
494
|
+
h.warning(t);
|
|
495
|
+
});
|
|
496
|
+
}
|
|
497
|
+
function K(e) {
|
|
498
|
+
let t = z(e), a = t && (t == "1" || t == "3" || t == "4") || !t;
|
|
499
|
+
return C(S.edit) === !0 && C(S.update) === !0 && a ? [
|
|
500
|
+
{
|
|
501
|
+
label: b.edit.buttonName,
|
|
502
|
+
ifShow: () => b.edit.enabled,
|
|
503
|
+
onClick: (o) => {
|
|
504
|
+
s.editClickCallback && s.editClickCallback(e.id, o), G(e);
|
|
505
|
+
}
|
|
506
|
+
}
|
|
507
|
+
] : [];
|
|
508
|
+
}
|
|
509
|
+
function Y(e) {
|
|
510
|
+
return {
|
|
511
|
+
label: b.bpm.buttonName,
|
|
512
|
+
ifShow: () => b.bpm.enabled,
|
|
513
|
+
popConfirm: {
|
|
514
|
+
title: "确认提交流程吗?",
|
|
515
|
+
confirm: U.bind(null, e)
|
|
516
|
+
}
|
|
517
|
+
};
|
|
518
|
+
}
|
|
519
|
+
function pe(e) {
|
|
520
|
+
return {
|
|
521
|
+
label: "审批进度",
|
|
522
|
+
onClick: j.bind(null, e)
|
|
523
|
+
};
|
|
524
|
+
}
|
|
525
|
+
function j(e) {
|
|
526
|
+
const { currentTableName: t } = l;
|
|
527
|
+
let a = t;
|
|
528
|
+
t.includes("$") && (a = t.split("$")[0]);
|
|
529
|
+
let o = Pe + a, c = e.id;
|
|
530
|
+
ie(!0, {
|
|
531
|
+
flowCode: o,
|
|
532
|
+
dataId: c
|
|
533
|
+
});
|
|
534
|
+
}
|
|
535
|
+
function L(e, t = {}) {
|
|
536
|
+
let a = [];
|
|
537
|
+
if (C(S.detail) === !0 && a.push({
|
|
538
|
+
label: b.detail.buttonName,
|
|
539
|
+
ifShow: () => b.detail.enabled,
|
|
540
|
+
onClick: de.bind(null, e)
|
|
541
|
+
}), l.hasBpmStatus === !0 && C(S.bpm) === !0) {
|
|
542
|
+
let y = z(e);
|
|
543
|
+
!y || y == "1" ? a.push(Y(e)) : a.push(pe(e));
|
|
544
|
+
}
|
|
545
|
+
if (m.value) {
|
|
546
|
+
let { reportPrintShow: y, reportPrintUrl: I } = m.value;
|
|
547
|
+
y && I && a.push({
|
|
548
|
+
label: "打印",
|
|
549
|
+
onClick() {
|
|
550
|
+
let E = I, T = e.id, Q = Ae();
|
|
551
|
+
qe(E, T, Q);
|
|
552
|
+
}
|
|
553
|
+
});
|
|
554
|
+
}
|
|
555
|
+
let o = z(e), c = o && o == "1" || !o;
|
|
556
|
+
C(S.delete) === !0 && c && a.push(W(e));
|
|
557
|
+
let d = P;
|
|
558
|
+
if (d && d.length > 0)
|
|
559
|
+
for (let y of d)
|
|
560
|
+
f(y.exp || "", e) === !0 && a.push({
|
|
561
|
+
label: y.buttonName,
|
|
562
|
+
onClick: x.bind(null, e, y.buttonCode, y.optType)
|
|
563
|
+
});
|
|
564
|
+
return a;
|
|
565
|
+
}
|
|
566
|
+
function z(e) {
|
|
567
|
+
const t = "bpm_status";
|
|
568
|
+
let a = e[t];
|
|
569
|
+
return a || (a = e[t.toUpperCase()]), a;
|
|
570
|
+
}
|
|
571
|
+
function de(e) {
|
|
572
|
+
O(!0, {
|
|
573
|
+
isUpdate: !0,
|
|
574
|
+
disableSubmit: !0,
|
|
575
|
+
record: e
|
|
576
|
+
});
|
|
577
|
+
}
|
|
578
|
+
function me(e) {
|
|
579
|
+
const {
|
|
580
|
+
currentTableName: t,
|
|
581
|
+
onlineUrl: { startProcess: a }
|
|
582
|
+
} = l;
|
|
583
|
+
let o = t;
|
|
584
|
+
t.includes("$") && (o = t.split("$")[0]);
|
|
585
|
+
let c = {
|
|
586
|
+
url: a,
|
|
587
|
+
params: {
|
|
588
|
+
flowCode: Pe + o,
|
|
589
|
+
id: e.id,
|
|
590
|
+
// TODO 流程表单没有
|
|
591
|
+
formUrl: "modules/bpm/task/form/OnlineFormDetail",
|
|
592
|
+
formUrlMobile: "check/onlineForm/detail"
|
|
593
|
+
}
|
|
594
|
+
}, d = { isTransformResponse: !1 };
|
|
595
|
+
return new Promise((y, I) => {
|
|
596
|
+
_.post(c, d).then((E) => {
|
|
597
|
+
E.success ? (y(E), h.success(E.message)) : (I(), h.warning(E.message));
|
|
598
|
+
});
|
|
599
|
+
});
|
|
600
|
+
}
|
|
601
|
+
function U(e) {
|
|
602
|
+
return V(this, null, function* () {
|
|
603
|
+
yield me(e), l.loadData();
|
|
604
|
+
});
|
|
605
|
+
}
|
|
606
|
+
function Z(e, t = !0) {
|
|
607
|
+
let a = `${l.onlineUrl.optPre}${l.ID}/${e}`;
|
|
608
|
+
return l.isErpSubTable === !0 && (a = `${a}?tabletype=3`), new Promise((o, c) => {
|
|
609
|
+
_.delete(
|
|
610
|
+
{
|
|
611
|
+
url: a
|
|
612
|
+
},
|
|
613
|
+
{ isTransformResponse: !1 }
|
|
614
|
+
).then((d) => {
|
|
615
|
+
d.success ? (h.success(d.message), l.loadData({ delNum: e.split(",").length }), t || s.singleDelCallback && s.singleDelCallback(e), o(!0)) : (h.warning(d.message), c());
|
|
616
|
+
});
|
|
617
|
+
});
|
|
618
|
+
}
|
|
619
|
+
function ge() {
|
|
620
|
+
let e = l.selectedRowKeys;
|
|
621
|
+
if (e.length <= 0)
|
|
622
|
+
return h.warning("请选择一条记录!"), !1;
|
|
623
|
+
{
|
|
624
|
+
let t = [];
|
|
625
|
+
e.forEach(function(o) {
|
|
626
|
+
let c = o;
|
|
627
|
+
c && c.endsWith("_loadChild") && (c = c.replace("_loadChild", "")), t.indexOf(c) < 0 && t.push(c);
|
|
628
|
+
});
|
|
629
|
+
let a = t.join(",");
|
|
630
|
+
He.confirm({
|
|
631
|
+
title: "确认删除",
|
|
632
|
+
content: "是否删除选中数据",
|
|
633
|
+
okText: "确认",
|
|
634
|
+
cancelText: "取消",
|
|
635
|
+
onOk: () => V(this, null, function* () {
|
|
636
|
+
yield Z(a), l.clearSelectedRow();
|
|
637
|
+
})
|
|
638
|
+
});
|
|
639
|
+
}
|
|
640
|
+
}
|
|
641
|
+
const he = (e, t) => {
|
|
642
|
+
N.value = !0, _.post({ url: `/online/cgform/api/aigc/mock/data/${e}`, timeout: 12e4 }, { isTransformResponse: !1 }).then((a) => {
|
|
643
|
+
a.code == 200 ? (h.success("生成测试数据成功~"), t()) : h.warn(a.message), N.value = !1;
|
|
644
|
+
}).catch((a) => {
|
|
645
|
+
N.value = !1;
|
|
646
|
+
});
|
|
647
|
+
};
|
|
648
|
+
function x(e, t, a) {
|
|
649
|
+
if (a == "js")
|
|
650
|
+
l.execButtonEnhance(t, e);
|
|
651
|
+
else if (a == "action") {
|
|
652
|
+
let o = {
|
|
653
|
+
formId: l.ID,
|
|
654
|
+
buttonCode: t,
|
|
655
|
+
dataId: e.id
|
|
656
|
+
}, c = `${l.onlineUrl.buttonAction}`;
|
|
657
|
+
_.post(
|
|
658
|
+
{
|
|
659
|
+
url: c,
|
|
660
|
+
params: o
|
|
661
|
+
},
|
|
662
|
+
{ isTransformResponse: !1 }
|
|
663
|
+
).then((d) => {
|
|
664
|
+
d.success ? (l.loadData(), h.success("处理完成!")) : h.warning(d.message);
|
|
665
|
+
});
|
|
666
|
+
}
|
|
667
|
+
}
|
|
668
|
+
function ee(e) {
|
|
669
|
+
l.execButtonEnhance(e);
|
|
670
|
+
}
|
|
671
|
+
function be(e) {
|
|
672
|
+
let t = l.selectedRowKeys;
|
|
673
|
+
if (!t || t.length == 0)
|
|
674
|
+
return h.warning("请先选中一条记录"), !1;
|
|
675
|
+
let a = t.join(","), o = {
|
|
676
|
+
formId: l.ID,
|
|
677
|
+
buttonCode: e,
|
|
678
|
+
dataId: a
|
|
679
|
+
}, c = `${l.onlineUrl.buttonAction}`;
|
|
680
|
+
_.post(
|
|
681
|
+
{
|
|
682
|
+
url: c,
|
|
683
|
+
params: o
|
|
684
|
+
},
|
|
685
|
+
{ isTransformResponse: !1 }
|
|
686
|
+
).then((d) => {
|
|
687
|
+
d.success ? (l.loadData(), l.clearSelectedRow(), h.success("处理完成!")) : h.warning(d.message);
|
|
688
|
+
});
|
|
689
|
+
}
|
|
690
|
+
function ye() {
|
|
691
|
+
l.foreignKeyField && l.foreignKeyValue ? v(!0, {
|
|
692
|
+
[l.foreignKeyField]: l.foreignKeyValue
|
|
693
|
+
}) : v(!0);
|
|
694
|
+
}
|
|
695
|
+
const te = () => {
|
|
696
|
+
let e = `${l.onlineUrl.importXls}${l.ID}`;
|
|
697
|
+
return l.isErpSubTable === !0 && (e = `${e}?tabletype=3`), e;
|
|
698
|
+
}, { handleExportXlsx: r } = Je();
|
|
699
|
+
function n() {
|
|
700
|
+
let e = l.getLoadDataParams(), t = l.selectedRowKeys;
|
|
701
|
+
t && t.length > 0 && (e.selections = t.join(","));
|
|
702
|
+
let a = {};
|
|
703
|
+
l.isErpSubTable === !0 && (a = { tabletype: 3 }, l.foreignKeyField && l.foreignKeyValue && (e[l.foreignKeyField] = l.foreignKeyValue));
|
|
704
|
+
let o = JSON.stringify(Oe(e)), c = `${l.onlineUrl.exportXls}${l.ID}`;
|
|
705
|
+
const d = l.description;
|
|
706
|
+
return r(d, c, M({ paramsStr: o }, a));
|
|
707
|
+
}
|
|
708
|
+
function u(e, t) {
|
|
709
|
+
const a = [];
|
|
710
|
+
e.split("||").forEach((c) => {
|
|
711
|
+
const d = [];
|
|
712
|
+
c.trim().split("&&").forEach((y) => {
|
|
713
|
+
d.push(p(y.trim(), t));
|
|
714
|
+
}), a.push(d.join("&&"));
|
|
715
|
+
});
|
|
716
|
+
const o = a.join("||");
|
|
717
|
+
return new Function(`return ${o}`)();
|
|
718
|
+
}
|
|
719
|
+
function f(e, t) {
|
|
720
|
+
return !e || e == "" ? !0 : e.indexOf("||") == -1 && e.indexOf("&&") == -1 ? p(e, t) : u(e, t);
|
|
721
|
+
}
|
|
722
|
+
function p(e, t) {
|
|
723
|
+
if (!e || e == "")
|
|
724
|
+
return !0;
|
|
725
|
+
let a = e.split("#"), o = t[a[0]], c = a[1].toLowerCase();
|
|
726
|
+
return c === "eq" ? o == a[2] : c === "ne" ? o != a[2] : c === "empty" ? a[2] === "true" ? !o || o == "" : o && o.length > 0 : c === "in" ? a[2].split(",").indexOf(String(o)) >= 0 : !1;
|
|
727
|
+
}
|
|
728
|
+
return {
|
|
729
|
+
buttonSwitch: S,
|
|
730
|
+
cgLinkButtonList: P,
|
|
731
|
+
cgBIBtnMap: b,
|
|
732
|
+
getQueryButtonCfg: oe,
|
|
733
|
+
getResetButtonCfg: se,
|
|
734
|
+
getFormConfirmButtonCfg: ue,
|
|
735
|
+
cgTopButtonList: F,
|
|
736
|
+
importUrl: te,
|
|
737
|
+
registerModal: R,
|
|
738
|
+
handleAdd: ce,
|
|
739
|
+
handleEdit: G,
|
|
740
|
+
handleBatchDelete: ge,
|
|
741
|
+
handleAddTestData: he,
|
|
742
|
+
testDataLoading: N,
|
|
743
|
+
testDataBtnShow: q,
|
|
744
|
+
registerImportModal: g,
|
|
745
|
+
onImportExcel: ye,
|
|
746
|
+
onExportExcel: n,
|
|
747
|
+
getDropDownActions: L,
|
|
748
|
+
getActions: K,
|
|
749
|
+
cgButtonJsHandler: ee,
|
|
750
|
+
cgButtonActionHandler: be,
|
|
751
|
+
cgButtonLinkHandler: x,
|
|
752
|
+
initButtonList: $,
|
|
753
|
+
initButtonSwitch: X,
|
|
754
|
+
getDeleteButton: W,
|
|
755
|
+
handleSubmitFlow: U,
|
|
756
|
+
getSubmitFlowButton: Y,
|
|
757
|
+
registerDetailModal: D,
|
|
758
|
+
registerBpmModal: A,
|
|
759
|
+
openDetailModal: O
|
|
760
|
+
};
|
|
761
|
+
}
|
|
762
|
+
export {
|
|
763
|
+
St as a,
|
|
764
|
+
yt as u
|
|
765
|
+
};
|