临时提交

dev
lilu 2 years ago
parent fa4baad677
commit a40ca2231f

@ -606,4 +606,11 @@ export function BookingOrderPrintTemplateList(parameter) {
params: parameter
})
}
//
export function LetterYardPdf(parameter) {
return axios({
url: '/BookingOrder/LetterYardPdf',
method: 'get',
params: parameter
})
}

@ -1040,7 +1040,7 @@ export default {
// - start
getVoynoinner(name = '') {
console.log('暂无接口', name, this.voynoinnerData, this.voynoinnerDataArr)
// console.log('', name, this.voynoinnerData, this.voynoinnerDataArr)
},
voynoinnerSelect(value) {
this.details.voynoinner = value
@ -1053,7 +1053,7 @@ export default {
// 线 - start
getLanename(name = '') {
console.log('暂无接口', name, this.lanenameData, this.lanenameDataArr)
// console.log('', name, this.lanenameData, this.lanenameDataArr)
},
lanenameSelect(value) {
this.details.lanename = value
@ -1301,6 +1301,9 @@ export default {
.table-no-data {
text-align: center;
}
/deep/ .date-box{
padding-top: 7px;
}
// .ant-calendar-picker-input{
// padding: 0 4px;

@ -413,6 +413,10 @@
<a-button type="primary" @click="removeModel" :loading="DelLoading" v-if="['initCabin'].includes(modelType)">
删除
</a-button>
<template v-if="modelType === 'initCabin'"></template>
<a-button type="primary" @click="downLoadFile(2)" :loading="downLoadLoading">EXCEL</a-button>
<a-button type="primary" @click="downLoadFile(1)" :loading="downLoadLoading">PDF</a-button>
<a-button type="primary" @click="downLoadFile(3)" :loading="downLoadLoading">PDF</a-button>
</template>
</template>
</a-modal>
@ -511,7 +515,8 @@ import {
BookingOrderOcrGetText,
BookingOrderPrintTemplateList,
DownloadBookingOrClosingEDI,
DeleteLetterYard
DeleteLetterYard,
LetterYardPdf
} from '@/api/modular/main/BookingLedger'
export default {
@ -601,7 +606,8 @@ export default {
BCvData: [],
Rdata: '',
scale: '1.5',
PrintType: '1'
PrintType: '1',
downLoadLoading: false
}
},
mounted() {
@ -1216,6 +1222,31 @@ export default {
},
addChild() {
this.$emit('addSedList')
},
downLoadFile(type) {
this.downLoadLoading = true
LetterYardPdf({
bookingId: this.id,
type: type
})
.then(res => {
this.downLoadLoading = false
this.pdfUrl = window.URL.createObjectURL(new Blob([res], { type: 'application/pdf;charset=utf-8' }))
const fname = '放舱打印' //
const link = document.createElement('a')
link.href = this.pdfUrl
link.setAttribute('download', fname)
document.body.appendChild(link)
link.click()
if (res.message) {
this.$message.error(res.message)
}
})
.catch(() => {
this.downLoadLoading = false
this.$message.destroy()
this.$message.success({ content: '下载失败' })
})
}
}
}

Loading…
Cancel
Save