Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions webapp/templates/team/partials/clarifications_team.html.twig
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would rather reject clar requests before contest start through the API

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So instead of letting teams ask them via UI (because they can via API) disallow both via UI & API?

I think I'm fine with that, I want the jury to still be able to send them via API because of imports and suspected we didn't want the extra branch. I did not really like having to add this to the UI but found consistency important.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, there is no point in asking for clarification for a contest where no data is supposed to be known yet to teams.

I want the jury to still be able to send them via API because of imports

Do we have a way to import clarifications through problem upload or what do you mean by "imports" here?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, there is no point in asking for clarification for a contest where no data is supposed to be known yet to teams.

I think can I go to the toilet is always an important one. But I'm fine with either way.. either the extra branch in the UI or the extra branch in the API.

Do we have a way to import clarifications through problem upload or what do you mean by "imports" here?

I'm not sure if we have it yet, but I think it's something we should have. In BAPC prelims (multisite over different days) the jury now updates the PDF. But I can imagine a year where we would just also upload the clars directly in case as they don't have the time.

Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{% if clarifications is not empty or always_display %}
<h1 class="teamoverview">Clarifications</h1>
{% if clarifications is empty %}
<p class="nodata">No clarifications.</p>
{% else %}
{% include 'team/partials/clarification_list.html.twig' with {clarifications: clarifications} %}
{% endif %}
{% endif %}

<h1 class="teamoverview">Clarification Requests</h1>
{% if clarificationRequests is empty %}
<p class="nodata">No clarification request.</p>
{% else %}
{% include 'team/partials/clarification_list.html.twig' with {clarifications: clarificationRequests} %}
{% endif %}

<div class="m-1">
<a href="{{ path('team_clarification_add') }}" class="btn btn-secondary btn-sm" data-ajax-modal data-ajax-modal-after="initModalClarificationPreviewAdd">
Request clarification
</a>
</div>

27 changes: 4 additions & 23 deletions webapp/templates/team/partials/index_content.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,8 @@
<h2 id="contestnotstarted" class="text-center">
Contest {{ contest | printContestStart }}
</h2>
{% if clarifications is not empty %}
<h1 class="teamoverview">Clarifications</h1>
{% include 'team/partials/clarification_list.html.twig' with {clarifications: clarifications} %}
{% endif %}

{% include 'team/partials/clarifications_team.html.twig' with {'always_display': false} %}
{% else %}

<div id="teamscoresummary">
Expand All @@ -30,26 +28,9 @@

{% include 'team/partials/submission_list.html.twig' %}
</div>
<div class="col">
<h1 class="teamoverview">Clarifications</h1>
{% if clarifications is empty %}
<p class="nodata">No clarifications.</p>
{% else %}
{% include 'team/partials/clarification_list.html.twig' with {clarifications: clarifications} %}
{% endif %}

<h1 class="teamoverview">Clarification Requests</h1>
{% if clarificationRequests is empty %}
<p class="nodata">No clarification request.</p>
{% else %}
{% include 'team/partials/clarification_list.html.twig' with {clarifications: clarificationRequests} %}
{% endif %}

<div class="m-1">
<a href="{{ path('team_clarification_add') }}" class="btn btn-secondary btn-sm" data-ajax-modal data-ajax-modal-after="initModalClarificationPreviewAdd">
Request clarification
</a>
</div>
<div class="col">
{% include 'team/partials/clarifications_team.html.twig' with {'always_display': true} %}
</div>
</div>
{% endif %}
Expand Down