mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
ui: update pid display
This commit is contained in:
1 parent
a6f48233d1
commit
f4127a806a
4 files changed
+11
-6
No files matched your search
@@ -8,7 +8,7 @@ contest_detail: Contest Detail
|
|||||||
contest_edit: Contest Edit
|
contest_edit: Contest Edit
|
||||||
contest_files: Contest Files
|
contest_files: Contest Files
|
||||||
contest_main: Contest
|
contest_main: Contest
|
||||||
contest_problemlist: Proble List
|
contest_problemlist: Problem List
|
||||||
contest_scoreboard: Scoreboard
|
contest_scoreboard: Scoreboard
|
||||||
discussion_create: Create Discussion
|
discussion_create: Create Discussion
|
||||||
discussion_detail: Discussion Detail
|
discussion_detail: Discussion Detail
|
||||||
|
|||||||
@@ -252,8 +252,9 @@ export class ContestProblemListHandler extends ContestDetailBaseHandler {
|
|||||||
if (contest.canShowSelfRecord.call(this, this.tdoc)) {
|
if (contest.canShowSelfRecord.call(this, this.tdoc)) {
|
||||||
[this.response.body.rdict, this.response.body.rdocs] = await Promise.all([
|
[this.response.body.rdict, this.response.body.rdocs] = await Promise.all([
|
||||||
record.getList(domainId, psdocs.map((i: any) => i.rid)),
|
record.getList(domainId, psdocs.map((i: any) => i.rid)),
|
||||||
await record.getMulti(domainId, { tid, uid: this.user._id }).toArray(),
|
await record.getMulti(domainId, { tid, uid: this.user._id }).sort({ _id: -1 }).toArray(),
|
||||||
]);
|
]);
|
||||||
|
this.response.body.canViewRecord = true;
|
||||||
} else {
|
} else {
|
||||||
for (const i of psdocs) this.response.body.rdict[i.rid] = { _id: i.rid };
|
for (const i of psdocs) this.response.body.rdict[i.rid] = { _id: i.rid };
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -46,7 +46,9 @@
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
<td class="col--problem col--problem-name">
|
<td class="col--problem col--problem-name">
|
||||||
{{ problem.render_problem_title(pdict[pid], tdoc=tdoc, show_invisible_flag=false, show_tags=false) }}
|
<a href="{{ url('problem_detail', pid=pid, query={tid:tdoc.docId}) }}">
|
||||||
|
<b>{{ String.fromCharCode(65+loop.index0) }}</b> {{ pdict[pid].title }}
|
||||||
|
</a>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
{%- endfor -%}
|
{%- endfor -%}
|
||||||
@@ -56,8 +58,10 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="section">
|
<div class="section">
|
||||||
<div class="section__body no-padding">
|
<div class="section__body no-padding">
|
||||||
{% if not rdocs.length %}
|
{% if not canViewRecord %}
|
||||||
{{ nothing.render('Oh, there is no task in the queue!') }}
|
{{ nothing.render('According to the contest rules, you cannot view your submission details at current.') }}'
|
||||||
|
{% elif not rdocs.length %}
|
||||||
|
{{ nothing.render('Oh, there is no submission!') }}
|
||||||
{% else %}
|
{% else %}
|
||||||
<table class="data-table record_main__table">
|
<table class="data-table record_main__table">
|
||||||
<colgroup>
|
<colgroup>
|
||||||
|
|||||||
@@ -44,7 +44,7 @@
|
|||||||
</button>
|
</button>
|
||||||
</form>
|
</form>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
#{{ pdoc.pid|default(pdoc.docId) }}. {{ pdoc.title }}
|
#{{ String.fromCharCode(65+tdoc.pids.indexOf(pdoc.docId)) if tdoc else pdoc.pid|default(pdoc.docId) }}. {{ pdoc.title }}
|
||||||
</h1>
|
</h1>
|
||||||
{% if tdoc %}
|
{% if tdoc %}
|
||||||
<div class="section__tools contest-problems">
|
<div class="section__tools contest-problems">
|
||||||
|
|||||||
Reference in new issue
Block a user