changes
This commit is contained in:
@@ -603,13 +603,6 @@ export default defineNuxtPlugin(() => {
|
||||
url_detail: "data-detail/Menu_Choice/",
|
||||
params: {},
|
||||
},
|
||||
{
|
||||
name: "moneyunit",
|
||||
commit: "moneyunit",
|
||||
url: "data/Money_Unit/",
|
||||
url_detail: "data-detail/Money_Unit/",
|
||||
params: {},
|
||||
},
|
||||
{
|
||||
name: "legaltype",
|
||||
commit: "legaltype",
|
||||
@@ -847,6 +840,7 @@ export default defineNuxtPlugin(() => {
|
||||
store.commit("login", undefined);
|
||||
store.commit("layersetting", undefined);
|
||||
store.commit("lastlegendfiltertab", "Giỏ hàng");
|
||||
console.log('requestLogin: redirect to login')
|
||||
window.location.href = `https://${mode === "dev" ? "dev." : ""}login.utopia.com.vn/signin?module=${module}&link=${window.location.origin}`;
|
||||
};
|
||||
|
||||
@@ -876,6 +870,7 @@ export default defineNuxtPlugin(() => {
|
||||
|
||||
// get data
|
||||
const getapi = async function (list) {
|
||||
console.trace('getapi')
|
||||
try {
|
||||
let arr = list.map((v) => {
|
||||
let found = apis.find((api) => api.name === v.name);
|
||||
@@ -898,7 +893,7 @@ export default defineNuxtPlugin(() => {
|
||||
});
|
||||
return list;
|
||||
} catch (err) {
|
||||
console.log(err);
|
||||
console.error(err);
|
||||
return "error";
|
||||
}
|
||||
};
|
||||
|
||||
@@ -2,7 +2,7 @@ export default defineNuxtPlugin(async (nuxtApp) => {
|
||||
const { $getapi, $readyapi } = useNuxtApp()
|
||||
let connlist = $readyapi(['moneyunit', 'datatype', 'filterchoice', 'colorchoice', 'textalign', 'placement', 'colorscheme',
|
||||
'filtertype', 'sorttype', 'tablesetting', 'settingchoice', 'sharechoice', 'menuchoice', 'settingtype', 'settingclass',
|
||||
'common', 'sex', 'legaltype', 'cart'])
|
||||
'sex', 'legaltype', 'cart'])
|
||||
let filter = connlist.filter(v=>!v.ready)
|
||||
if(filter.length>0) await $getapi(filter)
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user