feat: 添加SignalR登录状态管理功能
- 在Program.cs中注册LoginHub - 在HomeController中传递用户ID以支持SignalR连接 - 在Index.cshtml中实现SignalR连接和心跳机制,处理强制登出和注册成功事件 - 移除旧的登录状态检查逻辑,优化页面加载时的连接管理
This commit is contained in:
1 parent
0e5d0247bf
commit
c38199268f
9 files changed
+242
-49
No files matched your search
@@ -75,7 +75,7 @@
|
||||
margin-bottom: 1%;
|
||||
">© 2022 华恒工程技术中心有限公司</p>*@
|
||||
</div>
|
||||
<script>
|
||||
@* <script>
|
||||
var loginData = [];
|
||||
$.post('/Home/BeforeLogin/',{},function (data){
|
||||
loginData = data.Data;
|
||||
@@ -101,7 +101,7 @@
|
||||
})
|
||||
|
||||
return issigned;
|
||||
}
|
||||
} *@
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
Reference in new issue
Block a user