when an error happenes to editProfil Modal will also be closed then

This commit is contained in:
SimonGschnell
2024-09-12 11:53:13 +02:00
parent 1de8c00990
commit 1208c6829c
3 changed files with 11 additions and 3 deletions
@@ -104,6 +104,10 @@ export default {
})
.catch((err) => {
console.error(err);
this.loading = false;
this.setLoading(false);
this.result = false;
this.hide();
})
: this.$fhcApi.factory.profilUpdate.insertProfilRequest(
this.topic,
@@ -115,6 +119,10 @@ export default {
})
.catch((err) => {
console.error(err);
this.loading = false;
this.setLoading(false);
this.result = false;
this.hide();
});
}
},
@@ -94,10 +94,10 @@ export default {
item.data.delete = true;
this.$emit("update:profilUpdate", item.data);
//? updates the topic when a Kontakt or an Address should be deleted
this.topic = this.profilUpdateTopic["Private Adressen"]
this.modal_topic = this.profilUpdateTopic["Private Adressen"]
? this.profilUpdateTopic["Delete Adresse"]
: this.profilUpdateTopic["Delete Kontakt"];
this.$emit("update:topic", this.topic);
this.$emit("update:topic", this.modal_topic);
this.$emit("submit");
},