ocr修改
This commit is contained in:
@@ -26,7 +26,7 @@
|
||||
import { ACCESS_TOKEN } from "@/store/mutation-types"
|
||||
export default {
|
||||
name: 'ocrUpload',
|
||||
props:['disableds','disabled','thisFileUploadUrl','readonly','thisFileType','accept','title','listType'],
|
||||
props:['disableds','disabled','thisFileUploadUrl','readonly','thisFileType','accept','listType'],
|
||||
data(){
|
||||
return{
|
||||
visible:false,
|
||||
@@ -36,12 +36,14 @@
|
||||
fileList:[],
|
||||
fileTypeSatus:false,
|
||||
headers:{},
|
||||
title:this.$t('UploadFile'),
|
||||
}
|
||||
},
|
||||
created(){
|
||||
const token = Vue.ls.get(ACCESS_TOKEN);
|
||||
this.headers = {"X-Access-Token":token};
|
||||
this.containerId = 'container-ty-'+new Date().getTime();
|
||||
// console.log('title',this.title)
|
||||
},
|
||||
mounted(){
|
||||
// console.log(this.thisFileType,this.thisFileSize,this.thisFileUploadUrl);
|
||||
@@ -115,6 +117,7 @@
|
||||
})
|
||||
// console.log('file1111',this.fileList)
|
||||
this.$emit('uploadSuccess', this.fileList)
|
||||
|
||||
this.$message.destroy()
|
||||
this.$message.error('最多只能上传一个文件');
|
||||
return
|
||||
@@ -131,6 +134,7 @@
|
||||
|
||||
if(this.myfileList.length > 0){
|
||||
this.$emit('uploadSuccess', this.fileList)
|
||||
// console.log('fileList111',this.fileList)
|
||||
this.$message.destroy()
|
||||
this.$message.success(`${info.file.name} 文件上传成功。`);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user