Browse Source

fix bug && vtest 1.1.41

privacy
刘嘉炜 1 year ago
parent
commit
f7a02eb176
  1. 2
      src/store/device.js
  2. 7
      src/subpackage/device/pages/device_manage/device_manage.vue
  3. 2
      src/subpackage/device/pages/index/index.vue

2
src/store/device.js

@ -29,7 +29,7 @@ export default {
if(stadium_id&&_list.some(item=>item.id===stadium_id)){
commit('setStoreInfo', _list.find(item=>item.id===stadium_id));
}else{
commit('setStoreInfo', _list?.[0] || {});
if(storeChange || !state?.curStoreInfo?.id)commit('setStoreInfo', _list?.[0] || {});
}
return res;
})

7
src/subpackage/device/pages/device_manage/device_manage.vue

@ -215,7 +215,7 @@ export default {
},
changeDeviceStatus({info, status}){
let { pageInfo } = this;
let { pageInfo, curStoreInfo } = this;
util.showLoad();
deviceServer.get({
url: deviceApi.hardwareSave,
@ -228,7 +228,10 @@ export default {
.then(res=>{
if(res.data.code == 0){
util.showNone(res.data.message || '操作成功!')
setTimeout(_=>this.getDeviceList(pageInfo),1200);
setTimeout(_=>this.getDeviceList({
hardware_type: pageInfo.deviceType,
stadium_id: curStoreInfo.id
}),1200);
}else{
util.showNone(res.data.message || '操作失败!');
}

2
src/subpackage/device/pages/index/index.vue

@ -132,7 +132,7 @@ export default {
if(nw?.id === od?.id)return;
let { brandInfo } = this;
this.$store.commit('setBrandInfo', { ...brandInfo, brand: nw });
this.$store.dispatch('getStoreList');
this.$store.dispatch('getStoreList', { storeChange: true });
}
},
data(){

Loading…
Cancel
Save