|
|
@@ -683,10 +683,23 @@ export default {
|
|
|
fileSelected(list) {
|
|
|
if (!list) return;
|
|
|
let tempArry = [];
|
|
|
+ let fileNameList=[]
|
|
|
+ let addFileNameList=[]
|
|
|
+ this.form.fileList.forEach(x => {
|
|
|
+ let fileObj= JSON.parse(x);
|
|
|
+ fileNameList.push(fileObj.name);
|
|
|
+ })
|
|
|
list.forEach(x => {
|
|
|
- tempArry = tempArry.concat(x.fileList);
|
|
|
+ tempArry.forEach(s => {
|
|
|
+ addFileNameList.push(JSON.parse(s).name);
|
|
|
+ })
|
|
|
+ x.fileList.forEach(y => {
|
|
|
+ let fileObj= JSON.parse(y);
|
|
|
+ if (fileNameList.indexOf(fileObj.name) == -1&&addFileNameList.indexOf(fileObj.name) == -1) {
|
|
|
+ tempArry.push(y);
|
|
|
+ }
|
|
|
+ })
|
|
|
})
|
|
|
- console.log("tempArry", tempArry, this.form.fileList);
|
|
|
if (this.form.fileList) {
|
|
|
this.formFileListDefualtValue = this.form.fileList.concat(tempArry);
|
|
|
} else {
|