修改发票信息
This commit is contained in:
@@ -7,7 +7,8 @@ Page({
|
||||
* 页面的初始数据
|
||||
*/
|
||||
data: {
|
||||
detail: {}
|
||||
detail: {},
|
||||
id: "",
|
||||
},
|
||||
|
||||
/**
|
||||
@@ -19,14 +20,27 @@ Page({
|
||||
},
|
||||
async init(id) {
|
||||
const { code, message, data } = await getInvoiceInfoDetail(id)
|
||||
this.setData({ detail: data });
|
||||
this.setData({ detail: data, id });
|
||||
},
|
||||
handleBack() {
|
||||
wx.navigateBack()
|
||||
},
|
||||
jumpToDetail() {
|
||||
wx.redirectTo({
|
||||
url: '/pages/invoiceDetailContent/index',
|
||||
url: '/pages/invoiceDetailContent/index?id=' + this.data.id,
|
||||
})
|
||||
},
|
||||
download() {
|
||||
// console.log('---------')
|
||||
wx.showActionSheet({
|
||||
itemList: ['发票XML文件下载', '发票PDF文件下载'],
|
||||
async success(res) {
|
||||
console.log('res', res.tapIndex)
|
||||
const { code, message, data } = await downloadInvoice(this.data.id, res.tapIndex);
|
||||
if (code !== OK) {
|
||||
|
||||
}
|
||||
}
|
||||
})
|
||||
},
|
||||
/**
|
||||
|
Reference in New Issue
Block a user