commit:bug修复

This commit is contained in:
Jerry
2024-09-10 17:15:43 +08:00
parent 0601f17291
commit 7d652ca316
2 changed files with 9 additions and 2 deletions

View File

@@ -7,7 +7,7 @@
:model="formPageData" :model="formPageData"
:rules="formRules" :rules="formRules"
label-position="right" label-position="right"
label-width="80px" label-width="90px"
@submit.prevent @submit.prevent
> >
<el-col :span="24"> <el-col :span="24">
@@ -89,7 +89,7 @@ watch(
() => props.modelValue, () => props.modelValue,
(newVal, oldVal) => { (newVal, oldVal) => {
if (newVal != oldVal) { if (newVal != oldVal) {
formPageData.value = { ...newVal }; formPageData.value = { ...formPageData.value, ...newVal };
} }
}, },
{ {

View File

@@ -440,6 +440,9 @@ const initPageInfo = () => {
published: false, published: false,
pageType: SysOnlinePageType.BIZ, pageType: SysOnlinePageType.BIZ,
status: SysOnlinePageStatus.BASIC, status: SysOnlinePageStatus.BASIC,
extraJson: {
extendClass: undefined,
},
}; };
activeStep.value = SysOnlinePageSettingStep.BASIC; activeStep.value = SysOnlinePageSettingStep.BASIC;
let pageId = props.pageId || thirdParams.value.pageId; let pageId = props.pageId || thirdParams.value.pageId;
@@ -718,8 +721,12 @@ onMounted(() => {
return initPageInfo(); return initPageInfo();
}) })
.then(res => { .then(res => {
let extraJson = JSON.parse((res.data.extraJson as string) || '{}');
formPageData.value = { formPageData.value = {
...res.data, ...res.data,
extraJson: {
extendClass: extraJson.extendClass,
},
}; };
}) })
.catch(e => { .catch(e => {