fix: 换电脑登录已授权账号仍提示未授权
- 后端 _account_license_ok: 账号持有有效卡或绑定过任一已授权机器即视为账号已授权, 所有登录设备继承授权(覆盖卡激活在设备未关联账号场景) - 前端 LicenseGate: 登录/登出后重查授权(it-tools-auth-changed), 不再停留首次缓存的未授权态 - CHANGELOG记录 验证: 新机器登录 auth-status=true 受控工具放行; 无关机器仍未授权
This commit is contained in:
1 parent
8124e88a53
commit
4efc442977
3 files changed
+29
-4
No files matched your search
@@ -109,6 +109,12 @@ onMounted(() => {
|
||||
timer = setInterval(() => {
|
||||
now.value = Date.now();
|
||||
}, 1000);
|
||||
// 登录/登出后重新检查授权:换电脑登录已授权账号后,立即解除未授权提示
|
||||
window.addEventListener('it-tools-auth-changed', init);
|
||||
});
|
||||
|
||||
onBeforeUnmount(() => {
|
||||
window.removeEventListener('it-tools-auth-changed', init);
|
||||
});
|
||||
|
||||
// 跨工具路由复用:路径变化时重新走授权检查
|
||||
|
||||
Reference in new issue
Block a user