@jeecg/online 3.8.2-beta → 3.9.0-beta2

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.
Files changed (112) hide show
  1. package/{AccountLoginForm-79fa7b01.mjs → AccountLoginForm-634a76b1.mjs} +1 -1
  2. package/{AiModal-942b59ec.mjs → AiModal-204a2146.mjs} +1 -1
  3. package/{AppForgetPassword-d762e5b3.mjs → AppForgetPassword-f9a6258a.mjs} +2 -2
  4. package/{AppLogin-41372985.mjs → AppLogin-bf783eab.mjs} +9 -9
  5. package/{AppLoginHeader-3b6fa33d.mjs → AppLoginHeader-55594326.mjs} +1 -1
  6. package/{AppNameEmail-8dfbad62.mjs → AppNameEmail-54026ea8.mjs} +2 -2
  7. package/{AppRegister-433c54db.mjs → AppRegister-043efc45.mjs} +3 -3
  8. package/{AppTenant-e49dfa9b.mjs → AppTenant-c7bb8700.mjs} +2 -2
  9. package/{AppThirdForm-7b75b4fc.mjs → AppThirdForm-5e7e1144.mjs} +1 -1
  10. package/{AuthButtonConfig-a0f59cb5.mjs → AuthButtonConfig-4887be0d.mjs} +1 -1
  11. package/{AuthButtonTree-f0a5cc0b.mjs → AuthButtonTree-7e47b44b.mjs} +1 -1
  12. package/{AuthDataConfig-647c4a27.mjs → AuthDataConfig-3cd10ca2.mjs} +1 -1
  13. package/{AuthDataTree-b80a3ea5.mjs → AuthDataTree-714c259c.mjs} +1 -1
  14. package/{AuthFieldConfig-d36a1b2d.mjs → AuthFieldConfig-bb65f78b.mjs} +1 -1
  15. package/{AuthFieldTree-dba6af79.mjs → AuthFieldTree-3e38b12b.mjs} +1 -1
  16. package/{AuthManagerDrawer-5acbd451.mjs → AuthManagerDrawer-dee39b07.mjs} +4 -4
  17. package/{AuthSetterModal-95b5f616.mjs → AuthSetterModal-f176c221.mjs} +7 -7
  18. package/{CgformAddressModal-5d889870.mjs → CgformAddressModal-a3903b24.mjs} +1 -1
  19. package/{CgformCopyList-cc5f76cd.mjs → CgformCopyList-4be1000f.mjs} +37 -37
  20. package/{CgformModal-cebc698b.mjs → CgformModal-115710a6.mjs} +10 -10
  21. package/{CgreportAigcModal-d1e62385.mjs → CgreportAigcModal-3bef8abe.mjs} +1 -1
  22. package/{CgreportModal-2e4421e6.mjs → CgreportModal-0cc48587.mjs} +143 -139
  23. package/{CheckDictTable-8fb7299c.mjs → CheckDictTable-65157c48.mjs} +1 -1
  24. package/{CodeFileListModal-25fad54f.mjs → CodeFileListModal-305c1a62.mjs} +2 -2
  25. package/CodeFileViewModal-320d7acf.mjs +269 -0
  26. package/CodeGeneratorModal-2ba18bd1.mjs +298 -0
  27. package/{CustomButtonList-26490688.mjs → CustomButtonList-98db8fd2.mjs} +1 -1
  28. package/{DBAttributeTable-dea8ab11.mjs → DBAttributeTable-56701599.mjs} +40 -39
  29. package/{DbToOnlineModal-60317a16.mjs → DbToOnlineModal-a82cdeb5.mjs} +1 -1
  30. package/{DetailForm-b92a5e9d.mjs → DetailForm-7d4f630e.mjs} +163 -152
  31. package/{DropMenuItem-82213be6.mjs → DropMenuItem-b3a9cd6a.mjs} +1 -1
  32. package/{EnhanceJavaModal-6ebefc8b.mjs → EnhanceJavaModal-469e645e.mjs} +1 -1
  33. package/{EnhanceJsHistory-8d9b86ca.mjs → EnhanceJsHistory-bb6ba865.mjs} +1 -1
  34. package/{EnhanceJsModal-9439e6f8.mjs → EnhanceJsModal-b0527cbf.mjs} +2 -2
  35. package/{EnhanceSqlModal-ea4592bf.mjs → EnhanceSqlModal-c6e8bce1.mjs} +1 -1
  36. package/{ExtendConfigModal-f509db46.mjs → ExtendConfigModal-7b00b49a.mjs} +1 -1
  37. package/{FieldExtendJsonModal-73bab5b5.mjs → FieldExtendJsonModal-536e6d5b.mjs} +2 -2
  38. package/{FileSelectModal-49d6dade.mjs → FileSelectModal-eb026170.mjs} +1 -1
  39. package/{ForeignKeyTable-330963c1.mjs → ForeignKeyTable-97a5827f.mjs} +1 -1
  40. package/{IndexTable-c0478faa.mjs → IndexTable-4d350e4e.mjs} +1 -1
  41. package/{JModalTip-b1d19eaa.mjs → JModalTip-c3e6726c.mjs} +1 -1
  42. package/{JOnlineSearchSelect-97662e1b.mjs → JOnlineSearchSelect-ffeac61d.mjs} +1 -1
  43. package/{LeftDepart-4b1003f0.mjs → LeftDepart-a727aab7.mjs} +1 -1
  44. package/{LeftRole-8486ba4f.mjs → LeftRole-b533dcf6.mjs} +1 -1
  45. package/{LeftUser-09894a2f.mjs → LeftUser-aaac52cb.mjs} +1 -1
  46. package/{LinkTableConfigModal-cd0980e9.mjs → LinkTableConfigModal-4053b62d.mjs} +1 -1
  47. package/{LinkTableFieldConfigModal-f4106ab7.mjs → LinkTableFieldConfigModal-93552099.mjs} +1 -1
  48. package/{LinkTableListPiece-4187ad7d.mjs → LinkTableListPiece-0f4ca559.mjs} +1 -1
  49. package/{ModalFormDemo-4ec79769.mjs → ModalFormDemo-b8478356.mjs} +1 -1
  50. package/OnlCgformErpList-b0605798.mjs +527 -0
  51. package/{OnlCgformErpSubTable-421e2051.mjs → OnlCgformErpSubTable-89699bc9.mjs} +42 -41
  52. package/{OnlCgformInnerSubTable-9616ebf2.mjs → OnlCgformInnerSubTable-f2722f77.mjs} +105 -102
  53. package/{OnlCgformInnerTableList-5ed887e4.mjs → OnlCgformInnerTableList-992aa7e9.mjs} +20 -19
  54. package/{OnlCgformTabList-c03a1d0a.mjs → OnlCgformTabList-882a0e0c.mjs} +20 -19
  55. package/{OnlineAutoList-e5a61211.mjs → OnlineAutoList-caedb54a.mjs} +19 -18
  56. package/{OnlineAutoModal-38f2d522.mjs → OnlineAutoModal-a0d1a6b8.mjs} +7 -7
  57. package/{OnlineAutoTreeList-16fa962f.mjs → OnlineAutoTreeList-624106c1.mjs} +19 -18
  58. package/OnlineCustomModal-f4e17bed.mjs +246 -0
  59. package/{OnlineDetailModal-79085ba8.mjs → OnlineDetailModal-35394778.mjs} +44 -43
  60. package/OnlineForm-86b5966d.mjs +1079 -0
  61. package/OnlineFormDetail-4b3ad130.mjs +349 -0
  62. package/{OnlineFormUrlAdd-2e05ba0f.mjs → OnlineFormUrlAdd-708c91fb.mjs} +9 -9
  63. package/{OnlineFormUrlDetail-06b2d9e6.mjs → OnlineFormUrlDetail-5c8efaeb.mjs} +14 -13
  64. package/{OnlineFormUrlEdit-77ac4bba.mjs → OnlineFormUrlEdit-8f08474e.mjs} +9 -9
  65. package/{OnlineFormUrlSuccess-cb3f7be4.mjs → OnlineFormUrlSuccess-0c2431a4.mjs} +1 -1
  66. package/{OnlineQueryForm-528af6ed.mjs → OnlineQueryForm-3017a4ca.mjs} +119 -120
  67. package/{OnlineSearchFormItem-51eefaf4.mjs → OnlineSearchFormItem-1b54585f.mjs} +2 -2
  68. package/{OnlineSelectCascade-b218691c.mjs → OnlineSelectCascade-fab4426d.mjs} +61 -55
  69. package/{OnlineSubFormDetail-a1b7f33f.mjs → OnlineSubFormDetail-bbc48c3e.mjs} +48 -45
  70. package/{OnlineTabAutoModal-1c7c4ed2.mjs → OnlineTabAutoModal-b0f9fce8.mjs} +6 -6
  71. package/{OnlineTabDetailModal-7c45e727.mjs → OnlineTabDetailModal-401a26ad.mjs} +38 -37
  72. package/{OnlineTabForm-9682158f.mjs → OnlineTabForm-5c04cbc5.mjs} +22 -22
  73. package/OnlineTabFormDetail-2a28febf.mjs +328 -0
  74. package/{PageAttributeTable-21314341.mjs → PageAttributeTable-18aabf81.mjs} +5 -5
  75. package/{PhoneLoginForm-c3c16f16.mjs → PhoneLoginForm-4a9d7869.mjs} +18 -18
  76. package/ProcessOnlineForm-0ddce4fb.mjs +218 -0
  77. package/{QueryTable-413d1366.mjs → QueryTable-342fd89a.mjs} +1 -1
  78. package/{SetSwitchOptions-82fd6265.mjs → SetSwitchOptions-e1d5a6b4.mjs} +1 -1
  79. package/{ShareAddView-a2dba2ef.mjs → ShareAddView-a5154da3.mjs} +22 -21
  80. package/{ShareEditView-ecd590dc.mjs → ShareEditView-cf761cf3.mjs} +22 -21
  81. package/{ShareView-84f333e7.mjs → ShareView-3b2f5457.mjs} +20 -19
  82. package/{ShareView.vue_vue_type_script_setup_true_lang-9a3a259e.mjs → ShareView.vue_vue_type_script_setup_true_lang-9ea579c2.mjs} +2 -2
  83. package/{SingleView-d4f29169.mjs → SingleView-3cab20a9.mjs} +15 -14
  84. package/{SingleView.vue_vue_type_style_index_0_lang-40ea7e64.mjs → SingleView.vue_vue_type_style_index_0_lang-24d417dc.mjs} +4 -4
  85. package/{SuperQuery-290f5080.mjs → SuperQuery-270b0968.mjs} +39 -39
  86. package/TaskOpinionList-60cf4080.mjs +13 -0
  87. package/{aiModal-6e338c79.mjs → aiModal-e7362c3f.mjs} +2 -2
  88. package/{index-bc0d747e.mjs → index-6d1a78e2.mjs} +2 -2
  89. package/index-740b2c4a.mjs +57 -0
  90. package/{index-7bab525f.mjs → index-8fd12d0f.mjs} +3 -3
  91. package/{index-7890e2b4.mjs → index-b5fe9bd4.mjs} +1 -1
  92. package/{index-9bebbfe5.mjs → index-b811abb9.mjs} +2 -2
  93. package/{index-c5737cbb.mjs → index-d95bb7c2.mjs} +4 -4
  94. package/{index-254a82b7.mjs → index-e2c3e6f3.mjs} +129 -123
  95. package/main.index.js +1 -1
  96. package/package.json +1 -1
  97. package/style.css +1 -1
  98. package/useCgformList-6d5547ff.mjs +410 -0
  99. package/{useExtendComponent-d1db211d.mjs → useExtendComponent-95ce0719.mjs} +405 -405
  100. package/{useListButton-7f9674a0.mjs → useListButton-73071548.mjs} +21 -21
  101. package/CodeFileViewModal-12299ab5.mjs +0 -253
  102. package/CodeGeneratorModal-791b1695.mjs +0 -281
  103. package/OnlCgformErpList-63089149.mjs +0 -498
  104. package/OnlineCustomModal-7e31297e.mjs +0 -232
  105. package/OnlineForm-0438f4bf.mjs +0 -1012
  106. package/OnlineFormDetail-76d243ed.mjs +0 -348
  107. package/OnlineTabFormDetail-b8650175.mjs +0 -327
  108. package/ProcessOnlineForm-d6113dec.mjs +0 -188
  109. package/README.md +0 -26
  110. package/index-30c0a14f.mjs +0 -57
  111. package/useCgformList-52631580.mjs +0 -395
  112. /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,1079 @@
