More views

This commit is contained in:
Raphael Michel
2018-07-16 10:34:23 +02:00
parent 053de88173
commit e9f0af1898
77 changed files with 2564 additions and 2009 deletions
+12
View File
@@ -1151,3 +1151,15 @@ class Quota(LoggedModel):
else:
if subevent:
raise ValidationError(_('The subevent does not belong to this event.'))
def get_items_display(self):
parts = []
vars = self.variations.all()
for i in self.items.all():
if i.has_variations:
for v in vars:
if v.item_id == i.pk:
parts.append('{} {}'.format(i, v))
else:
parts.append(str(i))
return parts
@@ -32,6 +32,26 @@
{% blocktrans with name=checkinlist.name %}Check-in list: {{ name }}{% endblocktrans %}
</h1>
</div>
<div class="panel-body">
<dl class="dl-horizontal dl-left">
<dt>{% trans "Products" %}</dt>
<dd>
{% if checkinlist.all_products %}
{% trans "All" %}
{% else %}
{{ checkinlist.limit_products.all|join:"<br>" }}
{% endif %}
</dd>
<dt>{% trans "Orders" %}</dt>
<dd>{% if checkinlist.include_pending %}{% trans "Pending and paid" %}{% else %}{% trans "Only paid orders" %}{% endif %}</dd>
{% if checkinlist.subevent %}
<dt>{% trans "Date" context "subevent" %}</dt>
<dd>{{ checkinlist.subevent }}</dd>
{% endif %}
</dl>
</div>
</div>
<div class="panel panel-default">
<form class="panel-body row filter-form" action="" method="get">
<div class="col-md-4 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.user layout='inline' %}
@@ -4,34 +4,37 @@
{% load formset_tags %}
{% block title %}{{ request.event.name }}{% endblock %}
{% block content %}
<div class="quick-setup-step">
<div class="quick-icon">
<span class="fa fa-fw fa-check-circle text-success"></span>
</div>
<div class="quick-content">
<h2>{% trans "Congratulations!" %}</h2>
<p>
<strong>{% trans "You just created an event!" %}</strong>
</p>
<p>
{% blocktrans trimmed %}
You can scroll down and create your first ticket products quickly, or you can use the navigation
on the left to modify the settings of your event in much more detail.
{% endblocktrans %}
</p>
<div class="clearfix"></div>
<div class="panel panel-default">
<div class="panel-body">
<div class="quick-setup-step">
<div class="quick-icon">
<span class="fa fa-fw fa-check-circle text-success"></span>
</div>
<div class="quick-content">
<h2>{% trans "Congratulations!" %}</h2>
<p>
<strong>{% trans "You just created an event!" %}</strong>
</p>
<p>
{% blocktrans trimmed %}
You can scroll down and create your first ticket products quickly, or you can use the
navigation
on the left to modify the settings of your event in much more detail.
{% endblocktrans %}
</p>
<div class="clearfix"></div>
</div>
</div>
</div>
</div>
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<fieldset class="quick-setup-step">
<div class="quick-icon">
<span class="fa fa-fw fa-ticket text-muted"></span>
</div>
<div class="quick-content">
<fieldset class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Create ticket types" %}</legend>
</div>
<div class="panel-body">
<div class="formset" data-formset data-formset-prefix="{{ formset.prefix }}">
{{ formset.management_form }}
{% bootstrap_formset_errors formset %}
@@ -104,7 +107,9 @@
<strong>{% trans "Total capacity:" %}</strong>
<span id="total-capacity"></span>
{% bootstrap_field form.total_quota layout="inline" field_class="sr-only" %}
<a href="#" data-toggle="tooltip" title="{% trans 'You can set a limit on the total number of tickets sold for your event, regardless of the ticket type.' %}" id="total-capacity-edit">
<a href="#" data-toggle="tooltip"
title="{% trans 'You can set a limit on the total number of tickets sold for your event, regardless of the ticket type.' %}"
id="total-capacity-edit">
<span class="fa fa-edit"></span>
</a>
</div>
@@ -114,20 +119,19 @@
<p>&nbsp;</p>
<p class="bigger">
{% blocktrans trimmed %}
If you want to use more advanced features like non-admission products, product variations, custom
quotas, add-on products or want to modify your ticket types in more detail, you can later do so
in the "Products" section in the navigation. Don't worry, you can change everything you input here.
If you want to use more advanced features like non-admission products, product variations,
custom quotas, add-on products or want to modify your ticket types in more detail, you can later
do so in the "Products" section in the navigation. Don't worry, you can change everything you
input here.
{% endblocktrans %}
</p>
<p>&nbsp;</p>
</div>
</fieldset>
<fieldset class="quick-setup-step">
<div class="quick-icon">
<span class="fa fa-fw fa-wrench text-muted"></span>
</div>
<div class="quick-content">
<fieldset class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Features" %}</legend>
</div>
<div class="panel-body">
<p class="bigger">
{% blocktrans trimmed %}
We recommend that you take some time to go through the "Settings" part of your event, but if
@@ -138,15 +142,13 @@
{% bootstrap_field form.waiting_list_enabled layout="control" label_class="sr-only" field_class="col-md-12" %}
{% bootstrap_field form.show_quota_left layout="control" label_class="sr-only" field_class="col-md-12" %}
{% bootstrap_field form.attendee_names_required layout="control" label_class="sr-only" field_class="col-md-12" %}
<p>&nbsp;</p>
</div>
</fieldset>
<fieldset class="quick-setup-step" id="quick-setup-step-payment">
<div class="quick-icon">
<span class="fa fa-fw fa-money text-muted"></span>
</div>
<div class="quick-content">
<fieldset class="panel panel-default" id="quick-setup-step-payment">
<div class="panel-heading">
<legend>{% trans "Payment" %}</legend>
</div>
<div class="panel-body">
<p class="bigger">
{% blocktrans trimmed %}
pretix supports a
@@ -164,21 +166,20 @@
<div data-display-dependency="#id_payment_stripe__enabled">
<div class="alert alert-info">
{% blocktrans trimmed %}
After you saved this page, we will redirect you to Stripe to create or connect an account
After you saved this page, we will redirect you to Stripe to create or connect an
account
there. Once you completed this, you will be taken back to pretix.
{% endblocktrans %}
</div>
</div>
{% endif %}
<p>&nbsp;</p>
</div>
</fieldset>
<fieldset class="quick-setup-step">
<div class="quick-icon">
<span class="fa fa-fw fa-envelope text-muted"></span>
</div>
<div class="quick-content">
<fieldset class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Getting in touch with you" %}</legend>
</div>
<div class="quick-content panel-body">
<p class="bigger">
{% blocktrans trimmed %}
In case something goes wrong or is unclear, we strongly suggest that you provide ways for your
@@ -6,6 +6,11 @@
<div class="panel-heading">
<legend>{% trans "Tax rules" %}</legend>
</div>
<div class="panel-body">
{% trans "You can create one or multiple tax rules that you can apply to your products." %}
</div>
</div>
<div class="panel panel-default">
{% if taxrules|length == 0 %}
<div class="panel-body empty-collection">
<p>
@@ -3,9 +3,6 @@
{% load bootstrap3 %}
{% block title %}{% trans "Create a new event" %}{% endblock %}
{% block content %}
<h1>{% trans "Create a new event" %} <small>{% blocktrans trimmed with step=wizard.steps.step1 %}
Step {{ step }}
{% endblocktrans %}</small></h1>
{% if has_organizer %}
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
@@ -13,17 +10,6 @@
{% bootstrap_form_errors form %}
{% block form %}
{% endblock %}
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save pull-right">
{% trans "Continue" %}
</button>
{% if wizard.steps.prev %}
<button name="wizard_goto_step" type="submit" value="{{ wizard.steps.prev }}"
class="btn btn-default btn-lg pull-left">
{% trans "Back" %}
</button>
{% endif %}
</div>
</form>
{% else %}
<div class="alert alert-danger">
@@ -2,54 +2,81 @@
{% load i18n %}
{% load bootstrap3 %}
{% block form %}
<fieldset>
<legend>{% trans "General information" %}</legend>
{% bootstrap_field form.name layout="control" %}
<div class="form-group">
<label class="col-md-3 control-label" for="{{ form.slug.id_for_label }}">{{ form.slug.label }}</label>
<div class="col-md-9 form-inline">
<button class="btn btn-default pull-right" type="button" id="event-slug-random-generate"
data-rng-url="{% url "control:events.add.slugrng" organizer=organizer.slug %}">
{% trans "Set to random" %}
</button>
{% bootstrap_field form.slug form_group_class="helper-display-inline" show_label=False layout="inline" %}
<div class="help-block">
{% blocktrans trimmed %}
This is the address users can buy your tickets at. Should be short, only contain lowercase
letters and numbers, and must be unique among your events. We recommend some kind of
abbreviation or a date with less than 10 characters that can be easily remembered, but you
can also choose to use a random value.
{% endblocktrans %}
</div>
<div class="help-block">
{% blocktrans trimmed %}
We will also use this in some places like order codes, invoice numbers or bank transfer
references as an abbreviation to reference this event.
{% endblocktrans %}
</div>
<div class="slug-length alert alert-warning helper-display-none-soft">
{% blocktrans trimmed %}
We strongly recommend against using short forms of more then 16 characters.
{% endblocktrans %}
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Create a new event" %}
<small>{% blocktrans trimmed with step=wizard.steps.step1 %}
Step {{ step }}
{% endblocktrans %}</small>
</h1>
</div>
<fieldset class="panel-body">
{% bootstrap_field form.name layout="control" %}
<div class="form-group">
<label class="col-md-3 control-label" for="{{ form.slug.id_for_label }}">{{ form.slug.label }}</label>
<div class="col-md-9 form-inline">
<button class="btn btn-default pull-right" type="button" id="event-slug-random-generate"
data-rng-url="{% url "control:events.add.slugrng" organizer=organizer.slug %}">
{% trans "Set to random" %}
</button>
{% bootstrap_field form.slug form_group_class="helper-display-inline" show_label=False layout="inline" %}
<div class="help-block">
{% blocktrans trimmed %}
This is the address users can buy your tickets at. Should be short, only contain lowercase
letters and numbers, and must be unique among your events. We recommend some kind of
abbreviation or a date with less than 10 characters that can be easily remembered, but you
can also choose to use a random value.
{% endblocktrans %}
</div>
<div class="help-block">
{% blocktrans trimmed %}
We will also use this in some places like order codes, invoice numbers or bank transfer
references as an abbreviation to reference this event.
{% endblocktrans %}
</div>
<div class="slug-length alert alert-warning helper-display-none-soft">
{% blocktrans trimmed %}
We strongly recommend against using short forms of more then 16 characters.
{% endblocktrans %}
</div>
</div>
</div>
{% bootstrap_field form.date_from layout="control" %}
{% bootstrap_field form.date_to layout="control" %}
{% bootstrap_field form.location layout="control" %}
{% bootstrap_field form.currency layout="control" %}
{% bootstrap_field form.tax_rate addon_after="%" layout="control" %}
</fieldset>
</div>
<fieldset class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Display settings" %}</legend>
</div>
<div class="panel-body">
{% bootstrap_field form.locale layout="control" %}
{% bootstrap_field form.timezone layout="control" %}
</div>
{% bootstrap_field form.date_from layout="control" %}
{% bootstrap_field form.date_to layout="control" %}
{% bootstrap_field form.location layout="control" %}
{% bootstrap_field form.currency layout="control" %}
{% bootstrap_field form.tax_rate addon_after="%" layout="control" %}
</fieldset>
<fieldset>
<legend>{% trans "Display settings" %}</legend>
{% bootstrap_field form.locale layout="control" %}
{% bootstrap_field form.timezone layout="control" %}
</fieldset>
{% if form.presale_start %}
<fieldset>
<legend>{% trans "Timeline" %}</legend>
{% bootstrap_field form.presale_start layout="control" %}
{% bootstrap_field form.presale_end layout="control" %}
<fieldset class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Timeline" %}</legend>
</div>
<div class="panel-body">
{% bootstrap_field form.presale_start layout="control" %}
{% bootstrap_field form.presale_end layout="control" %}
</div>
</fieldset>
{% endif %}
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save pull-right">
{% trans "Continue" %}
</button>
{% if wizard.steps.prev %}
<button name="wizard_goto_step" type="submit" value="{{ wizard.steps.prev }}"
class="btn btn-default btn-lg pull-left">
{% trans "Back" %}
</button>
{% endif %}
</div>
{% endblock %}
@@ -2,19 +2,41 @@
{% load i18n %}
{% load bootstrap3 %}
{% block form %}
<p>
{% blocktrans trimmed %}
Do you want to copy over your configuration from a different event? We will copy all
products, categories, quotas, and questions as well as general event settings.
{% endblocktrans %}
</p>
<div class="alert alert-info">
<strong>
{% blocktrans trimmed %}
Please make sure to review all settings extensively. You will probably still need to change some
settings manually, e.g. date and time settings and texts that contain the event name.
{% endblocktrans %}
</strong>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Create a new event" %}
<small>{% blocktrans trimmed with step=wizard.steps.step1 %}
Step {{ step }}
{% endblocktrans %}</small>
</h1>
</div>
<div class="panel-body">
<p>
{% blocktrans trimmed %}
Do you want to copy over your configuration from a different event? We will copy all
products, categories, quotas, and questions as well as general event settings.
{% endblocktrans %}
</p>
<div class="alert alert-info">
<strong>
{% blocktrans trimmed %}
Please make sure to review all settings extensively. You will probably still need to change some
settings manually, e.g. date and time settings and texts that contain the event name.
{% endblocktrans %}
</strong>
</div>
{% bootstrap_field form.copy_from_event layout="control" %}
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save pull-right">
{% trans "Continue" %}
</button>
{% if wizard.steps.prev %}
<button name="wizard_goto_step" type="submit" value="{{ wizard.steps.prev }}"
class="btn btn-default btn-lg pull-left">
{% trans "Back" %}
</button>
{% endif %}
</div>
</div>
</div>
{% bootstrap_field form.copy_from_event layout="control" %}
{% endblock %}
@@ -2,11 +2,33 @@
{% load i18n %}
{% load bootstrap3 %}
{% block form %}
{% bootstrap_field form.organizer layout="horizontal" %}
{% bootstrap_field form.locales layout="horizontal" %}
{% bootstrap_field form.has_subevents layout="horizontal" %}
<p>
<span class="fa fa-info-circle"></span>
{% trans "Please note that you will only be able to delete your event until the first order has been created." %}
</p>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Create a new event" %}
<small>{% blocktrans trimmed with step=wizard.steps.step1 %}
Step {{ step }}
{% endblocktrans %}</small>
</h1>
</div>
<div class="panel-body">
{% bootstrap_field form.organizer layout="horizontal" %}
{% bootstrap_field form.locales layout="horizontal" %}
{% bootstrap_field form.has_subevents layout="horizontal" %}
<p class="help-block">
<span class="fa fa-info-circle"></span>
{% trans "Please note that you will only be able to delete your event until the first order has been created." %}
</p>
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save pull-right">
{% trans "Continue" %}
</button>
{% if wizard.steps.prev %}
<button name="wizard_goto_step" type="submit" value="{{ wizard.steps.prev }}"
class="btn btn-default btn-lg pull-left">
{% trans "Back" %}
</button>
{% endif %}
</div>
</div>
</div>
{% endblock %}
@@ -4,134 +4,150 @@
{% load bootstrap3 %}
{% block title %}{% trans "Events" %}{% endblock %}
{% block content %}
<h1>{% trans "Events" %}</h1>
<p>{% trans "The list below shows all events you have administrative access to. Click on the event name to access event details." %}</p>
{% if events|length == 0 and not filter_form.filtered %}
<div class="empty-collection">
<p>
{% blocktrans trimmed %}
You currently do not have access to any events.
{% endblocktrans %}
</p>
<a href="{% url "control:events.add" %}" class="btn btn-primary btn-lg">
<span class="fa fa-plus"></span>
{% trans "Create a new event" %}
</a>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Events" %}</h1>
</div>
{% else %}
<form class="row filter-form" action="" method="get">
<div class="col-md-4 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.query layout='inline' %}
<div class="panel-body">{% trans "The list below shows all events you have administrative access to. Click on the event name to access event details." %}</div>
</div>
<div class="panel panel-default">
{% if events|length == 0 and not filter_form.filtered %}
<div class="empty-collection panel-body">
<p>
{% blocktrans trimmed %}
You currently do not have access to any events.
{% endblocktrans %}
</p>
<a href="{% url "control:events.add" %}" class="btn btn-primary btn-lg">
<span class="fa fa-plus"></span>
{% trans "Create a new event" %}
</a>
</div>
<div class="col-md-3 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.status layout='inline' %}
</div>
<div class="col-md-3 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.organizer layout='inline' %}
</div>
<div class="col-md-2 col-sm-6 col-xs-12">
<button class="btn btn-primary btn-block" type="submit">
<span class="fa fa-filter"></span>
<span class="hidden-md">
{% else %}
<form class="panel-body row filter-form" action="" method="get">
<div class="col-md-4 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.query layout='inline' %}
</div>
<div class="col-md-3 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.status layout='inline' %}
</div>
<div class="col-md-3 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.organizer layout='inline' %}
</div>
<div class="col-md-2 col-sm-6 col-xs-12">
<button class="btn btn-primary btn-block" type="submit">
<span class="fa fa-filter"></span>
<span class="hidden-md">
{% trans "Filter" %}
</span>
</button>
</button>
</div>
</form>
<div class="panel-body">
<a href="{% url "control:events.add" %}" class="btn btn-default">
<span class="fa fa-plus"></span>
{% trans "Create a new event" %}
</a>
</div>
</form>
<p>
<a href="{% url "control:events.add" %}" class="btn btn-default">
<span class="fa fa-plus"></span>
{% trans "Create a new event" %}
</a>
</p>
<table class="table table-condensed table-hover">
<thead>
<tr>
<th>
{% trans "Event name" %}
</th>
{% if not hide_orga %}
<th>
{% trans "Organizer" %}
<a href="?{% url_replace request 'ordering' '-organizer' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'organizer' %}"><i class="fa fa-caret-up"></i></a>
</th>
{% endif %}
<th>
{% trans "Start date" %}
<a href="?{% url_replace request 'ordering' '-date_from' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'date_from' %}"><i class="fa fa-caret-up"></i></a>
/
{% trans "End date" %}
<a href="?{% url_replace request 'ordering' '-date_to' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'date_to' %}"><i class="fa fa-caret-up"></i></a>
</th>
<th>
{% trans "Paid tickets per quota" %}
<a href="?{% url_replace request 'ordering' '-sum_tickets_paid' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'sum_tickets_paid' %}"><i class="fa fa-caret-up"></i></a>
</th>
<th class="text-right">
{% trans "Status" %}
<a href="?{% url_replace request 'ordering' '-live' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'live' %}"><i class="fa fa-caret-up"></i></a>
</th>
</tr>
</thead>
<tbody>
{% for e in events %}
<table class="table table-condensed table-hover">
<thead>
<tr>
<td class="event-name-col">
<strong><a href="{% url "control:event.index" organizer=e.organizer.slug event=e.slug %}">{{ e.name }}</a></strong>
<br><small>{{ e.slug }}</small>
</td>
{% if not hide_orga %}<td>{{ e.organizer }}</td>{% endif %}
<td class="event-date-col">
{% if e.has_subevents %}
{{ e.min_from|default_if_none:""|date:"SHORT_DATETIME_FORMAT" }}
{% else %}
{{ e.get_short_date_from_display }}
{% endif %}
{% if e.has_subevents %}
<span class="label label-default">{% trans "Series" %}</span>
{% endif %}
{% if e.settings.show_date_to and e.date_to %}
<br>
{% if e.has_subevents %}
{{ e.max_fromto|default_if_none:e.max_from|default_if_none:e.max_to|default_if_none:""|date:"SHORT_DATETIME_FORMAT" }}
{% else %}
{{ e.get_short_date_to_display }}
{% endif %}
{% endif %}
</td>
<td>
{% for q in e.first_quotas|slice:":3" %}
{% include "pretixcontrol/fragment_quota_box_paid.html" with quota=q %}
{% endfor %}
{% if e.first_quotas|length > 3 %}
<a href="{% url "control:event.items.quotas" organizer=e.organizer.slug event=e.slug %}"
class="quotabox-more" data-toggle="tooltip" title="{% trans "More quotas" %}"
data-placement="top">
&middot;&middot;&middot;
</a>
{% endif %}
</td>
<td class="text-right">
{% if not e.live %}
<span class="label label-danger">{% trans "Shop disabled" %}</span>
{% elif e.presale_has_ended %}
<span class="label label-warning">{% trans "Presale over" %}</span>
{% elif not e.presale_is_running %}
<span class="label label-warning">{% trans "Presale not started" %}</span>
{% else %}
<span class="label label-success">{% trans "On sale" %}</span>
{% endif %}
</td>
<th>
{% trans "Event name" %}
</th>
{% if not hide_orga %}
<th>
{% trans "Organizer" %}
<a href="?{% url_replace request 'ordering' '-organizer' %}"><i
class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'organizer' %}"><i
class="fa fa-caret-up"></i></a>
</th>
{% endif %}
<th>
{% trans "Start date" %}
<a href="?{% url_replace request 'ordering' '-date_from' %}"><i
class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'date_from' %}"><i class="fa fa-caret-up"></i></a>
/
{% trans "End date" %}
<a href="?{% url_replace request 'ordering' '-date_to' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'date_to' %}"><i class="fa fa-caret-up"></i></a>
</th>
<th>
{% trans "Paid tickets per quota" %}
<a href="?{% url_replace request 'ordering' '-sum_tickets_paid' %}"><i
class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'sum_tickets_paid' %}"><i
class="fa fa-caret-up"></i></a>
</th>
<th class="text-right">
{% trans "Status" %}
<a href="?{% url_replace request 'ordering' '-live' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'live' %}"><i class="fa fa-caret-up"></i></a>
</th>
</tr>
{% endfor %}
</tbody>
</table>
{% include "pretixcontrol/pagination.html" %}
{% endif %}
</thead>
<tbody>
{% for e in events %}
<tr>
<td class="event-name-col">
<strong><a
href="{% url "control:event.index" organizer=e.organizer.slug event=e.slug %}">{{ e.name }}</a></strong>
<br>
<small>{{ e.slug }}</small>
</td>
{% if not hide_orga %}
<td>{{ e.organizer }}</td>{% endif %}
<td class="event-date-col">
{% if e.has_subevents %}
{{ e.min_from|default_if_none:""|date:"SHORT_DATETIME_FORMAT" }}
{% else %}
{{ e.get_short_date_from_display }}
{% endif %}
{% if e.has_subevents %}
<span class="label label-default">{% trans "Series" %}</span>
{% endif %}
{% if e.settings.show_date_to and e.date_to %}
<br>
{% if e.has_subevents %}
{{ e.max_fromto|default_if_none:e.max_from|default_if_none:e.max_to|default_if_none:""|date:"SHORT_DATETIME_FORMAT" }}
{% else %}
{{ e.get_short_date_to_display }}
{% endif %}
{% endif %}
</td>
<td>
{% for q in e.first_quotas|slice:":3" %}
{% include "pretixcontrol/fragment_quota_box_paid.html" with quota=q %}
{% endfor %}
{% if e.first_quotas|length > 3 %}
<a href="{% url "control:event.items.quotas" organizer=e.organizer.slug event=e.slug %}"
class="quotabox-more" data-toggle="tooltip" title="{% trans "More quotas" %}"
data-placement="top">
&middot;&middot;&middot;
</a>
{% endif %}
</td>
<td class="text-right">
{% if not e.live %}
<span class="label label-danger">{% trans "Shop disabled" %}</span>
{% elif e.presale_has_ended %}
<span class="label label-warning">{% trans "Presale over" %}</span>
{% elif not e.presale_is_running %}
<span class="label label-warning">{% trans "Presale not started" %}</span>
{% else %}
<span class="label label-success">{% trans "On sale" %}</span>
{% endif %}
</td>
</tr>
{% endfor %}
</tbody>
</table>
<div class="panel-footer">
{% include "pretixcontrol/pagination.html" %}
</div>
{% endif %}
</div>
{% endblock %}
@@ -4,6 +4,12 @@
{% block title %}{% trans "System message" %}{% endblock %}
{% block content %}
<h1>{% trans "System message" %}</h1>
{{ global_settings.banner_message_detail|rich_text }}
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "System message" %}</h1>
</div>
<div class="panel-body">
{{ global_settings.banner_message_detail|rich_text }}
</div>
</div>
{% endblock %}
@@ -3,14 +3,21 @@
{% load bootstrap3 %}
{% block inner %}
<form action="" method="post" class="form-horizontal" enctype="multipart/form-data">
{% csrf_token %}
{% bootstrap_form_errors form %}
{% bootstrap_form form layout='horizontal' %}
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Save" %}
</button>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Global settings" %}</h1>
</div>
</form>
<div class="panel-body">
<form action="" method="post" class="form-horizontal" enctype="multipart/form-data">
{% csrf_token %}
{% bootstrap_form_errors form %}
{% bootstrap_form form layout='horizontal' %}
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Save" %}
</button>
</div>
</form>
</div>
</div>
{% endblock %}
@@ -4,19 +4,6 @@
{% block title %}{% trans "Global settings" %}{% endblock %}
{% block content %}
<h1>{% trans "Global settings" %}</h1>
<ul class="nav nav-pills">
<li {% if "global.settings" == url_name %}class="active"{% endif %}>
<a href="{% url 'control:global.settings' %}">
{% trans "General" %}
</a>
</li>
<li {% if "global.update" == url_name %}class="active"{% endif %}>
<a href="{% url 'control:global.update' %}">
{% trans "Update check" %}
</a>
</li>
</ul>
{% block inner %}
{% endblock %}
{% endblock %}
@@ -3,55 +3,63 @@
{% load bootstrap3 %}
{% block inner %}
<fieldset>
<legend>{% trans "Update check results" %}</legend>
<fieldset class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Update check results" %}</legend>
</div>
{% if not gs.settings.update_check_perform %}
<div class="alert alert-warning">
{% trans "Update checks are disabled." %}
<div class="panel-body">
<div class="alert alert-warning">
{% trans "Update checks are disabled." %}
</div>
</div>
{% elif not gs.settings.update_check_last %}
<div class="alert alert-info">
{% trans "No update check has been performed yet since the last update of this installation. Update checks are performed on a daily basis if your cronjob is set up properly." %}
{% elif not gs.settings.update_check_last %}
<div class="panel-body">
<div class="alert alert-info">
{% trans "No update check has been performed yet since the last update of this installation. Update checks are performed on a daily basis if your cronjob is set up properly." %}
</div>
<form action="" method="post">
{% csrf_token %}
<p>
<button type="submit" name="trigger" value="1" class="btn btn-default">
{% trans "Check for updates now" %}
</button>
</p>
</form>
</div>
<form action="" method="post">
{% csrf_token %}
<p>
<button type="submit" name="trigger" value="1" class="btn btn-default">
{% trans "Check for updates now" %}
</button>
</p>
</form>
{% elif "error" in gs.settings.update_check_result %}
<div class="alert alert-danger">
{% trans "The last update check was not successful." %}
{% if gs.settings.update_check_result.error == "http_error" %}
{% trans "The pretix.eu server returned an error code." %}
{% elif gs.settings.update_check_result.error == "unavailable" %}
{% trans "The pretix.eu server could not be reached." %}
{% elif gs.settings.update_check_result.error == "development" %}
{% trans "This installation appears to be a development installation." %}
{% endif %}
{% elif "error" in gs.settings.update_check_result %}
<div class="panel-body">
<div class="alert alert-danger">
{% trans "The last update check was not successful." %}
{% if gs.settings.update_check_result.error == "http_error" %}
{% trans "The pretix.eu server returned an error code." %}
{% elif gs.settings.update_check_result.error == "unavailable" %}
{% trans "The pretix.eu server could not be reached." %}
{% elif gs.settings.update_check_result.error == "development" %}
{% trans "This installation appears to be a development installation." %}
{% endif %}
</div>
<form action="" method="post">
{% csrf_token %}
<p>
<button type="submit" name="trigger" value="1" class="btn btn-default">
{% trans "Check for updates now" %}
</button>
</p>
</form>
</div>
<form action="" method="post">
{% csrf_token %}
<p>
<button type="submit" name="trigger" value="1" class="btn btn-default">
{% trans "Check for updates now" %}
</button>
</p>
</form>
{% else %}
<form action="" method="post">
{% csrf_token %}
<p>
<div class="panel-body">
<form action="" method="post">
{% csrf_token %}
{% blocktrans trimmed with date=gs.settings.update_check_last|date:"SHORT_DATETIME_FORMAT" %}
Last updated: {{ date }}
{% endblocktrans %}
<button type="submit" name="trigger" value="1" class="btn btn-default btn-xs">
{% trans "Check for updates now" %}
</button>
</p>
</form>
</form>
</div>
<div class="table-responsive">
<table class="table table-condensed">
<thead>
@@ -63,11 +71,11 @@
</thead>
<tbody>
{% for row in tbl %}
<tr class="{% if row.3 %}danger{% elif row.2 == "?" %}warning{% else %}success{% endif %}">
<td>{{ row.0 }}</td>
<td>{{ row.1 }}</td>
<td>{{ row.2 }}</td>
</tr>
<tr class="{% if row.3 %}danger{% elif row.2 == "?" %}warning{% else %}success{% endif %}">
<td>{{ row.0 }}</td>
<td>{{ row.1 }}</td>
<td>{{ row.2 }}</td>
</tr>
{% endfor %}
</tbody>
</table>
@@ -76,15 +84,19 @@
</fieldset>
<form action="" method="post" class="form-horizontal" enctype="multipart/form-data">
{% csrf_token %}
<fieldset>
<legend>{% trans "Update check settings" %}</legend>
{% bootstrap_form_errors form %}
{% bootstrap_form form layout='horizontal' %}
<fieldset class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Update check settings" %}</legend>
</div>
<div class="panel-body">
{% bootstrap_form_errors form %}
{% bootstrap_form form layout='horizontal' %}
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Save" %}
</button>
</div>
</div>
</fieldset>
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Save" %}
</button>
</div>
</form>
{% endblock %}
@@ -6,6 +6,11 @@
<div class="panel-heading">
<h1 class="panel-title">{% trans "Product categories" %}</h1>
</div>
<div class="panel-body">
{% trans "You can use categories to group multiple products together in an organized way." %}
</div>
</div>
<div class="panel panel-default">
{% if categories|length == 0 %}
<div class="empty-collection panel-body">
<p>
@@ -4,8 +4,13 @@
{% block inside %}
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Products" %}</h1>
<legend>{% trans "Products" %}</legend>
</div>
<div class="panel-body">
{% trans "Products are everything that you sell: Different ticket price categories, additional merchandise items, or parts of your event that you sell individually." %}
</div>
</div>
<div class="panel panel-default">
{% if items|length == 0 %}
<div class="empty-collection panel-body">
<p>
@@ -5,57 +5,76 @@
{% load formset_tags %}
{% block title %}{% blocktrans with name=question.question %}Question: {{ name }}{% endblocktrans %}{% endblock %}
{% block inside %}
<div class="panel panel-default panel-with-btn">
<div class="panel-heading">
<a href="{% url "control:event.items.questions.edit" event=request.event.slug organizer=request.event.organizer.slug question=question.pk %}"
class="btn btn-default btn-sm pull-right">
<span class="fa fa-edit"></span>
{% trans "Edit question" %}
</a>
<h1 class="panel-title">
{% blocktrans with name=question.question %}Question: {{ name }}{% endblocktrans %}
</h1>
</div>
<div class="panel-body">
<form class="form-inline helper-display-inline" action="" method="get">
<p>
<select name="status" class="form-control">
<option value=""
{% if request.GET.status == "" %}selected="selected"{% endif %}>{% trans "All orders" %}</option>
<option value="p"
{% if request.GET.status == "p" %}selected="selected"{% endif %}>{% trans "Paid" %}</option>
<option value="n"
{% if request.GET.status == "n" %}selected="selected"{% endif %}>{% trans "Pending" %}</option>
<option value="np"
{% if request.GET.status == "np" or "status" not in request.GET %}selected="selected"{% endif %}>{% trans "Pending or paid" %}</option>
<option value="o"
{% if request.GET.status == "o" %}selected="selected"{% endif %}>{% trans "Pending (overdue)" %}</option>
<option value="e"
{% if request.GET.status == "e" %}selected="selected"{% endif %}>{% trans "Expired" %}</option>
<option value="ne"
{% if request.GET.status == "ne" %}selected="selected"{% endif %}>{% trans "Pending or expired" %}</option>
<option value="c"
{% if request.GET.status == "c" %}selected="selected"{% endif %}>{% trans "Canceled" %}</option>
<option value="r"
{% if request.GET.status == "r" %}selected="selected"{% endif %}>{% trans "Refunded" %}</option>
</select>
<select name="item" class="form-control">
<option value="">{% trans "All products" %}</option>
{% for item in items %}
<option value="{{ item.id }}"
{% if request.GET.item|add:0 == item.id %}selected="selected"{% endif %}>
{{ item.name }}
</option>
{% endfor %}
</select>
<button class="btn btn-primary" type="submit">{% trans "Filter" %}</button>
</p>
</form>
</div>
</div>
<div class="row" id="question-stats">
{% if not stats %}
<div class="col-md-10 col-xs-12">
<div class="col-lg-10 col-xs-12">
<div class="panel panel-default panel-with-btn">
<div class="panel-heading">
<a href="{% url "control:event.items.questions.edit" event=request.event.slug organizer=request.event.organizer.slug question=question.pk %}"
class="btn btn-default btn-sm pull-right">
<span class="fa fa-edit"></span>
{% trans "Edit question" %}
</a>
<h1 class="panel-title">
{% blocktrans with name=question.question %}Question: {{ name }}{% endblocktrans %}
</h1>
</div>
<div class="panel-body">
<dl class="dl-horizontal dl-left">
<dt>{% trans "Products" %}</dt>
<dd>{{ question.items.all|join:"<br>" }}</dd>
<dt>{% trans "Type" %}</dt>
<dd>{{ question.get_type_display }}</dd>
<dt>{% trans "Internal reference" %}</dt>
<dd>{{ question.identifier }}</dd>
<dt>{% trans "Answer required" %}</dt>
<dd>{% if question.required %}{% trans "Yes" %}{% else %}{% trans "No" %}{% endif %}</dd>
<dt>{% trans "Time of question" %}</dt>
<dd>{% if not question.ask_during_checkin %}{% trans "Ticket purchase" %}{% else %}
{% trans "Check-in" %}{% endif %}</dd>
</dl>
</div>
<div class="panel-footer">
<form class="row" action="" method="get">
<div class="col-md-5 col-xs-12">
<select name="status" class="form-control">
<option value=""
{% if request.GET.status == "" %}selected="selected"{% endif %}>{% trans "All orders" %}</option>
<option value="p"
{% if request.GET.status == "p" %}selected="selected"{% endif %}>{% trans "Paid" %}</option>
<option value="n"
{% if request.GET.status == "n" %}selected="selected"{% endif %}>{% trans "Pending" %}</option>
<option value="np"
{% if request.GET.status == "np" or "status" not in request.GET %}selected="selected"{% endif %}>{% trans "Pending or paid" %}</option>
<option value="o"
{% if request.GET.status == "o" %}selected="selected"{% endif %}>{% trans "Pending (overdue)" %}</option>
<option value="e"
{% if request.GET.status == "e" %}selected="selected"{% endif %}>{% trans "Expired" %}</option>
<option value="ne"
{% if request.GET.status == "ne" %}selected="selected"{% endif %}>{% trans "Pending or expired" %}</option>
<option value="c"
{% if request.GET.status == "c" %}selected="selected"{% endif %}>{% trans "Canceled" %}</option>
<option value="r"
{% if request.GET.status == "r" %}selected="selected"{% endif %}>{% trans "Refunded" %}</option>
</select>
</div>
<div class="col-md-5 col-xs-12">
<select name="item" class="form-control">
<option value="">{% trans "All products" %}</option>
{% for item in items %}
<option value="{{ item.id }}"
{% if request.GET.item|add:0 == item.id %}selected="selected"{% endif %}>
{{ item.name }}
</option>
{% endfor %}
</select>
</div>
<div class="col-md-2 col-xs-12">
<button class="btn btn-block btn-primary" type="submit">{% trans "Filter" %}</button>
</div>
</form>
</div>
</div>
{% if not stats %}
<div class="panel panel-default">
<div class="panel-body empty-collection">
<p>
@@ -69,52 +88,62 @@
</p>
<a href="{% url "control:event.items.questions.edit" event=request.event.slug organizer=request.event.organizer.slug question=question.pk %}"
class="btn btn-primary btn-lg"><i class="fa fa-edit"></i> {% trans "Edit question" %}</a>
class="btn btn-primary btn-lg"><i class="fa fa-edit"></i> {% trans "Edit question" %}
</a>
{% endif %}
</div>
</div>
</div>
{% else %}
<div class="col-md-5 col-xs-12">
<div class="panel panel-default">
<div class="panel-body">
<div class="chart" id="question_chart" data-type="{{ question.type }}">
{% else %}
<div class="row">
<div class="col-md-6 col-xs-12">
<div class="panel panel-default">
<div class="panel-body">
<div class="chart" id="question_chart" data-type="{{ question.type }}">
</div>
<script type="application/json"
id="question-chart-data">{{ stats_json|escapejson }}</script>
</div>
</div>
</div>
<div class="col-md-6 col-xs-12">
<div class="panel panel-default">
<table class="table table-bordered table-hover">
<thead>
<tr>
<th>{% trans "Answer" %}</th>
<th>{% trans "Count" %}</th>
</tr>
</thead>
<tbody>
{% for stat in stats %}
<tr>
<td>
<a href="{% url "control:event.orders" event=request.event.slug organizer=request.event.organizer.slug %}?status=
{{ request.GET.status|default:"np" }}&item={{ request.GET.item }}&question={{ question.pk }}&answer=
{{ stat.alink|default:stat.answer|urlencode }}">
{{ stat.answer }}
</a>
</td>
<td>{{ stat.count }}</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
<script type="application/json" id="question-chart-data">{{ stats_json|escapejson }}</script>
</div>
</div>
</div>
<div class="col-md-5 col-xs-12">
<div class="panel panel-default">
<table class="table table-bordered table-hover">
<thead>
<tr>
<th>{% trans "Answer" %}</th>
<th>{% trans "Count" %}</th>
</tr>
</thead>
<tbody>
{% for stat in stats %}
<tr>
<td>
<a href="{% url "control:event.orders" event=request.event.slug organizer=request.event.organizer.slug %}?status=
{{ request.GET.status|default:"np" }}&item={{ request.GET.item }}&question={{ question.pk }}&answer=
{{ stat.alink|default:stat.answer|urlencode }}">
{{ stat.answer }}
</a>
</td>
<td>{{ stat.count }}</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
</div>
{% endif %}
{% endif %}
</div>
<div class="col-xs-12 col-lg-2">
<div class="panel panel-default">
<div class="panel-heading">
@@ -5,80 +5,99 @@
{% load eventsignal %}
{% block title %}{% blocktrans with name=quota.name %}Quota: {{ name }}{% endblocktrans %}{% endblock %}
{% block inside %}
<div class="panel panel-default panel-with-btn">
<div class="panel-heading">
{% 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 btn-sm pull-right">
<span class="fa fa-edit"></span>
{% trans "Edit quota" %}
</a>
{% endif %}
<h1 class="panel-title">
{% blocktrans with name=quota.name %}Quota: {{ name }}{% endblocktrans %}
<div class="clearfix"></div>
</h1>
</div>
</div>
{% if quota.subevent %}
<p>
<span class="fa fa-calendar"></span> {{ quota.subevent.name }} {{ quota.subevent.get_date_range_display }}
</p>
{% endif %}
<div class="row" id="quota-stats">
<div class="col-md-5 col-xs-12">
<div class="panel panel-default">
<div class="col-lg-10 col-xs-12">
<div class="panel panel-default panel-with-btn">
<div class="panel-heading">
<legend>{% trans "Usage overview" %}</legend>
{% 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 btn-sm pull-right">
<span class="fa fa-edit"></span>
{% trans "Edit quota" %}
</a>
{% endif %}
<h1 class="panel-title">
{% blocktrans with name=quota.name %}Quota: {{ name }}{% endblocktrans %}
<div class="clearfix"></div>
</h1>
</div>
<div class="panel-body">
<div class="chart" id="quota_chart">
</div>
<script type="application/json" id="quota-chart-data">{{ quota_chart_data|escapejson }}</script>
<dl class="dl-horizontal dl-left">
<dt>{% trans "Size" %}</dt>
<dd>{{ quota.size|default_if_none:"Unlimited" }}</dd>
<dt>{% trans "Products" %}</dt>
<dd>{{ quota.get_items_display|join:"<br>" }}</dd>
{% if quota.subevent %}
<dt>{% trans "Date" context "subevent" %}</dt>
<dd>{{ quota.subevent }}</dd>
{% endif %}
</dl>
</div>
</div>
</div>
<div class="col-md-5 col-xs-12">
<div class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Availability calculation" %}</legend>
</div>
<div class="panel-body">
{% if quota.subevent %}
<p>
<span class="fa fa-calendar"></span> {{ quota.subevent.name }}
{{ quota.subevent.get_date_range_display }}
</p>
{% endif %}
<div class="row" id="quota-stats">
<div class="col-md-6 col-xs-12">
<div class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Usage overview" %}</legend>
</div>
<div class="panel-body">
<div class="chart" id="quota_chart">
<div class="row">
<div class="col-xs-9">{% trans "Total quota" %}</div>
<div class="col-xs-3 text-right">
{% if quota.size == None %}{% trans "Infinite" %}{% else %}{{ quota.size }}{% endif %}
</div>
<script type="application/json"
id="quota-chart-data">{{ quota_chart_data|escapejson }}</script>
</div>
</div>
{% for row in quota_table_rows %}
<div class="row">
<div class="col-xs-9">{{ row.label }}</div>
<div class="col-xs-3 text-right"> {{ row.value }}</div>
</div>
<div class="col-md-6 col-xs-12">
<div class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Availability calculation" %}</legend>
</div>
{% endfor %}
<div class="row">
<div class="col-xs-9"><strong>{% trans "Current availability" %}</strong></div>
<div class="col-xs-3 text-right">
{% if quota.size == None %}{% trans "Infinite" %}{% else %}{{ avail.1 }}{% endif %}
<div class="panel-body">
<div class="row">
<div class="col-xs-9">{% trans "Total quota" %}</div>
<div class="col-xs-3 text-right">
{% if quota.size == None %}{% trans "Infinite" %}{% else %}
{{ quota.size }}{% endif %}
</div>
</div>
{% for row in quota_table_rows %}
<div class="row">
<div class="col-xs-9">{{ row.label }}</div>
<div class="col-xs-3 text-right"> {{ row.value }}</div>
</div>
{% endfor %}
<div class="row">
<div class="col-xs-9"><strong>{% trans "Current availability" %}</strong></div>
<div class="col-xs-3 text-right">
{% if quota.size == None %}{% trans "Infinite" %}{% else %}{{ avail.1 }}{% endif %}
</div>
</div>
{% if quota_overbooked > 0 %}
<div class="alert alert-warning">
{% blocktrans trimmed with num=quota_overbooked %}
This quota is currently overbooked by {{ num }} tickets.
{% endblocktrans %}
</div>
{% endif %}
{% if has_ignore_vouchers %}
<div class="alert alert-warning">
{% blocktrans trimmed %}
Your event contains vouchers that affect products covered by this quota and that
allow a user to buy products even if this quota is sold out.
{% endblocktrans %}
</div>
{% endif %}
</div>
</div>
{% if quota_overbooked > 0 %}
<div class="alert alert-warning">
{% blocktrans trimmed with num=quota_overbooked %}
This quota is currently overbooked by {{ num }} tickets.
{% endblocktrans %}
</div>
{% endif %}
{% if has_ignore_vouchers %}
<div class="alert alert-warning">
{% blocktrans trimmed %}
Your event contains vouchers that affect products covered by this quota and that
allow a user to buy products even if this quota is sold out.
{% endblocktrans %}
</div>
{% endif %}
</div>
</div>
</div>
@@ -3,17 +3,24 @@
{% load bootstrap3 %}
{% block title %}{% trans "Disable application" %}{% endblock %}
{% block content %}
<h1>{% trans "Disable application" %}</h1>
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<p>{% blocktrans %}Are you sure you want to disable the application <strong>{{ application }}</strong> permanently?{% endblocktrans %}</p>
<div class="form-group submit-group">
<a href="{% url "control:user.settings.oauth.apps" %}" class="btn btn-default btn-cancel">
{% trans "Cancel" %}
</a>
<button type="submit" class="btn btn-danger btn-save">
{% trans "Disable" %}
</button>
</div>
</form>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Disable application" %}</h1>
</div>
<div class="panel-body">
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<p>{% blocktrans %}Are you sure you want to disable the application <strong>{{ application }}</strong>
permanently?{% endblocktrans %}</p>
<div class="form-group submit-group">
<a href="{% url "control:user.settings.oauth.apps" %}" class="btn btn-default btn-cancel">
{% trans "Cancel" %}
</a>
<button type="submit" class="btn btn-danger btn-save">
{% trans "Disable" %}
</button>
</div>
</form>
</div>
</div>
{% endblock %}
@@ -3,48 +3,57 @@
{% load bootstrap3 %}
{% block title %}{% trans "Your applications" %}{% endblock %}
{% block content %}
<h1>{% trans "Your applications" %}</h1>
{% if applications %}
<div class="table-responsive">
<table class="table table-condensed table-hover">
<thead>
<tr>
<th>{% trans "Name" %}</th>
<th class="action-col-2"></th>
</tr>
</thead>
<tbody>
{% for application in applications %}
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Your applications" %}</h1>
</div>
{% if applications %}
<div class="table-responsive">
<table class="table table-condensed table-hover">
<thead>
<tr>
<td><strong><a href="{% url "control:user.settings.oauth.app" pk=application.pk %}">{{ application.name }}</a></strong></td>
<td class="text-right">
<a href="{% url "control:user.settings.oauth.app" pk=application.pk %}" class="btn btn-default btn-sm"><i class="fa fa-edit"></i></a>
<a href="{% url "control:user.settings.oauth.app.roll" pk=application.pk %}" class="btn btn-default btn-sm"><i class="fa fa-repeat"></i></a>
<a href="{% url "control:user.settings.oauth.app.disable" pk=application.pk %}" class="btn btn-danger btn-sm"><i class="fa fa-trash"></i></a>
</td>
<th>{% trans "Name" %}</th>
<th class="action-col-2"></th>
</tr>
{% endfor %}
</tbody>
</table>
</div>
<p>
<a class="btn btn-primary" href="{% url "control:user.settings.oauth.apps.register" %}">
<span class="fa fa-plus"></span>
{% trans "Create new application" %}
</a>
</p>
{% else %}
<div class="empty-collection">
<p>
{% blocktrans trimmed %}
No applications registered yet.
{% endblocktrans %}
</p>
</thead>
<tbody>
{% for application in applications %}
<tr>
<td><strong><a
href="{% url "control:user.settings.oauth.app" pk=application.pk %}">{{ application.name }}</a></strong>
</td>
<td class="text-right">
<a href="{% url "control:user.settings.oauth.app" pk=application.pk %}"
class="btn btn-default btn-sm"><i class="fa fa-edit"></i></a>
<a href="{% url "control:user.settings.oauth.app.roll" pk=application.pk %}"
class="btn btn-default btn-sm"><i class="fa fa-repeat"></i></a>
<a href="{% url "control:user.settings.oauth.app.disable" pk=application.pk %}"
class="btn btn-danger btn-sm"><i class="fa fa-trash"></i></a>
</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
<div class="panel-body">
<a class="btn btn-primary" href="{% url "control:user.settings.oauth.apps.register" %}">
<span class="fa fa-plus"></span>
{% trans "Create new application" %}
</a>
</div>
{% else %}
<div class="empty-collection panel-body">
<p>
{% blocktrans trimmed %}
No applications registered yet.
{% endblocktrans %}
</p>
<a href="{% url "control:user.settings.oauth.apps.register" %}"
class="btn btn-primary btn-lg">
{% trans "Register a new application" %}
</a>
</div>
{% endif %}
<a href="{% url "control:user.settings.oauth.apps.register" %}"
class="btn btn-primary btn-lg">
{% trans "Register a new application" %}
</a>
</div>
{% endif %}
</div>
{% endblock %}
@@ -3,14 +3,20 @@
{% load bootstrap3 %}
{% block title %}{% trans "Register a new application" %}{% endblock %}
{% block content %}
<h1>{% trans "Register a new application" %}</h1>
<form class="form-horizontal" method="post" action="">
{% csrf_token %}
{% bootstrap_form form layout='control' %}
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Save" %}
</button>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Register a new application" %}</h1>
</div>
</form>
<div class="panel-body">
<form class="form-horizontal" method="post" action="">
{% csrf_token %}
{% bootstrap_form form layout='control' %}
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Save" %}
</button>
</div>
</form>
</div>
</div>
{% endblock %}
@@ -3,17 +3,24 @@
{% load bootstrap3 %}
{% block title %}{% trans "Generate new application secret" %}{% endblock %}
{% block content %}
<h1>{% trans "Generate new application secret" %}</h1>
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<p>{% blocktrans %}Are you sure you want to generate a new client secret for the application <strong>{{ application }}</strong>?{% endblocktrans %}</p>
<div class="form-group submit-group">
<a href="{% url "control:user.settings.oauth.apps" %}" class="btn btn-default btn-cancel">
{% trans "Cancel" %}
</a>
<button type="submit" class="btn btn-danger btn-save">
{% trans "Roll secret" %}
</button>
</div>
</form>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Generate new application secret" %}</h1>
</div>
<div class="panel-body">
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<p>{% blocktrans %}Are you sure you want to generate a new client secret for the application
<strong>{{ application }}</strong>?{% endblocktrans %}</p>
<div class="form-group submit-group">
<a href="{% url "control:user.settings.oauth.apps" %}" class="btn btn-default btn-cancel">
{% trans "Cancel" %}
</a>
<button type="submit" class="btn btn-danger btn-save">
{% trans "Roll secret" %}
</button>
</div>
</form>
</div>
</div>
{% endblock %}
@@ -3,14 +3,20 @@
{% load bootstrap3 %}
{% block title %}{% trans "Update an application" %}{% endblock %}
{% block content %}
<h1>{% trans "Update an application" %}</h1>
<form class="form-horizontal" method="post" action="">
{% csrf_token %}
{% bootstrap_form form layout='control' %}
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Save" %}
</button>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Update an application" %}</h1>
</div>
</form>
<div class="panel-body">
<form class="form-horizontal" method="post" action="">
{% csrf_token %}
{% bootstrap_form form layout='control' %}
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Save" %}
</button>
</div>
</form>
</div>
</div>
{% endblock %}
@@ -3,17 +3,23 @@
{% load bootstrap3 %}
{% block title %}{% trans "Revoke access" %}{% endblock %}
{% block content %}
<h1>{% trans "Revoke access" %}</h1>
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<p>{% blocktrans %}Are you sure you want to revoke access to your account for the application <strong>{{ application }}</strong>?{% endblocktrans %}</p>
<div class="form-group submit-group">
<a href="{% url "control:user.settings.oauth.list" %}" class="btn btn-default btn-cancel">
{% trans "Cancel" %}
</a>
<button type="submit" class="btn btn-danger btn-save">
{% trans "Revoke" %}
</button>
</div>
</form>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Revoke access" %}</h1>
</div>
<div class="panel-body">
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<p>{% blocktrans %}Are you sure you want to revoke access to your account for the application <strong>{{ application }}</strong>?{% endblocktrans %}</p>
<div class="form-group submit-group">
<a href="{% url "control:user.settings.oauth.list" %}" class="btn btn-default btn-cancel">
{% trans "Cancel" %}
</a>
<button type="submit" class="btn btn-danger btn-save">
{% trans "Revoke" %}
</button>
</div>
</form>
</div>
</div>
{% endblock %}
@@ -3,12 +3,15 @@
{% load bootstrap3 %}
{% block title %}{% trans "Authorized applications" %}{% endblock %}
{% block content %}
<h1>{% trans "Authorized applications" %}</h1>
<p>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Authorized applications" %}</h1>
</div>
<div class="panel-body">
<a href="{% url "control:user.settings.oauth.apps" %}" class="btn btn-default">
{% trans "Manage your own apps" %}
</a>
</p>
</div>
{% if tokens %}
<div class="table-responsive">
<table class="table table-condensed table-hover table-quotas">
@@ -54,7 +57,7 @@
</table>
</div>
{% else %}
<div class="empty-collection">
<div class="empty-collection panel-body">
<p>
{% blocktrans trimmed %}
No applications have access to your pretix account.
@@ -62,4 +65,5 @@
</p>
</div>
{% endif %}
</div>
{% endblock %}
@@ -7,9 +7,6 @@
{% block title %}{% trans "Orders" %}{% endblock %}
{% block content %}
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Orders" %}</h1>
</div>
{% if not filter_form.filtered and orders|length == 0 %}
<div class="empty-collection panel-body">
<p>
@@ -3,19 +3,22 @@
{% load bootstrap3 %}
{% block title %}{% trans "Create a new organizer" %}{% endblock %}
{% block content %}
<h1>{% trans "Create a new organizer" %}</h1>
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
{% bootstrap_form_errors form %}
<fieldset>
<legend>{% trans "General information" %}</legend>
{% bootstrap_field form.name layout="horizontal" %}
{% bootstrap_field form.slug layout="horizontal" %}
</fieldset>
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Save" %}
</button>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Create a new organizer" %}</h1>
</div>
<div class="panel-body">
{% csrf_token %}
{% bootstrap_form_errors form %}
{% bootstrap_field form.name layout="horizontal" %}
{% bootstrap_field form.slug layout="horizontal" %}
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Save" %}
</button>
</div>
</div>
</div>
</form>
{% endblock %}
@@ -2,11 +2,18 @@
{% load i18n %}
{% load bootstrap3 %}
{% block inner %}
<div class="panel panel-default">
{% if events|length == 0 %}
<p>
<div class="panel-body empty-collection">
<em>{% trans "You currently do not have access to any events." %}</em>
</p>
</div>
{% else %}
<div class="panel-body">
<a href="{% url "control:events.add" %}" class="btn btn-default">
<span class="fa fa-plus"></span>
{% trans "Create a new event" %}
</a>
</div>
<table class="table table-condensed table-hover">
<thead>
<tr>
@@ -27,8 +34,5 @@
</tbody>
</table>
{% endif %}
<a href="{% url "control:events.add" %}" class="btn btn-default">
<span class="fa fa-plus"></span>
{% trans "Create a new event" %}
</a>
</div>
{% endblock %}
@@ -4,25 +4,32 @@
{% block inner %}
<form action="" method="post" class="form-horizontal" enctype="multipart/form-data">
{% csrf_token %}
<fieldset>
<legend>{% trans "Organizer page" %}</legend>
{% bootstrap_form_errors form %}
{% bootstrap_field form.locales layout="control" %}
{% bootstrap_field form.organizer_logo_image layout="control" %}
{% bootstrap_field form.organizer_homepage_text layout="control" %}
{% bootstrap_field form.event_list_type layout="control" %}
{% bootstrap_field form.organizer_link_back layout="control" %}
<fieldset class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Organizer page" %}</legend>
</div>
<div class="panel-body">
{% bootstrap_form_errors form %}
{% bootstrap_field form.locales layout="control" %}
{% bootstrap_field form.organizer_logo_image layout="control" %}
{% bootstrap_field form.organizer_homepage_text layout="control" %}
{% bootstrap_field form.event_list_type layout="control" %}
{% bootstrap_field form.organizer_link_back layout="control" %}
</div>
</fieldset>
<fieldset>
<legend>{% trans "Shop design" %}</legend>
<p class="help-block">
{% blocktrans trimmed %}
These settings will be used for the organizer page as well as for the default settings
for all events in this account that do not have their own design settings.
{% endblocktrans %}
</p>
{% bootstrap_field form.primary_color layout="control" %}
{% bootstrap_field form.primary_font layout="control" %}
<fieldset class="panel-default panel">
<div class="panel-heading">
<legend>{% trans "Shop design" %}</legend>
</div>
<div class="panel-body">
<p class="help-block">
{% blocktrans trimmed %}
These settings will be used for the organizer page as well as for the default settings
for all events in this account that do not have their own design settings.
{% endblocktrans %}
</p>
{% bootstrap_field form.primary_color layout="control" %}
{% bootstrap_field form.primary_font layout="control" %}
</fieldset>
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
@@ -4,80 +4,93 @@
{% load formset_tags %}
{% block title %}{% trans "Organizer" %}{% endblock %}
{% block content %}
<h1>{% trans "Organizer" %}</h1>
<form action="" method="post" class="form-horizontal" enctype="multipart/form-data">
{% csrf_token %}
<fieldset>
<legend>{% trans "General information" %}</legend>
{% bootstrap_form_errors form %}
{% bootstrap_field form.name layout="control" %}
{% bootstrap_field form.slug layout="control" %}
{% if form.domain %}
{% bootstrap_field form.domain layout="control" %}
{% endif %}
<fieldset class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "General information" %}</legend>
</div>
<div class="panel-body">
{% bootstrap_form_errors form %}
{% bootstrap_field form.name layout="control" %}
{% bootstrap_field form.slug layout="control" %}
{% if form.domain %}
{% bootstrap_field form.domain layout="control" %}
{% endif %}
</div>
</fieldset>
<fieldset>
<legend>{% trans "Other" %}</legend>
{% bootstrap_form_errors sform %}
{% bootstrap_field sform.organizer_info_text layout="control" %}
<fieldset class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Other" %}</legend>
</div>
<div class="panel-body">
{% bootstrap_form_errors sform %}
{% bootstrap_field sform.organizer_info_text layout="control" %}
</div>
</fieldset>
<fieldset>
<legend>{% trans "Event metadata (advanced)" %}</legend>
<p>
{% blocktrans trimmed %}
You can here define a set of metadata properties (i.e. variables) that you can later set for your
events and re-use in places like ticket layouts. This is an useful timesaver if you create lots and
lots of events.
{% endblocktrans %}
</p>
<div class="formset" data-formset data-formset-prefix="{{ formset.prefix }}">
{{ formset.management_form }}
{% bootstrap_formset_errors formset %}
<div data-formset-body>
{% for form in formset %}
<div class="row" data-formset-form>
<div class="sr-only">
{{ form.id }}
{% bootstrap_field form.DELETE form_group_class="" layout="inline" %}
</div>
<div class="col-md-5">
{% bootstrap_form_errors form %}
{% bootstrap_field form.name layout='inline' form_group_class="" %}
</div>
<div class="col-md-5 col-lg-6">
{% bootstrap_field form.default layout='inline' form_group_class="" %}
</div>
<div class="col-md-2 col-lg-1 text-right">
<button type="button" class="btn btn-danger" data-formset-delete-button>
<i class="fa fa-trash"></i></button>
</div>
</div>
{% endfor %}
</div>
<script type="form-template" data-formset-empty-form>
{% escapescript %}
<div class="row" data-formset-form>
<div class="sr-only">
{{ formset.empty_form.id }}
{% bootstrap_field formset.empty_form.DELETE form_group_class="" layout="inline" %}
</div>
<div class="col-md-5">
{% bootstrap_field formset.empty_form.name layout='inline' form_group_class="" %}
</div>
<div class="col-md-5 col-lg-6">
{% bootstrap_field formset.empty_form.default layout='inline' form_group_class="" %}
</div>
<div class="col-md-2 col-lg-1 text-right">
<button type="button" class="btn btn-danger" data-formset-delete-button>
<i class="fa fa-trash"></i></button>
</div>
</div>
{% endescapescript %}
</script>
<fieldset class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Event metadata (advanced)" %}</legend>
</div>
<div class="panel-body">
<p>
<button type="button" class="btn btn-default" data-formset-add>
<i class="fa fa-plus"></i> {% trans "Add property" %}</button>
{% blocktrans trimmed %}
You can here define a set of metadata properties (i.e. variables) that you can later set for
your
events and re-use in places like ticket layouts. This is an useful timesaver if you create lots
and
lots of events.
{% endblocktrans %}
</p>
<div class="formset" data-formset data-formset-prefix="{{ formset.prefix }}">
{{ formset.management_form }}
{% bootstrap_formset_errors formset %}
<div data-formset-body>
{% for form in formset %}
<div class="row" data-formset-form>
<div class="sr-only">
{{ form.id }}
{% bootstrap_field form.DELETE form_group_class="" layout="inline" %}
</div>
<div class="col-md-5">
{% bootstrap_form_errors form %}
{% bootstrap_field form.name layout='inline' form_group_class="" %}
</div>
<div class="col-md-5 col-lg-6">
{% bootstrap_field form.default layout='inline' form_group_class="" %}
</div>
<div class="col-md-2 col-lg-1 text-right">
<button type="button" class="btn btn-danger" data-formset-delete-button>
<i class="fa fa-trash"></i></button>
</div>
</div>
{% endfor %}
</div>
<script type="form-template" data-formset-empty-form>
{% escapescript %}
<div class="row" data-formset-form>
<div class="sr-only">
{{ formset.empty_form.id }}
{% bootstrap_field formset.empty_form.DELETE form_group_class="" layout="inline" %}
</div>
<div class="col-md-5">
{% bootstrap_field formset.empty_form.name layout='inline' form_group_class="" %}
</div>
<div class="col-md-5 col-lg-6">
{% bootstrap_field formset.empty_form.default layout='inline' form_group_class="" %}
</div>
<div class="col-md-2 col-lg-1 text-right">
<button type="button" class="btn btn-danger" data-formset-delete-button>
<i class="fa fa-trash"></i></button>
</div>
</div>
{% endescapescript %}
</script>
<p>
<button type="button" class="btn btn-default" data-formset-add>
<i class="fa fa-plus"></i> {% trans "Add property" %}</button>
</p>
</div>
</div>
</fieldset>
<div class="form-group submit-group">
@@ -5,32 +5,37 @@
{% load eventurl %}
{% block title %}{% trans "Organizers" %}{% endblock %}
{% block content %}
<h1>{% trans "Organizers" %}</h1>
<p>{% trans "The list below shows all organizer accounts you have administrative access to." %}</p>
<form class="row filter-form" action="" method="get">
<div class="col-md-10 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.query layout='inline' %}
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Organizers" %}</h1>
</div>
<div class="col-md-2 col-sm-6 col-xs-12">
<button class="btn btn-primary btn-block" type="submit">
<span class="fa fa-filter"></span>
<span class="hidden-md">
<div class="panel-body">{% trans "The list below shows all organizer accounts you have administrative access to." %}</div>
</div>
<div class="panel panel-default">
<form class="row filter-form panel-body" action="" method="get">
<div class="col-md-10 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.query layout='inline' %}
</div>
<div class="col-md-2 col-sm-6 col-xs-12">
<button class="btn btn-primary btn-block" type="submit">
<span class="fa fa-filter"></span>
<span class="hidden-md">
{% trans "Filter" %}
</span>
</button>
</div>
</form>
{% if staff_session %}
<p>
<a href="{% url "control:organizers.add" %}" class="btn btn-default">
<span class="fa fa-plus"></span>
{% trans "Create a new organizer" %}
</a>
</p>
{% endif %}
<table class="table table-condensed table-hover">
<thead>
<tr>
</button>
</div>
</form>
{% if staff_session %}
<div class="panel-body">
<a href="{% url "control:organizers.add" %}" class="btn btn-default">
<span class="fa fa-plus"></span>
{% trans "Create a new organizer" %}
</a>
</div>
{% endif %}
<table class="table table-condensed table-hover">
<thead>
<tr>
<th>
{% trans "Organizer name" %}
<a href="?{% url_replace request 'ordering' '-name' %}"><i class="fa fa-caret-down"></i></a>
@@ -41,18 +46,21 @@
<a href="?{% url_replace request 'ordering' '-slug' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'slug' %}"><i class="fa fa-caret-up"></i></a>
</th>
</tr>
</thead>
<tbody>
{% for o in organizers %}
<tr>
<td><strong>
<a href="{% url "control:organizer" organizer=o.slug %}">{{ o.name }}</a>
</strong></td>
<td>{{ o.slug }}</td>
</tr>
{% endfor %}
</tbody>
</table>
{% include "pretixcontrol/pagination.html" %}
</tr>
</thead>
<tbody>
{% for o in organizers %}
<tr>
<td><strong>
<a href="{% url "control:organizer" organizer=o.slug %}">{{ o.name }}</a>
</strong></td>
<td>{{ o.slug }}</td>
</tr>
{% endfor %}
</tbody>
</table>
<div class="panel-footer">
{% include "pretixcontrol/pagination.html" %}
</div>
</div>
{% endblock %}
@@ -2,28 +2,37 @@
{% load i18n %}
{% load bootstrap3 %}
{% block inner %}
<h2>{% trans "Delete team:" %} {{ team.name }}</h2>
{% if not possible %}
<p>{% blocktrans %}You cannot delete the team because there would be no one left who could change team permissions afterwards.{% endblocktrans %}</p>
<div class="form-group submit-group">
<a href="{% url "control:organizer.teams" organizer=request.organizer.slug %}" class="btn btn-default btn-cancel">
{% trans "Cancel" %}
</a>
<div class="clearfix"></div>
<div class="panel panel-default">
<div class="panel-heading">
<h2 class="panel-titlte">{% trans "Delete team:" %} {{ team.name }}</h2>
</div>
{% else %}
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<p>{% blocktrans %}Are you sure you want to delete the team?{% endblocktrans %}
</p>
<div class="form-group submit-group">
<a href="{% url "control:organizer.teams" organizer=request.organizer.slug%}" class="btn btn-default btn-cancel">
{% trans "Cancel" %}
</a>
<button type="submit" class="btn btn-danger btn-save">
{% trans "Delete" %}
</button>
</div>
</form>
{% endif %}
<div class="panel-body">
{% if not possible %}
<p>{% blocktrans %}You cannot delete the team because there would be no one left who could change team
permissions afterwards.{% endblocktrans %}</p>
<div class="form-group submit-group">
<a href="{% url "control:organizer.teams" organizer=request.organizer.slug %}"
class="btn btn-default btn-cancel">
{% trans "Cancel" %}
</a>
<div class="clearfix"></div>
</div>
{% else %}
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<p>{% blocktrans %}Are you sure you want to delete the team?{% endblocktrans %}
</p>
<div class="form-group submit-group">
<a href="{% url "control:organizer.teams" organizer=request.organizer.slug %}"
class="btn btn-default btn-cancel">
{% trans "Cancel" %}
</a>
<button type="submit" class="btn btn-danger btn-save">
{% trans "Delete" %}
</button>
</div>
</form>
{% endif %}
</div>
</div>
{% endblock %}
@@ -2,40 +2,53 @@
{% load i18n %}
{% load bootstrap3 %}
{% block inner %}
{% if team %}
<h2>{% trans "Team:" %} {{ team.name }}</h2>
{% else %}
<h2>{% trans "Create a new team" %}</h2>
<p>
{% blocktrans trimmed %}
You will be able to add team members in the next step.
{% endblocktrans %}
</p>
{% endif %}
<form class="form-horizontal" action="" method="post">
{% csrf_token %}
{% bootstrap_form_errors form %}
<fieldset>
<legend>{% trans "General information" %}</legend>
{% bootstrap_field form.name layout="control" %}
<fieldset class="panel panel-default">
<div class="panel-heading">
{% if team %}
<h2 class="panel-title">{% trans "Team:" %} {{ team.name }}</h2>
{% else %}
<h2 class="panel-title">{% trans "Create a new team" %}</h2>
{% endif %}
</div>
<div class="panel-body">
{% if not team %}
<p>
{% blocktrans trimmed %}
You will be able to add team members in the next step.
{% endblocktrans %}
</p>
{% endif %}
{% bootstrap_field form.name layout="control" %}
</div>
</fieldset>
<fieldset>
<legend>{% trans "Organizer permissions" %}</legend>
{% bootstrap_field form.can_create_events layout="control" %}
{% bootstrap_field form.can_change_teams layout="control" %}
{% bootstrap_field form.can_change_organizer_settings layout="control" %}
<fieldset class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Organizer permissions" %}</legend>
</div>
<div class="panel-body">
{% bootstrap_field form.can_create_events layout="control" %}
{% bootstrap_field form.can_change_teams layout="control" %}
{% bootstrap_field form.can_change_organizer_settings layout="control" %}
</div>
</fieldset>
<fieldset>
<legend>{% trans "Event permissions" %}</legend>
<fieldset class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Event permissions" %}</legend>
</div>
<div class="panel-body">
{% bootstrap_field form.all_events layout="control" %}
{% bootstrap_field form.limit_events layout="control" %}
{% bootstrap_field form.can_change_event_settings layout="control" %}
{% bootstrap_field form.can_change_items layout="control" %}
{% bootstrap_field form.can_view_orders layout="control" %}
{% bootstrap_field form.can_change_orders layout="control" %}
{% bootstrap_field form.can_view_vouchers layout="control" %}
{% bootstrap_field form.can_change_vouchers layout="control" %}
{% bootstrap_field form.all_events layout="control" %}
{% bootstrap_field form.limit_events layout="control" %}
{% bootstrap_field form.can_change_event_settings layout="control" %}
{% bootstrap_field form.can_change_items layout="control" %}
{% bootstrap_field form.can_view_orders layout="control" %}
{% bootstrap_field form.can_change_orders layout="control" %}
{% bootstrap_field form.can_view_vouchers layout="control" %}
{% bootstrap_field form.can_change_vouchers layout="control" %}
</div>
</fieldset>
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
@@ -2,124 +2,137 @@
{% load i18n %}
{% load bootstrap3 %}
{% block inner %}
<h2>
{% trans "Team:" %} {{ team.name }}
<a href="{% url "control:organizer.team.edit" organizer=organizer.slug team=team.pk %}"
class="btn btn-default">
<span class="fa fa-edit"></span>
{% trans "Edit" %}
</a>
</h2>
<h3>{% trans "Team members" %}</h3>
<div class="panel panel-default">
<div class="panel-heading">
<a href="{% url "control:organizer.team.edit" organizer=organizer.slug team=team.pk %}"
class="btn btn-default pull-right">
<span class="fa fa-edit"></span>
{% trans "Edit" %}
</a>
<h2 class="panel-title">
{% trans "Team:" %} {{ team.name }}
</h2>
</div>
</div>
<form action="" method="post">
{% csrf_token %}
<!-- Trick browsers into taking this as a default -->
<button type="submit" class="btn btn-primary btn-sm btn-block nearly-gone"></button>
<table class="table table-condensed table-hover">
<thead>
<tr>
<th>{% trans "Member" %}</th>
<th width="150"></th>
</tr>
</thead>
<tbody>
{% for u in team.members.all %}
<div class="panel panel-default">
<div class="panel-heading">
<h3 class="panel-title">{% trans "Team members" %}</h3>
</div>
<button type="submit" class="btn btn-primary btn-sm btn-block nearly-gone"></button>
<table class="table table-condensed table-hover">
<thead>
<tr>
<th>{% trans "Member" %}</th>
<th width="150"></th>
</tr>
</thead>
<tbody>
{% for u in team.members.all %}
<tr>
<td>
{{ u.email }}
{% if u.require_2fa %}
<span class="fa fa-shield text-success" data-toggle="tooltip"
title="{% trans "Two-factor authentication enabled" %}">
</span>
{% else %}
<span class="fa fa-shield disabled" data-toggle="tooltip"
title="{% trans "Two-factor authentication disabled" %}">
</span>
{% endif %}
</td>
<td class="text-right">
<button type="submit" name="remove-member" value="{{ u.id }}"
class="btn btn-danger btn-sm btn-block">
<i class="fa fa-times"></i> {% trans "Remove" %}
</button>
</td>
</tr>
{% endfor %}
{% for i in team.invites.all %}
<tr>
<td>
{{ i.email }}
<span class="fa fa-envelope-o" data-toggle="tooltip"
title="{% trans "invited, pending response" %}"></span>
</td>
<td class="text-right">
<button type="submit" name="remove-invite" value="{{ i.id }}"
class="btn btn-danger btn-sm btn-block">
<i class="fa fa-times"></i> {% trans "Remove" %}
</button>
</td>
</tr>
{% endfor %}
</tbody>
<tfoot>
<tr>
<td>
{{ u.email }}
{% if u.require_2fa %}
<span class="fa fa-shield text-success" data-toggle="tooltip"
title="{% trans "Two-factor authentication enabled" %}">
</span>
{% else %}
<span class="fa fa-shield disabled" data-toggle="tooltip"
title="{% trans "Two-factor authentication disabled" %}">
</span>
{% endif %}
{% bootstrap_field add_form.user layout='inline' %}
</td>
<td class="text-right">
<button type="submit" name="remove-member" value="{{ u.id }}"
class="btn btn-danger btn-sm btn-block">
<i class="fa fa-times"></i> {% trans "Remove" %}
<button type="submit" class="btn btn-primary btn-sm btn-block">
<i class="fa fa-plus"></i> {% trans "Add" %}
</button>
</td>
</tr>
{% endfor %}
{% for i in team.invites.all %}
<tr>
<td>
{{ i.email }}
<span class="fa fa-envelope-o" data-toggle="tooltip"
title="{% trans "invited, pending response" %}"></span>
</td>
<td class="text-right">
<button type="submit" name="remove-invite" value="{{ i.id }}"
class="btn btn-danger btn-sm btn-block">
<i class="fa fa-times"></i> {% trans "Remove" %}
</button>
</td>
</tr>
{% endfor %}
</tbody>
<tfoot>
<tr>
<td>
{% bootstrap_field add_form.user layout='inline' %}<br>
{% blocktrans trimmed %}
To add a new user, you can enter their email address here. If they already have a
pretix account, they will immediately be added to the event. Otherwise, they will
be sent an email with an invitation.
{% endblocktrans %}
</td>
<td class="text-right">
<button type="submit" class="btn btn-primary btn-sm btn-block">
<i class="fa fa-plus"></i> {% trans "Add" %}
</button>
</td>
</tr>
</tfoot>
</table>
</tfoot>
</table>
<div class="panel-footer">
{% blocktrans trimmed %}
To add a new user, you can enter their email address here. If they already have a
pretix account, they will immediately be added to the event. Otherwise, they will
be sent an email with an invitation.
{% endblocktrans %}
</div>
</div>
</form>
<h3>{% trans "API tokens" %}</h3>
<form action="" method="post">
{% csrf_token %}
<!-- Trick browsers into taking this as a default -->
<button type="submit" class="btn btn-primary btn-sm btn-block nearly-gone"></button>
<table class="table table-condensed table-hover">
<thead>
<tr>
<th>{% trans "Name" %}</th>
<th width="150"></th>
</tr>
</thead>
<tbody>
{% for t in team.active_tokens %}
<div class="panel-default panel">
<div class="panel-heading">
<h3 class="panel-title">{% trans "API tokens" %}</h3>
</div>
<table class="table table-condensed table-hover">
<thead>
<tr>
<th>{% trans "Name" %}</th>
<th width="150"></th>
</tr>
</thead>
<tbody>
{% for t in team.active_tokens %}
<tr>
<td>
{{ t.name }}
</td>
<td class="text-right">
<button type="submit" name="remove-token" value="{{ t.id }}"
class="btn btn-danger btn-sm btn-block">
<i class="fa fa-times"></i> {% trans "Remove" %}
</button>
</td>
</tr>
{% endfor %}
</tbody>
<tfoot>
<tr>
<td>
{{ t.name }}
{% bootstrap_field add_token_form.name layout='inline' %}<br>
</td>
<td class="text-right">
<button type="submit" name="remove-token" value="{{ t.id }}"
class="btn btn-danger btn-sm btn-block">
<i class="fa fa-times"></i> {% trans "Remove" %}
<button type="submit" class="btn btn-primary btn-sm btn-block">
<i class="fa fa-plus"></i> {% trans "Add" %}
</button>
</td>
</tr>
{% endfor %}
</tbody>
<tfoot>
<tr>
<td>
{% bootstrap_field add_token_form.name layout='inline' %}<br>
</td>
<td class="text-right">
<button type="submit" class="btn btn-primary btn-sm btn-block">
<i class="fa fa-plus"></i> {% trans "Add" %}
</button>
</td>
</tr>
</tfoot>
</table>
</tfoot>
</table>
</div>
</form>
<div class="panel panel-default">
<div class="panel-heading">
@@ -2,55 +2,56 @@
{% load i18n %}
{% load bootstrap3 %}
{% block inner %}
<p>
{% trans "The list below shows all teams that exist within this organizer." %}
</p>
<a href="{% url "control:organizer.team.add" organizer=request.organizer.slug %}" class="btn btn-default">
<span class="fa fa-plus"></span>
{% trans "Create a new team" %}
</a>
<table class="table table-condensed table-hover">
<thead>
<tr>
<th>{% trans "Team name" %}</th>
<th>{% trans "Members" %}</th>
<th>{% trans "Events" %}</th>
<th></th>
</tr>
</thead>
<tbody>
{% for t in teams %}
<div class="panel panel-default">
<div class="panel-body">
<a href="{% url "control:organizer.team.add" organizer=request.organizer.slug %}" class="btn btn-default">
<span class="fa fa-plus"></span>
{% trans "Create a new team" %}
</a>
</div>
<table class="table table-condensed table-hover">
<thead>
<tr>
<td><strong>
<a href="{% url "control:organizer.team" organizer=request.organizer.slug team=t.id %}">
{{ t.name }}
</a>
</strong></td>
<td>
{{ t.memcount }}
{% if t.invcount %}
{% blocktrans trimmed with count=t.invcount %}
+ {{ count }} invited
{% endblocktrans %}
{% endif %}
</td>
<td>
{% if t.all_events %}
{% trans "All" %}
{% else %}
{{ t.eventcount }}
{% endif %}
</td>
<td class="text-right">
<a href="{% url "control:organizer.team" organizer=request.organizer.slug team=t.id %}"
class="btn btn-default btn-sm"><i class="fa fa-list"></i></a>
<a href="{% url "control:organizer.team.edit" organizer=request.organizer.slug team=t.id %}"
class="btn btn-default btn-sm"><i class="fa fa-edit"></i></a>
<a href="{% url "control:organizer.team.delete" organizer=request.organizer.slug team=t.id %}"
class="btn btn-danger btn-sm"><i class="fa fa-trash"></i></a>
</td>
<th>{% trans "Team name" %}</th>
<th>{% trans "Members" %}</th>
<th>{% trans "Events" %}</th>
<th></th>
</tr>
{% endfor %}
</tbody>
</table>
</thead>
<tbody>
{% for t in teams %}
<tr>
<td><strong>
<a href="{% url "control:organizer.team" organizer=request.organizer.slug team=t.id %}">
{{ t.name }}
</a>
</strong></td>
<td>
{{ t.memcount }}
{% if t.invcount %}
{% blocktrans trimmed with count=t.invcount %}
+ {{ count }} invited
{% endblocktrans %}
{% endif %}
</td>
<td>
{% if t.all_events %}
{% trans "All" %}
{% else %}
{{ t.eventcount }}
{% endif %}
</td>
<td class="text-right">
<a href="{% url "control:organizer.team" organizer=request.organizer.slug team=t.id %}"
class="btn btn-default btn-sm"><i class="fa fa-list"></i></a>
<a href="{% url "control:organizer.team.edit" organizer=request.organizer.slug team=t.id %}"
class="btn btn-default btn-sm"><i class="fa fa-edit"></i></a>
<a href="{% url "control:organizer.team.delete" organizer=request.organizer.slug team=t.id %}"
class="btn btn-danger btn-sm"><i class="fa fa-trash"></i></a>
</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
{% endblock %}
@@ -11,12 +11,6 @@
<link type="text/css" rel="stylesheet" href="{% url "control:pdf.css" organizer=request.organizer.slug event=request.event.slug %}">
{% endblock %}
{% block content %}
<h1>
{% trans "PDF Editor" %}
{% if title %}
<small>{{ title }}</small>
{% endif %}
</h1>
<script type="application/json" id="editor-data">
{{ layout|safe }}
@@ -27,25 +21,30 @@
<div class="panel-heading">
<div class="pull-right">
<div class="btn-group">
<button type="button" class="btn btn-default btn-xs" id="toolbox-source"
<button type="button" class="btn btn-default btn-sm" id="toolbox-source"
title="{% trans "Code" %}">
<span class="fa fa-code"></span>
</button>
<button type="button" class="btn btn-default btn-xs" id="toolbox-paste"
<button type="button" class="btn btn-default btn-sm" id="toolbox-paste"
title="{% trans "Paste" %}">
<span class="fa fa-paste"></span>
</button>
<button type="button" class="btn btn-default btn-xs" id="toolbox-undo"
<button type="button" class="btn btn-default btn-sm" id="toolbox-undo"
title="{% trans "Undo" %}">
<span class="fa fa-undo"></span>
</button>
<button type="button" class="btn btn-default btn-xs" id="toolbox-redo"
<button type="button" class="btn btn-default btn-sm" id="toolbox-redo"
title="{% trans "Redo" %}">
<span class="fa fa-repeat"></span>
</button>
</div>
</div>
{% trans "Editor" %}
<h1 class="panel-title">
{% trans "PDF Editor" %}
{% if title %}
<small>{{ title }}</small>
{% endif %}
</h1>
</div>
<div class="panel-body">
<div id="editor-canvas-area">
@@ -6,83 +6,89 @@
{% load bootstrap3 %}
{% block title %}{% trans "Order search" %}{% endblock %}
{% block content %}
<h1>{% trans "Order search" %}</h1>
<form class="row filter-form" action="" method="get">
<div class="col-md-3 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.query layout='inline' %}
</div>
<div class="col-md-2 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.status layout='inline' %}
</div>
<div class="col-md-3 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.organizer layout='inline' %}
</div>
<div class="col-md-2 col-xs-6">
{% bootstrap_field filter_form.provider layout='inline' %}
</div>
<div class="col-md-2 col-sm-6 col-xs-12">
<button class="btn btn-primary btn-block" type="submit">
<span class="fa fa-filter"></span>
<span class="hidden-md">
<div class="panel panel-default">
<div class="panel-body">
<form class="row filter-form" action="" method="get">
<div class="col-md-3 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.query layout='inline' %}
</div>
<div class="col-md-2 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.status layout='inline' %}
</div>
<div class="col-md-3 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.organizer layout='inline' %}
</div>
<div class="col-md-2 col-xs-6">
{% bootstrap_field filter_form.provider layout='inline' %}
</div>
<div class="col-md-2 col-sm-6 col-xs-12">
<button class="btn btn-primary btn-block" type="submit">
<span class="fa fa-filter"></span>
<span class="hidden-md">
{% trans "Filter" %}
</span>
</button>
</button>
</div>
</form>
</div>
</form>
<div class="table-responsive">
<table class="table table-condensed table-hover">
<thead>
<tr>
<th>{% trans "Order code" %}
<a href="?{% url_replace request 'ordering' '-code' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'code' %}"><i class="fa fa-caret-up"></i></a></th>
<th>{% trans "Event" %}
<a href="?{% url_replace request 'ordering' '-event' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'event' %}"><i class="fa fa-caret-up"></i></a></th>
<th>{% trans "User" %}
<a href="?{% url_replace request 'ordering' '-email' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'email' %}"><i class="fa fa-caret-up"></i></a></th>
<th>{% trans "Order date" %}
<a href="?{% url_replace request 'ordering' '-datetime' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'datetime' %}"><i class="fa fa-caret-up"></i></a></th>
<th class="text-right">{% trans "Order total" %}
<a href="?{% url_replace request 'ordering' '-total' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'total' %}"><i class="fa fa-caret-up"></i></a></th>
<th class="text-right">{% trans "Status" %}
<a href="?{% url_replace request 'ordering' '-status' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'status' %}"><i class="fa fa-caret-up"></i></a></th>
</tr>
</thead>
<tbody>
{% for o in orders %}
<div class="table-responsive">
<table class="table table-condensed table-hover">
<thead>
<tr>
<td>
<strong>
<a href="{% url "control:event.order" event=o.event.slug organizer=o.event.organizer.slug code=o.code %}">
{{ o.event.slug|upper }}-{{ o.code }}
</a>
</strong>
</td>
<td>{{ o.event.name }}</td>
<td>
{{ o.email|default_if_none:"" }}
{% if o.invoice_address.name %}
<br>{{ o.invoice_address.name }}
{% endif %}
</td>
<td>{{ o.datetime|date:"SHORT_DATETIME_FORMAT" }}</td>
<td class="text-right">{{ o.total|money:o.event.currency }}</td>
<td class="text-right">{% include "pretixcontrol/orders/fragment_order_status.html" with order=o %}</td>
<th>{% trans "Order code" %}
<a href="?{% url_replace request 'ordering' '-code' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'code' %}"><i class="fa fa-caret-up"></i></a></th>
<th>{% trans "Event" %}
<a href="?{% url_replace request 'ordering' '-event' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'event' %}"><i class="fa fa-caret-up"></i></a></th>
<th>{% trans "User" %}
<a href="?{% url_replace request 'ordering' '-email' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'email' %}"><i class="fa fa-caret-up"></i></a></th>
<th>{% trans "Order date" %}
<a href="?{% url_replace request 'ordering' '-datetime' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'datetime' %}"><i class="fa fa-caret-up"></i></a>
</th>
<th class="text-right">{% trans "Order total" %}
<a href="?{% url_replace request 'ordering' '-total' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'total' %}"><i class="fa fa-caret-up"></i></a></th>
<th class="text-right">{% trans "Status" %}
<a href="?{% url_replace request 'ordering' '-status' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'status' %}"><i class="fa fa-caret-up"></i></a></th>
</tr>
{% empty %}
<tr>
<td colspan="6" class="text-center"><em>
{% trans "We couldn't find any orders that you have access to and that match your search query." %}
</em></td>
</tr>
{% endfor %}
</tbody>
</table>
</thead>
<tbody>
{% for o in orders %}
<tr>
<td>
<strong>
<a href="{% url "control:event.order" event=o.event.slug organizer=o.event.organizer.slug code=o.code %}">
{{ o.event.slug|upper }}-{{ o.code }}
</a>
</strong>
</td>
<td>{{ o.event.name }}</td>
<td>
{{ o.email|default_if_none:"" }}
{% if o.invoice_address.name %}
<br>{{ o.invoice_address.name }}
{% endif %}
</td>
<td>{{ o.datetime|date:"SHORT_DATETIME_FORMAT" }}</td>
<td class="text-right">{{ o.total|money:o.event.currency }}</td>
<td class="text-right">{% include "pretixcontrol/orders/fragment_order_status.html" with order=o %}</td>
</tr>
{% empty %}
<tr>
<td colspan="6" class="text-center"><em>
{% trans "We couldn't find any orders that you have access to and that match your search query." %}
</em></td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
<div class="panel-footer">
{% include "pretixcontrol/pagination_huge.html" %}
</div>
</div>
{% include "pretixcontrol/pagination_huge.html" %}
{% endblock %}
@@ -11,7 +11,6 @@
</h1>
</div>
<div class="panel-body">
<p>
{% blocktrans trimmed %}
This feature allows you to remove personal data from this event. You will first select what kind of
@@ -6,7 +6,6 @@
{% load eventsignal %}
{% block title %}{% trans "Date" context "subevent" %}{% endblock %}
{% block content %}
<h1>{% trans "Create multiple dates" context "subevent" %}</h1>
<form action="" method="post" class="form-horizontal" id="subevent-bulk-create-form">
{% csrf_token %}
{% bootstrap_form_errors form %}
@@ -16,10 +15,8 @@
<div class="row">
<div class="col-md-8">
<fieldset>
<legend>{% trans "Dates" context "subevent" %}</legend>
<div class="formset" data-formset data-formset-prefix="{{ rrule_formset.prefix }}"
id="rrule-formset">
id="rrule-formset">
{{ rrule_formset.management_form }}
{% bootstrap_formset_errors rrule_formset %}
<div data-formset-body>
@@ -34,7 +31,7 @@
{% trans "Repetition rule" %}
</div>
<div class="col-md-2 text-right">
<button type="button" class="btn btn-danger btn-xs"
<button type="button" class="btn btn-danger btn-sm"
data-formset-delete-button>
<i class="fa fa-trash"></i></button>
</div>
@@ -145,7 +142,7 @@
{% trans "Repetition rule" %}
</div>
<div class="col-md-2 text-right">
<button type="button" class="btn btn-danger btn-xs"
<button type="button" class="btn btn-danger btn-sm"
data-formset-delete-button>
<i class="fa fa-trash"></i></button>
</div>
@@ -253,10 +250,14 @@
</fieldset>
</div>
<div class="col-md-4">
<fieldset>
<legend>{% trans "Preview" context "subevent" %}</legend>
<ul id="rrule-preview">
</ul>
<fieldset class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Preview" context "subevent" %}</legend>
</div>
<div class="panel-body">
<ul id="rrule-preview">
</ul>
</div>
</fieldset>
</div>
</div>
@@ -4,53 +4,55 @@
{% load urlreplace %}
{% block title %}{% trans "Dates" context "subevent" %}{% endblock %}
{% block content %}
<h1>{% trans "Dates" context "subevent" %}</h1>
{% if subevents|length == 0 and not filter_form.filtered %}
<div class="empty-collection">
<p>
{% blocktrans trimmed %}
You haven't created any dates for this event series yet.
{% endblocktrans %}
</p>
<div class="panel-default">
<div class="empty-collection panel-body">
<p>
{% blocktrans trimmed %}
You haven't created any dates for this event series yet.
{% endblocktrans %}
</p>
<a href="{% url "control:event.subevents.add" organizer=request.event.organizer.slug event=request.event.slug %}"
class="btn btn-primary btn-lg"><i class="fa fa-plus"></i>
{% trans "Create a new date" context "subevent" %}</a>
<a href="{% url "control:event.subevents.bulk" organizer=request.event.organizer.slug event=request.event.slug %}"
class="btn btn-primary btn-lg"><i class="fa fa-plus"></i>
{% trans "Create many new dates" context "subevent" %}</a>
<a href="{% url "control:event.subevents.add" organizer=request.event.organizer.slug event=request.event.slug %}"
class="btn btn-primary btn-lg"><i class="fa fa-plus"></i>
{% trans "Create a new date" context "subevent" %}</a>
<a href="{% url "control:event.subevents.bulk" organizer=request.event.organizer.slug event=request.event.slug %}"
class="btn btn-primary btn-lg"><i class="fa fa-plus"></i>
{% trans "Create many new dates" context "subevent" %}</a>
</div>
</div>
{% else %}
<form class="row filter-form" action="" method="get">
<div class="col-md-4 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.query layout='inline' %}
</div>
<div class="col-md-3 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.status layout='inline' %}
</div>
<div class="col-md-3 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.weekday layout='inline' %}
</div>
<div class="col-md-2 col-sm-6 col-xs-12">
<button class="btn btn-primary btn-block" type="submit">
<span class="fa fa-filter"></span>
<span class="hidden-md">
<div class="panel panel-default">
<form class="row filter-form panel-body" action="" method="get">
<div class="col-md-4 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.query layout='inline' %}
</div>
<div class="col-md-3 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.status layout='inline' %}
</div>
<div class="col-md-3 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.weekday layout='inline' %}
</div>
<div class="col-md-2 col-sm-6 col-xs-12">
<button class="btn btn-primary btn-block" type="submit">
<span class="fa fa-filter"></span>
<span class="hidden-md">
{% trans "Filter" %}
</span>
</button>
</button>
</div>
</form>
<div class="panel-body">
<a href="{% url "control:event.subevents.add" organizer=request.event.organizer.slug event=request.event.slug %}"
class="btn btn-default"><i class="fa fa-plus"></i>
{% trans "Create a new date" context "subevent" %}</a>
<a href="{% url "control:event.subevents.bulk" organizer=request.event.organizer.slug event=request.event.slug %}"
class="btn btn-default"><i class="fa fa-plus"></i>
{% trans "Create many new dates" context "subevent" %}</a>
</div>
</form>
<p>
<a href="{% url "control:event.subevents.add" organizer=request.event.organizer.slug event=request.event.slug %}"
class="btn btn-default"><i class="fa fa-plus"></i>
{% trans "Create a new date" context "subevent" %}</a>
<a href="{% url "control:event.subevents.bulk" organizer=request.event.organizer.slug event=request.event.slug %}"
class="btn btn-default"><i class="fa fa-plus"></i>
{% trans "Create many new dates" context "subevent" %}</a>
</p>
<form action="{% url "control:event.subevents.bulkaction" organizer=request.event.organizer.slug event=request.event.slug %}" method="post">
{% csrf_token %}
<div class="table-responsive">
<form action="{% url "control:event.subevents.bulkaction" organizer=request.event.organizer.slug event=request.event.slug %}"
method="post" class="table-responsive">
{% csrf_token %}
<table class="table table-hover table-quotas">
<thead>
<tr>
@@ -64,17 +66,22 @@
</th>
<th>
{% trans "Begin" %}
<a href="?{% url_replace request 'ordering' '-date_from' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'date_from' %}"><i class="fa fa-caret-up"></i></a>
<a href="?{% url_replace request 'ordering' '-date_from' %}"><i
class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'date_from' %}"><i
class="fa fa-caret-up"></i></a>
</th>
<th>
{% trans "Paid tickets per quota" %}
<a href="?{% url_replace request 'ordering' '-sum_tickets_paid' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'sum_tickets_paid' %}"><i class="fa fa-caret-up"></i></a>
<a href="?{% url_replace request 'ordering' '-sum_tickets_paid' %}"><i
class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'sum_tickets_paid' %}"><i
class="fa fa-caret-up"></i></a>
</th>
<th>
{% trans "Status" %}
<a href="?{% url_replace request 'ordering' '-active' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' '-active' %}"><i
class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'active' %}"><i class="fa fa-caret-up"></i></a>
</th>
<th></th>
@@ -89,7 +96,8 @@
{% endif %}
</td>
<td>
<strong><a href="{% url "control:event.subevent" organizer=request.event.organizer.slug event=request.event.slug subevent=s.id %}">
<strong><a
href="{% url "control:event.subevent" organizer=request.event.organizer.slug event=request.event.slug subevent=s.id %}">
{{ s.name }}</a></strong>
</td>
<td>{{ s.get_date_from_display }}</td>
@@ -99,8 +107,8 @@
{% endfor %}
{% if s.first_quotas|length > 3 %}
<a href="{% url "control:event.items.quotas" organizer=request.event.organizer.slug event=request.event.slug %}?subevent={{ s.id }}"
class="quotabox-more" data-toggle="tooltip" title="{% trans "More quotas" %}"
data-placement="top">
class="quotabox-more" data-toggle="tooltip" title="{% trans "More quotas" %}"
data-placement="top">
&middot;&middot;&middot;
</a>
{% endif %}
@@ -108,16 +116,17 @@
<td>
{% if not s.active %}
<span class="label label-danger">{% trans "Disabled" %}</span>
{% elif s.presale_has_ended %}
{% elif s.presale_has_ended %}
<span class="label label-warning">{% trans "Presale over" %}</span>
{% elif not s.presale_is_running %}
{% elif not s.presale_is_running %}
<span class="label label-warning">{% trans "Presale not started" %}</span>
{% else %}
<span class="label label-success">{% trans "On sale" %}</span>
{% endif %}
</td>
<td class="text-right">
<a href="{% url "control:event.subevent" organizer=request.event.organizer.slug event=request.event.slug subevent=s.id %}" class="btn btn-default btn-sm"><i class="fa fa-edit"></i></a>
<a href="{% url "control:event.subevent" organizer=request.event.organizer.slug event=request.event.slug subevent=s.id %}"
class="btn btn-default btn-sm"><i class="fa fa-edit"></i></a>
<div class="btn-group {% if forloop.revcounter0 < 2 %}dropup{% endif %}">
<button type="button" class="btn btn-default btn-sm dropdown-toggle"
data-toggle="dropdown">
@@ -136,25 +145,34 @@
</li>
</ul>
</div>
<a href="{% url "control:event.subevent.delete" organizer=request.event.organizer.slug event=request.event.slug subevent=s.id %}" class="btn btn-danger btn-sm"><i class="fa fa-trash"></i></a>
<a href="{% url "control:event.subevent.delete" organizer=request.event.organizer.slug event=request.event.slug subevent=s.id %}"
class="btn btn-danger btn-sm"><i class="fa fa-trash"></i></a>
</td>
</tr>
{% endfor %}
</tbody>
{% if "can_change_event_settings" in request.eventpermset %}
<tfoot>
<tr>
<td colspan="6">
<button type="submit" class="btn btn-default btn-save" name="action" value="delete">
{% trans "Delete selected" %}
</button>
<button type="submit" class="btn btn-default btn-save" name="action" value="enable">
{% trans "Enable selected" %}
</button>
<button type="submit" class="btn btn-default btn-save" name="action" value="disable">
{% trans "Disable selected" %}
</button>
</td>
</tr>
</tfoot>
{% endif %}
</table>
</form>
<div class="panel-footer">
{% include "pretixcontrol/pagination.html" %}
</div>
{% if "can_change_event_settings" in request.eventpermset %}
<button type="submit" class="btn btn-default btn-save" name="action" value="delete">
{% trans "Delete selected" %}
</button>
<button type="submit" class="btn btn-default btn-save" name="action" value="enable">
{% trans "Enable selected" %}
</button>
<button type="submit" class="btn btn-default btn-save" name="action" value="disable">
{% trans "Disable selected" %}
</button>
{% endif %}
</form>
{% include "pretixcontrol/pagination.html" %}
</div>
{% endif %}
{% endblock %}
@@ -3,16 +3,22 @@
{% load bootstrap3 %}
{% block title %}{% trans "Add a two-factor authentication device" %}{% endblock %}
{% block content %}
<h1>{% trans "Add a two-factor authentication device" %}</h1>
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
{% bootstrap_form_errors form %}
{% bootstrap_field form.name layout='horizontal' %}
{% bootstrap_field form.devicetype layout='horizontal' %}
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Continue" %}
</button>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Add a two-factor authentication device" %}</h1>
</div>
</form>
<div class="panel-body">
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
{% bootstrap_form_errors form %}
{% bootstrap_field form.name layout='horizontal' %}
{% bootstrap_field form.devicetype layout='horizontal' %}
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Continue" %}
</button>
</div>
</form>
</div>
</div>
{% endblock %}
@@ -3,23 +3,24 @@
{% load bootstrap3 %}
{% block title %}{% trans "Add a two-factor authentication device" %}{% endblock %}
{% block content %}
<h1>{% trans "Add a two-factor authentication device" %}</h1>
<p>
{% trans "To set up this device, please follow the following steps:" %}
</p>
<ol class="multi-step-tutorial">
<li>
{% trans "Download the Google Authenticator application to your phone:" %}
<div class="panel panel-default">
<div class="panel-heading">
<legend>
{% trans "Step 1:" %}
{% trans "Download the Google Authenticator application to your phone:" %}
</legend>
</div>
<div class="panel-body">
<ul>
<li>
<a href="https://play.google.com/store/apps/details?id=com.google.android.apps.authenticator2&"
target="_blank">
target="_blank">
{% trans "Android (Google Play)" %}
</a>
</li>
<li>
<a href="https://f-droid.org/repository/browse/?fdfilter=authenticator&fdid=com.google.android.apps.authenticator2"
target="_blank">
target="_blank">
{% trans "Android (F-Droid)" %}
</a>
</li>
@@ -34,9 +35,14 @@
</a>
</li>
</ul>
</li>
<li>
</div>
</div>
<div class="panel panel-default">
<div class="panel-heading">
{% trans "Step 2:" %}
{% trans "Add a new account to the app by scanning the following barcode:" %}
</div>
<div class="panel-body">
<div class="qrcode-canvas" data-qrdata="#qrdata"></div>
<p>
<a data-toggle="collapse" href="#no_scan">
@@ -55,40 +61,48 @@
{% trans 'In "Secret"/"Account Key", enter the following code:' %}
<div>
<code id="otp_secret" style="white-space: pre">{{ secretGrouped }}</code>
<button type="button" class="btn btn-default btn-xs btn-clipboard" data-clipboard-target="#otp_secret">
<button type="button" class="btn btn-default btn-xs btn-clipboard"
data-clipboard-target="#otp_secret">
<span class="fa fa-clipboard" aria-hidden="true"></span>
{% trans "copy" %}
</button>
</div>
<div>
<small>Spaces don't matter.</small>
<small>{% trans "Spaces don't matter." %}</small>
</div>
</li>
<li>
<li>
{% trans 'If present, make sure "Time-based"/"TOTP" and 6 digit codes are selected.' %}
</li>
</li>
</ol>
</div>
</li>
<li>
</div>
</div>
<div class="panel panel-default">
<div class="panel-heading">
{% trans "Step 3:" %}
{% trans "Enter the displayed code here:" %}
</div>
<div class="panel-body">
<form class="form form-inline" method="post" action="">
{% csrf_token %}
<input type="number" name="token" class="form-control" required="required">
<button class="btn btn-primary" type="submit">
{% trans "Continue" %}
</button><br>
</button>
<br>
<label>
<input type="checkbox" name="activate" checked="checked" value="on">
{% trans "Require second factor for future logins" %}
</label>
</form>
</li>
</ol>
</div>
</div>
<script type="text/json" id="qrdata">
{{ qrdata|safe }}
</script>
{% endblock %}
@@ -5,31 +5,33 @@
{% load compress %}
{% block title %}{% trans "Add a two-factor authentication device" %}{% endblock %}
{% block content %}
<h1>{% trans "Add a two-factor authentication device" %}</h1>
<p id="u2f-progress">
<span class="fa fa-cog fa-spin"></span>
{% trans "Please connect your U2F device. If it has a button, touch it now. You might have to unplug the device and plug it back in again." %}
</p>
<form class="form form-inline" method="post" action="" id="u2f-form">
{% csrf_token %}
<input type="hidden" id="u2f-response" name="token" class="form-control" required="required">
<p>
<label>
<input type="checkbox" name="activate" checked="checked" value="on">
{% trans "Require second factor for future logins" %}
</label>
</p>
<button class="btn btn-primary sr-only" type="submit"></button>
</form>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Add a two-factor authentication device" %}</h1>
</div>
<div class="panel-body">
<p id="u2f-progress">
<span class="fa fa-cog fa-spin"></span>
{% trans "Please connect your U2F device. If it has a button, touch it now. You might have to unplug the device and plug it back in again." %}
</p>
<form class="form form-inline" method="post" action="" id="u2f-form">
{% csrf_token %}
<input type="hidden" id="u2f-response" name="token" class="form-control" required="required">
<p>
<label>
<input type="checkbox" name="activate" checked="checked" value="on">
{% trans "Require second factor for future logins" %}
</label>
</p>
<button class="btn btn-primary sr-only" type="submit"></button>
</form>
<div class="sr-only alert alert-danger" id="u2f-error">
{% trans "Device registration failed." %}
<div class="sr-only alert alert-danger" id="u2f-error">
{% trans "Device registration failed." %}
</div>
<script type="text/json" id="u2f-enroll">{{ jsondata|safe }}</script>
</div>
</div>
<script type="text/json" id="u2f-enroll">
{{ jsondata|safe }}
</script>
{% compress js %}
<script type="text/javascript" src="{% static "pretixcontrol/js/ui/u2f-api.js" %}"></script>
<script type="text/javascript" src="{% static "pretixcontrol/js/ui/u2f.js" %}"></script>
@@ -3,23 +3,29 @@
{% load bootstrap3 %}
{% block title %}{% trans "Delete a two-factor authentication device" %}{% endblock %}
{% block content %}
<h1>{% trans "Delete a two-factor authentication device" %}</h1>
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<p>{% blocktrans trimmed with device=device.name %}
Are you sure you want to delete the authentication device "{{ device }}"?
{% endblocktrans %}</p>
<p>{% trans "You will no longer be able to use this device to log in to pretix." %}</p>
<p>
{% trans "If this is the only device connected to your account, we will disable two-factor authentication." %}
</p>
<div class="form-group submit-group">
<a href="{% url "control:user.settings.2fa" %}" class="btn btn-default btn-cancel">
{% trans "Cancel" %}
</a>
<button type="submit" class="btn btn-danger btn-save">
{% trans "Delete" %}
</button>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Delete a two-factor authentication device" %}</h1>
</div>
</form>
<div class="panel-body">
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<p>{% blocktrans trimmed with device=device.name %}
Are you sure you want to delete the authentication device "{{ device }}"?
{% endblocktrans %}</p>
<p>{% trans "You will no longer be able to use this device to log in to pretix." %}</p>
<p>
{% trans "If this is the only device connected to your account, we will disable two-factor authentication." %}
</p>
<div class="form-group submit-group">
<a href="{% url "control:user.settings.2fa" %}" class="btn btn-default btn-cancel">
{% trans "Cancel" %}
</a>
<button type="submit" class="btn btn-danger btn-save">
{% trans "Delete" %}
</button>
</div>
</form>
</div>
</div>
{% endblock %}
@@ -3,22 +3,28 @@
{% load bootstrap3 %}
{% block title %}{% trans "Disable two-factor authentication" %}{% endblock %}
{% block content %}
<h1>{% trans "Disable two-factor authentication" %}</h1>
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<p>
{% trans "Do you really want to disable two-factor authentication?" %}
</p>
<p>
{% trans "You will no longer require a second device to log in to your account." %}
</p>
<div class="form-group submit-group">
<a href="{% url "control:user.settings.2fa" %}" class="btn btn-default btn-cancel">
{% trans "Cancel" %}
</a>
<button type="submit" class="btn btn-danger btn-save">
{% trans "Disable" %}
</button>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Disable two-factor authentication" %}</h1>
</div>
</form>
<div class="panel-body">
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<p>
{% trans "Do you really want to disable two-factor authentication?" %}
</p>
<p>
{% trans "You will no longer require a second device to log in to your account." %}
</p>
<div class="form-group submit-group">
<a href="{% url "control:user.settings.2fa" %}" class="btn btn-default btn-cancel">
{% trans "Cancel" %}
</a>
<button type="submit" class="btn btn-danger btn-save">
{% trans "Disable" %}
</button>
</div>
</form>
</div>
</div>
{% endblock %}
@@ -3,23 +3,29 @@
{% load bootstrap3 %}
{% block title %}{% trans "Enable two-factor authentication" %}{% endblock %}
{% block content %}
<h1>{% trans "Enable two-factor authentication" %}</h1>
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<p>
{% trans "Do you really want to enable two-factor authentication?" %}
</p>
<p>
{% trans "You will no longer be able to log in to pretix without one of your configured devices." %}
{% trans "Please make sure to print out or copy the emergency tokens and store them in a safe place." %}
</p>
<div class="form-group submit-group">
<a href="{% url "control:user.settings.2fa" %}" class="btn btn-default btn-cancel">
{% trans "Cancel" %}
</a>
<button type="submit" class="btn btn-danger btn-save">
{% trans "Enable" %}
</button>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Enable two-factor authentication" %}</h1>
</div>
</form>
<div class="panel-body">
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<p>
{% trans "Do you really want to enable two-factor authentication?" %}
</p>
<p>
{% trans "You will no longer be able to log in to pretix without one of your configured devices." %}
{% trans "Please make sure to print out or copy the emergency tokens and store them in a safe place." %}
</p>
<div class="form-group submit-group">
<a href="{% url "control:user.settings.2fa" %}" class="btn btn-default btn-cancel">
{% trans "Cancel" %}
</a>
<button type="submit" class="btn btn-danger btn-save">
{% trans "Enable" %}
</button>
</div>
</form>
</div>
</div>
{% endblock %}
@@ -3,34 +3,28 @@
{% load bootstrap3 %}
{% block title %}{% trans "Two-factor authentication" %}{% endblock %}
{% block content %}
<h1>{% trans "Two-factor authentication" %}</h1>
<p>
{% blocktrans trimmed %}
Two-factor authentication is a way to add additional security to your account. If you enable it, you will
not only need your password to log in, but also an additional token that is generated e.g. by an app on your
smartphone or a hardware token generator and that changes on a regular basis.
{% endblocktrans %}
</p>
{% if user.require_2fa %}
<div class="panel panel-success">
<div class="panel-heading">
<h3 class="panel-title">{% trans "Two-factor status" %}</h3>
</div>
<div class="panel-body">
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Two-factor authentication" %}</h1>
</div>
<div class="panel-body">
<p>
{% blocktrans trimmed %}
Two-factor authentication is a way to add additional security to your account. If you enable it, you
will
not only need your password to log in, but also an additional token that is generated e.g. by an app
on your
smartphone or a hardware token generator and that changes on a regular basis.
{% endblocktrans %}
</p>
{% if user.require_2fa %}
<a href="{% url "control:user.settings.2fa.disable" %}" class="btn btn-primary pull-right">
{% trans "Disable" %}
</a>
<p>
<strong>{% trans "Two-factor authentication is currently enabled." %}</strong>
</p>
</div>
</div>
{% else %}
<div class="panel panel-warning">
<div class="panel-heading">
<h3 class="panel-title">{% trans "Two-factor status" %}</h3>
</div>
<div class="panel-body">
{% else %}
{% if devices|length %}
<a href="{% url "control:user.settings.2fa.enable" %}" class="btn btn-primary pull-right">
{% trans "Enable" %}
@@ -42,9 +36,9 @@
{% if not devices|length %}
<p>{% trans "To enable it, you need to configure at least one device below." %}</p>
{% endif %}
</div>
{% endif %}
</div>
{% endif %}
</div>
<div class="panel panel-default">
<div class="panel-heading">
<h3 class="panel-title">{% trans "Registered devices" %}</h3>
@@ -53,7 +47,7 @@
{% for d in devices %}
<li class="list-group-item">
<a class="btn btn-danger btn-xs pull-right"
href="{% url "control:user.settings.2fa.delete" devicetype=d.devicetype device=d.pk %}">
href="{% url "control:user.settings.2fa.delete" devicetype=d.devicetype device=d.pk %}">
Delete
</a>
{% if d.devicetype == "totp" %}
@@ -75,6 +69,10 @@
</div>
<div class="panel panel-default">
<div class="panel-heading">
<a href="{% url "control:user.settings.2fa.regenemergency" %}" class="btn btn-default pull-right">
<span class="fa fa-refresh"></span>
{% trans "Generate new emergency tokens" %}
</a>
<h3 class="panel-title">{% trans "Emergency tokens" %}</h3>
</div>
<div class="panel-body">
@@ -87,10 +85,6 @@
<li><code>{{ t.token }}</code></li>
{% endfor %}
</ul>
<a href="{% url "control:user.settings.2fa.regenemergency" %}" class="btn btn-default">
<span class="fa fa-refresh"></span>
{% trans "Generate new emergency tokens" %}
</a>
</div>
</div>
{% endblock %}
@@ -3,22 +3,28 @@
{% load bootstrap3 %}
{% block title %}{% trans "Regenerate emergency codes" %}{% endblock %}
{% block content %}
<h1>{% trans "Regenerate emergency codes" %}</h1>
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<p>
{% trans "Do you really want to regenerate your emergency codes?" %}
</p>
<p>
{% trans "The old codes will no longer work." %}
</p>
<div class="form-group submit-group">
<a href="{% url "control:user.settings.2fa" %}" class="btn btn-default btn-cancel">
{% trans "Cancel" %}
</a>
<button type="submit" class="btn btn-danger btn-save">
{% trans "Regenerate" %}
</button>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Regenerate emergency codes" %}</h1>
</div>
</form>
<div class="panel-body">
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<p>
{% trans "Do you really want to regenerate your emergency codes?" %}
</p>
<p>
{% trans "The old codes will no longer work." %}
</p>
<div class="form-group submit-group">
<a href="{% url "control:user.settings.2fa" %}" class="btn btn-default btn-cancel">
{% trans "Cancel" %}
</a>
<button type="submit" class="btn btn-danger btn-save">
{% trans "Regenerate" %}
</button>
</div>
</form>
</div>
</div>
{% endblock %}
@@ -3,7 +3,6 @@
{% load bootstrap3 %}
{% block title %}{% trans "Account history" %}{% endblock %}
{% block content %}
<h1>{% trans "Account history" %}</h1>
<div class="panel panel-default">
<div class="panel-heading">
<h3 class="panel-title">
@@ -3,39 +3,49 @@
{% load bootstrap3 %}
{% block title %}{% trans "Notification settings" %}{% endblock %}
{% block content %}
<h1>{% trans "Notification settings" %}</h1>
<form method="post">
{% csrf_token %}
<fieldset>
{% if request.user.notifications_send %}
<div class="alert alert-info">
<button name="notifications_send" value="off" type="submit" class="pull-right btn btn-default">
<span class="fa fa-bell-slash"></span>
{% trans "Disable" %}
</button>
{% trans "Notifications are turned on according to the settings below." %}
<div class="clearfix"></div>
</div>
{% else %}
<div class="alert alert-warning">
<button name="notifications_send" value="on" type="submit" class="pull-right btn btn-default">
<span class="fa fa-bell"></span>
{% trans "Enable" %}
</button>
{% trans "All notifications are turned off globally." %}
<div class="clearfix"></div>
</div>
{% endif %}
</fieldset>
</form>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Notification settings" %}</h1>
</div>
<div class="panel-body">
<form method="post">
{% csrf_token %}
<fieldset>
{% if request.user.notifications_send %}
<div class="alert alert-info">
<button name="notifications_send" value="off" type="submit"
class="pull-right btn btn-default">
<span class="fa fa-bell-slash"></span>
{% trans "Disable" %}
</button>
{% trans "Notifications are turned on according to the settings below." %}
<div class="clearfix"></div>
</div>
{% else %}
<div class="alert alert-warning">
<button name="notifications_send" value="on" type="submit"
class="pull-right btn btn-default">
<span class="fa fa-bell"></span>
{% trans "Enable" %}
</button>
{% trans "All notifications are turned off globally." %}
<div class="clearfix"></div>
</div>
{% endif %}
</fieldset>
</form>
</div>
</div>
<form class="form-inline" method="get">
<fieldset>
<legend>{% trans "Choose event" %}</legend>
<p>
<fieldset class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Choose event" %}</legend>
</div>
<div class="panel-body">
<select name="event" class="form-control simple-subevent-choice"
data-model-select2="event"
data-placeholder="{% trans "All my events" %}"
data-select2-url="{% url "control:events.typeahead" %}">
data-model-select2="event"
data-placeholder="{% trans "All my events" %}"
data-select2-url="{% url "control:events.typeahead" %}">
{% if event %}
<option value="{{ event.pk }}" selected>
{{ event.name }}
@@ -43,13 +53,15 @@
{% endif %}
</select>
<span class="help-block">{% trans "Save your modifications before switching events." %}</span>
</p>
</div>
</fieldset>
</form>
<form method="post">
{% csrf_token %}
<fieldset>
<legend>{% trans "Choose notifications to get" %}</legend>
<fieldset class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Choose notifications to get" %}</legend>
</div>
<table class="table">
<thead>
<tr>
@@ -67,23 +79,30 @@
{% if not event or type.required_permission in permset %}
<select name="mail:{{ type.action_type }}" class="form-control">
{% if event %}
<option value="global">{% trans "Global" %} ({% if global.mail %}{% trans "On" %}{% else %}{% trans "Off" %}{% endif %})</option>{% endif %}
<option value="off" {% if "mail" in enabled and enabled.mail == False %}selected{% endif %}>{% trans "Off" %}</option>
<option value="on" {% if enabled.mail %}selected{% endif %}>{% trans "On" %}</option>
<option value="global">{% trans "Global" %} ({% if global.mail %}
{% trans "On" %}{% else %}{% trans "Off" %}{% endif %})
</option>{% endif %}
<option value="off"
{% if "mail" in enabled and enabled.mail == False %}selected{% endif %}>{% trans "Off" %}</option>
<option value="on"
{% if enabled.mail %}selected{% endif %}>{% trans "On" %}</option>
</select>
{% else %}
<span class="fa fa-lock" data-toggle="tooltip" title="{% trans "You have no permission to receive this notification" %}"></span>
<span class="fa fa-lock" data-toggle="tooltip"
title="{% trans "You have no permission to receive this notification" %}"></span>
{% endif %}
</td>
</tr>
{% endfor %}
</tbody>
</table>
<div class="panel-body">
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Save" %}
</button>
</div>
</div>
</fieldset>
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Save" %}
</button>
</div>
</form>
{% endblock %}
@@ -3,61 +3,69 @@
{% load bootstrap3 %}
{% block title %}{% trans "Account settings" %}{% endblock %}
{% block content %}
<h1>{% trans "Account settings" %}</h1>
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
{% bootstrap_form_errors form %}
<fieldset>
<legend>{% trans "General settings" %}</legend>
{% bootstrap_field form.fullname layout='horizontal' %}
{% bootstrap_field form.locale layout='horizontal' %}
{% bootstrap_field form.timezone layout='horizontal' %}
<div class="form-group">
<label class="col-md-3 control-label" for="id_new_pw_repeat">{% trans "Notifications" %}</label>
<div class="col-md-9 static-form-row">
{% if request.user.notifications_send and request.user.notification_settings.exists %}
<span class="label label-success">
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
{% bootstrap_form_errors form %}
<fieldset class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Account settings" %}</legend>
</div>
<div class="panel-body">
{% bootstrap_field form.fullname layout='horizontal' %}
{% bootstrap_field form.locale layout='horizontal' %}
{% bootstrap_field form.timezone layout='horizontal' %}
<div class="form-group">
<label class="col-md-3 control-label" for="id_new_pw_repeat">{% trans "Notifications" %}</label>
<div class="col-md-9 static-form-row">
{% if request.user.notifications_send and request.user.notification_settings.exists %}
<span class="label label-success">
<span class="fa fa-bell-o"></span> {% trans "On" %}
</span>
{% else %}
<span class="label label-warning">
{% else %}
<span class="label label-warning">
<span class="fa fa-bell-slash-o"></span> {% trans "Off" %}
</span>
{% endif %}
&nbsp;
<a href="{% url "control:user.settings.notifications" %}">
{% trans "Change notification settings" %}
</a>
{% endif %}
&nbsp;
<a href="{% url "control:user.settings.notifications" %}">
{% trans "Change notification settings" %}
</a>
</div>
</div>
</div>
</div>
</fieldset>
<fieldset>
<legend>{% trans "Login settings" %}</legend>
{% bootstrap_field form.old_pw layout='horizontal' %}
{% bootstrap_field form.email layout='horizontal' %}
{% bootstrap_field form.new_pw layout='horizontal' %}
{% bootstrap_field form.new_pw_repeat layout='horizontal' %}
<div class="form-group">
<label class="col-md-3 control-label" for="id_new_pw_repeat">{% trans "Two-factor authentication" %}</label>
<div class="col-md-9 static-form-row">
{% if user.require_2fa %}
<span class="label label-success">{% trans "Enabled" %}</span> &nbsp;
<a href="{% url "control:user.settings.2fa" %}">
{% trans "Change two-factor settings" %}
</a>
{% else %}
<span class="label label-default">{% trans "Disabled" %}</span> &nbsp;
<a href="{% url "control:user.settings.2fa" %}">
{% trans "Enable" %}
</a>
{% endif %}
</fieldset>
<fieldset class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Login settings" %}</legend>
</div>
<div class="panel-body">
{% bootstrap_field form.old_pw layout='horizontal' %}
{% bootstrap_field form.email layout='horizontal' %}
{% bootstrap_field form.new_pw layout='horizontal' %}
{% bootstrap_field form.new_pw_repeat layout='horizontal' %}
<div class="form-group">
<label class="col-md-3 control-label"
for="id_new_pw_repeat">{% trans "Two-factor authentication" %}</label>
<div class="col-md-9 static-form-row">
{% if user.require_2fa %}
<span class="label label-success">{% trans "Enabled" %}</span> &nbsp;
<a href="{% url "control:user.settings.2fa" %}">
{% trans "Change two-factor settings" %}
</a>
{% else %}
<span class="label label-default">{% trans "Disabled" %}</span> &nbsp;
<a href="{% url "control:user.settings.2fa" %}">
{% trans "Enable" %}
</a>
{% endif %}
</div>
</div>
</div>
</fieldset>
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Save" %}
</button>
</div>
</fieldset>
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Save" %}
</button>
</div>
</form>
</form>
{% endblock %}
@@ -3,45 +3,57 @@
{% load bootstrap3 %}
{% block title %}{% trans "Staff session" %}{% endblock %}
{% block content %}
<h1>{% trans "Session notes" %}</h1>
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
{% bootstrap_form_errors form %}
{% bootstrap_field form.comment layout='horizontal' %}
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Save" %}
</button>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Session notes" %}</h1>
</div>
</form>
<h1>{% trans "Audit log" %}</h1>
<dl class="dl-horizontal">
<dt>{% trans "Start date" %}</dt>
<dd>{{ session.date_start|date:"SHORT_DATETIME_FORMAT" }}</dd>
<dt>{% trans "End date" %}</dt>
<dd>{{ session.date_end|date:"SHORT_DATETIME_FORMAT" }}</dd>
<dt>{% trans "User" %}</dt>
<dd>{{ session.user.email }}</dd>
</dl>
<table class="table table-condensed">
<thead>
<tr>
<th>{% trans "Timestamp" %}</th>
<th>{% trans "Method" %}</th>
<th>{% trans "URL" %}</th>
<th>{% trans "On behalf of" %}</th>
</tr>
</thead>
<tbody>
{% for log in logs %}
<tr>
<td>{{ log.datetime|date:"SHORT_DATETIME_FORMAT" }}</td>
<td>{{ log.method }}</td>
<td>{{ log.url }}</td>
<td>{{ log.impersonating|default:"" }}</td>
</tr>
{% endfor %}
</tbody>
<div class="panel-body">
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
{% bootstrap_form_errors form %}
{% bootstrap_field form.comment layout='horizontal' %}
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Save" %}
</button>
</div>
</form>
</div>
</div>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Audit log" %}</h1>
</div>
<div class="panel-body">
<dl class="dl-horizontal dl-left">
<dt>{% trans "Start date" %}</dt>
<dd>{{ session.date_start|date:"SHORT_DATETIME_FORMAT" }}</dd>
<dt>{% trans "End date" %}</dt>
<dd>{{ session.date_end|date:"SHORT_DATETIME_FORMAT" }}</dd>
<dt>{% trans "User" %}</dt>
<dd>{{ session.user.email }}</dd>
</dl>
</div>
<table class="table table-condensed">
<thead>
<tr>
<th>{% trans "Timestamp" %}</th>
<th>{% trans "Method" %}</th>
<th>{% trans "URL" %}</th>
<th>{% trans "On behalf of" %}</th>
</tr>
</thead>
<tbody>
{% for log in logs %}
<tr>
<td>{{ log.datetime|date:"SHORT_DATETIME_FORMAT" }}</td>
<td>{{ log.method }}</td>
<td>{{ log.url }}</td>
<td>{{ log.impersonating|default:"" }}</td>
</tr>
{% endfor %}
</tbody>
</table>
</table>
</div>
{% endblock %}
@@ -4,55 +4,58 @@
{% load urlreplace %}
{% block title %}{% trans "Admin sessions" %}{% endblock %}
{% block content %}
<h1>{% trans "Admin sessions" %}</h1>
<table class="table table-condensed table-hover">
<thead>
<tr>
<th>
#
</th>
<th>
{% trans "User" %}
</th>
<th>
{% trans "Start date" %}
</th>
<th>{% trans "End date" %}</th>
<th>{% trans "Comment" %}</th>
<th></th>
</tr>
</thead>
<tbody>
{% for s in sessions %}
<div class="panel panel-default">
<table class="table table-condensed table-hover">
<thead>
<tr>
<td><strong>
<a href="{% url "control:user.sudo.edit" id=s.pk %}">{{ s.pk }}</a>
</strong></td>
<td><strong>
<a href="{% url "control:users.edit" id=s.user.pk %}">{{ s.user.email }}</a>
</strong></td>
<td>
{{ s.date_start|date:"SHORT_DATETIME_FORMAT" }}
</td>
<td>
{% if s.date_end %}
{{ s.date_end|date:"SHORT_DATETIME_FORMAT" }}
{% endif %}
</td>
<td>
{% if s.comment %}
<span class="fa fa-check"></span>
{% else %}
<span class="fa fa-times text-danger"></span>
{% endif %}
</td>
<td class="text-right">
<a href="{% url "control:user.sudo.edit" id=s.id %}" class="btn btn-default btn-sm"><i
class="fa fa-edit"></i></a>
</td>
<th>
#
</th>
<th>
{% trans "User" %}
</th>
<th>
{% trans "Start date" %}
</th>
<th>{% trans "End date" %}</th>
<th>{% trans "Comment" %}</th>
<th></th>
</tr>
{% endfor %}
</tbody>
</table>
{% include "pretixcontrol/pagination.html" %}
</thead>
<tbody>
{% for s in sessions %}
<tr>
<td><strong>
<a href="{% url "control:user.sudo.edit" id=s.pk %}">{{ s.pk }}</a>
</strong></td>
<td><strong>
<a href="{% url "control:users.edit" id=s.user.pk %}">{{ s.user.email }}</a>
</strong></td>
<td>
{{ s.date_start|date:"SHORT_DATETIME_FORMAT" }}
</td>
<td>
{% if s.date_end %}
{{ s.date_end|date:"SHORT_DATETIME_FORMAT" }}
{% endif %}
</td>
<td>
{% if s.comment %}
<span class="fa fa-check"></span>
{% else %}
<span class="fa fa-times text-danger"></span>
{% endif %}
</td>
<td class="text-right">
<a href="{% url "control:user.sudo.edit" id=s.id %}" class="btn btn-default btn-sm"><i
class="fa fa-edit"></i></a>
</td>
</tr>
{% endfor %}
</tbody>
</table>
<div class="panel-footer">
{% include "pretixcontrol/pagination.html" %}
</div>
</div>
{% endblock %}
@@ -3,20 +3,26 @@
{% load bootstrap3 %}
{% block title %}{% trans "Admin mode" %}{% endblock %}
{% block content %}
<h1>{% trans "Admin mode" %}</h1>
<p>
{% blocktrans trimmed %}
To perform this action, you need to start an administrative session. Everything you do in that session
will be logged and you will later be asked to fill in a comment on what you did in your session for later
reference.
{% endblocktrans %}
</p>
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Start session" %}
</button>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Admin mode" %}</h1>
</div>
</form>
<div class="panel-body">
<p>
{% blocktrans trimmed %}
To perform this action, you need to start an administrative session. Everything you do in that
session will be logged and you will later be asked to fill in a comment on what you did in your session for
later reference.
{% endblocktrans %}
</p>
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Start session" %}
</button>
</div>
</form>
</div>
</div>
{% endblock %}
@@ -3,22 +3,29 @@
{% load bootstrap3 %}
{% block title %}{% trans "Create user" %}{% endblock %}
{% block content %}
<h1>{% trans "Create user" %}</h1>
<form action="" method="post" class="form-horizontal" enctype="multipart/form-data">
{% csrf_token %}
{% bootstrap_form_errors form %}
<fieldset>
<legend>{% trans "Base settings" %}</legend>
{% bootstrap_field form.is_active layout='control' %}
{% bootstrap_field form.fullname layout='control' %}
{% bootstrap_field form.locale layout='control' %}
{% bootstrap_field form.timezone layout='control' %}
<fieldset class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Create user" %}</h1>
</div>
<div class="panel-body">
{% bootstrap_field form.is_active layout='control' %}
{% bootstrap_field form.fullname layout='control' %}
{% bootstrap_field form.locale layout='control' %}
{% bootstrap_field form.timezone layout='control' %}
</div>
</fieldset>
<fieldset>
<legend>{% trans "Log-in settings" %}</legend>
{% bootstrap_field form.email layout='control' %}
{% bootstrap_field form.new_pw layout='control' %}
{% bootstrap_field form.new_pw_repeat layout='control' %}
<fieldset class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Log-in settings" %}</legend>
</div>
<div class="panel-body">
{% bootstrap_field form.email layout='control' %}
{% bootstrap_field form.new_pw layout='control' %}
{% bootstrap_field form.new_pw_repeat layout='control' %}
</div>
</fieldset>
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
@@ -3,50 +3,62 @@
{% load bootstrap3 %}
{% block title %}{% trans "User" %}{% endblock %}
{% block content %}
<h1>{% trans "User" %} {{ user.email }}</h1>
<p>
<form action="{% url "control:users.reset" id=user.pk %}" method="post" class="form-inline helper-display-inline">
{% csrf_token %}
<button class="btn btn-default">{% trans "Send password reset email" %}</button>
</form>
<form action="{% url "control:users.impersonate" id=user.pk %}" method="post" class="form-inline helper-display-inline">
{% csrf_token %}
<button class="btn btn-default">{% trans "Impersonate user" %}</button>
</form>
</p>
<div class="row">
<div class="col-md-10 col-xs-12">
<form action="" method="post" class="form-horizontal" enctype="multipart/form-data">
{% csrf_token %}
{% bootstrap_form_errors form %}
<fieldset>
<legend>{% trans "Base settings" %}</legend>
{% bootstrap_field form.is_active layout='control' %}
{% bootstrap_field form.fullname layout='control' %}
{% bootstrap_field form.locale layout='control' %}
{% bootstrap_field form.timezone layout='control' %}
{% bootstrap_field form.is_staff layout='control' %}
<fieldset class="panel panel-default">
<div class="panel-heading">
<div class="pull-right">
<form action="{% url "control:users.reset" id=user.pk %}" method="post" class="form-inline helper-display-inline">
{% csrf_token %}
<button class="btn btn-default">{% trans "Send password reset email" %}</button>
</form>
<form action="{% url "control:users.impersonate" id=user.pk %}" method="post"
class="form-inline helper-display-inline">
{% csrf_token %}
<button class="btn btn-default">{% trans "Impersonate user" %}</button>
</form>
</div>
<h1 class="panel-title">{% trans "User" %} {{ user.email }}</h1>
</div>
<div class="panel-body">
{% bootstrap_field form.is_active layout='control' %}
{% bootstrap_field form.fullname layout='control' %}
{% bootstrap_field form.locale layout='control' %}
{% bootstrap_field form.timezone layout='control' %}
{% bootstrap_field form.is_staff layout='control' %}
</div>
</fieldset>
<fieldset>
<legend>{% trans "Log-in settings" %}</legend>
{% bootstrap_field form.email layout='control' %}
{% bootstrap_field form.new_pw layout='control' %}
{% bootstrap_field form.new_pw_repeat layout='control' %}
{% bootstrap_field form.require_2fa layout='control' %}
<fieldset class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Log-in settings" %}</legend>
</div>
<div class="panel-body">
{% bootstrap_field form.email layout='control' %}
{% bootstrap_field form.new_pw layout='control' %}
{% bootstrap_field form.new_pw_repeat layout='control' %}
{% bootstrap_field form.require_2fa layout='control' %}
</div>
</fieldset>
<fieldset>
<legend>{% trans "Team memberships" %}</legend>
<ul>
{% for t in teams %}
<li>
<a href="{% url "control:organizer.team" organizer=t.organizer.slug team=t.pk %}">
{% blocktrans trimmed with team=t.name organizer=t.organizer.name %}
Team "{{ team }}" of organizer "{{ organizer }}"
{% endblocktrans %}
</a>
</li>
{% endfor %}
</ul>
<fieldset class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "Team memberships" %}</legend>
</div>
<div class="panel-body">
<ul>
{% for t in teams %}
<li>
<a href="{% url "control:organizer.team" organizer=t.organizer.slug team=t.pk %}">
{% blocktrans trimmed with team=t.name organizer=t.organizer.name %}
Team "{{ team }}" of organizer "{{ organizer }}"
{% endblocktrans %}
</a>
</li>
{% endfor %}
</ul>
</div>
</fieldset>
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
@@ -4,65 +4,71 @@
{% load urlreplace %}
{% block title %}{% trans "Users" %}{% endblock %}
{% block content %}
<h1>{% trans "Users" %}</h1>
<form class="row filter-form" action="" method="get">
<div class="col-md-4 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.query layout='inline' %}
</div>
<div class="col-md-3 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.status layout='inline' %}
</div>
<div class="col-md-3 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.superuser layout='inline' %}
</div>
<div class="col-md-2 col-sm-6 col-xs-12">
<button class="btn btn-primary btn-block" type="submit">
<span class="fa fa-filter"></span>
<span class="hidden-md">
<div class="panel panel-default">
<div class="panel-body">
<form class="row filter-form" action="" method="get">
<div class="col-md-4 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.query layout='inline' %}
</div>
<div class="col-md-3 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.status layout='inline' %}
</div>
<div class="col-md-3 col-sm-6 col-xs-12">
{% bootstrap_field filter_form.superuser layout='inline' %}
</div>
<div class="col-md-2 col-sm-6 col-xs-12">
<button class="btn btn-primary btn-block" type="submit">
<span class="fa fa-filter"></span>
<span class="hidden-md">
{% trans "Filter" %}
</span>
</button>
</button>
</div>
</form>
</div>
</form>
<p>
<a href="{% url "control:users.add" %}" class="btn btn-default">
<span class="fa fa-plus"></span>
{% trans "Create a new user" %}
</a>
</p>
<table class="table table-condensed table-hover">
<thead>
<tr>
<th>
{% trans "E-mail address" %}
<a href="?{% url_replace request 'ordering' '-email' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'email' %}"><i class="fa fa-caret-up"></i></a>
</th>
<th>
{% trans "Full name" %}
<a href="?{% url_replace request 'ordering' '-fullname' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'fullname' %}"><i class="fa fa-caret-up"></i></a>
</th>
<th>{% trans "Active" %}</th>
<th>{% trans "Administrator" %}</th>
<th></th>
</tr>
</thead>
<tbody>
{% for u in users %}
<div class="panel-body">
<a href="{% url "control:users.add" %}" class="btn btn-default">
<span class="fa fa-plus"></span>
{% trans "Create a new user" %}
</a>
</div>
<table class="table table-condensed table-hover">
<thead>
<tr>
<td><strong>
<a href="{% url "control:users.edit" id=u.pk %}">{{ u.email }}</a>
</strong></td>
<td>{{ u.fullname|default_if_none:"" }}</td>
<td>{% if u.is_active %}<span class="fa fa-check-circle"></span>{% endif %}</td>
<td>{% if u.is_staff %}<span class="fa fa-check-circle"></span>{% endif %}</td>
<td class="text-right">
<a href="{% url "control:users.edit" id=u.id %}" class="btn btn-default btn-sm"><i class="fa fa-edit"></i></a>
</td>
<th>
{% trans "E-mail address" %}
<a href="?{% url_replace request 'ordering' '-email' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'email' %}"><i class="fa fa-caret-up"></i></a>
</th>
<th>
{% trans "Full name" %}
<a href="?{% url_replace request 'ordering' '-fullname' %}"><i class="fa fa-caret-down"></i></a>
<a href="?{% url_replace request 'ordering' 'fullname' %}"><i class="fa fa-caret-up"></i></a>
</th>
<th>{% trans "Active" %}</th>
<th>{% trans "Administrator" %}</th>
<th></th>
</tr>
{% endfor %}
</tbody>
</table>
{% include "pretixcontrol/pagination.html" %}
</thead>
<tbody>
{% for u in users %}
<tr>
<td><strong>
<a href="{% url "control:users.edit" id=u.pk %}">{{ u.email }}</a>
</strong></td>
<td>{{ u.fullname|default_if_none:"" }}</td>
<td>{% if u.is_active %}<span class="fa fa-check-circle"></span>{% endif %}</td>
<td>{% if u.is_staff %}<span class="fa fa-check-circle"></span>{% endif %}</td>
<td class="text-right">
<a href="{% url "control:users.edit" id=u.id %}" class="btn btn-default btn-sm"><i
class="fa fa-edit"></i></a>
</td>
</tr>
{% endfor %}
</tbody>
</table>
<div class="panel-footer">
{% include "pretixcontrol/pagination.html" %}
</div>
</div>
{% endblock %}
@@ -3,18 +3,25 @@
{% load bootstrap3 %}
{% block title %}{% trans "Badges" %}{% endblock %}
{% block content %}
<h1>{% trans "Badges" %}</h1>
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<p>{% blocktrans %}Are you sure you want to delete the badge layout <strong>{{ layout }}</strong>?{% endblocktrans %}</p>
<div class="form-group submit-group">
<a href="{% url "plugins:badges:index" organizer=request.event.organizer.slug event=request.event.slug %}" class="btn
btn-default btn-cancel">
{% trans "Cancel" %}
</a>
<button type="submit" class="btn btn-danger btn-save">
{% trans "Delete" %}
</button>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Badges" %}</h1>
</div>
</form>
<div class="panel-body">
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<p>{% blocktrans %}Are you sure you want to delete the badge layout <strong>{{ layout }}</strong>?{% endblocktrans %}</p>
<div class="form-group submit-group">
<a href="{% url "plugins:badges:index" organizer=request.event.organizer.slug event=request.event.slug %}"
class="btn btn-default btn-cancel">
{% trans "Cancel" %}
</a>
<button type="submit" class="btn btn-danger btn-save">
{% trans "Delete" %}
</button>
</div>
</form>
</div>
</div>
{% endblock %}
@@ -9,31 +9,37 @@
{% endif %}
{% endblock %}
{% block content %}
{% if layout %}
<h1>{% blocktrans with name=layout.name %}Badge layout: {{ name }}{% endblocktrans %}</h1>
{% else %}
<h1>{% trans "Badge layout" %}</h1>
{% endif %}
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
{% bootstrap_form_errors form %}
{% bootstrap_field form.name layout="control" %}
<div class="form-group">
<label class="col-md-3 control-label">
{% trans "Badge design" %}
</label>
<div class="col-md-9">
<p>
{% blocktrans trimmed %}
You can modify the design after you saved this page.
{% endblocktrans %}
</p>
</div>
<div class="panel panel-default">
<div class="panel-heading">
{% if layout %}
<h1 class="panel-title">{% blocktrans with name=layout.name %}Badge layout: {{ name }}{% endblocktrans %}</h1>
{% else %}
<h1 class="panel-title">{% trans "Badge layout" %}</h1>
{% endif %}
</div>
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Save" %}
</button>
<div class="panel-body">
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
{% bootstrap_form_errors form %}
{% bootstrap_field form.name layout="control" %}
<div class="form-group">
<label class="col-md-3 control-label">
{% trans "Badge design" %}
</label>
<div class="col-md-9">
<p>
{% blocktrans trimmed %}
You can modify the design after you saved this page.
{% endblocktrans %}
</p>
</div>
</div>
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Save" %}
</button>
</div>
</form>
</div>
</form>
</div>
{% endblock %}
@@ -3,79 +3,87 @@
{% load money %}
{% block title %}{% trans "Badges" %}{% endblock %}
{% block content %}
<h1>{% trans "Badges" %}</h1>
{% if layouts|length == 0 %}
<div class="empty-collection">
<p>
{% blocktrans trimmed %}
You haven't created any badge layouts yet.
{% endblocktrans %}
</p>
<div class="panel panel-default">
{% if layouts|length == 0 %}
<div class="empty-collection panel-body">
<p>
{% blocktrans trimmed %}
You haven't created any badge layouts yet.
{% endblocktrans %}
</p>
{% if "can_change_event_settings" in request.eventpermset %}
<a href="{% url "plugins:badges:add" organizer=request.event.organizer.slug event=request.event.slug %}"
class="btn btn-primary btn-lg"><i class="fa fa-plus"></i> {% trans "Create a new badge layout" %}
{% if "can_change_event_settings" in request.eventpermset %}
<a href="{% url "plugins:badges:add" organizer=request.event.organizer.slug event=request.event.slug %}"
class="btn btn-primary btn-lg"><i class="fa fa-plus"></i> {% trans "Create a new badge layout" %}
</a>
{% endif %}
</div>
{% else %}
<div class="panel-body">
{% if "can_change_event_settings" in request.eventpermset %}
<a href="{% url "plugins:badges:add" organizer=request.event.organizer.slug event=request.event.slug %}"
class="btn btn-default"><i class="fa fa-plus"></i> {% trans "Create a new badge layout" %}
</a>
{% endif %}
<a href="{% url "control:event.orders.export" organizer=request.event.organizer.slug event=request.event.slug %}?identifier=badges"
class="btn btn-primary"><i class="fa fa-print"></i> {% trans "Print badges" %}
</a>
{% endif %}
</div>
{% else %}
<p>
{% if "can_change_event_settings" in request.eventpermset %}
<a href="{% url "plugins:badges:add" organizer=request.event.organizer.slug event=request.event.slug %}" class="btn btn-default"><i class="fa fa-plus"></i> {% trans "Create a new badge layout" %}
</a>
{% endif %}
<a href="{% url "control:event.orders.export" organizer=request.event.organizer.slug event=request.event.slug %}?identifier=badges" class="btn btn-primary"><i class="fa fa-print"></i> {% trans "Print badges" %}
</a>
</p>
<div class="table-responsive">
<table class="table table-hover table-quotas">
<thead>
<tr>
<th>{% trans "Name" %}</th>
<th>{% trans "Default" %}</th>
<th class="action-col-2"></th>
</tr>
</thead>
<tbody>
{% for l in layouts %}
</div>
<div class="table-responsive">
<table class="table table-hover table-quotas">
<thead>
<tr>
<td>
{% if "can_change_event_settings" in request.eventpermset %}
<strong><a href="{% url "plugins:badges:edit" organizer=request.event.organizer.slug event=request.event.slug layout=l.id %}">
{{ l.name }}
</a></strong>
{% else %}
<strong>{{ l.name }}</strong>
{% endif %}
</td>
<td>
{% if l.default %}
<span class="text-success">
<th>{% trans "Name" %}</th>
<th>{% trans "Default" %}</th>
<th class="action-col-2"></th>
</tr>
</thead>
<tbody>
{% for l in layouts %}
<tr>
<td>
{% if "can_change_event_settings" in request.eventpermset %}
<strong><a
href="{% url "plugins:badges:edit" organizer=request.event.organizer.slug event=request.event.slug layout=l.id %}">
{{ l.name }}
</a></strong>
{% else %}
<strong>{{ l.name }}</strong>
{% endif %}
</td>
<td>
{% if l.default %}
<span class="text-success">
<span class="fa fa-check"></span>
{% trans "Default" %}
</span>
{% elif "can_change_event_settings" in request.eventpermset %}
<form class="form-inline" method="post"
action="{% url "plugins:badges:default" organizer=request.event.organizer.slug event=request.event.slug layout=l.id %}"
>
{% csrf_token %}
<button class="btn btn-default btn-sm">
{% trans "Make default" %}
</button>
</form>
{% endif %}
</td>
<td class="text-right">
{% if "can_change_event_settings" in request.eventpermset %}
<a href="{% url "plugins:badges:edit" organizer=request.event.organizer.slug event=request.event.slug layout=l.id %}" class="btn btn-default btn-sm"><i class="fa fa-edit"></i></a>
<a href="{% url "plugins:badges:delete" organizer=request.event.organizer.slug event=request.event.slug layout=l.id %}" class="btn btn-danger btn-sm"><i class="fa fa-trash"></i></a>
{% endif %}
</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
{% endif %}
{% include "pretixcontrol/pagination.html" %}
{% elif "can_change_event_settings" in request.eventpermset %}
<form class="form-inline" method="post"
action="{% url "plugins:badges:default" organizer=request.event.organizer.slug event=request.event.slug layout=l.id %}"
>
{% csrf_token %}
<button class="btn btn-default btn-sm">
{% trans "Make default" %}
</button>
</form>
{% endif %}
</td>
<td class="text-right">
{% if "can_change_event_settings" in request.eventpermset %}
<a href="{% url "plugins:badges:edit" organizer=request.event.organizer.slug event=request.event.slug layout=l.id %}"
class="btn btn-default btn-sm"><i class="fa fa-edit"></i></a>
<a href="{% url "plugins:badges:delete" organizer=request.event.organizer.slug event=request.event.slug layout=l.id %}"
class="btn btn-danger btn-sm"><i class="fa fa-trash"></i></a>
{% endif %}
</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
<div class="panel-footer">
{% include "pretixcontrol/pagination.html" %}
</div>
{% endif %}
</div>
{% endblock %}
+1
View File
@@ -35,6 +35,7 @@ class LayoutListView(EventPermissionRequiredMixin, ListView):
permission = ('can_change_event_settings', 'can_view_orders')
template_name = 'pretixplugins/badges/index.html'
context_object_name = 'layouts'
paginate_by = 25
def get_queryset(self):
return self.request.event.badge_layouts.prefetch_related('item_assignments')
@@ -1,23 +1,28 @@
{% extends basetpl %}
{% load i18n %}
{% block inner %}
<p>{% blocktrans trimmed %}
We've been unable to automatically determine how the columns in your file are aligned. Please help us
by selecting which column contain what kind of data.
{% endblocktrans %}</p>
<form method="post" action="">
{% csrf_token %}
<button class="btn btn-primary pull-right helper-space-below" type="submit">
<span class="icon icon-upload"></span> {% trans "Continue" %}
</button>
<div class="flipped-scroll-wrapper clearfix">
<table class="table table-condensed flipped-scroll-inner">
<thead>
<div class="panel panel-default">
<div class="panel-body">
<button class="btn btn-primary pull-right helper-space-below" type="submit">
<span class="icon icon-upload"></span> {% trans "Continue" %}
</button>
{% blocktrans trimmed %}
We've been unable to automatically determine how the columns in your file are aligned. Please help
us by selecting which column contain what kind of data.
{% endblocktrans %}
</div>
</div>
<div class="panel panel-default">
<div class="flipped-scroll-wrapper clearfix">
<table class="table table-condensed flipped-scroll-inner">
<thead>
<tr>
<th>{% trans "Date" %}</th>
{% for col in rows.0 %}
<th>
<input type="radio" name="date" value="{{ forloop.counter0 }}" />
<input type="radio" name="date" value="{{ forloop.counter0 }}"/>
</th>
{% endfor %}
</tr>
@@ -25,7 +30,7 @@
<th>{% trans "Amount" %}</th>
{% for col in rows.0 %}
<th>
<input type="radio" name="amount" value="{{ forloop.counter0 }}" required="required" />
<input type="radio" name="amount" value="{{ forloop.counter0 }}" required="required"/>
</th>
{% endfor %}
</tr>
@@ -33,7 +38,7 @@
<th>{% trans "Reference" %}</th>
{% for col in rows.0 %}
<th>
<input type="checkbox" name="reference" value="{{ forloop.counter0 }}" />
<input type="checkbox" name="reference" value="{{ forloop.counter0 }}"/>
</th>
{% endfor %}
</tr>
@@ -41,12 +46,12 @@
<th>{% trans "Payer" %}</th>
{% for col in rows.0 %}
<th>
<input type="checkbox" name="payer" value="{{ forloop.counter0 }}" />
<input type="checkbox" name="payer" value="{{ forloop.counter0 }}"/>
</th>
{% endfor %}
</tr>
</thead>
<tbody>
</thead>
<tbody>
{% for row in rows|slice:":100" %}
{% with forloop.counter0 as rowid %}
<tr>
@@ -64,11 +69,12 @@
</td>
</tr>
{% endif %}
</tbody>
</table>
</tbody>
</table>
</div>
</div>
<input type="hidden" name="cols" value="{{ rows.0|length }}" />
<input type="hidden" name="rows" value="{{ rows|length }}" />
<input type="hidden" name="cols" value="{{ rows.0|length }}"/>
<input type="hidden" name="rows" value="{{ rows|length }}"/>
<textarea class="helper-display-none" name="data">
{{ json|escape }}
</textarea>
@@ -3,7 +3,6 @@
{% load static %}
{% block title %}{% trans "Import bank data" %}{% endblock %}
{% block content %}
<h1>{% trans "Import bank data" %}</h1>
{% block inner %}
{% endblock %}
{% endblock %}
@@ -23,7 +23,8 @@
Currently, this feature supports <code>.csv</code> files and files in the MT940 format.
{% endblocktrans %}</p>
{% if job_running %}
<div class="alert alert-info" data-job-waiting data-job-waiting-url="{% url "plugins:banktransfer:import.job" event=request.event.slug organizer=request.event.organizer.slug job=job_running.pk %}?ajax=1">
<div class="alert alert-info" data-job-waiting
data-job-waiting-url="{% url "plugins:banktransfer:import.job" event=request.event.slug organizer=request.event.organizer.slug job=job_running.pk %}?ajax=1">
<span class="fa fa-cog fa-spin"></span>
{% trans "An import is currently being processed, please try again in a few minutes." %}
</div>
@@ -31,7 +32,8 @@
<form action="" method="post" enctype="multipart/form-data" class="form-inline">
{% csrf_token %}
<div class="form-group">
<label for="file">{% trans "Import file" %}: </label> <input id="file" type="file" name="file"/>
<label for="file">{% trans "Import file" %}: </label> <input id="file" type="file"
name="file"/>
</div>
<div class="clearfix"></div>
<button class="btn btn-primary pull-right" type="submit">
@@ -47,18 +49,17 @@
<div class="panel-heading">
<h3 class="panel-title">{% trans "Unresolved transactions" %}</h3>
</div>
{% if request.event %}
<div class="panel-body">
{% blocktrans trimmed %}
On this page, you can import banking data on a per-event level. You also only see
unmatched transactions imported directly for this event.
{% endblocktrans %}
<a href="{% url "plugins:banktransfer:import" organizer=request.organizer.slug %}"
class="btn btn-default btn-xs">{% trans "Go to organizer-level import" %}</a>
</div>
{% endif %}
<div class="panel-body">
{% if request.event %}
<p>
{% blocktrans trimmed %}
On this page, you can import banking data on a per-event level. You also only see
unmatched transactions imported directly for this event.
{% endblocktrans %}
<a href="{% url "plugins:banktransfer:import" organizer=request.organizer.slug %}"
class="btn btn-default btn-xs">{% trans "Go to organizer-level import" %}</a>
</p>
{% endif %}
<p>
<form class="form-inline helper-display-inline" action="" method="get">
<input type="text" name="search" class="form-control" placeholder="{% trans "Search" %}"
value="{{ request.GET.search }}">
@@ -73,16 +74,16 @@
</button>
</form>
{% endif %}
</p>
{% if transactions_unhandled|length > 0 %}
{% include "pretixcontrol/pagination.html" %}
{% include "pretixplugins/banktransfer/transaction_list.html" with list=transactions_unhandled %}
{% include "pretixcontrol/pagination.html" %}
{% else %}
<div>{% trans "Your search matched no transactions." %}</div>
{% endif %}
</div>
{% if transactions_unhandled|length > 0 %}
{% include "pretixplugins/banktransfer/transaction_list.html" with list=transactions_unhandled %}
<div class="panel-footer">
{% include "pretixcontrol/pagination.html" %}
</div>
{% else %}
<div class="empty-collection panel-body">{% trans "Your search matched no transactions." %}</div>
{% endif %}
</div>
{% endif %}
<script type="application/javascript" src="{% static "pretixplugins/banktransfer/ui.js" %}"></script>
@@ -2,48 +2,57 @@
{% load i18n %}
{% load staticfiles %}
{% block inner %}
<h2>{% trans "Import result" %}</h2>
{% if job.state == "running" or job.state == "pending" %}
<div class="empty-collection" data-job-waiting data-job-waiting-url="{% if request.event %}{% url "plugins:banktransfer:import.job" event=request.event.slug organizer=request.event.organizer.slug job=job.pk %}{% else %}{% url "plugins:banktransfer:import.job" organizer=request.organizer.slug job=job.pk %}{% endif %}?ajax=1">
<p>
<span class="fa big-grey-icon fa-cog fa big-rotating-icon"></span>
</p>
<p>
{% trans "The result of your import is in progress. Please be patient while we process the data …" %}
</p>
<div class="panel panel-default">
<div class="panel-body">
<h2 class="panel-title">{% trans "Import result" %}</h2>
</div>
{% else %}
{% if job.state == "error" %}
<div class="alert alert-danger">
{% trans "An internal error occurred during processing your data." %}
{% if job.state == "running" or job.state == "pending" %}
<div class="panel-body empty-collection" data-job-waiting data-job-waiting-url="{% if request.event %}{% url "plugins:banktransfer:import.job" event=request.event.slug organizer=request.event.organizer.slug job=job.pk %}{% else %}{% url "plugins:banktransfer:import.job" organizer=request.organizer.slug job=job.pk %}{% endif %}?ajax=1">
<p>
<span class="fa big-grey-icon fa-cog fa big-rotating-icon"></span>
</p>
<p>
{% trans "The result of your import is in progress. Please be patient while we process the data …" %}
</p>
</div>
{% elif transactions_ignored == 0 and transactions_invalid == 0 and transactions_valid == 0 %}
<div class="alert alert-info">
{% trans "Your import did not contain any transactions that you did not import before." %}
</div>
{% endif %}
{% else %}
{% if job.state == "error" %}
<div class="panel-body">
<div class="alert alert-danger">
{% trans "An internal error occurred during processing your data." %}
</div>
</div>
{% elif transactions_ignored == 0 and transactions_invalid == 0 and transactions_valid == 0 %}
<div class="panel-body">
<div class="alert alert-info">
{% trans "Your import did not contain any transactions that you did not import before." %}
</div>
</div>
{% endif %}
<table class="table table-condensed">
<tr class="success">
<td>{{ transactions_valid }}</td>
<td>{% trans "Orders marked as paid" %}</td>
</tr>
<tr class="warning">
<td>{{ transactions_invalid }}</td>
<td>{% trans "Invalid payments" %}</td>
</tr>
<tr class="info">
<td>{{ transactions_ignored }}</td>
<td>{% trans "Ignored payments" %}</td>
</tr>
</table>
{% if transactions_ignored or transactions_invalid %}
<a href="{% if request.event %}{% url "plugins:banktransfer:import" event=request.event.slug organizer=request.organizer.slug %}{% else %}{% url "plugins:banktransfer:import" organizer=request.organizer.slug %}{% endif %}"
class="btn btn-primary">
{% trans "Review invalid and ignored payments" %} &raquo;
</a>
<table class="table table-condensed">
<tr class="success">
<td>{{ transactions_valid }}</td>
<td>{% trans "Orders marked as paid" %}</td>
</tr>
<tr class="warning">
<td>{{ transactions_invalid }}</td>
<td>{% trans "Invalid payments" %}</td>
</tr>
<tr class="info">
<td>{{ transactions_ignored }}</td>
<td>{% trans "Ignored payments" %}</td>
</tr>
</table>
{% if transactions_ignored or transactions_invalid %}
<div class="panel-body">
<a href="{% if request.event %}{% url "plugins:banktransfer:import" event=request.event.slug organizer=request.organizer.slug %}{% else %}{% url "plugins:banktransfer:import" organizer=request.organizer.slug %}{% endif %}"
class="btn btn-primary">
{% trans "Review invalid and ignored payments" %} &raquo;
</a>
</div>
{% endif %}
{% endif %}
{% endif %}
</div>
<script type="application/javascript" src="{% static "pretixplugins/banktransfer/ui.js" %}"></script>
{% endblock %}
+1 -1
View File
@@ -24,7 +24,7 @@ def control_nav_import(sender, request=None, **kwargs):
'event': request.event.slug,
'organizer': request.event.organizer.slug,
}),
'active': (url.namespace == 'plugins:pretixdroid' and url.url_name == 'config'),
'active': (url.namespace == 'plugins:pretixdroid'),
'icon': 'mobile',
}
]
@@ -4,96 +4,115 @@
{% load staticfiles %}
{% block title %}{% trans "Check-in device configuration" %}{% endblock %}
{% block content %}
<h1>{% trans "Check-in device configuration" %}</h1>
<p>{% blocktrans trimmed %}
pretixdroid is an Android app that you can use to control tickets at the entrance of your event.
pretixdesk is the corresponding app for desktop computers.
{% endblocktrans %}</p>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Check-in device configuration" %}</h1>
</div>
<div class="panel-body">
{% blocktrans trimmed %}
pretixdroid is an Android app that you can use to control tickets at the entrance of your event.
pretixdesk is the corresponding app for desktop computers.
{% endblocktrans %}
</div>
{% if configs and "create" not in request.GET %}
<div class="panel-footer">
<a href="?create=1" class="btn btn-default">
{% trans "Create a new configuration" %}
</a>
</div>
{% endif %}
</div>
{% if not configs or "create" in request.GET %}
<h2>{% trans "Create app configuration" %}</h2>
<p>
{% blocktrans trimmed %}
To start scanning tickets with our apps, first create a configuration code here:
{% endblocktrans %}
</p>
<form action="?add" method="post" class="form-horizontal">
{% csrf_token %}
{% bootstrap_form_errors add_form %}
{% bootstrap_field add_form.list layout="horizontal" %}
{% bootstrap_field add_form.all_items layout="horizontal" %}
{% bootstrap_field add_form.items layout="horizontal" %}
{% bootstrap_field add_form.show_info layout="horizontal" %}
{% bootstrap_field add_form.allow_search layout="horizontal" %}
{% bootstrap_field add_form.app layout="horizontal" %}
<div class="form-group">
<div class="col-md-offset-3 col-md-9">
<button type="submit" class="btn btn-primary btn-save" name="add" value="1">
{% trans "Create configuration" %}
</button>
</div>
<div class="panel panel-default">
<div class="panel-heading">
<h2 class="panel-title">{% trans "Create app configuration" %}</h2>
</div>
</form>
<div class="panel-body">
<p>
{% blocktrans trimmed %}
To start scanning tickets with our apps, first create a configuration code here:
{% endblocktrans %}
</p>
<form action="?add" method="post" class="form-horizontal">
{% csrf_token %}
{% bootstrap_form_errors add_form %}
{% bootstrap_field add_form.list layout="horizontal" %}
{% bootstrap_field add_form.all_items layout="horizontal" %}
{% bootstrap_field add_form.items layout="horizontal" %}
{% bootstrap_field add_form.show_info layout="horizontal" %}
{% bootstrap_field add_form.allow_search layout="horizontal" %}
{% bootstrap_field add_form.app layout="horizontal" %}
<div class="submit-group">
<button type="submit" class="btn btn-primary btn-save" name="add" value="1">
{% trans "Create configuration" %}
</button>
</div>
</form>
</div>
</div>
{% endif %}
{% if configs and "create" not in request.GET %}
<h2>{% trans "Existing app configurations" %}</h2>
<a href="?create=1" class="btn btn-default">
{% trans "Create a new configuration" %}
</a>
<form action="?" method="post" class="form-horizontal">
{% csrf_token %}
<table class="table">
<thead>
<tr>
<th>{% trans "ID" %}</th>
<th>{% trans "Check-in list" %}</th>
<th>{% trans "Items" %}</th>
<th>{% trans "Show info" %}</th>
<th>{% trans "Allow search" %}</th>
<th></th>
</tr>
</thead>
<tbody>
{% for ac in configs %}
<div class="panel panel-default">
<div class="panel-heading">
<h2 class="panel-title">{% trans "Existing app configurations" %}</h2>
</div>
<form action="?" method="post" class="form-horizontal table-responsive">
{% csrf_token %}
<table class="table">
<thead>
<tr>
<td>
{% if ac.app == "pretixdroid" %}
<span class="fa fa-fw fa-android"></span>
{% elif ac.app == "pretixdesk" %}
<span class="fa fa-fw fa-desktop"></span>
{% endif %}
{{ ac.key|slice:"0:8" }}…
</td>
<td>
<a href="{% url "control:event.orders.checkinlists.show" organizer=request.event.organizer.slug event=request.event.slug list=ac.list.id %}">{{ ac.list }}</a>
</td>
<td>
{% if ac.all_items %}
{% trans "All" %}
{% else %}
{% for item in ac.items.all %}
<a href="{% url "control:event.item" organizer=request.event.organizer.slug event=request.event.slug item=item.id %}">{{ item.name }}</a>
{% if forloop.revcounter0 > 0 %}<br>{% endif %}
{% endfor %}
{% endif %}
</td>
<td>{% if ac.show_info %}{% trans "Yes" %}{% else %}{% trans "No" %}{% endif %}</td>
<td>{% if ac.allow_search %}{% trans "Yes" %}{% else %}{% trans "No" %}{% endif %}</td>
<td class="text-right">
<a href="{% url "plugins:pretixdroid:config.code" organizer=request.event.organizer.slug event=request.event.slug config=ac.pk %}" class="btn btn-default">
<span class="fa fa-qrcode"></span> {% trans "Configure device" %}
</a>
<button class="btn btn-danger" name="delete" value="{{ ac.pk }}">
<span class="fa fa-trash"></span>
</button>
</td>
<th>{% trans "ID" %}</th>
<th>{% trans "Check-in list" %}</th>
<th>{% trans "Items" %}</th>
<th>{% trans "Show info" %}</th>
<th>{% trans "Allow search" %}</th>
<th></th>
</tr>
{% endfor %}
</tbody>
</table>
</form>
</thead>
<tbody>
{% for ac in configs %}
<tr>
<td>
{% if ac.app == "pretixdroid" %}
<span class="fa fa-fw fa-android"></span>
{% elif ac.app == "pretixdesk" %}
<span class="fa fa-fw fa-desktop"></span>
{% endif %}
{{ ac.key|slice:"0:8" }}…
</td>
<td>
<a href="{% url "control:event.orders.checkinlists.show" organizer=request.event.organizer.slug event=request.event.slug list=ac.list.id %}">{{ ac.list }}</a>
</td>
<td>
{% if ac.all_items %}
{% trans "All" %}
{% else %}
{% for item in ac.items.all %}
<a href="{% url "control:event.item" organizer=request.event.organizer.slug event=request.event.slug item=item.id %}">{{ item.name }}</a>
{% if forloop.revcounter0 > 0 %}<br>{% endif %}
{% endfor %}
{% endif %}
</td>
<td>{% if ac.show_info %}{% trans "Yes" %}{% else %}{% trans "No" %}{% endif %}</td>
<td>{% if ac.allow_search %}{% trans "Yes" %}{% else %}{% trans "No" %}{% endif %}</td>
<td class="text-right">
<a href="{% url "plugins:pretixdroid:config.code" organizer=request.event.organizer.slug event=request.event.slug config=ac.pk %}"
class="btn btn-default">
<span class="fa fa-qrcode"></span> {% trans "Configure device" %}
</a>
<button class="btn btn-danger" name="delete" value="{{ ac.pk }}">
<span class="fa fa-trash"></span>
</button>
</td>
</tr>
{% endfor %}
</tbody>
</table>
</form>
</div>
{% endif %}
{% endblock %}
@@ -5,64 +5,87 @@
{% block title %}{% trans "Device configuration" %}{% endblock %}
{% block content %}
{% if config.app == "pretixdroid" %}
<h1>
{% trans "pretixdroid configuration" %}
<a href="{% url "plugins:pretixdroid:config" organizer=request.event.organizer.slug event=request.event.slug %}" class="btn btn-default">
{% trans "Back to overview" %}
</a>
</h1>
<h2>{% trans "1. Download app" %}</h2>
<p>
<a href="http://play.google.com/store/apps/details?id=eu.pretix.pretixdroid">
<img src="{% static "pretixplugins/pretixdroid/play_store_en.png" %}" alt="
<div class="panel panel-default">
<div class="panel-heading">
<h2 class="panel-title">{% trans "1. Download app" %}</h2>
</div>
<div class="panel-body">
<p>
<a href="http://play.google.com/store/apps/details?id=eu.pretix.pretixdroid">
<img src="{% static "pretixplugins/pretixdroid/play_store_en.png" %}" alt="
{% trans "Download the app from the Google Play Store" %}" height="70">
</a>
</p>
<p>
<small>
{% blocktrans trimmed %}
Android, Google Play and the Google Play logo are trademarks of Google Inc.
{% endblocktrans %}
</small>
</p>
<h2>{% trans "2. Scan code" %}</h2>
<div id="qrcodeCanvas"></div>
<script type="text/json" id="qrdata">
</a>
</p>
<p>
<small>
{% blocktrans trimmed %}
Android, Google Play and the Google Play logo are trademarks of Google Inc.
{% endblocktrans %}
</small>
</p>
</div>
</div>
<div class="panel panel-default">
<div class="panel-heading">
<h2 class="panel-title">{% trans "2. Scan code" %}</h2>
</div>
<div class="panel-body">
<div id="qrcodeCanvas"></div>
<script type="text/json" id="qrdata">
{{ qrdata|safe }}
</script>
<h2>{% trans "3. Start scanning tickets" %}</h2>
<script type="text/javascript" src="{% static "pretixplugins/pretixdroid/pretixdroid.js" %}"></script>
</script>
</div>
</div>
<div class="panel panel-default">
<div class="panel-heading">
<h2 class="panel-title">{% trans "3. Start scanning tickets" %}</h2>
</div>
</div>
{% else %}
<h1>
{% trans "pretixdesk configuration" %}
<a href="{% url "plugins:pretixdroid:config" organizer=request.event.organizer.slug event=request.event.slug %}" class="btn btn-default">
{% trans "Back to overview" %}
</a>
</h1>
<h2>{% trans "1. Download pretixdesk" %}</h2>
<p>
<a href="https://pretix.eu/about/en/desk" class="btn btn-lg btn-primary" target="_blank">
{% trans "Open download page" %}
</a>
</p>
<h2>{% trans "2. Connect device" %}</h2>
<p>
<a href="pretixdesk://setup?{{ query }}" class="btn btn-lg btn-primary">
{% trans "Connect with pretixdesk" %}
</a>
</p>
<p>
{% blocktrans trimmed %}
If this link does not open the pretixdesk application or if you want to set the application up on a
separate device, copy the following code and paste it into the application:
{% endblocktrans %}
</p>
<p>
<input type="text" class="form-control" value="pretixdesk://setup?{{ query }}" readonly>
</p>
<h2>{% trans "3. Start scanning tickets" %}</h2>
<script type="text/javascript" src="{% static "pretixplugins/pretixdroid/pretixdroid.js" %}"></script>
<div class="panel panel-default">
<div class="panel-heading">
<h2 class="panel-title">{% trans "1. Download pretixdesk" %}</h2>
</div>
<div class="panel-body">
<a href="https://pretix.eu/about/en/desk" class="btn btn-lg btn-primary" target="_blank">
{% trans "Open download page" %}
</a>
</div>
</div>
<div class="panel panel-default">
<div class="panel-heading">
<h2 class="panel-title">{% trans "2. Connect device" %}</h2>
</div>
<div class="panel-body">
<p>
<a href="pretixdesk://setup?{{ query }}" class="btn btn-lg btn-primary">
{% trans "Connect with pretixdesk" %}
</a>
</p>
<p>
{% blocktrans trimmed %}
If this link does not open the pretixdesk application or if you want to set the application up
on a
separate device, copy the following code and paste it into the application:
{% endblocktrans %}
</p>
<p>
<input type="text" class="form-control" value="pretixdesk://setup?{{ query }}" readonly>
</p>
</div>
</div>
<div class="panel panel-default">
<div class="panel-heading">
<h2 class="panel-title">{% trans "3. Start scanning tickets" %}</h2>
</div>
</div>
{% endif %}
<script type="text/javascript" src="{% static "pretixplugins/pretixdroid/pretixdroid.js" %}"></script>
{% endblock %}
@@ -3,8 +3,10 @@
{% load bootstrap3 %}
{% block title %}{% trans "Send out emails" %}{% endblock %}
{% block content %}
<h1>{% trans "Email history" %}</h1>
<div>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Email history" %}</h1>
</div>
<ul class="list-group">
{% for log in logs %}
<li class="list-group-item logentry">
@@ -36,6 +38,8 @@
</li>
{% endfor %}
</ul>
<div class="panel-footer">
{% include "pretixcontrol/pagination.html" %}
</div>
</div>
{% include "pretixcontrol/pagination.html" %}
{% endblock %}
@@ -3,20 +3,39 @@
{% load bootstrap3 %}
{% block title %}{% trans "Send out emails" %}{% endblock %}
{% block content %}
<h1>{% trans "Send out emails" %}</h1>
{% block inner %}
<form class="form-horizontal" method="post" action="">
{% csrf_token %}
{% bootstrap_field form.sendto layout='horizontal' %}
{% if form.subevent %}
{% bootstrap_field form.subevent layout='horizontal' %}
{% endif %}
{% bootstrap_field form.item layout='horizontal' %}
{% bootstrap_field form.subject layout='horizontal' %}
{% bootstrap_field form.message layout='horizontal' %}
{% if request.method == "POST" %}
<fieldset>
<legend>{% trans "E-mail preview" %}</legend>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Send out emails" %}</h1>
</div>
<div class="panel-body">
{% block inner %}
<form class="form-horizontal" method="post" action="">
{% csrf_token %}
{% bootstrap_field form.sendto layout='horizontal' %}
{% if form.subevent %}
{% bootstrap_field form.subevent layout='horizontal' %}
{% endif %}
{% bootstrap_field form.item layout='horizontal' %}
{% bootstrap_field form.subject layout='horizontal' %}
{% bootstrap_field form.message layout='horizontal' %}
<div class="form-group submit-group">
<button type="submit" class="btn btn-default btn-save pull-left" name="action" value="preview">
{% trans "Preview email" %}
</button>
<button type="submit" class="btn btn-primary btn-save">
{% trans "Send" %}
</button>
</div>
</form>
{% endblock %}
</div>
</div>
{% if request.method == "POST" %}
<fieldset class="panel panel-default">
<div class="panel-heading">
<legend>{% trans "E-mail preview" %}</legend>
</div>
<div class="panel-body">
<div class="tab-pane mail-preview-group">
{% for locale, segments in output.items %}
<pre lang="{{ locale }}" class="mail-preview">{% spaceless %}
@@ -26,16 +45,7 @@
{% endspaceless %}</pre>
{% endfor %}
</div>
</fieldset>
{% endif %}
<div class="form-group submit-group">
<button type="submit" class="btn btn-default btn-save pull-left" name="action" value="preview">
{% trans "Preview email" %}
</button>
<button type="submit" class="btn btn-primary btn-save">
{% trans "Send" %}
</button>
</div>
</form>
{% endblock %}
</fieldset>
{% endif %}
{% endblock %}
@@ -5,11 +5,12 @@
{% load escapejson %}
{% block title %}{% trans "Statistics" %}{% endblock %}
{% block content %}
<h1>{% trans "Statistics" %}</h1>
{% if request.event.has_subevents %}
<form class="form-inline helper-display-inline" action="" method="get">
{% include "pretixcontrol/event/fragment_subevent_choice_simple.html" %}
</form>
<div class="panel panel-default">
<form class="panel-body form-inline" action="" method="get">
{% include "pretixcontrol/event/fragment_subevent_choice_simple.html" %}
</form>
</div>
{% endif %}
{% if has_orders %}
<div class="panel panel-default">
@@ -29,7 +30,8 @@
{% if request.GET.subevent %}
<div class="alert alert-info">
{% blocktrans trimmed context "subevent" %}
If you select a single date, payment method fees will not be listed here as it might not be clear which
If you select a single date, payment method fees will not be listed here as it might not be
clear which
date they belong to.
{% endblocktrans %}
</div>
@@ -3,18 +3,25 @@
{% load bootstrap3 %}
{% block title %}{% trans "Ticket layout" %}{% endblock %}
{% block content %}
<h1>{% trans "Ticket layout" %}</h1>
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<p>{% blocktrans %}Are you sure you want to delete the layout <strong>{{ layout }}</strong>?{% endblocktrans %}</p>
<div class="form-group submit-group">
<a href="{% url "plugins:badges:index" organizer=request.event.organizer.slug event=request.event.slug %}" class="btn
btn-default btn-cancel">
{% trans "Cancel" %}
</a>
<button type="submit" class="btn btn-danger btn-save">
{% trans "Delete" %}
</button>
<div class="panel panel-default">
<div class="panel-heading">
<h1>{% trans "Ticket layout" %}</h1>
</div>
</form>
<div class="panel-body">
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
<p>{% blocktrans %}Are you sure you want to delete the layout <strong>{{ layout }}</strong>
?{% endblocktrans %}</p>
<div class="form-group submit-group">
<a href="{% url "plugins:badges:index" organizer=request.event.organizer.slug event=request.event.slug %}"
class="btn btn-default btn-cancel">
{% trans "Cancel" %}
</a>
<button type="submit" class="btn btn-danger btn-save">
{% trans "Delete" %}
</button>
</div>
</form>
</div>
</div>
{% endblock %}
@@ -9,31 +9,39 @@
{% endif %}
{% endblock %}
{% block content %}
{% if layout %}
<h1>{% blocktrans with name=layout.name %}Ticket layout: {{ name }}{% endblocktrans %}</h1>
{% else %}
<h1>{% trans "Ticket layout" %}</h1>
{% endif %}
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
{% bootstrap_form_errors form %}
{% bootstrap_field form.name layout="control" %}
<div class="form-group">
<label class="col-md-3 control-label">
{% trans "Ticket design" %}
</label>
<div class="col-md-9">
<p>
{% blocktrans trimmed %}
You can modify the design after you saved this page.
{% endblocktrans %}
</p>
</div>
<div class="panel panel-default">
<div class="panel-heading">
{% if layout %}
<h1 class="panel-title">{% blocktrans with name=layout.name %}Ticket layout:
{{ name }}{% endblocktrans %}</h1>
{% else %}
<h1 class="panel-title">{% trans "Ticket layout" %}</h1>
{% endif %}
</div>
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Save" %}
</button>
<div class="panel-body">
<form action="" method="post" class="form-horizontal">
{% csrf_token %}
{% bootstrap_form_errors form %}
{% bootstrap_field form.name layout="control" %}
<div class="form-group">
<label class="col-md-3 control-label">
{% trans "Ticket design" %}
</label>
<div class="col-md-9">
<p>
{% blocktrans trimmed %}
You can modify the design after you saved this page.
{% endblocktrans %}
</p>
</div>
</div>
<div class="form-group submit-group">
<button type="submit" class="btn btn-primary btn-save">
{% trans "Save" %}
</button>
</div>
</form>
</div>
</form>
</div>
{% endblock %}
@@ -3,76 +3,85 @@
{% load money %}
{% block title %}{% trans "Ticket layouts" %}{% endblock %}
{% block content %}
<h1>{% trans "Ticket layouts" %}</h1>
{% if layouts|length == 0 %}
<div class="empty-collection">
<p>
{% blocktrans trimmed %}
You haven't created any layouts yet.
{% endblocktrans %}
</p>
{% if "can_change_event_settings" in request.eventpermset %}
<a href="{% url "plugins:ticketoutputpdf:add" organizer=request.event.organizer.slug event=request.event.slug %}"
class="btn btn-primary btn-lg"><i class="fa fa-plus"></i> {% trans "Create a new layout" %}
</a>
{% endif %}
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">{% trans "Ticket layouts" %}</h1>
</div>
{% else %}
<p>
{% if "can_change_event_settings" in request.eventpermset %}
<a href="{% url "plugins:ticketoutputpdf:add" organizer=request.event.organizer.slug event=request.event.slug %}" class="btn btn-default"><i class="fa fa-plus"></i> {% trans "Create a new layout" %}
</a>
{% endif %}
</p>
<div class="table-responsive">
<table class="table table-hover table-quotas">
<thead>
<tr>
<th>{% trans "Name" %}</th>
<th>{% trans "Default" %}</th>
<th class="action-col-2"></th>
</tr>
</thead>
<tbody>
{% for l in layouts %}
{% if layouts|length == 0 %}
<div class="empty-collection panel-body">
<p>
{% blocktrans trimmed %}
You haven't created any layouts yet.
{% endblocktrans %}
</p>
{% if "can_change_event_settings" in request.eventpermset %}
<a href="{% url "plugins:ticketoutputpdf:add" organizer=request.event.organizer.slug event=request.event.slug %}"
class="btn btn-primary btn-lg"><i class="fa fa-plus"></i> {% trans "Create a new layout" %}
</a>
{% endif %}
</div>
{% else %}
<div class="panel-body">
{% if "can_change_event_settings" in request.eventpermset %}
<a href="{% url "plugins:ticketoutputpdf:add" organizer=request.event.organizer.slug event=request.event.slug %}"
class="btn btn-default"><i class="fa fa-plus"></i> {% trans "Create a new layout" %}
</a>
{% endif %}
</div>
<div class="table-responsive">
<table class="table table-hover table-quotas">
<thead>
<tr>
<td>
{% if "can_change_event_settings" in request.eventpermset %}
<strong><a href="{% url "plugins:ticketoutputpdf:edit" organizer=request.event.organizer.slug event=request.event.slug layout=l.id %}">
{{ l.name }}
</a></strong>
{% else %}
<strong>{{ l.name }}</strong>
{% endif %}
</td>
<td>
{% if l.default %}
<span class="text-success">
<th>{% trans "Name" %}</th>
<th>{% trans "Default" %}</th>
<th class="action-col-2"></th>
</tr>
</thead>
<tbody>
{% for l in layouts %}
<tr>
<td>
{% if "can_change_event_settings" in request.eventpermset %}
<strong><a href="{% url "plugins:ticketoutputpdf:edit" organizer=request.event.organizer.slug event=request.event.slug layout=l.id %}">
{{ l.name }}
</a></strong>
{% else %}
<strong>{{ l.name }}</strong>
{% endif %}
</td>
<td>
{% if l.default %}
<span class="text-success">
<span class="fa fa-check"></span>
{% trans "Default" %}
</span>
{% elif "can_change_event_settings" in request.eventpermset %}
<form class="form-inline" method="post"
action="{% url "plugins:ticketoutputpdf:default" organizer=request.event.organizer.slug event=request.event.slug layout=l.id %}">
{% csrf_token %}
<button class="btn btn-default btn-sm">
{% trans "Make default" %}
</button>
</form>
{% endif %}
</td>
<td class="text-right">
{% if "can_change_event_settings" in request.eventpermset %}
<a href="{% url "plugins:ticketoutputpdf:edit" organizer=request.event.organizer.slug event=request.event.slug layout=l.id %}" class="btn btn-default btn-sm"><i class="fa fa-edit"></i></a>
<a href="{% url "plugins:ticketoutputpdf:delete" organizer=request.event.organizer.slug event=request.event.slug layout=l.id %}" class="btn btn-danger btn-sm"><i class="fa fa-trash"></i></a>
{% endif %}
</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
{% endif %}
{% include "pretixcontrol/pagination.html" %}
{% elif "can_change_event_settings" in request.eventpermset %}
<form class="form-inline" method="post"
action="{% url "plugins:ticketoutputpdf:default" organizer=request.event.organizer.slug event=request.event.slug layout=l.id %}">
{% csrf_token %}
<button class="btn btn-default btn-sm">
{% trans "Make default" %}
</button>
</form>
{% endif %}
</td>
<td class="text-right">
{% if "can_change_event_settings" in request.eventpermset %}
<a href="{% url "plugins:ticketoutputpdf:edit" organizer=request.event.organizer.slug event=request.event.slug layout=l.id %}"
class="btn btn-default btn-sm"><i class="fa fa-edit"></i></a>
<a href="{% url "plugins:ticketoutputpdf:delete" organizer=request.event.organizer.slug event=request.event.slug layout=l.id %}"
class="btn btn-danger btn-sm"><i class="fa fa-trash"></i></a>
{% endif %}
</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
<div class="panel-footer">
{% include "pretixcontrol/pagination.html" %}
</div>
{% endif %}
</div>
{% endblock %}
@@ -77,6 +77,7 @@ class LayoutListView(EventPermissionRequiredMixin, ListView):
permission = ('can_change_event_settings')
template_name = 'pretixplugins/ticketoutputpdf/index.html'
context_object_name = 'layouts'
paginate_by = 25
def get_queryset(self):
return self.request.event.ticket_layouts.prefetch_related('item_assignments')
+16 -1
View File
@@ -19,6 +19,14 @@
}
}
.dl-left dt {
text-align: left;
}
.panel-body > dl:last-child, .panel-body > p:last-child {
margin-bottom: 0;
}
.navbar-inverse {
box-shadow: 0 2px 5px 0 rgba(78, 50, 92, .1), 0 1px 1px 0 rgba(0, 0, 0, .07);
margin: 0;
@@ -91,7 +99,14 @@
.panel-heading {
padding: 10px 15px;
}
.panel-heading small {
font-size: ceil(($font-size-base * 1.125));
color: $text-muted;
}
.panel-default > label > .panel-heading {
color: #333333;
border-color: #e5e5e5;
}
.panel-heading legend, .panel-heading .panel-title {
margin-top: 0;
margin-bottom: 0;
@@ -74,7 +74,9 @@ div[data-formset-body], div[data-formset-form], div[data-nested-formset-form], d
.panel-body .submit-group {
box-shadow: none;
padding: 0;
}
.panel-body .submit-group:first-child {
margin: 0 !important;
}
.panel .form-group:last-child {
@@ -351,7 +353,6 @@ table td > .checkbox input[type="checkbox"] {
}
.panel-default>.accordion-radio>.panel-heading {
color: #333;
background-color: #f5f5f5;
padding: 12px 15px;
input[type=checkbox] {
+1 -11
View File
@@ -480,20 +480,10 @@ body.loading #wrapper {
.quick-icon {
float: left;
width: 100px;
.fa-ticket, .fa-check-circle {
margin-top: -20px;
}
.fa-wrench {
margin-top: -30px;
}
.fa-money, .fa-envelope {
margin-top: -40px;
}
margin: 0;
}
.quick-icon .fa {
font-size: 100px;
line-height: 170px;
display: block;
}
.quick-content {