update UI
Some checks failed
Deploy / deploy (push) Has been cancelled

This commit is contained in:
2025-09-24 16:20:48 +08:00
parent de6ac4bd85
commit 0a9d49b526
7 changed files with 211 additions and 119 deletions

View File

@@ -2,10 +2,12 @@ import { DIFFICULTY } from "utils/constants"
import { getACRate } from "utils/functions"
import http from "utils/http"
import {
DetailsData,
Problem,
Submission,
SubmissionListPayload,
SubmitCodePayload,
WeeklyData,
} from "utils/types"
function filterResult(result: Problem) {
@@ -257,6 +259,12 @@ export function getAIWeeklyData(
return http.get("ai/weekly", { params: { end, duration, username } })
}
export function getAIAnalysis() {
return http.get("ai/analysis")
export function getAIAnalysis(
detailsData: DetailsData,
weeklyData: WeeklyData[],
) {
return http.post("ai/analysis", {
details: detailsData,
weekly: weeklyData,
})
}