Compare commits
2 Commits
721ce5a595
...
6781374c1e
| Author | SHA1 | Date | |
|---|---|---|---|
| 6781374c1e | |||
| 7c90f5e8af |
@@ -22,7 +22,18 @@
|
||||
"usedAt": 1776000797914,
|
||||
"industryId": "all"
|
||||
}
|
||||
],
|
||||
"44c34a14b6dc4139b39ff61239e259ea": [
|
||||
{
|
||||
"expertId": "SeniorDeveloper",
|
||||
"name": "Will",
|
||||
"profession": "高级开发工程师",
|
||||
"avatarUrl": "https://acc-1258344699.cos.accelerate.myqcloud.com/workbuddy/experts/avatars/02-Engineering/SeniorDeveloper/SeniorDeveloper.png",
|
||||
"promptUrl": "https://acc-1258344699.cos.accelerate.myqcloud.com/workbuddy/experts/experts/02-Engineering/SeniorDeveloper/SeniorDeveloper_zh.md",
|
||||
"usedAt": 1776000797914,
|
||||
"industryId": "all"
|
||||
}
|
||||
]
|
||||
},
|
||||
"lastUpdated": 1776000910040
|
||||
"lastUpdated": 1776002597201
|
||||
}
|
||||
13
.workbuddy/memory/2026-04-12.md
Normal file
13
.workbuddy/memory/2026-04-12.md
Normal file
@@ -0,0 +1,13 @@
|
||||
# 2026-04-12 工作日志
|
||||
|
||||
## 修复登录日志时间显示问题
|
||||
|
||||
**问题描述**:小程序后台登录日志中的登录时间显示不正确,实际登录时间 9:20:20,显示为 17:16:31,相差约 8 小时。
|
||||
|
||||
**问题原因**:`LoginRecord` 实体类中的 `createTime` 和 `updateTime` 字段使用了 `@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")` 注解,但没有指定 `timezone` 属性。对于 `LocalDateTime` 类型,Jackson 序列化时未正确应用全局时区配置,导致时间多了 8 小时。
|
||||
|
||||
**修复方案**:为 `@JsonFormat` 注解添加 `timezone = "GMT+8"` 属性。
|
||||
|
||||
**修改文件**:`src/main/java/com/gxwebsoft/common/system/entity/LoginRecord.java`
|
||||
|
||||
**状态**:已修复
|
||||
@@ -58,11 +58,11 @@ public class LoginRecord implements Serializable {
|
||||
private Integer tenantId;
|
||||
|
||||
@Schema(description = "操作时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@Schema(description = "修改时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@Schema(description = "用户id")
|
||||
|
||||
Reference in New Issue
Block a user