取消游客模式,强制登录后使用

This commit is contained in:
2026-07-04 09:48:00 +08:00
parent 24630654a2
commit 323f50bfc0
10 changed files with 34 additions and 53 deletions
-7
View File
@@ -153,13 +153,6 @@ func (h *AuthHandler) Logout(c *gin.Context) {
c.JSON(http.StatusOK, gin.H{"message": "登出成功"})
}
func (h *AuthHandler) PublicInfo(c *gin.Context) {
c.JSON(http.StatusOK, gin.H{
"message": "欢迎访问 A股工具公开信息",
"guest_allowed": true,
})
}
func hashPassword(password string) (string, error) {
bytes, err := bcrypt.GenerateFromPassword([]byte(password), bcrypt.DefaultCost)
return string(bytes), err