rating when ai is steaming

This commit is contained in:
xuyue committed 2026-06-11 19:53:15 -06:00
1 parent 05ecf6bebf
commit a15b3d9c76
4 files changed
+156

No files matched your search

+8
View File
@@ -20,6 +20,7 @@ import type {
ShowcaseSubmissionLookupOut,
ShowcaseDetail,
PromptRound,
RandomRatingItem,
} from "./utils/type"
import { BASE_URL, STORAGE_KEY } from "./utils/const"
@@ -237,6 +238,13 @@ export const Submission = {
return res.data
},
async randomForRating(excludeId?: string) {
const res = await http.get("/submission/random-for-rating/", {
params: excludeId ? { exclude_id: excludeId } : {},
})
return res.data as RandomRatingItem | null
},
async updateFlag(id: string, flag: FlagType) {
const res = await http.put(`/submission/${id}/flag`, { flag })
return res.data