fix(测试计划): 修复测试计划报告无痕浏览器打开重定向登录页面

This commit is contained in:
xinxin.wu 2024-06-20 09:55:08 +08:00 committed by Craftsman
parent e12eb97757
commit 3cf65b590b
3 changed files with 13 additions and 3 deletions

View File

@ -81,7 +81,10 @@
}
const { height } = useWindowSize();
appStore.innerHeight = height.value;
userStore.initLocalConfig(); //
if (userStore.id) {
userStore.initLocalConfig(); //
}
// @desc: TODO便
appStore.getProjectInfos();
});

View File

@ -302,6 +302,9 @@
onBeforeMount(async () => {
try {
loading.value = true;
if (!userStore.id) {
return;
}
const res = await getLocalConfig();
if (Array.isArray(res)) {
res.forEach((config) => {

View File

@ -114,7 +114,9 @@ const useUserStore = defineStore('user', {
appStore.setCurrentOrgId(res.lastOrganizationId || '');
appStore.setCurrentProjectId(res.lastProjectId || '');
this.setInfo(res);
this.initLocalConfig(); // 获取本地执行配置
if (res) {
this.initLocalConfig(); // 获取本地执行配置
}
} catch (err) {
clearToken();
throw err;
@ -129,7 +131,9 @@ const useUserStore = defineStore('user', {
appStore.setCurrentOrgId(res.lastOrganizationId || '');
appStore.setCurrentProjectId(res.lastProjectId || '');
this.setInfo(res);
this.initLocalConfig(); // 获取本地执行配置
if (res) {
this.initLocalConfig(); // 获取本地执行配置
}
} catch (err) {
clearToken();
throw err;