Commit 511db54d authored by Mac's avatar Mac

1

parent 110ada4a
......@@ -774,7 +774,10 @@
storeId: res.data.storeInfo.storeId
});
if (res.data.storeInfo.storeId && res.data.storeInfo.storeId > 0) {
this.init()
setTimeout((x)=>{
this.init()
},1000)
}
}
}
......
......@@ -650,7 +650,7 @@
this.u = uni.getStorageSync("mall_UserInfo");
if (this.u) {
uni.navigateTo({
url: "/pages/reserve/subscribe?id=" + this.storeId+'&servicePersionId='+x.ID,
url: "/pages/reserve/subscribe?id=" + this.storeId+'&servicePersionId='+this.ID,
})
} else {
this.showAuth = true;
......
......@@ -470,7 +470,7 @@
暂无设计师数据~
</view>
</view>
<view class="title-c" @click="gocomment()">
<view class="title-c classcomment" @click="gocomment()" >
<text>
评价{{count>0?'('+count+')':''}}
......@@ -722,7 +722,7 @@
this.designerH = res.top
}
})
this.$utils.getRect('.comment').then(res => {
this.$utils.getRect('.classcomment').then(res => {
if(res && res.top){
this.commentH = res.top
}
......@@ -848,7 +848,7 @@
})
}else if(e==2){
uni.pageScrollTo({
scrollTop: that.commentH - that.headH -40-30
scrollTop: that.commentH - that.headH -40
})
}else if(e==3){
uni.pageScrollTo({
......
......@@ -224,6 +224,31 @@
display: flex;
justify-content: flex-end;
}
.subscribe .popupBox {
width: 100%;
padding-bottom: 15px;
}
.subscribe .popupBox .popup_top {
width: 100%;
height: 45px;
display: flex;
flex-direction: row;
align-items: center;
justify-content: space-between;
padding: 0 15px;
}
.subscribe .popupBox .txtype {}
.subscribe .typeitem {
padding: 15px;
display: flex;
flex-direction: row;
align-items: center;
justify-content: space-between;
border-top: 1px solid #f5f5f5
}
</style>
<template>
<view class="subscribe">
......@@ -328,6 +353,13 @@
<u-number-box v-model="value" :min="1" @change="valChange"></u-number-box>
</view>
<view class="info-item">
<text class="info-i-l">付款方式</text>
<view @click="show=true" style="width: 200px;display: flex;flex-direction: row;align-items: center;justify-content: flex-end;">
<Text>{{payname}}</Text>
<u-icon name="arrow" color='#9F9F9F'></u-icon>
</view>
</view>
<view class="info-item" v-if="payId==2">
<text class="info-i-l">套餐卡</text>
<view class="right" >
<text class="content" v-if="courseList.length>0 && Use_Education_Id==0" @click="showCourseHandler">选择套餐卡
......@@ -350,7 +382,9 @@
</view>
<view class="submit">
<view class="submit-l">
<text>定金:</text>
<text v-if="payId==0">线下付款金额:</text>
<text v-if="payId==1">预付定金:</text>
<text v-if="payId==2">线上付款金额:</text>
<text :style="{'color':mainColor}">¥<text style='font-size: 20px;'>{{Income*value}}</text></text>
</view>
<u-button
......@@ -405,6 +439,24 @@
</view>
</u-popup>
<u-popup v-model="show" mode="bottom" border-radius="16">
<view class="popupBox">
<view class="popup_top">
<view></view>
<Text>付款方式</Text>
<u-icon name="cross" color='#9F9F9F' @click='show=false' size="40"></u-icon>
</view>
<view class="txtype">
<view class="typeitem" v-for="(item, index) in paymentList" :key="index">
<Text>{{item.name}}</Text>
<u-radio-group v-model="payId">
<u-radio :active-color="mainColor" shape="circle" :name="item.Id" @change="radioChange(item)">
</u-radio>
</u-radio-group>
</view>
</view>
</view>
</u-popup>
<packagecart v-if="courseList.length > 0 && showCourse" :list="courseList" :current="Use_Education_Id" @close="closeCourseHandler"></packagecart>
</view>
</template>
......@@ -423,6 +475,7 @@
return {
pageTitle: "预约",
mainColor: "",
show: false,
loading: true,
submitOrder:false,
payExit: false,
......@@ -458,6 +511,10 @@
Income:0,
EduCationMoney:0,
servicePersionId:0,
paymentList:[],//付款方式的选择
payname:'线下付款',
payId:0,
};
},
......@@ -475,9 +532,7 @@
}
if(option && option.servicePersionId){
this.servicePersionId = option.servicePersionId
}
this.payInfo.OpenId=uni.getStorageSync('mall_UserInfo').OpenId;
},
......@@ -561,7 +616,7 @@
ProductList.push(obj);
//获取套餐卡的处理
this.Use_Education_Id=0,
this.Income = this.goods.price;
this.Income =this.payId==1?this.goods.depositMoney: this.goods.price;
this.EduCationMoney= 0;
this.request2({
......@@ -607,6 +662,30 @@
this.designerList.unshift(obj)
this.selectdesigner= this.designerList[0].Gender;
let set = uni.getStorageSync("basedata") ? uni.getStorageSync("basedata").mall.offlineServiceSetting.offlineServicePayType : [];
if(set.length>0){
this.paymentList=[]
set.forEach(x=>{
if(x==1){
//data有默认值 这里不做处理
let obj = {name:'线下付款',Id:0};
this.paymentList.push(obj)
}else if(x==2){
let obj
if(this.goods.depositMoney>0){//预定金额大于0
obj =[{name:'预付定金',Id:1},{name:'线上付款',Id:2}]
}else{
obj =[{name:'线上付款',Id:2}]
}
this.paymentList= this.paymentList.concat(obj)
}
})
}
this.payname = this.paymentList[0].name;
this.payId = this.paymentList[0].Id;
this.schoolCoupon();//获取套餐卡
this.Nosubmit = false;
}
......@@ -654,8 +733,8 @@
data: form
},
res => {
if (res.resultCode == 1) {
if(form.Income>0){
if (res.resultCode == 1 ) {
if(form.Income>0 || this.payId!=0){
that.submitOrder = false;
that.payBtn = true;
that.payInfo.OrderId = res.data.OrderId;
......@@ -731,7 +810,13 @@
goodsdetails(){//商品详情
uni.navigateTo({ url: "/pages/reserve/goodsDetails?GoodsId=" + this.goods.id });
}
},
radioChange(item) {
this.payname=item.name;
this.payId=item.Id;
this.Income =this.payId==1?this.goods.depositMoney: this.goods.price;
this.show = false;
},
},
};
</script>
......
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