Commit 0e73da29 authored by youjie's avatar youjie

no message

parents f4eb07b8 ecb92346
...@@ -46,6 +46,9 @@ ...@@ -46,6 +46,9 @@
<div v-if="u.TenantId!=27" class="price" :style="{ color: mainColor }"> <div v-if="u.TenantId!=27" class="price" :style="{ color: mainColor }">
{{ cx.price_content }} {{ cx.price_content }}
</div> </div>
<view v-if="u.TenantId!=27" class="origin">
{{ cx.original_price_content }}
</view>
<div v-if="u.TenantId!=27" class="sell">{{ cx.sales }}</div> <div v-if="u.TenantId!=27" class="sell">{{ cx.sales }}</div>
</div> </div>
...@@ -69,6 +72,9 @@ ...@@ -69,6 +72,9 @@
<view class="vip2" :style="{ color: mainColor }"> <view class="vip2" :style="{ color: mainColor }">
{{ cx.price_content }} {{ cx.price_content }}
</view> </view>
<view v-if="cx.original_price_content && cx.original_price > 0" class="origin" :style="{ color: mainColor }">
{{ cx.original_price_content }}
</view>
<div @click.stop="showSkuHandler(cx)" class="right"> <div @click.stop="showSkuHandler(cx)" class="right">
<!-- todo 点击加入购物车--> <!-- todo 点击加入购物车-->
...@@ -248,6 +254,13 @@ ...@@ -248,6 +254,13 @@
</script> </script>
<style> <style>
.origin {
font-family: "oswald";
font-size: 28rpx;
color: #999;
text-decoration: line-through;
margin-left: 10rpx;
}
.vip2{ .vip2{
font-size: 16px; font-size: 16px;
margin-right: 10rpx; margin-right: 10rpx;
......
...@@ -52,14 +52,14 @@ ...@@ -52,14 +52,14 @@
<!-- 内容 --> <!-- 内容 -->
</view> </view>
<!-- 新增分类科目结束 --> <!-- 新增分类科目结束 -->
<view class="catstyle4" style="height: 100%;"> <view class="catstyle4" style="height: 100%;margin-bottom: 20rpx;">
<!-- <div class="left-slider"> <!-- <div class="left-slider">
<sidebar :active="tid" name="Name" :active-color="mainColor" :border="false" :list="d" <sidebar :active="tid" name="Name" :active-color="mainColor" :border="false" :list="d"
@change="changeHandler" @change2="changeHandler2"></sidebar> @change="changeHandler" @change2="changeHandler2"></sidebar>
</div> --> </div> -->
<div class="right-slider"> <div class="right-slider">
<scroll-view :scroll-y="true" @scrolltolower="lower" :enable-back-to-top="true" :enable-flex="true" <scroll-view :scroll-y="true" @scrolltolower="lower" :enable-back-to-top="true" :enable-flex="true"
:style="{ height: '100%' }"> style="height:calc(100vh - 35rpx);">
<div class="adbox" v-if="d[tid].advert_pic" @click="clickHandler(d[tid].advert_url)"> <div class="adbox" v-if="d[tid].advert_pic" @click="clickHandler(d[tid].advert_url)">
<image mode="aspectFit" :src="d[tid].advert_url" style="width: 100%; height: 100%;" /> <image mode="aspectFit" :src="d[tid].advert_url" style="width: 100%; height: 100%;" />
</div> </div>
...@@ -75,7 +75,7 @@ ...@@ -75,7 +75,7 @@
</image> </image>
</div> </div>
<div class="good-info"> <div class="good-info">
<div class="good-name"> <div class="good-name" :class="[cx.edudata.ClassCondition.length>0?'good-namee2':'']">
<view <view
v-if="cx.marketingLogo.iswords && cx.marketingLogo.iswords==1&& cx.marketingLogo.words!=''" v-if="cx.marketingLogo.iswords && cx.marketingLogo.iswords==1&& cx.marketingLogo.words!=''"
class="Logo" :style="{color: cx.marketingLogo.wordsColor, class="Logo" :style="{color: cx.marketingLogo.wordsColor,
...@@ -90,7 +90,16 @@ ...@@ -90,7 +90,16 @@
{{cx.freeShippingFullMoneyPinkage>0 && cx.freeShippingFullNumPinkage==0?cx.freeShippingFullMoneyPinkage+'元包邮':''}} {{cx.freeShippingFullMoneyPinkage>0 && cx.freeShippingFullNumPinkage==0?cx.freeShippingFullMoneyPinkage+'元包邮':''}}
{{cx.freeShippingFullMoneyPinkage==0 && cx.freeShippingFullNumPinkage>0?cx.freeShippingFullNumPinkage+'件包邮':''}} {{cx.freeShippingFullMoneyPinkage==0 && cx.freeShippingFullNumPinkage>0?cx.freeShippingFullNumPinkage+'件包邮':''}}
</view> </view>
<view class="The-title">
{{ cx.name }} {{ cx.name }}
</view>
<view v-if="cx.edudata.ClassCondition.length>0" class="limit" @touchstart="mouseover()" @touchend="mouseLeave()">
<u-icon name="lock" size="44" :color="mainColor" />
<view class="limit-box" v-show="limitShow">
此课程有报名限制,请点击详情查看
</view>
</view>
</div> </div>
<div class="goodprice"> <div class="goodprice">
<div class="left"> <div class="left">
...@@ -164,6 +173,9 @@ ...@@ -164,6 +173,9 @@
<div v-if="u.TenantId!=27" class="price" :style="{ color: mainColor }"> <div v-if="u.TenantId!=27" class="price" :style="{ color: mainColor }">
{{ cx.price_content }} {{ cx.price_content }}
</div> </div>
<view v-if="u.TenantId!=27 && cx.price_content !== cx.original_price_content" class="origin">
{{ cx.original_price_content }}
</view>
<div v-if="u.TenantId!=27" class="sell">{{ cx.sales }}</div> <div v-if="u.TenantId!=27" class="sell">{{ cx.sales }}</div>
</div> </div>
<div v-if="u.TenantId!=27" @click.stop="showSkuHandler(cx)" class="right"> <div v-if="u.TenantId!=27" @click.stop="showSkuHandler(cx)" class="right">
...@@ -186,6 +198,9 @@ ...@@ -186,6 +198,9 @@
<view class="vip2" :style="{ color: mainColor }"> <view class="vip2" :style="{ color: mainColor }">
{{ cx.price_content }} {{ cx.price_content }}
</view> </view>
<view v-if="cx.original_price_content && cx.original_price > 0 &&cx.original_price>cx.level_price && cx.price_content !== cx.original_price_content" class="origin">
{{ cx.original_price_content }}
</view>
<div @click.stop="showSkuHandler(cx)" class="right"> <div @click.stop="showSkuHandler(cx)" class="right">
<!-- todo 点击加入购物车--> <!-- todo 点击加入购物车-->
...@@ -195,7 +210,7 @@ ...@@ -195,7 +210,7 @@
</view> </view>
</template> </template>
</div> </div>
<u-divider v-if="isover" :margin-top="20" :margin-bottom="20">没有更多商品了</u-divider> <u-divider class="The-tail" v-if="isover" :margin-top="20" :margin-bottom="20" bg-color="transparent" >没有更多商品了</u-divider>
</scroll-view> </scroll-view>
</div> </div>
<template v-if="u&&u.TenantId==27"> <template v-if="u&&u.TenantId==27">
...@@ -222,6 +237,7 @@ ...@@ -222,6 +237,7 @@
props: ["d", "h"], props: ["d", "h"],
data() { data() {
return { return {
limitShow:false,
ind: 1, ind: 1,
show: false, show: false,
Theclass: [{ Theclass: [{
...@@ -294,6 +310,14 @@ ...@@ -294,6 +310,14 @@
// this.u = uni.getStorageSync('mall_UserInfo5') // this.u = uni.getStorageSync('mall_UserInfo5')
}, },
methods: { methods: {
// 鼠标移进时间
mouseover(){
// console.log('44444')
this.limitShow = true
},
mouseLeave() {
this.limitShow = false
},
remaining(i) { remaining(i) {
this.$nextTick(function() { this.$nextTick(function() {
i.show = !i.show i.show = !i.show
...@@ -513,6 +537,7 @@ ...@@ -513,6 +537,7 @@
); );
}, },
lower(e) { lower(e) {
// console.log('4444')
if (this.msg.pageIndex < this.page_count) { if (this.msg.pageIndex < this.page_count) {
if (!this.loading) { if (!this.loading) {
this.msg.pageIndex++; this.msg.pageIndex++;
...@@ -533,7 +558,38 @@ ...@@ -533,7 +558,38 @@
}; };
</script> </script>
<style> <style >
.origin {
font-family: "oswald";
font-size: 24rpx;
color: #999;
text-decoration: line-through;
margin: 0 10rpx;
}
/* .The-tail >>> .u-divider{
background-color: transparent !important;
} */
.The-title{
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.limit{
/* position: relative; */
}
.limit-box{
position: absolute;
right: 0px;
font-size: 12px;
color: #fff;
background-color: rgba(0, 0, 0, 0.6);
padding: 10px;
border-radius: 10rpx;
}
.good-namee2{
display: flex !important;
position: relative;
}
.rema3{ .rema3{
margin-bottom: 8rpx; margin-bottom: 8rpx;
} }
......
...@@ -16,6 +16,7 @@ ...@@ -16,6 +16,7 @@
</view> </view>
</view> </view>
</view> </view>
<scroll-view scroll-y class="sku-box"> <scroll-view scroll-y class="sku-box">
<view class="sku-item" v-for="(x, i) in g.attr_groups" :key="i"> <view class="sku-item" v-for="(x, i) in g.attr_groups" :key="i">
<view class="sku-title">{{ x.attr_group_name }}</view> <view class="sku-title">{{ x.attr_group_name }}</view>
...@@ -491,6 +492,13 @@ ...@@ -491,6 +492,13 @@
</script> </script>
<style> <style>
.origin {
font-family: "oswald";
font-size: 14px;
color: #999;
text-decoration: line-through;
margin-left: 10rpx;
}
.goodsku { .goodsku {
position: relative; position: relative;
padding: 10px; padding: 10px;
......
...@@ -9,6 +9,10 @@ ...@@ -9,6 +9,10 @@
<text class="small"></text> <text class="small"></text>
<text>{{ goodprice }}</text> <text>{{ goodprice }}</text>
</view> </view>
<view class="origin" v-if="good_original_price && good_original_price >0 && good_original_price > goodprice">
<text class="small"></text>
<text>{{ good_original_price }}</text>
</view>
<view class="amount amount2">可报名额 {{ goodamount }}</view> <view class="amount amount2">可报名额 {{ goodamount }}</view>
<view class="sku_close"> <view class="sku_close">
<u-icon name="cross" color="#9F9F9F" @click="cloGood()" size="40" /> <u-icon name="cross" color="#9F9F9F" @click="cloGood()" size="40" />
...@@ -31,17 +35,15 @@ ...@@ -31,17 +35,15 @@
说明:以下物品需与当前课程绑定购买 说明:以下物品需与当前课程绑定购买
</text> </text>
</text> </text>
</view> </view>
<view class="val3 sku-chi2" :style="{ <view class="val3 sku-chi2" :style="{
background: y.attr_id == x.checkId ? mc : '#eee', background: y.attr_id == x.checkId ? mc : '#eee',
color: y.attr_id == x.checkId ? '#FFF' : '#333' color: y.attr_id == x.checkId ? '#FFF' : '#333'
}" v-if="notes" v-for="(item, index) in g.goodsRelevanceList" :key="index"> }"
v-if="notes" v-for="(item, index) in g.goodsRelevanceList" :key="index">
<text>{{item.RelevanceName}}</text> <text>{{item.RelevanceName}}</text>
<text></text> <text></text>
<text>{{item.RelevancePrice}}</text> <text>{{item.RelevancePrice}}</text>
</view> </view>
<view class="btn-box" v-if="g.totalStock>0&& g.status==1 && (g.form_id == -1 || g.form_id ==0)"> <view class="btn-box" v-if="g.totalStock>0&& g.status==1 && (g.form_id == -1 || g.form_id ==0)">
<view style="flex: 1;" v-if="optionType != 1"> <view style="flex: 1;" v-if="optionType != 1">
...@@ -114,6 +116,7 @@ ...@@ -114,6 +116,7 @@
notes: true, notes: true,
goodimage: '', goodimage: '',
goodprice: '', goodprice: '',
good_original_price: 0.00,
goodamount: '', goodamount: '',
mc: '', mc: '',
fu: '', fu: '',
...@@ -182,7 +185,6 @@ ...@@ -182,7 +185,6 @@
GoodsId: this.good.id GoodsId: this.good.id
} }
}, },
res => { res => {
this.g = res.data.goods; this.g = res.data.goods;
this.g.totalStock = 0; this.g.totalStock = 0;
...@@ -193,43 +195,52 @@ ...@@ -193,43 +195,52 @@
this.mc = this.$uiConfig.mainColor; this.mc = this.$uiConfig.mainColor;
this.fu = this.$uiConfig.secondary; this.fu = this.$uiConfig.secondary;
this.secondary = this.$uiConfig.secondary; this.secondary = this.$uiConfig.secondary;
var jjxkt_original_price = 0; //原价
if (this.g.jjxkt_original_price && this.g.jjxkt_original_price > 0) {
jjxkt_original_price = this.g.jjxkt_original_price;
}
this.skuObj = this.skued.id ? this.skued : null; this.skuObj = this.skued.id ? this.skued : null;
if (this.skuObj) { if (this.skuObj) {
this.goodimage = this.skuObj.pic_url || this.g.cover_pic; this.goodimage = this.skuObj.pic_url || this.g.cover_pic;
this.goodamount = this.skuObj.stock; this.goodamount = this.skuObj.stock;
// var tempGoodprice = (parseFloat(this.skuObj.price) * parseFloat(this.g.attr_groups[0].service_time)).toFixed(2);
// var tempGoodprice = (this.skuObj.price).toFixed(2);
if (this.g.goodsRelevanceList && this.g.goodsRelevanceList.length > 0) { if (this.g.goodsRelevanceList && this.g.goodsRelevanceList.length > 0) {
this.$nextTick(() => { this.$nextTick(() => {
this.g.goodsRelevanceList.forEach(item => { this.g.goodsRelevanceList.forEach(item => {
// tempGoodprice += parseFloat(item.RelevancePrice).toFixed(2)
this.goodprice = (parseFloat(this.skuObj.price) + parseFloat(item this.goodprice = (parseFloat(this.skuObj.price) + parseFloat(item
.RelevancePrice)).toFixed(2) .RelevancePrice)).toFixed(2);
//计算原价
if (jjxkt_original_price > 0) {
this.good_original_price = (parseFloat(jjxkt_original_price) + parseFloat(item
.RelevancePrice)).toFixed(2);
}
}); });
}) })
} else { } else {
this.$nextTick(() => { this.$nextTick(() => {
this.goodprice = (parseFloat(this.g.price)).toFixed(2); this.goodprice = (parseFloat(this.g.price)).toFixed(2);
this.good_original_price = (parseFloat(jjxkt_original_price)).toFixed(2);
}) })
} }
// this.goodprice = tempGoodprice
} else { } else {
this.goodimage = this.g.cover_pic; this.goodimage = this.g.cover_pic;
// var tempGoodprice = (this.g.price).toFixed(2);
this.goodamount = this.g.goods_stock; this.goodamount = this.g.goods_stock;
if (this.g.goodsRelevanceList && this.g.goodsRelevanceList.length > 0) { if (this.g.goodsRelevanceList && this.g.goodsRelevanceList.length > 0) {
this.$nextTick(() => { this.$nextTick(() => {
this.g.goodsRelevanceList.forEach(item => { this.g.goodsRelevanceList.forEach(item => {
// tempGoodprice += parseFloat(item.RelevancePrice).toFixed(2)
this.goodprice = (parseFloat(this.g.price) + parseFloat(item this.goodprice = (parseFloat(this.g.price) + parseFloat(item
.RelevancePrice)).toFixed(2) .RelevancePrice)).toFixed(2);
//计算原价
if (jjxkt_original_price > 0) {
this.good_original_price = (parseFloat(jjxkt_original_price) + parseFloat(item
.RelevancePrice)).toFixed(2);
}
}); });
}) })
} else { } else {
this.$nextTick(() => { this.$nextTick(() => {
this.goodprice = (parseFloat(this.g.price)).toFixed(2); this.goodprice = (parseFloat(this.g.price)).toFixed(2);
this.good_original_price = (parseFloat(jjxkt_original_price)).toFixed(2);
}) })
} }
} }
...@@ -554,6 +565,14 @@ ...@@ -554,6 +565,14 @@
</script> </script>
<style> <style>
.origin {
font-family: "oswald";
font-size: 14px;
color: #999;
text-decoration: line-through;
margin-left: 10rpx;
}
.amount2 { .amount2 {
margin-top: 40rpx; margin-top: 40rpx;
} }
......
...@@ -32,8 +32,6 @@ export default { ...@@ -32,8 +32,6 @@ export default {
return { return {
show: true, show: true,
orderInfo: {}, orderInfo: {},
}; };
}, },
created() { created() {
......
...@@ -14,7 +14,8 @@ ...@@ -14,7 +14,8 @@
<img style="width:50rpx;height:50rpx;margin-right:10px" :src="item.src" alt="" /> <img style="width:50rpx;height:50rpx;margin-right:10px" :src="item.src" alt="" />
<span style="position:relative;top:-7px">{{item.Name}}</span> <span style="position:relative;top:-7px">{{item.Name}}</span>
</p> --> </p> -->
<u-radio-group v-model="payment" :size="36" :active-color='mc' @change="radioChange" :wrap="true"> <u-radio-group v-model="payment" :size="36" :active-color='mc' @change="radioChange"
:wrap="true">
<u-radio shape="circle" :name="0" :wrap="true"> <u-radio shape="circle" :name="0" :wrap="true">
<img style="width:50rpx;height:50rpx;margin-right:10px" <img style="width:50rpx;height:50rpx;margin-right:10px"
src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Static/wx.png" alt="" /> src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Static/wx.png" alt="" />
...@@ -55,7 +56,9 @@ ...@@ -55,7 +56,9 @@
</view> </view>
<view class="Alipay-text4" @click="send()" style="margin-bottom: 86rpx;"> <view class="Alipay-text4" @click="send()" style="margin-bottom: 86rpx;">
去发送 去发送
<button open-type="contact" send-message-title="支付" style="position: absolute;left: 0;top: 0;width: 100%;height: 100%;opacity: 0;" :show-message-card="true">0</button> <button open-type="contact" send-message-title="支付"
style="position: absolute;left: 0;top: 0;width: 100%;height: 100%;opacity: 0;"
:show-message-card="true">0</button>
</view> </view>
...@@ -84,7 +87,8 @@ ...@@ -84,7 +87,8 @@
props: ['payInfo', 'isAlipay', 'StuId', 'TeacherIds'], props: ['payInfo', 'isAlipay', 'StuId', 'TeacherIds'],
data() { data() {
return { return {
url:'', times: null,
url: '',
AlipayMask: false, AlipayMask: false,
mc: {}, mc: {},
payment: 0, payment: 0,
...@@ -109,9 +113,21 @@ ...@@ -109,9 +113,21 @@
}; };
}, },
created() { created() {
console.log(wx) // console.log(wx)
this.getDataInfo();
this.u = uni.getStorageSync('mall_UserInfo') this.u = uni.getStorageSync('mall_UserInfo')
this.mc = this.$uiConfig.mainColor; this.mc = this.$uiConfig.mainColor;
this.TimingState();
this.times = setInterval(() => {
this.TimingState();
}, 30000);
},
onShow() {
this.TimingState();
this.times = setInterval(() => {
this.TimingState();
}, 30000);
}, },
wacth: { wacth: {
payInfo: { payInfo: {
...@@ -122,6 +138,52 @@ ...@@ -122,6 +138,52 @@
} }
}, },
methods: { methods: {
// 定时查询状态
TimingState() {
let that = this
this.request2({
url: '/api/AppletOrder/GetAppletMyOrderInfo',
data: {
OrderId: this.payInfo.OrderId,
NewUserId: 0
}
},
(res) => {
if (res.data.OrderStatus == 5) {
clearInterval(this.times);
uni.navigateTo({
url: `/pages/order-submit/pay-success2?payInfo=${JSON.stringify(that.payInfo)}&StuId=${that.StuId}&TeacherIds=${that.TeacherIds}`
// url: '/pages/order-submit/pay-success2?payInfo='+JSON.stringify(that.payInfo)
});
that.pay = false
}
// console.log('状态',res.data.OrderStatus)
}
);
},
// 微信支付一开始的请求
getDataInfo() {
let that=this;
// console.log("要发送的参数",that.payInfo)
let msg = {
OpenId: that.payInfo.OpenId,
OrderId: that.payInfo.OrderId,
OrderPayType:that.payInfo.OrderPayType,
GoodsName: that.payInfo.GoodsName
};
this.request2(
{
url: '/api/WeChatPay/GetPayInfo',
data: msg
},
res => {
if (res.resultCode == 1) {
this.orderInfo = JSON.parse(res.data);
}
uni.hideNavigationBarLoading();
}
);
},
radioChange(e) { radioChange(e) {
if (e == 0) { if (e == 0) {
this.payType = 'wx_lite' this.payType = 'wx_lite'
...@@ -135,7 +197,6 @@ ...@@ -135,7 +197,6 @@
}, },
// 支付宝发送发送 // 支付宝发送发送
send() { send() {
}, },
copy() { copy() {
uniCopy({ uniCopy({
...@@ -159,8 +220,11 @@ ...@@ -159,8 +220,11 @@
closePay() { closePay() {
this.$emit('closePay'); this.$emit('closePay');
}, },
// 支付宝支付
Pay() { Pay() {
// if (this.payment == 0) { if(this.payType == 'wx_lite') {
this.wxPay()
} else {
let msg = { let msg = {
'pay_channel': this 'pay_channel': this
.payType, //网页打开支付宝支付:alipay_wap 支付宝正扫:alipay_qr 支付宝app:alipay 微信小程序:wx_lite 微信公众号:wx_pub .payType, //网页打开支付宝支付:alipay_wap 支付宝正扫:alipay_qr 支付宝app:alipay 微信小程序:wx_lite 微信公众号:wx_pub
...@@ -182,7 +246,7 @@ ...@@ -182,7 +246,7 @@
if (res.data != '') { if (res.data != '') {
if (this.payType != 'wx_lite') { if (this.payType != 'wx_lite') {
this.aliPay(res.data) this.aliPay(res.data)
this.AlipayMask =true this.AlipayMask = true
this.pay = false this.pay = false
} else { } else {
this.wxPay(JSON.parse(res.data)) this.wxPay(JSON.parse(res.data))
...@@ -193,14 +257,9 @@ ...@@ -193,14 +257,9 @@
icon: 'error' icon: 'error'
}) })
} }
// uni.hideNavigationBarLoading();
} }
); );
// } }
// else {
// this.AlipayMask = true
// this.pay = false
// }
}, },
// 支付宝支付 // 支付宝支付
...@@ -212,21 +271,22 @@ ...@@ -212,21 +271,22 @@
// 微信支付 // 微信支付
wxPay(payData) { wxPay(payData) {
let that = this let that = this
let orderInfo = this.orderInfo;
uni.showLoading({ uni.showLoading({
title: '支付中...' title: '支付中...'
}) })
wx.requestPayment({ uni.requestPayment({
"timeStamp": payData.timeStamp, //时间戳,自1970年以来的秒数 provider: 'wxpay',
"nonceStr": payData.nonceStr, //随机串 timeStamp: that.orderInfo.timeStamp,
"package": payData.package, nonceStr: that.orderInfo.nonceStr,
"signType": payData.signType, //微信签名方式: package: that.orderInfo.package,
"paySign": payData.paySign, //微信签名 signType: that.orderInfo.signType,
'success': function(res) { paySign: that.orderInfo.sign,
success: function(res) {
uni.hideLoading() uni.hideLoading()
if (that.u && that.u.TenantId == 27) { if (that.u && that.u.TenantId == 27) {
uni.navigateTo({ uni.navigateTo({
url: `/pages/order-submit/pay-success2?payInfo=${JSON.stringify(that.payInfo)}&StuId=${that.StuId}&TeacherIds=${that.TeacherIds}` url: `/pages/order-submit/pay-success2?payInfo=${JSON.stringify(that.payInfo)}&StuId=${that.StuId}&TeacherIds=${that.TeacherIds}`
// url: '/pages/order-submit/pay-success2?payInfo='+JSON.stringify(that.payInfo)
}); });
that.pay = false that.pay = false
} else { } else {
...@@ -236,22 +296,15 @@ ...@@ -236,22 +296,15 @@
}); });
that.pay = false that.pay = false
} }
// uni.showToast({
// title:'支付成功'
// })
}, },
'fail': function(res) { fail: function(res) {
uni.hideLoading() uni.hideLoading()
uni.navigateTo({ uni.navigateTo({
// url: `/pages/order-submit/pay-success2?payInfo=${JSON.stringify(that.payInfo)}&StuId=${that.StuId}&TeacherIds=${that.TeacherIds}`
url: '/pages/order/index/index?status=1' url: '/pages/order/index/index?status=1'
}); });
that.pay = false that.pay = false
}, },
'complete': function(res) { complete: function(res) {
// uni.showToast({
// title:res.errMsg
// })
} }
}) })
}, },
...@@ -260,7 +313,7 @@ ...@@ -260,7 +313,7 @@
</script> </script>
<style> <style>
.fangs{ .fangs {
font-size: 26rpx; font-size: 26rpx;
font-family: PingFang SC; font-family: PingFang SC;
font-weight: bold; font-weight: bold;
...@@ -268,9 +321,11 @@ ...@@ -268,9 +321,11 @@
margin-right: 10rpx; margin-right: 10rpx;
width: 60rpx; width: 60rpx;
} }
.item-box{
.item-box {
position: relative; position: relative;
} }
.Alipay-box { .Alipay-box {
/* height: 930rpx; */ /* height: 930rpx; */
background: #FFFFFF; background: #FFFFFF;
......
...@@ -256,9 +256,6 @@ ...@@ -256,9 +256,6 @@
},{ },{
"path": "pay-success2" "path": "pay-success2"
}, },
{
"path": "pay-success2"
},
{ {
"path": "order-submit" "path": "order-submit"
}, { }, {
...@@ -897,6 +894,7 @@ ...@@ -897,6 +894,7 @@
// } // }
// ] // ]
// } // }
],
"globalStyle": { "globalStyle": {
"navigationBarTextStyle": "black", "navigationBarTextStyle": "black",
"navigationBarTitleText": "", "navigationBarTitleText": "",
......
...@@ -214,11 +214,6 @@ ...@@ -214,11 +214,6 @@
that.requestJJSWAdmin(testCmd, postMsg, that.requestJJSWAdmin(testCmd, postMsg,
(res) => { (res) => {
if (res.data.Code == 1) { if (res.data.Code == 1) {
// uni.showToast({
// title: '提交成功',
// icon: 'exception',
// duration: 2000
// });
uni.navigateBack({ uni.navigateBack({
delta: 1 delta: 1
}); });
......
...@@ -73,8 +73,19 @@ ...@@ -73,8 +73,19 @@
v-if="item.MarketingLogo.iswords&&item.MarketingLogo.iswords==2&& item.MarketingLogo.ico!=''" v-if="item.MarketingLogo.iswords&&item.MarketingLogo.iswords==2&& item.MarketingLogo.ico!=''"
mode="heightFix" :src="item.MarketingLogo.ico" mode="heightFix" :src="item.MarketingLogo.ico"
style=" height: 12px;margin-right: 5px" /> style=" height: 12px;margin-right: 5px" />
<view class="The-box">
<view class="The-title">
{{ item.GoodsName}} {{ item.GoodsName}}
</view> </view>
<view v-if="item.EduData.ClassCondition.length>0" class="limit" @touchstart="mouseover()" @touchend="mouseLeave()">
<u-icon name="lock" size="44" :color="mc" />
<view class="limit-box" v-show="limitShow">
此课程有报名限制,请点击详情查看
</view>
</view>
</view>
</view>
<view <view
style="width: 440rpx;overflow: hidden;white-space: nowrap;text-overflow: ellipsis;" style="width: 440rpx;overflow: hidden;white-space: nowrap;text-overflow: ellipsis;"
v-if="IsEducation!=1"> v-if="IsEducation!=1">
...@@ -241,6 +252,7 @@ ...@@ -241,6 +252,7 @@
export default { export default {
data() { data() {
return { return {
limitShow:false,
isloading: false, isloading: false,
pageTitle: '购物车', pageTitle: '购物车',
navHeight: 0, navHeight: 0,
...@@ -321,6 +333,13 @@ ...@@ -321,6 +333,13 @@
}); });
}, },
methods: { methods: {
mouseover(){
// console.log('44444')
this.limitShow = true
},
mouseLeave() {
this.limitShow = false
},
remaining(i) { remaining(i) {
this.$nextTick(function() { this.$nextTick(function() {
i.show = !i.show i.show = !i.show
...@@ -723,6 +742,26 @@ ...@@ -723,6 +742,26 @@
</script> </script>
<style> <style>
.limit{
/* position: relative; */
}
.limit-box{
position: absolute;
right: 0px;
font-size: 12px;
color: #fff;
background-color: rgba(0, 0, 0, 0.6);
padding: 10px;
border-radius: 10rpx;
}
.The-box{
display: flex;
}
.The-title{
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.rema { .rema {
display: flex; display: flex;
flex-wrap: wrap; flex-wrap: wrap;
...@@ -899,6 +938,7 @@ ...@@ -899,6 +938,7 @@
width: 440rpx; width: 440rpx;
height: 150rpx; height: 150rpx;
margin-left: 20rpx; margin-left: 20rpx;
position: relative;
} }
.cartStyle .item-r-n2 { .cartStyle .item-r-n2 {
......
...@@ -14,20 +14,17 @@ ...@@ -14,20 +14,17 @@
<swiper indicator-dots :autoplay="false" :interval="1000" style="height:100vw;"> <swiper indicator-dots :autoplay="false" :interval="1000" style="height:100vw;">
<block v-for="(item, index) in g.pic_url" :key="index"> <block v-for="(item, index) in g.pic_url" :key="index">
<swiper-item> <swiper-item>
<video @click="startPlay(item)" style="width:100%;height:100%" id="myVideo" <video @click="startPlay(item)" style="width:100%;height:100%" id="myVideo" v-if="item.type==1" :src="item.pic_url"
v-if="item.type==1" :src="item.pic_url" :autoplay="false" loop muted show-play-btn :autoplay="false" loop muted show-play-btn :enable-progress-gesture="true" :controls="true" :show-progress="true"
:enable-progress-gesture="true" :controls="true" :show-progress="true"
:show-mute-btn="true" objectFit="cover"></video> :show-mute-btn="true" objectFit="cover"></video>
<image @click="previewImage(index)" style="width:100%;height:100%;" v-else <image @click="previewImage(index)" style="width:100%;height:100%;" v-else :src="item.pic_url" :mode="u.TenantId==27 ? 'scaleToFill' : 'aspectFill'"></image>
:src="item.pic_url" :mode="u.TenantId==27 ? 'scaleToFill' : 'aspectFill'"></image>
</swiper-item> </swiper-item>
</block> </block>
</swiper> </swiper>
<!-- TODO 分销价格未做 is_share_price --> <!-- TODO 分销价格未做 is_share_price -->
<view class="is_share" v-if="g.share > 0 && hideshare == false&&setting.is_show_korea==0" <view class="is_share" v-if="g.share > 0 && hideshare == false&&setting.is_show_korea==0" style="top:240px;">
style="top:240px;"> <image src="@/static/images/icon/WechatIMG424.png" style="width: 20px; margin-left: 12px; opacity: 1;height: auto;"
<image src="@/static/images/icon/WechatIMG424.png" mode="widthFix" />
style="width: 20px; margin-left: 12px; opacity: 1;height: auto;" mode="widthFix" />
<view style=" <view style="
display: flex; display: flex;
flex-direction: column; flex-direction: column;
...@@ -39,12 +36,11 @@ ...@@ -39,12 +36,11 @@
<Text>即刻分享赚</Text> <Text>即刻分享赚</Text>
<Text>{{ g.share }}</Text> <Text>{{ g.share }}</Text>
</view> </view>
<u-icon name="close" style='position: absolute;right: 4px;top: 12.5px;z-index: 999;' color="#fff" <u-icon name="close" style='position: absolute;right: 4px;top: 12.5px;z-index: 999;' color="#fff" size="40" @click='goclose'></u-icon>
size="40" @click='goclose'></u-icon>
</view> </view>
<view class="is_share" v-if="g.myBuyCommission > 0 && hideshare == false&&setting.is_show_korea==0"> <view class="is_share" v-if="g.myBuyCommission > 0 && hideshare == false&&setting.is_show_korea==0">
<image src="@/static/images/icon/WechatIMG424.png" <image src="@/static/images/icon/WechatIMG424.png" style="width: 20px; margin-left: 12px; opacity: 1;height: auto;"
style="width: 20px; margin-left: 12px; opacity: 1;height: auto;" mode="widthFix" /> mode="widthFix" />
<view style=" <view style="
display: flex; display: flex;
flex-direction: column; flex-direction: column;
...@@ -56,25 +52,23 @@ ...@@ -56,25 +52,23 @@
<Text>即刻购买省</Text> <Text>即刻购买省</Text>
<Text>{{ g.myBuyCommission }}</Text> <Text>{{ g.myBuyCommission }}</Text>
</view> </view>
<u-icon v-if='g.share ==0' name="close" style='position: absolute;right: 4px;top: 12.5px;' <u-icon v-if='g.share ==0' name="close" style='position: absolute;right: 4px;top: 12.5px;' color="#fff" size="40"
color="#fff" size="40" @click='hideshare=true'></u-icon> @click='hideshare=true'></u-icon>
</view> </view>
</view> </view>
<!-- 非id27开始 --> <!-- 非id27开始 -->
<view class="g-info" v-if="u.TenantId!=27"> <view class="g-info" v-if="u.TenantId!=27">
<view class="g-name u-skeleton-rect"> <view class="g-name u-skeleton-rect">
<view v-if="g.marketingLogo.iswords&&g.marketingLogo.iswords==1 && g.marketingLogo.words!=''" <view v-if="g.marketingLogo.iswords&&g.marketingLogo.iswords==1 && g.marketingLogo.words!=''" class="Logo" :style="{color: g.marketingLogo.wordsColor,
class="Logo" :style="{color: g.marketingLogo.wordsColor,
background:g.marketingLogo.wordsBack ,}">{{g.marketingLogo.words}}</view> background:g.marketingLogo.wordsBack ,}">{{g.marketingLogo.words}}</view>
<image v-if="g.marketingLogo.iswords&&g.marketingLogo.iswords==2&& g.marketingLogo.ico!=''" <image v-if="g.marketingLogo.iswords&&g.marketingLogo.iswords==2&& g.marketingLogo.ico!=''" mode="heightFix" :src="g.marketingLogo.ico"
mode="heightFix" :src="g.marketingLogo.ico" style=" height: 12px;margin-right: 5px" /> style=" height: 12px;margin-right: 5px" />
{{ g.name }} {{ g.name }}
</view> </view>
<view class="g-price-box" v-if="setting.is_show_korea==0"> <view class="g-price-box" v-if="setting.is_show_korea==0">
<view class="left"> <view class="left">
<view class="price u-skeleton-rect" :style="{ color: mc }"> <view class="price u-skeleton-rect" :style="{ color: mc }">
<u-tag v-if='g.price_min!=g.original_price' text="心动价" mode="light" size='mini' type="error" <u-tag v-if='g.price_min!=g.original_price' text="心动价" mode="light" size='mini' type="error" style='font-size: 12px;font-family: aa;margin-right: 10px;' />
style='font-size: 12px;font-family: aa;margin-right: 10px;' />
<text class="small"></text> <text class="small"></text>
<text class="numfont" v-if="g.form_id!=1"> <text class="numfont" v-if="g.form_id!=1">
{{ g.price_min == g.price_max ? g.price_min : g.price_min + '-' + g.price_max }} {{ g.price_min == g.price_max ? g.price_min : g.price_min + '-' + g.price_max }}
...@@ -99,8 +93,7 @@ ...@@ -99,8 +93,7 @@
<template v-if="setting.is_show_korea==1"> <template v-if="setting.is_show_korea==1">
<view style="height:50px;margin:10px 10px 0 0;display:none;"> <view style="height:50px;margin:10px 10px 0 0;display:none;">
<view style="float:right;" @click="openShare" v-if="isAllowShare == 1"> <view style="float:right;" @click="openShare" v-if="isAllowShare == 1">
<image src="@/static/images/icon/icon-share.png" style="width:20px;height:20px;" <image src="@/static/images/icon/icon-share.png" style="width:20px;height:20px;" class="share-icon" />
class="share-icon" />
</view> </view>
</view> </view>
<view class="koarea_Country" style="display:none;"> <view class="koarea_Country" style="display:none;">
...@@ -115,13 +108,11 @@ ...@@ -115,13 +108,11 @@
<view style="text-align: left;padding:15px 0;border-bottom:1px solid #F2F3F6;display:none;"> <view style="text-align: left;padding:15px 0;border-bottom:1px solid #F2F3F6;display:none;">
卖点:<text v-if="g.subname">{{g.subname}}</text> 卖点:<text v-if="g.subname">{{g.subname}}</text>
</view> </view>
<view <view style="text-align: left;border-bottom:1px solid #F2F3F6;padding:15px 0;display:flex;font-size:13px;color:#737373;">
style="text-align: left;border-bottom:1px solid #F2F3F6;padding:15px 0;display:flex;font-size:13px;color:#737373;">
<u-icon name="location" color="#D4D4D4" size="30"></u-icon> <u-icon name="location" color="#D4D4D4" size="30"></u-icon>
地址:<text v-if="g.fatcode">{{g.fatcode}}</text> 地址:<text v-if="g.fatcode">{{g.fatcode}}</text>
</view> </view>
<view <view style="display:flex;text-align: left;padding:10px;background-color: #F3F3F3;color:#404040;min-height:100px;line-height: 25px;font-size:13px;">
style="display:flex;text-align: left;padding:10px;background-color: #F3F3F3;color:#404040;min-height:100px;line-height: 25px;font-size:13px;">
<text style="flex-shrink: 0;width:45px;">简介:</text><text v-if="g.goodsurl">{{g.goodsurl}}</text> <text style="flex-shrink: 0;width:45px;">简介:</text><text v-if="g.goodsurl">{{g.goodsurl}}</text>
</view> </view>
</template> </template>
...@@ -130,9 +121,8 @@ ...@@ -130,9 +121,8 @@
<!-- id27开始 --> <!-- id27开始 -->
<view class="g-info" v-if="u.TenantId==27" style="position: relative;"> <view class="g-info" v-if="u.TenantId==27" style="position: relative;">
<!-- 标题 --> <!-- 标题 -->
<view class="g-name u-skeleton-rect" style="height: 60rpx;"> <view class="g-name u-skeleton-rect">
<view v-if="g.marketingLogo.iswords&&g.marketingLogo.iswords==1 && g.marketingLogo.words!=''" <view v-if="g.marketingLogo.iswords&&g.marketingLogo.iswords==1 && g.marketingLogo.words!=''" class="Logo" :style="{color: g.marketingLogo.wordsColor,
class="Logo" :style="{color: g.marketingLogo.wordsColor,
background:g.marketingLogo.wordsBack ,}">{{g.marketingLogo.words}}</view> background:g.marketingLogo.wordsBack ,}">{{g.marketingLogo.words}}</view>
{{ g.name }} {{ g.name }}
</view> </view>
...@@ -142,6 +132,41 @@ ...@@ -142,6 +132,41 @@
<text v-if="g.edu_data.EndOrderTime" class="sign-dian"></text> <text v-if="g.edu_data.EndOrderTime" class="sign-dian"></text>
<text v-if="g.edu_data.ClassNum">{{g.edu_data.ClassNum}}次</text> <text v-if="g.edu_data.ClassNum">{{g.edu_data.ClassNum}}次</text>
</view> </view>
<!-- 报名限制 -->
<view v-if='g.edu_data.ClassCondition.length>0'>
<view class="limit">
<view v-if="ItemType1 && ItemType1.length > 0" class="box-title">
只允许以下学员报名
</view>
<text v-for="(item, index) in ItemType1" class="box-name">
{{ index + 1 }}:{{ item.ItemName }}。
</text>
<view v-if="ItemType2 && ItemType2.length > 0" class="box-title">
只允许以下年级学员报名
</view>
<text v-for="(item, index) in ItemType2" class="box-name">
{{ index + 1 }}:{{ item.ItemName }}。
</text>
<view v-if="ItemType3 && ItemType3.length > 0" class="box-title">
只允许曾报以下课程学员报名
</view>
<text v-for="(item, index) in ItemType3" class="box-name">
{{ index + 1 }}:{{ item.ItemName }}。
</text>
<view v-if="ItemType4 && ItemType4.length > 0" class="box-title">
只允许曾报以下班级学员报名
</view>
<text v-for="(item, index) in ItemType4" class="box-name">
{{ index + 1 }}:{{ item.ItemName }}。
</text>
<view v-if="ItemType5 && ItemType5.length > 0" class="box-title">
只允许以下考试成绩报名:
</view>
<text v-for="(item, index) in ItemType5" class="box-name">
{{ index + 1 }}:{{ item.ItemName }}({{item.LowScore}}-{{item.HighScore}})。
</text>
</view>
</view>
<!-- 价格 --> <!-- 价格 -->
<view :style="{ color: mc }" class="the-price"> <view :style="{ color: mc }" class="the-price">
<text class="small22"></text> <text class="small22"></text>
...@@ -151,14 +176,19 @@ ...@@ -151,14 +176,19 @@
<text class="numfont22" v-if="g.form_id!=1&&g.edu_data.BookPrice"> <text class="numfont22" v-if="g.form_id!=1&&g.edu_data.BookPrice">
{{ g.price_min == g.price_max ? parseFloat(g.price_min)+parseFloat(g.edu_data.BookPrice) : g.price_min + '-' + g.price_max }} {{ g.price_min == g.price_max ? parseFloat(g.price_min)+parseFloat(g.edu_data.BookPrice) : g.price_min + '-' + g.price_max }}
</text> </text>
<text class="origin" v-if="g.form_id!=1&&!g.edu_data.BookPrice&& g.jjxkt_original_price && g.jjxkt_original_price > 0 && g.jjxkt_original_price>g.price">
¥{{ g.jjxkt_original_price.toFixed(2)}}
</text>
<text class="origin" v-if="g.form_id!=1&& g.edu_data.BookPrice&& g.jjxkt_original_price && g.jjxkt_original_price > 0 && g.jjxkt_original_price>g.price">
¥{{parseFloat(g.jjxkt_original_price)+parseFloat(g.edu_data.BookPrice)}}
</text>
<!-- <text class="numfont" v-if="g.form_id==1"> <!-- <text class="numfont" v-if="g.form_id==1">
{{ g.price_min }} {{ g.price_min }}
</text> --> </text> -->
</view> </view>
<!-- top切换 --> <!-- top切换 -->
<view class="top-switch" id="productId"> <view class="top-switch" id="productId">
<u-tabs :list="list" :is-scroll="false" :current="current" inactive-color='#999' :active-color='mc' <u-tabs :list="list" :is-scroll="false" :current="current" inactive-color='#999' :active-color='mc' @change="change"></u-tabs>
@change="change"></u-tabs>
</view> </view>
<!-- 内容1 --> <!-- 内容1 -->
<view v-if="current==0"> <view v-if="current==0">
...@@ -167,8 +197,7 @@ ...@@ -167,8 +197,7 @@
<text class="introduce2">老师介绍</text> <text class="introduce2">老师介绍</text>
</view> </view>
<view class="teacher"> <view class="teacher">
<image :src="g.edu_data.TeacherIcon" mode="aspectFill" style="width:30px;height:30px;" <image :src="g.edu_data.TeacherIcon" mode="aspectFill" style="width:30px;height:30px;" class="share-icon" />
class="share-icon" />
<view class="teacher2"> <view class="teacher2">
<view class="teacher3"> <view class="teacher3">
<view class="teacher4" v-if='g.edu_data.TeacherName'>{{g.edu_data.TeacherName}}</view> <view class="teacher4" v-if='g.edu_data.TeacherName'>{{g.edu_data.TeacherName}}</view>
...@@ -238,34 +267,26 @@ ...@@ -238,34 +267,26 @@
</view> --> </view> -->
</view> </view>
<!-- id27结束 --> <!-- id27结束 -->
<view class="sku-box u-skeleton-rect" style="margin: 0;padding: 10px;" <view class="sku-box u-skeleton-rect" style="margin: 0;padding: 10px;" v-if="g.friendUrl!=null && g.friendUrl!=''&&setting.is_show_korea==0 &&u.TenantId!=27"
v-if="g.friendUrl!=null && g.friendUrl!=''&&setting.is_show_korea==0 &&u.TenantId!=27"
@click="goCoiling(g.friendUrl)"> @click="goCoiling(g.friendUrl)">
<image src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Static/goodsCoiling.png" <image src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Static/goodsCoiling.png" style="width: 100%;height: 68px;" />
style="width: 100%;height: 68px;" />
</view> </view>
<view class="sku-box u-skeleton-rect" style="align-items: flex-start;" <view class="sku-box u-skeleton-rect" style="align-items: flex-start;" v-if="(g.goods_marketing_award.integral.title != '')|| (g.goods_marketing_award.PresentFXGradeMsg != '')|| g.freeShippingName != null && g.freeShippingName != '' && (g.fullMoneyPinkage > 0 || g.fullNumPinkage > 0)&&u.TenantId!=27">
v-if="(g.goods_marketing_award.integral.title != '')|| (g.goods_marketing_award.PresentFXGradeMsg != '')|| g.freeShippingName != null && g.freeShippingName != '' && (g.fullMoneyPinkage > 0 || g.fullNumPinkage > 0)&&u.TenantId!=27">
<view class="label" style="margin-top: 5px;">活动</view> <view class="label" style="margin-top: 5px;">活动</view>
<view class="content" style="display: flex;flex-direction: column"> <view class="content" style="display: flex;flex-direction: column">
<view style="display: flex;flex-direction: row;align-items: center;margin-bottom: 5px;" <view style="display: flex;flex-direction: row;align-items: center;margin-bottom: 5px;" v-if="g.goods_marketing_award.integral.title != ''">
v-if="g.goods_marketing_award.integral.title != ''">
<u-tag text="送积分" type="error" /> <u-tag text="送积分" type="error" />
<text <text style="margin-left: 5px; font-size: 12px;">{{ g.goods_marketing_award.integral.title }}</text>
style="margin-left: 5px; font-size: 12px;">{{ g.goods_marketing_award.integral.title }}</text>
</view> </view>
<view style="display: flex;flex-direction: row;align-items: center" <view style="display: flex;flex-direction: row;align-items: center" v-if="g.goods_marketing_award.PresentFXGradeMsg != ''"
v-if="g.goods_marketing_award.PresentFXGradeMsg != ''" @click="goVIP"> @click="goVIP">
<u-tag text="送会员" type="error" /> <u-tag text="送会员" type="error" />
<text <text style="margin-left: 5px; font-size: 12px;">{{ g.goods_marketing_award.PresentFXGradeMsg }}</text>
style="margin-left: 5px; font-size: 12px;">{{ g.goods_marketing_award.PresentFXGradeMsg }}</text>
</view> </view>
<view style="display: flex;flex-direction: row;align-items: center;margin-top: 5px;" <view style="display: flex;flex-direction: row;align-items: center;margin-top: 5px;" @click="goUrl(g.FreeShippingUrl)"
@click="goUrl(g.FreeShippingUrl)"
v-if="g.freeShippingName != null && g.freeShippingName != '' && (g.fullMoneyPinkage > 0 || g.fullNumPinkage > 0)"> v-if="g.freeShippingName != null && g.freeShippingName != '' && (g.fullMoneyPinkage > 0 || g.fullNumPinkage > 0)">
<view <view style="color: #fa3534;background: #fef0f0;padding: 12rpx 22rpx; font-size: 22rpx;margin-right: 5px;border: 1px solid #fde2e2;border-radius: 6rpx;">
style="color: #fa3534;background: #fef0f0;padding: 12rpx 22rpx; font-size: 22rpx;margin-right: 5px;border: 1px solid #fde2e2;border-radius: 6rpx;">
{{ g.freeShippingName != null ? g.freeShippingName : '' }} {{ g.freeShippingName != null ? g.freeShippingName : '' }}
</view> </view>
{{ g.fullMoneyPinkage > 0 && g.fullNumPinkage == 0 ? g.fullMoneyPinkage + '元包邮' : '' }} {{ g.fullMoneyPinkage > 0 && g.fullNumPinkage == 0 ? g.fullMoneyPinkage + '元包邮' : '' }}
...@@ -281,8 +302,7 @@ ...@@ -281,8 +302,7 @@
</view>--> </view>-->
</view> </view>
</view> </view>
<view class="sku-box u-skeleton-rect" style="align-items: flex-start;" <view class="sku-box u-skeleton-rect" style="align-items: flex-start;" v-if="sku.length > 0&&setting.is_show_korea==0&&u.TenantId!=27">
v-if="sku.length > 0&&setting.is_show_korea==0&&u.TenantId!=27">
<view class="label">选择</view> <view class="label">选择</view>
<view class="content"> <view class="content">
<view class="sku-chosen" @click="chosenSku"> <view class="sku-chosen" @click="chosenSku">
...@@ -315,19 +335,16 @@ ...@@ -315,19 +335,16 @@
<view class="label">发货地</view> <view class="label">发货地</view>
<view class="content">{{g.sendArea }}</view> <view class="content">{{g.sendArea }}</view>
</view> </view>
<view class="sku-box u-skeleton-rect" <view class="sku-box u-skeleton-rect" v-if="setting.is_express == '1'&&setting.is_show_korea==0&&u.TenantId!=27">
v-if="setting.is_express == '1'&&setting.is_show_korea==0&&u.TenantId!=27">
<view class="label">快递</view> <view class="label">快递</view>
<view class="content">{{ g.express == '' ? '免运费' : '¥' + g.express }}</view> <view class="content">{{ g.express == '' ? '免运费' : '¥' + g.express }}</view>
</view> </view>
<view class="sku-box u-skeleton-rect" style="margin-top: -10;" <view class="sku-box u-skeleton-rect" style="margin-top: -10;" v-if="g.goods_marketing.shipping != ''&&u.TenantId!=27">
v-if="g.goods_marketing.shipping != ''&&u.TenantId!=27">
<view class="label">包邮</view> <view class="label">包邮</view>
<view class="content">{{ g.goods_marketing.shipping }}</view> <view class="content">{{ g.goods_marketing.shipping }}</view>
</view> </view>
<view class="sku-box u-skeleton-rect" style="margin-top: -10;" <view class="sku-box u-skeleton-rect" style="margin-top: -10;" v-if="g.goods_marketing.limit != ''&&setting.is_show_korea==0&&u.TenantId!=27">
v-if="g.goods_marketing.limit != ''&&setting.is_show_korea==0&&u.TenantId!=27">
<view class="label">限购</view> <view class="label">限购</view>
<view class="content">{{ g.goods_marketing.limit }}</view> <view class="content">{{ g.goods_marketing.limit }}</view>
</view> </view>
...@@ -346,23 +363,21 @@ ...@@ -346,23 +363,21 @@
</view> </view>
</view> </view>
<view class="sku-box u-skeleton-rect" <view class="sku-box u-skeleton-rect" v-if="comments.length == 0 && setting.is_comment == 1&&setting.is_show_korea==0&&u.TenantId!=27">
v-if="comments.length == 0 && setting.is_comment == 1&&setting.is_show_korea==0&&u.TenantId!=27">
<view class="label">暂无评论信息</view> <view class="label">暂无评论信息</view>
</view> </view>
<view class="comment" v-if="comments.length > 0"> <view class="comment" v-if="comments.length > 0">
<view class="chead"> <view class="chead">
<u-section :bold="false" :sub-color="secondary" :show-split="false" <u-section :bold="false" :sub-color="secondary" :show-split="false" :title="`商品评价(${comments.length})`" sub-title="查看更多"
:title="`商品评价(${comments.length})`" sub-title="查看更多" @click="clickCommentHandler" @click="clickCommentHandler" font-size="24"></u-section>
font-size="24"></u-section>
</view> </view>
<view class="content"> <view class="content">
<view class="u-box"> <view class="u-box">
<view class="user"> <view class="user">
<u-avatar :src="comments[0].UserPhotoPath" :size="50"></u-avatar> <u-avatar :src="comments[0].UserPhotoPath" :size="50"></u-avatar>
<text style="margin-left: 10px;">{{ comments[0].UserName }}</text> <text style="margin-left: 10px;">{{ comments[0].UserName }}</text>
<u-rate :current="comments[0].CommentScore" active-color="#FA3534" inactive-color="#b2b2b2" <u-rate :current="comments[0].CommentScore" active-color="#FA3534" inactive-color="#b2b2b2" active-icon="star"
active-icon="star" inactive-icon="star-o" size="20" :disabled="true"></u-rate> inactive-icon="star-o" size="20" :disabled="true"></u-rate>
</view> </view>
<view class="timer">{{ comments[0].CreateDate }}</view> <view class="timer">{{ comments[0].CreateDate }}</view>
</view> </view>
...@@ -398,7 +413,8 @@ ...@@ -398,7 +413,8 @@
<view style="margin:10px 0;">留言(至少填写10个文字)</view> <view style="margin:10px 0;">留言(至少填写10个文字)</view>
<view> <view>
<textarea placeholder="请输入评论信息" style="width: 94.5%;height: 100px;border:1px solid #d1d1d1; <textarea placeholder="请输入评论信息" style="width: 94.5%;height: 100px;border:1px solid #d1d1d1;
padding:10px;background-color: #fff;" confirm-type='done' v-model="comentMsg.Content"> padding:10px;background-color: #fff;"
confirm-type='done' v-model="comentMsg.Content">
</textarea> </textarea>
</view> </view>
<view class="goodComentBtn" @click="submitCommit">提交留言</view> <view class="goodComentBtn" @click="submitCommit">提交留言</view>
...@@ -411,36 +427,31 @@ ...@@ -411,36 +427,31 @@
</view> </view>
<u-skeleton v-if="loading" :loading="true" :animation="true" bgcolor="#FFF"></u-skeleton> <u-skeleton v-if="loading" :loading="true" :animation="true" bgcolor="#FFF"></u-skeleton>
<template v-if="setting&&setting.is_show_korea==0"> <template v-if="setting&&setting.is_show_korea==0">
<goodsaction v-if="!loading" :good-name="g.name" :cover-pic="g.cover_pic" :favorite="g.favorite" <goodsaction v-if="!loading" :good-name="g.name" :cover-pic="g.cover_pic" :favorite="g.favorite" :good-id="id"
:good-id="id" :total-stock="g.totalStock" :status="g.status" :formid='g.form_id' @joincar="joinCar" :total-stock="g.totalStock" :status="g.status" :formid='g.form_id' @joincar="joinCar" @buy="buy"></goodsaction>
@buy="buy"></goodsaction>
</template> </template>
<template v-if="setting&&setting.is_show_korea==1"> <template v-if="setting&&setting.is_show_korea==1">
<kotragoodsaction v-if="!loading" :good-name="g.name" :cover-pic="g.pic_url" :favorite="g.favorite" <kotragoodsaction v-if="!loading" :good-name="g.name" :cover-pic="g.pic_url" :favorite="g.favorite" :good-id="id"
:good-id="id" :total-stock="g.totalStock" :status="g.status" @buy="buy"> :total-stock="g.totalStock" :status="g.status" @buy="buy">
</kotragoodsaction> </kotragoodsaction>
</template> </template>
<goodsku v-if="!loading && showSku&&u.TenantId!=27" border-radius="10" v-model="showSku" <goodsku v-if="!loading && showSku&&u.TenantId!=27" border-radius="10" v-model="showSku" :mask-close-able="true"
:mask-close-able="true" :safe-area-inset-bottom="true" :good="g" :option-type="ot" :skued="currentSku" :safe-area-inset-bottom="true" :good="g" :option-type="ot" :skued="currentSku" @close="closeSkuChosen">
@close="closeSkuChosen">
</goodsku> </goodsku>
<template v-if="u&&u.TenantId==27"> <template v-if="u&&u.TenantId==27">
<goodsku2 v-if="!loading && showSku" border-radius="10" v-model="showSku" :mask-close-able="true" <goodsku2 v-if="!loading && showSku" border-radius="10" v-model="showSku" :mask-close-able="true"
:safe-area-inset-bottom="true" :good="g" :option-type="ot" :skued="currentSku" :safe-area-inset-bottom="true" :good="g" :option-type="ot" :skued="currentSku" @close="closeSkuChosen">
@close="closeSkuChosen">
</goodsku2> </goodsku2>
</template> </template>
<template v-else> <template v-else>
<goodsku v-if="!loading && showSku" border-radius="10" v-model="showSku" :mask-close-able="true" <goodsku v-if="!loading && showSku" border-radius="10" v-model="showSku" :mask-close-able="true"
:safe-area-inset-bottom="true" :good="g" :option-type="ot" :skued="currentSku" :safe-area-inset-bottom="true" :good="g" :option-type="ot" :skued="currentSku" @close="closeSkuChosen">
@close="closeSkuChosen">
</goodsku> </goodsku>
</template> </template>
</view> </view>
<u-empty text="没有找到商品,或商品已下架" mode="favor" v-if="!isExsitGoods"></u-empty> <u-empty text="没有找到商品,或商品已下架" mode="favor" v-if="!isExsitGoods"></u-empty>
<share :good-id="id" v-if="showShare" :good-name="g.name" :images="g.pic_url" :advertising="g.advertising" <share :good-id="id" v-if="showShare" :good-name="g.name" :images="g.pic_url" :advertising="g.advertising" @close="closeShare"></share>
@close="closeShare"></share>
<auth v-if="showAuth" @changeuserinfo="reloadUserinfo" @gbAuth="gbAuth"></auth> <auth v-if="showAuth" @changeuserinfo="reloadUserinfo" @gbAuth="gbAuth"></auth>
<coupon v-if="showCoupons" :coupon-message="couponMessage" @goLook="goLook" @closeBtn="closeBtn"></coupon> <coupon v-if="showCoupons" :coupon-message="couponMessage" @goLook="goLook" @closeBtn="closeBtn"></coupon>
</view> </view>
...@@ -462,6 +473,11 @@ ...@@ -462,6 +473,11 @@
export default { export default {
data() { data() {
return { return {
ItemType1: [],
ItemType2: [],
ItemType3: [],
ItemType4: [],
ItemType5: [],
barStyle: { barStyle: {
height: 'mc ', height: 'mc ',
}, },
...@@ -541,12 +557,17 @@ ...@@ -541,12 +557,17 @@
this.scrollTop = e.scrollTop; this.scrollTop = e.scrollTop;
}, },
onLoad(option) { onLoad(option) {
this.ItemType1 = [],
this.ItemType2 = [],
this.ItemType3 = [],
this.ItemType4 = [],
this.ItemType5 = [],
this.opTionObj = option; this.opTionObj = option;
console.log(option, "option"); console.log(option, "option");
if (option && option.id) { if (option && option.id) {
this.id = option.id ? option.id : 29; //40887 59512 46942 this.id = option.id ? option.id : 29; //40887 59512 46942
} else { } else {
this.id = option.GoodsId ? option.GoodsId : 29; //40887 59512 46942 this.id = option.GoodsId ? option.GoodsId : 774192; //774192
} }
if (option && option.custom_params) { if (option && option.custom_params) {
let custom_params = JSON.parse(decodeURIComponent(option.custom_params)); let custom_params = JSON.parse(decodeURIComponent(option.custom_params));
...@@ -602,7 +623,7 @@ ...@@ -602,7 +623,7 @@
// this.init(); // this.init();
// this.initPage(); // this.initPage();
// } // }
this.init();
this.initPage(); this.initPage();
this.getVipId(); this.getVipId();
this.mc = this.$uiConfig.mainColor; this.mc = this.$uiConfig.mainColor;
...@@ -677,6 +698,7 @@ ...@@ -677,6 +698,7 @@
setTimeout(() => { setTimeout(() => {
this.initImages(); this.initImages();
}, 3000); }, 3000);
this.init();
}, },
methods: { methods: {
// counter() { // counter() {
...@@ -772,6 +794,21 @@ ...@@ -772,6 +794,21 @@
(res) => { (res) => {
if (res.resultCode == 1) { if (res.resultCode == 1) {
this.g = res.data.goods; this.g = res.data.goods;
// 报名限制数组
res.data.goods.edu_data.ClassCondition.forEach(item2 => {
if (item2.ItemType == 1) {
this.ItemType1.push(item2)
} else if (item2.ItemType == 2) {
this.ItemType2.push(item2)
} else if (item2.ItemType == 3) {
this.ItemType3.push(item2)
} else if (item2.ItemType == 4) {
this.ItemType4.push(item2)
} else if (item2.ItemType == 5) {
this.ItemType5.push(item2)
}
})
// 报名限制数组结束
this.g.totalStock = 0; this.g.totalStock = 0;
this.g.attr.forEach((x) => { this.g.attr.forEach((x) => {
this.g.totalStock += x.stock; this.g.totalStock += x.stock;
...@@ -1087,6 +1124,18 @@ ...@@ -1087,6 +1124,18 @@
</script> </script>
<style> <style>
.limit {
margin-top: 20rpx;
}
.box-title {
font-weight: bold;
}
.box-name {
font-size: 22rpx;
}
.the-top { .the-top {
position: absolute; position: absolute;
top: 82%; top: 82%;
...@@ -1177,6 +1226,14 @@ ...@@ -1177,6 +1226,14 @@
font-weight: bold; font-weight: bold;
} }
.origin {
font-family: "oswald";
font-size: 28rpx;
color: #999;
text-decoration: line-through;
margin-left: 10rpx;
}
.sign-up { .sign-up {
font-size: 20rpx; font-size: 20rpx;
color: #999; color: #999;
...@@ -1218,7 +1275,8 @@ ...@@ -1218,7 +1275,8 @@
-webkit-line-clamp: 2; -webkit-line-clamp: 2;
-webkit-box-orient: vertical; -webkit-box-orient: vertical;
font-size: 16px; font-size: 16px;
height: 45px; /* height: 45px; */
margin-bottom: 10rpx;
} }
.goods .g-info .g-price-box { .goods .g-info .g-price-box {
......
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
<view class="address"> <view class="address">
</view> </view>
</view> </view>
<view v-if="namelist.length<=0" class="add-info2" > <view v-if="namelist.length<=0" class="add-info2">
<view @click="chosenAddress()">请添加学员</view> <view @click="chosenAddress()">请添加学员</view>
</view> </view>
<view class="arrow" @click="chosenAddress()"> <view class="arrow" @click="chosenAddress()">
...@@ -241,7 +241,9 @@ ...@@ -241,7 +241,9 @@
<view class="notOption" v-if="submitOrder"></view> <view class="notOption" v-if="submitOrder"></view>
<good-list :list="goodData" v-if="showGoodList" @close="closeGoodListHandler"></good-list> <good-list :list="goodData" v-if="showGoodList" @close="closeGoodListHandler"></good-list>
<payCom v-if="payBtn" :payInfo="payInfo" :isAlipay="isAlipay" :StuId='JJSWStuId' :TeacherIds='mrk' @closePay="closePay"></payCom> <payCom v-if="payBtn" :payInfo="payInfo" :isAlipay="isAlipay" :StuId='JJSWStuId' :TeacherIds='EduTeacherId'
@closePay="closePay"></payCom>
<u-toast ref="uToast" /> <u-toast ref="uToast" />
<u-popup v-model="payExit" mode="center" :mask-close-able="false"> <u-popup v-model="payExit" mode="center" :mask-close-able="false">
<view style="background:#fff;width:500rpx"> <view style="background:#fff;width:500rpx">
...@@ -314,7 +316,25 @@ ...@@ -314,7 +316,25 @@
<!-- 支付宝弹窗 --> <!-- 支付宝弹窗 -->
<!-- <Alipay v-if="AlipayMask" :AlipayMask='AlipayMask' :payInfo="payInfo" :isAlipay="isAlipay" :StuId='JJSWStuId' :TeacherIds='mrk' @closePay="closePay"> <!-- <Alipay v-if="AlipayMask" :AlipayMask='AlipayMask' :payInfo="payInfo" :isAlipay="isAlipay" :StuId='JJSWStuId' :TeacherIds='mrk' @closePay="closePay">
</Alipay> --> </Alipay> -->
<u-popup mode="center" v-model="showExame">
<view style="width: 577rpx;padding-top:129rpx;text-align:center;height: 509rpx;background: #FFFFFF;border-radius: 50rpx; position: relative;">
<image src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Static/exambg.png" mode="widthFix" style="width:220rpx;height:118px;position: absolute; top:-52rpx;right:27rpx;"></image>
<view style="font-size: 34rpx;font-weight: bold;color: #10100F;">
测验提醒
</view>
<view style="margin-top:32rpx; font-size: 28rpx;font-weight: 500;color: #959595;">
此课程需要学员完成测验<br/>通过后才能报名
</view>
<view style="margin-top:50rpx">
<view style="width:50%;margin:0 auto;">
<u-button type="error" shape="circle" @click="goExameHandler">立即测验</u-button>
</view>
</view>
<view style="margin-top:30rpx;color:#FA5B23;font-size:30rpx" @click="showExame=false">
取消报名
</view>
</view>
</u-popup>
</view> </view>
</template> </template>
...@@ -337,10 +357,15 @@ ...@@ -337,10 +357,15 @@
}, },
data() { data() {
return { return {
AlipayMask:false, limits: false,
IsQZJC:0, AlipayMask: false,
mrk:'', IsQZJC: 0,
isAlipay: 2,//1微信 2微信支付宝 EduTeacherId: '',
ClassId: '',
PaperId:'',
PublishId:'',
// mrk3: '',
isAlipay: 2, //1微信 2微信支付宝
JJSWStuId: "", JJSWStuId: "",
Thename2: '', Thename2: '',
u: {}, u: {},
...@@ -402,7 +427,7 @@ ...@@ -402,7 +427,7 @@
IsFormShoppingCart: 2, IsFormShoppingCart: 2,
adressInfo: {}, adressInfo: {},
payInfo: { payInfo: {
OpenId: '',//ow_7I5XC1-RGwwk8QANBmWKYKmOc OpenId: '', //ow_7I5XC1-RGwwk8QANBmWKYKmOc
OrderId: '', OrderId: '',
OrderPayType: 1, OrderPayType: 1,
GoodsName: '' GoodsName: ''
...@@ -416,6 +441,8 @@ ...@@ -416,6 +441,8 @@
showcashcard: false, showcashcard: false,
onecoupon: true, //第一次进页面的时候选最优的优惠券 onecoupon: true, //第一次进页面的时候选最优的优惠券
IsDeposit: 0, //是否开启储蓄卡功能 IsDeposit: 0, //是否开启储蓄卡功能
showExame:false,
examInfo:''
}; };
}, },
onLoad(option) { onLoad(option) {
...@@ -440,6 +467,7 @@ ...@@ -440,6 +467,7 @@
this.mc = this.$uiConfig.mainColor; this.mc = this.$uiConfig.mainColor;
this.secondary = this.$uiConfig.secondary; this.secondary = this.$uiConfig.secondary;
}, },
onShow() { onShow() {
this.init(); this.init();
if (this.isLeave) { if (this.isLeave) {
...@@ -458,7 +486,7 @@ ...@@ -458,7 +486,7 @@
} }
this.requestJJSWAdmin(testCmd, postMsg, this.requestJJSWAdmin(testCmd, postMsg,
(res) => { (res) => {
console.log("111",res); // console.log("111",res);
if (res.data.Data.length > 0) { if (res.data.Data.length > 0) {
this.namelist = res.data.Data this.namelist = res.data.Data
this.Thename = res.data.Data[0].StuName this.Thename = res.data.Data[0].StuName
...@@ -500,7 +528,7 @@ ...@@ -500,7 +528,7 @@
closePay() { closePay() {
this.payBtn = false; this.payBtn = false;
this.payExit = true; this.payExit = true;
this.AlipayMask =false this.AlipayMask = false
}, },
closeGoodListHandler() { closeGoodListHandler() {
this.goodData = []; this.goodData = [];
...@@ -513,9 +541,53 @@ ...@@ -513,9 +541,53 @@
submitModel() { submitModel() {
this.showReviceModal = true; this.showReviceModal = true;
}, },
// 提交订单 // 报名限制
submitOrderHandler() { Registration() {
let that = this; let postMsg = {
StuId: this.JJSWStuId,
ClassIds: this.ClassId
}
let that = this
let obj={
// PaperId:this.PaperId,
// PublishId:this.PublishId,
// GuestId:this.JJSWStuId
}
this.requestJJSWAdmin("/api/WeChatPublic/CheckStuSubmitOrder", postMsg,
(res) => {
if (res.data.Code != 1) {
that.limits = true
if(res.data.Message&&res.data.Message!='')
{
uni.showToast({
title: res.data.Message,
icon: "none",
});
}
if(res.data.Data.PaperId>0&&res.data.Data.PublishId>0&&res.data.Data.StuId){
obj.PaperId=res.data.Data.PaperId
obj.PublishId=res.data.Data.PublishId
obj.StuId=res.data.Data.StuId
this.showExame=true
this.examInfo = JSON.stringify(obj)
// 跳转入学考试
}
} else {
that.limits = false
this.OrderInterface()
}
// console.log('llll',that.limits)
}
);
},
goExameHandler(){
uni.redirectTo({
url: `/pages/webbox/webbox?limit=${this.examInfo}`
});
},
// 提交订单接口
OrderInterface() {
// that.adressInfo.Consignee = '测试' // that.adressInfo.Consignee = '测试'
// that.adressInfo.ShoppingAddress = '四川成都龙泉驿1' // that.adressInfo.ShoppingAddress = '四川成都龙泉驿1'
// that.JJSWStuId = '10724'; // that.JJSWStuId = '10724';
...@@ -527,18 +599,13 @@ ...@@ -527,18 +599,13 @@
// }); // });
// return; // return;
// } // }
if (that.JJSWStuId == '' || that.Thename == '') { let that =this
this.$refs.uToast.show({ if (!this.submitOrder && !that.limits) {
title: '请添加学员!',
type: 'warning'
});
return;
}
if (!this.submitOrder) {
this.submitOrder = true; this.submitOrder = true;
uni.requestSubscribeMessage({ uni.requestSubscribeMessage({
tmplIds: this.ds.template_message_list, tmplIds: this.ds.template_message_list,
complete(res) { complete(res) {
// console.log('44444444444444444')
that.submitOrder = false; that.submitOrder = false;
let form = {}; let form = {};
// form.Consignee = that.adressInfo.Consignee; // form.Consignee = that.adressInfo.Consignee;
...@@ -563,7 +630,8 @@ ...@@ -563,7 +630,8 @@
form.Use_Integral = that.formdata.Use_Integral; form.Use_Integral = that.formdata.Use_Integral;
form.ShoppingCartIdList = that.ShoppingCartIdList; form.ShoppingCartIdList = that.ShoppingCartIdList;
form.JJSWStuId = that.JJSWStuId; form.JJSWStuId = that.JJSWStuId;
form.AnchorName = uni.getStorageSync("AnchorName") ? uni.getStorageSync("AnchorName") form.AnchorName = uni.getStorageSync("AnchorName") ? uni.getStorageSync(
"AnchorName")
.AnchorName : ''; //直播名称 .AnchorName : ''; //直播名称
if (that.mchs && that.mchs.length > 0) { if (that.mchs && that.mchs.length > 0) {
that.deduction_commission = that.mchs[0].deduction_commission; that.deduction_commission = that.mchs[0].deduction_commission;
...@@ -574,21 +642,22 @@ ...@@ -574,21 +642,22 @@
data: form data: form
}, },
res => { res => {
// console.log('7777777777')
if (res.resultCode == 1) { if (res.resultCode == 1) {
that.payInfo.OrderId = res.data.OrderId; that.payInfo.OrderId = res.data.OrderId;
that.payInfo.total_price = that.ds.total_price; that.payInfo.total_price = that.ds.total_price;
if(res.data.OrderStatus==5){ if (res.data.OrderStatus == 5) {
let info = { let info = {
OrderId:that.payInfo.OrderId, OrderId: that.payInfo.OrderId,
total_price: that.ds.total_price, total_price: that.ds.total_price,
StuId:that.JJSWStuId, StuId: that.JJSWStuId,
TeacherIds:that.mrk, TeacherIds: that.EduTeacherId,
} }
uni.reLaunch({ uni.reLaunch({
url: '/pages/order-submit/pay-success2?payInfo=' + url: '/pages/order-submit/pay-success2?payInfo=' +
JSON.stringify(info) JSON.stringify(info)
}) })
}else { } else {
if (that.checked == true) { if (that.checked == true) {
that.zhaoren = true; that.zhaoren = true;
let u = uni.getStorageSync("mall_UserInfo"); let u = uni.getStorageSync("mall_UserInfo");
...@@ -597,22 +666,25 @@ ...@@ -597,22 +666,25 @@
let SmallShopId = u.SmallShopId ? u.SmallShopId : 0; let SmallShopId = u.SmallShopId ? u.SmallShopId : 0;
if (SmallShopId == 0) { if (SmallShopId == 0) {
//如果微店id为0 去找所属微店id //如果微店id为0 去找所属微店id
SmallShopId = u.UserSmallShopId ? u.UserSmallShopId : 0; SmallShopId = u.UserSmallShopId ? u.UserSmallShopId :
0;
} }
that.path = '/pages/index/index?OrderId=' + res.data.OrderId + that.path = '/pages/index/index?OrderId=' + res.data
.OrderId +
"&user_id=" + uid + "&Up=" + Up + "&user_id=" + uid + "&Up=" + Up +
"&SmallShopId=" + SmallShopId + '&JumpType=4'; "&SmallShopId=" + SmallShopId + '&JumpType=4';
} else { } else {
if (that.formdata.Use_Deposit_Id != 0 && that.ds.total_price == if (that.formdata.Use_Deposit_Id != 0 && that.ds
.total_price ==
0) { //如果使用了储蓄卡 就直接支付成功 跳入支付结果 0) { //如果使用了储蓄卡 就直接支付成功 跳入支付结果
uni.reLaunch({ uni.reLaunch({
url: '/pages/order-submit/pay-success?payInfo=' + url: '/pages/order-submit/pay-success?payInfo=' +
JSON.stringify(that.payInfo) JSON.stringify(that.payInfo)
}) })
} else { //没使用的话 就弹出支付页面 } else { //没使用的话 就弹出支付页面
if(that.IsQZJC==1) { if (that.IsQZJC == 1) {
that.AlipayMask =true that.AlipayMask = true
} else { } else {
that.payBtn = true; that.payBtn = true;
} }
...@@ -634,6 +706,18 @@ ...@@ -634,6 +706,18 @@
}); });
} }
}, },
// 提交订单按钮
submitOrderHandler() {
let that = this;
if (that.JJSWStuId == '' || that.Thename == '') {
this.$refs.uToast.show({
title: '请添加学员!',
type: 'warning'
});
return;
}
that.Registration()
},
closeCouponHandler(e) { closeCouponHandler(e) {
if (e != -1) { if (e != -1) {
this.formdata.User_Coupon_Id = e; this.formdata.User_Coupon_Id = e;
...@@ -754,7 +838,10 @@ ...@@ -754,7 +838,10 @@
}); });
}, },
init() { init() {
let list =[] // 获取跳转接口
let EduTeacherIdlist = []
let ClassIdlist = []
// let list3 = []
this.loading = true; this.loading = true;
this.request2({ this.request2({
url: '/api/AppletOrder/GetAppletGoodsSettlementInfoForZY', url: '/api/AppletOrder/GetAppletGoodsSettlementInfoForZY',
...@@ -769,10 +856,15 @@ ...@@ -769,10 +856,15 @@
this.mchs.forEach(x => { this.mchs.forEach(x => {
x.goods_list.forEach(j => { x.goods_list.forEach(j => {
j.marketingLogo = JSON.parse(j.marketingLogo) j.marketingLogo = JSON.parse(j.marketingLogo)
list.push(j.EduTeacherId) EduTeacherIdlist.push(j.EduTeacherId)
ClassIdlist.push(j.EduData.ClassId)
// list3.push(j.EduData.ClassPersion)
}) })
}) })
this.mrk = list.toString()
this.EduTeacherId = EduTeacherIdlist.toString()
this.ClassId = ClassIdlist.toString()
// this.mrk3 = list3.toString()
this.payInfo.GoodsName = this.mchs[0].goods_list[0].name.slice(0, 10); this.payInfo.GoodsName = this.mchs[0].goods_list[0].name.slice(0, 10);
this.formdata.DeliveryMethod = this.mchs[0].delivery.send_type; this.formdata.DeliveryMethod = this.mchs[0].delivery.send_type;
this.ds = res.data; this.ds = res.data;
...@@ -868,8 +960,10 @@ ...@@ -868,8 +960,10 @@
</script> </script>
<style> <style>
.u-toast{
.add-info2{ height: auto !important;
}
.add-info2 {
width: 1px; width: 1px;
flex: 1; flex: 1;
min-height: 60px; min-height: 60px;
...@@ -878,6 +972,7 @@ ...@@ -878,6 +972,7 @@
display: flex; display: flex;
align-items: center; align-items: center;
} }
.determine-box { .determine-box {
margin: auto; margin: auto;
height: 80rpx; height: 80rpx;
......
...@@ -97,6 +97,7 @@ ...@@ -97,6 +97,7 @@
<auth v-if="showAuth" @changeuserinfo="reloadUserinfo" @gbAuth='goback'></auth> <auth v-if="showAuth" @changeuserinfo="reloadUserinfo" @gbAuth='goback'></auth>
<payCom v-if="payBtn&&u.TenantId!=27" :payInfo="payInfo" @closePay="closePay"></payCom> <payCom v-if="payBtn&&u.TenantId!=27" :payInfo="payInfo" @closePay="closePay"></payCom>
<submit2PayCom v-if="payBtn&&u.TenantId==27" :payInfo="payInfo" :isAlipay="isAlipay" :StuId='StuId' :TeacherIds='TeacherIds' @closePay="closePay"></submit2PayCom> <submit2PayCom v-if="payBtn&&u.TenantId==27" :payInfo="payInfo" :isAlipay="isAlipay" :StuId='StuId' :TeacherIds='TeacherIds' @closePay="closePay"></submit2PayCom>
<u-popup v-model="payExit" mode="center" :mask-close-able="false"> <u-popup v-model="payExit" mode="center" :mask-close-able="false">
<view style="background:#fff;width:500rpx"> <view style="background:#fff;width:500rpx">
<view style="padding:10px 0 0 10px">提交失败</view> <view style="padding:10px 0 0 10px">提交失败</view>
...@@ -322,6 +323,8 @@ ...@@ -322,6 +323,8 @@
this.Cancelmsg.OrderId = e.OrderId; this.Cancelmsg.OrderId = e.OrderId;
this.Cancelmsg.Type = e.OrderStatus == 1 ? 1 : 2; this.Cancelmsg.Type = e.OrderStatus == 1 ? 1 : 2;
}, },
// 待付款立即支付
payment(e) { payment(e) {
let list =[] let list =[]
this.payInfo.OrderId = e.OrderId; this.payInfo.OrderId = e.OrderId;
......
<template> <template>
<web-view :src="url" v-if="!showPhone"></web-view> <web-view :src="url"></web-view>
<view v-else class="indexassembly" > <!-- <view v-else class="indexassembly" >
<u-popup v-model="showPhone" mode="center" length="auto"> <u-popup v-model="showPhone" mode="center" length="auto">
<view style="width: 70vw;" class="mask"> <view style="width: 70vw;" class="mask">
<view <view
...@@ -21,12 +21,14 @@ ...@@ -21,12 +21,14 @@
</view> </view>
</view> </view>
</u-popup> </u-popup>
</view> </view> -->
</template> </template>
<script> <script>
export default { export default {
data() { data() {
return { return {
info:{},
show:false, show:false,
showPhone:true, showPhone:true,
showLogin: true, //多次点击 showLogin: true, //多次点击
...@@ -44,11 +46,19 @@ ...@@ -44,11 +46,19 @@
this.getCode() this.getCode()
}, },
onLoad: function(option) { //option为object类型,会序列化上个页面传递的参数 onLoad: function(option) { //option为object类型,会序列化上个页面传递的参数
this.url = decodeURIComponent(option.u) // this.url = decodeURIComponent(option.u)
if(option.auth){ if(option.auth||option.limit){
this.showPhone =true this.showPhone =true
if(option.limit) {
this.info=option.limit
// console.log('参数',this.info)
let limiturls =`https://jj.kookaku.com?limit=${this.info}`
this.url=decodeURIComponent(limiturls)
console.log('要跳转的链接',this.url)
}
} else { } else {
this.showPhone =false this.url = decodeURIComponent(option.u)
// this.showPhone =false
} }
}, },
methods: { methods: {
...@@ -133,8 +143,15 @@ ...@@ -133,8 +143,15 @@
(res) => { (res) => {
if (res.resultCode == 1) { if (res.resultCode == 1) {
that.obj.phoneNum =JSON.parse(res.data).phoneNumber that.obj.phoneNum =JSON.parse(res.data).phoneNumber
if(that.info) {
let limiturls =`https://jj.kookaku.com?phoneNum=${that.obj.phoneNum}&limit=${that.info}`
that.url=decodeURIComponent(limiturls)
} else {
let urls =`https://jj.kookaku.com?phoneNum=${that.obj.phoneNum}` let urls =`https://jj.kookaku.com?phoneNum=${that.obj.phoneNum}`
that.url=decodeURIComponent(urls) that.url=decodeURIComponent(urls)
}
that.showPhone =false that.showPhone =false
console.log('要跳转的链接',that.url) console.log('要跳转的链接',that.url)
// that.goUrl(`https://jj.kookaku.com?phoneNum=${that.obj.phoneNum}`) // that.goUrl(`https://jj.kookaku.com?phoneNum=${that.obj.phoneNum}`)
......
export default { export default {
install(Vue, options) { install(Vue, options) {
Vue.prototype.host = "https://wx.weibaoge.cn/web/index.php?_mall_id=1285" Vue.prototype.host = "https://wx.weibaoge.cn/web/index.php?_mall_id=1285"
//Vue.prototype.host2 = "http://192.168.10.128:8200"
Vue.prototype.host2 = "http://192.168.10.128:8200"//本地 //Vue.prototype.host3 = "http://192.168.10.128:8900"//本地
// Vue.prototype.host2 = "http://192.168.10.46:8200"
Vue.prototype.host2 = "https://mallApi.oytour.com"//测试 Vue.prototype.host2 = "https://mallApi.oytour.com"//测试
//进阶思维后台地址 //进阶思维后台地址
// Vue.prototype.host3 = "http://192.168.10.128:8900"//本地 //Vue.prototype.host3 = "http://192.168.10.128:8900"//本地
Vue.prototype.host3 = "https://jjeduapi.oytour.com"//测试 Vue.prototype.host3 = "https://jjeduapi.oytour.com"//测试
Vue.prototype.UploadConfig = function() { //本地上传配置 Vue.prototype.UploadConfig = function() { //本地上传配置
return { return {
...@@ -140,13 +138,14 @@ export default { ...@@ -140,13 +138,14 @@ export default {
msg: postMsg msg: postMsg
}, },
success: res => { success: res => {
typeof success == "function" && success(res);
if (res.data.Code == 10000) { if (res.data.Code == 10000) {
let u = uni.getStorageSync("mall_UserInfo"); let u = uni.getStorageSync("mall_UserInfo");
if (u) { if (u) {
this.getLogin_t(u) this.getLogin_t(u)
} }
} else if (res.Code == 1) { } else if (res.data.Code == 0) {
} else if (res.data.Code != 1) { } else if (res.data.Code != 1) {
...@@ -213,7 +212,7 @@ export default { ...@@ -213,7 +212,7 @@ export default {
// 获取小程序APPID // 获取小程序APPID
Vue.prototype.GetMiniAppId = function() { Vue.prototype.GetMiniAppId = function() {
let appObj = {}; let appObj = {};
let appType = 4; let appType = 13;
switch (appType) { switch (appType) {
case 1: //赞羊 case 1: //赞羊
appObj = { appObj = {
......
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