@kp-ui/lowcode 1.0.59 → 1.0.61
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/_virtual/virtual_svg-icons-register.js +2 -2
- package/designer.js +1 -18
- package/package.json +1 -1
- package/render.js +7 -3
- package/src/components/form-designer/form-widget/container-widget/data-table-widget.vue.js +1 -1
- package/src/components/form-designer/form-widget/container-widget/vf-collapse-widget.vue.js +2 -13
- package/src/components/form-designer/form-widget/field-widget/button-list-widget.vue.js +3 -2
- package/src/components/form-designer/form-widget/index.vue.js +5 -13
- package/src/components/form-designer/setting-panel/property-editor/container-data-table/data-table-dsEnabled-editor.vue.js +7 -6
- package/src/components/form-designer/setting-panel/property-editor/container-data-table/data-table-tableColumns-editor.vue.js +36 -13
- package/src/components/form-designer/widget-panel/containers/data-table.js +1 -0
- package/src/components/form-designer/widget-panel/containers/vf-collapse.js +2 -2
- package/src/components/form-render/container-item/grid-item.vue.js +1 -0
- package/src/components/form-render/container-item/vf-collapse-item.vue.js +13 -16
- package/src/components/public/ActionButtonListRender.vue.js +2 -1
- package/src/components/public/ActionButtonListRender.vue2.js +5 -0
- package/src/lang/en-US.js +2 -2
- package/src/lang/en-US_extension.js +2 -2
- package/src/lang/en-US_render.js +2 -2
- package/src/lang/zh-CN.js +2 -2
- package/src/lang/zh-CN_extension.js +2 -2
- package/src/lang/zh-CN_render.js +2 -2
- package/src/mixins/useDataTableMixin.js +18 -4
- package/src/utils/i18n.js +30 -32
- package/src/utils/request/fmtHttpParams.js +0 -1
- package/src/utils/request/handleAxiosError.js +2 -1
- package/src/utils/smart-vue-i18n/index.js +16 -4
- package/styles/style.css +1 -1
- package/types/install.d.ts +0 -9
- package/types/install.d.ts.map +1 -1
- package/types/src/components/form-designer/widget-panel/containers/data-table.d.ts.map +1 -1
- package/types/src/hooks/useFilePreview.d.ts +1 -7
- package/types/src/hooks/useFilePreview.d.ts.map +1 -1
- package/types/src/utils/request/handleAxiosError.d.ts.map +1 -1
- package/types/src/utils/smart-vue-i18n/index.d.ts +12 -0
- package/types/src/utils/smart-vue-i18n/index.d.ts.map +1 -0
- package/types/src/components/code-editor/code-modal-editor.d.ts +0 -49
- package/types/src/components/code-editor/code-modal-editor.d.ts.map +0 -1
- package/types/src/components/code-editor/index.d.ts +0 -37
- package/types/src/components/code-editor/index.d.ts.map +0 -1
- package/types/src/components/form-designer/setting-panel/form-crud-setting.d.ts +0 -140
- package/types/src/components/form-designer/setting-panel/form-crud-setting.d.ts.map +0 -1
- package/types/src/components/form-designer/toolbar-panel/index.d.ts +0 -558
- package/types/src/components/form-designer/toolbar-panel/index.d.ts.map +0 -1
- package/types/src/components/form-designer/widget-panel/index.d.ts +0 -117
- package/types/src/components/form-designer/widget-panel/index.d.ts.map +0 -1
- package/types/src/components/form-render/SubmitButtonRender.d.ts +0 -25
- package/types/src/components/form-render/SubmitButtonRender.d.ts.map +0 -1
- package/types/src/components/form-render/index.d.ts +0 -509
- package/types/src/components/form-render/index.d.ts.map +0 -1
- package/types/src/components/http-editor/index.d.ts +0 -117
- package/types/src/components/http-editor/index.d.ts.map +0 -1
- package/types/src/components/svg-icon/index.d.ts +0 -47
- package/types/src/components/svg-icon/index.d.ts.map +0 -1
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
if (typeof window !== "undefined") {
|
|
2
2
|
let loadSvg = function() {
|
|
3
3
|
var body = document.body;
|
|
4
|
-
var svgDom = document.getElementById("
|
|
4
|
+
var svgDom = document.getElementById("__svg__icons__dom__1748419627870__");
|
|
5
5
|
if (!svgDom) {
|
|
6
6
|
svgDom = document.createElementNS("http://www.w3.org/2000/svg", "svg");
|
|
7
7
|
svgDom.style.position = "absolute";
|
|
8
8
|
svgDom.style.width = "0";
|
|
9
9
|
svgDom.style.height = "0";
|
|
10
|
-
svgDom.id = "
|
|
10
|
+
svgDom.id = "__svg__icons__dom__1748419627870__";
|
|
11
11
|
svgDom.setAttribute("xmlns", "http://www.w3.org/2000/svg");
|
|
12
12
|
svgDom.setAttribute("xmlns:link", "http://www.w3.org/1999/xlink");
|
|
13
13
|
}
|
package/designer.js
CHANGED
|
@@ -112,7 +112,6 @@ const _sfc_main = {
|
|
|
112
112
|
this.scrollerHeight = window.innerHeight - 56 - 36 + "px";
|
|
113
113
|
});
|
|
114
114
|
});
|
|
115
|
-
this.loadCase();
|
|
116
115
|
this.loadFieldListFromServer();
|
|
117
116
|
},
|
|
118
117
|
methods: {
|
|
@@ -160,17 +159,6 @@ const _sfc_main = {
|
|
|
160
159
|
}
|
|
161
160
|
return !!this.designerConfig[configName];
|
|
162
161
|
},
|
|
163
|
-
openHome() {
|
|
164
|
-
if (!!this.vsCodeFlag) {
|
|
165
|
-
const msgObj = {
|
|
166
|
-
cmd: "openUrl",
|
|
167
|
-
data: {
|
|
168
|
-
url: "https://www.vform666.com/"
|
|
169
|
-
}
|
|
170
|
-
};
|
|
171
|
-
window.parent.postMessage(msgObj, "*");
|
|
172
|
-
}
|
|
173
|
-
},
|
|
174
162
|
openUrl(event, url) {
|
|
175
163
|
if (!!this.vsCodeFlag) {
|
|
176
164
|
const msgObj = {
|
|
@@ -185,11 +173,6 @@ const _sfc_main = {
|
|
|
185
173
|
aDom.href = url;
|
|
186
174
|
}
|
|
187
175
|
},
|
|
188
|
-
loadCase() {
|
|
189
|
-
if (!this.caseName) {
|
|
190
|
-
return;
|
|
191
|
-
}
|
|
192
|
-
},
|
|
193
176
|
changeLanguage(langName) {
|
|
194
177
|
changeLocale(langName);
|
|
195
178
|
},
|
|
@@ -424,7 +407,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
424
407
|
_: 3
|
|
425
408
|
});
|
|
426
409
|
}
|
|
427
|
-
const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-
|
|
410
|
+
const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-90c0a3ae"]]);
|
|
428
411
|
export {
|
|
429
412
|
index as default
|
|
430
413
|
};
|
package/package.json
CHANGED
package/render.js
CHANGED
|
@@ -684,6 +684,9 @@ const _sfc_main = {
|
|
|
684
684
|
setTableValue(name, value) {
|
|
685
685
|
this.formDataModel[name] = value;
|
|
686
686
|
},
|
|
687
|
+
getTableValue(name) {
|
|
688
|
+
return this.formDataModel[name];
|
|
689
|
+
},
|
|
687
690
|
setFieldValue(fieldName, fieldValue, disableChangeEvent = false) {
|
|
688
691
|
const fieldRef = this.getWidgetRef(fieldName);
|
|
689
692
|
if (!!fieldRef && !!fieldRef.setValue) {
|
|
@@ -1036,7 +1039,8 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
1036
1039
|
data: $data.formDataModel[widget.options.name],
|
|
1037
1040
|
"parent-list": $options.widgetList,
|
|
1038
1041
|
"index-of-parent-list": index2,
|
|
1039
|
-
"parent-widget": null
|
|
1042
|
+
"parent-widget": null,
|
|
1043
|
+
model: $data.formDataModel
|
|
1040
1044
|
}, createSlots({ _: 2 }, [
|
|
1041
1045
|
renderList(Object.keys(_ctx.$slots), (slot) => {
|
|
1042
1046
|
return {
|
|
@@ -1046,7 +1050,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
1046
1050
|
])
|
|
1047
1051
|
};
|
|
1048
1052
|
})
|
|
1049
|
-
]), 1032, ["widget", "data", "parent-list", "index-of-parent-list"])) : (openBlock(), createBlock(resolveDynamicComponent($options.getWidgetName(widget)), {
|
|
1053
|
+
]), 1032, ["widget", "data", "parent-list", "index-of-parent-list", "model"])) : (openBlock(), createBlock(resolveDynamicComponent($options.getWidgetName(widget)), {
|
|
1050
1054
|
field: widget,
|
|
1051
1055
|
"form-model": $data.formDataModel,
|
|
1052
1056
|
designer: null,
|
|
@@ -1077,7 +1081,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
1077
1081
|
_: 3
|
|
1078
1082
|
}, 8, ["component-size"]);
|
|
1079
1083
|
}
|
|
1080
|
-
const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-
|
|
1084
|
+
const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-ad27ca1a"]]);
|
|
1081
1085
|
export {
|
|
1082
1086
|
index as default
|
|
1083
1087
|
};
|
|
@@ -58,7 +58,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
58
58
|
_: 1
|
|
59
59
|
}, 8, ["designer", "widget", "parent-widget", "parent-list", "index-of-parent-list", "style"]);
|
|
60
60
|
}
|
|
61
|
-
const dataTableWidget = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-
|
|
61
|
+
const dataTableWidget = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-814c57c7"]]);
|
|
62
62
|
export {
|
|
63
63
|
dataTableWidget as default
|
|
64
64
|
};
|
|
@@ -12,7 +12,6 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
12
12
|
const _component_SvgIcon = resolveComponent("SvgIcon");
|
|
13
13
|
const _component_a_space = resolveComponent("a-space");
|
|
14
14
|
const _component_draggable = resolveComponent("draggable");
|
|
15
|
-
const _component_VFormRender = resolveComponent("VFormRender");
|
|
16
15
|
const _component_container_wrapper = resolveComponent("container-wrapper");
|
|
17
16
|
return openBlock(), createBlock(_component_container_wrapper, {
|
|
18
17
|
designer: $props.designer,
|
|
@@ -97,16 +96,6 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
97
96
|
...JSON.parse($props.widget.options.bodyStyle || "{}")
|
|
98
97
|
})
|
|
99
98
|
}, [
|
|
100
|
-
$props.widget.options.formCode ? (openBlock(), createBlock(_component_VFormRender, {
|
|
101
|
-
key: 0,
|
|
102
|
-
ref: "dFormRef",
|
|
103
|
-
"form-json": $props.formJson,
|
|
104
|
-
"form-data": $props.formData,
|
|
105
|
-
"global-dsv": $props.globalDsv,
|
|
106
|
-
"parent-form": $props.parentFormRef,
|
|
107
|
-
"disabled-mode": $props.options.disabledMode,
|
|
108
|
-
"dynamic-creation": true
|
|
109
|
-
}, null, 8, ["form-json", "form-data", "global-dsv", "parent-form", "disabled-mode"])) : createCommentVNode("", true),
|
|
110
99
|
createVNode(_component_draggable, mergeProps({
|
|
111
100
|
list: $props.widget.defaultSlotsList,
|
|
112
101
|
"item-key": "id"
|
|
@@ -141,7 +130,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
141
130
|
_: 1
|
|
142
131
|
}, 16, ["list", "onUpdate", "move"])
|
|
143
132
|
], 4), [
|
|
144
|
-
[vShow,
|
|
133
|
+
[vShow, !$props.widget.options.isCollapse]
|
|
145
134
|
])
|
|
146
135
|
]),
|
|
147
136
|
_: 1
|
|
@@ -152,7 +141,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
152
141
|
_: 1
|
|
153
142
|
}, 8, ["designer", "widget", "parent-widget", "parent-list", "index-of-parent-list"]);
|
|
154
143
|
}
|
|
155
|
-
const vfCollapseWidget = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-
|
|
144
|
+
const vfCollapseWidget = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-e08dd758"]]);
|
|
156
145
|
export {
|
|
157
146
|
vfCollapseWidget as default
|
|
158
147
|
};
|
|
@@ -111,16 +111,17 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
111
111
|
}, {
|
|
112
112
|
default: withCtx(() => [
|
|
113
113
|
createVNode(_component_ActionButtonListRender, {
|
|
114
|
+
designState: $props.designState,
|
|
114
115
|
buttonList: $options.buttonList,
|
|
115
116
|
customClass: $options.customClass,
|
|
116
117
|
flex: $props.field.options.flex,
|
|
117
118
|
ctx: this
|
|
118
|
-
}, null, 8, ["buttonList", "customClass", "flex"])
|
|
119
|
+
}, null, 8, ["designState", "buttonList", "customClass", "flex"])
|
|
119
120
|
]),
|
|
120
121
|
_: 1
|
|
121
122
|
}, 8, ["designer", "field", "design-state", "parent-widget", "parent-list", "index-of-parent-list", "sub-form-row-index", "sub-form-col-index", "sub-form-row-id"]);
|
|
122
123
|
}
|
|
123
|
-
const buttonListWidget = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-
|
|
124
|
+
const buttonListWidget = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-dfc7daf7"]]);
|
|
124
125
|
export {
|
|
125
126
|
buttonListWidget as default
|
|
126
127
|
};
|
|
@@ -146,14 +146,12 @@ const _sfc_main = {
|
|
|
146
146
|
}
|
|
147
147
|
};
|
|
148
148
|
const _hoisted_1 = { class: "form-widget-container" };
|
|
149
|
-
const _hoisted_2 = {
|
|
150
|
-
const _hoisted_3 = {
|
|
149
|
+
const _hoisted_2 = {
|
|
151
150
|
key: 0,
|
|
152
151
|
class: "no-widget-hint"
|
|
153
152
|
};
|
|
154
|
-
const
|
|
153
|
+
const _hoisted_3 = { class: "transition-group-el" };
|
|
155
154
|
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
156
|
-
const _component_SubmitButtonRender = resolveComponent("SubmitButtonRender");
|
|
157
155
|
const _component_draggable = resolveComponent("draggable");
|
|
158
156
|
const _component_a_form = resolveComponent("a-form");
|
|
159
157
|
const _component_a_config_provider = resolveComponent("a-config-provider");
|
|
@@ -163,12 +161,6 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
163
161
|
}, {
|
|
164
162
|
default: withCtx(() => [
|
|
165
163
|
createElementVNode("div", _hoisted_1, [
|
|
166
|
-
createElementVNode("div", _hoisted_2, [
|
|
167
|
-
createVNode(_component_SubmitButtonRender, {
|
|
168
|
-
options: $props.formConfig,
|
|
169
|
-
ctx: this
|
|
170
|
-
}, null, 8, ["options"])
|
|
171
|
-
]),
|
|
172
164
|
createVNode(_component_a_form, {
|
|
173
165
|
class: normalizeClass(["full-height-width widget-form tpf-form", [$options.customClass, $options.layoutType + "-layout"]]),
|
|
174
166
|
layout: ["horizontal", "vertical", "inline"].includes($options.labelPosition) ? $options.labelPosition : "horizontal",
|
|
@@ -176,7 +168,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
176
168
|
"validate-on-rule-change": false
|
|
177
169
|
}, {
|
|
178
170
|
default: withCtx(() => [
|
|
179
|
-
$props.designer.widgetList.length === 0 ? (openBlock(), createElementBlock("div",
|
|
171
|
+
$props.designer.widgetList.length === 0 ? (openBlock(), createElementBlock("div", _hoisted_2, toDisplayString(_ctx.i18nt("designer.noWidgetHint")), 1)) : createCommentVNode("", true),
|
|
180
172
|
createElementVNode("div", {
|
|
181
173
|
class: "form-widget-canvas",
|
|
182
174
|
style: normalizeStyle({ minHeight: $options.canvasMinHeight })
|
|
@@ -194,7 +186,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
194
186
|
move: $options.checkMove
|
|
195
187
|
}), {
|
|
196
188
|
item: withCtx(({ element: widget, index }) => [
|
|
197
|
-
createElementVNode("div",
|
|
189
|
+
createElementVNode("div", _hoisted_3, [
|
|
198
190
|
"container" === widget.category ? (openBlock(), createBlock(resolveDynamicComponent($options.getWidgetName(widget)), {
|
|
199
191
|
widget,
|
|
200
192
|
designer: $props.designer,
|
|
@@ -225,7 +217,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
225
217
|
_: 1
|
|
226
218
|
}, 8, ["component-size"]);
|
|
227
219
|
}
|
|
228
|
-
const VFormWidget = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-
|
|
220
|
+
const VFormWidget = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-856e02ed"]]);
|
|
229
221
|
export {
|
|
230
222
|
VFormWidget as default
|
|
231
223
|
};
|
|
@@ -18,11 +18,14 @@ const _sfc_main = {
|
|
|
18
18
|
};
|
|
19
19
|
},
|
|
20
20
|
methods: {
|
|
21
|
-
saveTableData() {
|
|
21
|
+
saveTableData(data) {
|
|
22
22
|
try {
|
|
23
|
-
|
|
23
|
+
console.log("saveTableData", data);
|
|
24
|
+
this.optionModel.dataSource = JSON.parse(data);
|
|
24
25
|
} catch (ex) {
|
|
25
|
-
this.$message.error(
|
|
26
|
+
this.$message.error(
|
|
27
|
+
this.i18nt("designer.hint.invalidOptionsData") + ex.message
|
|
28
|
+
);
|
|
26
29
|
}
|
|
27
30
|
},
|
|
28
31
|
openTableDataEdit() {
|
|
@@ -71,11 +74,9 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
71
74
|
ref: "CodeModalEditorRef",
|
|
72
75
|
mode: "json",
|
|
73
76
|
readonly: false,
|
|
74
|
-
modelValue: $data.tableDataOptions,
|
|
75
|
-
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => $data.tableDataOptions = $event),
|
|
76
77
|
title: _ctx.i18nt("designer.setting.tableDataEdit"),
|
|
77
78
|
onSave: $options.saveTableData
|
|
78
|
-
}, null, 8, ["
|
|
79
|
+
}, null, 8, ["title", "onSave"]),
|
|
79
80
|
!!$props.optionModel.dsEnabled ? (openBlock(), createBlock(_component_HttpEditor, {
|
|
80
81
|
key: 1,
|
|
81
82
|
designer: $props.designer,
|
|
@@ -18,7 +18,7 @@ const _sfc_main = {
|
|
|
18
18
|
{
|
|
19
19
|
title: "序号",
|
|
20
20
|
dataIndex: "index",
|
|
21
|
-
width:
|
|
21
|
+
width: 100,
|
|
22
22
|
fixed: "left",
|
|
23
23
|
rowDrag: true,
|
|
24
24
|
resizable: true,
|
|
@@ -42,6 +42,18 @@ const _sfc_main = {
|
|
|
42
42
|
resizable: true,
|
|
43
43
|
width: 100
|
|
44
44
|
},
|
|
45
|
+
{
|
|
46
|
+
title: "最大宽度",
|
|
47
|
+
dataIndex: "minWidth",
|
|
48
|
+
resizable: true,
|
|
49
|
+
width: 100
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
title: "最小宽度",
|
|
53
|
+
dataIndex: "minWidth",
|
|
54
|
+
resizable: true,
|
|
55
|
+
width: 100
|
|
56
|
+
},
|
|
45
57
|
{
|
|
46
58
|
title: this.i18nt("designer.setting.visibleColumn"),
|
|
47
59
|
dataIndex: "show",
|
|
@@ -57,7 +69,7 @@ const _sfc_main = {
|
|
|
57
69
|
{
|
|
58
70
|
title: "可拖动调整宽度",
|
|
59
71
|
dataIndex: "resizable",
|
|
60
|
-
width:
|
|
72
|
+
width: 120
|
|
61
73
|
},
|
|
62
74
|
{
|
|
63
75
|
title: "超过宽度将自动省略",
|
|
@@ -116,7 +128,7 @@ const _sfc_main = {
|
|
|
116
128
|
sorter: false,
|
|
117
129
|
customRender: "",
|
|
118
130
|
fixed: "",
|
|
119
|
-
align: "
|
|
131
|
+
align: "left",
|
|
120
132
|
title: "标题名",
|
|
121
133
|
dataIndex: "",
|
|
122
134
|
resizable: true,
|
|
@@ -150,6 +162,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
150
162
|
const _component_a_button = resolveComponent("a-button");
|
|
151
163
|
const _component_a_form_item = resolveComponent("a-form-item");
|
|
152
164
|
const _component_a_input = resolveComponent("a-input");
|
|
165
|
+
const _component_a_input_number = resolveComponent("a-input-number");
|
|
153
166
|
const _component_a_switch = resolveComponent("a-switch");
|
|
154
167
|
const _component_a_select_option = resolveComponent("a-select-option");
|
|
155
168
|
const _component_a_select = resolveComponent("a-select");
|
|
@@ -238,33 +251,43 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
238
251
|
value: $props.optionModel.tableColumns[recordIndexs[0]].title,
|
|
239
252
|
"onUpdate:value": ($event) => $props.optionModel.tableColumns[recordIndexs[0]].title = $event
|
|
240
253
|
}, null, 8, ["value", "onUpdate:value"])) : createCommentVNode("", true),
|
|
241
|
-
column.dataIndex === "width" ? (openBlock(), createBlock(
|
|
254
|
+
column.dataIndex === "width" ? (openBlock(), createBlock(_component_a_input_number, {
|
|
242
255
|
key: 2,
|
|
243
256
|
value: $props.optionModel.tableColumns[recordIndexs[0]].width,
|
|
244
257
|
"onUpdate:value": ($event) => $props.optionModel.tableColumns[recordIndexs[0]].width = $event
|
|
245
258
|
}, null, 8, ["value", "onUpdate:value"])) : createCommentVNode("", true),
|
|
246
|
-
column.dataIndex === "
|
|
259
|
+
column.dataIndex === "maxWidth" ? (openBlock(), createBlock(_component_a_input_number, {
|
|
247
260
|
key: 3,
|
|
261
|
+
value: $props.optionModel.tableColumns[recordIndexs[0]].maxWidth,
|
|
262
|
+
"onUpdate:value": ($event) => $props.optionModel.tableColumns[recordIndexs[0]].maxWidth = $event
|
|
263
|
+
}, null, 8, ["value", "onUpdate:value"])) : createCommentVNode("", true),
|
|
264
|
+
column.dataIndex === "minWidth" ? (openBlock(), createBlock(_component_a_input_number, {
|
|
265
|
+
key: 4,
|
|
266
|
+
value: $props.optionModel.tableColumns[recordIndexs[0]].minWidth,
|
|
267
|
+
"onUpdate:value": ($event) => $props.optionModel.tableColumns[recordIndexs[0]].minWidth = $event
|
|
268
|
+
}, null, 8, ["value", "onUpdate:value"])) : createCommentVNode("", true),
|
|
269
|
+
column.dataIndex === "show" ? (openBlock(), createBlock(_component_a_switch, {
|
|
270
|
+
key: 5,
|
|
248
271
|
checked: $props.optionModel.tableColumns[recordIndexs[0]].show,
|
|
249
272
|
"onUpdate:checked": ($event) => $props.optionModel.tableColumns[recordIndexs[0]].show = $event
|
|
250
273
|
}, null, 8, ["checked", "onUpdate:checked"])) : createCommentVNode("", true),
|
|
251
274
|
column.dataIndex === "sorter" ? (openBlock(), createBlock(_component_a_switch, {
|
|
252
|
-
key:
|
|
275
|
+
key: 6,
|
|
253
276
|
checked: $props.optionModel.tableColumns[recordIndexs[0]].sorter,
|
|
254
277
|
"onUpdate:checked": ($event) => $props.optionModel.tableColumns[recordIndexs[0]].sorter = $event
|
|
255
278
|
}, null, 8, ["checked", "onUpdate:checked"])) : createCommentVNode("", true),
|
|
256
279
|
column.dataIndex === "resizable" ? (openBlock(), createBlock(_component_a_switch, {
|
|
257
|
-
key:
|
|
280
|
+
key: 7,
|
|
258
281
|
checked: $props.optionModel.tableColumns[recordIndexs[0]].resizable,
|
|
259
282
|
"onUpdate:checked": ($event) => $props.optionModel.tableColumns[recordIndexs[0]].resizable = $event
|
|
260
283
|
}, null, 8, ["checked", "onUpdate:checked"])) : createCommentVNode("", true),
|
|
261
284
|
column.dataIndex === "ellipsis" ? (openBlock(), createBlock(_component_a_switch, {
|
|
262
|
-
key:
|
|
285
|
+
key: 8,
|
|
263
286
|
checked: $props.optionModel.tableColumns[recordIndexs[0]].ellipsis,
|
|
264
287
|
"onUpdate:checked": ($event) => $props.optionModel.tableColumns[recordIndexs[0]].ellipsis = $event
|
|
265
288
|
}, null, 8, ["checked", "onUpdate:checked"])) : createCommentVNode("", true),
|
|
266
289
|
column.dataIndex === "fixed" ? (openBlock(), createBlock(_component_a_select, {
|
|
267
|
-
key:
|
|
290
|
+
key: 9,
|
|
268
291
|
value: $props.optionModel.tableColumns[recordIndexs[0]].fixed,
|
|
269
292
|
"onUpdate:value": ($event) => $props.optionModel.tableColumns[recordIndexs[0]].fixed = $event,
|
|
270
293
|
allowClear: "",
|
|
@@ -287,14 +310,14 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
287
310
|
_: 2
|
|
288
311
|
}, 1032, ["value", "onUpdate:value"])) : createCommentVNode("", true),
|
|
289
312
|
column.dataIndex === "align" ? (openBlock(), createBlock(_component_a_select, {
|
|
290
|
-
key:
|
|
313
|
+
key: 10,
|
|
291
314
|
style: {},
|
|
292
315
|
value: $props.optionModel.tableColumns[recordIndexs[0]].align,
|
|
293
316
|
"onUpdate:value": ($event) => $props.optionModel.tableColumns[recordIndexs[0]].align = $event,
|
|
294
317
|
options: $data.alignOptions
|
|
295
318
|
}, null, 8, ["value", "onUpdate:value", "options"])) : createCommentVNode("", true),
|
|
296
319
|
column.dataIndex === "customRender" ? (openBlock(), createBlock(_component_a_button, {
|
|
297
|
-
key:
|
|
320
|
+
key: 11,
|
|
298
321
|
onClick: ($event) => $options.showRenderDialog(recordIndexs[0], record, _ctx.dataIndex),
|
|
299
322
|
class: normalizeClass([{ "button-text-highlight": !!record.customRender }]),
|
|
300
323
|
size: "small",
|
|
@@ -305,7 +328,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
305
328
|
])),
|
|
306
329
|
_: 2
|
|
307
330
|
}, 1032, ["onClick", "class"])) : createCommentVNode("", true),
|
|
308
|
-
column.dataIndex === "action" ? (openBlock(), createBlock(_component_a_space, { key:
|
|
331
|
+
column.dataIndex === "action" ? (openBlock(), createBlock(_component_a_space, { key: 12 }, {
|
|
309
332
|
default: withCtx(() => [
|
|
310
333
|
createVNode(_component_a_button, {
|
|
311
334
|
title: _ctx.i18nt("designer.setting.deleteTableColumn"),
|
|
@@ -349,7 +372,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
349
372
|
}, null, 8, ["onSave", "title"])
|
|
350
373
|
], 64);
|
|
351
374
|
}
|
|
352
|
-
const dataTableTableColumnsEditor = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-
|
|
375
|
+
const dataTableTableColumnsEditor = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-7b0fd5cd"]]);
|
|
353
376
|
export {
|
|
354
377
|
dataTableTableColumnsEditor as default
|
|
355
378
|
};
|
|
@@ -14,10 +14,10 @@ const vfCollapse = (ops = {}) => {
|
|
|
14
14
|
title: "标题",
|
|
15
15
|
height: "",
|
|
16
16
|
bodyStyle: "",
|
|
17
|
-
formCode:
|
|
17
|
+
// formCode: '',
|
|
18
18
|
collapseIcon: "xiangshang",
|
|
19
19
|
unCollapseIcon: "xiangxia",
|
|
20
|
-
isCollapse:
|
|
20
|
+
isCollapse: false,
|
|
21
21
|
rightSlotCss: [],
|
|
22
22
|
...ops
|
|
23
23
|
}
|
|
@@ -28,6 +28,10 @@ const _sfc_main = {
|
|
|
28
28
|
parentWidget: Object,
|
|
29
29
|
parentList: Array,
|
|
30
30
|
indexOfParentList: Number,
|
|
31
|
+
model: {
|
|
32
|
+
type: Object,
|
|
33
|
+
default: () => ({})
|
|
34
|
+
},
|
|
31
35
|
subFormRowIndex: {
|
|
32
36
|
/* 子表单组件行索引,从0开始计数 */
|
|
33
37
|
type: Number,
|
|
@@ -133,7 +137,6 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
133
137
|
const _component_TpfCollapseTitle = resolveComponent("TpfCollapseTitle");
|
|
134
138
|
const _component_SvgIcon = resolveComponent("SvgIcon");
|
|
135
139
|
const _component_a_space = resolveComponent("a-space");
|
|
136
|
-
const _component_VFormRender = resolveComponent("VFormRender");
|
|
137
140
|
const _component_container_item_wrapper = resolveComponent("container-item-wrapper");
|
|
138
141
|
return withDirectives((openBlock(), createBlock(_component_container_item_wrapper, { widget: $props.widget }, {
|
|
139
142
|
default: withCtx(() => [
|
|
@@ -168,7 +171,8 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
168
171
|
"parent-widget": $props.widget,
|
|
169
172
|
"sub-form-row-id": $props.subFormRowId,
|
|
170
173
|
"sub-form-row-index": $props.subFormRowIndex,
|
|
171
|
-
"sub-form-col-index": $props.subFormColIndex
|
|
174
|
+
"sub-form-col-index": $props.subFormColIndex,
|
|
175
|
+
data: $props.model[$props.widget.options.name]
|
|
172
176
|
}, createSlots({ _: 2 }, [
|
|
173
177
|
renderList(Object.keys(_ctx.$slots), (slot) => {
|
|
174
178
|
return {
|
|
@@ -178,7 +182,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
178
182
|
])
|
|
179
183
|
};
|
|
180
184
|
})
|
|
181
|
-
]), 1032, ["widget", "parent-list", "index-of-parent-list", "parent-widget", "sub-form-row-id", "sub-form-row-index", "sub-form-col-index"])) : (openBlock(), createBlock(resolveDynamicComponent(subWidget.type + "-widget"), {
|
|
185
|
+
]), 1032, ["widget", "parent-list", "index-of-parent-list", "parent-widget", "sub-form-row-id", "sub-form-row-index", "sub-form-col-index", "data"])) : (openBlock(), createBlock(resolveDynamicComponent(subWidget.type + "-widget"), {
|
|
182
186
|
field: subWidget,
|
|
183
187
|
designer: null,
|
|
184
188
|
key: swIdx,
|
|
@@ -213,15 +217,6 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
213
217
|
...JSON.parse($props.widget.options.bodyStyle || "{}")
|
|
214
218
|
})
|
|
215
219
|
}, [
|
|
216
|
-
createVNode(_component_VFormRender, {
|
|
217
|
-
ref: "dFormRef",
|
|
218
|
-
"form-json": $props.formJson,
|
|
219
|
-
"form-data": $props.formData,
|
|
220
|
-
"global-dsv": $props.globalDsv,
|
|
221
|
-
"parent-form": $props.parentFormRef,
|
|
222
|
-
"disabled-mode": $props.widget.options.disabledMode,
|
|
223
|
-
"dynamic-creation": true
|
|
224
|
-
}, null, 8, ["form-json", "form-data", "global-dsv", "parent-form", "disabled-mode"]),
|
|
225
220
|
!!$props.widget.defaultSlotsList && $props.widget.defaultSlotsList.length > 0 ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList($props.widget.defaultSlotsList, (subWidget, swIdx) => {
|
|
226
221
|
return openBlock(), createElementBlock(Fragment, null, [
|
|
227
222
|
"container" === subWidget.category ? (openBlock(), createBlock(resolveDynamicComponent(_ctx.getComponentByContainer(subWidget)), {
|
|
@@ -232,7 +227,9 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
232
227
|
"parent-widget": $props.widget,
|
|
233
228
|
"sub-form-row-id": $props.subFormRowId,
|
|
234
229
|
"sub-form-row-index": $props.subFormRowIndex,
|
|
235
|
-
"sub-form-col-index": $props.subFormColIndex
|
|
230
|
+
"sub-form-col-index": $props.subFormColIndex,
|
|
231
|
+
data: $props.model[subWidget.options.name],
|
|
232
|
+
model: $props.model
|
|
236
233
|
}, createSlots({ _: 2 }, [
|
|
237
234
|
renderList(Object.keys(_ctx.$slots), (slot) => {
|
|
238
235
|
return {
|
|
@@ -242,7 +239,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
242
239
|
])
|
|
243
240
|
};
|
|
244
241
|
})
|
|
245
|
-
]), 1032, ["widget", "parent-list", "index-of-parent-list", "parent-widget", "sub-form-row-id", "sub-form-row-index", "sub-form-col-index"])) : (openBlock(), createBlock(resolveDynamicComponent(subWidget.type + "-widget"), {
|
|
242
|
+
]), 1032, ["widget", "parent-list", "index-of-parent-list", "parent-widget", "sub-form-row-id", "sub-form-row-index", "sub-form-col-index", "data", "model"])) : (openBlock(), createBlock(resolveDynamicComponent(subWidget.type + "-widget"), {
|
|
246
243
|
field: subWidget,
|
|
247
244
|
designer: null,
|
|
248
245
|
key: swIdx,
|
|
@@ -262,7 +259,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
262
259
|
], 64);
|
|
263
260
|
}), 256)) : createCommentVNode("", true)
|
|
264
261
|
], 4), [
|
|
265
|
-
[vShow,
|
|
262
|
+
[vShow, !$props.widget.options.isCollapse]
|
|
266
263
|
])
|
|
267
264
|
]),
|
|
268
265
|
_: 3
|
|
@@ -274,7 +271,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
274
271
|
[vShow, !$props.widget.options.hidden]
|
|
275
272
|
]);
|
|
276
273
|
}
|
|
277
|
-
const vfCollapseItem = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-
|
|
274
|
+
const vfCollapseItem = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-d81bc2ac"]]);
|
|
278
275
|
export {
|
|
279
276
|
vfCollapseItem as default
|
|
280
277
|
};
|
|
@@ -18,6 +18,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
18
18
|
key: item.key,
|
|
19
19
|
type: item.type,
|
|
20
20
|
danger: item.danger,
|
|
21
|
+
class: "tpf-button",
|
|
21
22
|
disabled: _ctx.handleDisabled(item),
|
|
22
23
|
onClick: ($event) => _ctx.handleClick(item)
|
|
23
24
|
}, {
|
|
@@ -37,7 +38,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
37
38
|
})
|
|
38
39
|
], 6);
|
|
39
40
|
}
|
|
40
|
-
const ActionButtonListRender = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-
|
|
41
|
+
const ActionButtonListRender = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-008c5a21"]]);
|
|
41
42
|
export {
|
|
42
43
|
ActionButtonListRender as default
|
|
43
44
|
};
|
|
@@ -25,6 +25,10 @@ const _sfc_main = defineComponent({
|
|
|
25
25
|
type: String,
|
|
26
26
|
default: "center",
|
|
27
27
|
validator: (value) => ["start", "center", "end", "space-between"].includes(value)
|
|
28
|
+
},
|
|
29
|
+
designState: {
|
|
30
|
+
type: Boolean,
|
|
31
|
+
default: false
|
|
28
32
|
}
|
|
29
33
|
},
|
|
30
34
|
setup(props) {
|
|
@@ -35,6 +39,7 @@ const _sfc_main = defineComponent({
|
|
|
35
39
|
() => props.buttonList.filter((item) => !handleHidden(item))
|
|
36
40
|
);
|
|
37
41
|
const handleClick = async (item) => {
|
|
42
|
+
if (props.designState) return;
|
|
38
43
|
if (!item.onClick) return;
|
|
39
44
|
try {
|
|
40
45
|
await executeFunction({
|
package/src/lang/en-US.js
CHANGED
package/src/lang/en-US_render.js
CHANGED
package/src/lang/zh-CN.js
CHANGED
package/src/lang/zh-CN_render.js
CHANGED