refs #5858 feat: add catch when patch FormModel
gitea/salix-front/pipeline/head This commit looks good
Details
gitea/salix-front/pipeline/head This commit looks good
Details
This commit is contained in:
parent
222a970a26
commit
701f1e100f
|
@ -80,7 +80,13 @@ async function save() {
|
|||
});
|
||||
}
|
||||
isLoading.value = true;
|
||||
await axios.patch($props.urlUpdate || $props.url, formData.value);
|
||||
try {
|
||||
await axios.patch($props.urlUpdate || $props.url, formData.value);
|
||||
} catch (err) {
|
||||
if (err) {
|
||||
isLoading.value = false;
|
||||
}
|
||||
}
|
||||
|
||||
originalData.value = JSON.parse(JSON.stringify(formData.value));
|
||||
hasChanges.value = false;
|
||||
|
|
Loading…
Reference in New Issue