Commit 8610a0d2 authored by zhangjianguo's avatar zhangjianguo

修改小程序

parent 981f0a45
......@@ -20,9 +20,10 @@
<view class="ticket">
<view class="miane">
<view class="money">
<text class="small" v-if="x.coupon_data.type==2"></text>
<text class="small" v-if="x.coupon_data.type==1"></text>
<text style="font-size: 44px;">{{x.sub_price.toString().split('.')[0]}}</text>
<text class="small" v-if="x.coupon_data.type==1"></text>
<text class="small" v-if="x.coupon_data.type==2"></text>
</view>
<view class="tiaojian">{{x.coupon_min_price}}元可用</view>
</view>
......
......@@ -480,6 +480,9 @@ export default {
this.expressPrice = 0.0;
this.goodPrice = 0.0;
this.couponPrice = 0.0;
if(res.data.total_price<0){
this.ds.total_price =0
}
this.integral = {
can_use: false,
use: false,
......
......@@ -70,27 +70,25 @@ export default {
},
methods: {
initRecommend() {
this.request(
{
url: "",
data: {
r: "api/goods/new-recommend",
goods_id: 0,
type: "goods",
},
},
this.request2(
{
url: "/api/AppletGoods/GetAppletGoodsRecommendListForZY",
data: {
RecommendType: 1,
},
},
(res) => {
this.recommend = res.data.list;
this.recommend = res.data.List;
}
);
},
redictToOrders() {
uni.redirectTo({
uni.reLaunch({
url: "/pages/order/index/index?status=2",
});
},
goHome() {
uni.redirectTo({
uni.reLaunch({
url: "/pages/index/index",
});
},
......
......@@ -44,7 +44,7 @@
<view
style="margin-top: 40rpx;"
class="block"
v-if="d.ReOrderStatus=='3' || d.ReOrderStatus=='4'"
v-if="d.ReOrderStatus=='3' || d.ReOrderStatus=='4'|| d.ReOrderStatus=='5'"
>
<view class="good-title">{{d.ReOrderStatus==3?'退货物流':'换货物流'}} </view>
<view class="filed">
......
......@@ -24,7 +24,7 @@
<u-number-box :disabled="forms.Type==1" :min="1" :max="good.Number" v-model="forms.ReNumber" @change="valChange"></u-number-box>
</view>
</view> -->
<view class="num-box">
<view class="num-box" v-if='forms.Type==1'>
<view class="left">退款金额</view>
<view class="right" style="display: flex;flex-direction: row;align-items: center;">
<input
......@@ -193,7 +193,7 @@ export default {
},
inputnum(val){
let that = this
let totelPrice = that.good.Final_Price - that.good.FreightMoney
let totelPrice = that.good.Final_Price
if(val.target.value>totelPrice){
console.log('进入')
that.forms.Refund= totelPrice
......@@ -219,10 +219,11 @@ export default {
if (!that.submitStatus) {
that.submitStatus = true;
let msg = "";
console.log(that.forms)
if (that.forms.Remark == "") {
msg = "亲,请描述一下你遇到的问题吧";
} else if(that.forms.Refund==''){
msg = "亲,退款金额不能为空";
} else if(that.forms.Refund<0){
msg = "亲,退款金额为正数";
}else if (that.forms.VoucherList.length == 0) {
msg = "亲,请上传一张说明截图吧";
}
......@@ -242,7 +243,7 @@ export default {
confirmText: "查看记录",
success: function (res) {
if (res.confirm) {
uni.navigateTo({
uni.reLaunch({
url: "/pages/order/after-sale/refunds-list",
});
}
......
......@@ -23,7 +23,9 @@
</view>
<view class="status" :style="[headStyle]">
<view class="status-title">{{ orders.OrderStatusName }}</view>
<view class="sub-title">
<view class="sub-title"
v-if='orders.OrderStatus==1 || orders.OrderStatus==2 ||orders.OrderStatus==3||orders.OrderStatus==4 '
>
<u-icon
style="display: inline-block; vertical-align: middle;"
name="warning-o"
......@@ -31,7 +33,7 @@
size="28"
></u-icon>
<!-- TODO返回字段 不能写死 -->
<text style="margin-left: 5px;">交易成功14天,系统自动确认完成</text>
<text style="margin-left: 5px;">交易成功{{delivery_time}}天,系统自动确认完成</text>
<!-- TODO 交易情况说明 -->
</view>
</view>
......@@ -370,6 +372,7 @@ export default {
},
showAfter: false,
showModal: false,
delivery_time:14,//时间
};
},
onLoad(option) {
......@@ -380,6 +383,7 @@ export default {
let nav = uni.getMenuButtonBoundingClientRect();
this.headStyle.paddingTop = nav.top + "px";
this.contentStyle.paddingTop = nav.top + 44 + "px";
this.delivery_time = uni.getStorageSync('basedata') ? uni.getStorageSync('basedata').mall.setting.delivery_time : 14;
let p = getCurrentPages();
if (p.length > 1) {
......
......@@ -85,12 +85,15 @@
uni.getImageInfo({
src: that.qrcode.PosterBgImg,
success: function (image) {
console.log('绘制')
ctx.drawImage(image.path, 0, 0, 750, 1344);//绘制图
if(that.qrcode.IsShowHead==0){
that.drawTitle(ctx); //绘制文字
}
if(that.qrcode.IsShowNick==0){
console.log('绘制文字')
that.drawTitle(ctx); //绘制文字
}
if(that.qrcode.IsShowHead==0){
console.log('绘制头像')
uni.getImageInfo({//头像
src: that.UserInfo.Photo,
success: function (image) {
......@@ -107,7 +110,7 @@
if(that.qrcode.IsShowQrCode==0){ //二维码
console.log('绘制二维码')
uni.getImageInfo({
// src: that.UserInfo.Photo,
src: that.fenxqrcode,
......@@ -117,12 +120,15 @@
that.drawQrCode(ctx)
},
});
}else{
that.drawQrCode(ctx)
}
},
});
}else{
if(that.qrcode.IsShowQrCode==0){
console.log('绘制二维码')
uni.getImageInfo({//头像
src: that.fenxqrcode,
success: function (image) {
......@@ -131,6 +137,8 @@
that.drawQrCode(ctx)
},
});
}else{
that.drawQrCode(ctx)
}
}
......
......@@ -195,11 +195,7 @@ console.log(wx.getStorageSync('basedata'))
},
goUrl(url) {
if(url =='/pages/order/refund/index'){
uni.navigateTo({
url: '/pages/order/after-sale/refunds-list'
});
}else if(url =='/pages/balance/balance'){
if(url =='/pages/balance/balance'){
uni.navigateTo({
url: '/pages/balance/balance?balance='+this.user_info.balance
});
......
export default {
install(Vue, options) {
Vue.prototype.host = "https://wx.weibaoge.cn/web/index.php?_mall_id=1285"
// Vue.prototype.host2 = "https://mallApi.oytour.com"
//Vue.prototype.host2 = "http://192.168.2.16:8088"
Vue.prototype.host2 = "https://mallApi.oytour.com"
Vue.prototype.request = function(param, success, failed) {
//网络请求
uni.request({
url: this.host + "&r=" + param.data.r,
method: param.method || "GET",
header: param.header || {
'content-type': "application/json"
},
data: param.data,
success: res => {
if (res.data.code != 0 && res.data.msg != "商品未上架") {
}
typeof success == "function" && success(res.data);
},
fail: (e) => {
console.log("网络请求fail:" + JSON.stringify(e));
uni.showModal({
content: "" + res.errMsg
});
typeof failed == "function" && failed(res.data);
}
});
}
// Vue.prototype.host2 = "http://192.168.0.110:8200"
Vue.prototype.host2 = "https://mallApi.oytour.com"
// Vue.prototype.host2 = "http://192.168.2.16:8088"
// Vue.prototype.host2 = "http://192.168.2.65"
Vue.prototype.request2 = function(param, success, failed) {
//网络请求
uni.request({
......@@ -48,7 +23,10 @@ export default {
},
success: res => {
if (res.data.resultCode != 1) {
uni.showToast({
title: res.data.message,
icon: "none",
});
} else {
typeof success == "function" && success(res.data);
}
......
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