1
+ var $t = Object.defineProperty, en = Object.defineProperties;
2
+ var tn = Object.getOwnPropertyDescriptors;
3
+ var Ve = Object.getOwnPropertySymbols;
4
+ var nn = Object.prototype.hasOwnProperty, ln = Object.prototype.propertyIsEnumerable;
5
+ var Be = (u, f, s) => f in u ? $t(u, f, { enumerable: !0, configurable: !0, writable: !0, value: s }) : u[f] = s, S = (u, f) => {
6
+ for (var s in f || (f = {}))
7
+ nn.call(f, s) && Be(u, s, f[s]);
8
+ if (Ve)
9
+ for (var s of Ve(f))
10
+ ln.call(f, s) && Be(u, s, f[s]);
11
+ return u;
12
+ }, de = (u, f) => en(u, tn(f));
13
+ var w = (u, f, s) => new Promise((a, x) => {
14
+ var M = (F) => {
15
+ try {
16
+ P(s.next(F));
17
+ } catch (A) {
18
+ x(A);
19
+ }
20
+ }, O = (F) => {
21
+ try {
22
+ P(s.throw(F));
23
+ } catch (A) {
24
+ x(A);
25
+ }
26
+ }, P = (F) => F.done ? a(F.value) : Promise.resolve(F.value).then(M, O);
27
+ P((s = s.apply(u, f)).next());
28
+ });
29
+ import { useMessage as on } from "/@/hooks/web/useMessage";
30
+ import { ref as y, inject as an, reactive as rn, watch as sn, computed as un, resolveComponent as B, openBlock as I, createElementBlock as le, normalizeClass as cn, createVNode as G, createBlock as oe, withCtx as Q, Fragment as fn, renderList as dn, normalizeStyle as mn, createElementVNode as Ie, toDisplayString as je, createCommentVNode as me, renderSlot as pn, unref as Le, nextTick as Ne, toRaw as J } from "vue";
31
+ import { BasicForm as hn, useForm as gn } from "/@/components/Form/index";
32
+ import { e as bn, O as yn, f as vn, h as Fn, u as Sn, l as Y, i as wn, g as Tn, V as X, S as kn, j as Cn, k as Je, d as pe } from "./useExtendComponent-95ce0719.mjs";
33
+ import { defHttp as ae } from "/@/utils/http/axios";
34
+ import { pick as _n, omit as We, debounce as On, cloneDeep as Pn } from "lodash-es";
35
+ import { sleep as An, goJmReportViewPage as En } from "/@/utils";
36
+ import { Loading as Rn } from "/@/components/Loading";
37
+ import "/@/components/jeecg/JVxeTable/types";
38
+ import { getToken as xn } from "/@/utils/auth";
39
+ import { PrinterOutlined as Mn } from "@ant-design/icons-vue";
40
+ import "/@/hooks/core/useContext";
41
+ import "/@/utils/mitt";
42
+ import { useModal as Dn } from "/@/components/Modal";
43
+ import { u as Vn, G as Bn } from "./useCustomHook-3a17a690.mjs";
44
+ import { E as ie } from "./constant-fa63bd66.mjs";
45
+ import { useAppInject as In } from "/@/hooks/web/useAppInject";
46
+ import { isArray as jn } from "/@/utils/is";
47
+ import { usePermissionStore as Ln } from "/@/store/modules/permission";
48
+ import "./OnlineForm.vue_vue_type_style_index_0_scoped_60bd1850_lang-4ed993c7.mjs";
49
+ import { _ as Nn } from "./index-740b2c4a.mjs";
50
+ import "/@/components/Form/src/componentMap";
51
+ import "/@/utils/propTypes";
52
+ import "/@/utils/common/compUtils";
53
+ import "/@/components/Form/src/jeecg/components/JUpload";
54
+ import "/@/views/system/user/user.api";
55
+ import "/@/store/modules/user";
56
+ import "/@/utils/desform/customExpression";
57
+ import "/@/utils/dict/JDictSelectUtil";
58
+ import "/@/components/Table";
59
+ import "/@/hooks/system/useListPage";
60
+ import "vue-router";
61
+ import "/@/components/Form/src/utils/Area";
62
+ import "/@/components/Preview/index";
63
+ import "./LinkTableListPiece-0f4ca559.mjs";
64
+ import "/@/components/jeecg/OnLine/JPopupOnlReport.vue";
65
+ import "/@/api/common/api";
66
+ import "/@/assets/images/placeholderImage.png";
67
+ import "./OnlineSelectCascade-fab4426d.mjs";
68
+ import "./JModalTip-c3e6726c.mjs";
69
+ import "ant-design-vue";
70
+ import "@vueuse/core";
71
+ import "/@/utils/cache";
72
+ const he = {
73
+ optPre: "/online/cgform/api/form/",
74
+ urlButtonAction: "/online/cgform/api/doButton"
75
+ }, Jn = {
76
+ name: "OnlineForm",
77
+ components: {
78
+ BasicForm: hn,
79
+ Loading: Rn,
80
+ OnlineSubForm: bn,
81
+ PrinterOutlined: Mn,
82
+ OnlinePopModal: yn
83
+ },
84
+ props: {
85
+ id: {
86
+ type: String,
87
+ default: ""
88
+ },
89
+ formTemplate: {
90
+ type: Number,
91
+ default: 1
92
+ },
93
+ disabled: {
94
+ type: Boolean,
95
+ default: !1
96
+ },
97
+ isTree: {
98
+ type: Boolean,
99
+ default: !1
100
+ },
101
+ pidField: {
102
+ type: String,
103
+ default: ""
104
+ },
105
+ submitTip: {
106
+ type: Boolean,
107
+ default: !0
108
+ },
109
+ modalClass: {
110
+ type: String,
111
+ default: ""
112
+ },
113
+ themeTemplate: {
114
+ type: String,
115
+ default: ""
116
+ },
117
+ // update-begin--author:liaozhiyang---date:20231128---for:【QQYUN-7260】erp主表编辑时保存子表记录
118
+ // erp风格会传来所有子表数据
119
+ subTableSource: {
120
+ default: () => ({})
121
+ },
122
+ // update-end-author:liaozhiyang---date:20231128---for:【QQYUN-7260】erp主表编辑时保存子表记录
123
+ // -update-begin--author:liaozhiyang---date:20240613---for:【TV360X-1000】流程一对多走流程的接口
124
+ // 流程会传taskId
125
+ taskId: {
126
+ type: String
127
+ },
128
+ // -update-end--author:liaozhiyang---date:20240613---for:【TV360X-1000】流程一对多走流程的接口
129
+ cgBIBtnMap: Object,
130
+ buttonSwitch: Object
131
+ },
132
+ emits: ["success", "rendered", "close", "validate"],
133
+ setup(u, { emit: f }) {
134
+ const { createMessage: s } = on(), a = y(null), x = y(null), M = y(!0), O = y(!1), P = y(1), F = y(""), A = y(!1), _ = y(!1), { getIsMobile: j } = In(), Z = y(!1), W = an("foreignkey", { value: {} }), p = y(!j.value), K = y(null);
135
+ let v = null;
136
+ const q = rn({
137
+ reportPrintShow: 0,
138
+ reportPrintUrl: "",
139
+ joinQuery: 0,
140
+ modelFullscreen: 0,
141
+ modalMinWidth: "",
142
+ commentStatus: 0
143
+ }), {
144
+ onlineFormContext: b,
145
+ resetContext: Ue,
146
+ getSubAddBtnCfg: Ye,
147
+ getSubRemoveBtnCfg: Ke,
148
+ getSubOpenAddBtnCfg: qe,
149
+ getSubOpenEditBtnCfg: He
150
+ } = vn(u), {
151
+ formSchemas: $,
152
+ defaultValueFields: H,
153
+ changeDataIfArray2String: ge,
154
+ tableName: D,
155
+ dbData: V,
156
+ checkOnlyFieldValue: ze,
157
+ hasSubTable: Ge,
158
+ subTabInfo: T,
159
+ refMap: E,
160
+ subDataSource: ee,
161
+ baseColProps: Qe,
162
+ createFormSchemas: Xe,
163
+ linkDownList: Kn,
164
+ fieldDisplayStatus: U,
165
+ labelCol: Ze,
166
+ wrapperCol: $e,
167
+ labelWidth: et
168
+ } = Fn(u, x);
169
+ let { EnhanceJS: d, initCgEnhanceJs: tt } = Sn(b, !1);
170
+ sn(
171
+ [T, j],
172
+ () => {
173
+ j.value && T.value.length && T.value.forEach((e) => {
174
+ e.relationType != 1 && e.columns.forEach((t) => {
175
+ t.width = 100;
176
+ });
177
+ });
178
+ },
179
+ { immediate: !0 }
180
+ );
181
+ const { executeJsEnhanced: nt } = Vn({}, b), [lt, { setProps: ot, validate: re, resetFields: be, clearValidate: at, setFieldsValue: R, updateSchema: z, getFieldsValue: te, scrollToField: ye }] = gn({
182
+ schemas: $,
183
+ showActionButtonGroup: !1,
184
+ baseColProps: Qe,
185
+ // update-begin--author:liaozhiyang---date:20240329---for:【QQYUN-7872】online表单label较长优化
186
+ labelWidth: et,
187
+ // update-end--author:liaozhiyang---date:20240329---for:【QQYUN-7872】online表单label较长优化
188
+ // update-begin--author:liaozhiyang---date:20240105---for:【QQYUN-7499】多列风格富文本、markdown增加独占一行功能
189
+ labelCol: Ze,
190
+ wrapperCol: $e
191
+ // update-end--author:liaozhiyang---date:20240105---for:【QQYUN-7499】多列风格富文本、markdown增加独占一行功能
192
+ }), ve = y(!1);
193
+ function it() {
194
+ let e = u.disabled;
195
+ ve.value = e, ot({ disabled: e });
196
+ }
197
+ function rt(e, t, n) {
198
+ return w(this, null, function* () {
199
+ yield st(), F.value = "", yield be(), setTimeout(() => {
200
+ at();
201
+ }, 0), V.value = "";
202
+ let l = Le(e);
203
+ _.value = l, dt(), l ? yield Se(t) : we(), Ne(() => {
204
+ var o;
205
+ !l && n && R(n), ut(), se("js", "loaded"), it(), (o = K.value) != null && o.length && (K.value[0].scrollTop = 0);
206
+ });
207
+ });
208
+ }
209
+ function st() {
210
+ return w(this, null, function* () {
211
+ if (u.isTree === !0) {
212
+ let e = u.pidField, t = $.value;
213
+ t && t.length > 0 && t.filter((l) => l.field === e).length > 0 && (yield z({
214
+ field: e,
215
+ componentProps: {
216
+ reload: (/* @__PURE__ */ new Date()).getTime(),
217
+ // update-begin--author:liaozhiyang---date:20240529---for:【TV360X-87】树表编辑时不可选自己及子孙节点当父节点
218
+ hiddenNodeKey: ""
219
+ // update-end--author:liaozhiyang---date:20240529---for:【TV360X-87】树表编辑时不可选自己及子孙节点当父节点
220
+ }
221
+ }));
222
+ }
223
+ });
224
+ }
225
+ const L = {
226
+ keys: [],
227
+ map: /* @__PURE__ */ new Map(),
228
+ calcFn: /* @__PURE__ */ new Map()
229
+ };
230
+ function ut() {
231
+ let e = J(H[D.value]);
232
+ Le(_) === !1 && Y(e, (n) => {
233
+ R(n);
234
+ });
235
+ const t = wn(e);
236
+ L.keys = [...t.keys()], L.map = t, L.calcFn.clear();
237
+ }
238
+ function ct(e, t) {
239
+ if (L.keys.includes(e)) {
240
+ let n = L.calcFn.get(e);
241
+ typeof n != "function" && (n = On(() => {
242
+ let l = J(H[D.value]);
243
+ if (Array.isArray(l) && l.length > 0) {
244
+ const o = L.map.get(e);
245
+ l = l.filter((i) => o.includes(i.field));
246
+ } else
247
+ l = [];
248
+ if (l.length > 0) {
249
+ let o = te();
250
+ Y(l, (i) => R(i), o);
251
+ }
252
+ }, 150), L.calcFn.set(e, n)), n(t);
253
+ }
254
+ }
255
+ function Fe(e, t) {
256
+ let n = J(H[e.key]);
257
+ Y(n, (l) => {
258
+ const { row: o, target: i } = t;
259
+ let c = [{ rowKey: o.id, values: S({}, l) }];
260
+ i.setValues(c);
261
+ });
262
+ }
263
+ function Se(e) {
264
+ return w(this, null, function* () {
265
+ let t = yield pt(e.id);
266
+ V.value = Object.assign({}, e, t);
267
+ let n = mt.value, l = _n(t, ...n);
268
+ u.disabled && Object.keys(l).map((o) => {
269
+ !l[o] && l[o] !== 0 && l[o] !== "0" && delete l[o];
270
+ }), yield R(l), ft(e.id), we(t);
271
+ });
272
+ }
273
+ function we(e) {
274
+ e || (e = {});
275
+ let t = Object.keys(ee.value);
276
+ if (t && t.length > 0) {
277
+ let n = {};
278
+ for (let l of t)
279
+ n[l] = e[l] || [];
280
+ ee.value = n;
281
+ }
282
+ }
283
+ function ft(e) {
284
+ var t;
285
+ if (u.isTree === !0) {
286
+ const { schema: n } = v, l = (t = n.properties) != null ? t : {}, o = Object.entries(l);
287
+ if (o.length) {
288
+ const i = o.find(([c, m]) => m.view === "sel_tree" && m.pidComponent != null);
289
+ if (i) {
290
+ const c = i[0];
291
+ $.value.find((r) => r.field == c) && z({
292
+ field: c,
293
+ componentProps: {
294
+ hiddenNodeKey: e
295
+ }
296
+ });
297
+ }
298
+ }
299
+ }
300
+ }
301
+ function dt() {
302
+ var e;
303
+ (e = T.value) == null || e.forEach((t) => {
304
+ t.relationType == 1 && E[t.key].value && E[t.key].value[0].resetFields();
305
+ });
306
+ }
307
+ let mt = un(() => {
308
+ let e = $.value, t = [];
309
+ for (let n of e)
310
+ t.push(n.field);
311
+ return t;
312
+ });
313
+ function pt(e) {
314
+ let t = `${he.optPre}${u.id}/${e}`;
315
+ return new Promise((n, l) => {
316
+ ae.get({ url: t }, { isTransformResponse: !1 }).then((o) => {
317
+ o.success ? n(o.result) : (l(), s.warning(o.message));
318
+ }).catch(() => {
319
+ l();
320
+ });
321
+ });
322
+ }
323
+ function ht(e) {
324
+ return w(this, null, function* () {
325
+ P.value = e.head.tableType, D.value = e.head.tableName, M.value = e.head.tableType == 1, yt(e.head.extConfigJson), Xe(e.schema.properties, e.schema.required, ze, q), d = tt(e.enhanceJs), f("rendered", q);
326
+ let t = yield Tn(x);
327
+ t.$formValueChange = (n, l, o) => {
328
+ Vt(n, l), o && R(o), gt(n, l, o), ct(n, l);
329
+ }, d && d.setup && Ee(d.setup), v = e;
330
+ });
331
+ }
332
+ function gt(e, t, n) {
333
+ b.changEvent(e, t, n);
334
+ }
335
+ function bt(e) {
336
+ b.addObject2Context("changEvent", e);
337
+ }
338
+ function yt(e) {
339
+ let t = { reportPrintShow: 0, reportPrintUrl: "", joinQuery: 0, modelFullscreen: 0, modalMinWidth: "", commentStatus: 0, formLabelLength: null };
340
+ e && (t = JSON.parse(e), j.value && (t.commentStatus = 0)), Z.value = !!t.formLabelLength, Object.keys(t).map((n) => {
341
+ q[n] = t[n];
342
+ });
343
+ }
344
+ function vt() {
345
+ A.value = !0, Te();
346
+ }
347
+ function Te() {
348
+ M.value === !0 ? kt() : St();
349
+ }
350
+ function Ft() {
351
+ return w(this, null, function* () {
352
+ if (M.value === !0)
353
+ try {
354
+ yield re();
355
+ } catch (e) {
356
+ Array.isArray(e == null ? void 0 : e.errorFields) && e.errorFields[0] && f("validate", { passed: !1 });
357
+ }
358
+ else
359
+ yield ke();
360
+ });
361
+ }
362
+ function St() {
363
+ ke().then((e) => {
364
+ _e(e);
365
+ });
366
+ }
367
+ function ke() {
368
+ let e = {};
369
+ return new Promise((t, n) => {
370
+ re().then(
371
+ (l) => t(l),
372
+ ({ errorFields: l, values: o }) => {
373
+ n({
374
+ // update-begin--author:liaozhiyang---date:20240617---for:【TV360X-496】使用数值类型,金额校验,控件默认值得出的是小数导致校验过不去给提示
375
+ errorFields: l,
376
+ values: o,
377
+ // update-end--author:liaozhiyang---date:20240617---for:【TV360X-496】使用数值类型,金额校验,控件默认值得出的是小数导致校验过不去给提示
378
+ code: X,
379
+ key: D.value,
380
+ // 滚动到未通过校验的字段上
381
+ scrollToField: () => l[0] && ye(l[0].name, { behavior: "smooth", block: "center" })
382
+ });
383
+ }
384
+ );
385
+ }).then((t) => (Object.assign(e, ge(t)), u.themeTemplate === ie ? Promise.resolve({}) : Tt())).then((t) => (Object.assign(e, t), Promise.resolve(e))).catch((t) => ((t === X || (t == null ? void 0 : t.code) === X) && (Ce(t.errorFields, t.values, M.value, t.key).then((n) => {
386
+ n || s.warning("校验未通过");
387
+ }), t.key && (wt(t.key), t.scrollToField && setTimeout(() => t.scrollToField(), 150)), f("validate", { passed: !1 })), Promise.reject(null)));
388
+ }
389
+ function wt(e) {
390
+ let t = T.value;
391
+ for (let n = 0; n < t.length; n++)
392
+ if (e == t[n].key) {
393
+ let l = n + "";
394
+ if (ne.value === l)
395
+ break;
396
+ if (ne.value = l, t[n].relationType === 0) {
397
+ let o = k(e);
398
+ An(300, () => o == null ? void 0 : o.validateTable());
399
+ }
400
+ break;
401
+ }
402
+ }
403
+ function Tt() {
404
+ return new Promise((e, t) => w(this, null, function* () {
405
+ let n = {};
406
+ try {
407
+ let l = T.value;
408
+ for (let o = 0; o < l.length; o++) {
409
+ let i = l[o].key, c = k(i);
410
+ if (l[o].relationType == 1)
411
+ try {
412
+ let m = yield c.getAll();
413
+ n[i] = [], n[i].push(m);
414
+ } catch (m) {
415
+ return t(S({ code: X, key: i }, m));
416
+ }
417
+ else {
418
+ if (yield c.fullValidateTable())
419
+ return t({ code: X, key: i });
420
+ n[i] = c.getTableData();
421
+ }
422
+ }
423
+ } catch (l) {
424
+ t(l);
425
+ }
426
+ e(n);
427
+ }));
428
+ }
429
+ function kt() {
430
+ return w(this, null, function* () {
431
+ try {
432
+ let e = yield re();
433
+ e = Object.assign({}, V.value, e), e = ge(e), O.value = !0, _e(e);
434
+ } catch (e) {
435
+ Array.isArray(e == null ? void 0 : e.errorFields) && e.errorFields[0] && (ye(e.errorFields[0].name, { behavior: "smooth", block: "center" }), Ce(e.errorFields, e.values, M.value), f("validate", { passed: !1 }));
436
+ } finally {
437
+ O.value = !1, f("close");
438
+ }
439
+ });
440
+ }
441
+ function Ce(e, t, n, l = null) {
442
+ return w(this, null, function* () {
443
+ var i;
444
+ let o = !1;
445
+ if (e != null && e.length) {
446
+ const c = (i = v.schema) != null ? i : {}, { properties: m = {} } = c, r = e[0].name[0];
447
+ let g;
448
+ if (n || l === D.value)
449
+ g = m[r];
450
+ else {
451
+ const h = m[l], { properties: C = {} } = h;
452
+ g = C[r];
453
+ }
454
+ g.type === "number" && g.view === "number" && g.defVal && (yield Y(
455
+ [
456
+ {
457
+ field: r,
458
+ type: g.type,
459
+ value: g.defVal,
460
+ view: g.view
461
+ }
462
+ ],
463
+ (h) => {
464
+ h[r] === t[r] && (s.warning(`${g.title}的默认值是:${t[r]},导致校验通不过,需要正确配置默认值!`), o = !0);
465
+ }
466
+ ));
467
+ }
468
+ return o;
469
+ });
470
+ }
471
+ function _e(e) {
472
+ u.themeTemplate === ie && _.value && Object.keys(u.subTableSource).length && (e = S(S({}, e), u.subTableSource)), Jt(De, e).then(() => {
473
+ _t(e);
474
+ }).catch((t) => {
475
+ s.warning(t);
476
+ });
477
+ }
478
+ const Ct = (e) => {
479
+ const { schema: t } = v, { properties: n } = t, l = (o, i) => {
480
+ Object.entries(o).forEach(([c, m]) => {
481
+ var g;
482
+ const r = i[c];
483
+ if (r) {
484
+ if (r.view === "tab" && jn(m)) {
485
+ if (r.properties && m.forEach((h) => {
486
+ l(h, r.properties);
487
+ }), (g = r.columns) != null && g.length) {
488
+ const h = Pn(r.columns.filter((C) => C.type === "date" && C.fieldExtendJson));
489
+ if (h.length) {
490
+ const C = {};
491
+ h.forEach((N) => {
492
+ C[N.key] = {
493
+ view: "date",
494
+ fieldExtendJson: N.fieldExtendJson
495
+ };
496
+ }), m.forEach((N) => {
497
+ l(N, C);
498
+ });
499
+ }
500
+ }
501
+ } else if (r.view === "date" && typeof m == "string" && m !== "") {
502
+ let h = r.fieldExtendJson;
503
+ h && (h = JSON.parse(h), h.picker && h.picker !== "default" && (h.picker === "year" ? o[c] = pe(m).set("month", 0).set("date", 1).format("YYYY-MM-DD") : h.picker === "month" ? o[c] = pe(m).set("date", 1).format("YYYY-MM-DD") : h.picker === "week" && (o[c] = pe(m).startOf("week").format("YYYY-MM-DD"))));
504
+ }
505
+ }
506
+ });
507
+ };
508
+ l(e, n);
509
+ };
510
+ function _t(e) {
511
+ Object.keys(e).map((o) => {
512
+ Array.isArray(e[o]) && e[o].length == 0 && (e[o] = "");
513
+ }), Ct(e);
514
+ let t = F.value, n = `${he.optPre}${u.id}?tabletype=${P.value}`;
515
+ t && (n = `${t}?tabletype=${P.value}`), A.value === !0 && (e[kn] = 1), W.value.field && W.value.value && (e[W.value.field] = W.value.value);
516
+ let l = _.value === !0 ? "put" : "post";
517
+ ae.request({ url: n, method: l, params: e }, { isTransformResponse: !1 }).then((o) => {
518
+ o.success ? (o.result && (e[Cn] = o.result), f("success", e), u.submitTip === !0 && s.success(o.message)) : s.warning(o.message);
519
+ }).finally(() => {
520
+ O.value = !1, f("close");
521
+ });
522
+ }
523
+ function Ot(e, t, n) {
524
+ t && n ? n.vxeProps ? n.setValues([
525
+ {
526
+ rowKey: t,
527
+ values: e
528
+ }
529
+ ]) : n.setValues(e) : R(e);
530
+ }
531
+ function Pt(e, t) {
532
+ let n = {};
533
+ n[e] = t, R(n);
534
+ }
535
+ const ne = y("0"), Oe = y(j.value ? "auto" : 500), Pe = y(340);
536
+ function At(e) {
537
+ if (_.value === !0) {
538
+ let t = V.value;
539
+ return Et(t, e);
540
+ }
541
+ return "";
542
+ }
543
+ function Et(e, t) {
544
+ if (e) {
545
+ let n = e[t];
546
+ return !n && n !== 0 && (n = e[t.toLowerCase()], !n && n !== 0 && (n = e[t.toUpperCase()])), n;
547
+ }
548
+ return "";
549
+ }
550
+ function Rt(e, t) {
551
+ if (d && d[t + "_onlChange"]) {
552
+ let n = d[t + "_onlChange"](), l = Object.keys(e)[0];
553
+ if (n[l]) {
554
+ let i = k(t).getFormEvent(), c = S({
555
+ column: { key: l },
556
+ value: e[l]
557
+ }, i);
558
+ n[l].call(b, b, c);
559
+ }
560
+ }
561
+ }
562
+ function xt(e, t) {
563
+ if (d && d[t + "_onlChange"]) {
564
+ let n = d[t + "_onlChange"](b);
565
+ if (e.column === "all") {
566
+ let l = Object.keys(n);
567
+ if (l.length > 0)
568
+ for (let o of l)
569
+ n[o].call(b, b, e);
570
+ } else {
571
+ let l = e.column.key || e.col.key;
572
+ n[l] && e.row && e.row.id && n[l].call(b, b, e);
573
+ }
574
+ }
575
+ }
576
+ function Mt(e, t) {
577
+ var n;
578
+ if (d && d[t + "_onlChange"]) {
579
+ let l = d[t + "_onlChange"](b), o = Object.keys(l);
580
+ if (o.length > 0)
581
+ for (let i of o)
582
+ (n = l[i]) == null || n.call(b, b, de(S({}, e), { row: e.deleteRows }));
583
+ }
584
+ }
585
+ function Dt(e, t) {
586
+ t.isModalData || Fe(e, t);
587
+ }
588
+ function Ae(e) {
589
+ return "online_" + e + ":";
590
+ }
591
+ function Vt(e, t) {
592
+ return w(this, null, function* () {
593
+ if (!d || !d.onlChange || !e)
594
+ return !1;
595
+ let n = d.onlChange();
596
+ n[e] && setTimeout(() => w(this, null, function* () {
597
+ let o = {
598
+ row: yield te(),
599
+ column: { key: e },
600
+ value: t
601
+ };
602
+ n[e].call(b, b, o);
603
+ }), 0);
604
+ });
605
+ }
606
+ function Ee(e) {
607
+ let n = e.toLocaleString().match(Bn);
608
+ if (n.length > 1) {
609
+ let l = n[1];
610
+ nt(l);
611
+ }
612
+ }
613
+ function se(e, t) {
614
+ if (e == "js") {
615
+ let n = t + "_hook";
616
+ d && d[t] ? d[t].call(b, b) : d && d[n] && Ee(d[n]);
617
+ } else if (e == "action") {
618
+ let n = V.value, l = {
619
+ formId: u.id,
620
+ buttonCode: t,
621
+ dataId: n.id,
622
+ uiFormData: Object.assign({}, n)
623
+ };
624
+ ae.post(
625
+ {
626
+ url: `${he.urlButtonAction}`,
627
+ params: l
628
+ },
629
+ { isTransformResponse: !1 }
630
+ ).then((o) => {
631
+ o.success ? s.success("处理完成!") : s.warning("处理失败!");
632
+ });
633
+ }
634
+ }
635
+ function Re(e) {
636
+ let t = k(e), n = [...t.getNewDataWithId(), ...ee.value[e]];
637
+ if (!n || n.length == 0)
638
+ return !1;
639
+ let l = [];
640
+ for (let o of n)
641
+ l.push(o.id);
642
+ t.removeRowsById(l);
643
+ }
644
+ function xe(e, t) {
645
+ if (!t)
646
+ return !1;
647
+ let n = k(e);
648
+ typeof t == "object" ? n.addRows(t, !0) : this.$message.error("添加子表数据,参数不识别!");
649
+ }
650
+ function Bt(e, t) {
651
+ Re(e), xe(e, t);
652
+ }
653
+ function It(e, t) {
654
+ !t && t.length <= 0 && (t = []), t.map((n) => {
655
+ n.hasOwnProperty("label") || (n.label = n.text);
656
+ }), z({
657
+ field: e,
658
+ componentProps: {
659
+ options: t
660
+ }
661
+ });
662
+ }
663
+ function jt({ field: e, dict: t, label: n, type: l, subTableName: o }) {
664
+ var c, m;
665
+ const i = t.split(",").map((r) => encodeURIComponent(r)).join(",");
666
+ if (l == "subTable") {
667
+ const r = T.value.find((g) => g.key === o);
668
+ if (r) {
669
+ const g = r.columns.findIndex((h) => h.key === e);
670
+ g !== -1 && ae.get({
671
+ url: `/sys/dict/loadDict/${i}`,
672
+ params: { keyword: "", pageSize: 1e3 }
673
+ }).then((h) => {
674
+ const C = t.split(","), N = { customOptions: !0, dictTable: C[0], dictCode: C[2], dictText: C[1], options: h };
675
+ n && (N.title = n), r.columns[g] = S(S({}, r.columns[g]), N), window.findSubTableInfo = r;
676
+ });
677
+ }
678
+ } else if (l == "subForm") {
679
+ if ((m = (c = E[o]) == null ? void 0 : c.value) != null && m[0]) {
680
+ const r = {
681
+ field: e,
682
+ componentProps: {
683
+ dict: i
684
+ }
685
+ };
686
+ n && (r.label = n), E[o].value[0].updateSchema(r);
687
+ }
688
+ } else {
689
+ const r = {
690
+ field: e,
691
+ componentProps: {
692
+ dict: i
693
+ }
694
+ };
695
+ n && (r.label = n), z(r);
696
+ }
697
+ }
698
+ function Lt(e, t, n) {
699
+ const l = T.value.find((o) => o.key === e);
700
+ if (l) {
701
+ !n && n.length <= 0 && (n = []), n.map((i) => {
702
+ i.hasOwnProperty("label") || (i.label = i.text);
703
+ });
704
+ const o = l.columns.findIndex((i) => i.key === t);
705
+ o !== -1 && (l.columns[o] = de(S({}, l.columns[o]), { options: n, dictCode: "" }));
706
+ }
707
+ }
708
+ function Nt(e, t, n) {
709
+ var l, o;
710
+ (o = (l = E[e]) == null ? void 0 : l.value) != null && o[0] && (!n && n.length <= 0 && (n = []), n.map((i) => {
711
+ i.hasOwnProperty("label") || (i.label = i.text);
712
+ }), E[e].value[0].updateSchema({
713
+ field: t,
714
+ componentProps: {
715
+ dictCode: "",
716
+ options: n
717
+ }
718
+ }));
719
+ }
720
+ function Jt(e, t) {
721
+ return d && d.beforeSubmit ? d.beforeSubmit(e, t) : Promise.resolve();
722
+ }
723
+ function Wt(e, t) {
724
+ let n = J(U);
725
+ Object.keys(n).map((l) => {
726
+ l.endsWith("_load") || l.endsWith("_disabled") || (U[l] = !0);
727
+ }), e && e.length > 0 ? Object.keys(n).map((l) => {
728
+ !l.endsWith("_load") && e.indexOf(l) < 0 && (U[l] = !1);
729
+ }) : t && t.length > 0 && Object.keys(n).map((l) => {
730
+ t.indexOf(l) >= 0 && (U[l] = !1);
731
+ });
732
+ }
733
+ function Ut(e, t) {
734
+ return w(this, null, function* () {
735
+ F.value = t, yield be(), V.value = "", _.value = !0, yield Se(e), yield Ne(() => {
736
+ se("js", "loaded");
737
+ });
738
+ });
739
+ }
740
+ function k(e) {
741
+ let t = E[e].value;
742
+ if (t instanceof Array && (t = t[0]), !t) {
743
+ s.warning("子表ref找不到:" + e);
744
+ return;
745
+ }
746
+ return t;
747
+ }
748
+ function Yt() {
749
+ let e = q.reportPrintUrl, t = V.value.id, n = xn();
750
+ En(e, t, n);
751
+ }
752
+ function Kt() {
753
+ setTimeout(() => {
754
+ var o, i;
755
+ if (!a.value)
756
+ return;
757
+ const e = document.createElement("iframe");
758
+ e.style.display = "none", document.body.appendChild(e);
759
+ const t = e.contentDocument || ((o = e.contentWindow) == null ? void 0 : o.document);
760
+ if (!t)
761
+ return;
762
+ t.open(), t.write(`
763
+ <!DOCTYPE html>
764
+ <html>
765
+ <head>
766
+ <title>打印表单</title>
767
+ ${Array.from(document.querySelectorAll('style, link[rel="stylesheet"]')).map((c) => c.outerHTML).join("")}
768
+ </head>
769
+ <body>
770
+ ${a.value.outerHTML}
771
+ </body>
772
+ </html>
773
+ `);
774
+ const n = a.value.scrollHeight, l = t.createElement("style");
775
+ l.innerHTML = `
776
+ body {
777
+ margin: 0;
778
+ padding: 15px;
779
+ font-family: Arial, sans-serif;
780
+ }
781
+ img {
782
+ max-width: 100%;
783
+ height: auto;
784
+ }
785
+ @page {
786
+ size: auto;
787
+ margin: 15mm;
788
+ }
789
+ @media print {
790
+ body {
791
+ padding: 0;
792
+ height: ${n}px;
793
+ }
794
+ }
795
+ `, t.head.appendChild(l), t.close(), (i = e.contentWindow) == null || i.addEventListener("afterprint", () => {
796
+ document.body.removeChild(e);
797
+ }), setTimeout(() => {
798
+ var c;
799
+ (c = e.contentWindow) == null || c.print();
800
+ }, 200);
801
+ }, 10);
802
+ }
803
+ const [qt, { openModal: Me }] = Dn(), ue = y(""), ce = y(""), fe = y(!0);
804
+ function Ht(e) {
805
+ ue.value = e.id, ce.value = e.key, fe.value = !1, Me(!0, { isUpdate: !1, tableType: "3" });
806
+ }
807
+ function zt(e) {
808
+ let n = k(e.key).getSelectedData();
809
+ if (n.length != 1) {
810
+ s.warning("请选择一条数据");
811
+ return;
812
+ }
813
+ ue.value = e.id, ce.value = e.key, fe.value = !1, Me(!0, { isUpdate: !0, record: n[0] });
814
+ }
815
+ function Gt(e) {
816
+ const t = e[Je];
817
+ let n = We(e, [Je]);
818
+ if (n.id) {
819
+ let l = We(S({}, n), "id"), o = [{ rowKey: n.id, values: l }];
820
+ k(t).setValues(o);
821
+ } else
822
+ k(t).addRows(n, { isOnlineJS: !1, setActive: !1, emitChange: !0, isModalData: !0 });
823
+ }
824
+ function Qt() {
825
+ if (u.themeTemplate === ie)
826
+ return;
827
+ let e = T.value;
828
+ if (e && e.length > 0) {
829
+ for (let t of e)
830
+ if (t.relationType != 1) {
831
+ let n = k(t.key);
832
+ n && n.clearSelection();
833
+ }
834
+ }
835
+ }
836
+ function Xt() {
837
+ let e = te(), t = J(H[D.value]);
838
+ Y(t, (n) => {
839
+ R(n);
840
+ }, e);
841
+ }
842
+ function Zt(e, t) {
843
+ let n = T.value;
844
+ if (n && n.length > 0) {
845
+ let l = n.filter((o) => o.key === e);
846
+ if (l.length == 0)
847
+ return;
848
+ if (l[0].relationType == 1)
849
+ k(e).executeFillRule();
850
+ else {
851
+ let o = J(H[e]), i = J(t.row);
852
+ Y(o, (c) => {
853
+ const { row: m, target: r } = t;
854
+ let g = [{ rowKey: m.id, values: S({}, c) }];
855
+ r.setValues(g);
856
+ }, i);
857
+ }
858
+ }
859
+ }
860
+ let De = {
861
+ tableName: D,
862
+ loading: O,
863
+ subActiveKey: ne,
864
+ onlineFormRef: x,
865
+ getFieldsValue: te,
866
+ setFieldsValue: R,
867
+ submitFlowFlag: A,
868
+ subFormHeight: Oe,
869
+ subTableHeight: Pe,
870
+ refMap: E,
871
+ triggleChangeValues: Ot,
872
+ triggleChangeValue: Pt,
873
+ sh: U,
874
+ clearSubRows: Re,
875
+ addSubRows: xe,
876
+ clearThenAddRows: Bt,
877
+ changeOptions: It,
878
+ isUpdate: _,
879
+ getSubTableInstance: k,
880
+ updateSchema: z,
881
+ executeMainFillRule: Xt,
882
+ executeSubFillRule: Zt,
883
+ // update-begin--author:liaozhiyang---date:20240313---for:【QQYUN-8350】js增强根据主表限制子表options
884
+ changeSubTableOptions: Lt,
885
+ changeSubFormbleOptions: Nt,
886
+ // update-end--author:liaozhiyang---date:20240313---for:【QQYUN-8350】js增强根据主表限制子表options
887
+ changeRemoteOptions: jt,
888
+ changEvent: () => {
889
+ },
890
+ onlineFormValueChange: bt,
891
+ // update-begin--author:liaozhiyang---date:20240705---for:【TV360X-1754】js增强-提交表单并且发起流程
892
+ submitFormAndFlow: vt
893
+ // update-end--author:liaozhiyang---date:20240705---for:【TV360X-1754】js增强-提交表单并且发起流程
894
+ };
895
+ return Ue(De), {
896
+ //主表
897
+ tableName: D,
898
+ onlineFormRef: x,
899
+ registerForm: lt,
900
+ loading: O,
901
+ //子表
902
+ subActiveKey: ne,
903
+ hasSubTable: Ge,
904
+ subTabInfo: T,
905
+ refMap: E,
906
+ //一对一子表
907
+ subFormHeight: Oe,
908
+ getSubTableForeignKeyValue: At,
909
+ isUpdate: _,
910
+ handleSubFormChange: Rt,
911
+ //一对多子表
912
+ subTableHeight: Pe,
913
+ onlineFormDisabled: ve,
914
+ subDataSource: ee,
915
+ getSubTableAuthPre: Ae,
916
+ handleAdded: Dt,
917
+ handleSubTableDefaultValue: Fe,
918
+ handleValueChange: xt,
919
+ openSubFormModalForAdd: Ht,
920
+ openSubFormModalForEdit: zt,
921
+ getBtnAuth: (e, t) => {
922
+ const n = Ae(t);
923
+ let o = Ln().getOnlineSubTableAuth(n);
924
+ return o != null && o.length ? !o.find((c) => c === e) : !0;
925
+ },
926
+ handleRemoved: Mt,
927
+ //父组件调用
928
+ show: rt,
929
+ createRootProperties: ht,
930
+ handleSubmit: Te,
931
+ handleValidate: Ft,
932
+ sh: U,
933
+ handleCgButtonClick: se,
934
+ handleCustomFormSh: Wt,
935
+ handleCustomFormEdit: Ut,
936
+ //跳转
937
+ dbData: V,
938
+ onOpenReportPrint: Yt,
939
+ onlineExtConfigJson: q,
940
+ onCompPrint: Kt,
941
+ printRef: a,
942
+ //一对多子表弹窗操作数据
943
+ registerPopModal: qt,
944
+ popTableId: ue,
945
+ popTableName: ce,
946
+ getPopFormData: Gt,
947
+ popModalRequest: fe,
948
+ onCloseModal: Qt,
949
+ ERP: ie,
950
+ rowNumber: p,
951
+ isSetFormLabelLength: Z,
952
+ subFormWrapRef: K,
953
+ getSubAddBtnCfg: Ye,
954
+ getSubRemoveBtnCfg: Ke,
955
+ getSubOpenAddBtnCfg: qe,
956
+ getSubOpenEditBtnCfg: He
957
+ };
958
+ }
959
+ }, Wn = ["id"], Un = { key: 1 };
960
+ function Yn(u, f, s, a, x, M) {
961
+ const O = B("BasicForm"), P = B("online-sub-form"), F = B("a-button"), A = B("JVxeTable"), _ = B("a-tab-pane"), j = B("a-tabs"), Z = B("Loading"), W = B("online-pop-modal");
962
+ return I(), le("div", {
963
+ ref: "printRef",
964
+ id: a.tableName + "_form",
965
+ class: cn(["onlineFormWrap", [`formTemplate_${s.formTemplate}`]])
966
+ }, [
967
+ G(O, {
968
+ ref: "onlineFormRef",
969
+ onRegister: a.registerForm,
970
+ name: "online-form_" + a.tableName
971
+ }, null, 8, ["onRegister", "name"]),
972
+ s.themeTemplate !== a.ERP && a.hasSubTable ? (I(), oe(j, {
973
+ key: 0,
974
+ activeKey: a.subActiveKey,
975
+ "onUpdate:activeKey": f[0] || (f[0] = (p) => a.subActiveKey = p)
976
+ }, {
977
+ default: Q(() => [
978
+ (I(!0), le(fn, null, dn(a.subTabInfo, (p, K) => (I(), oe(_, {
979
+ tab: p.describe,
980
+ key: K + "",
981
+ forceRender: !0
982
+ }, {
983
+ default: Q(() => [
984
+ p.relationType == 1 ? (I(), le("div", {
985
+ key: 0,
986
+ ref_for: !0,
987
+ ref: "subFormWrapRef",
988
+ style: mn({ "overflow-y": "auto", "overflow-x": "hidden", "max-height": a.subFormHeight + "px" })
989
+ }, [
990
+ G(P, {
991
+ ref_for: !0,
992
+ ref: a.refMap[p.key],
993
+ table: p.key,
994
+ disabled: a.onlineFormDisabled,
995
+ "form-template": s.formTemplate,
996
+ "main-id": a.getSubTableForeignKeyValue(p.foreignKey),
997
+ properties: p.properties,
998
+ "required-fields": p.requiredFields,
999
+ "is-update": a.isUpdate,
1000
+ onFormChange: (v) => a.handleSubFormChange(v, p.key)
1001
+ }, null, 8, ["table", "disabled", "form-template", "main-id", "properties", "required-fields", "is-update", "onFormChange"])
1002
+ ], 4)) : (I(), le("div", Un, [
1003
+ G(A, {
1004
+ ref_for: !0,
1005
+ ref: a.refMap[p.key],
1006
+ toolbar: "",
1007
+ "keep-source": "",
1008
+ "row-number": a.rowNumber,
1009
+ "row-selection": "",
1010
+ height: (
1011
+ // 【VUEN-803】一对多子表固定340高度,修复自定义列组件被遮挡的问题
1012
+ a.subTableHeight
1013
+ ),
1014
+ disabled: a.onlineFormDisabled,
1015
+ columns: p.columns,
1016
+ dataSource: a.subDataSource[p.key],
1017
+ addBtnCfg: a.getSubAddBtnCfg,
1018
+ removeBtnCfg: a.getSubRemoveBtnCfg,
1019
+ onValueChange: (v) => a.handleValueChange(v, p.key),
1020
+ onRemoved: (v) => a.handleRemoved(v, p.key),
1021
+ authPre: a.getSubTableAuthPre(p.key),
1022
+ onAdded: (v) => a.handleAdded(p, v),
1023
+ onExecuteFillRule: (v) => a.handleSubTableDefaultValue(p, v)
1024
+ }, {
1025
+ toolbarSuffix: Q(() => [
1026
+ !a.onlineFormDisabled && a.getSubOpenAddBtnCfg.enabled && a.getBtnAuth("add", p.key) ? (I(), oe(F, {
1027
+ key: 0,
1028
+ type: "primary",
1029
+ preIcon: a.getSubOpenAddBtnCfg.buttonIcon,
1030
+ onClick: (v) => a.openSubFormModalForAdd(p)
1031
+ }, {
1032
+ default: Q(() => [
1033
+ Ie("span", null, je(a.getSubOpenAddBtnCfg.buttonName), 1)
1034
+ ]),
1035
+ _: 2
1036
+ }, 1032, ["preIcon", "onClick"])) : me("", !0),
1037
+ !a.onlineFormDisabled && a.getSubOpenEditBtnCfg.enabled && a.getBtnAuth("update", p.key) ? (I(), oe(F, {
1038
+ key: 1,
1039
+ type: "primary",
1040
+ preIcon: a.getSubOpenEditBtnCfg.buttonIcon,
1041
+ onClick: (v) => a.openSubFormModalForEdit(p)
1042
+ }, {
1043
+ default: Q(() => [
1044
+ Ie("span", null, je(a.getSubOpenEditBtnCfg.buttonName), 1)
1045
+ ]),
1046
+ _: 2
1047
+ }, 1032, ["preIcon", "onClick"])) : me("", !0)
1048
+ ]),
1049
+ _: 2
1050
+ }, 1032, ["row-number", "height", "disabled", "columns", "dataSource", "addBtnCfg", "removeBtnCfg", "onValueChange", "onRemoved", "authPre", "onAdded", "onExecuteFillRule"])
1051
+ ]))
1052
+ ]),
1053
+ _: 2
1054
+ }, 1032, ["tab"]))), 128))
1055
+ ]),
1056
+ _: 1
1057
+ }, 8, ["activeKey"])) : me("", !0),
1058
+ G(Z, {
1059
+ loading: a.loading,
1060
+ absolute: !1
1061
+ }, null, 8, ["loading"]),
1062
+ pn(u.$slots, "bottom", {}, void 0, !0),
1063
+ G(W, {
1064
+ formTableType: "3",
1065
+ request: a.popModalRequest,
1066
+ id: a.popTableId,
1067
+ onRegister: a.registerPopModal,
1068
+ onSuccess: a.getPopFormData,
1069
+ taskId: s.taskId,
1070
+ tableName: a.popTableName,
1071
+ topTip: "",
1072
+ isVxeTableData: ""
1073
+ }, null, 8, ["request", "id", "onRegister", "onSuccess", "taskId", "tableName"])
1074
+ ], 10, Wn);
1075
+ }
1076
+ const Il = /* @__PURE__ */ Nn(Jn, [["render", Yn], ["__scopeId", "data-v-60bd1850"]]);
1077
+ export {
1078
+ Il as default
1079
+ };