|
@@ -41,7 +41,7 @@ router.beforeEach(async(to, from, next) => {
|
|
|
// set page title
|
|
|
|
|
|
try {
|
|
|
- // throw Error('测试')
|
|
|
+ throw Error('测试')
|
|
|
const response = await ajax.get('https://cxcy.ssti.net.cn/sso/api');
|
|
|
console.log(response);
|
|
|
let data = response.data.replaceAll("\'", "\"")
|
|
@@ -72,17 +72,17 @@ router.beforeEach(async(to, from, next) => {
|
|
|
}
|
|
|
} catch {
|
|
|
// setToken('2021400203')//yym
|
|
|
- // setToken("201901766");//qgt
|
|
|
+ setToken("1270"); //qgt
|
|
|
|
|
|
- // userLogin((isLogin)=>{
|
|
|
- // getSystemState(to,()=>{
|
|
|
- // if(!isLogin&&to.name!='resultShowDetail'){
|
|
|
- // store.commit('getPlanEndProjectData');
|
|
|
- // }
|
|
|
- // next()
|
|
|
- // })
|
|
|
- // });
|
|
|
- window.location.href = "https://cxcy.ssti.net.cn/sso/caslogin.jsp";
|
|
|
+ userLogin((isLogin) => {
|
|
|
+ getSystemState(to, () => {
|
|
|
+ if (!isLogin && to.name != 'resultShowDetail') {
|
|
|
+ store.commit('getPlanEndProjectData');
|
|
|
+ }
|
|
|
+ next()
|
|
|
+ })
|
|
|
+ });
|
|
|
+ // window.location.href = "https://cxcy.ssti.net.cn/sso/caslogin.jsp";
|
|
|
}
|
|
|
// determine whether the user has logged in
|
|
|
|