Merge branch 'master' of gitee.com:beijing_hongye_huicheng/lilishop-uniapp
commit
07627c41e3
|
@ -1,10 +1,8 @@
|
||||||
/**
|
/**
|
||||||
* 公共API
|
* 公共API
|
||||||
*/
|
*/
|
||||||
import {http, Method} from '@/utils/request.js';
|
import { http, Method } from "@/utils/request.js";
|
||||||
import api from '@/config/api.js';
|
import api from "@/config/api.js";
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 获取地区数据
|
* 获取地区数据
|
||||||
|
@ -18,9 +16,17 @@ export function getRegionsById(id = 0) {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 获取IM接口前缀
|
||||||
|
export function getIMDetail() {
|
||||||
|
return http.request({
|
||||||
|
url: `${api.common}/IM`,
|
||||||
|
method: Method.GET,
|
||||||
|
message: false,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 文件上传地址
|
* 文件上传地址
|
||||||
* @type {string}
|
* @type {string}
|
||||||
*/
|
*/
|
||||||
export const upload =api.common+'/upload/file';
|
export const upload = api.common + "/upload/file";
|
||||||
|
|
||||||
|
|
|
@ -221,7 +221,7 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="card-flex" @click="shutMask(3)">
|
<view class="card-flex" @click="shutMask(3)">
|
||||||
<view class="card-title"> 送至 </view>
|
<view class="card-title"> 送至</view>
|
||||||
<view class="card-content">
|
<view class="card-content">
|
||||||
<span v-if="delivery">{{
|
<span v-if="delivery">{{
|
||||||
delivery.consigneeAddressPath | clearStrComma
|
delivery.consigneeAddressPath | clearStrComma
|
||||||
|
@ -362,6 +362,7 @@ import { getGoods, getGoodsList, getMpScene, getGoodsDistribution } from "@/api/
|
||||||
import * as API_trade from "@/api/trade.js";
|
import * as API_trade from "@/api/trade.js";
|
||||||
import * as API_Members from "@/api/members.js";
|
import * as API_Members from "@/api/members.js";
|
||||||
import * as API_store from "@/api/store.js";
|
import * as API_store from "@/api/store.js";
|
||||||
|
import { getIMDetail } from '@/api/common'
|
||||||
import { modelNavigateTo } from "@/pages/tabbar/home/template/tpl.js";
|
import { modelNavigateTo } from "@/pages/tabbar/home/template/tpl.js";
|
||||||
/************请求存储***************/
|
/************请求存储***************/
|
||||||
import storage from "@/utils/storage.js";
|
import storage from "@/utils/storage.js";
|
||||||
|
@ -522,9 +523,17 @@ export default {
|
||||||
startTimer: false, //未开启 是false
|
startTimer: false, //未开启 是false
|
||||||
|
|
||||||
routerVal: "",
|
routerVal: "",
|
||||||
|
IMLink:"", // IM地址
|
||||||
|
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
|
|
||||||
|
computed:{
|
||||||
|
IM() {
|
||||||
|
return this.IMLink + this.storeDetail.merchantEuid;
|
||||||
|
},
|
||||||
|
},
|
||||||
|
|
||||||
watch: {
|
watch: {
|
||||||
isGroup(val) {
|
isGroup(val) {
|
||||||
if (val) {
|
if (val) {
|
||||||
|
@ -679,7 +688,7 @@ export default {
|
||||||
this.cartCount();
|
this.cartCount();
|
||||||
|
|
||||||
// 获取店铺推荐商品
|
// 获取店铺推荐商品
|
||||||
this.getstoreRecommend();
|
this.getStoreRecommend();
|
||||||
|
|
||||||
// 获取商品列表
|
// 获取商品列表
|
||||||
this.getOtherLikeGoods();
|
this.getOtherLikeGoods();
|
||||||
|
@ -688,11 +697,28 @@ export default {
|
||||||
if (this.$options.filters.isLogin("auth")) {
|
if (this.$options.filters.isLogin("auth")) {
|
||||||
this.getGoodsCollectionFun(this.goodsDetail.id);
|
this.getGoodsCollectionFun(this.goodsDetail.id);
|
||||||
}
|
}
|
||||||
|
// 获取IM 需要的话使用
|
||||||
|
// this.getIMDetailMethods();
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
|
async getIMDetailMethods(){
|
||||||
|
let res = await getIMDetail()
|
||||||
|
if(res.data.success){
|
||||||
|
this.IMLink = res.data.result
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
linkMsgDetail() {
|
linkMsgDetail() {
|
||||||
|
|
||||||
|
if(this.storeDetail.merchantEuid){
|
||||||
|
uni.navigateTo({
|
||||||
|
url:`/pages/tabbar/home/web-view?src=${this.IM}`
|
||||||
|
});
|
||||||
|
}
|
||||||
|
else{
|
||||||
// 客服
|
// 客服
|
||||||
// #ifdef MP-WEIXIN
|
// #ifdef MP-WEIXIN
|
||||||
|
|
||||||
const params = {
|
const params = {
|
||||||
storeName: this.storeDetail.storeName,
|
storeName: this.storeDetail.storeName,
|
||||||
goodsName: this.goodsDetail.goodsName,
|
goodsName: this.goodsDetail.goodsName,
|
||||||
|
@ -719,6 +745,7 @@ export default {
|
||||||
sign,
|
sign,
|
||||||
});
|
});
|
||||||
// #endif
|
// #endif
|
||||||
|
}
|
||||||
},
|
},
|
||||||
// 格式化金钱 1999 --> [1999,00]
|
// 格式化金钱 1999 --> [1999,00]
|
||||||
formatPrice(val) {
|
formatPrice(val) {
|
||||||
|
@ -834,7 +861,7 @@ export default {
|
||||||
/**
|
/**
|
||||||
* 获取店铺推荐商品列表
|
* 获取店铺推荐商品列表
|
||||||
*/
|
*/
|
||||||
getstoreRecommend() {
|
getStoreRecommend() {
|
||||||
getGoodsList({
|
getGoodsList({
|
||||||
pageNumber: 1,
|
pageNumber: 1,
|
||||||
pageSize: 6,
|
pageSize: 6,
|
||||||
|
|
Loading…
Reference in New Issue