@kp-ui/lowcode 1.0.68 → 1.0.69
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/package.json +2 -2
- package/packages/tmgc2-share/src/components/TpfCodeEditor/code-editor.vue.js +7 -0
- package/packages/tmgc2-share/src/components/TpfCodeEditor/code-editor.vue2.js +164 -0
- package/packages/tmgc2-share/src/components/TpfModal/index.vue.js +7 -0
- package/packages/tmgc2-share/src/components/TpfModal/index.vue2.js +173 -0
- package/packages/tmgc2-share/src/components/TpfModal/index.vue3.js +1 -0
- package/render.js +6 -7
- package/src/components/code-editor/code-modal-editor.vue.js +54 -67
- package/src/components/code-editor/code-modal-editor.vue2.js +1 -42
- package/src/components/form-designer/form-widget/index.vue.js +5 -3
- package/src/components/form-designer/setting-panel/form-setting.vue.js +1 -1
- package/src/components/form-designer/setting-panel/index.vue.js +24 -71
- package/src/components/form-designer/setting-panel/property-editor/button-list-editor.vue.js +2 -2
- 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-selections-editor.vue.js +2 -2
- package/src/components/form-designer/setting-panel/property-editor/container-data-table/data-table-tableColumns-editor.vue.js +63 -62
- package/src/components/form-designer/setting-panel/property-editor/field-dropdown/dropdown-menuList-editor.vue.js +2 -2
- package/src/components/form-designer/toolbar-panel/index.vue.js +99 -108
- package/src/components/form-designer/widget-panel/index.vue.js +4 -2
- package/src/components/form-render/dynamic-dialog.vue.js +5 -6
- package/src/components/http-editor/index.vue.js +6 -5
- package/src/components/http-editor/index.vue2.js +2 -2
- package/src/components/public/ActionButtonListDialog.vue2.js +2 -2
- package/src/mixins/useDataTableMixin.js +8 -5
- package/styles/style.css +1 -1
- package/types/src/lang/en-US.d.ts +440 -0
- package/types/src/lang/en-US.d.ts.map +1 -0
- package/types/src/lang/en-US_extension.d.ts +24 -0
- package/types/src/lang/en-US_extension.d.ts.map +1 -0
- package/types/src/lang/en-US_render.d.ts +39 -0
- package/types/src/lang/en-US_render.d.ts.map +1 -0
- package/types/src/lang/zh-CN.d.ts +450 -0
- package/types/src/lang/zh-CN.d.ts.map +1 -0
- package/types/src/lang/zh-CN_extension.d.ts +24 -0
- package/types/src/lang/zh-CN_extension.d.ts.map +1 -0
- package/types/src/lang/zh-CN_render.d.ts +39 -0
- package/types/src/lang/zh-CN_render.d.ts.map +1 -0
- package/types/src/utils/i18n.d.ts +14 -0
- package/types/src/utils/i18n.d.ts.map +1 -0
|
@@ -6,7 +6,9 @@ import WidgetProperties, { propertyRegistered } from "./propertyRegister.js";
|
|
|
6
6
|
import { addWindowResizeHandler } from "../../../utils/util.js";
|
|
7
7
|
import i18n from "../../../utils/i18n.js";
|
|
8
8
|
import emitter from "../../../utils/emitter.js";
|
|
9
|
-
import
|
|
9
|
+
import _sfc_main$1 from "../../code-editor/code-modal-editor.vue.js";
|
|
10
|
+
import { TpfConfigProvider } from "tmgc2-share";
|
|
11
|
+
import { resolveComponent, createBlock, openBlock, withCtx, createVNode, createCommentVNode, createElementVNode, normalizeStyle, withModifiers, createElementBlock, Fragment, renderList, resolveDynamicComponent } from "vue";
|
|
10
12
|
/* empty css */
|
|
11
13
|
/* empty css */
|
|
12
14
|
import _export_sfc from "../../../../_virtual/_plugin-vue_export-helper.js";
|
|
@@ -17,7 +19,9 @@ const _sfc_main = {
|
|
|
17
19
|
mixins: [i18n, emitter],
|
|
18
20
|
components: {
|
|
19
21
|
CodeEditor,
|
|
22
|
+
TpfConfigProvider,
|
|
20
23
|
FormSetting,
|
|
24
|
+
CodeModalEditor: _sfc_main$1,
|
|
21
25
|
// DataSourceSetting,
|
|
22
26
|
FormCrudSetting,
|
|
23
27
|
...comps
|
|
@@ -167,10 +171,11 @@ const _sfc_main = {
|
|
|
167
171
|
if (eventName === "onValidate" && !this.optionModel["onValidate"]) {
|
|
168
172
|
this.eventHandlerCode = " /* sample code */\n /*\n if ((value > 100) || (value < 0)) {\n return Promise.reject('error message') //fail\n } else {\n return Promise.resolve(); //pass\n }\n */";
|
|
169
173
|
}
|
|
170
|
-
this.
|
|
174
|
+
console.log(this.eventHandlerCode);
|
|
175
|
+
this.$refs.CodeModalEditorRef.open(this.eventHandlerCode);
|
|
171
176
|
},
|
|
172
|
-
saveEventHandler() {
|
|
173
|
-
const codeHints = this.$refs.ecEditor.getEditorAnnotations();
|
|
177
|
+
saveEventHandler(value) {
|
|
178
|
+
const codeHints = this.$refs.CodeModalEditorRef.codeEditorRef.ecEditor.getEditorAnnotations();
|
|
174
179
|
let syntaxErrorFlag = false;
|
|
175
180
|
if (!!codeHints && codeHints.length > 0) {
|
|
176
181
|
codeHints.forEach((chItem) => {
|
|
@@ -185,15 +190,13 @@ const _sfc_main = {
|
|
|
185
190
|
}
|
|
186
191
|
if (this.curEventName.includes(".")) {
|
|
187
192
|
const [a, b] = this.curEventName.split(".");
|
|
188
|
-
this.selectedWidget.options[a][b] =
|
|
193
|
+
this.selectedWidget.options[a][b] = value;
|
|
189
194
|
} else {
|
|
190
|
-
this.selectedWidget.options[this.curEventName] =
|
|
195
|
+
this.selectedWidget.options[this.curEventName] = value;
|
|
191
196
|
}
|
|
192
|
-
this.showWidgetEventDialogFlag = false;
|
|
193
197
|
}
|
|
194
198
|
}
|
|
195
199
|
};
|
|
196
|
-
const _hoisted_1 = { class: "dialog-footer" };
|
|
197
200
|
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
198
201
|
const _component_a_collapse_panel = resolveComponent("a-collapse-panel");
|
|
199
202
|
const _component_a_collapse = resolveComponent("a-collapse");
|
|
@@ -203,16 +206,10 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
203
206
|
const _component_form_setting = resolveComponent("form-setting");
|
|
204
207
|
const _component_FormCrudSetting = resolveComponent("FormCrudSetting");
|
|
205
208
|
const _component_a_tabs = resolveComponent("a-tabs");
|
|
206
|
-
const
|
|
207
|
-
const _component_code_editor = resolveComponent("code-editor");
|
|
208
|
-
const _component_a_button = resolveComponent("a-button");
|
|
209
|
-
const _component_a_modal = resolveComponent("a-modal");
|
|
209
|
+
const _component_CodeModalEditor = resolveComponent("CodeModalEditor");
|
|
210
210
|
const _component_a_layout = resolveComponent("a-layout");
|
|
211
|
-
const
|
|
212
|
-
return openBlock(), createBlock(
|
|
213
|
-
"component-size": "small",
|
|
214
|
-
input: { autocomplete: "off" }
|
|
215
|
-
}, {
|
|
211
|
+
const _component_TpfConfigProvider = resolveComponent("TpfConfigProvider");
|
|
212
|
+
return openBlock(), createBlock(_component_TpfConfigProvider, null, {
|
|
216
213
|
default: withCtx(() => [
|
|
217
214
|
createVNode(_component_a_layout, { class: "panel-container" }, {
|
|
218
215
|
default: withCtx(() => [
|
|
@@ -286,6 +283,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
286
283
|
}, 8, ["header"])) : createCommentVNode("", true),
|
|
287
284
|
$options.showEventCollapse() && $options.showCollapse($data.eventProps) ? (openBlock(), createBlock(_component_a_collapse_panel, {
|
|
288
285
|
key: "3",
|
|
286
|
+
class: "eventPanel",
|
|
289
287
|
header: _ctx.i18nt("designer.setting.事件属性")
|
|
290
288
|
}, {
|
|
291
289
|
default: withCtx(() => [
|
|
@@ -364,6 +362,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
364
362
|
}, 8, ["header"])) : createCommentVNode("", true),
|
|
365
363
|
$options.showEventCollapse() && $options.showCollapse($data.eventProps) ? (openBlock(), createBlock(_component_a_collapse_panel, {
|
|
366
364
|
key: "3",
|
|
365
|
+
class: "eventPanel",
|
|
367
366
|
header: _ctx.i18nt("designer.setting.事件属性")
|
|
368
367
|
}, {
|
|
369
368
|
default: withCtx(() => [
|
|
@@ -432,60 +431,14 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
432
431
|
]),
|
|
433
432
|
_: 1
|
|
434
433
|
}, 8, ["activeKey"]),
|
|
435
|
-
createVNode(
|
|
434
|
+
createVNode(_component_CodeModalEditor, {
|
|
435
|
+
eventHeader: $data.eventHeader,
|
|
436
|
+
ref: "CodeModalEditorRef",
|
|
436
437
|
title: _ctx.i18nt("designer.setting.editWidgetEventHandler"),
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
"append-to-body": "",
|
|
442
|
-
"close-on-click-modal": false,
|
|
443
|
-
"close-on-press-escape": false,
|
|
444
|
-
"destroy-on-close": true,
|
|
445
|
-
width: 800
|
|
446
|
-
}, {
|
|
447
|
-
footer: withCtx(() => [
|
|
448
|
-
createElementVNode("div", _hoisted_1, [
|
|
449
|
-
createVNode(_component_a_button, {
|
|
450
|
-
onClick: _cache[8] || (_cache[8] = ($event) => $data.showWidgetEventDialogFlag = false)
|
|
451
|
-
}, {
|
|
452
|
-
default: withCtx(() => [
|
|
453
|
-
createTextVNode(toDisplayString(_ctx.i18nt("designer.hint.cancel")), 1)
|
|
454
|
-
]),
|
|
455
|
-
_: 1
|
|
456
|
-
}),
|
|
457
|
-
createVNode(_component_a_button, {
|
|
458
|
-
type: "primary",
|
|
459
|
-
onClick: $options.saveEventHandler
|
|
460
|
-
}, {
|
|
461
|
-
default: withCtx(() => [
|
|
462
|
-
createTextVNode(toDisplayString(_ctx.i18nt("designer.hint.confirm")), 1)
|
|
463
|
-
]),
|
|
464
|
-
_: 1
|
|
465
|
-
}, 8, ["onClick"])
|
|
466
|
-
])
|
|
467
|
-
]),
|
|
468
|
-
default: withCtx(() => [
|
|
469
|
-
createVNode(_component_a_alert, {
|
|
470
|
-
type: "info",
|
|
471
|
-
closable: false,
|
|
472
|
-
message: $data.eventHeader
|
|
473
|
-
}, null, 8, ["message"]),
|
|
474
|
-
createVNode(_component_code_editor, {
|
|
475
|
-
mode: "javascript",
|
|
476
|
-
readonly: false,
|
|
477
|
-
modelValue: $data.eventHandlerCode,
|
|
478
|
-
"onUpdate:modelValue": _cache[7] || (_cache[7] = ($event) => $data.eventHandlerCode = $event),
|
|
479
|
-
ref: "ecEditor"
|
|
480
|
-
}, null, 8, ["modelValue"]),
|
|
481
|
-
createVNode(_component_a_alert, {
|
|
482
|
-
type: "info",
|
|
483
|
-
closable: false,
|
|
484
|
-
message: "}"
|
|
485
|
-
})
|
|
486
|
-
]),
|
|
487
|
-
_: 1
|
|
488
|
-
}, 8, ["title", "visible"])
|
|
438
|
+
mode: "json",
|
|
439
|
+
readonly: false,
|
|
440
|
+
onSave: $options.saveEventHandler
|
|
441
|
+
}, null, 8, ["eventHeader", "title", "onSave"])
|
|
489
442
|
]),
|
|
490
443
|
_: 1
|
|
491
444
|
})
|
|
@@ -493,7 +446,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
493
446
|
_: 1
|
|
494
447
|
});
|
|
495
448
|
}
|
|
496
|
-
const SettingPanel = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-
|
|
449
|
+
const SettingPanel = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-63b257d3"]]);
|
|
497
450
|
export {
|
|
498
451
|
SettingPanel as default
|
|
499
452
|
};
|
package/src/components/form-designer/setting-panel/property-editor/button-list-editor.vue.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import i18n from "../../../../utils/i18n.js";
|
|
2
|
-
import
|
|
2
|
+
import _sfc_main$1 from "../../../code-editor/code-modal-editor.vue.js";
|
|
3
3
|
import { generateId } from "../../../../utils/util.js";
|
|
4
4
|
import { cloneDeep } from "lodash-es";
|
|
5
5
|
import ActionButtonListDialog from "../../../public/ActionButtonListDialog.vue.js";
|
|
@@ -16,7 +16,7 @@ const _sfc_main = {
|
|
|
16
16
|
},
|
|
17
17
|
components: {
|
|
18
18
|
ActionButtonListDialog,
|
|
19
|
-
CodeModalEditor
|
|
19
|
+
CodeModalEditor: _sfc_main$1
|
|
20
20
|
},
|
|
21
21
|
data() {
|
|
22
22
|
return {
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import i18n from "../../../../../utils/i18n.js";
|
|
2
2
|
import HttpEditor from "../../../../http-editor/index.vue.js";
|
|
3
|
-
import
|
|
3
|
+
import _sfc_main$1 from "../../../../code-editor/code-modal-editor.vue.js";
|
|
4
4
|
import { resolveComponent, createElementBlock, openBlock, Fragment, createVNode, createBlock, createCommentVNode, withCtx, createTextVNode, toDisplayString } from "vue";
|
|
5
5
|
import _export_sfc from "../../../../../../_virtual/_plugin-vue_export-helper.js";
|
|
6
6
|
const _sfc_main = {
|
|
7
7
|
name: "data-table-dsEnabled-editor",
|
|
8
8
|
mixins: [i18n],
|
|
9
|
-
components: { HttpEditor, CodeModalEditor },
|
|
9
|
+
components: { HttpEditor, CodeModalEditor: _sfc_main$1 },
|
|
10
10
|
props: {
|
|
11
11
|
designer: Object,
|
|
12
12
|
selectedWidget: Object,
|
|
@@ -18,10 +18,9 @@ const _sfc_main = {
|
|
|
18
18
|
};
|
|
19
19
|
},
|
|
20
20
|
methods: {
|
|
21
|
-
|
|
21
|
+
handleUpdate(value) {
|
|
22
22
|
try {
|
|
23
|
-
|
|
24
|
-
this.optionModel.dataSource = JSON.parse(data);
|
|
23
|
+
this.optionModel.dataSource = JSON.parse(value);
|
|
25
24
|
} catch (ex) {
|
|
26
25
|
this.$message.error(
|
|
27
26
|
this.i18nt("designer.hint.invalidOptionsData") + ex.message
|
|
@@ -30,6 +29,7 @@ const _sfc_main = {
|
|
|
30
29
|
},
|
|
31
30
|
openTableDataEdit() {
|
|
32
31
|
this.tableDataOptions = JSON.stringify(this.optionModel.dataSource, null, " ");
|
|
32
|
+
console.log(this.tableDataOptions);
|
|
33
33
|
this.$refs.CodeModalEditorRef.open(this.tableDataOptions);
|
|
34
34
|
}
|
|
35
35
|
}
|
|
@@ -74,8 +74,9 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
74
74
|
ref: "CodeModalEditorRef",
|
|
75
75
|
mode: "json",
|
|
76
76
|
readonly: false,
|
|
77
|
+
isShowEventHeader: false,
|
|
77
78
|
title: _ctx.i18nt("designer.setting.tableDataEdit"),
|
|
78
|
-
onSave: $options.
|
|
79
|
+
onSave: $options.handleUpdate
|
|
79
80
|
}, null, 8, ["title", "onSave"]),
|
|
80
81
|
!!$props.optionModel.dsEnabled ? (openBlock(), createBlock(_component_HttpEditor, {
|
|
81
82
|
key: 1,
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import i18n from "../../../../../utils/i18n.js";
|
|
2
|
-
import
|
|
2
|
+
import _sfc_main$1 from "../../../../code-editor/code-modal-editor.vue.js";
|
|
3
3
|
import { resolveComponent, createElementBlock, openBlock, Fragment, createVNode, withCtx, createBlock, createCommentVNode, createTextVNode, normalizeClass, toDisplayString } from "vue";
|
|
4
4
|
/* empty css */
|
|
5
5
|
import _export_sfc from "../../../../../../_virtual/_plugin-vue_export-helper.js";
|
|
6
6
|
const _sfc_main = {
|
|
7
7
|
name: "rowSelection-editor",
|
|
8
8
|
mixins: [i18n],
|
|
9
|
-
components: { CodeModalEditor },
|
|
9
|
+
components: { CodeModalEditor: _sfc_main$1 },
|
|
10
10
|
props: {
|
|
11
11
|
designer: Object,
|
|
12
12
|
selectedWidget: Object,
|
|
@@ -1,12 +1,18 @@
|
|
|
1
1
|
import i18n from "../../../../../utils/i18n.js";
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
2
|
+
import _sfc_main$1 from "../../../../code-editor/code-modal-editor.vue.js";
|
|
3
|
+
import { cloneDeep } from "lodash-es";
|
|
4
|
+
import { defineAsyncComponent, resolveComponent, createElementBlock, openBlock, Fragment, createVNode, withCtx, createTextVNode, toDisplayString, createElementVNode, createBlock, createCommentVNode, normalizeClass } from "vue";
|
|
4
5
|
/* empty css */
|
|
5
6
|
import _export_sfc from "../../../../../../_virtual/_plugin-vue_export-helper.js";
|
|
6
7
|
const _sfc_main = {
|
|
7
8
|
name: "tableColumns-editor",
|
|
8
9
|
mixins: [i18n],
|
|
9
|
-
components: {
|
|
10
|
+
components: {
|
|
11
|
+
CodeModalEditor: _sfc_main$1,
|
|
12
|
+
TpfModal: defineAsyncComponent(
|
|
13
|
+
() => import("../../../../../../packages/tmgc2-share/src/components/TpfModal/index.vue.js")
|
|
14
|
+
)
|
|
15
|
+
},
|
|
10
16
|
props: {
|
|
11
17
|
designer: Object,
|
|
12
18
|
selectedWidget: Object,
|
|
@@ -14,6 +20,7 @@ const _sfc_main = {
|
|
|
14
20
|
},
|
|
15
21
|
data() {
|
|
16
22
|
return {
|
|
23
|
+
tableColumns: [],
|
|
17
24
|
columns: [
|
|
18
25
|
{
|
|
19
26
|
title: "序号",
|
|
@@ -107,7 +114,7 @@ const _sfc_main = {
|
|
|
107
114
|
this.$refs.CodeModalEditorRef.open(record.customRender);
|
|
108
115
|
},
|
|
109
116
|
saveColumnRender(value) {
|
|
110
|
-
this.
|
|
117
|
+
this.tableColumns[this.currentRecordIndexs].customRender = value;
|
|
111
118
|
},
|
|
112
119
|
addCol() {
|
|
113
120
|
const newRow = {
|
|
@@ -124,24 +131,26 @@ const _sfc_main = {
|
|
|
124
131
|
resizable: true,
|
|
125
132
|
showSorterTooltip: false
|
|
126
133
|
};
|
|
127
|
-
this.
|
|
134
|
+
this.tableColumns.push(newRow);
|
|
128
135
|
this.designer.emitHistoryChange();
|
|
129
136
|
},
|
|
130
137
|
handleDelete(index) {
|
|
131
|
-
if (this.
|
|
138
|
+
if (this.tableColumns.length === 1) {
|
|
132
139
|
this.$message.warning(
|
|
133
140
|
this.i18nt("designer.setting.onlyOneColumnCannotBeDeleted")
|
|
134
141
|
);
|
|
135
142
|
return false;
|
|
136
143
|
}
|
|
137
|
-
this.
|
|
144
|
+
this.tableColumns.splice(index, 1);
|
|
138
145
|
},
|
|
139
146
|
// 确认表格列更改
|
|
140
147
|
colSubmit() {
|
|
148
|
+
this.optionModel.tableColumns = cloneDeep(this.tableColumns);
|
|
141
149
|
this.dialogVisible = false;
|
|
142
150
|
},
|
|
143
151
|
openSetting() {
|
|
144
152
|
this.dialogVisible = true;
|
|
153
|
+
this.tableColumns = cloneDeep(this.optionModel.tableColumns);
|
|
145
154
|
}
|
|
146
155
|
}
|
|
147
156
|
};
|
|
@@ -151,7 +160,6 @@ const _hoisted_2 = {
|
|
|
151
160
|
style: { "text-align": "center" }
|
|
152
161
|
};
|
|
153
162
|
const _hoisted_3 = { class: "add-btn" };
|
|
154
|
-
const _hoisted_4 = { class: "dialog-footer" };
|
|
155
163
|
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
156
164
|
const _component_a_button = resolveComponent("a-button");
|
|
157
165
|
const _component_a_form_item = resolveComponent("a-form-item");
|
|
@@ -161,7 +169,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
161
169
|
const _component_a_select = resolveComponent("a-select");
|
|
162
170
|
const _component_a_space = resolveComponent("a-space");
|
|
163
171
|
const _component_s_table = resolveComponent("s-table");
|
|
164
|
-
const
|
|
172
|
+
const _component_TpfModal = resolveComponent("TpfModal");
|
|
165
173
|
const _component_CodeModalEditor = resolveComponent("CodeModalEditor");
|
|
166
174
|
return openBlock(), createElementBlock(Fragment, null, [
|
|
167
175
|
createVNode(_component_a_form_item, {
|
|
@@ -181,52 +189,45 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
181
189
|
]),
|
|
182
190
|
_: 1
|
|
183
191
|
}, 8, ["label"]),
|
|
184
|
-
createVNode(
|
|
192
|
+
createVNode(_component_TpfModal, {
|
|
185
193
|
title: _ctx.i18nt("designer.setting.tableColEdit"),
|
|
186
194
|
visible: $data.dialogVisible,
|
|
187
195
|
"onUpdate:visible": _cache[2] || (_cache[2] = ($event) => $data.dialogVisible = $event),
|
|
188
|
-
"
|
|
189
|
-
"close-on-click-modal": false,
|
|
190
|
-
"close-on-press-escape": false,
|
|
191
|
-
"destroy-on-close": true,
|
|
192
|
-
width: "1200px",
|
|
193
|
-
"aria-hidden": "false",
|
|
194
|
-
wrapClassName: "table-columns-modal"
|
|
196
|
+
width: "1200px"
|
|
195
197
|
}, {
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
}, 8, ["onClick"])
|
|
217
|
-
])
|
|
198
|
+
footerRight: withCtx(() => [
|
|
199
|
+
createVNode(_component_a_button, {
|
|
200
|
+
size: "default",
|
|
201
|
+
onClick: _cache[1] || (_cache[1] = ($event) => $data.dialogVisible = false)
|
|
202
|
+
}, {
|
|
203
|
+
default: withCtx(() => [
|
|
204
|
+
createTextVNode(toDisplayString(_ctx.i18nt("designer.hint.cancel")), 1)
|
|
205
|
+
]),
|
|
206
|
+
_: 1
|
|
207
|
+
}),
|
|
208
|
+
createVNode(_component_a_button, {
|
|
209
|
+
size: "default",
|
|
210
|
+
type: "primary",
|
|
211
|
+
onClick: $options.colSubmit
|
|
212
|
+
}, {
|
|
213
|
+
default: withCtx(() => [
|
|
214
|
+
createTextVNode(toDisplayString(_ctx.i18nt("designer.hint.confirm")), 1)
|
|
215
|
+
]),
|
|
216
|
+
_: 1
|
|
217
|
+
}, 8, ["onClick"])
|
|
218
218
|
]),
|
|
219
219
|
default: withCtx(() => [
|
|
220
220
|
createElementVNode("div", _hoisted_1, [
|
|
221
221
|
createVNode(_component_s_table, {
|
|
222
222
|
class: "tpf-surely-table",
|
|
223
223
|
"aria-hidden": "false",
|
|
224
|
-
dataSource: $
|
|
224
|
+
dataSource: $data.tableColumns,
|
|
225
225
|
style: { "width": "100%" },
|
|
226
226
|
deepWatchDataSource: "",
|
|
227
227
|
"cell-style": { padding: "0" },
|
|
228
228
|
height: "600",
|
|
229
229
|
id: "singleTable",
|
|
230
|
+
size: "medium",
|
|
230
231
|
scroll: { y: 300, x: 300 },
|
|
231
232
|
pagination: false,
|
|
232
233
|
resizable: "",
|
|
@@ -236,50 +237,50 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
236
237
|
bodyCell: withCtx(({ column, record, index, recordIndexs }) => [
|
|
237
238
|
column.dataIndex === "dataIndex" ? (openBlock(), createBlock(_component_a_input, {
|
|
238
239
|
key: 0,
|
|
239
|
-
value: $
|
|
240
|
-
"onUpdate:value": ($event) => $
|
|
240
|
+
value: $data.tableColumns[recordIndexs[0]].dataIndex,
|
|
241
|
+
"onUpdate:value": ($event) => $data.tableColumns[recordIndexs[0]].dataIndex = $event
|
|
241
242
|
}, null, 8, ["value", "onUpdate:value"])) : createCommentVNode("", true),
|
|
242
243
|
column.dataIndex === "title" ? (openBlock(), createBlock(_component_a_input, {
|
|
243
244
|
key: 1,
|
|
244
|
-
value: $
|
|
245
|
-
"onUpdate:value": ($event) => $
|
|
245
|
+
value: $data.tableColumns[recordIndexs[0]].title,
|
|
246
|
+
"onUpdate:value": ($event) => $data.tableColumns[recordIndexs[0]].title = $event
|
|
246
247
|
}, null, 8, ["value", "onUpdate:value"])) : createCommentVNode("", true),
|
|
247
248
|
column.dataIndex === "width" ? (openBlock(), createElementBlock("div", _hoisted_2, [
|
|
248
249
|
createVNode(_component_a_switch, {
|
|
249
250
|
"checked-children": "自动宽度",
|
|
250
|
-
checked: $
|
|
251
|
-
"onUpdate:checked": ($event) => $
|
|
251
|
+
checked: $data.tableColumns[recordIndexs[0]].isAutoWidth,
|
|
252
|
+
"onUpdate:checked": ($event) => $data.tableColumns[recordIndexs[0]].isAutoWidth = $event
|
|
252
253
|
}, null, 8, ["checked", "onUpdate:checked"]),
|
|
253
254
|
!record.isAutoWidth ? (openBlock(), createBlock(_component_a_input, {
|
|
254
255
|
key: 0,
|
|
255
|
-
value: $
|
|
256
|
-
"onUpdate:value": ($event) => $
|
|
256
|
+
value: $data.tableColumns[recordIndexs[0]].width,
|
|
257
|
+
"onUpdate:value": ($event) => $data.tableColumns[recordIndexs[0]].width = $event
|
|
257
258
|
}, null, 8, ["value", "onUpdate:value"])) : createCommentVNode("", true)
|
|
258
259
|
])) : createCommentVNode("", true),
|
|
259
260
|
column.dataIndex === "show" ? (openBlock(), createBlock(_component_a_switch, {
|
|
260
261
|
key: 3,
|
|
261
|
-
checked: $
|
|
262
|
-
"onUpdate:checked": ($event) => $
|
|
262
|
+
checked: $data.tableColumns[recordIndexs[0]].show,
|
|
263
|
+
"onUpdate:checked": ($event) => $data.tableColumns[recordIndexs[0]].show = $event
|
|
263
264
|
}, null, 8, ["checked", "onUpdate:checked"])) : createCommentVNode("", true),
|
|
264
265
|
column.dataIndex === "sorter" ? (openBlock(), createBlock(_component_a_switch, {
|
|
265
266
|
key: 4,
|
|
266
|
-
checked: $
|
|
267
|
-
"onUpdate:checked": ($event) => $
|
|
267
|
+
checked: $data.tableColumns[recordIndexs[0]].sorter,
|
|
268
|
+
"onUpdate:checked": ($event) => $data.tableColumns[recordIndexs[0]].sorter = $event
|
|
268
269
|
}, null, 8, ["checked", "onUpdate:checked"])) : createCommentVNode("", true),
|
|
269
270
|
column.dataIndex === "resizable" ? (openBlock(), createBlock(_component_a_switch, {
|
|
270
271
|
key: 5,
|
|
271
|
-
checked: $
|
|
272
|
-
"onUpdate:checked": ($event) => $
|
|
272
|
+
checked: $data.tableColumns[recordIndexs[0]].resizable,
|
|
273
|
+
"onUpdate:checked": ($event) => $data.tableColumns[recordIndexs[0]].resizable = $event
|
|
273
274
|
}, null, 8, ["checked", "onUpdate:checked"])) : createCommentVNode("", true),
|
|
274
275
|
column.dataIndex === "ellipsis" ? (openBlock(), createBlock(_component_a_switch, {
|
|
275
276
|
key: 6,
|
|
276
|
-
checked: $
|
|
277
|
-
"onUpdate:checked": ($event) => $
|
|
277
|
+
checked: $data.tableColumns[recordIndexs[0]].ellipsis,
|
|
278
|
+
"onUpdate:checked": ($event) => $data.tableColumns[recordIndexs[0]].ellipsis = $event
|
|
278
279
|
}, null, 8, ["checked", "onUpdate:checked"])) : createCommentVNode("", true),
|
|
279
280
|
column.dataIndex === "fixed" ? (openBlock(), createBlock(_component_a_select, {
|
|
280
281
|
key: 7,
|
|
281
|
-
value: $
|
|
282
|
-
"onUpdate:value": ($event) => $
|
|
282
|
+
value: $data.tableColumns[recordIndexs[0]].fixed,
|
|
283
|
+
"onUpdate:value": ($event) => $data.tableColumns[recordIndexs[0]].fixed = $event,
|
|
283
284
|
allowClear: "",
|
|
284
285
|
style: {}
|
|
285
286
|
}, {
|
|
@@ -302,8 +303,8 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
302
303
|
column.dataIndex === "align" ? (openBlock(), createBlock(_component_a_select, {
|
|
303
304
|
key: 8,
|
|
304
305
|
style: {},
|
|
305
|
-
value: $
|
|
306
|
-
"onUpdate:value": ($event) => $
|
|
306
|
+
value: $data.tableColumns[recordIndexs[0]].align,
|
|
307
|
+
"onUpdate:value": ($event) => $data.tableColumns[recordIndexs[0]].align = $event,
|
|
307
308
|
options: $data.alignOptions
|
|
308
309
|
}, null, 8, ["value", "onUpdate:value", "options"])) : createCommentVNode("", true),
|
|
309
310
|
column.dataIndex === "customRender" ? (openBlock(), createBlock(_component_a_button, {
|
|
@@ -358,11 +359,11 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
358
359
|
onSave: $options.saveColumnRender,
|
|
359
360
|
ref: "CodeModalEditorRef",
|
|
360
361
|
title: _ctx.i18nt("designer.setting.renderFunction"),
|
|
361
|
-
"
|
|
362
|
+
"fn-params": "scope"
|
|
362
363
|
}, null, 8, ["onSave", "title"])
|
|
363
364
|
], 64);
|
|
364
365
|
}
|
|
365
|
-
const dataTableTableColumnsEditor = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-
|
|
366
|
+
const dataTableTableColumnsEditor = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-11e67ce4"]]);
|
|
366
367
|
export {
|
|
367
368
|
dataTableTableColumnsEditor as default
|
|
368
369
|
};
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import i18n from "../../../../../utils/i18n.js";
|
|
2
|
-
import
|
|
2
|
+
import _sfc_main$1 from "../../../../code-editor/code-modal-editor.vue.js";
|
|
3
3
|
import { resolveComponent, createElementBlock, openBlock, Fragment, createVNode, withCtx, createTextVNode, toDisplayString } from "vue";
|
|
4
4
|
import _export_sfc from "../../../../../../_virtual/_plugin-vue_export-helper.js";
|
|
5
5
|
const _sfc_main = {
|
|
6
6
|
name: "menuList-editor",
|
|
7
7
|
mixins: [i18n],
|
|
8
|
-
components: { CodeModalEditor },
|
|
8
|
+
components: { CodeModalEditor: _sfc_main$1 },
|
|
9
9
|
props: {
|
|
10
10
|
designer: Object,
|
|
11
11
|
selectedWidget: Object,
|