story#7062,供应商培训和财务发票修改,上传发票问题查找
This commit is contained in:
@ -170,8 +170,9 @@ export default {
|
||||
let res = await this.getJumpHandler();
|
||||
if(res?.data?.jump) {
|
||||
Dialog.alert({
|
||||
message: '您有没有完成的培训,请在中道调度APP上完成培训,再进行发票上传',
|
||||
message: '您有暂未完成的培训,请在中道调度APP上完成培训,再进行发票上传',
|
||||
confirmButtonText: '去培训',
|
||||
confirmButtonColor: '#0E76F4',
|
||||
showCancelButton: false,
|
||||
}).then(async() => {
|
||||
this.goPage('newTrainingList', { supplierId : this.supplierId })
|
||||
|
||||
@ -62,7 +62,7 @@
|
||||
</div>
|
||||
<div class="upload_btn_wrap">
|
||||
<div class="btn_save" @click="createInvoiceHandler">保存</div>
|
||||
<van-uploader :before-read="beforeRead" :after-read="afterRead" accept=".png,.jpg,.jpeg,.pdf,.ofd">
|
||||
<van-uploader :before-read="beforeRead" use-before-read :after-read="afterRead" accept=".png,.jpg,.jpeg,.pdf,.ofd">
|
||||
<div class="btn_upload">
|
||||
<img class="icon_upload" src="@/assets/icon_upload.png" alt="">
|
||||
上传发票
|
||||
@ -83,6 +83,7 @@
|
||||
data(){
|
||||
return {
|
||||
list: [],
|
||||
fileObj: '',
|
||||
invoiceMoneyTotal: 0,
|
||||
tableData: [],
|
||||
activeObj: {},
|
||||
@ -235,18 +236,12 @@
|
||||
});
|
||||
},
|
||||
async beforeRead (file) {
|
||||
/*let res = await this.getJumpHandler();
|
||||
if(res?.data?.jump) {
|
||||
this.$message.warning("您有没有完成的培训,请在中道调度APP上完成培训,再进行发票上传")
|
||||
return false
|
||||
}*/
|
||||
const FileExt = file.name.replace(/.+\./, "");
|
||||
if (['jpg', 'png', 'jpeg', 'pdf', 'ofd'].indexOf(FileExt.toLowerCase()) === -1) {
|
||||
this.$toast('请上传后缀名为jpg、jpeg、png、pdf、ofd的文件!')
|
||||
return false;
|
||||
return false
|
||||
}
|
||||
this.$set(this.activeObj, 'fileType', FileExt)
|
||||
return true
|
||||
},
|
||||
async afterRead (file) {
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user