This commit is contained in:
2019-04-26 21:02:04 +00:00
parent 1565c4c94b
commit aa3751be35
6 changed files with 67 additions and 209 deletions

View File

@@ -12,6 +12,9 @@ export default {
return store.state.localeText[key];
},
fetch(keys) {
/* eslint-disable-next-line */
console.log("LOCALE - TOP OF FETCH(KEYS)");
return new Promise(function fetchLocaleKeysFromServer(resolve) {
//, reject
//step 1: build an array of keys that we don't have already
@@ -36,6 +39,10 @@ export default {
_.forEach(response.data, function commitFetchedLTItemToStore(item) {
store.commit("addLocaleText", item);
});
/* eslint-disable-next-line */
console.log(
"LOCALE - DONE FETCH(KEYS) and stored about to call Resolve()..."
);
resolve();
});