master
parent
13ad619d26
commit
dea606c274
|
@ -2,6 +2,10 @@
|
|||
// launchtype项可配置值为local或remote, local代表前端连本地云函数,remote代表前端连云端云函数
|
||||
"version": "0.0",
|
||||
"configurations": [{
|
||||
"app-plus" :
|
||||
{
|
||||
"launchtype" : "local"
|
||||
},
|
||||
"default" :
|
||||
{
|
||||
"launchtype" : "local"
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
<template>
|
||||
<view v-if="isShowT" class="disjcac posAll">
|
||||
<view v-if="isShowT" class="disjcac posAll" @tap="closeXial">
|
||||
<view class="bacf radius20 width100 tank-box">
|
||||
<view v-if="isXiala" class="pad-x20">
|
||||
<view class="mar-s30 mar-x40 tc">请选择客服</view>
|
||||
<view @tap="openXia" class="disjbac radius10 pad-zy20 mar-zy20 xialak mar-x50 posir">
|
||||
<view @tap.stop="openXia" class="disjbac radius10 pad-zy20 mar-zy20 xialak mar-x50 posir">
|
||||
<view class="col3" v-if="!isTag">{{category[current].title}}</view>
|
||||
<view class="col3 disac width100" v-if="isTag"><input class="width100 mar-y20" disabled v-model="tagStr"></view>
|
||||
<image :class="isZhuan?'zhuan':'nozhuan'" src="/static/public/sanj.png" mode="aspectFill"></image>
|
||||
|
@ -11,14 +11,14 @@
|
|||
<view v-if="isZhuan" class="posia bacf radius10 xial-box">
|
||||
<!-- 普通下拉 -->
|
||||
<view class="pad-zy20 xial-item-box" v-if="!isTag">
|
||||
<view @tap="chooseXia(index)":class="current==index?'pcol':''" v-for="(item,index) in category" :key="index">{{item.title}}</view>
|
||||
<view @tap.stop="chooseXia(index)":class="current==index?'pcol':''" v-for="(item,index) in category" :key="index">{{item.title}}</view>
|
||||
</view>
|
||||
<!-- 标签下拉 -->
|
||||
<view class="pad-zy20 xial-item-box" v-if="isTag">
|
||||
<view class="disac" @tap.stop="quanEv" :class="isAll?'pcol':''">
|
||||
<!-- <view class="disac" @tap.stop="quanEv" :class="isAll?'pcol':''">
|
||||
<checkbox style="width: 60rpx;height: 60rpx;display: inherit;" color="#3875F6" :checked="isAll" />
|
||||
全选
|
||||
</view>
|
||||
</view> -->
|
||||
<view @tap.stop="chooseXiaTag(index)" class="disac" :class="item.checked?'pcol':''" v-for="(item,index) in category" :key="index">
|
||||
<view v-if="" class="disac">
|
||||
<checkbox style="width: 60rpx;height: 60rpx;display: inherit;" color="#3875F6" :data-id="item.id" :checked="item.checked" />
|
||||
|
@ -89,6 +89,10 @@
|
|||
};
|
||||
},
|
||||
methods:{
|
||||
// 关闭下拉
|
||||
closeXial(){
|
||||
this.isZhuan = false;
|
||||
},
|
||||
comfirEv(){//确认事件
|
||||
this.isZhuan = false
|
||||
this.current = 0
|
||||
|
|
|
@ -4,8 +4,8 @@ console.log('当前环境', process.env.NODE_ENV)
|
|||
const apiHub = {
|
||||
//开发环境
|
||||
development: {
|
||||
// BASE_URL: `https://hengmei.scdxtc.cn/api/`,
|
||||
BASE_URL: "https://hm.hmzfyy.cn/api/",
|
||||
BASE_URL: `https://hengmei.scdxtc.cn/api/`,
|
||||
// BASE_URL: "https://hm.hmzfyy.cn/api/",
|
||||
IMG_URL: "https://xx",
|
||||
BASE_UPLOAD_URL: "",
|
||||
},
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// const domainName = 'https://hengmei.scdxtc.cn/api/'//域名配置
|
||||
const domainName = 'https://hm.hmzfyy.cn/api/'//域名配置
|
||||
const domainName = 'https://hengmei.scdxtc.cn/api/'//域名配置
|
||||
// const domainName = 'https://hm.hmzfyy.cn/api/'//域名配置
|
||||
// 统一给参数
|
||||
const dataObj = (url, params) => {
|
||||
let options = params
|
||||
|
|
|
@ -291,7 +291,7 @@ const tools = {
|
|||
language:obj.language
|
||||
}
|
||||
uni.request({
|
||||
url: `https://hm.hmzfyy.cn/api/user/login`,
|
||||
url: `https://hengmei.scdxtc.cn/api/user/login`,
|
||||
method: 'post',
|
||||
data: params,
|
||||
header: {
|
||||
|
@ -301,7 +301,6 @@ const tools = {
|
|||
},
|
||||
success: res => {
|
||||
if(res.data.data.token!=''){
|
||||
uni.removeStorageSync('ninvite_code')
|
||||
uni.setStorageSync('token',res.data.data.token)//缓存token
|
||||
uni.setStorageSync('openid',res.data.data.openid)//缓存Openid
|
||||
uni.setStorageSync('expire',res.data.data.expire)//缓存失效时间(时间戳格式)
|
||||
|
@ -384,7 +383,7 @@ const tools = {
|
|||
},
|
||||
isVedio(){//是否显示视频内容
|
||||
uni.request({
|
||||
url: `https://hm.hmzfyy.cn/api/index/base-config`,
|
||||
url: `https://hengmei.scdxtc.cn/api/index/base-config`,
|
||||
method: 'get',
|
||||
header: {
|
||||
'Content-Type': 'application/json; charset=UTF-8',
|
||||
|
|
|
@ -412,7 +412,7 @@
|
|||
is_hot:1
|
||||
}
|
||||
uni.request({
|
||||
url:`https://hm.hmzfyy.cn/api/spu/list`,
|
||||
url:`https://hengmei.scdxtc.cn/api/spu/list`,
|
||||
data:params,
|
||||
method:'post',
|
||||
header:{
|
||||
|
|
|
@ -228,7 +228,7 @@
|
|||
customerInfo:'',
|
||||
times:0,
|
||||
openSettingBtnHidden: true,//是否授权
|
||||
optionObj:{}
|
||||
optionObj:{},
|
||||
}
|
||||
},
|
||||
onUnload: function() {
|
||||
|
@ -506,7 +506,8 @@
|
|||
this.tongList[0].num = res.data.score;//个人积分
|
||||
this.tongList[1].num = res.data.coin;//个人孔雀币
|
||||
this.tongList[2].num = res.data.continuity_sign;//个人连续签到
|
||||
this.toolsList[4].num = res.data.unread_messages;//分享人总数
|
||||
this.tongList[3].num = res.data.share_users.total;//分享人总数
|
||||
this.toolsList[4].num = res.data.unread_messages;//消息总数
|
||||
this.myOrderList[0].num = res.data.order_count.waiting;//待支付总数
|
||||
this.myOrderList[1].num = res.data.order_count.paid;//待发货总数
|
||||
this.myOrderList[2].num = res.data.order_count.shipped;//待收货总数
|
||||
|
|
|
@ -134,7 +134,7 @@
|
|||
isNewRenderDone:false ,//锁的作用
|
||||
isQuan:uni.getStorageSync('isQuan'),
|
||||
quanImg:uni.getStorageSync('quanImg'),
|
||||
isAutoPlay:false
|
||||
isAutoPlay:false,
|
||||
}
|
||||
},
|
||||
onPageScroll(e) {
|
||||
|
|
|
@ -203,6 +203,11 @@
|
|||
this.titleHeight = rect.height;
|
||||
}).exec()
|
||||
this.checkSX();
|
||||
let maiOjb = {
|
||||
e:12,//进入商城
|
||||
t:new Date().getTime()//当前时间戳
|
||||
}
|
||||
this.$toolAll.tools.maiDian(maiOjb)
|
||||
},
|
||||
methods: {
|
||||
chooseDoctor(index){//选择医生
|
||||
|
@ -306,7 +311,7 @@
|
|||
disease_id:this.disease_id//病种ID
|
||||
}
|
||||
uni.request({
|
||||
url:`https://hm.hmzfyy.cn/api/spu/list`,
|
||||
url:`https://hengmei.scdxtc.cn/api/spu/list`,
|
||||
data:params,
|
||||
method:'post',
|
||||
header:{
|
||||
|
|
|
@ -511,7 +511,7 @@
|
|||
this.$toolAll.tools.showToast('正在调起支付','loading',1500);
|
||||
}
|
||||
uni.request({
|
||||
url:`https://hm.hmzfyy.cn/api/order/create`,
|
||||
url:`https://hengmei.scdxtc.cn/api/order/create`,
|
||||
data:parmas,
|
||||
method:'post',
|
||||
header:{
|
||||
|
|
|
@ -90,6 +90,11 @@
|
|||
this.titleHeight = rect.height
|
||||
}).exec()
|
||||
this.checkList();
|
||||
let maiOjb = {
|
||||
e:12,//进入商城
|
||||
t:new Date().getTime()//当前时间戳
|
||||
}
|
||||
this.$toolAll.tools.maiDian(maiOjb)
|
||||
},
|
||||
methods: {
|
||||
loginEv(invite_code='',source='',channel=''){
|
||||
|
|
|
@ -30,23 +30,25 @@
|
|||
<view class="flexs">来源:{{item.come}}</view>
|
||||
</view>
|
||||
<view style="margin: 15rpx 0;">联系方式:{{item.phone || '暂无'}}</view>
|
||||
<view>客服:{{item.customer || '暂无'}}</view>
|
||||
<view>客服:{{item.service || '暂无'}}</view>
|
||||
<view class="col80 disjbac" style="margin: 15rpx 0 0 0;">
|
||||
<view>{{item.time}}</view>
|
||||
<view class="col3">{{item.qudao}}</view>
|
||||
</view>
|
||||
</view>
|
||||
<!-- 分配客服 -->
|
||||
<view @tap="fenCustomer(index)" class="posia colf fon24 radius10 tc customer-btn" style="right: 20rpx;top: 80rpx;z-index: 1;" v-if="item.customer=='' || item.customer==null" :style="{background:publicColor}">分配客服</view>
|
||||
<view @tap="tuneUpTag(index)" class="posia colf fon24 radius10 tc customer-btn" style="right: 20rpx;bottom: 20rpx;z-index: 1;" v-if="!item.tags.length" :style="{background:publicColor}">设置标签</view>
|
||||
<!-- 设置标签 -->
|
||||
<view @tap="tuneUpTag(index)" v-if="item.isTag" class="posia colf fon24 radius10 tc customer-btn" style="right: 20rpx;bottom: 20rpx;z-index: 1;" :style="{background:publicColor}">设置标签</view>
|
||||
<view class="fon24 col3 posia bold disac" style="bottom: 60rpx;left: 20rpx;right: 20rpx;"><text class="flexs">标签:</text>
|
||||
<block v-if="item.tags.length">
|
||||
<scroll-view scroll-x="true" >
|
||||
<view class="disac"><view v-for="(item1,tagIndex) in item.tags" :key="tagIndex" class="pcol pad-zy10">{{item1}}</view></view>
|
||||
<scroll-view scroll-x style="max-width: 60%;">
|
||||
<view class="disac"><view v-for="(item1,tagIndex) in item.tags" :key="tagIndex" class="pcol pad-zy10 flexs">{{item1}}</view></view>
|
||||
</scroll-view>
|
||||
</block>
|
||||
<block v-else class="col9">无</block>
|
||||
</view>
|
||||
<view class="fon24 col3 posia clips1 bold" style="bottom: 20rpx;left: 20rpx;right: 20rpx;">详细来源:{{item.source_detail}}</view>
|
||||
<view class="fon24 col3 posia clips1 bold" style="bottom: 20rpx;left: 20rpx;right: 20rpx;max-width: 70%;">详细来源:{{item.source_detail}}</view>
|
||||
</view>
|
||||
<view v-if="dataList.length==0" class="disjcac fc" style="margin-top: 50%;">
|
||||
<image class="zanw-img" src="/static/public/nothing.png" mode="aspectFill"></image>
|
||||
|
@ -55,12 +57,39 @@
|
|||
<!-- 分配客服弹框 -->
|
||||
<pu-po :category="xialtList" @chooseXiaT="chooseXiaT" :isXiala="true" :isShowT="isShowT" :clearVal="'暂不分配'" :comfrimVal="'立即分配'" @comfirmev="comfirmev" @cancleev="cancleev"></pu-po>
|
||||
<!-- 设置标签弹框 -->
|
||||
<pu-po :category="tagList" @chooseXiaT="chooseTag" :isXiala="true" :isTag="true" :isShowT="isShowTag" :clearVal="'暂不设置'" :comfrimVal="'立即设置'" @comfirmev="comfirmevTag" @cancleev="cancleevTag"></pu-po>
|
||||
<!-- <pu-po :category="tagList" @chooseXiaT="chooseTag" :isXiala="true" :isTag="true" :isShowT="isShowTag" :clearVal="'暂不设置'" :comfrimVal="'立即设置'" @comfirmev="comfirmevTag" @cancleev="cancleevTag"></pu-po> -->
|
||||
<!-- 返回顶部 -->
|
||||
<!-- <back-top :showTop="showTop" @backTop="backTop"></back-top> -->
|
||||
</view>
|
||||
<!-- 底部客服 -->
|
||||
<public-customer :nbottom="100"></public-customer>
|
||||
<view v-if="isShowTag" class="disjcac posAll" @tap="closeXial">
|
||||
<view class="bacf radius20 width100 tank-box">
|
||||
<view class="pad-x20">
|
||||
<view class="mar-s30 mar-x40 tc">请选择标签</view>
|
||||
<view @tap.stop="openXia" class="disjbac radius10 pad-zy20 mar-zy20 xialak mar-x50 posir">
|
||||
<view class="col3 disac width100"><input class="width100 mar-y20" disabled v-model="tagStr"></view>
|
||||
<image :class="isZhuan1?'zhuan':'nozhuan'" src="/static/public/sanj.png" mode="aspectFill"></image>
|
||||
<!-- 下拉列表 -->
|
||||
<view v-if="isZhuan1" class="posia bacf radius10 xial-box">
|
||||
<!-- 标签下拉 -->
|
||||
<view class="pad-zy20 xial-item-box">
|
||||
<view @tap.stop="chooseXiaTag(index)" class="disac" :class="item.checked?'pcol':''" v-for="(item,index) in tagList" :key="index">
|
||||
<view v-if="" class="disac">
|
||||
<checkbox style="width: 60rpx;height: 60rpx;display: inherit;" color="#3875F6" :data-id="item.id" :checked="item.checked" />
|
||||
</view>
|
||||
{{item.title}}
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="disjb fon28 colf pad-x30 pad-zy30 tc">
|
||||
<view @tap="cancleevTag" class="pad-sx20 radius10 tank-btn" style="background-color: rgba(230, 230, 230,1);color: #000000;">暂不设置</view>
|
||||
<view @tap="comfirmevTag" :style="{background:publicColor}" class="pad-sx20 radius10 tank-btn">立即设置</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
|
@ -76,6 +105,7 @@
|
|||
isShowT:false,
|
||||
isXiala:true,
|
||||
isZhuan:false,
|
||||
isZhuan1:false,
|
||||
xialCurrent:0,
|
||||
xialone:['全部'],
|
||||
xialtList:[],
|
||||
|
@ -90,7 +120,10 @@
|
|||
tag_id:'',
|
||||
isShowTag:false,
|
||||
tagId:'',
|
||||
searchVal:''
|
||||
searchVal:'',
|
||||
tagIds:[],
|
||||
tagVal:[],
|
||||
tagStr:'',
|
||||
}
|
||||
},
|
||||
onPageScroll(e) {
|
||||
|
@ -119,16 +152,47 @@
|
|||
this.obtainTag();//获取标签列表
|
||||
},
|
||||
methods: {
|
||||
// 关闭下拉
|
||||
closeXial(){
|
||||
// this.isShowTag = false;
|
||||
this.isZhuan1 = false;
|
||||
},
|
||||
openXia(){
|
||||
this.isZhuan1 = !this.isZhuan1
|
||||
},
|
||||
// 标签单选
|
||||
chooseXiaTag(index){
|
||||
let isexistence = this.tagIds.indexOf(this.tagList[index].id);
|
||||
this.tagList[index].checked = !this.tagList[index].checked;
|
||||
if(isexistence!=-1){
|
||||
this.tagIds.splice(isexistence,1);
|
||||
this.tagVal.splice(isexistence,1)
|
||||
} else {
|
||||
this.tagIds.push(this.tagList[index].id)
|
||||
this.tagVal.push(this.tagList[index].title)
|
||||
}
|
||||
this.tagStr = this.tagVal.join(',');
|
||||
this.tagId = this.tagIds.join(',');
|
||||
// 单选时,控制全选按钮是否选中
|
||||
if(this.tagIds.length==this.tagList.length){
|
||||
this.isAll = true;
|
||||
} else this.isAll = false;
|
||||
if(!this.tagIds.length) {
|
||||
this.tagStr = '请选择'
|
||||
}
|
||||
},
|
||||
obtainTag(){//获取标签列表
|
||||
this.$requst.post('user/tag-list').then(res=>{
|
||||
// console.log('查询客户列表:',res);
|
||||
if(res.code==0){
|
||||
this.tagList = [];
|
||||
if(res.data.length!=0){
|
||||
res.data.forEach(item=>{
|
||||
let xuan = false;
|
||||
let obj = {
|
||||
title:item.name,
|
||||
id:item.id,
|
||||
checked:false
|
||||
checked:xuan
|
||||
}
|
||||
this.tagList.push(obj)
|
||||
})
|
||||
|
@ -140,6 +204,26 @@
|
|||
tuneUpTag(index){
|
||||
// console.log('分配客服调起弹框');
|
||||
this.isShowTag = true
|
||||
this.tagStr = '';
|
||||
this.tagId = '';
|
||||
this.tagIds = [];
|
||||
this.tagVal = [];
|
||||
this.tagList.forEach((item,v)=>{
|
||||
item.checked = false;
|
||||
if(this.dataList[index].tags.length) {
|
||||
this.dataList[index].tags.forEach(item1=>{
|
||||
if(item.title == item1){
|
||||
this.tagList[v].checked = true;
|
||||
}
|
||||
})
|
||||
if(item.checked){
|
||||
this.tagIds.push(item.id);
|
||||
this.tagVal.push(item.title)
|
||||
}
|
||||
}
|
||||
})
|
||||
this.tagStr = this.tagVal.join(',');
|
||||
this.tagId = this.tagIds.join(',');
|
||||
// 客服列表
|
||||
this.customer_id = this.dataList[index].id//客户ID
|
||||
if(this.tagList.length==0) this.tagList = ['暂无可设置的标签']
|
||||
|
@ -201,9 +285,10 @@
|
|||
qudao:item.tag[0],
|
||||
service:item.service,
|
||||
source_detail:item.source_detail,
|
||||
tags:item.tag
|
||||
tags:item.tag,
|
||||
isTag:!item.tag.includes('员工')
|
||||
}
|
||||
this.dataList.push(cuObj)
|
||||
this.dataList.push(cuObj);
|
||||
})
|
||||
}
|
||||
this.isZhuan = false;
|
||||
|
@ -232,7 +317,7 @@
|
|||
this.page = 1
|
||||
this.$toolAll.tools.showToast('分配成功')
|
||||
this.checkCL(this.ntype)//客户列表
|
||||
}
|
||||
} else this.$toolAll.tools.showToast(res.msg)
|
||||
},error=>{})
|
||||
},
|
||||
// 立即设置标签
|
||||
|
@ -244,6 +329,7 @@
|
|||
if(res.code==0){
|
||||
this.page = 1
|
||||
this.$toolAll.tools.showToast('设置成功')
|
||||
this.obtainTag();
|
||||
this.isShowTag = false
|
||||
this.checkCL(this.ntype)//客户列表
|
||||
} else this.$toolAll.tools.showToast(res.msg)
|
||||
|
@ -269,11 +355,6 @@
|
|||
chooseXiaT(e){
|
||||
this.staff_id = e.id
|
||||
},
|
||||
// 标签选择
|
||||
chooseTag(e){
|
||||
this.tagId = e.id;
|
||||
this.tagList = e.arr;
|
||||
},
|
||||
entryEv(){
|
||||
this.isXiala = true;
|
||||
}
|
||||
|
|
|
@ -238,7 +238,7 @@
|
|||
if(index==1){
|
||||
this.isWen = false;
|
||||
uni.request({
|
||||
url:`https://hm.hmzfyy.cn/api/spu/collection`,
|
||||
url:`https://hengmei.scdxtc.cn/api/spu/collection`,
|
||||
data:{page:this.page,size:this.size},
|
||||
method:'post',
|
||||
header:{
|
||||
|
|
|
@ -146,6 +146,11 @@
|
|||
checkPeople(){//查询分享一二级列表人数
|
||||
this.$requst.post('user/share-users',{grade:this.cateList[this.flag].grade,page:this.page,size:this.size}).then(res=>{
|
||||
console.log('查询分享一二级列表人数列表:',res);
|
||||
if(this.flag){
|
||||
this.dataList[1] = [];
|
||||
} else {
|
||||
this.dataList[0] = [];
|
||||
}
|
||||
if(res.code==0){
|
||||
if(res.data.list.length!=0){
|
||||
res.data.list.forEach(item=>{
|
||||
|
@ -170,7 +175,8 @@
|
|||
});
|
||||
},
|
||||
chooseye(index){
|
||||
this.flag = index
|
||||
this.flag = index;
|
||||
this.checkPeople();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -247,46 +247,41 @@
|
|||
this.isAutoPlay = false;
|
||||
},
|
||||
onLoad(options) {
|
||||
//查询过期时间和是否有token,并调用登录事件
|
||||
this.$toolAll.tools.overdue();
|
||||
if (options.category_id != undefined) {
|
||||
this.category_id = options.category_id
|
||||
this.conid = options.id
|
||||
this.invite_code = options.invite_code
|
||||
uni.setStorageSync('ninvite_code', this.invite_code)
|
||||
if (this.invite_code != '' && this.invite_code != undefined) {
|
||||
this.loginEv(this.invite_code);
|
||||
} else if (options.source_code != '' && options.source_code != undefined) {
|
||||
this.loginEv('', options.source_code, options.channel);
|
||||
} else {
|
||||
this.$toolAll.tools.overdue()
|
||||
this.$toolAll.tools.isLogin()
|
||||
}
|
||||
}
|
||||
this.checkDetail(this.conid)
|
||||
if (options.share_id != undefined) this.share_id = options.share_id
|
||||
if(options.invite_code!=undefined){this.invite_code = options.invite_code;}
|
||||
if (options.share_id != undefined){this.share_id = options.share_id;}
|
||||
this.checkDetail(options.id);
|
||||
let maiOjb = {
|
||||
e: 4, //内容分享
|
||||
c: this.conid * 1,
|
||||
e: 1, //内容访问
|
||||
c: options.id * 1,
|
||||
t: new Date().getTime() //当前时间戳
|
||||
}
|
||||
this.$toolAll.tools.maiDian(maiOjb)
|
||||
this.$toolAll.tools.maiDian(maiOjb);
|
||||
if(uni.getStorageSync('phone_active')!=1){
|
||||
this.vision = true;
|
||||
this.loginEv(options);
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
loginEv(invite_code = '', source = '', channel = '') {
|
||||
loginEv(options) {
|
||||
uni.login({
|
||||
provider: 'weixin',
|
||||
success: (res) => {
|
||||
if (res.code) {
|
||||
var params = {
|
||||
code: res.code,
|
||||
invite_code: invite_code, //用户邀请码
|
||||
source_code: source,
|
||||
channel: channel
|
||||
invite_code: options.invite_code || '', //用户邀请码
|
||||
source_code: options.source_code || '',
|
||||
channel: options.channel || ''
|
||||
}
|
||||
this.$requst.post('user/login', params).then(res => {
|
||||
if (res.data.token != '') {
|
||||
if (res.data.is_active == 0) {
|
||||
this.haveImg = false;
|
||||
this.vision = true;
|
||||
}
|
||||
}
|
||||
}, error => {})
|
||||
|
@ -349,9 +344,7 @@
|
|||
})
|
||||
},
|
||||
lianK() { //客服
|
||||
if (this.haveImg == false) {
|
||||
this.vision = true
|
||||
} else {
|
||||
if (this.haveImg) {
|
||||
this.$requst.post('user/rand-bind-service').then(res => {})
|
||||
this.$toolAll.tools.closeTimer() //清空埋点倒计时
|
||||
this.$requst.post('user/record', {
|
||||
|
@ -364,9 +357,9 @@
|
|||
t: new Date().getTime() //当前时间戳
|
||||
}
|
||||
this.$toolAll.tools.maiDian(maiOjb);
|
||||
} else {
|
||||
this.vision = true
|
||||
}
|
||||
// } else this.jieDuan = true
|
||||
// }
|
||||
},
|
||||
shareEv() {
|
||||
if (this.haveImg == false) {
|
||||
|
@ -591,9 +584,7 @@
|
|||
}, error => {})
|
||||
},
|
||||
tapLike() { //喜欢、不喜欢事件
|
||||
// if(!this.jieDuan){
|
||||
// let isAuth = this.$toolAll.tools.returnAuth()
|
||||
// if(!isAuth){
|
||||
if(this.haveImg){
|
||||
this.isDetailLike = !this.isDetailLike
|
||||
if (this.isDetailLike) {
|
||||
this.detailObj.likes++
|
||||
|
@ -614,14 +605,14 @@
|
|||
action: isLikeCon,
|
||||
archive_id: this.detailObj.id
|
||||
})
|
||||
// } else this.jieDuan = true
|
||||
// }
|
||||
} else {
|
||||
// 调起授权弹框
|
||||
this.vision = true;
|
||||
}
|
||||
},
|
||||
tapConllection() { //收藏、取消收藏事件
|
||||
let isLikeCon = 'collect'
|
||||
// if(!this.jieDuan){
|
||||
// let isAuth = this.$toolAll.tools.returnAuth()
|
||||
// if(!isAuth){
|
||||
if(this.haveImg){
|
||||
// 调用收藏事件
|
||||
if (!this.isDetailConllection) collectionEV({
|
||||
action: isLikeCon,
|
||||
|
@ -633,8 +624,10 @@
|
|||
archive_id: this.detailObj.id
|
||||
})
|
||||
this.isDetailConllection = !this.isDetailConllection
|
||||
// } else this.jieDuan = true
|
||||
// }
|
||||
} else {
|
||||
// 调起授权弹框
|
||||
this.vision = true;
|
||||
}
|
||||
},
|
||||
backTop() { //回到顶部事件
|
||||
uni.pageScrollTo({
|
||||
|
|
|
@ -198,7 +198,7 @@
|
|||
</view>
|
||||
</view>
|
||||
<!-- 立即购买,加入购物车弹框 -->
|
||||
<view v-if="showTK" class="posAll" @tap="showTK=false">
|
||||
<view v-if="showTK" class="posAll" style="z-index: 1000;" @tap="showTK=false">
|
||||
<view class="bacf posixzy bottom-popu" @tap.stop="showTK=true">
|
||||
<view class="disjb pad-zy50">
|
||||
<image :src="zhuImg" mode="aspectFill"></image>
|
||||
|
@ -362,10 +362,10 @@
|
|||
},
|
||||
onShareAppMessage(res) {
|
||||
var ya = this;
|
||||
this.$requst.post('user/record',{type:'content',action:'share',id:this.detailObj.spu_id}).then(res=>{console.log('分享成功:',res);},error=>{})
|
||||
this.$requst.post('user/record',{type:this.detailObj.is_activity==0 ? 'spu':'activity',action:'share',id:this.detailObj.id}).then(res=>{console.log('分享成功:',res);},error=>{})
|
||||
let maiOjb = {
|
||||
e:4,//内容分享
|
||||
c:this.detailObj.spu_id*1,
|
||||
e:this.detailObj.is_activity==0 ? 10 : 11,//商品分享(10普通商品,11活动商品)
|
||||
c: this.detailObj.is_activity==0 ? this.detailObj.id*1 : this.detailObj.activity_id,
|
||||
t:new Date().getTime()//当前时间戳
|
||||
}
|
||||
this.$toolAll.tools.maiDian(maiOjb)
|
||||
|
@ -391,30 +391,18 @@
|
|||
this.isAutoPlay = false;
|
||||
},
|
||||
onLoad(options) {
|
||||
if(uni.getStorageSync('is_active')!=1){this.vision = true;}
|
||||
//查询过期时间和是否有token,并调用登录事件
|
||||
this.$toolAll.tools.overdue();
|
||||
if(uni.getStorageSync('is_active')!=1){
|
||||
this.vision = true;
|
||||
this.loginEv(options);
|
||||
}
|
||||
if(options.category_id!=undefined) {
|
||||
this.category_id = options.category_id
|
||||
this.conid = options.id
|
||||
this.invite_code = options.invite_code
|
||||
uni.setStorageSync('ninvite_code',this.invite_code)
|
||||
if(this.invite_code!='' && this.invite_code!=undefined){
|
||||
this.loginEv(this.invite_code);
|
||||
} else if(options.source_code!='' && options.source_code!=undefined){
|
||||
this.loginEv('',options.source_code,options.channel);
|
||||
} else {
|
||||
this.$toolAll.tools.overdue()
|
||||
this.$toolAll.tools.isLogin()
|
||||
}
|
||||
}
|
||||
if(options.share_id!=undefined) this.share_id = options.share_id
|
||||
let maiOjb = {
|
||||
e:4,//内容分享
|
||||
c:this.conid*1,
|
||||
t:new Date().getTime()//当前时间戳
|
||||
}
|
||||
this.$toolAll.tools.maiDian(maiOjb);
|
||||
if(options.isIntegral=="true"){this.isScore = 3;}
|
||||
console.log(options.id,options.is_activity,'123');
|
||||
this.checkDetail(options.id,options.is_activity);
|
||||
this.cartNumEv();
|
||||
// 如果链接是拼团链接,则调起发起拼团人的商品
|
||||
|
@ -447,22 +435,21 @@
|
|||
} else this.$toolAll.tools.showToast(res.msg);
|
||||
})
|
||||
},
|
||||
loginEv(invite_code='',source='',channel=''){
|
||||
loginEv(options){
|
||||
uni.login({
|
||||
provider: 'weixin',
|
||||
success: (res)=> {
|
||||
if (res.code) {
|
||||
var params = {
|
||||
code:res.code,
|
||||
invite_code:invite_code,//用户邀请码
|
||||
source_code:source,
|
||||
channel:channel
|
||||
invite_code:options.invite_code || '',//用户邀请码
|
||||
source_code:options.source_code || '',
|
||||
channel:options.channel || ''
|
||||
}
|
||||
this.$requst.post('user/login',params).then(res => {
|
||||
if(res.data.token!=''){
|
||||
if(res.data.is_active==0) {
|
||||
this.haveImg = false;
|
||||
this.vision = true;
|
||||
}
|
||||
}
|
||||
},error => {})
|
||||
|
@ -488,7 +475,7 @@
|
|||
},
|
||||
checkPTList(id){//查询正在拼团的人数
|
||||
uni.request({
|
||||
url:`https://hm.hmzfyy.cn/api/spu/group-list`,
|
||||
url:`https://hengmei.scdxtc.cn/api/spu/group-list`,
|
||||
data:{id:id},
|
||||
method:'post',
|
||||
header:{
|
||||
|
@ -626,7 +613,7 @@
|
|||
this.$toolAll.tools.closeTimer()//清空埋点倒计时
|
||||
this.$requst.post('user/record',{type:'other',action:'ask',id:0}).then(res=>{},error=>{})
|
||||
let maiOjb = {
|
||||
e:5,//内容咨询
|
||||
e:this.detailObj.is_activity==0 ? 13:14,//商品咨询(13普通商品,14活动商品)
|
||||
t:new Date().getTime()//当前时间戳
|
||||
}
|
||||
this.$toolAll.tools.maiDian(maiOjb)
|
||||
|
@ -666,7 +653,7 @@
|
|||
},
|
||||
checkDetail(newId,is_activity){
|
||||
uni.request({
|
||||
url:`https://hm.hmzfyy.cn/api/spu/detail`,
|
||||
url:`https://hengmei.scdxtc.cn/api/spu/detail`,
|
||||
data:{id:newId,is_activity:is_activity},
|
||||
method:'post',
|
||||
header:{
|
||||
|
@ -739,8 +726,8 @@
|
|||
}
|
||||
}
|
||||
let maiOjb = {
|
||||
e:1,//内容访问
|
||||
c:this.detailObj.spu_id*1,
|
||||
e:this.detailObj.is_activity==0 ? 8 : 9,//商品访问(8普通,9活动)
|
||||
c: this.detailObj.is_activity==0 ? this.detailObj.id*1 : this.detailObj.activity_id,
|
||||
t:new Date().getTime()//当前时间戳
|
||||
}
|
||||
this.$toolAll.tools.maiDian(maiOjb)
|
||||
|
@ -804,7 +791,7 @@
|
|||
disease_id:''//病种ID
|
||||
}
|
||||
uni.request({
|
||||
url:`https://hm.hmzfyy.cn/api/spu/list`,
|
||||
url:`https://hengmei.scdxtc.cn/api/spu/list`,
|
||||
data:params,
|
||||
method:'post',
|
||||
header:{
|
||||
|
|
|
@ -274,7 +274,7 @@
|
|||
size:this.size,
|
||||
}
|
||||
uni.request({
|
||||
url:`https://hm.hmzfyy.cn/api/spu/list`,
|
||||
url:`https://hengmei.scdxtc.cn/api/spu/list`,
|
||||
data:params,
|
||||
method:'post',
|
||||
header:{
|
||||
|
|
|
@ -14,8 +14,8 @@
|
|||
</view>
|
||||
</view>
|
||||
<!-- 列表 -->
|
||||
<view @tap="chooseId(item.id)" class="bacf radius10 pad20 mar-x20 fon28" v-for="(item,index) in dataList" :key="index">
|
||||
<view style="color: #B3B3B3;">{{item.time}}</view>
|
||||
<view @tap="chooseId(item.id)" v-if="item.name!=null" class="bacf radius10 pad20 mar-x20 fon28" v-for="(item,index) in dataList" :key="index">
|
||||
<view style="color: #B3B3B3;" class="disjbac">{{item.time}} <view>{{item.mobile}}</view></view>
|
||||
<view class="mar-s20">
|
||||
<text class="bold col3">{{item.name}}</text>
|
||||
<text style="color: #B3B3B3;">{{item.action}}</text>
|
||||
|
@ -23,12 +23,12 @@
|
|||
<text style="color: #B3B3B3;" v-if="item.zwhat!=null && item.zwhat!=''">{{item.zwhat}}</text>
|
||||
</view>
|
||||
</view>
|
||||
<view v-if="dataList.length==0" class="disjcac fc" style="margin-top: 50%;">
|
||||
<view v-if="dataList.length==0 && keyword!=''" class="disjcac fc" style="margin-top: 50%;">
|
||||
<image class="zanw-img" src="/static/public/nothing.png" mode="aspectFill"></image>
|
||||
<view class="fon24 col3">您搜索的内容暂无结果,换个关键词试试吧</view>
|
||||
</view>
|
||||
<!-- 返回顶部 -->
|
||||
<back-top :showTop="showTop" @backTop="backTop"></back-top>
|
||||
<!-- <back-top :showTop="showTop" @backTop="backTop"></back-top> -->
|
||||
</view>
|
||||
<!-- 底部客服 -->
|
||||
<public-customer :nbottom="100"></public-customer>
|
||||
|
@ -131,7 +131,8 @@
|
|||
page:this.page,
|
||||
size:this.size,
|
||||
customer_id:this.customer_id,//客户ID
|
||||
keyword:this.keyword
|
||||
keyword:this.keyword,
|
||||
// user_id:uni.getStorageSync('userId')
|
||||
}
|
||||
this.$requst.post('user/footmarks',params).then(res=>{
|
||||
// console.log('足迹列表查询:',res);
|
||||
|
@ -150,6 +151,7 @@
|
|||
title:item.title,
|
||||
time:item.created_at,
|
||||
zwhat:newCate,
|
||||
mobile:item.mobile
|
||||
}
|
||||
this.dataList.push(obj)
|
||||
})
|
||||
|
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue