修改bug

master
chen 2022-07-22 18:39:41 +08:00
parent 738ef6de93
commit 008cfca588
34 changed files with 158 additions and 79 deletions

View File

@ -9,11 +9,11 @@
<view class="posia fon24 colf" style="right: 10rpx;top: 40rpx;z-index: 1;">
<view @tap.stop="praiseEv(index)" class="disjcac fc">
<image class="img-box" lazy-load :style="{width: radiu ?'40rpx':'60rpx',height: radiu ?'40rpx':'60rpx'}" :src="['/static/public/list-nlike.png','/static/public/detail-like.png'][item.is_liked]" mode="aspectFill"></image>
<view style="text-shadow: 0px 0px 3px #000000;">{{item.likes>1000 ? '999':item.likes}}</view>
<view style="text-shadow: 0px 0px 3px #000000;">{{item.likes>1000 ? '999+':item.likes}}</view>
</view>
<view @tap.stop="chooseLike(index)" class="disjcac fc mar-s10">
<image class="img-box" lazy-load :style="{width: radiu ?'40rpx':'60rpx',height: radiu ?'40rpx':'60rpx'}" :src="['/static/public/cnllection-no.png','/static/public/yconllection.png'][item.is_collected]" mode="aspectFill"></image>
<view style="text-shadow: 0px 0px 3px #000000;">{{item.collects>1000 ? '999':item.collects}}</view>
<view style="text-shadow: 0px 0px 3px #000000;">{{item.collects>1000 ? '999+':item.collects}}</view>
</view>
</view>
<!-- <view class="posia list-like-box" @tap.stop="chooseLike(index)"> -->
@ -51,11 +51,11 @@
<view class="posia fon24 colf" style="right: 10rpx;top: 40rpx;z-index: 1;">
<view @tap.stop="praiseEv(index)" class="disjcac fc">
<image class="img-box" lazy-load :style="{width: radiu ?'40rpx':'60rpx',height: radiu ?'40rpx':'60rpx'}" :src="['/static/public/list-nlike.png','/static/public/detail-like.png'][item.is_liked]" mode="aspectFill"></image>
<view style="text-shadow: 0px 0px 3px #000000;">{{item.likes>1000 ? '999':item.likes}}</view>
<view style="text-shadow: 0px 0px 3px #000000;">{{item.likes>1000 ? '999+':item.likes}}</view>
</view>
<view @tap.stop="chooseLike(index)" class="disjcac fc mar-s10">
<image class="img-box" lazy-load :style="{width: radiu ?'40rpx':'60rpx',height: radiu ?'40rpx':'60rpx'}" :src="['/static/public/cnllection-no.png','/static/public/yconllection.png'][item.is_collected]" mode="aspectFill"></image>
<view style="text-shadow: 0px 0px 3px #000000;">{{item.collects>1000 ? '999':item.collects}}</view>
<view style="text-shadow: 0px 0px 3px #000000;">{{item.collects>1000 ? '999+':item.collects}}</view>
</view>
</view>
<!-- <view class="posia list-like-box" @tap.stop="chooseLike(index)"> -->

View File

