|
@@ -31,7 +31,8 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
<view class="mall-bottom-row">
|
|
|
- <view v-if="item.type ==1" class="kcb-btn" @click="productBtn(item.levelList)">课程包明细<icon>
|
|
|
+ <view v-if="item.type ==1" class="kcb-btn" @click="productBtn(item.levelList)">课程包明细
|
|
|
+ <icon>
|
|
|
</icon>
|
|
|
</view>
|
|
|
<view class="hdj-text">活动价:{{item.xianjia}}</view>
|
|
@@ -40,34 +41,35 @@
|
|
|
</scroll-view>
|
|
|
</view>
|
|
|
<view v-if="productData.current === 1">
|
|
|
- <scroll-view scroll-y="true" :scroll-into-view="scrollIntoId" class="order-scroll-view">
|
|
|
- <!--数学-->
|
|
|
- <view :id="'item-' + item.id" v-for="item in productData.list" :key="item.id"
|
|
|
- class="mall-list-item">
|
|
|
- <view class="mall-content-box" :class="item.yigou ==1?'mall-yigou-box':''">
|
|
|
- <img :src='item.cover' class="mall-image" />
|
|
|
- <view class="content-body-box">
|
|
|
- <view class="content-name">
|
|
|
- <view class="name-text">{{item.name}}</view>
|
|
|
- </view>
|
|
|
- <view class="content-text">{{item.intro}}</view>
|
|
|
- <view class="content-row">
|
|
|
- <view class="content-yuanjia">原价:{{item.yuanjia}}</view>
|
|
|
- <view class="shop-car-box" v-if="item.yigou !=1" @click="addProduct(item)">
|
|
|
- <icon v-if="productData.selectedIds.includes(item.id)" class="car-change">
|
|
|
- </icon>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
- <view class="mall-bottom-row">
|
|
|
- <view v-if="item.type ==1" class="kcb-btn" @click="productBtn(item.levelList)">课程包明细<icon>
|
|
|
- </icon>
|
|
|
- </view>
|
|
|
- <view class="hdj-text">活动价:{{item.xianjia}}</view>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
- </scroll-view>
|
|
|
+ <scroll-view scroll-y="true" :scroll-into-view="scrollIntoId" class="order-scroll-view">
|
|
|
+ <!--数学-->
|
|
|
+ <view :id="'item-' + item.id" v-for="item in productData.list" :key="item.id"
|
|
|
+ class="mall-list-item">
|
|
|
+ <view class="mall-content-box" :class="item.yigou ==1?'mall-yigou-box':''">
|
|
|
+ <img :src='item.cover' class="mall-image" />
|
|
|
+ <view class="content-body-box">
|
|
|
+ <view class="content-name">
|
|
|
+ <view class="name-text">{{item.name}}</view>
|
|
|
+ </view>
|
|
|
+ <view class="content-text">{{item.intro}}</view>
|
|
|
+ <view class="content-row">
|
|
|
+ <view class="content-yuanjia">原价:{{item.yuanjia}}</view>
|
|
|
+ <view class="shop-car-box" v-if="item.yigou !=1" @click="addProduct(item)">
|
|
|
+ <icon v-if="productData.selectedIds.includes(item.id)" class="car-change">
|
|
|
+ </icon>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ <view class="mall-bottom-row">
|
|
|
+ <view v-if="item.type ==1" class="kcb-btn" @click="productBtn(item.levelList)">课程包明细
|
|
|
+ <icon>
|
|
|
+ </icon>
|
|
|
+ </view>
|
|
|
+ <view class="hdj-text">活动价:{{item.xianjia}}</view>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ </scroll-view>
|
|
|
</view>
|
|
|
<!-- <view v-if="productData.current === 2">
|
|
|
<view>语文</view>
|
|
@@ -97,8 +99,7 @@
|
|
|
|
|
|
<view v-if="currentPlatform =='android'" class="pay-btn" @touchstart="creatOrder">立即支付
|
|
|
</view>
|
|
|
- <view v-if="currentPlatform =='ios'" class="pay-btn"
|
|
|
- @touchstart="creatOrderIos">立即支付</view>
|
|
|
+ <view v-if="currentPlatform =='ios'" class="pay-btn" @touchstart="creatOrderIos">立即支付</view>
|
|
|
</view>
|
|
|
<detail-dialog ref="mallDetailPopup" :selected-list="getSelectedProducts"></detail-dialog>
|
|
|
|
|
@@ -189,12 +190,12 @@
|
|
|
toast("请选择至少一个商品查看明细");
|
|
|
return;
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
showDetail.value = !showDetail.value;
|
|
|
- if (showDetail.value) {
|
|
|
- const selected = productData.list.filter(item =>
|
|
|
- productData.selectedIds.includes(item.id)
|
|
|
- );
|
|
|
+ if (showDetail.value) {
|
|
|
+ const selected = productData.list.filter(item =>
|
|
|
+ productData.selectedIds.includes(item.id)
|
|
|
+ );
|
|
|
mxjtClass.value = 'mxjt-zk-icon';
|
|
|
mallDetailPopup.value.detailShow(selected);
|
|
|
} else {
|
|
@@ -223,13 +224,13 @@
|
|
|
const mergeList = [...new Set([...localList, ...data.levelIdList])]
|
|
|
cacheManager.updateObject('auth', {
|
|
|
levelIdList: mergeList
|
|
|
- })
|
|
|
-
|
|
|
- uni.redirectTo({
|
|
|
- url: '/pages/pay/order?status=2'
|
|
|
- })
|
|
|
-
|
|
|
- // toast("chenggong!!!! 之后跳转我的订单页面")
|
|
|
+ })
|
|
|
+
|
|
|
+ uni.redirectTo({
|
|
|
+ url: '/pages/pay/order?status=2'
|
|
|
+ })
|
|
|
+
|
|
|
+ // toast("chenggong!!!! 之后跳转我的订单页面")
|
|
|
|
|
|
// if (formPage.value == 'my') {
|
|
|
// uni.redirectTo({
|
|
@@ -557,18 +558,8 @@
|
|
|
orderAdd(req).then(res => {
|
|
|
console.log('res', res);
|
|
|
console.log(' res.data.id', res.data.id);
|
|
|
- orderId.value = res.data.id
|
|
|
- orderCheck({
|
|
|
- id: orderId.value
|
|
|
- }).then(res3 => {
|
|
|
- console.log('res3', res3);
|
|
|
- if (res3.code == 0) {
|
|
|
- genggaiVip(res3.data)
|
|
|
- }
|
|
|
- })
|
|
|
-
|
|
|
-
|
|
|
- // wxPay()
|
|
|
+ orderId.value = res.data.id
|
|
|
+ wxPay()
|
|
|
}).catch((err) => {
|
|
|
uni.hideLoading();
|
|
|
toast("订单创建失败")
|