@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
package/useOnlineTest.js
DELETED
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
import { ref } from "vue";
|
|
2
|
-
function useOnlineTest(data, methods, form) {
|
|
3
|
-
const aiTestMode = ref(false);
|
|
4
|
-
const aiTestTable = ref([]);
|
|
5
|
-
const aiTableList = ref([]);
|
|
6
|
-
function initVirtualData() {
|
|
7
|
-
}
|
|
8
|
-
function genButtons(code) {
|
|
9
|
-
}
|
|
10
|
-
function genEnhanceJavaData(code) {
|
|
11
|
-
}
|
|
12
|
-
function genEnhanceJsData(tableName, type, codeEditor) {
|
|
13
|
-
}
|
|
14
|
-
function genEnhanceSqlData(code, tableName) {
|
|
15
|
-
}
|
|
16
|
-
function setTaleConfig() {
|
|
17
|
-
}
|
|
18
|
-
function tableJsonGetHelper(pickAfter) {
|
|
19
|
-
console.log("\u8868\u7684\u914D\u7F6E\u4FE1\u606F", JSON.stringify(pickAfter));
|
|
20
|
-
console.log("---------------------------------------");
|
|
21
|
-
}
|
|
22
|
-
function fieldsJsonGetHelper(fields) {
|
|
23
|
-
}
|
|
24
|
-
function refreshCacheTableName(oldValue, newValue) {
|
|
25
|
-
}
|
|
26
|
-
function getCacheTableName(name) {
|
|
27
|
-
}
|
|
28
|
-
return {
|
|
29
|
-
aiTestMode,
|
|
30
|
-
aiTestTable,
|
|
31
|
-
aiTableList,
|
|
32
|
-
initVirtualData,
|
|
33
|
-
genButtons,
|
|
34
|
-
genEnhanceJavaData,
|
|
35
|
-
genEnhanceJsData,
|
|
36
|
-
genEnhanceSqlData,
|
|
37
|
-
setTaleConfig,
|
|
38
|
-
tableJsonGetHelper,
|
|
39
|
-
fieldsJsonGetHelper,
|
|
40
|
-
refreshCacheTableName,
|
|
41
|
-
getCacheTableName
|
|
42
|
-
};
|
|
43
|
-
}
|
|
44
|
-
export { useOnlineTest as u };
|
package/useSchemas.js
DELETED
|
@@ -1,653 +0,0 @@
|
|
|
1
|
-
import { computed, h } from "vue";
|
|
2
|
-
import { Input, Button } from "ant-design-vue";
|
|
3
|
-
import { FolderOpenOutlined } from "@ant-design/icons-vue";
|
|
4
|
-
import { bindMapFormSchema } from "/@/utils/common/compUtils";
|
|
5
|
-
import { usePermission } from "/@/hooks/web/usePermission";
|
|
6
|
-
import { rules } from "/@/utils/helper/validator";
|
|
7
|
-
usePermission();
|
|
8
|
-
function useFormSchemas(_props, handlers) {
|
|
9
|
-
const mapFormSchema = bindMapFormSchema(
|
|
10
|
-
{
|
|
11
|
-
one: {
|
|
12
|
-
colProps: { xs: 24, sm: 24 },
|
|
13
|
-
itemProps: {
|
|
14
|
-
labelCol: { xs: 24, sm: 2 },
|
|
15
|
-
wrapperCol: { xs: 24, sm: 22 }
|
|
16
|
-
}
|
|
17
|
-
},
|
|
18
|
-
tow: {
|
|
19
|
-
colProps: { xs: 24, sm: 12 },
|
|
20
|
-
itemProps: {
|
|
21
|
-
labelCol: { xs: 24, sm: 4 },
|
|
22
|
-
wrapperCol: { xs: 24, sm: 20 }
|
|
23
|
-
}
|
|
24
|
-
},
|
|
25
|
-
three: {
|
|
26
|
-
colProps: { xs: 24, sm: 8 },
|
|
27
|
-
itemProps: {
|
|
28
|
-
labelCol: { xs: 24, sm: 6 },
|
|
29
|
-
wrapperCol: { xs: 24, sm: 18 }
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
},
|
|
33
|
-
"three"
|
|
34
|
-
);
|
|
35
|
-
const formSchemas = [
|
|
36
|
-
{ label: "", field: "id", component: "Input", show: false },
|
|
37
|
-
{ label: "", field: "tableVersion", component: "Input", show: false },
|
|
38
|
-
mapFormSchema({
|
|
39
|
-
label: "\u8868\u540D",
|
|
40
|
-
field: "tableName",
|
|
41
|
-
component: "Input",
|
|
42
|
-
required: true,
|
|
43
|
-
dynamicDisabled: ({ model }) => model.tableVersion && model.tableVersion != 1,
|
|
44
|
-
dynamicRules: ({ model, schema }) => rules.duplicateCheckRule("onl_cgform_head", "table_name", model, schema, true)
|
|
45
|
-
}),
|
|
46
|
-
mapFormSchema({
|
|
47
|
-
label: "\u8868\u63CF\u8FF0",
|
|
48
|
-
field: "tableTxt",
|
|
49
|
-
component: "Input",
|
|
50
|
-
required: true
|
|
51
|
-
}),
|
|
52
|
-
mapFormSchema({
|
|
53
|
-
label: "\u8868\u7C7B\u578B",
|
|
54
|
-
field: "tableType",
|
|
55
|
-
component: "Select",
|
|
56
|
-
defaultValue: 1,
|
|
57
|
-
componentProps: {
|
|
58
|
-
options: [
|
|
59
|
-
{ label: "\u5355\u8868", value: 1 },
|
|
60
|
-
{ label: "\u4E3B\u8868", value: 2 },
|
|
61
|
-
{ label: "\u9644\u8868", value: 3 }
|
|
62
|
-
],
|
|
63
|
-
onChange: handlers.onTableTypeChange
|
|
64
|
-
}
|
|
65
|
-
}),
|
|
66
|
-
{
|
|
67
|
-
label: "",
|
|
68
|
-
field: "relationType",
|
|
69
|
-
component: "InputNumber",
|
|
70
|
-
render: () => "",
|
|
71
|
-
colProps: { xs: 0, sm: 17 },
|
|
72
|
-
ifShow: fieldIfShow
|
|
73
|
-
},
|
|
74
|
-
mapFormSchema({
|
|
75
|
-
label: "",
|
|
76
|
-
field: "relationType",
|
|
77
|
-
component: "RadioGroup",
|
|
78
|
-
defaultValue: 0,
|
|
79
|
-
componentProps: {
|
|
80
|
-
options: [
|
|
81
|
-
{ label: "\u4E00\u5BF9\u591A", value: 0 },
|
|
82
|
-
{ label: "\u4E00\u5BF9\u4E00", value: 1 }
|
|
83
|
-
]
|
|
84
|
-
},
|
|
85
|
-
colProps: { xs: 24, sm: 4 },
|
|
86
|
-
itemProps: {
|
|
87
|
-
colon: false,
|
|
88
|
-
labelCol: { xs: 0, sm: 0 },
|
|
89
|
-
wrapperCol: { xs: 24, sm: 24 }
|
|
90
|
-
},
|
|
91
|
-
ifShow: fieldIfShow
|
|
92
|
-
}),
|
|
93
|
-
mapFormSchema({
|
|
94
|
-
label: "\u5E8F\u53F7",
|
|
95
|
-
field: "tabOrderNum",
|
|
96
|
-
component: "InputNumber",
|
|
97
|
-
componentProps: {
|
|
98
|
-
style: {
|
|
99
|
-
width: "100%"
|
|
100
|
-
}
|
|
101
|
-
},
|
|
102
|
-
colProps: { xs: 24, sm: 3 },
|
|
103
|
-
itemProps: {
|
|
104
|
-
labelCol: { xs: 24, sm: 7 },
|
|
105
|
-
wrapperCol: { xs: 24, sm: 24 - 7 }
|
|
106
|
-
},
|
|
107
|
-
ifShow: fieldIfShow
|
|
108
|
-
}),
|
|
109
|
-
mapFormSchema({
|
|
110
|
-
label: "\u8868\u5355\u5206\u7C7B",
|
|
111
|
-
field: "formCategory",
|
|
112
|
-
component: "JDictSelectTag",
|
|
113
|
-
defaultValue: "temp",
|
|
114
|
-
componentProps: {
|
|
115
|
-
dictCode: "ol_form_biz_type"
|
|
116
|
-
}
|
|
117
|
-
}),
|
|
118
|
-
mapFormSchema({
|
|
119
|
-
label: "\u4E3B\u952E\u7B56\u7565",
|
|
120
|
-
field: "idType",
|
|
121
|
-
component: "Select",
|
|
122
|
-
defaultValue: "UUID",
|
|
123
|
-
componentProps: {
|
|
124
|
-
options: [
|
|
125
|
-
{ label: "ID_WORKER(\u5206\u5E03\u5F0F\u81EA\u589E)", value: "UUID" }
|
|
126
|
-
]
|
|
127
|
-
}
|
|
128
|
-
}),
|
|
129
|
-
mapFormSchema({
|
|
130
|
-
label: "\u5E8F\u53F7\u540D\u79F0",
|
|
131
|
-
field: "idSequence",
|
|
132
|
-
component: "Input",
|
|
133
|
-
componentProps: {},
|
|
134
|
-
ifShow: fieldIfShow
|
|
135
|
-
}),
|
|
136
|
-
mapFormSchema({
|
|
137
|
-
label: "\u663E\u793A\u590D\u9009\u6846",
|
|
138
|
-
field: "isCheckbox",
|
|
139
|
-
component: "Select",
|
|
140
|
-
defaultValue: "Y",
|
|
141
|
-
componentProps: {
|
|
142
|
-
options: [
|
|
143
|
-
{ label: "\u662F", value: "Y" },
|
|
144
|
-
{ label: "\u5426", value: "N" }
|
|
145
|
-
]
|
|
146
|
-
}
|
|
147
|
-
}),
|
|
148
|
-
mapFormSchema({
|
|
149
|
-
label: "\u4E3B\u9898\u6A21\u677F",
|
|
150
|
-
field: "themeTemplate",
|
|
151
|
-
component: "Select",
|
|
152
|
-
defaultValue: "normal",
|
|
153
|
-
componentProps: {
|
|
154
|
-
options: [
|
|
155
|
-
{ label: "\u9ED8\u8BA4\u4E3B\u9898", value: "normal" }
|
|
156
|
-
]
|
|
157
|
-
},
|
|
158
|
-
dynamicDisabled: ({ model }) => model.tableType === 1
|
|
159
|
-
}),
|
|
160
|
-
mapFormSchema({
|
|
161
|
-
label: "\u8868\u5355\u98CE\u683C",
|
|
162
|
-
field: "formTemplate",
|
|
163
|
-
component: "Select",
|
|
164
|
-
defaultValue: "1",
|
|
165
|
-
componentProps: {
|
|
166
|
-
options: [
|
|
167
|
-
{ label: "\u4E00\u5217", value: "1" },
|
|
168
|
-
{ label: "\u4E24\u5217", value: "2" },
|
|
169
|
-
{ label: "\u4E09\u5217", value: "3" },
|
|
170
|
-
{ label: "\u56DB\u5217", value: "4" }
|
|
171
|
-
],
|
|
172
|
-
placeholder: "\u8BF7\u9009\u62E9PC\u8868\u5355\u98CE\u683C"
|
|
173
|
-
}
|
|
174
|
-
}),
|
|
175
|
-
mapFormSchema({
|
|
176
|
-
label: "\u79FB\u52A8\u8868\u5355\u98CE\u683C",
|
|
177
|
-
field: "formTemplateMobile",
|
|
178
|
-
component: "Select",
|
|
179
|
-
defaultValue: "1",
|
|
180
|
-
componentProps: {
|
|
181
|
-
options: [
|
|
182
|
-
{ label: "AntDesign\u6A21\u677F", value: "1" },
|
|
183
|
-
{ label: "Bootstrap\u6A21\u677F", value: "2" }
|
|
184
|
-
],
|
|
185
|
-
placeholder: "\u8BF7\u9009\u62E9\u79FB\u52A8\u8868\u5355\u98CE\u683C"
|
|
186
|
-
},
|
|
187
|
-
ifShow: false
|
|
188
|
-
}),
|
|
189
|
-
mapFormSchema({
|
|
190
|
-
label: "\u6EDA\u52A8\u6761",
|
|
191
|
-
field: "scroll",
|
|
192
|
-
component: "Select",
|
|
193
|
-
defaultValue: 1,
|
|
194
|
-
componentProps: {
|
|
195
|
-
options: [
|
|
196
|
-
{ label: "\u6709", value: 1 },
|
|
197
|
-
{ label: "\u65E0", value: 0 }
|
|
198
|
-
]
|
|
199
|
-
}
|
|
200
|
-
}),
|
|
201
|
-
mapFormSchema({
|
|
202
|
-
label: "\u662F\u5426\u5206\u9875",
|
|
203
|
-
field: "isPage",
|
|
204
|
-
component: "Select",
|
|
205
|
-
defaultValue: "Y",
|
|
206
|
-
componentProps: {
|
|
207
|
-
options: [
|
|
208
|
-
{ label: "\u662F", value: "Y" },
|
|
209
|
-
{ label: "\u5426", value: "N" }
|
|
210
|
-
]
|
|
211
|
-
}
|
|
212
|
-
}),
|
|
213
|
-
mapFormSchema({
|
|
214
|
-
label: "\u662F\u5426\u6811",
|
|
215
|
-
field: "isTree",
|
|
216
|
-
component: "Select",
|
|
217
|
-
defaultValue: "N",
|
|
218
|
-
componentProps: {
|
|
219
|
-
options: [
|
|
220
|
-
{ label: "\u662F", value: "Y" },
|
|
221
|
-
{ label: "\u5426", value: "N" }
|
|
222
|
-
],
|
|
223
|
-
onChange: handlers.onIsTreeChange
|
|
224
|
-
},
|
|
225
|
-
dynamicRules({ model }) {
|
|
226
|
-
return [
|
|
227
|
-
{
|
|
228
|
-
validator({}, value) {
|
|
229
|
-
if (value === "Y" && (model.tableType == 2 || model.tableType == 3)) {
|
|
230
|
-
return Promise.reject("\u4E3B\u8868\u548C\u9644\u8868\u4E0D\u652F\u6301\u6811\u7C7B\u578B\uFF01");
|
|
231
|
-
}
|
|
232
|
-
return Promise.resolve();
|
|
233
|
-
}
|
|
234
|
-
}
|
|
235
|
-
];
|
|
236
|
-
}
|
|
237
|
-
}),
|
|
238
|
-
mapFormSchema({
|
|
239
|
-
label: " ",
|
|
240
|
-
field: "extConfigJson",
|
|
241
|
-
component: "Input",
|
|
242
|
-
slot: "extConfigButton",
|
|
243
|
-
itemProps: { colon: false }
|
|
244
|
-
}),
|
|
245
|
-
mapFormSchema({
|
|
246
|
-
label: "\u6811\u8868\u5355\u7236ID",
|
|
247
|
-
field: "treeParentIdField",
|
|
248
|
-
component: "Input",
|
|
249
|
-
ifShow: fieldIfShow
|
|
250
|
-
}),
|
|
251
|
-
mapFormSchema({
|
|
252
|
-
label: "\u662F\u5426\u6709\u5B50\u8282\u70B9\u5B57\u6BB5",
|
|
253
|
-
field: "treeIdField",
|
|
254
|
-
component: "Input",
|
|
255
|
-
show: false
|
|
256
|
-
}),
|
|
257
|
-
mapFormSchema({
|
|
258
|
-
label: "\u6811\u5F00\u8868\u5355\u5217",
|
|
259
|
-
field: "treeFieldname",
|
|
260
|
-
required: true,
|
|
261
|
-
component: "Input",
|
|
262
|
-
ifShow: fieldIfShow
|
|
263
|
-
}),
|
|
264
|
-
mapFormSchema(
|
|
265
|
-
{
|
|
266
|
-
label: "\u9644\u8868",
|
|
267
|
-
field: "subTableStr",
|
|
268
|
-
component: "Input",
|
|
269
|
-
componentProps: {
|
|
270
|
-
disabled: true,
|
|
271
|
-
placeholder: " ",
|
|
272
|
-
allowClear: false
|
|
273
|
-
},
|
|
274
|
-
ifShow: handlers.ifShowOfSubTableStr
|
|
275
|
-
},
|
|
276
|
-
"one"
|
|
277
|
-
)
|
|
278
|
-
];
|
|
279
|
-
function fieldIfShow({ field, model }) {
|
|
280
|
-
switch (field) {
|
|
281
|
-
case "relationType":
|
|
282
|
-
case "tabOrderNum":
|
|
283
|
-
return model.tableType === 3;
|
|
284
|
-
case "treeParentIdField":
|
|
285
|
-
case "treeIdField":
|
|
286
|
-
case "treeFieldname":
|
|
287
|
-
return model.isTree === "Y";
|
|
288
|
-
case "idSequence":
|
|
289
|
-
return model.idType === "SEQUENCE";
|
|
290
|
-
}
|
|
291
|
-
return true;
|
|
292
|
-
}
|
|
293
|
-
return { formSchemas };
|
|
294
|
-
}
|
|
295
|
-
function useExtendConfigFormSchemas(_props, handlers) {
|
|
296
|
-
const mapFormSchema = bindMapFormSchema(
|
|
297
|
-
{
|
|
298
|
-
left: {
|
|
299
|
-
colProps: { xs: 24, sm: 7 },
|
|
300
|
-
itemProps: {
|
|
301
|
-
labelCol: { xs: 24, sm: 11 },
|
|
302
|
-
wrapperCol: { xs: 24, sm: 13 }
|
|
303
|
-
},
|
|
304
|
-
style: { width: "100%" }
|
|
305
|
-
},
|
|
306
|
-
right: {
|
|
307
|
-
colProps: { xs: 24, sm: 17 },
|
|
308
|
-
itemProps: {
|
|
309
|
-
labelCol: { xs: 24, sm: 3 },
|
|
310
|
-
wrapperCol: { xs: 24, sm: 20 }
|
|
311
|
-
},
|
|
312
|
-
style: { width: "100%" }
|
|
313
|
-
}
|
|
314
|
-
},
|
|
315
|
-
"left"
|
|
316
|
-
);
|
|
317
|
-
const formSchemas = [
|
|
318
|
-
mapFormSchema(
|
|
319
|
-
{
|
|
320
|
-
label: "\u5F39\u7A97\u9ED8\u8BA4\u5168\u5C4F",
|
|
321
|
-
field: "modelFullscreen",
|
|
322
|
-
component: "RadioButtonGroup",
|
|
323
|
-
componentProps: {
|
|
324
|
-
options: [
|
|
325
|
-
{ label: "\u5F00\u542F", value: 1 },
|
|
326
|
-
{ label: "\u5173\u95ED", value: 0 }
|
|
327
|
-
],
|
|
328
|
-
buttonStyle: "solid"
|
|
329
|
-
}
|
|
330
|
-
},
|
|
331
|
-
"left"
|
|
332
|
-
),
|
|
333
|
-
mapFormSchema(
|
|
334
|
-
{
|
|
335
|
-
label: "\u5F39\u7A97\u5BBD\u5EA6",
|
|
336
|
-
field: "modalMinWidth",
|
|
337
|
-
component: "InputNumber",
|
|
338
|
-
componentProps: {
|
|
339
|
-
style: "width: 80%",
|
|
340
|
-
placeholder: "\u5F39\u7A97\u6700\u5C0F\u5BBD\u5EA6\uFF08\u5355\u4F4D\uFF1Apx\uFF09"
|
|
341
|
-
}
|
|
342
|
-
},
|
|
343
|
-
"right"
|
|
344
|
-
),
|
|
345
|
-
mapFormSchema(
|
|
346
|
-
{
|
|
347
|
-
label: "\u5F00\u542F\u8868\u5355\u8BC4\u8BBA",
|
|
348
|
-
field: "commentStatus",
|
|
349
|
-
component: "RadioButtonGroup",
|
|
350
|
-
componentProps: {
|
|
351
|
-
options: [
|
|
352
|
-
{ label: "\u5F00\u542F", value: 1 },
|
|
353
|
-
{ label: "\u5173\u95ED", value: 0 }
|
|
354
|
-
],
|
|
355
|
-
buttonStyle: "solid"
|
|
356
|
-
}
|
|
357
|
-
},
|
|
358
|
-
"left"
|
|
359
|
-
),
|
|
360
|
-
mapFormSchema(
|
|
361
|
-
{
|
|
362
|
-
label: "",
|
|
363
|
-
field: "commentStatus",
|
|
364
|
-
component: "InputNumber",
|
|
365
|
-
render: () => ""
|
|
366
|
-
},
|
|
367
|
-
"right"
|
|
368
|
-
),
|
|
369
|
-
mapFormSchema(
|
|
370
|
-
{
|
|
371
|
-
label: "\u542F\u7528\u8054\u5408\u67E5\u8BE2",
|
|
372
|
-
field: "joinQuery",
|
|
373
|
-
component: "RadioButtonGroup",
|
|
374
|
-
componentProps: {
|
|
375
|
-
options: [
|
|
376
|
-
{ label: "\u5F00\u542F", value: 1 },
|
|
377
|
-
{ label: "\u5173\u95ED", value: 0 }
|
|
378
|
-
],
|
|
379
|
-
buttonStyle: "solid",
|
|
380
|
-
onChange: handlers.onJoinQueryChange
|
|
381
|
-
}
|
|
382
|
-
},
|
|
383
|
-
"left"
|
|
384
|
-
),
|
|
385
|
-
mapFormSchema(
|
|
386
|
-
{
|
|
387
|
-
label: "",
|
|
388
|
-
field: "joinQuery",
|
|
389
|
-
component: "InputNumber",
|
|
390
|
-
render: () => ""
|
|
391
|
-
},
|
|
392
|
-
"right"
|
|
393
|
-
),
|
|
394
|
-
mapFormSchema(
|
|
395
|
-
{
|
|
396
|
-
label: "\u96C6\u6210\u79EF\u6728\u62A5\u8868",
|
|
397
|
-
field: "reportPrintShow",
|
|
398
|
-
component: "RadioButtonGroup",
|
|
399
|
-
componentProps: {
|
|
400
|
-
options: [
|
|
401
|
-
{ label: "\u5F00\u542F", value: 1 },
|
|
402
|
-
{ label: "\u5173\u95ED", value: 0 }
|
|
403
|
-
],
|
|
404
|
-
buttonStyle: "solid",
|
|
405
|
-
onChange: handlers.onReportPrintShowChange
|
|
406
|
-
}
|
|
407
|
-
},
|
|
408
|
-
"left"
|
|
409
|
-
),
|
|
410
|
-
mapFormSchema(
|
|
411
|
-
{
|
|
412
|
-
label: "\u62A5\u8868\u5730\u5740",
|
|
413
|
-
field: "reportPrintUrl",
|
|
414
|
-
component: "Input",
|
|
415
|
-
componentProps: {
|
|
416
|
-
style: "width: 80%"
|
|
417
|
-
},
|
|
418
|
-
dynamicDisabled: ({ model }) => !model.reportPrintShow,
|
|
419
|
-
dynamicRules: ({ model }) => {
|
|
420
|
-
return [
|
|
421
|
-
{ required: !!model.reportPrintShow, message: "\u8BF7\u8F93\u5165\u62A5\u8868\u5730\u5740\uFF01" },
|
|
422
|
-
{
|
|
423
|
-
validator({}, value) {
|
|
424
|
-
if (/\/jmreport\/view\/{积木报表ID}/.test(value)) {
|
|
425
|
-
return Promise.reject("\u8BF7\u5C06{\u79EF\u6728\u62A5\u8868ID}\u66FF\u6362\u4E3A\u771F\u5B9E\u7684\u79EF\u6728\u62A5\u8868ID\uFF01");
|
|
426
|
-
}
|
|
427
|
-
return Promise.resolve();
|
|
428
|
-
}
|
|
429
|
-
}
|
|
430
|
-
];
|
|
431
|
-
}
|
|
432
|
-
},
|
|
433
|
-
"right"
|
|
434
|
-
),
|
|
435
|
-
mapFormSchema(
|
|
436
|
-
{
|
|
437
|
-
label: "\u96C6\u6210\u8BBE\u8BA1\u8868\u5355",
|
|
438
|
-
field: "isDesForm",
|
|
439
|
-
component: "RadioButtonGroup",
|
|
440
|
-
componentProps: {
|
|
441
|
-
options: [
|
|
442
|
-
{ label: "\u5F00\u542F", value: "Y" },
|
|
443
|
-
{ label: "\u5173\u95ED", value: "N" }
|
|
444
|
-
],
|
|
445
|
-
buttonStyle: "solid",
|
|
446
|
-
onChange: handlers.onIsDesformChange
|
|
447
|
-
}
|
|
448
|
-
},
|
|
449
|
-
"left"
|
|
450
|
-
),
|
|
451
|
-
mapFormSchema(
|
|
452
|
-
{
|
|
453
|
-
label: "\u8868\u5355\u7F16\u7801",
|
|
454
|
-
field: "desFormCode",
|
|
455
|
-
component: "Input",
|
|
456
|
-
componentProps: {
|
|
457
|
-
style: "width: 80%"
|
|
458
|
-
},
|
|
459
|
-
dynamicDisabled: ({ model }) => model.isDesForm !== "Y",
|
|
460
|
-
dynamicRules: ({ model }) => {
|
|
461
|
-
return [{ required: model.isDesForm === "Y", message: "\u8BF7\u8F93\u5165\u8868\u5355\u7F16\u7801\uFF01" }];
|
|
462
|
-
}
|
|
463
|
-
},
|
|
464
|
-
"right"
|
|
465
|
-
),
|
|
466
|
-
mapFormSchema(
|
|
467
|
-
{
|
|
468
|
-
label: "\u56FA\u5B9A\u64CD\u4F5C\u5217",
|
|
469
|
-
field: "tableFixedAction",
|
|
470
|
-
component: "RadioButtonGroup",
|
|
471
|
-
componentProps: {
|
|
472
|
-
options: [
|
|
473
|
-
{ label: "\u5F00\u542F", value: 1 },
|
|
474
|
-
{ label: "\u5173\u95ED", value: 0 }
|
|
475
|
-
],
|
|
476
|
-
buttonStyle: "solid"
|
|
477
|
-
},
|
|
478
|
-
defaultValue: 1
|
|
479
|
-
},
|
|
480
|
-
"left"
|
|
481
|
-
),
|
|
482
|
-
mapFormSchema(
|
|
483
|
-
{
|
|
484
|
-
label: "\u56FA\u5B9A\u65B9\u5F0F",
|
|
485
|
-
field: "tableFixedActionType",
|
|
486
|
-
component: "Select",
|
|
487
|
-
componentProps: {
|
|
488
|
-
options: [
|
|
489
|
-
{ label: "\u56FA\u5B9A\u5230\u53F3\u4FA7", value: "right" },
|
|
490
|
-
{ label: "\u56FA\u5B9A\u5230\u5DE6\u4FA7", value: "left" }
|
|
491
|
-
],
|
|
492
|
-
style: "width: 80%"
|
|
493
|
-
},
|
|
494
|
-
defaultValue: "right",
|
|
495
|
-
dynamicDisabled: ({ model }) => !model.tableFixedAction,
|
|
496
|
-
dynamicRules: ({ model }) => {
|
|
497
|
-
return [{ required: !!model.tableFixedAction, message: "\u8BF7\u9009\u62E9\u56FA\u5B9A\u65B9\u5F0F\uFF01" }];
|
|
498
|
-
}
|
|
499
|
-
},
|
|
500
|
-
"right"
|
|
501
|
-
)
|
|
502
|
-
];
|
|
503
|
-
return { formSchemas };
|
|
504
|
-
}
|
|
505
|
-
function useCodeGeneratorFormSchemas(_, handlers, single) {
|
|
506
|
-
const mapFormSchema = bindMapFormSchema(
|
|
507
|
-
{
|
|
508
|
-
one: {
|
|
509
|
-
colProps: { xs: 24, sm: 24 },
|
|
510
|
-
itemProps: {
|
|
511
|
-
labelCol: { xs: 24, sm: 5 },
|
|
512
|
-
wrapperCol: { xs: 24, sm: 16 }
|
|
513
|
-
}
|
|
514
|
-
},
|
|
515
|
-
towOne: {
|
|
516
|
-
colProps: { xs: 24, sm: 24 },
|
|
517
|
-
itemProps: {
|
|
518
|
-
labelCol: { xs: 24, sm: 3 },
|
|
519
|
-
wrapperCol: { xs: 24, sm: 20 }
|
|
520
|
-
}
|
|
521
|
-
},
|
|
522
|
-
tow: {
|
|
523
|
-
colProps: { xs: 24, sm: 12 },
|
|
524
|
-
itemProps: {
|
|
525
|
-
labelCol: { xs: 24, sm: 6 },
|
|
526
|
-
wrapperCol: { xs: 24, sm: 16 }
|
|
527
|
-
}
|
|
528
|
-
}
|
|
529
|
-
},
|
|
530
|
-
"one"
|
|
531
|
-
);
|
|
532
|
-
const getColSize = computed(() => single.value ? "one" : "tow");
|
|
533
|
-
const formSchemas = computed(() => [
|
|
534
|
-
mapFormSchema(
|
|
535
|
-
{
|
|
536
|
-
label: "\u4EE3\u7801\u751F\u6210\u76EE\u5F55",
|
|
537
|
-
field: "projectPath",
|
|
538
|
-
render: ({ model, field }) => h(
|
|
539
|
-
Input.Search,
|
|
540
|
-
{
|
|
541
|
-
value: model[field],
|
|
542
|
-
onChange: (e) => {
|
|
543
|
-
model[field] = e.target.value;
|
|
544
|
-
handlers.onProjectPathChange(e);
|
|
545
|
-
},
|
|
546
|
-
onSearch: handlers.onProjectPathSearch
|
|
547
|
-
},
|
|
548
|
-
{
|
|
549
|
-
enterButton: () => h(
|
|
550
|
-
Button,
|
|
551
|
-
{
|
|
552
|
-
preIcon: "ant-design:folder-open"
|
|
553
|
-
},
|
|
554
|
-
{
|
|
555
|
-
default: () => "\u6D4F\u89C8",
|
|
556
|
-
icon: () => h(FolderOpenOutlined)
|
|
557
|
-
}
|
|
558
|
-
)
|
|
559
|
-
}
|
|
560
|
-
),
|
|
561
|
-
component: "InputSearch",
|
|
562
|
-
required: true
|
|
563
|
-
},
|
|
564
|
-
single.value ? "one" : "towOne"
|
|
565
|
-
),
|
|
566
|
-
mapFormSchema(
|
|
567
|
-
{
|
|
568
|
-
label: "\u9875\u9762\u98CE\u683C",
|
|
569
|
-
field: "jspMode",
|
|
570
|
-
component: "Select",
|
|
571
|
-
componentProps: {
|
|
572
|
-
options: handlers.jspModeOptions.value
|
|
573
|
-
}
|
|
574
|
-
},
|
|
575
|
-
getColSize.value
|
|
576
|
-
),
|
|
577
|
-
mapFormSchema(
|
|
578
|
-
{
|
|
579
|
-
label: "\u529F\u80FD\u8BF4\u660E",
|
|
580
|
-
field: "ftlDescription",
|
|
581
|
-
component: "Input"
|
|
582
|
-
},
|
|
583
|
-
getColSize.value
|
|
584
|
-
),
|
|
585
|
-
{ label: "\u6570\u636E\u6A21\u578B", field: "jformType", component: "Input", show: false },
|
|
586
|
-
mapFormSchema(
|
|
587
|
-
{
|
|
588
|
-
label: "\u8868\u540D",
|
|
589
|
-
field: "tableName_tmp",
|
|
590
|
-
required: true,
|
|
591
|
-
dynamicDisabled: true,
|
|
592
|
-
component: "Input"
|
|
593
|
-
},
|
|
594
|
-
getColSize.value
|
|
595
|
-
),
|
|
596
|
-
mapFormSchema(
|
|
597
|
-
{
|
|
598
|
-
label: "\u5B9E\u4F53\u7C7B\u540D",
|
|
599
|
-
field: "entityName",
|
|
600
|
-
required: true,
|
|
601
|
-
component: "Input",
|
|
602
|
-
componentProps: {
|
|
603
|
-
placeholder: "\u8BF7\u8F93\u5165\u5B9E\u4F53\u7C7B\u540D(\u9996\u5B57\u6BCD\u5927\u5199)"
|
|
604
|
-
}
|
|
605
|
-
},
|
|
606
|
-
getColSize.value
|
|
607
|
-
),
|
|
608
|
-
mapFormSchema(
|
|
609
|
-
{
|
|
610
|
-
label: "\u5305\u540D(\u5C0F\u5199)",
|
|
611
|
-
field: "entityPackage",
|
|
612
|
-
required: true,
|
|
613
|
-
component: "Input"
|
|
614
|
-
},
|
|
615
|
-
getColSize.value
|
|
616
|
-
),
|
|
617
|
-
mapFormSchema(
|
|
618
|
-
{
|
|
619
|
-
label: "\u4EE3\u7801\u5206\u5C42\u6837\u5F0F",
|
|
620
|
-
field: "packageStyle",
|
|
621
|
-
component: "Select",
|
|
622
|
-
componentProps: {
|
|
623
|
-
disabled: true,
|
|
624
|
-
options: [
|
|
625
|
-
{ label: "\u4E1A\u52A1\u5206\u5C42", value: "service" },
|
|
626
|
-
{ label: "\u4EE3\u7801\u5206\u5C42", value: "project" }
|
|
627
|
-
]
|
|
628
|
-
}
|
|
629
|
-
},
|
|
630
|
-
getColSize.value
|
|
631
|
-
),
|
|
632
|
-
mapFormSchema(
|
|
633
|
-
{
|
|
634
|
-
label: "\u9875\u9762\u4EE3\u7801",
|
|
635
|
-
field: "vueStyle",
|
|
636
|
-
required: true,
|
|
637
|
-
component: "RadioGroup",
|
|
638
|
-
defaultValue: "vue3",
|
|
639
|
-
componentProps: {
|
|
640
|
-
options: [
|
|
641
|
-
{ label: "Vue3", value: "vue3" },
|
|
642
|
-
{ label: "Vue3 \u539F\u751F", value: "vue3Native" },
|
|
643
|
-
{ label: "Vue2", value: "vue" }
|
|
644
|
-
]
|
|
645
|
-
}
|
|
646
|
-
},
|
|
647
|
-
getColSize.value
|
|
648
|
-
),
|
|
649
|
-
{ label: "\u9700\u8981\u751F\u6210\u7684\u4EE3\u7801", field: "codeTypes", component: "Input", show: false }
|
|
650
|
-
]);
|
|
651
|
-
return { formSchemas };
|
|
652
|
-
}
|
|
653
|
-
export { useExtendConfigFormSchemas as a, useCodeGeneratorFormSchemas as b, useFormSchemas as u };
|