2021-09-24 20:28:51 +02:00
|
|
|
{% extends "layouts/app.twig" %}
|
|
|
|
{% import 'macros/base.twig' as m %}
|
|
|
|
{% import 'macros/form.twig' as f %}
|
|
|
|
|
2023-01-27 21:01:23 +01:00
|
|
|
{% block title %}
|
2023-03-05 03:00:38 +01:00
|
|
|
{{ is_tshirt ? __('user.edit.shirt') : __('user.edit.goodie') }}
|
2023-08-17 20:13:46 +02:00
|
|
|
{%- endblock %}
|
2021-09-24 20:28:51 +02:00
|
|
|
|
|
|
|
{% block content %}
|
|
|
|
<div class="container">
|
2023-10-25 17:38:23 +02:00
|
|
|
<h1>
|
2023-12-21 13:08:29 +01:00
|
|
|
{{ m.button(m.icon('chevron-left'), url('/admin-active'), null, 'sm', __('general.back')) }}
|
2023-10-25 17:38:23 +02:00
|
|
|
{{ block('title') }}: <small>{{ m.user(userdata) }}</small>
|
|
|
|
</h1>
|
2021-09-24 20:28:51 +02:00
|
|
|
|
|
|
|
{% include 'layouts/parts/messages.twig' %}
|
|
|
|
|
|
|
|
<form method="post">
|
|
|
|
{{ csrf() }}
|
|
|
|
|
|
|
|
<div class="row">
|
2023-03-05 03:00:38 +01:00
|
|
|
{% if is_tshirt %}
|
2023-01-27 21:01:23 +01:00
|
|
|
<div class="col-md-6">
|
2023-04-19 22:34:08 +02:00
|
|
|
{{ f.select('shirt_size', __('user.shirt_size'), config('tshirt_sizes'), {
|
|
|
|
'selected': userdata.personalData.shirt_size,
|
2023-05-03 17:51:43 +02:00
|
|
|
'required': true,
|
|
|
|
'required_icon': true,
|
2023-05-11 19:04:07 +02:00
|
|
|
'default_option': __('form.select_placeholder'),
|
2023-04-19 22:34:08 +02:00
|
|
|
}) }}
|
2023-01-27 21:01:23 +01:00
|
|
|
</div>
|
|
|
|
{% endif %}
|
2021-10-26 16:08:27 +02:00
|
|
|
<div class="col-md-6">
|
2023-04-19 22:34:08 +02:00
|
|
|
{{ f.switch('arrived', __('user.arrived'), {
|
|
|
|
'checked': userdata.state.arrived,
|
|
|
|
'disabled': not has_permission_to('admin_arrive'),
|
|
|
|
}) }}
|
2021-09-24 20:28:51 +02:00
|
|
|
|
2024-01-23 17:11:32 +01:00
|
|
|
{% if userdata.state.force_active and config('enable_force_active') %}
|
2023-04-19 22:34:08 +02:00
|
|
|
{{ f.switch('force_active', __('user.force_active'), {
|
|
|
|
'checked': true,
|
|
|
|
'disabled': true,
|
|
|
|
}) }}
|
2021-09-24 20:28:51 +02:00
|
|
|
{% endif %}
|
|
|
|
|
2023-04-19 22:34:08 +02:00
|
|
|
{{ f.switch('active', __('user.active'), {
|
|
|
|
'checked': userdata.state.active,
|
|
|
|
}) }}
|
2021-10-26 16:08:27 +02:00
|
|
|
|
2024-04-10 18:29:12 +02:00
|
|
|
{{ f.switch('got_goodie', is_tshirt ? __('user.got_shirt') : __('user.got_goodie'), {
|
|
|
|
'checked': userdata.state.got_goodie,
|
2023-04-19 22:34:08 +02:00
|
|
|
}) }}
|
2021-09-24 20:28:51 +02:00
|
|
|
</div>
|
|
|
|
<div class="col-md-12">
|
2023-12-21 13:08:29 +01:00
|
|
|
{{ f.submit(__('form.save'), {'icon_left': 'save'}) }}
|
2021-09-24 20:28:51 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</form>
|
|
|
|
</div>
|
|
|
|
{% endblock %}
|