优化文件上传 未发布版本

master
lion 8 months ago
parent 97636e6984
commit e2ae92ee7f

@ -46,7 +46,7 @@
<u-upload @on-remove="(index, lists, name)=>{onRemove(index, lists, name,item)}"
@on-success="(data, index, lists, name)=>{onSuccess(data, index, lists, name,item)}"
@on-uploaded="(lists, name)=>{onUploaded(lists, name,item)}" :form-data="formData"
:action="action" :show-progress="false" :file-list="item.fileListArr"
:action="action" :show-progress="true" :file-list="item.fileListArr"
max-count="9"></u-upload>
</block>
</u-form-item>
@ -308,7 +308,6 @@
// item.value b
const exists = _arr.includes(item1.value);
// checked
console.log("exists", exists)
item1.checked = exists;
});
}

@ -75,16 +75,20 @@
this.sign_id = res.detail.id
if (res.detail.data && res.detail.data.length > 0) {
res.detail.data.map(item => {
this.course_forms.map(forms=>{
this.course_forms.map((forms,index)=>{
if(item.field==forms.field){
forms.value = item.value?item.value:''
if(forms.edit_input==='files'){
this.$set(forms,'fileListArr',item.fileListArr?item.fileListArr:[])
this.$set(forms,'fileList',item.fileList?item.fileList:[])
}
}
})
// if (item.value === null) {
// item.value = ''
// }
})
console.log("this.course_forms",this.course_forms)
// this.course_forms = res.detail.data.sort((a, b) => (a.sort - b.sort))
}
},
@ -196,7 +200,6 @@
}, 1500)
})
}
}).catch(err => {
console.log("err", err)
that.isLocked = false
@ -204,6 +207,8 @@
},
//
async updateApplyCourse() {
// console.log("this.apply_form",this.apply_form)
// return
let that = this
this.$u.api.courseUpdateSign({
id: this.sign_id,

Loading…
Cancel
Save