- 流程图评到 A 或 S,记进所有已加入、且包含这道题的题单(和判题那一路同一个口径,不看从哪个 入口交的),徽章和题单类成就照样推送。原来题单进度只在判代码时记,流程图作业在题单里永远是 「没做」。流程图提交的 id 进不了 problemset_submission(外键指向代码提交表),所以只写 progress_detail —— 解锁旧提交的那道闸看的也是它 - 课堂条(/me/class-activity)的 myStatus:流程图 A / S 也算 accepted,评完的非 A/S 算 tried - 题单防抄闸门补到流程图上:加入题单之前画的图,对本人藏起来(列表 showLink、详情 404、 current / history 不数它),规则和代码提交同一份(problemSetJoinTimes 挪进 services/problemset)。 原来加入之前画到 A 的那张图点一下就能载回画布、交上去就是 A - 新增 GET /problems/:id/flowchart/scores:一次给出自己评完的每一次的分数和等级,外加被藏起来 的次数(原来 history 一次只给一条,看分数走势得一页一页翻) - 「A/S 算过关」和按分数定等级收进 flowchart/grade.ts;判题那边的记账 + 通知抽成 recordSolvedAndNotify,两条路共用 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
948e9a734d
commit
3fe3caa944
8 files changed
+280
-145
No files matched your search
@@ -73,6 +73,19 @@ export const flowchartDetailSchema = z.object({
|
||||
count: z.number().int(),
|
||||
})
|
||||
|
||||
/** 自己在一道题上评完的历次分数,早的在前;hidden = 被题单闸门藏起来的次数 */
|
||||
export const flowchartScoresSchema = z.object({
|
||||
scores: z.array(
|
||||
z.object({
|
||||
id: z.string(),
|
||||
score: z.number(),
|
||||
grade: z.string(),
|
||||
createTime: z.string(),
|
||||
}),
|
||||
),
|
||||
hidden: z.number().int(),
|
||||
})
|
||||
|
||||
export const flowchartStatisticsSchema = z.object({
|
||||
totalCount: z.number().int(),
|
||||
avgScore: z.number(),
|
||||
@@ -107,6 +120,7 @@ export type FlowchartListItem = z.infer<typeof flowchartListItemSchema>
|
||||
export type FlowchartList = z.infer<typeof flowchartListSchema>
|
||||
export type FlowchartCurrent = z.infer<typeof flowchartCurrentSchema>
|
||||
export type FlowchartDetail = z.infer<typeof flowchartDetailSchema>
|
||||
export type FlowchartScores = z.infer<typeof flowchartScoresSchema>
|
||||
export type CreateFlowchartResponse = z.infer<typeof createFlowchartResponseSchema>
|
||||
export type CreateFlowchartRequest = z.infer<typeof createFlowchartRequestSchema>
|
||||
|
||||
|
||||
Reference in new issue
Block a user