This commit is contained in:
u2nyakim 2025-08-28 11:48:19 +08:00
parent 0e47ef526c
commit c818caf193
4 changed files with 11 additions and 4 deletions

View File

@ -21,6 +21,8 @@ export function strToValue(type: string, value: string): any {
case 'text':
case 'textarea':
return value ? value.toString() : '';
case 'tabs':
return 0;
case 'date':
case 'datetime':
case 'time':

View File

@ -25,12 +25,13 @@
</el-collapse>
</template>
<template v-else-if="config.type === 'tabs'">
<el-tabs type="card" v-model="config.value">
<el-tab-pane
v-for="tabPane in config.children"
v-for="(tabPane, tabPaneIndex) in config.children"
:label="tabPane.title"
:name="tabPane.id"
:key="tabPane.id"
:name="tabPaneIndex"
:key="tabPaneIndex"
>
<config-form-list
:config-list="tabPane.children"

View File

@ -106,8 +106,12 @@ const reload = () => {
// vBinditem
d.bind = strToBind(d.type, d.itemBind);
d.option = strToOption(d.type, d.option);
if (d.type == 'tabs') {
d.value = 0;
}
return d;
});
console.log("lists->lists", lists);
configList.value = toTree({
data: lists,
idField: 'id',

View File

@ -246,7 +246,7 @@
const updateSort = (id, sort) => {
updateConfigSort(id, sort).then(()=>{
EleMessage.success("更新成功");
// EleMessage.success("");
});
}
/** 修改配置状态 */