Browse Source

fix tid1803

tid1878
刘嘉炜 3 months ago
parent
commit
04d9030192
  1. 4
      src/subpackage/blacklist/pages/abnormal_list/abnormal_list.vue
  2. 34
      src/subpackage/verification/pages/index.vue
  3. 15
      src/subpackage/verification/pages/record.vue
  4. 5
      src/subpackage/verification/pages/site_people/index.vue
  5. 6
      src/subpackage/verification/pages/site_people/modules/not_leave_modal.vue
  6. 15
      src/subpackage/verification/pages/site_people/modules/stadium_select.vue

4
src/subpackage/blacklist/pages/abnormal_list/abnormal_list.vue

@ -102,10 +102,10 @@ export default {
async onLoad(options){
try{
let _date = this.curDate = util.formatDate({});
let _stadiumLs = await this.getStoreList({});
let _stadiumLs = await this.getStoreList({ brand_id: options?.brand_id ?? '' });
let { curTimeTab } = this;
this.getRecords({
brand_id: options.brand_id,
brand_id: options?.brand_id ?? '',
[ curTimeTab?.label || '-' ]: _date
});
}catch(err){

34
src/subpackage/verification/pages/index.vue

@ -48,25 +48,40 @@ export default {
}
},
onLoad(options){
/**
* @param {String} options.brand_id 品牌id
* @param {String} options.stadium_id 场馆id
*/
async onLoad(options){
let _brand_id = options?.brand_id || '';
this.brand_id = _brand_id;
this.getStadiumLs({ brand_id: _brand_id });
let _stadiumLs = await this.getStadiumLs({ brand_id: _brand_id });
if(options?.stadium_id&&_stadiumLs?.length){
//
let _selected = _stadiumLs.find(ele => +ele.id === +(options?.stadium_id ?? ''));
if(_selected?.id)this.curStadium = _selected;
}
},
methods: {
//
toSitePeople(){
let { brand_id } = this;
routeTo(`/subpackage/verification/pages/site_people/index?brand_id=${brand_id}`, 'nT');
let { brand_id, curStadium } = this;
let _qryStr = `brand_id=${brand_id}`
if(curStadium?.id) _qryStr += `&stadium_id=${curStadium.id}`;
routeTo(`/subpackage/verification/pages/site_people/index?${_qryStr}`, 'nT');
},
//
toAbnormal(){
let { brand_id } = this;
routeTo(`/subpackage/blacklist/pages/abnormal_list/abnormal_list?brand_id=${brand_id}`, 'nT');
let { brand_id, curStadium } = this;
let _qryStr = `brand_id=${brand_id}`
if(curStadium?.id) _qryStr += `&stadium_id=${curStadium.id}`;
routeTo(`/subpackage/blacklist/pages/abnormal_list/abnormal_list?${_qryStr}`, 'nT');
},
toRecord(){
let { brand_id } = this;
routeTo(`/subpackage/verification/pages/record?brand_id=${brand_id}`, 'nT');
let { brand_id, curStadium } = this;
let _qryStr = `brand_id=${brand_id}`
if(curStadium?.id) _qryStr += `&stadium_id=${curStadium.id}`;
routeTo(`/subpackage/verification/pages/record?${_qryStr}`, 'nT');
},
confirmBtn: debounce(function(){
let { iptCode } = this;
@ -116,8 +131,7 @@ export default {
let _data = res?.data || {};
if(_data.code === 0){
let _ls = _data?.data?.list || [];
this.stadiumList = _ls;
return _ls;
return this.stadiumList = _ls;
}else{
return Promise.reject(_data);
}

15
src/subpackage/verification/pages/record.vue

@ -109,9 +109,19 @@ export default {
page: 1,
}
},
/**
* @param {Object} options
* @param {String} options.brand_id // id
* @param {String} options.stadium_id // id
*/
async onLoad(options){
this.brand_id = options?.brand_id ?? '';
this.getStadiumLs({ brand_id: options?.brand_id ?? '' });
let _stadiumLs = await this.getStadiumLs({ brand_id: options?.brand_id ?? '' });
if(options?.stadium_id&&_stadiumLs?.length){
//
let _selected = _stadiumLs.find(ele => +ele.id === +(options?.stadium_id ?? ''));
if(_selected?.id)this.curStadium = _selected;
}
this.reloadRecordLs();
},
onReachBottom(){
@ -203,8 +213,7 @@ export default {
let _data = res?.data || {};
if(_data.code === 0){
let _ls = _data?.data?.list || [];
this.stadiumList = _ls;
return _ls;
return this.stadiumList = _ls;
}else{
return Promise.reject(_data);
}

5
src/subpackage/verification/pages/site_people/index.vue

@ -77,7 +77,10 @@ export default {
}
},
async onLoad(options){
this.$refs.stadiumSelect.initStadium(options?.brand_id || '')
this.$refs.stadiumSelect.initStadium({
brand_id: options?.brand_id ?? '',
stadium_id: options?.stadium_id ?? '',
})
.then(stadiumInfo=>{
if(!stadiumInfo?.id) return;
this.stadiumInfo = stadiumInfo;

6
src/subpackage/verification/pages/site_people/modules/not_leave_modal.vue

@ -29,6 +29,7 @@ export default {
visible: false,
notLeaveInfo: {},
brand_id: '',
stadium_id: '',
}
},
methods: {
@ -41,6 +42,7 @@ export default {
initData(e){
let { igsType, key, stadium_id, brand_id } = e;
this.brand_id = brand_id ?? '';
this.stadium_id = stadium_id ?? '';
this.show();
let _keyName = igsType === 1 ? 'gate_id' : igsType === 2 ? 'venue_type_key' : '';
let _query = { brand_id, stadium_id };
@ -71,8 +73,8 @@ export default {
})
},
checkBtn(type){
let { brand_id } = this;
if(type == 0)return routeTo(`/subpackage/verification/pages/record?brand_id=${brand_id?? ''}`, 'nT');
let { brand_id, stadium_id } = this;
if(type == 0)return routeTo(`/subpackage/verification/pages/record?brand_id=${brand_id?? ''}&stadium_id=${stadium_id??''}`, 'nT');
if(type == 1)return routeTo(`/pages/order_list/order_list?order_type=1`, 'nT');
},
}

15
src/subpackage/verification/pages/site_people/modules/stadium_select.vue

@ -27,7 +27,7 @@ export default {
this.curStadium = stadiumLs?.[value] || {};
this.$emit('change:stadium', this.curStadium);
},
async initStadium(brand_id){
async initStadium({ brand_id, stadium_id }){
try{
showLoad();
let _ls = await this.getStadiumLs({ brand_id });
@ -36,10 +36,19 @@ export default {
// })
this.stadiumLs = _ls || [];
hideLoad();
if(_ls.length){
if(stadium_id&&_ls?.length){
let _cur = _ls.find(e=>Number(e.id) === Number(stadium_id));
if(_cur){
this.curStadium = _cur;
return _cur;
} else {
this.curStadium = _ls[0];
return _ls[0];
}
} else if (_ls.length){
this.curStadium = _ls[0];
return _ls[0];
}else{
} else {
showNone('暂无店铺信息!');
}
}catch(err){

Loading…
Cancel
Save