diff --git a/components/commentsList.vue b/components/commentsList.vue
index 3aae86b..8333f65 100644
--- a/components/commentsList.vue
+++ b/components/commentsList.vue
@@ -198,19 +198,19 @@
font-size: 24rpx;
.name {
- color: #999;
+ color: #999; font-size: 28rpx;
@include toe();
}
.content {
color: #333;
- font-size: 26rpx;
+ font-size: 28rpx;
margin-top: 10rpx;
}
.others {
margin-top: 10rpx;
- color: #999;
+ color: #999; font-size: 28rpx;
align-items: center;
.dianzan {
diff --git a/config/baseUrl.js b/config/baseUrl.js
index 3b2a865..34b1545 100644
--- a/config/baseUrl.js
+++ b/config/baseUrl.js
@@ -12,13 +12,14 @@ if (process.env.NODE_ENV === 'development') {
// baseUrl = "http://59.110.212.44:9200/pb/";
// baseUrl = "http://192.168.110.100:9100/pb/"; // 开发用电脑
// baseUrl = "http://192.168.110.110:9200/pb/";
+ // baseUrl = "http://192.168.110.38:9200/pb/"; // 吴春磊笔记本1
// socketUrl = "ws://8.129.186.35:6001/";
} else if (process.env.NODE_ENV === 'production') {
// 生产环境11
- // baseUrl = "http://192.168.110.100:9200/pb/" // 开发用电脑
+ // baseUrl = "http://59.110.212.44:9100/pb/";
// baseUrl = "https://testapi.nuttyreading.com/";
// baseUrl = "http://192.168.110.110:9200/pb/";//磊哥
- baseUrl = "https://api.nuttyreading.com/"; // 正式环境
+ baseUrl = "https://api.nuttyreading.com/"; //1
// baseUrl = "ws://twin-ui.com:6001/";
// socketUrl = "ws://twin-ui.com:6001/";
}
diff --git a/pages/bookShop/orderLCont.vue b/pages/bookShop/orderLCont.vue
index 4deac51..b6a2e31 100644
--- a/pages/bookShop/orderLCont.vue
+++ b/pages/bookShop/orderLCont.vue
@@ -1088,10 +1088,22 @@ export default {
// 商品内容跳转
goDetail(id, data) {
- console.log("data at line 1277:", data);
+ console.log("data at line 1277:订单详情参数", data);
if (data.delFlag == -1) {
this.$commonJS.showToast("商品已下架");
- } else {
+ }else if(data.goodsType == '05'){
+ if(data.courseIds && data.courseIds.length > 0){
+ uni.navigateTo({
+ url: `/pages/course/courseDetail?id=${data.courseIds[0].courseId}`,
+ });
+ }else{
+ uni.showToast({
+ title: "课程数据出错",
+ icon: "none"
+ });
+ }
+
+ } else {
uni.navigateTo({
// url: '../bookShop/commodityDetail?id=' + item.id
url: `/pages/goods/index/index?navTitle=''&title=''&id=${id}`,
diff --git a/pages/component/commonComponents/selectGoods.vue b/pages/component/commonComponents/selectGoods.vue
index c8c32f9..8d206c2 100644
--- a/pages/component/commonComponents/selectGoods.vue
+++ b/pages/component/commonComponents/selectGoods.vue
@@ -50,7 +50,7 @@
: ''
}`"
>
-
+
-
+
{{ slotProps.row.productName }}
- ¥{{ slotProps.row.activityPrice?slotProps.row.activityPrice:slotProps.row.price }}
+
+ ¥{{slotProps.row.price}}
+ ¥{{ slotProps.row.activityPrice?slotProps.row.activityPrice:slotProps.row.price }}
+
+
diff --git a/pages/course/courseDetail.vue b/pages/course/courseDetail.vue
index 5e84414..42b35d5 100644
--- a/pages/course/courseDetail.vue
+++ b/pages/course/courseDetail.vue
@@ -167,11 +167,11 @@
{{ item.title }}
+ v-if="librayList[curIndex] && librayList[curIndex].isBuy == 1 || (userMsg.vip == 1 || userMsg.vip == 2)">
暂无章节内容
-
-
+
+
+ 学习进度
+
+
-
+
@@ -225,14 +228,22 @@
-
+
+
+ 留言板
+
+
+
+ 发布留言
+
+
@@ -271,8 +282,8 @@
-
-
+
+
回复@:{{ fatherSay.user.name }} 的留言
@@ -342,7 +353,8 @@
-
+
+
@@ -1612,7 +1624,7 @@
}
.sbmitBox {
- button {
+ button.submit {
margin-top: 20rpx;
margin-bottom: 20rpx;
@include theme("btn_bg");
diff --git a/pages/goods/index/index.vue b/pages/goods/index/index.vue
index a166865..4471507 100644
--- a/pages/goods/index/index.vue
+++ b/pages/goods/index/index.vue
@@ -877,7 +877,8 @@ export default {
productImages: this.selectGoodsData.productImages,
productId: this.selectGoodsData.productId,
productName: this.selectGoodsData.productName,
- price: this.selectGoodsData.activityPrice?this.selectGoodsData.activityPrice:this.selectGoodsData.price,
+ activityPrice:this.selectGoodsData.activityPrice,
+ price: this.selectGoodsData.price,
goodsType: this.selectGoodsData.goodsType,
},
],
diff --git a/pages/goods/order/index.vue b/pages/goods/order/index.vue
index e0e5df2..f2ba75e 100644
--- a/pages/goods/order/index.vue
+++ b/pages/goods/order/index.vue
@@ -53,15 +53,25 @@
{{ v.productName }}
-
+
-
-
- x 1
+
+
+
+
+ 原价:¥{{v.price}}
+
+ ¥{{ v.activityPrice && v.activityPrice > 0 ? v.activityPrice : v.price}}
+
+ x 1
+
+
+
@@ -411,6 +422,7 @@
},
data() {
return {
+ historyOrderInfo:undefined, //上一个订单的参数
isDefaultCurrency: false,
isShowAddress: false,
jfNumber: 0,
@@ -483,6 +495,7 @@
"margin-left": "30rpx",
},
modalInfo: {},
+ canjump:true, // 是否可以跳转到其他页面
currentCateIndex: 0,
show: false,
playData: {},
@@ -866,7 +879,7 @@
var s = 0;
var that = this;
for (var i = this.goodsDataList.length - 1; i >= 0; i--) {
- s += this.goodsDataList[i].price ? this.goodsDataList[i].price : 0;
+ s += this.goodsDataList[i].activityPrice && this.goodsDataList[i].activityPrice > 0 ? this.goodsDataList[i].activityPrice : this.goodsDataList[i].price;
}
that.totalPrice = s;
// !
@@ -928,6 +941,7 @@
}
},
async goBuyJie() {
+ console.log('this.buyingFlag',this.buyingFlag);
if (this.buyingFlag) {
uni.showToast({
title: '操作太频繁了,休息下吧',
@@ -947,6 +961,7 @@
setTimeout(() => {
this.nowClick = true;
}, 5000);
+
// let youPre = {
// id: "",
// coupons: {
@@ -969,7 +984,8 @@
this.$commonJS.showToast("请选择收货地址");
return false;
}
- }
+ }
+
let data = {
buyType: this.options.typeId, //0- 商品页直接下单 1- 购物车结算
userId: this.userInfo.id, //下单人ID
@@ -997,9 +1013,48 @@
appName: "wumen",
come: "2",
};
-
- console.log("data at line 477:", data);
-
+ var productList = [...data.productList]
+ var thisproduct = productList.map(item => {
+ return item.productId+"_"+item.quantity
+ })
+ thisproduct = thisproduct.join(',')
+ console.log("data at line 477:", data);
+ // console.log('成功信息',product,thisproduct,data.addressId, data.realMoney);
+ if(this.historyOrderInfo &&
+ thisproduct == this.historyOrderInfo.product &&
+ data.addressId == this.historyOrderInfo.addressId &&
+ this.historyOrderInfo.realMoney == data.realMoney){
+ that.canjump = false
+ uni.showModal({
+ title:'提示',
+ content:'您短时间内有一笔相同金额的订单,是否确定继续下单?',
+ cancelText:'点错了',
+ confirmText:'继续操作',
+ success: function(res) {
+ that.canjump = true
+ if (res.confirm) {
+
+ that.buyingFlag = false
+ console.log('用户点击确定',that.buyingFlag);
+ that.submitorder(data)
+ }
+ else{
+ that.buyingFlag = false
+ }
+ }
+ })
+ }else{
+ that.submitorder(data)
+ }
+ },
+
+ async submitorder(data){
+ uni.showLoading({
+ title:'正在请求订单'
+ })
+ // this.buyingFlag = false
+ console.log('进来请求了吗?');
+ let that = this
await $http
.request({
// url: "book/buyOrder/buySave",
@@ -1012,9 +1067,19 @@
},
})
.then(async (res) => {
- this.buyingFlag = false
- console.log("res at line 598:", res);
- if (res.code == 0) {
+ that.buyingFlag = false
+ var product = data.productList.map(item => {
+ return item.productId+"_"+item.quantity
+ })
+ product = product.join(',')
+ that.historyOrderInfo = {
+ 'product':product,
+ 'addressId':data.addressId,
+ 'realMoney':data.realMoney
+ }
+
+ console.log("res at line 598系统下单返回结果:", res);
+ if (res.code == 0) {
if (res.orderSn == null) {
uni.showToast({
title: "失败,请重新下单",
@@ -1023,12 +1088,12 @@
});
} else {
console.log("that.payType at line 607:", that.payType);
+ uni.showToast({
+ title: "下单成功,即将进行支付",
+ icon:'none'
+ })
if (that.payType == 2) {
- // 常规支付
- uni.showToast({
- title: "正在支付",
- icon: "loading",
- });
+ // 常规支付
await setPay({
typePay: "alipay",
subject: "order",
@@ -1042,12 +1107,14 @@
title: "加载中",
});
console.log(res, "支付支付");
- if (res.success) {
+ if (res.success) {
+ uni.hideLoading()
uni.showToast({
title: "支付成功",
});
setTimeout(() => {
- if (that.goToInfo.type == 1) {
+ if(that.canjump){
+ if (that.goToInfo.type == 1 ) {
uni.switchTab({
url: `${that.goToInfo.url}?type=order`,
});
@@ -1059,8 +1126,10 @@
url: `${that.goToInfo.url}?backType=order`,
});
}
+ }
}, 1000);
} else {
+ uni.hideLoading()
console.log("失败失败失败");
// this.buyingFlag = false
// that.$commonJS.showToast('支付是失败')
@@ -1068,13 +1137,12 @@
console.log("延迟调用 失败提示");
uni.showToast({
title: "支付失败",
-
image: "../../../static/icon/ic_close.png",
});
}, 0);
-
+
// setTimeout(() => {
-
+
// uni.navigateTo({
// url: './orderList'
// });
@@ -1082,7 +1150,7 @@
}
}
);
- } else if (this.payType == 1) {
+ } else if (that.payType == 1) {
// 微信支付
let data1 = {
orderSn: res.orderSn,
@@ -1092,26 +1160,26 @@
setWXPay(data1, (res) => {
if (res.success) {
// this.buyingFlag = false
+ uni.hideLoading()
uni.showToast({
title: "支付成功",
});
setTimeout(() => {
+ if(that.canjump){
if (that.goToInfo.type == 1) {
uni.switchTab({
url: `${that.goToInfo.url}?type=order`,
});
- } else {
- // uni.navigateBack({
- // delta: 2,
- // });
- // uni.n
+ } else {
uni.redirectTo({
url: `${that.goToInfo.url}?backType=order`,
});
}
+ }
}, 1000);
} else {
// this.buyingFlag = false
+ uni.hideLoading()
console.log(res, "微信支付111111111111111");
if (res.data.errMsg.indexOf("User canceled") != -1) {
uni.showToast({
@@ -1128,14 +1196,16 @@
}
}
});
- } else if (this.payType == 4) {
- // this.buyingFlag = false
+ } else if (that.payType == 4) {
+ that.buyingFlag = false
// 天医币支付
+ uni.hideLoading()
uni.showToast({
title: "购买成功",
icon: "success",
});
setTimeout(() => {
+ if(that.canjump){
if (that.goToInfo.type == 1) {
uni.switchTab({
url: `${that.goToInfo.url}?type=order`,
@@ -1145,15 +1215,16 @@
url: `${that.goToInfo.url}?backType=order`,
});
}
+ }
}, 1000);
}
}
}
}).catch(e => {
- this.buyingFlag = false
+ that.buyingFlag = false
+ uni.hideLoading()
});
},
-
radioChange(index) {
if (index == this.selectPayIndex) {
return
@@ -1866,6 +1937,7 @@
background-color: #fff;
.curriulum_title {
+ // width: calc(100% - 80rpx);
width: calc(100% - 80rpx);
font-weight: 500;
font-size: 30rpx;