This commit is contained in:
@@ -105,13 +105,23 @@ export default {
|
||||
/////////////////////////////////////
|
||||
// Display LT message with wait for ok
|
||||
//
|
||||
// displayLTErrorMessage(tKeyText, tKeyTitle = undefined) {
|
||||
// return VM_LOCAL.$root.$gzconfirm({
|
||||
// message: tKeyText ? window.$gz.translation.get(tKeyText) : "",
|
||||
// title: tKeyTitle ? window.$gz.translation.get(tKeyTitle) : "",
|
||||
// yesButtonText: window.$gz.translation.get("OK"),
|
||||
// type: "error"
|
||||
// });
|
||||
// },
|
||||
displayLTErrorMessage(tKeyText, tKeyTitle = undefined) {
|
||||
return VM_LOCAL.$root.$gzconfirm({
|
||||
message: tKeyText ? window.$gz.translation.get(tKeyText) : "",
|
||||
title: tKeyTitle ? window.$gz.translation.get(tKeyTitle) : "",
|
||||
yesButtonText: window.$gz.translation.get("OK")
|
||||
yesButtonText: window.$gz.translation.get("OK"),
|
||||
type: "error"
|
||||
});
|
||||
}, /////////////////////////////////////
|
||||
},
|
||||
/////////////////////////////////////
|
||||
// Custom confirmation
|
||||
//
|
||||
confirmGeneric(tKey) {
|
||||
|
||||
@@ -263,12 +263,11 @@ export default {
|
||||
//Not found?
|
||||
if (res.error.code == "2010") {
|
||||
//notify not found error then navigate backwards
|
||||
window.$gz.dialog
|
||||
.displayLTErrorMessage("ErrorAPI2010")
|
||||
.then(() => {
|
||||
// navigate backwards
|
||||
vm.$router.go(-1);
|
||||
});
|
||||
window.$gz.eventBus.$emit("notify-error", vm.t("ErrorAPI2010"));
|
||||
// navigate backwards
|
||||
window.$gz._.delay(function() {
|
||||
vm.$router.go(-1);
|
||||
}, 2000);
|
||||
}
|
||||
vm.formState.serverError = res.error;
|
||||
window.$gz.form.setErrorBoxErrors(vm);
|
||||
|
||||
@@ -408,12 +408,11 @@ export default {
|
||||
//Not found?
|
||||
if (res.error.code == "2010") {
|
||||
//notify not found error then navigate backwards
|
||||
window.$gz.dialog
|
||||
.displayLTErrorMessage("ErrorAPI2010")
|
||||
.then(() => {
|
||||
// navigate backwards
|
||||
vm.$router.go(-1);
|
||||
});
|
||||
window.$gz.eventBus.$emit("notify-error", vm.t("ErrorAPI2010"));
|
||||
// navigate backwards
|
||||
window.$gz._.delay(function() {
|
||||
vm.$router.go(-1);
|
||||
}, 2000);
|
||||
}
|
||||
vm.formState.serverError = res.error;
|
||||
window.$gz.form.setErrorBoxErrors(vm);
|
||||
|
||||
Reference in New Issue
Block a user