@ -66,16 +66,34 @@
uni.setStorageSync('paramsUrl',currentPage.$page.fullPath);
// console.log(uni.getStorageSync('paramsUrl'),66);
// console.log(uni.getStorageSync('url'),64);
if(currentPage.$page.fullPath.indexOf('channel')>=0 || currentPage.$page.fullPath.indexOf('invite_code')>=0){
let params = {
path:currentPage.$page.fullPath,
openid:uni.getStorageSync('openid')
}
this.$requst.post('user/unusual-enter',params).then(res=>{
if(res.code==0){
}
})
if(currentPage.options.invite_code){
uni.login({
provider: 'weixin',
success: (res)=> {
if (res.code) {
var params = {
code: res.code,
invite_code: currentPage.options.invite_code || '', //
source_code: currentPage.options.source_code || '', //
channel: currentPage.options.channel || ''
}
uni.request({
url: `${uni.getStorageSync('hostapi')}user/login`,
method: 'GET',
data: params,
success: res => {
this.$requst.post('user/unusual-enter',{
path:currentPage.$page.fullPath,
openid:res.data.data.openid
}).then(res=>{
if(res.code==0){
}
})
},
})
}
},
});
}
},
data() {

View File

@ -342,7 +342,7 @@ const tools = {
uni.setStorageSync('hostapi','https://hengmei.scdxtc.cn/api/');
// uni.setStorageSync('hostapi','https://hm.hmzfyy.cn/api/');
// 开启埋点倒计时
this.daoTime();//开启埋点倒计时
// this.daoTime();//开启埋点倒计时
} else {
// 清除所有输出日志
console.log = () =>{};

View File

@ -290,13 +290,13 @@
},
praiseEv(e){ //
// console.log(this.dataList[e].is_collected);
if(this.dataList[e].is_liked==0){
// if(this.dataList[e].is_liked==0){
this.dataList[e].is_liked = 1;
this.dataList[e].likes++;
if(this.dataList[e].likes>1000) this.dataList[e].likes = '999+'
// if(this.dataList[e].likes>1000) this.dataList[e].likes = '999+'
//
collectionEV({action:'like',archive_id:this.dataList[e].id})
}
// }
},
comfirmev(e){//
this.dataList[e].is_collected = 0

View File

@ -229,6 +229,10 @@
uni.setStorageSync('is_active',res.data.is_active)//
uni.setStorageSync('token',res.data.token);
uni.setStorageSync('openid',res.data.openid)//openid
this.$requst.post('user/unusual-enter',{
path:this.pagePath,
openid:res.data.openid
}).then(res=>{})
if(res.data.is_active==0 || res.data.phone_active==0) {
this.$requst.post('user/first-enter',{openid:res.data.openid,path:this.pagePath}).then(res=>{})
}
@ -266,6 +270,12 @@
uni.setStorageSync('is_active',res.data.is_active)//
uni.setStorageSync('token',res.data.token);
uni.setStorageSync('openid',res.data.openid)//openid
if(option.invite_code){
this.$requst.post('user/unusual-enter',{
path:this.pagePath,
openid:res.data.openid
}).then(res=>{})
}
if(res.data.is_active==0 || res.data.phone_active==0) {
this.$requst.post('user/first-enter',{openid:res.data.openid,path:this.pagePath}).then(res=>{})
}
@ -464,12 +474,12 @@
},
praiseEv(e){ //
// console.log(this.dataList[e].is_collected);
if(this.dataList[e].is_liked==0){
// if(this.dataList[e].is_liked==0){
this.dataList[e].is_liked = 1;
this.dataList[e].likes++;
//
collectionEV({action:'like',archive_id:this.dataList[e].id})
}
// }
},
chooseLike(e){//
// console.log(this.dataList[e].is_collected);

View File

@ -51,7 +51,7 @@
<view>
<view class="" v-if="1===2">
<!-- <view v-if="item.is_only==0 && item.open_one==1 && item.is_group_make==1 && item.open_one_success==0" class="posir disjcac flexs" style="color: #010101;font-size: 24rpx;"> -->
<view v-if="item.is_only==0 && item.group.surplus > 0" class="posir disjcac flexs" style="color: #010101;font-size: 24rpx;">
<view v-if="item.is_only==0 && item.group.surplus > 0 && item.status_text=='待拼成'" class="posir disjcac flexs" style="color: #010101;font-size: 24rpx;">
<image src="../../static/public/weix.png" mode="" class="flexs" style="width: 50rpx;height: 50rpx;"></image>
邀请拼单
<button open-type="share"
@ -70,21 +70,21 @@
<view class="disjbac" v-if="item.group">
<view class="width100 disje">
<view class="" v-if="item.group">
<view v-if="item.group.surplus > 0">
<view v-if="item.group.surplus > 0 && item.status_text=='待拼成'">
<view @tap="comeing(item.orderNum)" v-if="item.is_only==0 && item.open_one==1 && item.is_group_make==1 && item.open_one_success==0" class="order-btn mar-y20"></view>
</view>
</view>
<view @tap="transferFrame(index)" v-if="item.orderStatus != 0 && item.orderStatus != 5 && item.virtual_check==0 && item.orderStatus!=5" class="order-cancle"></view>
<view @tap="payMentEv(index)" v-if="item.orderStatus == 1" class="order-btn"></view>
<!-- <view class="order-btn" v-if="item.is_only==1"></view> -->
<view v-if="item.group.surplus > 0" class="order-btn" style="background-color: #38CE51;position: relative;">
邀请拼单
<button open-type="share"
:data-title="item.childrenList[0].title"
:data-is_activity="item.childrenList[0].is_activity"
:data-imgsrc="item.childrenList[0].imgSrc"
:data-id="item.childrenList[0].spu_activity_id || item.childrenList[0].sku_id"
class="posia-op">邀请拼单</button>
<view v-if="item.group.surplus > 0 && item.status_text=='待拼成'" class="order-btn" style="background-color: #38CE51;position: relative;">
邀请拼单
<button open-type="share"
:data-title="item.childrenList[0].title"
:data-is_activity="item.childrenList[0].is_activity"
:data-imgsrc="item.childrenList[0].imgSrc"
:data-id="item.childrenList[0].spu_activity_id || item.childrenList[0].sku_id"
class="posia-op">邀请拼单</button>
</view>
<view @tap="confirmReceipt(item.id)" v-if="item.orderStatus == 4 && item.group.surplus == 0" class="order-btn"></view>
</view>
@ -344,6 +344,13 @@
}
nchildren.push(objs);
})
let expiredTime = '';
//
let currentTime = new Date().getTime();
if(item.group.expired_at){
//
expiredTime = this.$toolAll.tools.timeToTimestamp(item.group.expired_at);
}
let obj = {
id:item.id,
establish:item.created_at,//
@ -360,7 +367,7 @@
is_group_make:item.is_group_make,
group_make_end_at:item.group_make_end_at,
group_id:item.group_id,
status_text: item.group!=null && item.status_text!='已完成' && item.status_text!='待付款' ? (item.group.surplus > 0 ? '待拼成' : item.status_text) : item.status_text,//
status_text: item.group!=null && item.status_text!='已完成' && item.status_text!='待付款' ? (item.group.surplus > 0 ? ((expiredTime-currentTime)>0 ? '待拼成' : '已拼成') : item.status_text) : item.status_text,//
group:item.group//
}
this.zanArr.push(obj);

