fix: 时间校准接口全局复用旧 peace/storedetail,修正活动名称
- 从 Activity 结构体移除 TimeAPIURL 字段,时间校准与活动无关, 统一用 constants.DefaultTimeAPI(peace/storedetail 能稳定返回 currentTime) - 旧活动 peace DisplayName 从"和平手册"修正为"精英手册" - 更改项目默认端口避免冲突:Vite 5173→15173,Wails dev 34115→34215
This commit is contained in:
@@ -625,7 +625,7 @@ func (a *App) SwitchActivity(id string) map[string]any {
|
||||
return map[string]any{"success": false, "error": "未知活动: " + id}
|
||||
}
|
||||
a.cfg.Activity = act.ID
|
||||
a.cfg.TimeAPIURL = act.TimeAPIURL
|
||||
a.cfg.TimeAPIURL = constants.DefaultTimeAPI
|
||||
if err := config.SaveConfig(a.paths.ConfigFile, a.cfg); err != nil {
|
||||
logger.LogEvent("活动", "error", "切换活动配置保存失败: %v", err)
|
||||
return map[string]any{"success": false, "error": "配置保存失败: " + err.Error()}
|
||||
|
||||
Reference in New Issue
Block a user