Commit 050cc754 by 侯体倬

客服逻辑优化

parent 5b84c7ec
......@@ -41,6 +41,7 @@ const { log } = app;
export default {
data() {
return {
options: {},
sessionFrom: "",
defaultContact: null,
result: null,
......@@ -48,6 +49,7 @@ export default {
};
},
onLoad(options) {
this.options = options;
if(options.wxConcatGoods){
let wxConcatGoods = JSON.parse(options.wxConcatGoods)
wxConcatGoods['pathLink'] = pathToNavigation.toPageUrl(pathToNavigation.getUrlofLink(wxConcatGoods), pathToNavigation.getUrlofQuery(wxConcatGoods));
......@@ -62,8 +64,12 @@ export default {
});
},
onShow() {
let shopCode = this.options.shopCode;
if (!shopCode) {
const { offlineShopCode } = getStoreInfo();
getWxContact({ shopCode: offlineShopCode }).then(res => {
shopCode = offlineShopCode;
}
getWxContact({ shopCode }).then(res => {
if (res.data.code == 200) {
const result = res.data.data
if (result.whetherOpenCustomerChannel == 0) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment