This commit is contained in:
2018-11-14 18:19:59 +00:00
parent e4991bdade
commit 06312793a9
7 changed files with 31 additions and 19 deletions

View File

@@ -1,7 +1,6 @@
/* xeslint-disable */
import store from "../store";
import config from "../utils/config";
import api from "./apiutil";
import apiUtil from "./apiutil";
import _ from "../utils/libs/core.min.js";
export default {
@@ -24,14 +23,14 @@ export default {
resolve();
return;
}
fetch(config.apiUrl + "locale/subset", {
fetch(apiUtil.APIUrl + "locale/subset", {
method: "post",
mode: "cors",
headers: api.AuthorizedHeaders(),
headers: apiUtil.AuthorizedHeaders(),
body: JSON.stringify(NeedIt)
})
.then(api.status)
.then(api.json)
.then(apiUtil.status)
.then(apiUtil.json)
.then(response => {
_.forEach(response.data, function(item) {
store.commit("addLocaleText", item);