File tree Expand file tree Collapse file tree 2 files changed +2
-5
lines changed
Expand file tree Collapse file tree 2 files changed +2
-5
lines changed Original file line number Diff line number Diff line change @@ -247,25 +247,21 @@ def render_params(self):
247247
248248 current_score = 0
249249 if best_result :
250- # ใช้ public_score เพื่อแสดงผลตามที่ผู้เข้าแข่งขันควรจะเห็น
251250 current_score = best_result .public_score if best_result .public_score is not None else 0.0
252251
253252 max_score = 100
254253 if task .active_dataset :
255254 try :
256- # score_type_object จะถูกนิยามใน Dataset Model (task.py)
257- # และมี property ชื่อ max_score อยู่
258255 max_score = task .active_dataset .score_type_object .max_score
259256 except Exception :
260- # ถ้าเกิดข้อผิดพลาดในการเข้าถึงให้ใช้ค่าเริ่มต้น 100
261257 pass
262258
263259 task_scores [task .name ] = {
264260 "score" : current_score ,
265261 "max_score" : max_score
266262 }
267263
268- # ส่ง task_scores ไปให้ template
264+ # sent score to fontend
269265 ret ["task_scores" ] = task_scores
270266 # some information about token configuration
271267 ret ["tokens_contest" ] = self .contest .token_mode
Original file line number Diff line number Diff line change 2929 background-color : hsla (120 , 100% , 50% , 0.4 );
3030}
3131
32+ /* add color in table overview */
3233.table-striped tbody > tr > th .overview-score .score_0 ,
3334.table-striped tbody > tr : nth-child (odd)> th .overview-score .score_0 {
3435 background-color : hsla (0 , 100% , 50% , 0.4 ) !important ;
You can’t perform that action at this time.
0 commit comments