fix: align admin behavior and Kratos integrations

This commit is contained in:
2026-08-14 14:14:51 +08:00
parent 8c4c6ba661
commit e0b0e1d8c8
123 changed files with 4334 additions and 1877 deletions
+8 -2
View File
@@ -77,7 +77,7 @@ func (h *Parameter) Find(c *gin.Context) {
httpx.Fail(c, "查询失败")
return
}
httpx.Write(c, httpx.CodeSuccess, gin.H{"resysParams": item}, "查询成功")
httpx.Write(c, httpx.CodeSuccess, item, "查询成功")
}
func (h *Parameter) Get(c *gin.Context) {
@@ -91,7 +91,13 @@ func (h *Parameter) Get(c *gin.Context) {
func (h *Parameter) List(c *gin.Context) {
p, size := page(c)
items, total, err := h.service.ParametersFilter(c.Request.Context(), p, size, c.Query("name"), c.Query("key"))
start, startErr := parseTime(c.Query("startCreatedAt"))
end, endErr := parseTime(c.Query("endCreatedAt"))
if startErr != nil || endErr != nil {
httpx.Fail(c, "参数错误")
return
}
items, total, err := h.service.ParametersFilter(c.Request.Context(), p, size, c.Query("name"), c.Query("key"), start, end)
if err != nil {
httpx.Fail(c, "获取失败")
return