From 7c6e881e0388e49bee3ad5bd79fac79062c2a03e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=98=BF=E6=80=AA?= <690927457@qq.com> Date: Tue, 7 Nov 2023 23:40:53 +0800 Subject: [PATCH] 2023.11.7 --- pages.json | 24 +++++- pages/index/index.vue | 1 + pages/user/setting.vue | 43 ++++++++-- pages/user/setting/aboutUs.vue | 11 +++ pages/user/setting/phone_list.vue | 11 +++ pages/user/setting/privacyPolicy.vue | 11 +++ pages/user/setting/userAgreement.vue | 11 +++ pages/user/userInfo.vue | 119 +++++++++++++++++++++++---- 8 files changed, 209 insertions(+), 22 deletions(-) create mode 100644 pages/user/setting/aboutUs.vue create mode 100644 pages/user/setting/phone_list.vue create mode 100644 pages/user/setting/privacyPolicy.vue create mode 100644 pages/user/setting/userAgreement.vue diff --git a/pages.json b/pages.json index 0840bd2..ece7f56 100644 --- a/pages.json +++ b/pages.json @@ -88,7 +88,29 @@ "navigationBarTitleText": "注意事项", "enablePullDownRefresh": true } - } + }, + { + "path": "pages/user/setting/userAgreement", + "style": { + "navigationBarTitleText": "用户协议" + } + }, + { + "path": "pages/user/setting/privacyPolicy", + "style": { + "navigationBarTitleText": "隐私政策" + } + },{ + "path": "pages/user/setting/phone_list", + "style": { + "navigationBarTitleText": "个人信息手机清单" + } + },{ + "path": "pages/user/setting/aboutUs", + "style": { + "navigationBarTitleText": "关于我们" + } + }, ], "globalStyle": { "navigationBarTextStyle": "white", diff --git a/pages/index/index.vue b/pages/index/index.vue index b5fca0b..99ea52a 100644 --- a/pages/index/index.vue +++ b/pages/index/index.vue @@ -2,6 +2,7 @@ // 引入依赖 import uniDatetimePicker from '@/uni_modules/uni-datetime-picker/components/uni-datetime-picker/uni-datetime-picker.vue' import uniEasyinput from '@/uni_modules/uni-easyinput/components/uni-easyinput/uni-easyinput.vue' + import unCombox from '@/uni_modules/uni-combox/components/uni-combox/uni-combox.vue' import { onLoad,onShow } from "@dcloudio/uni-app" import mySwiper from "@/components/mySwiper.vue" import {ref,onMounted,nextTick,watch} from "vue" diff --git a/pages/user/setting.vue b/pages/user/setting.vue index 77e0c67..90d9cd3 100644 --- a/pages/user/setting.vue +++ b/pages/user/setting.vue @@ -4,6 +4,7 @@ import {ref,onMounted,nextTick} from "vue" import {useStore} from '@/store/index.js' import api from "@/api/index.js" + const store = useStore() onLoad(() => { // console.log(useStore.userInfo) userinfo.value = JSON.parse(uni.getStorageSync('userInfo')) @@ -14,7 +15,39 @@ const avatar = ref(null) // 方法 function toDetail(type) { - + let url = '' + switch(type) { + case 1: + url = '/pages/user/setting/userAgreement' + break; + case 2: + url = '/pages/user/setting/privacyPolicy' + break; + case 3: + url = '/pages/user/setting/phone_list' + break; + case 4: + url = '/pages/user/setting/aboutUs' + break; + case 5: // 退出 + uni.showModal({ + title:"提示", + content:"确认要退出登录吗?", + success:async function(res) { + if(res.confirm) { + store.logout() + } + } + }) + break; + default: + break; + } + if(url) { + uni.navigateTo({ + url + }) + } }