主流程

This commit is contained in:
2026-06-10 17:53:09 +08:00
parent c6f239f424
commit b20435c027
66 changed files with 2779 additions and 1181 deletions
+10 -2
View File
@@ -300,8 +300,16 @@ func (h *Handler) listSessions(w http.ResponseWriter, r *http.Request) {
writeErr(w, r, err)
return
}
all := r.URL.Query().Get("all") == "true"
list, err := h.sessSvc.List(r.Context(), c, all)
f := SessionListFilter{All: r.URL.Query().Get("all") == "true"}
if v := r.URL.Query().Get("requirement_id"); v != "" {
id, err := uuid.Parse(v)
if err != nil {
writeErr(w, r, errs.New(errs.CodeInvalidInput, "requirement_id 非法"))
return
}
f.RequirementID = &id
}
list, err := h.sessSvc.List(r.Context(), c, f)
if err != nil {
writeErr(w, r, err)
return