fix:图片编辑时丢失上次保存问题修正

This commit is contained in:
shijing 2026-01-12 08:50:56 +08:00
parent d3e788ffe0
commit 3c96c48d2e
1 changed files with 7 additions and 4 deletions

View File

@ -444,8 +444,13 @@ export default {
obj.path = item.path; obj.path = item.path;
files.push(obj); files.push(obj);
}) })
if(that.fileurl.length>0){
this.paramsJsonFileurl = files.concat(that.fileurl);
}else{
this.paramsJsonFileurl = files; this.paramsJsonFileurl = files;
this.params_json.fileurl = JSON.stringify(files); }
this.params_json.fileurl = JSON.stringify(this.paramsJsonFileurl);
}, },
//Ids //Ids
imagesDel(index){ imagesDel(index){
@ -482,9 +487,7 @@ export default {
} }
if(data.process_name=='排一次棒'){ if(data.process_name=='排一次棒'){
that.params_json=that.form.params_json; that.params_json=that.form.params_json;
console.log('that.params_json',that.params_json);
let fileurl = JSON.parse(that.params_json.fileurl); let fileurl = JSON.parse(that.params_json.fileurl);
console.log('fileurl',fileurl);
fileurl.forEach((item)=>{ fileurl.forEach((item)=>{
item.url = item.path; item.url = item.path;
that.fileurl.push(item); that.fileurl.push(item);