From 139381e210e5388b494e2cd548be51857eb89546 Mon Sep 17 00:00:00 2001 From: "liujw155@outlook.com" Date: Wed, 15 Feb 2023 16:59:38 +0800 Subject: [PATCH 1/6] add blacklist style --- src/pages.json | 11 ++ src/pages/index/index.vue | 6 + src/static/images/icon/index/tab_10.png | Bin 0 -> 604 bytes src/store/index.js | 1 + src/subpackage/blacklist/js/api.js | 8 + src/subpackage/blacklist/js/server.js | 10 ++ .../pages/abnormal_list/abnormal_list.vue | 184 +++++++++++++++++++++ src/subpackage/blacklist/static/images/arrow.png | Bin 0 -> 230 bytes .../blacklist/static/images/triangle.png | Bin 0 -> 227 bytes 9 files changed, 220 insertions(+) create mode 100644 src/static/images/icon/index/tab_10.png create mode 100644 src/subpackage/blacklist/js/api.js create mode 100644 src/subpackage/blacklist/js/server.js create mode 100644 src/subpackage/blacklist/pages/abnormal_list/abnormal_list.vue create mode 100644 src/subpackage/blacklist/static/images/arrow.png create mode 100644 src/subpackage/blacklist/static/images/triangle.png diff --git a/src/pages.json b/src/pages.json index fe088c7..c1e0f13 100644 --- a/src/pages.json +++ b/src/pages.json @@ -683,6 +683,17 @@ } } ] + }, + { + "root": "subpackage/blacklist", + "pages": [ + { + "path": "pages/abnormal_list/abnormal_list", + "style" : { + "navigationBarTitleText": "进场人数异常" + } + } + ] } ], "globalStyle": { diff --git a/src/pages/index/index.vue b/src/pages/index/index.vue index 1dae59e..4821034 100644 --- a/src/pages/index/index.vue +++ b/src/pages/index/index.vue @@ -137,6 +137,12 @@ path: '/pages/order_list/order_list?order_type=18', serverKey: 1014 // 后端对应权限编号 1014 }, + { + id: 10, + name: '进场人数异常', + path: '/subpackage/blacklist/pages/abnormal_list/abnormal_list', + serverKey: 1014 // 后端对应权限编号 1014 + }, ]; const app = getApp(); diff --git a/src/static/images/icon/index/tab_10.png b/src/static/images/icon/index/tab_10.png new file mode 100644 index 0000000000000000000000000000000000000000..846edf1f7f812cc1c5e072153d64e17fa3288340 GIT binary patch literal 604 zcmeAS@N?(olHy`uVBq!ia0vp^CLqkg3?x4-dwml~IR*HHxB_X0xm64^N*HDogUFdB z471A^W|cwNAVw*}Oe8c5l|7^6VQ7dv&=Ap*AirP+-uFhApUC*0>Q+yi)v&D~ZpHpE zr+|xrlNlHow|KfZhIkyGJN53SW(A&>RtbkSD^|S!zsf!3@61d`i|W9QkJ(jjI($~W zc;!^ty&ry|hLi6!JqbGa;_Vc@G?!{ew-8;HwM#F2X!!NtA-V7!LrALAhof7bs>;1~ zYO*qL4px3UnlpKS^)!%sr&I{c0cfx7szyCP1 zKVE298pm}dk!NSPaqYgC1!w+U58_++akV1v`s)rEHTtI%CCXI{QZMXMoM~bm%fZ=f zwq!!@N|q*G(+9q{Y($a{{F(1IM{b_C%){oTA`cd577Lu5=W*~ocg+>4GZPATrmRi5 zBbXpvXRn_=uQ2hIZP{r-x3IWf0+n<4E2Km}&EIvNN1}Y44e#%y6(wF=v3Y`vg>x&c z%{=rkbnNofX7XyU?mgl3?@iCbz}$vMw`a5z=q2PiL`*ljaG~Rdq{!Lh;Vt_W6_bnJ z*L*dyTYiSE`sC}ol8z$gt*e&iH!NpAG25cSe$t}$+kc*3GtB+I+xWtv@@p~2-WhzC ze3Gj$DRXyp<&WngnLGjPbN7|r+%kbvS);c9Omx^k^({{pDi-!`^69eoTpt{?T=gHr Xr9|_{|7WLP1SJzsS3j3^P6 + + + 当前门店 + + + + 全部 + + + + + + + + + 核销日期:2020-08-27 + + + + + + + 欧轩智能羽毛球馆(永泰店) + + 订单编号:20195175645666 + (租场) + + + 用户信息:183165538(周大强) + + + 核销码:200801108978 + + + 验证方式:扫码器验证(pad) + + + 核销时间:2021-05-17 11:12:58 + + + 抓拍图片: + + + 移出黑名单 + + + + + + + + + \ No newline at end of file diff --git a/src/subpackage/blacklist/static/images/arrow.png b/src/subpackage/blacklist/static/images/arrow.png new file mode 100644 index 0000000000000000000000000000000000000000..ad300f49d7398f734d25d5baa333dbb09e0e8218 GIT binary patch literal 230 zcmeAS@N?(olHy`uVBq!ia0vp^G9b*t3?v(r4=o2$>H$6>u0VRzrcGP6Yypznw{PFP zc{7j!Bq0FEhH#&s;b8|V!yYR);g{}u)%D(ggN+f!^IEF}E-g@#N zuS0+c>qTjyq@NuwHv*dYL>98Cc9>0Bz$UxmO#B($hv)N(rmX*UyP literal 0 HcmV?d00001 diff --git a/src/subpackage/blacklist/static/images/triangle.png b/src/subpackage/blacklist/static/images/triangle.png new file mode 100644 index 0000000000000000000000000000000000000000..7b7a4a89d2bb8fa753a9b1c8dd8524862ac9a36a GIT binary patch literal 227 zcmeAS@N?(olHy`uVBq!ia0vp^Vj#@H3?x5i&EW)6W&u7Su0UE!N=i~vQbIyPT3Q;& zh65m1Mn(oMC?_WeWXsFT0~LH0ZTJe*DOeKZ7tHXTldtXlqy1T-Qs>vrceT(wlE3^0 zP}1Ae#W6(U^3_wvc@H>nxLj1sDOvJA?QCbM)`2=FnSE^g6>K_O!n{SIQs(JuuxYx@ z`=e{|`sU>L#F(6ucdis(u9;hI6S7!Tf6Jq0zC+KLPK8uz&jlLG;OXk;vd$@?2>{yR BLk9o= literal 0 HcmV?d00001 From ffb762b8fac1fdc1849bd3a4127e64a3509956d7 Mon Sep 17 00:00:00 2001 From: "liujw155@outlook.com" Date: Mon, 27 Feb 2023 17:55:53 +0800 Subject: [PATCH 2/6] add black ls api --- src/pages/index/index.vue | 2 + src/pages/write_off/operate/operate.vue | 2 +- src/subpackage/blacklist/js/api.js | 1 + .../pages/abnormal_list/abnormal_list.vue | 80 ++++++++++++++++++++-- 4 files changed, 79 insertions(+), 6 deletions(-) diff --git a/src/pages/index/index.vue b/src/pages/index/index.vue index 4821034..bc4a991 100644 --- a/src/pages/index/index.vue +++ b/src/pages/index/index.vue @@ -220,6 +220,8 @@ brandInfo: indexData&&indexData.brand ? indexData.brand : null, }); } + if(tabInfo.id === 10)return util.routeTo(tabInfo.path + `?brand_id=${indexData.brand.id}`,'nT'); + util.routeTo(tabInfo.path,'nT'); }, diff --git a/src/pages/write_off/operate/operate.vue b/src/pages/write_off/operate/operate.vue index 8a810fe..d9a6272 100644 --- a/src/pages/write_off/operate/operate.vue +++ b/src/pages/write_off/operate/operate.vue @@ -69,7 +69,7 @@ export default { // 获取店铺列表 getStoreList({ page=1, - page_size=9999, + page_size=99999, brand_id='', }){ return servers.get({ diff --git a/src/subpackage/blacklist/js/api.js b/src/subpackage/blacklist/js/api.js index 1f2c492..ebcd45a 100644 --- a/src/subpackage/blacklist/js/api.js +++ b/src/subpackage/blacklist/js/api.js @@ -2,6 +2,7 @@ import { ORIGIN } from '../../../js/api'; export const BLACKLIST_API = { stadiumList:`${ORIGIN}/admin/stadium/list`, // 店铺列表 + identifyRecords:`${ORIGIN}/admin/stadium/identify/records`, // 疑似逃票的记录 } diff --git a/src/subpackage/blacklist/pages/abnormal_list/abnormal_list.vue b/src/subpackage/blacklist/pages/abnormal_list/abnormal_list.vue index 15ab5d2..e2f13d2 100644 --- a/src/subpackage/blacklist/pages/abnormal_list/abnormal_list.vue +++ b/src/subpackage/blacklist/pages/abnormal_list/abnormal_list.vue @@ -2,19 +2,19 @@ 当前门店 - + - 全部 + {{ selectStadium.name || '全部' }} - + - 核销日期:2020-08-27 + 核销日期:{{ curDate || '' }} @@ -50,16 +50,86 @@ From acb2f6b8d289c3090f1250c01675ab2a9e5884d5 Mon Sep 17 00:00:00 2001 From: "liujw155@outlook.com" Date: Tue, 28 Feb 2023 14:34:21 +0800 Subject: [PATCH 3/6] add black ls api --- src/subpackage/blacklist/js/api.js | 2 + .../pages/abnormal_list/abnormal_list.vue | 137 +++++++++++++++++---- 2 files changed, 117 insertions(+), 22 deletions(-) diff --git a/src/subpackage/blacklist/js/api.js b/src/subpackage/blacklist/js/api.js index ebcd45a..a059e51 100644 --- a/src/subpackage/blacklist/js/api.js +++ b/src/subpackage/blacklist/js/api.js @@ -3,6 +3,8 @@ import { ORIGIN } from '../../../js/api'; export const BLACKLIST_API = { stadiumList:`${ORIGIN}/admin/stadium/list`, // 店铺列表 identifyRecords:`${ORIGIN}/admin/stadium/identify/records`, // 疑似逃票的记录 + blacklistAdd:`${ORIGIN}/admin/user/blacklist/add`, // 黑名单添加-后台 + blacklistRemove:`${ORIGIN}/admin/user/blacklist/remove`, // 黑名单移除-后台 } diff --git a/src/subpackage/blacklist/pages/abnormal_list/abnormal_list.vue b/src/subpackage/blacklist/pages/abnormal_list/abnormal_list.vue index e2f13d2..61847eb 100644 --- a/src/subpackage/blacklist/pages/abnormal_list/abnormal_list.vue +++ b/src/subpackage/blacklist/pages/abnormal_list/abnormal_list.vue @@ -5,7 +5,7 @@ - {{ selectStadium.name || '全部' }} + {{ selectStadium.name || '全部' }} @@ -20,29 +20,40 @@ - - 欧轩智能羽毛球馆(永泰店) + + {{ e.extension.stadium_name || '-' }} - 订单编号:20195175645666 - (租场) + 订单编号:{{ e.order_no || '-' }} + ({{ e.type || '-' }}) - 用户信息:183165538(周大强) + 用户信息:{{ e.extension.mobile || '-' }}({{ e.extension.nickname || '-' }}) - 核销码:200801108978 + 核销码:{{ e.verify_code || '-' }} - 验证方式:扫码器验证(pad) + 验证方式:{{ e.verify_desc || '-' }} - 核销时间:2021-05-17 11:12:58 + 核销时间:{{ e.verify_leave_time || '-' }} 抓拍图片: - + + + - 移出黑名单 + {{e.in_black_list === 1?'移出黑名单':'加入黑名单'}} @@ -59,6 +70,8 @@ export default { stadiumLs: [], selectStadium: {}, curDate: '', + blackLs: [], + page: 1 } }, async onLoad(options){ @@ -73,41 +86,119 @@ export default { console.warn('get records ls err --->', err); } }, + onReachBottom(){ + let { selectStadium, curDate, page } = this; + this.getRecords({ + brand_id: selectStadium.brand_id, + stadium_id: selectStadium.id, + verify_time: curDate, + page: ++page + }) + }, methods: { + previewImg(url){ + uni.previewImage({ urls: [url] }) + }, getRecords({ - authority = 'wx', + authority = 'wx', // 后台:随便字段写死 brand_id = 63, stadium_id = '', page = 1, - page_size = 15, + page_size = 10, verify_time = '' }){ + util.showLoad(); server.get({ url: BLACKLIST_API.identifyRecords, data: { authority, brand_id, page, page_size, - stadium_id, verify_time + stadium_id: stadium_id || '', verify_time }, failMsg: '加载列表失败!' }) .then(res => { - console.warn('getRecords->', res); + util.hideLoad(); + let _ls = res.list || []; + if(page ===1)return this.blackLs = _ls; + if(!_ls.length)return util.showNone('没有更多数据!'); + this.page = page; + this.blackLs = [ ...this.blackLs, ..._ls ]; + }) }, dateChange(e){ - this.curDate = e.detail.value || '-' + let { selectStadium } = this; + let _date = e.detail.value || '-' + this.curDate = _date; + this.page = 1; + this.blackLs = []; + this.getRecords({ + brand_id: selectStadium.brand_id, + stadium_id: selectStadium.id, + verify_time: _date, + }) }, stadiumChange(e){ - let { stadiumLs } = this; - this.selectStadium = stadiumLs[e.detail.value] + let { stadiumLs, curDate } = this; + let _curStadium = stadiumLs[e.detail.value] || {}; + this.selectStadium = _curStadium; + this.page = 1; + this.blackLs = []; + this.getRecords({ + brand_id: _curStadium.brand_id, + stadium_id: _curStadium.id, + verify_time: curDate, + }) + }, + operateBtn(e, idx){ + let _status = e.in_black_list || '' + let _qry = { + uid: e.user_id, + brand_id: e.brand_id, + idx: idx, + status: _status, + } + if(_status == 0)return this.modalToDo({ qry: _qry, content: '确定将该用户拉入黑名单吗?确定后用户将不能再进入小程序' }); + + if(_status === 1)return this.modalToDo({ qry: _qry, content: '确定移出黑名单吗?' }); + }, - operateBtn(){ + modalToDo({ qry, content }){ util.showModal({ title: '提示', - content: '确定将该用户拉入黑名单吗?确定后用户将不能再进入小程序', + content: content, showCancel: true, + success: mRes => { + if(mRes.confirm)this.blackLsOpt(qry); + } }) }, + blackLsOpt: util.debounce(function({ uid, brand_id, idx, status}){ + let _url = ''; + if(status == 0)_url = BLACKLIST_API.blacklistAdd; + if(status == 1)_url = BLACKLIST_API.blacklistRemove; + util.showLoad(); + server.get({ + url: _url, + data: { + id: uid, + brand_id, + }, + isDefaultGet: false + }) + .then(res=>{ + util.hideLoad(); + if(res.data.code == 0){ + util.showNone('操作成功!'); + let _blackLs = this.blackLs || []; + _blackLs[idx].in_black_list = status == 0 ? 1 : 0; + this.blackLs = _blackLs; + setTimeout(_=>this.$forceUpdate(), 1200); + }else{ + util.showNone(res.data.message || '操作失败!稍后重试'); + } + }) + }, 300, true), // 获取店铺列表 getStoreList({ page=1, @@ -125,7 +216,7 @@ export default { }) .then(res=>{ let _list = res.list || []; - _list.unshift({ name: '全部', id: 0 }) + _list.unshift({ name: '全部', id: '' }) this.stadiumLs = _list; return _list }) @@ -163,6 +254,9 @@ export default { @include textHide(1); font-size: 28upx; color: #9c9c9f; + &.select{ + color: #1A1A1A; + } } .ac-icon{ flex-shrink: 0; @@ -228,7 +322,6 @@ export default { height: 180upx; overflow: hidden; border-radius: 6upx; - background-color: skyblue; >image{ width: 100%; height: 100%; From 2390b413cb27f8471bf9d3bc0838152ebb4e069c Mon Sep 17 00:00:00 2001 From: "liujw155@outlook.com" Date: Fri, 3 Mar 2023 15:57:24 +0800 Subject: [PATCH 4/6] fix black ls query --- src/subpackage/blacklist/pages/abnormal_list/abnormal_list.vue | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/subpackage/blacklist/pages/abnormal_list/abnormal_list.vue b/src/subpackage/blacklist/pages/abnormal_list/abnormal_list.vue index 61847eb..ce05a93 100644 --- a/src/subpackage/blacklist/pages/abnormal_list/abnormal_list.vue +++ b/src/subpackage/blacklist/pages/abnormal_list/abnormal_list.vue @@ -157,6 +157,7 @@ export default { brand_id: e.brand_id, idx: idx, status: _status, + enter_black_list_cause: '人数异常加入' } if(_status == 0)return this.modalToDo({ qry: _qry, content: '确定将该用户拉入黑名单吗?确定后用户将不能再进入小程序' }); @@ -173,7 +174,7 @@ export default { } }) }, - blackLsOpt: util.debounce(function({ uid, brand_id, idx, status}){ + blackLsOpt: util.debounce(function({ uid, brand_id, idx, status, enter_black_list_cause}){ let _url = ''; if(status == 0)_url = BLACKLIST_API.blacklistAdd; if(status == 1)_url = BLACKLIST_API.blacklistRemove; @@ -183,6 +184,7 @@ export default { data: { id: uid, brand_id, + enter_black_list_cause }, isDefaultGet: false }) From b2eb76fd11be2333c72c5e3cb3a0f0a523426829 Mon Sep 17 00:00:00 2001 From: "liujw155@outlook.com" Date: Mon, 27 Mar 2023 15:24:57 +0800 Subject: [PATCH 5/6] vtest 1.1.34 --- src/subpackage/blacklist/pages/abnormal_list/abnormal_list.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/subpackage/blacklist/pages/abnormal_list/abnormal_list.vue b/src/subpackage/blacklist/pages/abnormal_list/abnormal_list.vue index ce05a93..60a6c9e 100644 --- a/src/subpackage/blacklist/pages/abnormal_list/abnormal_list.vue +++ b/src/subpackage/blacklist/pages/abnormal_list/abnormal_list.vue @@ -97,7 +97,7 @@ export default { }, methods: { previewImg(url){ - uni.previewImage({ urls: [url] }) + uni.previewImage({ urls: [url] }); }, getRecords({ authority = 'wx', // 后台:随便字段写死 From 8e6db9637a3ee3eb80a275a66d082f388d352094 Mon Sep 17 00:00:00 2001 From: "liujw155@outlook.com" Date: Mon, 27 Mar 2023 15:26:20 +0800 Subject: [PATCH 6/6] v1.1.34 formal --- src/js/api.js | 4 ++-- src/manifest.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/js/api.js b/src/js/api.js index 555181e..daecf1c 100644 --- a/src/js/api.js +++ b/src/js/api.js @@ -1,5 +1,5 @@ -export const ORIGIN = `https://testmanager.ouxuanzhineng.cn`; // 测试 -// export const ORIGIN = `https://minimanage.ouxuanzhineng.cn`; // 正式 +// export const ORIGIN = `https://testmanager.ouxuanzhineng.cn`; // 测试 +export const ORIGIN = `https://minimanage.ouxuanzhineng.cn`; // 正式 // export const ORIGIN = `http://192.168.1.135:9090`; // 20210927 测试 diff --git a/src/manifest.json b/src/manifest.json index 01fc516..f4c24c3 100644 --- a/src/manifest.json +++ b/src/manifest.json @@ -55,7 +55,7 @@ /* 快应用特有相关 */ "mp-weixin" : { /* 微信小程序特有相关 */ - "appid" : "wx7106e84614cf0060", + "appid" : "wxf1294b279ad1b845", "setting" : { "urlCheck" : false, "minified" : true