This commit is contained in:
@@ -340,7 +340,7 @@ export default {
|
||||
}
|
||||
|
||||
let isReset = toPath && toPath.includes("home-reset");
|
||||
debugger;
|
||||
|
||||
//redirect to login if not authenticated
|
||||
if (!vm.$store.state.authenticated && !isReset) {
|
||||
//If a direct open path was being used but user is not logged in this will catch it
|
||||
|
||||
@@ -79,7 +79,7 @@ export default {
|
||||
}
|
||||
return window.$gz.store.state.translationText[key];
|
||||
},
|
||||
async cacheTranslations(keys, forceTranslationId = 0) {
|
||||
async cacheTranslations(keys, forceTranslationId) {
|
||||
return new Promise(async function fetchTranslationKeysFromServer(resolve) {
|
||||
//
|
||||
//step 1: build an array of keys that we don't have already
|
||||
@@ -100,8 +100,12 @@ export default {
|
||||
|
||||
//step 2: get it
|
||||
let transData = null;
|
||||
if (forceTranslationId != 0) {
|
||||
debugger;
|
||||
|
||||
console.log(
|
||||
"translation.js::cachetranslationkeys forcetranslationid=",
|
||||
forceTranslationId
|
||||
);
|
||||
if (forceTranslationId) {
|
||||
transData = await window.$gz.api.upsert(
|
||||
`translation/subset/${forceTranslationId}`,
|
||||
needIt
|
||||
|
||||
@@ -50,7 +50,6 @@
|
||||
/* Xeslint-disable */
|
||||
export default {
|
||||
async created() {
|
||||
debugger;
|
||||
let searchParams = new URLSearchParams(window.location.search);
|
||||
//home-reset?rc={ResetCode}&tr={EffectiveTranslationId}&lg={loginName}
|
||||
this.obj.passwordResetCode = searchParams.get("rc");
|
||||
@@ -136,7 +135,6 @@ async function initForm(vm) {
|
||||
// Ensures UI translated text is available
|
||||
//
|
||||
async function fetchTranslatedText(vm) {
|
||||
debugger;
|
||||
await window.$gz.translation.cacheTranslations(
|
||||
[
|
||||
"NewPassword",
|
||||
@@ -145,7 +143,7 @@ async function fetchTranslatedText(vm) {
|
||||
"ErrorRequiredFieldEmpty",
|
||||
"ErrorNoMatch"
|
||||
],
|
||||
vm.translationId
|
||||
vm.obj.translationId
|
||||
);
|
||||
}
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user