diff --git a/CoreCms.Net.Uni-App/CoreShop/App.vue b/CoreCms.Net.Uni-App/CoreShop/App.vue index 9ac19309..2b6dd6b9 100644 --- a/CoreCms.Net.Uni-App/CoreShop/App.vue +++ b/CoreCms.Net.Uni-App/CoreShop/App.vue @@ -3,15 +3,18 @@ import { queryShopConfigV2, queryAppVersions } from '@/core/api'; import type { Response, ShopConfigType } from '@/core/models'; import { useShopConfigStore } from '@/core/store'; - + + /** 获取项目配置 */ + const shopConfigStore = useShopConfigStore(); + onShow(() => { console.log('App Show') }) - + onHide(() => { console.log('App Hide') }) - + onLaunch(() => { getShopConfigV2(); /** 版本设置 */ @@ -31,15 +34,11 @@ checkVersion() // #endif }) - - /** 获取项目配置 */ - const shopConfigStore = useShopConfigStore(); - + const getShopConfigV2 = async () => { - const shopConfig : Response = await queryShopConfigV2(); - shopConfigStore.setConfig(shopConfig.data); + shopConfigStore.querySystemConfig(); } - + const autoUpdate = () => { /** 获取小程序更新机制兼容 */ if (wx.canIUse('getUpdateManager')) { diff --git a/CoreCms.Net.Uni-App/CoreShop/components/coreshop-page/coreshop-page.vue b/CoreCms.Net.Uni-App/CoreShop/components/coreshop-page/coreshop-page.vue index 1c7db9cc..3731b59d 100644 --- a/CoreCms.Net.Uni-App/CoreShop/components/coreshop-page/coreshop-page.vue +++ b/CoreCms.Net.Uni-App/CoreShop/components/coreshop-page/coreshop-page.vue @@ -11,6 +11,10 @@ +