{% import "components/record.html" as record with context %}
{% import "components/user.html" as user with context %}
{% import "components/problem.html" as problem with context %}
{% set _isPretest = rdoc.contest and rdoc.contest.toString() == '000000000000000000000000' %}
{{ record.render_status_td(rdoc, allDomain = allDomain) }}
{% if handler.user.hasPerm(perm.PERM_REJUDGE) and not rdoc.files.hack and not _isPretest %}
{% endif %}
{% if pdoc and rdoc.contest %}
{{ problem.render_problem_title(pdoc, tdoc=tdoc, show_tags=false, show_invisible_flag=false) }}
{% elif pdoc and (not pdoc.hidden or handler.user.hasPerm(perm.PERM_VIEW_PROBLEM_HIDDEN) or handler.user.own(pdoc)) %}
{{ problem.render_problem_title(pdoc, show_tags=false) }}
{% else %}
*
{% endif %}
{% if rdoc.files.hack %}({{ _('Hack') }}){% endif %}
{% if _isPretest %}({{ _('Pretest') }}){% endif %}