templates/olympiads/iofs/stages.html.twig line 1
{% set st_description %}{%- if config_value('olymp-right-block','desc-show-text') -%}{{ config_value('olymp-right-block','text-block-'~app.request.locale)|raw }}{%- endif -%}{% endset %}{% set button_task %}{{ config_value('olymp-right-block','down-block-'~app.request.locale)|raw }}{# <a class="iofs__register-offer-button mt-5" style="padding: 9px 6px"href="/file/1419/tasks.pdf">{{ 'site.stages.tasks'|trans }}</a> #}{% endset %}{% set button_review %}{% if config_value('olymp-right-block','show-review') %}<a class="iofs__register-offer-button mt-3"href="{{ path('review_60_submit') }}">{{ 'site.stages.review_create'|trans }}</a>{% endif %}{% endset %}{% if stages is defined and stages %}{% import "parts/pretty_date.html.twig" as pd %}<div class="iofs__register-offer-container"><div class="iofs__register-offer-wrapper">{% for st in stages %}{% set online_stage = (onlineStages[ st.id] is defined)?onlineStages[ st.id]:null %}<div class="iofs__register-offer{% if online_stage %}online-stage{% if online_stage.active %} online-stage-active {% endif %}{% if online_stage.inPast %} online-stage-past {% endif %}{% endif %}">{# <h2 class="iofs__register-offer-title">{{ st.caption }}</h2> #}{{ st_description }}{% if config_value('olymp-right-block','desc-show-auto') %}<h2 class="iofs__register-offer-title">{{ st.caption }}</h2>{% if online_stage %}{% for c in online_stage.categories %}<div class="iofs__register-offer-row"><div class="iofs__register-offer-row-icon"><i class="fal fa-calendar-alt"></i></div><div class="iofs__register-offer-row-text">{{ c.caption }}: {{ pd.pretty_date_full(c.interval.from,c.interval.to) }}{{ pd.pretty_time(c.timeInterval.from,c.timeInterval.to) }}</div></div>{% endfor %}{% else %}<div class="iofs__register-offer-row"><div class="iofs__register-offer-row-icon"><i class="fal fa-calendar-alt"></i></div><div class="iofs__register-offer-row-text">{{ pd.pretty_date_full(st.interval.from,st.interval.to) }}</div></div>{% endif %}{% if st.placeShort %}<div class="iofs__register-offer-row"><div class="iofs__register-offer-row-icon"><i class="fal fa-map-marker-alt"></i></div><div class="iofs__register-offer-row-text">{{ st.placeShort }}</div></div>{% endif %}{% if online_stage and not online_stage.inPast %}{% set showSoprovod = false %}{% set eventID=null %}{% for c in online_stage.categories|filter(c=>c.isRegistrationEnable) %}{% if loop.first %}{% set eventID=c.event.id %}{% endif %}<a class="iofs__register-offer-button {% if not is_granted('online_category_registration_open', c) %}disabled{% else %}{% set showSoprovod=true %}{% endif %}"href="{{ path('online_apply', {id:c.id}) }}">{{ c.applyButton }}</a>{% endfor %}{# {% if eventID %}<a class="iofs__register-offer-button mt-4"href="{{ path('online_attendant_apply', {id:eventID}) }}">Регистрация сопровождающих</a>{% endif %} #}{% endif %}<hr class="mt-4 mb-4">{% endif %}{% if is_granted('trial_test_enabled') and config_value('trial-test','show_button') %}<a class="iofs__register-offer-button highlight-white-border mt-4 "href="{{ path('online_trial') }}">{{ "olymp_online.trial.reg_block_button"|trans }}</a>{% endif %}{{ button_task }}{{ button_review }}</div>{% endfor %}</div></div>{% else %}<div class="iofs__register-offer-container"><div class="iofs__register-offer-wrapper"><div class="iofs__register-offer online-stageonline-stage-active ">{{ st_description }}{{ button_task }}{{ button_review }}</div></div></div>{% endif %}