Commit a4621c31 authored by Mac's avatar Mac

1

parent 336da235
...@@ -32,14 +32,15 @@ ...@@ -32,14 +32,15 @@
></u-rate> ></u-rate>
<text class="good-rb-text">{{cx.course_score!=null &&cx.course_score>0?cx.course_score.toFixed(1):'5.0'}}</text> <text class="good-rb-text">{{cx.course_score!=null &&cx.course_score>0?cx.course_score.toFixed(1):'5.0'}}</text>
</view> </view>
<view class="good-rb-box" v-if="cx.is_pay==false"> <view class="good-rb-box" v-if="cx.is_pay==false && cx.price!=0">
<text style="font-size: 10px;color: #999999;text-decoration:line-through;margin-right: 2px;margin-top: 2px;">{{cx.original_price}}</text> <text style="font-size: 10px;color: #999999;text-decoration:line-through;margin-right: 2px;margin-top: 2px;">{{cx.original_price}}</text>
<text :style="{'font-size': '11px','color': pricecolor,'margin-top':'2px'}">¥</text> <text :style="{'font-size': '11px','color': pricecolor,'margin-top':'2px'}">¥</text>
<text :style="{'font-size': '16px','color': pricecolor}">{{cx.price.split('.')[0]}}</text> <text :style="{'font-size': '16px','color': pricecolor}">{{cx.price.split('.')[0]}}</text>
</view> </view>
<view class="good-rb-box" v-if="cx.is_pay==true"> <view class="good-rb-box" v-if="cx.is_pay==true&& cx.price!=0">
<text :style="{'font-size': '14px','color': pricecolor}">已购买</text> <text :style="{'font-size': '14px','color': pricecolor}">已购买</text>
</view> </view>
<view v-if="cx.price==0" style="font-size: 12px;color: #999999;">免费</view>
</view> </view>
</view> </view>
</view> </view>
......
...@@ -9,39 +9,31 @@ ...@@ -9,39 +9,31 @@
padding: 0 15rpx; padding: 0 15rpx;
" "
> >
<Text class="grid-text">商品库存有限,请尽快下单哦</Text> <Text class="grid-text" v-if='IsEducation!=1'>商品库存有限,请尽快下单哦</Text>
<Text class="grid-text" v-if='IsEducation==1'>{{list[0].GoodsList.length}}个课程</Text>
<Text @click="edit" v-if="editType == false && list[0].GoodsList.length>0" class="grid-text_r">编辑</Text> <Text @click="edit" v-if="editType == false && list[0].GoodsList.length>0" class="grid-text_r">编辑</Text>
<Text @click="edit" v-if="editType == true" class="grid-text_r">完成</Text> <Text @click="edit" v-if="editType == true" class="grid-text_r">完成</Text>
</view> </view>
<view style="width: 100%; height: 30rpx; background: #f7f7f7; margin: 20rpx 0;"></view> <view style="width: 100%; height: 30rpx; background: #f7f7f7; margin: 20rpx 0;"></view>
<u-empty v-if="emptyshow == true" text="购物车还是空的哦" mode="car"></u-empty> <u-empty v-if="emptyshow == true" text="购物车还是空的哦" mode="car"></u-empty>
<view <view v-if="list.length > 0" style="height: calc(100vh - 60px-30px-35px-20px);width: calc(100vw);overflow: hidden;padding-top: 10px;">
v-if="list.length > 0"
style="
height: calc(100vh - 60px-30px-35px-20px);
width: calc(100vw);
overflow: hidden;
padding-top: 10px;
"
>
<scroll-view :scroll-y="true" :enable-back-to-top="true" :enable-flex="true" :style="{ height: '100%' }"> <scroll-view :scroll-y="true" :enable-back-to-top="true" :enable-flex="true" :style="{ height: '100%' }">
<template v-if="list.length > 0 && emptyshow==false"> <template v-if="list.length > 0 && emptyshow==false">
<view class="cartList" :style="{ 'margin-bottom': listbottom }" v-for="(c, i) in list" :key="i"> <view class="cartList" :style="{ 'margin-bottom': listbottom }" v-for="(c, i) in list" :key="i">
<view <view
style=" style=" padding: 0 12px 12px 12px; border-bottom: 1rpx solid #f5f5f5; width: 100%;">
padding: 0 12px 12px 12px;
border-bottom: 1rpx solid #f5f5f5;
width: 100%;
"
>
<u-checkbox-group @change="mch_SelectAll(c.checked, i)"> <u-checkbox-group @change="mch_SelectAll(c.checked, i)">
<u-checkbox v-model="c.checked" shape="circle" :active-color="mc">{{ c.MallName }}</u-checkbox> <u-checkbox v-model="c.checked" shape="circle" :active-color="mc">{{ c.MallName }}</u-checkbox>
</u-checkbox-group> </u-checkbox-group>
</view> </view>
<view class="cartList_item" v-for="(item, index) in c.GoodsList" :key="index" :name="item.GoodsName" > <view class="cartList_item" v-for="(item, index) in c.GoodsList" :key="index" >
<!-- <view style="width: 40px;text-align: center;" v-if="(item.GoodsStatus == 1 && editType == true) || (item.InventoryNum!=0&&editType == false)"> --> <view style="width: 40px;text-align: center;" v-if="(item.GoodsStatus == 1 && item.InventoryNum!=0 && IsEducation!=1) || (editType == true&& IsEducation!=1)">
<view style="width: 40px;text-align: center;" v-if="(item.GoodsStatus == 1 && item.InventoryNum!=0) || (editType == true)"> <u-checkbox-group @change="clickcheckbox(item.checked, item.Price, index, i)">
<u-checkbox v-model="item.checked" shape="circle" :active-color="mc"></u-checkbox>
</u-checkbox-group>
</view>
<view style="width: 40px;text-align: center;" v-if="(item.GoodsStatus == 1 && IsEducation==1) || (editType == true)">
<u-checkbox-group @change="clickcheckbox(item.checked, item.Price, index, i)"> <u-checkbox-group @change="clickcheckbox(item.checked, item.Price, index, i)">
<u-checkbox v-model="item.checked" shape="circle" :active-color="mc"></u-checkbox> <u-checkbox v-model="item.checked" shape="circle" :active-color="mc"></u-checkbox>
</u-checkbox-group> </u-checkbox-group>
...@@ -50,47 +42,31 @@ ...@@ -50,47 +42,31 @@
<view class="invalid" :style="{ background: mc }" v-if="item.GoodsStatus != 1 && editType == false"> <view class="invalid" :style="{ background: mc }" v-if="item.GoodsStatus != 1 && editType == false">
<Text style="color: #fff; width: 22px;font-size: 20rpx;">失效</Text> <Text style="color: #fff; width: 22px;font-size: 20rpx;">失效</Text>
</view> </view>
<view class="invalid" :style="{ background: mc }" v-if="item.InventoryNum == 0 && editType == false"> <view class="invalid" :style="{ background: mc }" v-if="item.InventoryNum == 0 && editType == false && IsEducation!=1">
<Text style="color: #fff; width: 22px;font-size: 20rpx;">售馨</Text> <Text style="color: #fff; width: 22px;font-size: 20rpx;">售馨</Text>
</view> </view>
<image <image
:src="item.CoverImage" :src="item.CoverImage"
v-if='IsEducation!=1'
mode="aspectFill" mode="aspectFill"
style=" style="width: 150rpx;height: 150rpx;margin-left: 30rpx;border-radius: 5px;"
width: 150rpx; @click="clickHandler(item.GoodsId)"
height: 150rpx; />
margin-left: 30rpx; <image
border-radius: 5px; :src="item.CoverImage"
" v-if='IsEducation==1'
mode="aspectFill"
style="width: 116px;height: 64px;margin-left: 30rpx;border-radius: 5px;box-shadow:0 4px 10px 1px #D2D2D2;"
@click="clickHandler(item.GoodsId)" @click="clickHandler(item.GoodsId)"
/> />
<view
style="
display: flex;
flex-direction: column;
justify-content: space-between;
width: 440rpx;
height: 150rpx;
margin-left: 20rpx;
"
> <view class="item-r" :style="{'width':IsEducation!=1?'440rpx':item_r,'height':IsEducation!=1?'150rpx':'65px', }">
<view <view :class="IsEducation!=1?'item-r-n':'item-r-n2'">
style="
font-size: 26rpx;
width: 440rpx;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
"
>
<view v-if="item.MarketingLogo.iswords && item.MarketingLogo.iswords==1&& item.MarketingLogo.words!=''" class="Logo" :style= <view v-if="item.MarketingLogo.iswords && item.MarketingLogo.iswords==1&& item.MarketingLogo.words!=''" class="Logo" :style=
"{color: item.MarketingLogo.wordsColor, "{color: item.MarketingLogo.wordsColor,background:item.MarketingLogo.wordsBack ,}">
background:item.MarketingLogo.wordsBack ,}">
{{item.MarketingLogo.words}} {{item.MarketingLogo.words}}
</view> </view>
<image <image
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" mode="heightFix"
...@@ -99,75 +75,39 @@ ...@@ -99,75 +75,39 @@
/> />
{{ item.GoodsName}} {{ item.GoodsName}}
</view> </view>
<view <view style="width: 440rpx;overflow: hidden;white-space: nowrap;text-overflow: ellipsis;" v-if="IsEducation!=1">
style="
width: 440rpx;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
"
>
<Text v-for="(attr, inde2x) in item.SpecificationList" :key="inde2x" <Text v-for="(attr, inde2x) in item.SpecificationList" :key="inde2x"
style=" style="color: #a0a09d;font-size: 20rpx;margin-right: 5rpx;">
color: #a0a09d;
font-size: 20rpx;
margin-right: 5rpx;
"
>
{{ attr}} {{ attr}}
</Text> </Text>
</view> </view>
<view <view style="max-width: 440rpx;overflow: hidden;white-space: nowrap;text-overflow: ellipsis;margin-top: 2px;"
style="
max-width: 440rpx;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
margin-top: 2px;
"
@click.native.stop="goUrl(item.FreeShippingUrl)" @click.native.stop="goUrl(item.FreeShippingUrl)"
v-if="item.FreeShippingName !=null && (item.FreeShippingFullMoneyPinkage>0 || item.FreeShippingFullNumPinkage>0)" v-if="item.FreeShippingName !=null&&IsEducation!=1 && (item.FreeShippingFullMoneyPinkage>0 || item.FreeShippingFullNumPinkage>0)" >
>
<view style="color: #FF4048;background: #fdf6ec;padding: 0 5px;display: inline-block;"> <view style="color: #FF4048;background: #fdf6ec;padding: 0 5px;display: inline-block;">
<Text style=" <Text style="font-size: 20rpx;margin-right: 5rpx;">
font-size: 20rpx;
margin-right: 5rpx;
">
{{item.FreeShippingName !=null ?item.FreeShippingName+':':''}} {{item.FreeShippingName !=null ?item.FreeShippingName+':':''}}
<text v-if="item.FreeShippingFullMoneyPinkage==0 && item.FreeShippingFullNumPinkage>0">{{item.FreeShippingFullNumPinkage}}件包邮</text> <text v-if="item.FreeShippingFullMoneyPinkage==0 && item.FreeShippingFullNumPinkage>0">{{item.FreeShippingFullNumPinkage}}件包邮</text>
<text v-if="item.FreeShippingFullMoneyPinkage>0 && item.FreeShippingFullNumPinkage==0">{{item.FreeShippingFullMoneyPinkage}}元包邮</text> <text v-if="item.FreeShippingFullMoneyPinkage>0 && item.FreeShippingFullNumPinkage==0">{{item.FreeShippingFullMoneyPinkage}}元包邮</text>
</Text> </Text>
</view> </view>
</view> </view>
<view style="display: flex;flex-direction: row;align-items: center;justify-content: space-between;" >
<Text style="font-size: 30rpx;" :style="{ color: pricecolor }">
<view <Text style="40rpx">{{ item.Price }}</Text>
style="
display: flex;
flex-direction: row;
align-items: center;
justify-content: space-between;
"
>
<Text style="font-size: 30rpx;" :style="{ color: mc }">
<Text style="40rpx">{{ item.Price }}</Text>
</Text> </Text>
<u-number-box <u-number-box v-if='IsEducation!=1'
v-model="item.Number" v-model="item.Number"
:min="1" :min="1"
:max="item.InventoryNum" :max="item.InventoryNum"
@change="valChange(i, index, item.Number, item.Price, $event)" @change="valChange(i, index, item.Number, item.Price, $event)"
></u-number-box> ></u-number-box>
</view> </view>
<Text v-if="item.GoodsStatus != 1 && editType == false" style="font-size: 20rpx;color:#a0a09d ;">失效原因:商品下架或者库存不足</Text> <Text v-if="item.GoodsStatus != 1 && editType == false&&IsEducation!=1" style="font-size: 20rpx;color:#a0a09d ;">失效原因:商品下架或者库存不足</Text>
<Text v-if="item.GoodsStatus != 1 && editType == false&&IsEducation==1" style="font-size: 20rpx;color:#a0a09d ;">失效原因:课程下架</Text>
</view> </view>
</view> </view>
</view> </view>
</template> </template>
</scroll-view> </scroll-view>
...@@ -179,7 +119,7 @@ ...@@ -179,7 +119,7 @@
<u-checkbox-group @change="SelectAll"> <u-checkbox-group @change="SelectAll">
<u-checkbox v-model="allchecked" shape="circle" :active-color="mc">全选</u-checkbox> <u-checkbox v-model="allchecked" shape="circle" :active-color="mc">全选</u-checkbox>
</u-checkbox-group> </u-checkbox-group>
<Text style="font-size: 30rpx;" :style="{ color: mc }" v-if="editType == false">¥{{ TotalPrice }}</Text> <Text style="font-size: 30rpx;" :style="{ color: pricecolor }" v-if="editType == false">¥{{ TotalPrice }}</Text>
</div> </div>
<div class="bottom_btn" v-if="!editType"> <div class="bottom_btn" v-if="!editType">
<u-button <u-button
...@@ -241,6 +181,7 @@ export default { ...@@ -241,6 +181,7 @@ export default {
cart_id_list: [], cart_id_list: [],
mc: '', mc: '',
pricecolor:'',
secondary: '', secondary: '',
checkCount: 0, checkCount: 0,
msg: { msg: {
...@@ -249,7 +190,9 @@ export default { ...@@ -249,7 +190,9 @@ export default {
Name: '' Name: ''
}, },
u:{}, u:{},
showAuth:false showAuth:false,
IsEducation:0,//1是0否是网课模式
item_r:0,//课程模式下的宽度
}; };
}, },
created() {}, created() {},
...@@ -261,13 +204,25 @@ export default { ...@@ -261,13 +204,25 @@ export default {
this.navHeight = this.$navHeight - 2; this.navHeight = this.$navHeight - 2;
this.mc = this.$uiConfig.mainColor; this.mc = this.$uiConfig.mainColor;
this.secondary = this.$uiConfig.secondary; this.secondary = this.$uiConfig.secondary;
this.pricecolor = this.$uiConfig.pricecolor;
this.cstyle = uni.getStorageSync('basedata') ? uni.getStorageSync('basedata').cat_style : []; this.cstyle = uni.getStorageSync('basedata') ? uni.getStorageSync('basedata').cat_style : [];
this.IsEducation = uni.getStorageSync('basedata') ? uni.getStorageSync('basedata').mall.setting.mallStyle.IsEducation :0;
let windowWidth = this.$utils.SystemInfo().windowWidth;
this.item_r = (windowWidth - 5-40-116-15-10)+'px'
if (this.cstyle.cat_style == '4') { if (this.cstyle.cat_style == '4') {
} }
}, },
onShow(){ onShow(){
this.u = uni.getStorageSync('mall_UserInfo');
if (!this.u) {
this.u = {
nickName: '未登录',
avatarUrl: ''
};
this.showAuth = true;
}else{
this.init();
}
}, },
mounted() { mounted() {
let currentPages = getCurrentPages(); let currentPages = getCurrentPages();
...@@ -285,16 +240,7 @@ export default { ...@@ -285,16 +240,7 @@ export default {
uni.setNavigationBarTitle({ uni.setNavigationBarTitle({
title: this.pageTitle title: this.pageTitle
}); });
this.u = uni.getStorageSync('mall_UserInfo');
if (!this.u) {
this.u = {
nickName: '未登录',
avatarUrl: ''
};
this.showAuth = true;
}else{
this.init();
}
}, },
methods: { methods: {
...@@ -315,6 +261,10 @@ export default { ...@@ -315,6 +261,10 @@ export default {
init() { init() {
uni.showNavigationBarLoading(); uni.showNavigationBarLoading();
this.isloading=true; this.isloading=true;
this.IsEducation=1
if(this.IsEducation==1){
this.msg.GoodsClassify=2
}
this.request2( this.request2(
{ {
url: '/api/AppletOrder/GetGoodsShoppingCartPageList', url: '/api/AppletOrder/GetGoodsShoppingCartPageList',
...@@ -351,32 +301,7 @@ export default { ...@@ -351,32 +301,7 @@ export default {
uni.hideNavigationBarLoading(); uni.hideNavigationBarLoading();
} }
); );
// this.request(
// {
// url: '',
// header: h,
// data: {
// r: 'api/cart/list'
// }
// },
// res => {
// uni.hideNavigationBarLoading();
// this.isloading = false;
// if (res.data.list.length > 0) {
// let list = res.data.list;
// list.forEach(x => {
// x.checked = false;
// x.goods_list.forEach(j => {
// j.checked = false;
// });
// });
// this.list = list;
// } else {
// this.list = [];
// }
// }
// );
}, },
clickcheckbox(checked, price, index, i) { clickcheckbox(checked, price, index, i) {
...@@ -440,6 +365,7 @@ export default { ...@@ -440,6 +365,7 @@ export default {
this.TotalPrice = parseFloat(this.TotalPrice.toFixed(2)); this.TotalPrice = parseFloat(this.TotalPrice.toFixed(2));
}, },
mch_SelectAll(checked, i) { mch_SelectAll(checked, i) {
console.log(checked,'checked')
if (checked == true) { if (checked == true) {
let add_cartlist = []; let add_cartlist = [];
let new_statusnum = 0; let new_statusnum = 0;
...@@ -602,26 +528,7 @@ export default { ...@@ -602,26 +528,7 @@ export default {
} }
); );
// this.request(
// {
// url: '',
// method: 'POST',
// header: h,
// data: {
// r: 'api/cart/delete',
// cart_id_list: JSON.stringify(this.cart_id_list)
// }
// },
// res => {
// this.init();
// this.TotalPrice = 0;
// this.editType = false;
// this.allchecked = false;
// this.checkCount = 0;
// uni.hideNavigationBarLoading();
// }
// );
} else { } else {
uni.showToast({ uni.showToast({
title: '请选择需要删除的商品', title: '请选择需要删除的商品',
...@@ -661,9 +568,16 @@ export default { ...@@ -661,9 +568,16 @@ export default {
forms=good; forms=good;
console.log("forms",forms) console.log("forms",forms)
}); });
if(this.IsEducation!=1){
uni.navigateTo({ uni.navigateTo({
url: '/pages/order-submit/order-submit?formData=' + encodeURIComponent(JSON.stringify(forms))+'&IsFormShoppingCart=1&ShoppingCartIdList='+JSON.stringify(ShoppingCartIdList) url: '/pages/order-submit/order-submit?formData=' + encodeURIComponent(JSON.stringify(forms))+'&IsFormShoppingCart=1&ShoppingCartIdList='+JSON.stringify(ShoppingCartIdList)
}); });
}else if(this.IsEducation==1){
uni.navigateTo({
url: '/pages/school/course-submit?DetailList=' + encodeURIComponent(JSON.stringify(forms.DetailList))+'&IsFormShoppingCart=1&ShoppingCartIdList='+JSON.stringify(ShoppingCartIdList)
});
}
} else { } else {
uni.showToast({ uni.showToast({
title: '请选择购买商品', title: '请选择购买商品',
...@@ -795,4 +709,20 @@ export default { ...@@ -795,4 +709,20 @@ export default {
margin-right: 5rpx; margin-right: 5rpx;
border-radius: 4px; border-radius: 4px;
} }
.cartStyle .item-r{
display: flex;flex-direction: column;justify-content: space-between;width: 440rpx;height: 150rpx;margin-left: 20rpx;
}
.cartStyle .item-r-n{
font-size: 26rpx;width: 440rpx;
overflow: hidden; white-space: nowrap;text-overflow: ellipsis;
}
.cartStyle .item-r-n2{
font-size: 26rpx;width: 100%;
overflow: hidden;
text-overflow: ellipsis;
display: -webkit-box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
}
</style> </style>
...@@ -95,13 +95,13 @@ ...@@ -95,13 +95,13 @@
</view> </view>
</view> </view>
<view class="filed" style="margin-top: 20px;" > <view class="filed" style="margin-top: 20px;" >
<view class="left">优惠</view> <view class="left">优惠券优惠</view>
<view class="right"> <view class="right">
<text class="price" :style="{ color: pricecolor }">-{{ couponPrice.toFixed(2) }}</text> <text class="price" :style="{ color: pricecolor }">-{{ couponPrice.toFixed(2) }}</text>
</view> </view>
</view> </view>
<view class="filed" style="margin-top: 20px;" > <view class="filed" style="margin-top: 20px;" >
<view class="left">课程卡优惠</view> <view class="left">学习卡优惠</view>
<view class="right"> <view class="right">
<text class="price" :style="{ color: pricecolor }">-{{ EducationMoney.toFixed(2) }}</text> <text class="price" :style="{ color: pricecolor }">-{{ EducationMoney.toFixed(2) }}</text>
</view> </view>
...@@ -264,6 +264,12 @@ ...@@ -264,6 +264,12 @@
if (option.DetailList) { if (option.DetailList) {
this.formdata.DetailList = JSON.parse(decodeURIComponent(option.DetailList)); this.formdata.DetailList = JSON.parse(decodeURIComponent(option.DetailList));
} }
if (option.IsFormShoppingCart) {
this.IsFormShoppingCart = option.IsFormShoppingCart;
}
if (option.ShoppingCartIdList) {
this.ShoppingCartIdList = JSON.parse(option.ShoppingCartIdList);
}
this.mc = this.$uiConfig.mainColor; this.mc = this.$uiConfig.mainColor;
this.secondary = this.$uiConfig.secondary; this.secondary = this.$uiConfig.secondary;
this.pricecolor = this.$uiConfig.pricecolor; this.pricecolor = this.$uiConfig.pricecolor;
......
...@@ -2,20 +2,18 @@ ...@@ -2,20 +2,18 @@
<view class="courseContent"> <view class="courseContent">
<view class="course-top"> <view class="course-top">
<!-- <video id="myVideo" :src="selectcourse.FilePath"
@error="videoErrorCallback" controls></video> --> <video id="myVideo" v-if="selectcourse.Type==1" :src="selectcourse.FilePath"
<video id="myVideo" src="https://img.cdn.aliyun.dcloud.net.cn/guide/uniapp/%E7%AC%AC1%E8%AE%B2%EF%BC%88uni-app%E4%BA%A7%E5%93%81%E4%BB%8B%E7%BB%8D%EF%BC%89-%20DCloud%E5%AE%98%E6%96%B9%E8%A7%86%E9%A2%91%E6%95%99%E7%A8%8B@20181126-lite.m4v" @error="videoErrorCallback" controls duration='selectcourse.VideoTime'></video>
@error="videoErrorCallback" controls duration='70'></video>
</view> </view>
<view class="course-t"> <view class="course-t">
<view class="course-t-item"> <button open-type="share" class="course-t-item">
<image src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Static/fengx.png" class="share-icon" /> <image src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Static/fengx.png" class="share-icon" />
<text>分享</text> <text>分享</text>
</view> </button>
<view class="course-t-item" @click="setFavorite"> <view class="course-t-item" @click="setFavorite">
<u-icon :name="favorite ? 'like' : 'like-o'" size="44" :color="favorite ? mc : '#333'"></u-icon> <u-icon :name="favorite ? 'like' : 'like-o'" size="44" :color="favorite ? pricecolor : '#333'"></u-icon>
<!-- <u-icon name="like-o" size="44" style='margin-bottom: 12rpx;'></u-icon> -->
<text>收藏</text> <text>收藏</text>
</view> </view>
<view class="course-t-item"> <view class="course-t-item">
......
...@@ -63,7 +63,7 @@ ...@@ -63,7 +63,7 @@
</view> </view>
<view class="g-price-box"> <view class="g-price-box">
<view class="left"> <view class="left">
<view class="price u-skeleton-rect" > <view class="price u-skeleton-rect" v-if=" g.price!=0" >
<text class="small" :style="{ color: pricecolor }">¥</text> <text class="small" :style="{ color: pricecolor }">¥</text>
<text <text
class="numfont" :style="{ color: pricecolor }" class="numfont" :style="{ color: pricecolor }"
...@@ -185,22 +185,26 @@ ...@@ -185,22 +185,26 @@
</view> </view>
<view class="actionsheet" > <view class="actionsheet" >
<view style="display: flex;flex-direction: row;align-items: center;"> <view style="display: flex;flex-direction: row;align-items: center;">
<view class="price-btn " :style="{ color: pricecolor }" > <view class="price-btn " :style="{ color: pricecolor }" v-if="g.price!=0">
<text style="font-size: 11px;" ></text> <text style="font-size: 11px;" ></text>
<text style="font-family: oswald; font-weight: unset;font-size: 20px;">{{ g.price }}</text> <text style="font-family: oswald; font-weight: unset;font-size: 20px;">{{ g.price }}</text>
</view> </view>
<view class="price-btn " v-if="g.price==0">免费课程</view>
</view> </view>
<view style="display: flex;flex-direction: row;align-items: center;font-size: 14px;"> <view style="display: flex;flex-direction: row;align-items: center;font-size: 14px;">
<view style="width: 22px; margin: auto;margin-right: 15px;" @click="setFavorite"><u-icon :name="g.favorite ? 'like' : 'like-o'" size="44" :color="g.favorite ? mc : '#333'"></u-icon></view> <view style="width: 22px; margin: auto;margin-right: 15px;" @click="setFavorite"><u-icon :name="g.favorite ? 'like' : 'like-o'" size="44" :color="g.favorite ? pricecolor : '#333'"></u-icon></view>
<view class="gwuche" :style="{'border':'1px solid'+mc}" @click="joinCar()"> <view class="gwuche" :style="{'border':'1px solid'+mc}" @click="joinCar()" v-if="g.price!=0 && g.is_pay==false && g.is_orders==false">
<text :style="{color:mc}">加入购物车</text> <text :style="{color:mc}">加入购物车</text>
</view> </view>
<view class="gwuche" :style="{background:mc,'border':'1px solid'+mc}" v-if='g.is_pay==false && g.is_orders==true'> <view class="gwuche" :style="{background:mc,'border':'1px solid'+mc}" v-if='g.is_pay==false && g.is_orders==true && g.price!=0'>
<text style="color: #fff;" >去支付</text> <text style="color: #fff;" >去支付</text>
</view> </view>
<view class="gwuche" :style="{background:mc,'border':'1px solid'+mc}" v-if='g.is_pay==false && g.is_orders==false' @click="goSettlement"> <view class="gwuche" :style="{background:mc,'border':'1px solid'+mc}" v-if='g.is_pay==false && g.is_orders==false && g.price!=0' @click="goSettlement">
<text style="color: #fff;" >立即购买</text> <text style="color: #fff;" >立即购买</text>
</view> </view>
<view class="gwuche" :style="{background:mc,'border':'1px solid'+mc}" v-if='g.price==0||g.is_pay==true' >
<text style="color: #fff;" >学习中心</text>
</view>
</view> </view>
</view> </view>
...@@ -549,7 +553,6 @@ export default { ...@@ -549,7 +553,6 @@ export default {
icon: 'success', icon: 'success',
duration: 2000 duration: 2000
}); });
this.popupClose();
} }
); );
}, },
......
...@@ -3,7 +3,7 @@ export default { ...@@ -3,7 +3,7 @@ export default {
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.0.110:8200" // Vue.prototype.host2 = "http://192.168.0.110:8200"
// Vue.prototype.host2 = "https://mallApi.oytour.com" // Vue.prototype.host2 = "https://mallApi.oytour.com"
Vue.prototype.host2 = "http://192.168.1.9:8088" Vue.prototype.host2 = "http://192.168.1.5:8088"
// Vue.prototype.host2 = "http://192.168.1.21" // Vue.prototype.host2 = "http://192.168.1.21"
// Vue.prototype.host2 = "http://192.168.1.27:8200" // Vue.prototype.host2 = "http://192.168.1.27:8200"
Vue.prototype.request = function(param, success, failed) { Vue.prototype.request = function(param, success, failed) {
......
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