From 6abdd28e794560593c3ee2c203bbd096629a1813 Mon Sep 17 00:00:00 2001 From: luyisha Date: Mon, 11 Sep 2023 16:10:05 +0800 Subject: [PATCH] 2 --- common/js/api.js | 9 +- pages.json | 9 ++ pages/about/bannerManage/addBanner.vue | 1 + pages/about/bannerManage/bannerManage.vue | 16 +-- pages/about/bonusSet/bonusSet.vue | 15 ++- pages/about/bonusSet/index.vue | 2 +- pages/about/noticeManage/noticeManage.vue | 15 ++- pages/about/serviceSet/serviceSet.vue | 23 ++-- pages/list/agent.vue | 23 ++-- pages/list/user.vue | 23 ++-- pages/recordsList/recordsList.vue | 136 ++++++++++++++-------- pages/serivce/serivce.vue | 129 ++++++++++++++++++++ pages/ucenter/ucenter.vue | 8 +- static/user/icon_manager2.png | Bin 0 -> 658 bytes 14 files changed, 306 insertions(+), 103 deletions(-) create mode 100644 pages/serivce/serivce.vue create mode 100644 static/user/icon_manager2.png diff --git a/common/js/api.js b/common/js/api.js index 0f096c7..9d97b2c 100644 --- a/common/js/api.js +++ b/common/js/api.js @@ -91,9 +91,16 @@ let API = { ...requestObj, success(res) { // console.log(res, '000'); - // 200=成功, 400 = 失败错误返回、404 token验证失败 + // 200=成功, 400 = 失败错误返回、404 token验证失败 ,403 token已过2小时失效 if(res.data.code==200){ success && success(res.data); + }else if(res.data.code==403){ + uni.removeStorageSync('user_token'); + setTimeout(()=>{ + uni.reLaunch({ + url: '/uni_modules/uni-id-pages/pages/login/login-withpwd' + }) + }, 1000) }else{ uni.showToast({ title: res.data.msg, diff --git a/pages.json b/pages.json index ea3fbf1..a34bd6e 100644 --- a/pages.json +++ b/pages.json @@ -321,6 +321,15 @@ } } + ,{ + "path" : "pages/serivce/serivce", + "style" : + { + "navigationBarTitleText": "联系客服", + "enablePullDownRefresh": false + } + + } ], "subPackages": [{ "root": "uni_modules/uni-feedback", diff --git a/pages/about/bannerManage/addBanner.vue b/pages/about/bannerManage/addBanner.vue index 705f56b..1d8857e 100644 --- a/pages/about/bannerManage/addBanner.vue +++ b/pages/about/bannerManage/addBanner.vue @@ -93,6 +93,7 @@ this.id = e.id; this.editInfo.title = e.title; this.editInfo.image = e.image; + this.editInfo.img = e.image.split('/storage')[1]; this.editInfo.sort = e.sort; } diff --git a/pages/about/bannerManage/bannerManage.vue b/pages/about/bannerManage/bannerManage.vue index 9c3d94e..9df64a8 100644 --- a/pages/about/bannerManage/bannerManage.vue +++ b/pages/about/bannerManage/bannerManage.vue @@ -6,7 +6,7 @@ 轮播名称:{{item.title}} - 排序:{{item.sort}}% + 排序:{{item.sort}} 编辑 @@ -43,13 +43,15 @@ uni.showModal({ title:'温馨提示', content:"确定是否删除该信息", - success() { - API.request('/rotationChart/delete', {id: val.id}, res=>{ - uni.showToast({ - title: res.msg + success(res) { + if(res.confirm){ + API.request('/rotationChart/delete', {id: val.id}, res=>{ + uni.showToast({ + title: res.msg + }) + _this.setList.splice(i, 1); }) - _this.setList.splice(i, 1); - }) + } } }) }, diff --git a/pages/about/bonusSet/bonusSet.vue b/pages/about/bonusSet/bonusSet.vue index bffb0bd..7777415 100644 --- a/pages/about/bonusSet/bonusSet.vue +++ b/pages/about/bonusSet/bonusSet.vue @@ -72,13 +72,16 @@ uni.showModal({ title:'温馨提示', content:"确定是否删除该奖金信息", - success() { - API.request('/adminZoneManage/goodsParamDel', {z_g_p_id: val.id}, res=>{ - uni.showToast({ - title: res.msg + success(res) { + if(res.confirm){ + API.request('/adminZoneManage/goodsParamDel', {z_g_p_id: val.id}, res=>{ + uni.showToast({ + title: res.msg + }) + _this.setList.splice(i, 1); }) - _this.setList.splice(i, 1); - }) + } + } }) }, diff --git a/pages/about/bonusSet/index.vue b/pages/about/bonusSet/index.vue index 4f52eb2..b4aa1a4 100644 --- a/pages/about/bonusSet/index.vue +++ b/pages/about/bonusSet/index.vue @@ -57,7 +57,7 @@ }else{ this.bonusList = res.data; } - }, fail=>{}, false) + }, fail=>{}) } }, onLoad(e) { diff --git a/pages/about/noticeManage/noticeManage.vue b/pages/about/noticeManage/noticeManage.vue index a6618ac..1adfd01 100644 --- a/pages/about/noticeManage/noticeManage.vue +++ b/pages/about/noticeManage/noticeManage.vue @@ -52,13 +52,16 @@ uni.showModal({ title:'温馨提示', content:"确定是否删除该信息", - success() { - API.request('/notice/delete', {id: val.id}, res=>{ - uni.showToast({ - title: res.msg + success(res) { + if(res.confirm){ + API.request('/notice/delete', {id: val.id}, res=>{ + uni.showToast({ + title: res.msg + }) + _this.setList.splice(i, 1); }) - _this.setList.splice(i, 1); - }) + } + } }) }, diff --git a/pages/about/serviceSet/serviceSet.vue b/pages/about/serviceSet/serviceSet.vue index f76a0fb..1b2c20b 100644 --- a/pages/about/serviceSet/serviceSet.vue +++ b/pages/about/serviceSet/serviceSet.vue @@ -66,22 +66,25 @@ edit(val, i){ this.title = "编辑客服信息"; this.showEdit = true; - this.editInfo = val; + this.editInfo = {...val}; }, remove(val, i){ let _this = this; uni.showModal({ title:'温馨提示', content:"确定是否删除该客服信息", - success() { - API.request('/customerService/delete', { - id: val.id - }, res=>{ - uni.showToast({ - title: res.msg + success(res) { + if(res.confirm){ + API.request('/customerService/delete', { + id: val.id + }, res=>{ + uni.showToast({ + title: res.msg + }) + _this.dataList.splice(i, 1); }) - _this.dataList.splice(i, 1); - }) + } + } }) }, @@ -116,7 +119,7 @@ }) } }, - onLoad() { + onShow() { this.getList(); }, onNavigationBarButtonTap(e){ diff --git a/pages/list/agent.vue b/pages/list/agent.vue index 83aac7e..942d46c 100644 --- a/pages/list/agent.vue +++ b/pages/list/agent.vue @@ -140,17 +140,20 @@ uni.showModal({ title:'温馨提示', content:"确定是否删除该代理信息", - success() { - API.request('/adminAgentTeam/deleteAgent', { - aid: val.id - }, res=>{ - uni.showToast({ - title: res.msg + success(res) { + if(res.confirm){ + API.request('/adminAgentTeam/deleteAgent', { + aid: val.id + }, res=>{ + uni.showToast({ + title: res.msg + }) + _this.listsData.splice(i, 1); + // _this.account = ''; + // _this.search(); }) - _this.listsData.splice(i, 1); - // _this.account = ''; - // _this.search(); - }) + } + } }) }, diff --git a/pages/list/user.vue b/pages/list/user.vue index 02a65d3..a4a4999 100644 --- a/pages/list/user.vue +++ b/pages/list/user.vue @@ -141,17 +141,20 @@ uni.showModal({ title:'温馨提示', content:"确定是否删除该用户信息", - success() { - API.request('/adminUserTeam/deleteUser', { - user_id: val.id - }, res=>{ - uni.showToast({ - title: res.msg + success(res) { + if(res.confirm){ + API.request('/adminUserTeam/deleteUser', { + user_id: val.id + }, res=>{ + uni.showToast({ + title: res.msg + }) + _this.listsData.splice(i, 1); + // _this.account = ''; + // _this.search(); }) - _this.listsData.splice(i, 1); - // _this.account = ''; - // _this.search(); - }) + } + } }) }, diff --git a/pages/recordsList/recordsList.vue b/pages/recordsList/recordsList.vue index eb53adf..17f7b26 100644 --- a/pages/recordsList/recordsList.vue +++ b/pages/recordsList/recordsList.vue @@ -4,8 +4,8 @@ 消费、中奖记录 - ID:{{item.id}}({{item.type}}) - 余额 + ID:{{item.id}}({{item.type}}) + {{item.trade_type}} 可提余额