Allow to release quota after exit scans

This commit is contained in:
Raphael Michel
2020-06-26 16:49:19 +02:00
parent fdea190d72
commit 922f12f55e
15 changed files with 178 additions and 24 deletions

View File

@@ -9,7 +9,7 @@
{% blocktrans with name=quota.name %}Quota: {{ name }}{% endblocktrans %}
{% if 'can_change_items' in request.eventpermset %}
<a href="{% url "control:event.items.quotas.edit" event=request.event.slug organizer=request.event.organizer.slug quota=quota.pk %}"
class="btn btn-default">
class="btn btn-default">
<span class="fa fa-edit"></span>
{% trans "Edit quota" %}
</a>
@@ -34,7 +34,8 @@
</div>
{% else %}
<div class="alert alert-warning">
<button type="submit" class="btn btn-primary pull-right flip" name="reopen" value="true">{% trans "Open quota" %}</button>
<button type="submit" class="btn btn-primary pull-right flip" name="reopen"
value="true">{% trans "Open quota" %}</button>
{% trans "This quota is closed since it has been sold out before. Tickets are theoretically available, but will not be sold unless you manually re-open the quota." %}
<div class="clearfix"></div>
</div>
@@ -65,9 +66,11 @@
{% if row.strong %}</strong>{% endif %}
</div>
<div class="col-xs-3 flip text-right">
{% if row.strong %}<strong>{% endif %}
{% if not row.strong %}{% endif %} {{ row.value }}
{% if row.strong %}</strong>{% endif %}
{% if row.strong %}
<strong>{{ row.value }}</strong>
{% else %}
{% if row.value >= 0 %} {{ row.value }}{% else %}+ {{ row.value_abs }}{% endif %}
{% endif %}
</div>
</div>
{% endfor %}

View File

@@ -40,6 +40,7 @@
<fieldset>
<legend>{% trans "Advanced options" %}</legend>
{% bootstrap_field form.close_when_sold_out layout="control" %}
{% bootstrap_field form.release_after_exit layout="control" %}
</fieldset>
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">

View File

@@ -422,6 +422,7 @@
{% bootstrap_form_errors form %}
{% bootstrap_field form.size layout="control" %}
{% bootstrap_field form.itemvars layout="control" %}
{% bootstrap_field form.release_after_exit layout="control" %}
</div>
</div>
{% endfor %}
@@ -449,6 +450,7 @@
<div class="panel-body form-horizontal">
{% bootstrap_field formset.empty_form.size layout="control" %}
{% bootstrap_field formset.empty_form.itemvars layout="control" %}
{% bootstrap_field formset.empty_form.release_after_exit layout="control" %}
</div>
</div>
{% endescapescript %}

View File

@@ -106,6 +106,7 @@
{% bootstrap_form_errors form %}
{% bootstrap_field form.size layout="control" %}
{% bootstrap_field form.itemvars layout="control" %}
{% bootstrap_field form.release_after_exit layout="control" %}
</div>
</div>
{% endfor %}
@@ -133,6 +134,7 @@
<div class="panel-body form-horizontal">
{% bootstrap_field formset.empty_form.size layout="control" %}
{% bootstrap_field formset.empty_form.itemvars layout="control" %}
{% bootstrap_field formset.empty_form.release_after_exit layout="control" %}
</div>
</div>
{% endescapescript %}