@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,404 @@
|
|
|
1
|
+
var W = Object.defineProperty, G = Object.defineProperties;
|
|
2
|
+
var U = Object.getOwnPropertyDescriptors;
|
|
3
|
+
var R = Object.getOwnPropertySymbols;
|
|
4
|
+
var X = Object.prototype.hasOwnProperty, Y = Object.prototype.propertyIsEnumerable;
|
|
5
|
+
var E = (t, s, n) => s in t ? W(t, s, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[s] = n, N = (t, s) => {
|
|
6
|
+
for (var n in s || (s = {}))
|
|
7
|
+
X.call(s, n) && E(t, n, s[n]);
|
|
8
|
+
if (R)
|
|
9
|
+
for (var n of R(s))
|
|
10
|
+
Y.call(s, n) && E(t, n, s[n]);
|
|
11
|
+
return t;
|
|
12
|
+
}, $ = (t, s) => G(t, U(s));
|
|
13
|
+
import { defineComponent as Z, ref as ee, resolveComponent as y, openBlock as H, createElementBlock as te, Fragment as le, createVNode as w, mergeProps as ie, withCtx as K, createBlock as ae, createTextVNode as oe, createCommentVNode as de } from "vue";
|
|
14
|
+
import { JVxeTypes as r } from "/@/components/jeecg/JVxeTable/types";
|
|
15
|
+
import { u as ne } from "./useTableSync-774c3774.mjs";
|
|
16
|
+
import se from "./LinkTableConfigModal-c2c5c7e6.mjs";
|
|
17
|
+
import ue from "./LinkTableFieldConfigModal-a3553b1f.mjs";
|
|
18
|
+
import re from "./FieldExtendJsonModal-adfcf5a7.mjs";
|
|
19
|
+
import { useModal as V } from "/@/components/Modal";
|
|
20
|
+
import { _ as fe } from "./index-b70302f2.mjs";
|
|
21
|
+
import "./cgform.data-cbdd88c3.mjs";
|
|
22
|
+
import "/@/utils/dict";
|
|
23
|
+
import "/@/utils/dict/JDictSelectUtil";
|
|
24
|
+
import "/@/utils/uuid";
|
|
25
|
+
import "lodash-es";
|
|
26
|
+
import "/@/components/Form/index";
|
|
27
|
+
import "/@/utils/http/axios";
|
|
28
|
+
import "/@/hooks/web/useMessage";
|
|
29
|
+
import "./constant-754f1a9d.mjs";
|
|
30
|
+
import "/@/components/jeecg/OnLine/JPopupOnlReport.vue";
|
|
31
|
+
import "vue-router";
|
|
32
|
+
const P = [
|
|
33
|
+
{ title: "文本框", value: "text" },
|
|
34
|
+
{ title: "密码", value: "password" },
|
|
35
|
+
{ title: "下拉框", value: "list" },
|
|
36
|
+
{ title: "单选框", value: "radio" },
|
|
37
|
+
{ title: "多选框", value: "checkbox" },
|
|
38
|
+
{ title: "开关", value: "switch" },
|
|
39
|
+
{ title: "日期(年月日)", value: "date" },
|
|
40
|
+
{ title: "日期(年月日时分秒)", value: "datetime" },
|
|
41
|
+
{ title: "时间(HH:mm:ss)", value: "time" },
|
|
42
|
+
{ title: "文件", value: "file" },
|
|
43
|
+
{ title: "图片", value: "image" },
|
|
44
|
+
{ title: "多行文本", value: "textarea" },
|
|
45
|
+
{ title: "富文本", value: "umeditor" },
|
|
46
|
+
{ title: "MarkDown", value: "markdown" },
|
|
47
|
+
{ title: "用户选择", value: "sel_user" },
|
|
48
|
+
{ title: "部门选择", value: "sel_depart" },
|
|
49
|
+
{ title: "关联记录", value: "link_table" },
|
|
50
|
+
{ title: "他表字段", value: "link_table_field" },
|
|
51
|
+
{ title: "省市区组件", value: "pca" },
|
|
52
|
+
{ title: "Popup弹框", value: "popup" },
|
|
53
|
+
{ title: "下拉多选框", value: "list_multi" },
|
|
54
|
+
{ title: "下拉搜索框", value: "sel_search" },
|
|
55
|
+
{ title: "分类字典树", value: "cat_tree" },
|
|
56
|
+
{ title: "自定义树控件", value: "sel_tree" },
|
|
57
|
+
{ title: "联动组件", value: "link_down" }
|
|
58
|
+
], ce = [
|
|
59
|
+
{ title: "文本框", value: "text" },
|
|
60
|
+
{ title: "单选框", value: "radio" },
|
|
61
|
+
{ title: "开关", value: "switch" },
|
|
62
|
+
{ title: "日期(yyyy-MM-dd)", value: "date" },
|
|
63
|
+
{ title: "日期(yyyy-MM-dd HH:mm:ss)", value: "datetime" },
|
|
64
|
+
{ title: "时间(HH:mm:ss)", value: "time" },
|
|
65
|
+
{ title: "文件", value: "file" },
|
|
66
|
+
{ title: "图片", value: "image" },
|
|
67
|
+
{ title: "下拉框", value: "list" },
|
|
68
|
+
{ title: "下拉多选框", value: "list_multi" },
|
|
69
|
+
{ title: "下拉搜索框", value: "sel_search" },
|
|
70
|
+
{ title: "popup弹出框", value: "popup" },
|
|
71
|
+
{ title: "部门选择", value: "sel_depart" },
|
|
72
|
+
{ title: "用户选择", value: "sel_user" },
|
|
73
|
+
{ title: "省市区组件", value: "pca" },
|
|
74
|
+
{ title: "多行文本", value: "textarea" }
|
|
75
|
+
], me = Z({
|
|
76
|
+
name: "PageAttributeTable",
|
|
77
|
+
components: {
|
|
78
|
+
LinkTableConfigModal: se,
|
|
79
|
+
LinkTableFieldConfigModal: ue,
|
|
80
|
+
FieldExtendJsonModal: re
|
|
81
|
+
},
|
|
82
|
+
setup() {
|
|
83
|
+
const t = ee([
|
|
84
|
+
{ title: "字段名称", key: "dbFieldName", width: 100 },
|
|
85
|
+
{ title: "字段备注", key: "dbFieldTxt", width: 150 },
|
|
86
|
+
{
|
|
87
|
+
title: "表单显示",
|
|
88
|
+
key: "isShowForm",
|
|
89
|
+
width: 80,
|
|
90
|
+
type: r.checkbox,
|
|
91
|
+
align: "center",
|
|
92
|
+
customValue: ["1", "0"],
|
|
93
|
+
defaultChecked: !0
|
|
94
|
+
},
|
|
95
|
+
{
|
|
96
|
+
title: "列表显示",
|
|
97
|
+
key: "isShowList",
|
|
98
|
+
width: 80,
|
|
99
|
+
type: r.checkbox,
|
|
100
|
+
align: "center",
|
|
101
|
+
customValue: ["1", "0"],
|
|
102
|
+
defaultChecked: !0
|
|
103
|
+
},
|
|
104
|
+
{
|
|
105
|
+
title: "是否排序",
|
|
106
|
+
key: "sortFlag",
|
|
107
|
+
width: 80,
|
|
108
|
+
type: r.checkbox,
|
|
109
|
+
align: "center",
|
|
110
|
+
customValue: ["1", "0"],
|
|
111
|
+
defaultChecked: !1
|
|
112
|
+
},
|
|
113
|
+
{
|
|
114
|
+
title: "是否只读",
|
|
115
|
+
key: "isReadOnly",
|
|
116
|
+
width: 80,
|
|
117
|
+
type: r.checkbox,
|
|
118
|
+
align: "center",
|
|
119
|
+
customValue: ["1", "0"],
|
|
120
|
+
defaultChecked: !1
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
title: "控件类型",
|
|
124
|
+
key: "fieldShowType",
|
|
125
|
+
width: 170,
|
|
126
|
+
type: r.select,
|
|
127
|
+
options: P,
|
|
128
|
+
defaultValue: "text",
|
|
129
|
+
placeholder: "请选择${title}",
|
|
130
|
+
validateRules: [{ required: !0, message: "请选择${title}" }, { handler: C }]
|
|
131
|
+
},
|
|
132
|
+
{
|
|
133
|
+
title: "控件长度",
|
|
134
|
+
key: "fieldLength",
|
|
135
|
+
width: 120,
|
|
136
|
+
titleHelp: { message: "此长度只对子表列字段宽度有效!" },
|
|
137
|
+
type: r.inputNumber,
|
|
138
|
+
defaultValue: 200,
|
|
139
|
+
placeholder: "请输入${title}",
|
|
140
|
+
validateRules: [{ required: !0, message: "${title}不能为空" }]
|
|
141
|
+
},
|
|
142
|
+
{
|
|
143
|
+
title: "是否查询",
|
|
144
|
+
key: "isQuery",
|
|
145
|
+
width: 80,
|
|
146
|
+
type: r.checkbox,
|
|
147
|
+
align: "center",
|
|
148
|
+
customValue: ["1", "0"],
|
|
149
|
+
defaultChecked: !1
|
|
150
|
+
},
|
|
151
|
+
{
|
|
152
|
+
title: "查询类型",
|
|
153
|
+
key: "queryMode",
|
|
154
|
+
width: 110,
|
|
155
|
+
type: r.select,
|
|
156
|
+
options: [
|
|
157
|
+
{ title: "普通查询", value: "single" },
|
|
158
|
+
{ title: "范围查询", value: "group" }
|
|
159
|
+
],
|
|
160
|
+
defaultValue: "single",
|
|
161
|
+
placeholder: "请选择${title}",
|
|
162
|
+
validateRules: [{ required: !0, message: "请选择${title}" }]
|
|
163
|
+
},
|
|
164
|
+
{
|
|
165
|
+
title: "控件默认值",
|
|
166
|
+
key: "fieldDefaultValue",
|
|
167
|
+
width: 120,
|
|
168
|
+
type: r.input,
|
|
169
|
+
defaultValue: ""
|
|
170
|
+
},
|
|
171
|
+
{
|
|
172
|
+
title: "定义转换器",
|
|
173
|
+
key: "converter",
|
|
174
|
+
width: 150,
|
|
175
|
+
type: r.input,
|
|
176
|
+
defaultValue: ""
|
|
177
|
+
},
|
|
178
|
+
{
|
|
179
|
+
title: "扩展参数",
|
|
180
|
+
key: "fieldExtendJson",
|
|
181
|
+
width: 120,
|
|
182
|
+
type: r.input,
|
|
183
|
+
defaultValue: ""
|
|
184
|
+
},
|
|
185
|
+
{
|
|
186
|
+
title: "更多配置",
|
|
187
|
+
minWidth: 100,
|
|
188
|
+
key: "fieldConfig",
|
|
189
|
+
type: r.slot,
|
|
190
|
+
slotName: "fieldConfig"
|
|
191
|
+
}
|
|
192
|
+
]), s = ne(t), { tableRef: n, tables: p } = s;
|
|
193
|
+
function C({ cellValue: e, row: l }, a) {
|
|
194
|
+
let { dbTable: u } = p, i = u.value.tableRef.getTableData({ rowIds: [l.id] })[0].dbType;
|
|
195
|
+
e === "time" && i !== "string" ? a(!1, "当控件类型为时间时,数据库属性里的字段类型必须是String!") : e === "date" && i !== "Date" && i !== "Datetime" ? a(!1, "当控件类型为日期时,数据库属性里的字段类型必须是Date或Datetime!") : e === "datetime" && i !== "Datetime" ? a(!1, "当控件类型为datetime时,数据库属性里的字段类型必须是Datetime!") : a(!0);
|
|
196
|
+
}
|
|
197
|
+
function D(e) {
|
|
198
|
+
let l = "date";
|
|
199
|
+
e.dbType === "Datetime" && (l = "datetime"), n.value.setValues([
|
|
200
|
+
{
|
|
201
|
+
rowKey: e.id,
|
|
202
|
+
values: { fieldShowType: l }
|
|
203
|
+
}
|
|
204
|
+
]);
|
|
205
|
+
}
|
|
206
|
+
function k(e) {
|
|
207
|
+
for (let l of t.value)
|
|
208
|
+
if (l.key == "fieldShowType") {
|
|
209
|
+
l.options = e ? ce : P;
|
|
210
|
+
break;
|
|
211
|
+
}
|
|
212
|
+
}
|
|
213
|
+
function F(e) {
|
|
214
|
+
n.value.setValues([
|
|
215
|
+
{
|
|
216
|
+
rowKey: e,
|
|
217
|
+
values: { isQuery: "1" }
|
|
218
|
+
}
|
|
219
|
+
]);
|
|
220
|
+
}
|
|
221
|
+
const [_, { openModal: x }] = V(), [S, { openModal: v }] = V(), [M, { openModal: O }] = V();
|
|
222
|
+
function A(e) {
|
|
223
|
+
return e.row.dbFieldName != "id";
|
|
224
|
+
}
|
|
225
|
+
function L(e) {
|
|
226
|
+
e.row.fieldShowType.indexOf("link_table") >= 0 ? J(e) : Q(e);
|
|
227
|
+
}
|
|
228
|
+
function J(e) {
|
|
229
|
+
let { row: l } = e, { checkTable: a } = p;
|
|
230
|
+
if (a) {
|
|
231
|
+
let u = a.value.tableRef.getTableData({ rowIds: [l.id] })[0];
|
|
232
|
+
if (e.row.fieldShowType == "link_table") {
|
|
233
|
+
let i = I(l, u);
|
|
234
|
+
x(!0, {
|
|
235
|
+
record: i,
|
|
236
|
+
fieldName: l.dbFieldName
|
|
237
|
+
});
|
|
238
|
+
} else if (e.row.fieldShowType == "link_table_field") {
|
|
239
|
+
let i = B(l, u);
|
|
240
|
+
v(!0, i);
|
|
241
|
+
}
|
|
242
|
+
}
|
|
243
|
+
}
|
|
244
|
+
function B(e, l) {
|
|
245
|
+
let u = n.value.getTableData().filter((g) => g.fieldShowType == "link_table"), i = {};
|
|
246
|
+
if (u && u.length > 0) {
|
|
247
|
+
let g = p.checkTable.value.tableRef.getTableData();
|
|
248
|
+
for (let T of u) {
|
|
249
|
+
let h = g.filter((m) => m.dbFieldName == T.dbFieldName);
|
|
250
|
+
if (h && h.length > 0) {
|
|
251
|
+
let m = h[0];
|
|
252
|
+
i[m.dbFieldName] = {
|
|
253
|
+
title: T.dbFieldTxt,
|
|
254
|
+
table: m.dictTable,
|
|
255
|
+
fields: m.dictText
|
|
256
|
+
};
|
|
257
|
+
}
|
|
258
|
+
}
|
|
259
|
+
}
|
|
260
|
+
const { dictTable: c, dictText: f } = l, { id: o, dbFieldTxt: d } = e;
|
|
261
|
+
return {
|
|
262
|
+
record: {
|
|
263
|
+
rowKey: o,
|
|
264
|
+
dbFieldTxt: d,
|
|
265
|
+
dictText: f,
|
|
266
|
+
dictTable: c
|
|
267
|
+
},
|
|
268
|
+
tableAndFieldsMap: i
|
|
269
|
+
};
|
|
270
|
+
}
|
|
271
|
+
function I(e, l) {
|
|
272
|
+
const { id: a, dbFieldTxt: u, fieldExtendJson: i } = e, { dictTable: c, dictText: f } = l;
|
|
273
|
+
let o = {
|
|
274
|
+
rowKey: a,
|
|
275
|
+
dbFieldTxt: u,
|
|
276
|
+
dictTable: c
|
|
277
|
+
};
|
|
278
|
+
if (f) {
|
|
279
|
+
let d = f.split(",");
|
|
280
|
+
o.titleField = d[0], d.length > 1 && (o.otherFields = f.substring(f.indexOf(",") + 1));
|
|
281
|
+
} else
|
|
282
|
+
o.titleField = "", o.otherFields = "";
|
|
283
|
+
if (i)
|
|
284
|
+
try {
|
|
285
|
+
let d = JSON.parse(i);
|
|
286
|
+
d.multiSelect ? o.multiSelect = d.multiSelect : o.multiSelect = !1, d.showType ? o.showType = d.showType : o.showType = "card", d.imageField ? o.imageField = d.imageField : o.imageField = "";
|
|
287
|
+
} catch (d) {
|
|
288
|
+
}
|
|
289
|
+
return o;
|
|
290
|
+
}
|
|
291
|
+
function q(e) {
|
|
292
|
+
const { multiSelect: l, showType: a, imageField: u, fieldName: i } = e;
|
|
293
|
+
let c = { showType: a, multiSelect: l, imageField: u }, f = [{ rowKey: e.rowKey, values: { fieldExtendJson: JSON.stringify(c), dbFieldTxt: e.dbFieldTxt } }];
|
|
294
|
+
n.value.setValues(f);
|
|
295
|
+
let { checkTable: o, dbTable: d } = p;
|
|
296
|
+
if (d) {
|
|
297
|
+
let b = [{ rowKey: e.rowKey, values: { dbFieldTxt: e.dbFieldTxt } }];
|
|
298
|
+
d.value.tableRef.setValues(b);
|
|
299
|
+
}
|
|
300
|
+
if (o) {
|
|
301
|
+
let b = e.titleField;
|
|
302
|
+
e.otherFields && (b += "," + e.otherFields);
|
|
303
|
+
const { dictTable: g, dictField: T } = e;
|
|
304
|
+
let h = {
|
|
305
|
+
dictTable: g,
|
|
306
|
+
dictField: T,
|
|
307
|
+
dictText: b,
|
|
308
|
+
dbFieldName: i
|
|
309
|
+
}, m = [{ rowKey: e.rowKey, values: h }];
|
|
310
|
+
o.value.tableRef.setValues(m);
|
|
311
|
+
}
|
|
312
|
+
}
|
|
313
|
+
function j(e) {
|
|
314
|
+
const { dbFieldTxt: l, dictTable: a, dictText: u, rowKey: i } = e;
|
|
315
|
+
let c = [{ rowKey: i, values: { dbFieldTxt: l } }];
|
|
316
|
+
n.value.setValues(c);
|
|
317
|
+
let { checkTable: f, dbTable: o } = p;
|
|
318
|
+
if (o) {
|
|
319
|
+
let d = [{ rowKey: i, values: { dbFieldTxt: l, dbIsPersist: "0" } }];
|
|
320
|
+
o.value.tableRef.setValues(d);
|
|
321
|
+
}
|
|
322
|
+
if (f) {
|
|
323
|
+
let d = [{ rowKey: i, values: { dictTable: a, dictText: u } }];
|
|
324
|
+
f.value.tableRef.setValues(d);
|
|
325
|
+
}
|
|
326
|
+
}
|
|
327
|
+
function Q(e) {
|
|
328
|
+
let l = e.row.fieldExtendJson || "", a = e.rowId, u = e.row.fieldShowType || "", i = e.row.sortFlag || "0";
|
|
329
|
+
O(!0, {
|
|
330
|
+
jsonStr: l,
|
|
331
|
+
fieldShowType: u,
|
|
332
|
+
sortFlag: i,
|
|
333
|
+
id: a
|
|
334
|
+
});
|
|
335
|
+
}
|
|
336
|
+
function z(e, l) {
|
|
337
|
+
let a;
|
|
338
|
+
e && Object.keys(e).length > 0 ? a = [{ rowKey: l, values: { fieldExtendJson: JSON.stringify(e) } }] : a = [{ rowKey: l, values: { fieldExtendJson: "" } }], n.value.setValues(a);
|
|
339
|
+
}
|
|
340
|
+
return $(N({}, s), {
|
|
341
|
+
columns: t,
|
|
342
|
+
enableQuery: F,
|
|
343
|
+
syncFieldShowType: D,
|
|
344
|
+
changePageType: k,
|
|
345
|
+
showConfigButton: A,
|
|
346
|
+
showFieldConfig: J,
|
|
347
|
+
registerExtJsonModal: M,
|
|
348
|
+
handleExtJson: z,
|
|
349
|
+
openConfig: L,
|
|
350
|
+
registerModal: _,
|
|
351
|
+
handleConfigData: q,
|
|
352
|
+
registerFieldModal: S,
|
|
353
|
+
handleFieldConfigData: j
|
|
354
|
+
});
|
|
355
|
+
}
|
|
356
|
+
});
|
|
357
|
+
function pe(t, s, n, p, C, D) {
|
|
358
|
+
const k = y("a-button"), F = y("JVxeTable"), _ = y("link-table-config-modal"), x = y("link-table-field-config-modal"), S = y("FieldExtendJsonModal");
|
|
359
|
+
return H(), te(le, null, [
|
|
360
|
+
w(F, ie({
|
|
361
|
+
ref: "tableRef",
|
|
362
|
+
"row-class-name": "online-config-page",
|
|
363
|
+
rowNumber: "",
|
|
364
|
+
keyboardEdit: "",
|
|
365
|
+
maxHeight: t.tableHeight.noToolbar,
|
|
366
|
+
loading: t.loading,
|
|
367
|
+
columns: t.columns,
|
|
368
|
+
dataSource: t.dataSource,
|
|
369
|
+
disabledRows: { dbFieldName: ["id", "has_child"] }
|
|
370
|
+
}, t.tableProps), {
|
|
371
|
+
fieldConfig: K((v) => [
|
|
372
|
+
t.showConfigButton(v) ? (H(), ae(k, {
|
|
373
|
+
key: 0,
|
|
374
|
+
type: "primary",
|
|
375
|
+
size: "small",
|
|
376
|
+
ghost: "",
|
|
377
|
+
onClick: (M) => t.openConfig(v)
|
|
378
|
+
}, {
|
|
379
|
+
default: K(() => [
|
|
380
|
+
oe("高级配置")
|
|
381
|
+
]),
|
|
382
|
+
_: 2
|
|
383
|
+
}, 1032, ["onClick"])) : de("", !0)
|
|
384
|
+
]),
|
|
385
|
+
_: 1
|
|
386
|
+
}, 16, ["maxHeight", "loading", "columns", "dataSource"]),
|
|
387
|
+
w(_, {
|
|
388
|
+
onRegister: t.registerModal,
|
|
389
|
+
onSuccess: t.handleConfigData
|
|
390
|
+
}, null, 8, ["onRegister", "onSuccess"]),
|
|
391
|
+
w(x, {
|
|
392
|
+
onRegister: t.registerFieldModal,
|
|
393
|
+
onSuccess: t.handleFieldConfigData
|
|
394
|
+
}, null, 8, ["onRegister", "onSuccess"]),
|
|
395
|
+
w(S, {
|
|
396
|
+
onRegister: t.registerExtJsonModal,
|
|
397
|
+
onSuccess: t.handleExtJson
|
|
398
|
+
}, null, 8, ["onRegister", "onSuccess"])
|
|
399
|
+
], 64);
|
|
400
|
+
}
|
|
401
|
+
const $e = /* @__PURE__ */ fe(me, [["render", pe], ["__scopeId", "data-v-08ae6456"]]);
|
|
402
|
+
export {
|
|
403
|
+
$e as default
|
|
404
|
+
};
|
|
@@ -0,0 +1,177 @@
|
|
|
1
|
+
var u = (e, r, o) => new Promise((p, s) => {
|
|
2
|
+
var l = (t) => {
|
|
3
|
+
try {
|
|
4
|
+
i(o.next(t));
|
|
5
|
+
} catch (a) {
|
|
6
|
+
s(a);
|
|
7
|
+
}
|
|
8
|
+
}, n = (t) => {
|
|
9
|
+
try {
|
|
10
|
+
i(o.throw(t));
|
|
11
|
+
} catch (a) {
|
|
12
|
+
s(a);
|
|
13
|
+
}
|
|
14
|
+
}, i = (t) => t.done ? p(t.value) : Promise.resolve(t.value).then(l, n);
|
|
15
|
+
i((o = o.apply(e, r)).next());
|
|
16
|
+
});
|
|
17
|
+
import S from "./OnlineForm-069f6092.mjs";
|
|
18
|
+
import { defineComponent as k, ref as m, watch as T, nextTick as w, resolveComponent as f, openBlock as h, createElementBlock as y, createVNode as _, withCtx as g, createTextVNode as N, createCommentVNode as C } from "vue";
|
|
19
|
+
import { defHttp as P } from "/@/utils/http/axios";
|
|
20
|
+
import { g as b } from "./useExtendComponent-aa1cdfc8.mjs";
|
|
21
|
+
import { _ as R } from "./index-b70302f2.mjs";
|
|
22
|
+
import "/@/hooks/web/useMessage";
|
|
23
|
+
import "/@/components/Form/index";
|
|
24
|
+
import "lodash-es";
|
|
25
|
+
import "/@/utils";
|
|
26
|
+
import "/@/components/Loading";
|
|
27
|
+
import "/@/components/jeecg/JVxeTable/types";
|
|
28
|
+
import "/@/utils/auth";
|
|
29
|
+
import "@ant-design/icons-vue";
|
|
30
|
+
import "/@/hooks/core/useContext";
|
|
31
|
+
import "/@/utils/mitt";
|
|
32
|
+
import "/@/components/Modal";
|
|
33
|
+
import "./useCustomHook-acb00837.mjs";
|
|
34
|
+
import "/@/utils/cache";
|
|
35
|
+
import "/@/utils/common/compUtils";
|
|
36
|
+
import "/@/store/modules/user";
|
|
37
|
+
import "./constant-754f1a9d.mjs";
|
|
38
|
+
import "/@/components/Form/src/componentMap";
|
|
39
|
+
import "/@/utils/propTypes";
|
|
40
|
+
import "/@/components/Form/src/jeecg/components/JUpload";
|
|
41
|
+
import "/@/views/system/user/user.api";
|
|
42
|
+
import "/@/utils/desform/customExpression";
|
|
43
|
+
import "/@/store/modules/permission";
|
|
44
|
+
import "/@/utils/dict/JDictSelectUtil";
|
|
45
|
+
import "/@/components/Table";
|
|
46
|
+
import "/@/hooks/system/useListPage";
|
|
47
|
+
import "vue-router";
|
|
48
|
+
import "/@/components/Form/src/utils/Area";
|
|
49
|
+
import "/@/components/Preview/index";
|
|
50
|
+
import "./LinkTableListPiece-7f793b08.mjs";
|
|
51
|
+
import "./OnlineSelectCascade-a05c30f4.mjs";
|
|
52
|
+
import "./JModalTip-e1938b49.mjs";
|
|
53
|
+
import "ant-design-vue";
|
|
54
|
+
import "@vueuse/core";
|
|
55
|
+
import "/@/components/jeecg/OnLine/JPopupOnlReport.vue";
|
|
56
|
+
const L = k({
|
|
57
|
+
name: "ProcessOnlineForm",
|
|
58
|
+
inheritAttrs: !1,
|
|
59
|
+
components: {
|
|
60
|
+
OnlineForm: S
|
|
61
|
+
},
|
|
62
|
+
props: {
|
|
63
|
+
dataId: {
|
|
64
|
+
type: String,
|
|
65
|
+
default: ""
|
|
66
|
+
},
|
|
67
|
+
tableName: {
|
|
68
|
+
type: String,
|
|
69
|
+
default: ""
|
|
70
|
+
},
|
|
71
|
+
taskId: {
|
|
72
|
+
type: String,
|
|
73
|
+
default: ""
|
|
74
|
+
},
|
|
75
|
+
disabled: {
|
|
76
|
+
type: Boolean,
|
|
77
|
+
default: !1
|
|
78
|
+
}
|
|
79
|
+
},
|
|
80
|
+
setup(e) {
|
|
81
|
+
const r = m(), o = m(""), p = m(1), s = m(!1), l = m(""), n = m(!1);
|
|
82
|
+
T(
|
|
83
|
+
() => e.tableName,
|
|
84
|
+
(c) => {
|
|
85
|
+
c && i();
|
|
86
|
+
},
|
|
87
|
+
{ immediate: !0 }
|
|
88
|
+
);
|
|
89
|
+
function i() {
|
|
90
|
+
return u(this, null, function* () {
|
|
91
|
+
n.value = !0;
|
|
92
|
+
const c = `/online/cgform/api/getFormItemBytbname/${e.tableName}`, I = { taskId: e.taskId };
|
|
93
|
+
try {
|
|
94
|
+
let d = yield P.get({ url: c, params: I });
|
|
95
|
+
o.value = d.head.id, p.value = Number(d.head.formTemplate || 1), s.value = d.head.isTree === "Y", l.value = d.head.treeParentIdField || "", yield w(() => u(this, null, function* () {
|
|
96
|
+
(yield b(r)).createRootProperties(d);
|
|
97
|
+
}));
|
|
98
|
+
} catch (d) {
|
|
99
|
+
}
|
|
100
|
+
});
|
|
101
|
+
}
|
|
102
|
+
function t() {
|
|
103
|
+
return u(this, null, function* () {
|
|
104
|
+
let c = yield b(r);
|
|
105
|
+
n.value = !1, c.show(!0, {
|
|
106
|
+
id: e.dataId
|
|
107
|
+
});
|
|
108
|
+
});
|
|
109
|
+
}
|
|
110
|
+
const a = m(!1);
|
|
111
|
+
function F() {
|
|
112
|
+
return u(this, null, function* () {
|
|
113
|
+
a.value = !0, r.value.handleSubmit();
|
|
114
|
+
});
|
|
115
|
+
}
|
|
116
|
+
function v() {
|
|
117
|
+
a.value = !1;
|
|
118
|
+
}
|
|
119
|
+
return {
|
|
120
|
+
onlineFormCompRef: r,
|
|
121
|
+
formId: o,
|
|
122
|
+
formTemplate: p,
|
|
123
|
+
isTreeForm: s,
|
|
124
|
+
pidFieldName: l,
|
|
125
|
+
renderSuccess: t,
|
|
126
|
+
handleSuccess: v,
|
|
127
|
+
handleSubmit: F,
|
|
128
|
+
buttonLoading: a,
|
|
129
|
+
spinLoading: n
|
|
130
|
+
};
|
|
131
|
+
}
|
|
132
|
+
}), $ = { class: "cust-onl-form" }, B = {
|
|
133
|
+
key: 0,
|
|
134
|
+
style: { width: "100%", "text-align": "center", "margin-top": "5px" }
|
|
135
|
+
};
|
|
136
|
+
function O(e, r, o, p, s, l) {
|
|
137
|
+
const n = f("a-button"), i = f("online-form"), t = f("a-spin");
|
|
138
|
+
return h(), y("div", $, [
|
|
139
|
+
_(t, { spinning: e.spinLoading }, {
|
|
140
|
+
default: g(() => [
|
|
141
|
+
_(i, {
|
|
142
|
+
ref: "onlineFormCompRef",
|
|
143
|
+
id: e.formId,
|
|
144
|
+
disabled: e.disabled,
|
|
145
|
+
"form-template": e.formTemplate,
|
|
146
|
+
isTree: e.isTreeForm,
|
|
147
|
+
pidField: e.pidFieldName,
|
|
148
|
+
onRendered: e.renderSuccess,
|
|
149
|
+
onSuccess: e.handleSuccess
|
|
150
|
+
}, {
|
|
151
|
+
bottom: g(() => [
|
|
152
|
+
!e.disabled && !e.spinLoading ? (h(), y("div", B, [
|
|
153
|
+
_(n, {
|
|
154
|
+
preIcon: "ant-design:check",
|
|
155
|
+
style: { width: "126px" },
|
|
156
|
+
type: "primary",
|
|
157
|
+
onClick: e.handleSubmit,
|
|
158
|
+
loading: e.buttonLoading
|
|
159
|
+
}, {
|
|
160
|
+
default: g(() => [
|
|
161
|
+
N(" 提 交 ")
|
|
162
|
+
]),
|
|
163
|
+
_: 1
|
|
164
|
+
}, 8, ["onClick", "loading"])
|
|
165
|
+
])) : C("", !0)
|
|
166
|
+
]),
|
|
167
|
+
_: 1
|
|
168
|
+
}, 8, ["id", "disabled", "form-template", "isTree", "pidField", "onRendered", "onSuccess"])
|
|
169
|
+
]),
|
|
170
|
+
_: 1
|
|
171
|
+
}, 8, ["spinning"])
|
|
172
|
+
]);
|
|
173
|
+
}
|
|
174
|
+
const Ie = /* @__PURE__ */ R(L, [["render", O], ["__scopeId", "data-v-530d8f91"]]);
|
|
175
|
+
export {
|
|
176
|
+
Ie as default
|
|
177
|
+
};
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
var y = Object.defineProperty, c = Object.defineProperties;
|
|
2
|
+
var f = Object.getOwnPropertyDescriptors;
|
|
3
|
+
var d = Object.getOwnPropertySymbols;
|
|
4
|
+
var h = Object.prototype.hasOwnProperty, b = Object.prototype.propertyIsEnumerable;
|
|
5
|
+
var n = (e, t, l) => t in e ? y(e, t, { enumerable: !0, configurable: !0, writable: !0, value: l }) : e[t] = l, p = (e, t) => {
|
|
6
|
+
for (var l in t || (t = {}))
|
|
7
|
+
h.call(t, l) && n(e, l, t[l]);
|
|
8
|
+
if (d)
|
|
9
|
+
for (var l of d(t))
|
|
10
|
+
b.call(t, l) && n(e, l, t[l]);
|
|
11
|
+
return e;
|
|
12
|
+
}, s = (e, t) => c(e, f(t));
|
|
13
|
+
import { defineComponent as g, ref as k, resolveComponent as v, openBlock as T, createBlock as _, mergeProps as V } from "vue";
|
|
14
|
+
import { JVxeTypes as a } from "/@/components/jeecg/JVxeTable/types";
|
|
15
|
+
import { u as w } from "./useTableSync-774c3774.mjs";
|
|
16
|
+
import { _ as C } from "./index-b70302f2.mjs";
|
|
17
|
+
import "./cgform.data-cbdd88c3.mjs";
|
|
18
|
+
import "/@/utils/dict";
|
|
19
|
+
import "/@/utils/dict/JDictSelectUtil";
|
|
20
|
+
import "/@/utils/uuid";
|
|
21
|
+
import "lodash-es";
|
|
22
|
+
import "/@/components/jeecg/OnLine/JPopupOnlReport.vue";
|
|
23
|
+
import "/@/hooks/web/useMessage";
|
|
24
|
+
import "vue-router";
|
|
25
|
+
const q = g({
|
|
26
|
+
name: "QueryTable",
|
|
27
|
+
emits: ["query"],
|
|
28
|
+
setup(e, { emit: t }) {
|
|
29
|
+
const l = k([
|
|
30
|
+
{ title: "字段名称", key: "dbFieldName", width: 130 },
|
|
31
|
+
{ title: "字段备注", key: "dbFieldTxt", width: 130 },
|
|
32
|
+
{
|
|
33
|
+
title: "控件类型",
|
|
34
|
+
key: "queryShowType",
|
|
35
|
+
width: 170,
|
|
36
|
+
type: a.select,
|
|
37
|
+
options: [
|
|
38
|
+
{ title: "文本框", value: "text" },
|
|
39
|
+
{ title: "日期(yyyy-MM-dd)", value: "date" },
|
|
40
|
+
{ title: "日期(yyyy-MM-dd HH:mm:ss)", value: "datetime" },
|
|
41
|
+
{ title: "时间(HH:mm:ss)", value: "time" },
|
|
42
|
+
{ title: "下拉框", value: "list" },
|
|
43
|
+
{ title: "下拉多选框", value: "list_multi" },
|
|
44
|
+
{ title: "下拉搜索框", value: "sel_search" },
|
|
45
|
+
{ title: "分类字典树", value: "cat_tree" },
|
|
46
|
+
{ title: "Popup弹框", value: "popup" },
|
|
47
|
+
{ title: "部门选择", value: "sel_depart" },
|
|
48
|
+
{ title: "用户选择", value: "sel_user" },
|
|
49
|
+
{ title: "省市区组件", value: "pca" },
|
|
50
|
+
{ title: "自定义树控件", value: "sel_tree" }
|
|
51
|
+
],
|
|
52
|
+
defaultValue: "text",
|
|
53
|
+
placeholder: "请选择${title}"
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
title: "字典Table",
|
|
57
|
+
key: "queryDictTable",
|
|
58
|
+
width: 130,
|
|
59
|
+
type: a.textarea,
|
|
60
|
+
defaultValue: ""
|
|
61
|
+
},
|
|
62
|
+
{
|
|
63
|
+
title: "字典Code",
|
|
64
|
+
key: "queryDictField",
|
|
65
|
+
width: 130,
|
|
66
|
+
type: a.input,
|
|
67
|
+
defaultValue: ""
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
title: "字典Text",
|
|
71
|
+
key: "queryDictText",
|
|
72
|
+
width: 130,
|
|
73
|
+
type: a.input,
|
|
74
|
+
defaultValue: ""
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
title: "默认值",
|
|
78
|
+
key: "queryDefVal",
|
|
79
|
+
width: 130,
|
|
80
|
+
type: a.input,
|
|
81
|
+
defaultValue: ""
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
title: "是否启用",
|
|
85
|
+
key: "queryConfigFlag",
|
|
86
|
+
minWidth: 80,
|
|
87
|
+
type: a.checkbox,
|
|
88
|
+
customValue: ["1", "0"],
|
|
89
|
+
defaultChecked: !1
|
|
90
|
+
}
|
|
91
|
+
]), o = w(l);
|
|
92
|
+
function u({ row: r, column: i, value: m }) {
|
|
93
|
+
i.key === "queryConfigFlag" && m === "1" && t("query", r.id);
|
|
94
|
+
}
|
|
95
|
+
return s(p({}, o), { columns: l, handleChange: u });
|
|
96
|
+
}
|
|
97
|
+
});
|
|
98
|
+
function x(e, t, l, o, u, r) {
|
|
99
|
+
const i = v("JVxeTable");
|
|
100
|
+
return T(), _(i, V({
|
|
101
|
+
ref: "tableRef",
|
|
102
|
+
rowNumber: "",
|
|
103
|
+
keyboardEdit: "",
|
|
104
|
+
maxHeight: e.tableHeight.noToolbar,
|
|
105
|
+
loading: e.loading,
|
|
106
|
+
columns: e.columns,
|
|
107
|
+
dataSource: e.dataSource,
|
|
108
|
+
disabledRows: { dbFieldName: ["id", "has_child"] },
|
|
109
|
+
onValueChange: e.handleChange
|
|
110
|
+
}, e.tableProps), null, 16, ["maxHeight", "loading", "columns", "dataSource", "onValueChange"]);
|
|
111
|
+
}
|
|
112
|
+
const W = /* @__PURE__ */ C(q, [["render", x]]);
|
|
113
|
+
export {
|
|
114
|
+
W as default
|
|
115
|
+
};
|
package/README.md
CHANGED