feat: 为应用版本查询增加appCode参数支持

新增应用版本类型的AppCode字段,修改相关接口和实现以支持通过appCode查询指定应用的最新版本,增加appCode合法性校验,完善缓存键以区分不同应用的版本信息
This commit is contained in:
Austin
2026-10-12 14:59:23 +08:00
parent 0a33d21eb8
commit 6be7796049
4 changed files with 32 additions and 8 deletions
+2 -1
View File
@@ -276,8 +276,9 @@ func (c *adminInternalClient) TenantLoginIPWhitelist(id types.TenantID) (*tenant
return &result, nil
}
func (c *adminInternalClient) LatestAppRelease(platform, channel string) (*types.AppRelease, error) {
func (c *adminInternalClient) LatestAppRelease(appCode, platform, channel string) (*types.AppRelease, error) {
query := url.Values{}
query.Set("app_code", strings.ToLower(strings.TrimSpace(appCode)))
query.Set("platform", strings.ToLower(strings.TrimSpace(platform)))
query.Set("channel", strings.ToLower(strings.TrimSpace(channel)))
var dto struct {