合并开发票跳转的逻辑完善,填写发票信息的静态页面和订单详情接口对接,提交接口的对接
This commit is contained in:
parent
4bcbc1494c
commit
96dda0b4c1
File diff suppressed because it is too large
Load Diff
@ -14,9 +14,9 @@
|
|||||||
<!-- 合开发票 -->
|
<!-- 合开发票 -->
|
||||||
<view v-if="selected == 0">
|
<view v-if="selected == 0">
|
||||||
<view class="invoiceList" v-for="(item,index) in unInvoiceList" :key="index">
|
<view class="invoiceList" v-for="(item,index) in unInvoiceList" :key="index">
|
||||||
<view class="invoiceList-item flex">
|
<view class="invoiceList-item flex" @click="checkInvoice(item.invoiceCheck,index)">
|
||||||
<view class="changedBox">
|
<view class="changedBox">
|
||||||
<view class="changedBox-Img" @click="checkInvoice(item.invoiceCheck,index)">
|
<view class="changedBox-Img" >
|
||||||
<image v-if="item.invoiceCheck === 1" style="width: 44rpx;height: 44rpx;" src="../../static/fabu/check.png" mode=""></image>
|
<image v-if="item.invoiceCheck === 1" style="width: 44rpx;height: 44rpx;" src="../../static/fabu/check.png" mode=""></image>
|
||||||
<image v-else style="width: 44rpx;height: 44rpx;" src="../../static/fabu/nocheck.png" mode=""></image>
|
<image v-else style="width: 44rpx;height: 44rpx;" src="../../static/fabu/nocheck.png" mode=""></image>
|
||||||
|
|
||||||
@ -217,6 +217,8 @@
|
|||||||
upList: [],//支票抬头列表
|
upList: [],//支票抬头列表
|
||||||
count:0,
|
count:0,
|
||||||
order_nos: '',//选中的多个订单号
|
order_nos: '',//选中的多个订单号
|
||||||
|
num:0,
|
||||||
|
id: 0,
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
onLoad(option) {
|
onLoad(option) {
|
||||||
@ -305,14 +307,31 @@
|
|||||||
handleIssueInvoice() {
|
handleIssueInvoice() {
|
||||||
//拿到选中的订单
|
//拿到选中的订单
|
||||||
const list = this.unInvoiceList.filter(item => item.invoiceCheck == 1).map(item => item.order_no)
|
const list = this.unInvoiceList.filter(item => item.invoiceCheck == 1).map(item => item.order_no)
|
||||||
console.log('list:',list);
|
const idList = this.unInvoiceList.filter(item => item.invoiceCheck == 1).map(item => item.id)
|
||||||
|
console.log('list:',list,idList);
|
||||||
// this.order_nos = JSON.stringify(list)
|
// this.order_nos = JSON.stringify(list)
|
||||||
this.order_nos = JSON.stringify(list.join(','))
|
this.order_nos = JSON.stringify(list.join(','))
|
||||||
const num = list.length
|
this.num = list.length
|
||||||
console.log('num:',num);
|
console.log('num:',this.num);
|
||||||
uni.navigateTo({
|
if(list.length<1){
|
||||||
url:'/packageB/invoice/addInvoice?order_nos=' + this.order_nos + '&num?' + num
|
uni.showToast({
|
||||||
})
|
title: '请选择需要开发票的订单',
|
||||||
|
icon: 'none',
|
||||||
|
duration: 2000
|
||||||
|
})
|
||||||
|
}else if(list.length === 1){
|
||||||
|
this.id = idList[0]
|
||||||
|
console.log('id',this.id);
|
||||||
|
uni.navigateTo({
|
||||||
|
url:'/packageB/invoice/addInvoice?order_nos=' + this.order_nos + '&num=' + this.num + '&id=' + this.id
|
||||||
|
})
|
||||||
|
}
|
||||||
|
else{
|
||||||
|
uni.navigateTo({
|
||||||
|
url:'/packageB/invoice/addInvoice?order_nos=' + this.order_nos + '&num=' + this.num
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user