View File

@ -177,13 +177,13 @@
},
praiseEv(e){ //
// console.log(this.dataList[e].is_collected);
if(this.dataList[e].is_liked==0){
// if(this.dataList[e].is_liked==0){
this.dataList[e].is_liked = 1;
this.dataList[e].likes++;
if(this.dataList[e].likes>1000) this.dataList[e].likes = '999+'
// if(this.dataList[e].likes>1000) this.dataList[e].likes = '999+'
//
collectionEV({action:'like',archive_id:this.dataList[e].id})
}
// }
},
comfirmev(e){//
this.dataList[e].is_collected = 0

View File

@ -130,7 +130,7 @@
</template>
<script>
import {cancleCollectionEV,cancleCollectionShopEV} from '@/jsFile/publicAPI.js';
import {cancleCollectionEV,cancleCollectionShopEV,collectionEV} from '@/jsFile/publicAPI.js';
import shopList from '@/components/shop-list.vue';
import bottomTab from '@/components/bottom-tab.vue';
export default {
@ -205,13 +205,12 @@
methods: {
praiseEv(e){ //
// console.log(this.dataList[e].is_collected);
if(this.dataList[e].is_liked==0){
// if(this.dataList[e].is_liked==0){
this.dataList[e].is_liked = 1;
this.dataList[e].likes++;
if(this.dataList[e].likes>1000) this.dataList[e].likes = '999+'
//
collectionEV({action:'like',archive_id:this.dataList[e].id})
}
// }
},
shopCollection(index){//
clearInterval(this.collectionTime);

View File

@ -102,7 +102,7 @@
<view class="disac paid-btn-box" v-if="orderInfo.status=='shipped'">
<view @tap="cancleEv"></view>
<!-- 邀请拼单 -->
<view class="orderInfo-btn" v-if="groupMakeDone==0" style="background-color: #38CE51;position: relative;">
<view class="orderInfo-btn" v-if="groupMakeDone==0 && ifExpire" style="background-color: #38CE51;position: relative;">
邀请拼单
<button open-type="share"
:data-title="orderInfo.skus[0].spu_name"
@ -164,6 +164,7 @@
daoTime:'',
timerDao:null,
groupMakeDone:1,//
ifExpire:false,//
}
},
computed:{
@ -281,7 +282,6 @@
},
checkInfo(id){//
this.$requst.post('user/order-detail',{id:id}).then(res=>{
console.log(res,12121212)
if(res.code==0){
this.allPrice = 0;
this.allNum = 0;
@ -302,6 +302,16 @@
} else {//
this.allPrice = this.allPrice;
}
// start
let expiredTime = '';
//
let currentTime = new Date().getTime();
if(narr.group.expired_at){
//
expiredTime = this.$toolAll.tools.timeToTimestamp(narr.group.expired_at);
}
this.ifExpire = (expiredTime - currentTime)>0 ? true : false;
// end
this.orderInfo = narr;
if(this.orderInfo.group_make_end_at!=null){
this.daoTime = this.$toolAll.tools.dayTime(this.orderInfo.group_make_end_at,new Date().getTime());

View File

@ -99,7 +99,9 @@
<!-- 返回顶部 -->
<!-- <back-top :showTop="showTop" @backTop="backTop"></back-top> -->
<!-- 用户信息授权手机号授权 -->
<auth-userInfo-mobileInfo></auth-userInfo-mobileInfo>
<view v-if="ifNeedAuth">
<auth-userInfo-mobileInfo></auth-userInfo-mobileInfo>
</view>
<!-- 底部导航 -->
<view class="posixzy">
<bottom-tab></bottom-tab>
@ -164,6 +166,7 @@
newHeight:'450',
ifSwiper:0,//swiper
shareFlag:true,
ifNeedAuth:false,//
}
},
computed: {
@ -228,6 +231,14 @@
// tools.js
this.$toolAll.tools.plantPoint(1,options.id);
}
} else {
console.log(options);
if (options.category_id != undefined) {
this.category_id = options.category_id
this.checkDetail(options.id);
// tools.js
this.$toolAll.tools.plantPoint(1,options.id);
}
}
},
methods: {
@ -331,6 +342,7 @@
//
if (item.active == 1) this.active = this.cateCurrent = index
//
console.log(this.category_id,item.id);
if (this.category_id == item.id) this.isNum = index
})
this.contentVal = this.cateList[this.cateCurrent].title.slice(2);
@ -338,8 +350,12 @@
this.newHeight = '200';
}
}
console.log(this.isNum,this.cateCurrent);
//
this.detailObj = res.data.detail;
if(uni.getStorageSync('phone_active')!=1){
this.ifNeedAuth = this.detailObj.need_permission ? true : false;
}
// swiper
this.ifSwiper = this.detailObj.images_show;
if (this.detailObj.published_headimgurl != '') {
@ -527,26 +543,27 @@
}, error => {this.$toolAll.tools.showToast(error.msg);})
},
praiseEv(e){ //
if(this.allList[e].is_liked==0){
// if(this.allList[e].is_liked==0){
this.allList[e].is_liked = 1;
this.allList[e].likes++;
if(this.allList[e].likes>1000) this.allList[e].likes = '999+'
// if(this.allList[e].likes>1000) this.allList[e].likes = '999+'
//
collectionEV({action:'like',archive_id:this.allList[e].id})
}
// }
},
//
praisexgEv(e){
if(this.xgList[e].is_liked==0){
// if(this.xgList[e].is_liked==0){
this.xgList[e].is_liked = 1;
this.xgList[e].likes++;
if(this.xgList[e].likes>1000) this.xgList[e].likes = '999+'
// if(this.xgList[e].likes>1000) this.xgList[e].likes = '999+'
//
collectionEV({action:'like',archive_id:this.xgList[e].id})
}
// }
},
tapLike() { //
this.isDetailLike = !this.isDetailLike
// this.isDetailLike = !this.isDetailLike
this.isDetailLike = true;
if (this.isDetailLike) {
this.detailObj.likes++
this.likeCon = this.detailObj.likes
@ -557,15 +574,16 @@
}
let isLikeCon = 'like'
//
if (this.isDetailLike) collectionEV({
// if (this.isDetailLike)
collectionEV({
action: isLikeCon,
archive_id: this.detailObj.id
})
//
else cancleCollectionEV({
action: isLikeCon,
archive_id: this.detailObj.id
})
// else cancleCollectionEV({
// action: isLikeCon,
// archive_id: this.detailObj.id
// })
},
tapConllection() { //
let isLikeCon = 'collect'

View File

@ -10,6 +10,7 @@
<!-- 搜索 -->
<view @tap="searchEv" class="flexs mar-z30 radius10 pad-zy40 fon34 colf" style="height: 80rpx;line-height: 80rpx;" :style="{background:publicColor}">搜索</view>
</view>
<view class="pad-s20 pad-zy30 fon34" @click="clickEv">{{diseaseText}}</view>
</view>
<view class="pad-zy20 mar-s20">
<!-- 列表 -->
@ -57,6 +58,7 @@
total:'',//
isZanw:true,
category_id:'',//ID
diseaseText:'',//
}
},
computed: {
@ -99,6 +101,21 @@
}
},
methods: {
//
clickEv(){
this.$requst.get('archives/disease').then(res=>{
if(res.code==0){
}
})
uni.showActionSheet({
itemList:['病种','并在2'],
success: (res) => {
this.category_id = this.categoryIdList[res.tapIndex].id;
this.searchEv();
}
})
},
//
inputEv(e) {
this.page = 1;
@ -114,7 +131,7 @@
if(this.dataList[e].is_liked==0){
this.dataList[e].is_liked = 1;
this.dataList[e].likes++;
if(this.dataList[e].likes>1000) this.dataList[e].likes = '999+'
// if(this.dataList[e].likes>1000) this.dataList[e].likes = '999+'
//
collectionEV({action:'like',archive_id:this.dataList[e].id})
}

View File

@ -150,13 +150,13 @@
},
praiseEv(e){ //
// console.log(this.dataList[e].is_collected);
if(this.dataList[e].is_liked==0){
// if(this.dataList[e].is_liked==0){
this.dataList[e].is_liked = 1;
this.dataList[e].likes++;
if(this.dataList[e].likes>1000) this.dataList[e].likes = '999+'
// if(this.dataList[e].likes>1000) this.dataList[e].likes = '999+'
//
collectionEV({action:'like',archive_id:this.dataList[e].id})
}
// }
},
comfirmevl(e){//
this.dataList[e].is_collected = 0

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