新增:导航栏目设计拆分简单和高级展示方式

This commit is contained in:
2024-09-03 01:13:18 +08:00
parent bf43bdbab4
commit aa85c133e3
24 changed files with 1121 additions and 353 deletions
@@ -55,18 +55,15 @@
@pressEnter="save"
/>
</a-form-item>
<!-- <a-form-item-->
<!-- label="组件路径"-->
<!-- name="component"-->
<!-- v-if="isUpdate"-->
<!-- >-->
<!-- <a-input-->
<!-- allow-clear-->
<!-- placeholder="/pages/product/detail.vue"-->
<!-- v-model:value="form.component"-->
<!-- @pressEnter="save"-->
<!-- />-->
<!-- </a-form-item>-->
<a-form-item label="组件路径" name="component" v-if="isUpdate">
<a-input
allow-clear
disabled
placeholder="/pages/product/detail.vue"
v-model:value="form.component"
@pressEnter="save"
/>
</a-form-item>
<a-form-item label="css样式" name="style" v-if="isUpdate">
<a-input
allow-clear
@@ -202,7 +199,7 @@
navigationId: undefined,
model: 'custom',
code: undefined,
modelName: '通用模型',
modelName: '单页模型',
type: 0,
title: '',
parentId: 0,
@@ -314,11 +311,22 @@
]
});
const chooseModel = (item: Navigation) => {
const chooseModel = (item: any) => {
console.log(item);
form.model = `${item.value}`;
form.modelName = `${item.label}`;
form.componentPath = `${item.component}`;
if (item.value == 'custom') {
form.path = `/custom-${form.navigationId}`;
form.component = `/pages/[${item.value}]/index.vue`;
return;
}
if (item.value == 'links') {
form.path = `https://`;
form.component = `/pages/${item.value}/index.vue`;
return;
}
form.path = `/${item.value}/${form.navigationId}`;
form.component = `/pages/${item.value}/index.vue`;
};
const chooseFile = (data: FileRecord) => {