diff --git a/src/components/footer-nav/index.vue b/src/components/footer-nav/index.vue index 1530f4a9..3969b347 100644 --- a/src/components/footer-nav/index.vue +++ b/src/components/footer-nav/index.vue @@ -48,6 +48,7 @@ const nav_style = ref(0); watch( () => props.footerData, (newVal, oldValue) => { + console.log('footer-nav-index:', newVal); const new_content = newVal?.content || {}; const new_style = newVal?.style || {}; nav_content.value = new_content?.nav_content || []; diff --git a/src/views/layout/components/main/index.vue b/src/views/layout/components/main/index.vue index 24c41b61..5e31fbe3 100644 --- a/src/views/layout/components/main/index.vue +++ b/src/views/layout/components/main/index.vue @@ -218,8 +218,10 @@ watch( watch( () => props.footer, (newValue) => { + console.log('main:', newValue); footer_nav.value = newValue; - } + }, + { deep: true } ); const top_padding = ref(90); const top_margin = ref(0); diff --git a/src/views/layout/index.vue b/src/views/layout/index.vue index 21153754..8f2d7729 100644 --- a/src/views/layout/index.vue +++ b/src/views/layout/index.vue @@ -118,7 +118,12 @@ const export_data_event = () => { // 清空数据 const clear_data_event = () => { let new_tem_form = cloneDeep(temp_form.value); - form.value = new_tem_form; + form.value.header.show_tabs = '1'; + form.value.footer.show_tabs = '0'; + form.value.header.com_data = new_tem_form.header.com_data; + form.value.footer.com_data = new_tem_form.footer.com_data; + form.value.diy_data = []; + diy_data_item.value = new_tem_form.header; }; //#region 页面初始化数据 ---------------------start // 页面加载