wangfukang 1 month ago
parent
commit
59dd01c0a1
  1. 12
      package3/shop/merchantCenter.vue

12
package3/shop/merchantCenter.vue

@ -13,11 +13,11 @@
</view> </view>
<view class="shop-title"> <view class="shop-title">
<view class="title1"> <view class="title1">
<img :src="shop.shopIcon" alt="" /> <img :src="shop.shopIcon" alt=""/>
</view> </view>
<view class="title2"> <view class="title2">
<view class="title22"> <view class="title22">
{{shop.shopName == undefined ?"":shop.shopName}} {{(shop.shopName == undefined || shop.shopName == null) ?"":shop.shopName}}
</view> </view>
<view class="title33" @tap="updateStatus"> <view class="title33" @tap="updateStatus">
{{businessStatus == '1'?'暂停营业':'正常营业'}} {{businessStatus == '1'?'暂停营业':'正常营业'}}
@ -314,13 +314,17 @@
}, },
// //
getBusinessStatus(){ getBusinessStatus(){
this.shop.shopName = uni.getStorageSync('shopName')
return this.tui.request("/app/shoptakeaway/getByShopId", "GET", { return this.tui.request("/app/shoptakeaway/getByShopId", "GET", {
shopId: uni.getStorageSync('shopId') shopId: uni.getStorageSync('shopId')
}, false, true).then((res) => { }, false, true).then((res) => {
if (res.code == 200) { if (res.code == 200) {
this.shop = res.result if(res.result != null){
uni.setStorageSync('shopTakeaway',res.result) this.shop = res.result
}
this.shop.shopIcon = uni.getStorageSync('shopIcon') this.shop.shopIcon = uni.getStorageSync('shopIcon')
uni.setStorageSync('shopTakeaway',res.result)
this.businessStatus = res.result.status this.businessStatus = res.result.status
} else { } else {
this.tui.toast(res.message) this.tui.toast(res.message)

Loading…
Cancel
Save