|
@@ -93,21 +93,23 @@ export default {
|
|
|
handleChange (file, filelist,type) {
|
|
handleChange (file, filelist,type) {
|
|
|
this.file = file
|
|
this.file = file
|
|
|
this.filelist = filelist
|
|
this.filelist = filelist
|
|
|
- console.log(this.filelist,'FILE4444')
|
|
|
|
|
|
|
+
|
|
|
if (type != '附件'){
|
|
if (type != '附件'){
|
|
|
this.$emit('upload')
|
|
this.$emit('upload')
|
|
|
}
|
|
}
|
|
|
var index = file.raw.name.lastIndexOf(".");
|
|
var index = file.raw.name.lastIndexOf(".");
|
|
|
- var ext = file.name.substr(index + 1);
|
|
|
|
|
|
|
+ var ext = file.name.substr(index + 1) === 'PDF' ? 'pdf' : file.name.substr(index + 1);
|
|
|
|
|
+
|
|
|
this.params.content.filename = file.raw.name
|
|
this.params.content.filename = file.raw.name
|
|
|
this.params.content.filetype = ext
|
|
this.params.content.filetype = ext
|
|
|
this.getUploadUrl(file, ext,type)
|
|
this.getUploadUrl(file, ext,type)
|
|
|
},
|
|
},
|
|
|
toUpload (type) {
|
|
toUpload (type) {
|
|
|
- console.log(this.fileListNew)
|
|
|
|
|
|
|
+
|
|
|
this.fileListNew.forEach(file=>{
|
|
this.fileListNew.forEach(file=>{
|
|
|
let index = file.name.lastIndexOf(".");
|
|
let index = file.name.lastIndexOf(".");
|
|
|
- let ext = file.name.substr(index + 1);
|
|
|
|
|
|
|
+ let ext = file.name.substr(index + 1) === 'PDF' ? 'pdf' : file.name.substr(index + 1);
|
|
|
|
|
+
|
|
|
this.params.content.filename = file.name
|
|
this.params.content.filename = file.name
|
|
|
this.params.content.filetype = ext
|
|
this.params.content.filetype = ext
|
|
|
this.getUploadUrl(file, ext,type)
|
|
this.getUploadUrl(file, ext,type)
|