This commit is contained in:
@@ -113,7 +113,21 @@ export default {
|
|||||||
type: "error"
|
type: "error"
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
/////////////////////////////////////
|
||||||
|
// Display LT message with wait for ok
|
||||||
|
//
|
||||||
|
displayLTModalNotificationMessage(
|
||||||
|
tKeyText,
|
||||||
|
tKeyTitle = undefined,
|
||||||
|
ttype = "info"
|
||||||
|
) {
|
||||||
|
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: ttype
|
||||||
|
});
|
||||||
|
},
|
||||||
/////////////////////////////////////
|
/////////////////////////////////////
|
||||||
// Custom confirmation
|
// Custom confirmation
|
||||||
//
|
//
|
||||||
|
|||||||
@@ -293,8 +293,21 @@ export default {
|
|||||||
if (r.startsWith("E1")) {
|
if (r.startsWith("E1")) {
|
||||||
throw r;
|
throw r;
|
||||||
}
|
}
|
||||||
//this should be the only place hit if everything goes well and key was fetched
|
//If here, there is no technical error
|
||||||
window.$gz.eventBus.$emit("notify-success", r);
|
//key might not exist or be not found but no error so r contains the deets
|
||||||
|
|
||||||
|
if (r == "ok") {
|
||||||
|
//all ok, new key installed time to logout and back in
|
||||||
|
await window.$gz.dialog.displayLTModalNotificationMessage(
|
||||||
|
vm.$ay.t("NewLicenseInstalled")
|
||||||
|
);
|
||||||
|
vm.$router.push("/login");
|
||||||
|
} else {
|
||||||
|
if (r == "notfound") {
|
||||||
|
r = vm.$ay.t("NewLicenseNotFound");
|
||||||
|
}
|
||||||
|
window.$gz.eventBus.$emit("notify-info", r);
|
||||||
|
}
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
window.$gz.errorHandler.handleFormError(error, vm);
|
window.$gz.errorHandler.handleFormError(error, vm);
|
||||||
}
|
}
|
||||||
@@ -407,7 +420,9 @@ function fetchTranslatedText(vm) {
|
|||||||
"LicenseEmail",
|
"LicenseEmail",
|
||||||
"RequestEvaluationLicense",
|
"RequestEvaluationLicense",
|
||||||
"LicenseEmailVerficationHint",
|
"LicenseEmailVerficationHint",
|
||||||
"AdminEraseDatabaseWarning" //preexisting
|
"AdminEraseDatabaseWarning", //preexisting
|
||||||
|
"NewLicenseInstalled",
|
||||||
|
"NewLicenseNotFound"
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user