Commit fa4c4855 by 张立顺

fix 提单bug修复

1 parent 2e6d44f7
......@@ -14,8 +14,8 @@ Component({
observer: function (n) {
}
},
resetTransNo:String,
resetOrder:Boolean
resetTransNo: String,
resetOrder: Boolean
},
/**
......@@ -38,8 +38,9 @@ Component({
* 组件的方法列表
*/
methods: {
noScroll() {},
noScroll() { },
close() {
let thisPage = wx.$router.getPageInstance()
let { routerBack } = this.data
if (routerBack) {
wx.navigateBack()
......@@ -48,6 +49,9 @@ Component({
this.setData({
show: false
})
thisPage.setData({
showPopup: false
})
},
input(e) {
let { value } = e.detail
......@@ -78,7 +82,7 @@ Component({
console.log(img)
let { code, data, message } = img
if (code == 0) {
payVoucherList.push({url: data})
payVoucherList.push({ url: data })
_this.setData({
payVoucherList
})
......@@ -110,38 +114,38 @@ Component({
})
},
confirm(e) {
let { outTradeNo, payVoucherList,resetOrder } = this.data
let { outTradeNo, payVoucherList, resetOrder } = this.data
// debugger
// console.log(wx.$router)
let thisPage = wx.$router.getPageInstance()
if(resetOrder) return this.newResetOrder()
if (resetOrder) return this.newResetOrder()
// if (orderType == 2) {
if (payVoucherList.length && outTradeNo) {
thisPage.setData({
['orderInfo.transactionNo']: outTradeNo,
['orderInfo.paymentDocList']: payVoucherList.map(item=>item.url)
})
console.log(thisPage.handleSecondConfirm);
thisPage.handleSecondConfirm()
} else {
wx.$util.showToast('交易流水号或付款凭证不能为空!')
}
if (payVoucherList.length && outTradeNo) {
thisPage.setData({
['orderInfo.transactionNo']: outTradeNo,
['orderInfo.paymentDocList']: payVoucherList.map(item => item.url)
})
console.log(thisPage.handleSecondConfirm);
thisPage.handleSecondConfirm()
} else {
wx.$util.showToast('交易流水号或付款凭证不能为空!')
}
// }
},
// 标记错误订单&补录订单
newResetOrder(){
let { resetTransNo, payVoucherList } = this.data
newResetOrder() {
let { resetTransNo, payVoucherList } = this.data
let thisPage = wx.$router.getPageInstance()
if (payVoucherList.length && resetTransNo) {
thisPage.setData({
['orderInfo.transactionNo']: resetTransNo,
['orderInfo.paymentDocList']: payVoucherList.map(item=>item.url)
['orderInfo.paymentDocList']: payVoucherList.map(item => item.url)
})
thisPage.handleSecondConfirm()
} else {
wx.$util.showToast('交易流水号或付款凭证不能为空!')
}
}
}
})
......@@ -356,8 +356,8 @@ Page({
} = this.data
// 先写死调试
getQuotationInfoById({
id
})
id
})
.then(result => {
console.log('result', result)
let {
......@@ -393,7 +393,7 @@ Page({
}
})
.catch(err => {})
.catch(err => { })
},
totalFee() {
let {
......@@ -491,9 +491,9 @@ Page({
orderInfo
} = this.data
listByMerchantIdAndIds({
merchantId: default4SStoreInfo.merchantId,
suitCarPrice: price ? parseFloat((price / 10000).toFixed(4)) : ''
})
merchantId: default4SStoreInfo.merchantId,
suitCarPrice: price ? parseFloat((price / 10000).toFixed(4)) : ''
})
.then(result => {
console.log(result, 'result')
// debugger
......@@ -539,7 +539,7 @@ Page({
// 判断有没有勾选商品,有的话调用一下
orderInfo.vdQuotationGoodsList.length && this.totalFee()
})
.catch(err => {})
.catch(err => { })
},
// 后面改成全局方法
// 除以100保留两位小数点
......@@ -600,7 +600,7 @@ Page({
navBarHeight
})
},
init() {},
init() { },
onRoute(options) {
console.log(options, 'options')
// 判断是编辑还是新增
......@@ -674,35 +674,35 @@ Page({
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady() {},
onReady() { },
/**
* 生命周期函数--监听页面显示
*/
onShow() {},
onShow() { },
/**
* 生命周期函数--监听页面隐藏
*/
onHide() {},
onHide() { },
/**
* 生命周期函数--监听页面卸载
*/
onUnload() {},
onUnload() { },
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh() {},
onPullDownRefresh() { },
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom() {},
onReachBottom() { },
/**
* 用户点击右上角分享
*/
onShareAppMessage() {}
onShareAppMessage() { }
})
\ No newline at end of file
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!