up
This commit is contained in:
@@ -30,3 +30,15 @@
|
||||
### 注意事项
|
||||
- GORM AutoMigrate 会自动添加新字段
|
||||
- 前端颜色选择与日程类型联动
|
||||
|
||||
## 修复:calendar/events jsonErr
|
||||
|
||||
**问题**:`fromGetCalendarEvents` 的 `start/end` 是 `*time.Time` 类型,无法直接解析字符串格式的日期。
|
||||
|
||||
**修复**:改为直接用类型断言解析字符串,用 `time.Parse("2006-01-02", ...)` 解析。
|
||||
|
||||
## 优化:BgColor 弃用,前端根据 ScheduleType 渲染颜色
|
||||
|
||||
**前端**:添加 `getColorByScheduleType()` 函数,`getEvents` 中使用 scheduleType 映射颜色。
|
||||
|
||||
**后端**:只存储 ScheduleType,不处理颜色逻辑。颜色完全由前端 `colorOptions` 控制。
|
||||
|
||||
Reference in New Issue
Block a user