From 89abab8153805f7a9e9e0a6cc0a36b49f59f28de Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=85=A8=E6=A0=88=E5=B0=8F=E5=AD=A6=E7=94=9F?= <1518079521@qq.com> Date: Wed, 31 May 2023 11:34:01 +0800 Subject: [PATCH] uni-app --- uni-app/App.vue | 3 + uni-app/api/system.ts | 9 +- .../diy/{system => }/article/index.vue | 33 +- uni-app/components/diy/comp-extend/index.vue | 20 - .../diy/extend/hello-info/index.vue | 24 - .../diy/extend/hello-text/index.vue | 24 - .../diy/{system => }/graphic-nav/index.vue | 28 +- uni-app/components/diy/group/index.scss | 30 + uni-app/components/diy/group/index.vue | 82 +-- .../diy/{system => }/horz-blank/index.vue | 7 +- .../diy/{system => }/image-ads/index.vue | 26 +- .../diy/{system => }/member-info/index.vue | 93 ++- .../diy/{system => }/text/index.vue | 15 +- uni-app/locale/zh-Hans.json | 4 +- uni-app/locale/zh-Hans/common.json | 7 +- uni-app/pages.json | 548 +++++++++--------- uni-app/pages/auth/bind.vue | 22 +- uni-app/pages/auth/login.vue | 2 +- uni-app/pages/auth/register.vue | 2 +- uni-app/pages/index/close.vue | 16 + uni-app/pages/index/diy.vue | 44 +- uni-app/pages/index/index.vue | 40 +- uni-app/pages/index/nonexistence.vue | 16 + uni-app/pages/member/index.vue | 43 +- .../pages/member/recharge_record_detail.vue | 40 +- uni-app/stores/config.ts | 7 +- uni-app/stores/diy.ts | 28 +- uni-app/stores/system.ts | 29 + uni-app/utils/request.ts | 21 + 29 files changed, 704 insertions(+), 559 deletions(-) rename uni-app/components/diy/{system => }/article/index.vue (56%) delete mode 100644 uni-app/components/diy/comp-extend/index.vue delete mode 100644 uni-app/components/diy/extend/hello-info/index.vue delete mode 100644 uni-app/components/diy/extend/hello-text/index.vue rename uni-app/components/diy/{system => }/graphic-nav/index.vue (88%) create mode 100644 uni-app/components/diy/group/index.scss rename uni-app/components/diy/{system => }/horz-blank/index.vue (65%) rename uni-app/components/diy/{system => }/image-ads/index.vue (66%) rename uni-app/components/diy/{system => }/member-info/index.vue (53%) rename uni-app/components/diy/{system => }/text/index.vue (69%) create mode 100644 uni-app/pages/index/close.vue create mode 100644 uni-app/pages/index/nonexistence.vue create mode 100644 uni-app/stores/system.ts diff --git a/uni-app/App.vue b/uni-app/App.vue index 232a87d9e..334d892e2 100644 --- a/uni-app/App.vue +++ b/uni-app/App.vue @@ -5,6 +5,7 @@ import { getToken, isWeixinBrowser, urlDeconstruction } from '@/utils/common' import useMemberStore from '@/stores/member' import useConfigStore from '@/stores/config' + import useSystemStore from '@/stores/system' import { useLogin } from '@/hooks/useLogin' import { language } from '@/locale' @@ -25,6 +26,8 @@ const configStore = useConfigStore() configStore.getTabbarConfig() await configStore.getLoginConfig() + + useSystemStore().getSitenfo() // 隐藏tabbar uni.hideTabBar() diff --git a/uni-app/api/system.ts b/uni-app/api/system.ts index 4e68d30d8..d9c3ec938 100644 --- a/uni-app/api/system.ts +++ b/uni-app/api/system.ts @@ -32,7 +32,7 @@ export function getAgreementInfo(key : string) { * 重置密码 */ export function resetPassword(data : AnyObject) { - return request.post(`/password/reset`, data, { showErrorMessage: true }) + return request.post(`password/reset`, data, { showErrorMessage: true }) } /** @@ -68,4 +68,11 @@ export function fetchImage(data : AnyObject) { */ export function fetchBase64Image(data : AnyObject) { return request.post('file/image/base64', data) +} + +/** + * 获取站点信息 + */ +export function getSiteInfo() { + return request.get('site') } \ No newline at end of file diff --git a/uni-app/components/diy/system/article/index.vue b/uni-app/components/diy/article/index.vue similarity index 56% rename from uni-app/components/diy/system/article/index.vue rename to uni-app/components/diy/article/index.vue index 8a79c6aba..344f329cd 100644 --- a/uni-app/components/diy/system/article/index.vue +++ b/uni-app/components/diy/article/index.vue @@ -1,8 +1,8 @@