From 1539515790d7e3b7a4f2aa01a6de235a879745fa Mon Sep 17 00:00:00 2001 From: sws <1141121512@qq.com> Date: Tue, 24 Sep 2024 11:03:08 +0800 Subject: [PATCH 1/3] =?UTF-8?q?1.=E6=96=B0=E5=A2=9E=E5=BA=95=E9=83=A8?= =?UTF-8?q?=E5=AF=BC=E8=88=AA=E5=8D=95=E7=8B=AC=E9=85=8D=E7=BD=AE=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/tabbar.ts | 22 +++ .../components/main/default/footer-nav.ts | 2 +- src/views/tabbar/components/main/index.ts | 7 +- src/views/tabbar/components/main/index.vue | 3 +- .../tabbar/components/settings/index.vue | 6 +- src/views/tabbar/index.vue | 153 ++---------------- 6 files changed, 44 insertions(+), 149 deletions(-) create mode 100644 src/api/tabbar.ts diff --git a/src/api/tabbar.ts b/src/api/tabbar.ts new file mode 100644 index 00000000..d92e1c86 --- /dev/null +++ b/src/api/tabbar.ts @@ -0,0 +1,22 @@ +import request from '@/utils/request'; + +class ShopAPI { + /** 获取tabbar列表 */ + static getTabbar(data: any) { + return request({ + url: `diyapi/apptabbardata`, + method: 'post', + data, + }); + } + /** 保存tabbar */ + static saveTabbar(data: any) { + return request({ + url: `diyapi/apptabbarsave`, + method: 'post', + data, + }); + } +} + +export default ShopAPI; diff --git a/src/views/tabbar/components/main/default/footer-nav.ts b/src/views/tabbar/components/main/default/footer-nav.ts index 3f075157..54841f10 100644 --- a/src/views/tabbar/components/main/default/footer-nav.ts +++ b/src/views/tabbar/components/main/default/footer-nav.ts @@ -1,7 +1,7 @@ import defaultCommon from './index'; import { online_url } from '@/utils'; const new_url = await online_url('/static/app/tabbar/').then((res) => res); -interface DefaultFooterNav { +export interface DefaultFooterNav { content: { nav_style: number; nav_type: number; diff --git a/src/views/tabbar/components/main/index.ts b/src/views/tabbar/components/main/index.ts index 68ac974d..aff3e467 100644 --- a/src/views/tabbar/components/main/index.ts +++ b/src/views/tabbar/components/main/index.ts @@ -1,9 +1,8 @@ import defaultFooterNav from './default/footer-nav'; -// 系统设置 -interface DefaultSettings { - footer_nav: object; -} +interface DefaultSettings { + footer_nav: any; +} const defaultSettings: DefaultSettings = { footer_nav: defaultFooterNav, }; diff --git a/src/views/tabbar/components/main/index.vue b/src/views/tabbar/components/main/index.vue index bd9ec2f4..77b6f903 100644 --- a/src/views/tabbar/components/main/index.vue +++ b/src/views/tabbar/components/main/index.vue @@ -11,7 +11,7 @@