更新oa的数据统计

This commit is contained in:
2026-08-26 16:15:23 +08:00
parent e60cd00395
commit 20bc65b1f3
11 changed files with 1328 additions and 282 deletions
+3 -1
View File
@@ -129,6 +129,7 @@ func (c *PlatformAuthController) LoginPlatform() {
// 控制器只做 HTTP 解析与响应编排,业务逻辑放 services 层
token, loginUser, err := services.PlatformAdminLogin(req.Account, req.Password)
if err != nil {
RecordLoginLog(nil, 0, req.Account, "", "", "password", 0, err.Error(), c.Ctx.Input.IP(), c.Ctx.Request.UserAgent())
c.Data["json"] = map[string]interface{}{
"code": 401,
"msg": err.Error(),
@@ -137,6 +138,8 @@ func (c *PlatformAuthController) LoginPlatform() {
return
}
RecordLoginLog(nil, loginUser.ID, loginUser.Account, loginUser.Name, "", "password", 1, "登录成功", c.Ctx.Input.IP(), c.Ctx.Request.UserAgent())
c.Data["json"] = map[string]interface{}{
"code": 200,
"msg": "登录成功",
@@ -422,4 +425,3 @@ func (c *PlatformAuthController) SendResetCode() {
}
_ = c.ServeJSON()
}