vuex模块化 登录,oauth,agentSign模块

This commit is contained in:
aixianling
2022-06-13 17:21:40 +08:00
parent 0b157621ca
commit 4520a74627
4 changed files with 144 additions and 153 deletions

View File

@@ -34,20 +34,9 @@ const app = new Vue({
store,
...App
});
app.$mount();
store.dispatch("agentSign").then(config => {
const init = (c = 0) => {
if (config) {
store.commit("getConfig", {...config, latlng: [config.lat, config.lng]})
// app.$mount();
} else {
if (c < 5) {
setTimeout(() => {
init(++c)
}, 300)
}
}
}
init()
})
let params = {}
if (sessionStorage.getItem("prj")?.indexOf("saas") > -1) {
params = {action: "/app/wxcptp/portal/agentSign", corpId: "ww596787bb70f08288"}
}
store.dispatch("agentSign", params).finally(() => app.$mount())