update templates

This commit is contained in:
Richard Schreiber
2024-11-22 11:12:57 +01:00
parent 3a1f19fa51
commit de6f6025e2
8 changed files with 188 additions and 132 deletions

View File

@@ -1,33 +1,39 @@
{% extends "pretixpresale/organizers/base.html" %} {% extends "pretixpresale/organizers/customer_base.html" %}
{% load i18n %} {% load i18n %}
{% load icon %}
{% load eventurl %} {% load eventurl %}
{% block title %}{% trans "Delete address" %}{% endblock %} {% block title %}{% trans "Delete address" %}{% endblock %}
{% block content %} {% block inner %}
<h2> <div class="panel panel-default">
{% trans "Delete address" %} <div class="panel-heading">
</h2> <h3 class="panel-title">
{% icon "address-card-o" %} <b>{% trans "Delete address" %}</b>
</h3>
</div>
<div class="panel-body account-addresses">
<p>
{% trans "Do you really want to delete the following address from your account?" %}
</p>
<address>
{{ address.describe|linebreaksbr }}
</address>
</div>
</div>
<form method="post"> <form method="post">
{% csrf_token %} {% csrf_token %}
<p>
{% trans "Do you really want to delete the following address from your account?" %}
</p>
<address>
{{ address.describe|linebreaksbr }}
</address>
<div class="row"> <div class="row">
<div class="col-md-4 col-sm-6"> <div class="col-md-4 col-sm-6">
<a class="btn btn-block btn-default btn-lg" <a class="btn btn-block btn-default btn-lg"
href="{% abseventurl request.organizer "presale:organizer.customer.profile" %}"> href="{% abseventurl request.organizer "presale:organizer.customer.addresses" %}">
{% trans "Go back" %} {% trans "Go back" %}
</a> </a>
</div> </div>
<div class="col-md-4 col-md-offset-4 col-sm-6"> <div class="col-md-4 col-md-offset-4 col-sm-6">
<button class="btn btn-block btn-danger btn-lg" type="submit"> <button class="btn btn-block btn-danger btn-lg" type="submit">
{% icon "trash" %}
{% trans "Delete" %} {% trans "Delete" %}
</button> </button>
</div> </div>
<div class="clearfix"></div>
</div> </div>
</form> </form>
{% endblock %} {% endblock %}

View File

@@ -1,15 +1,14 @@
{% extends "pretixpresale/organizers/customer_base.html" %} {% extends "pretixpresale/organizers/customer_base.html" %}
{% load i18n %} {% load i18n %}
{% load icon %}
{% load eventurl %} {% load eventurl %}
{% load urlreplace %} {% block title %}{% trans "Addresses" %}{% endblock %}
{% load money %}
{% load bootstrap3 %}
{% block title %}{% trans "Your account" %}{% endblock %}
{% block inner %} {% block inner %}
<div class="panel panel-default"> <div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h3 class="panel-title"> <h3 class="panel-title">
<span class="fa fa-address-card-o" aria-hidden="true"></span> <b>{% trans "Addresses" %}</b> ({{ page_obj.paginator.count }}) {% icon "address-card-o" %}
<b>{% trans "Addresses" %}</b> ({{ page_obj.paginator.count }})
</h3> </h3>
</div> </div>
<div class="panel-body"> <div class="panel-body">
@@ -26,7 +25,7 @@
<p class="blank-after"> <p class="blank-after">
<a href="{% abseventurl request.organizer "presale:organizer.customer.address.delete" id=ia.id %}" <a href="{% abseventurl request.organizer "presale:organizer.customer.address.delete" id=ia.id %}"
class="btn btn-danger btn-sm"> class="btn btn-danger btn-sm">
<span class="fa fa-trash" aria-hidden="true"></span> {% icon "trash" %}
{% trans "Delete" %} {% trans "Delete" %}
</a> </a>
</p> </p>

View File

@@ -1,7 +1,6 @@
{% extends "pretixpresale/organizers/base.html" %} {% extends "pretixpresale/organizers/base.html" %}
{% load i18n %} {% load i18n %}
{% load eventurl %} {% load eventurl %}
{% load bootstrap3 %}
{% block content %} {% block content %}
<h2> <h2>
{% trans "Your account" %} {% trans "Your account" %}

View File

@@ -1,96 +1,127 @@
{% extends "pretixpresale/organizers/base.html" %} {% extends "pretixpresale/organizers/customer_base.html" %}
{% load i18n %} {% load i18n %}
{% load icon %}
{% load eventurl %} {% load eventurl %}
{% load urlreplace %} {% load textblob %}
{% load money %}
{% load bootstrap3 %}
{% block title %}{% trans "Your membership" %}{% endblock %} {% block title %}{% trans "Your membership" %}{% endblock %}
{% block content %} {% block inner %}
<h2> <div class="panel panel-default">
{% trans "Your membership" %}
</h2>
<div class="panel panel-primary items">
<div class="panel-heading"> <div class="panel-heading">
<h3 class="panel-title"> <h3 class="panel-title">
{% trans "Details" %} {% if membership.membership_type.transferable %}
{% icon "users" %}
{% else %}
{% icon "id-badge" %}
{% endif %}
<b>{% trans "Your membership" %}</b>
{% if membership.testmode %}
<span class="h6">
{% textblob "warning" %}
{% trans "TEST MODE" %}
{% endtextblob %}
</span>
{% endif %}
</h3> </h3>
</div> </div>
<div class="panel-body"> <div class="panel-body">
<dl class="dl-horizontal"> <dl class="dl-horizontal">
<dt>{% trans "Membership type" %}</dt> <dt>{% trans "Membership type" %}</dt>
<dd>{{ membership.membership_type.name }}</dd> <dd>{% if membership.canceled %}<del>{% endif %}
{{ membership.membership_type.name }}
{% if membership.canceled %}</del>
<small>
{% textblob "danger" icon="times" %}
{% trans "Canceled" %}
{% endtextblob %}
</small>
{% endif %}
<br><small class="text-muted">
{% if membership.membership_type.transferable %}
({% trans "transferable" %})
{% else %}
({% trans "not transferable" %})
{% endif %}
</small>
</dd>
<dt>{% trans "Valid from" %}</dt> <dt>{% trans "Valid from" %}</dt>
<dd>{{ membership.date_start|date:"SHORT_DATETIME_FORMAT" }} <dd>{{ membership.date_start|date:"SHORT_DATETIME_FORMAT" }}
<dt>{% trans "Valid until" %}</dt> <dt>{% trans "Valid until" %}</dt>
<dd>{{ membership.date_end|date:"SHORT_DATETIME_FORMAT" }} <dd>{{ membership.date_end|date:"SHORT_DATETIME_FORMAT" }}
<dt>{% trans "Attendee name" %}</dt> <dt>{% trans "Attendee name" %}</dt>
<dd>{{ membership.attendee_name }} <dd>{{ membership.attendee_name|default_if_none:"" }}
<dt>{% trans "Maximum usages" %}</dt> <dt>{% trans "Maximum usages" %}</dt>
<dd>{{ membership.membership_type.max_usages|default_if_none:"" }}</dd> <dd>{{ membership.membership_type.max_usages|default_if_none:"" }}</dd>
</dl> </dl>
</div> </div>
</div> </div>
<div class="panel panel-default items"> <div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h3 class="panel-title"> <h3 class="panel-title">
{% trans "Usages" %} {% trans "Usages" %}
</h3> </h3>
</div> </div>
<table class="panel-body table table-hover"> <div class="panel-body">
<caption class="sr-only">{% trans "Usages" %}</caption> {% if usages %}
<thead> <ul class="full-width-list alternating-rows">
<tr>
<th>{% trans "Order code" %}</th>
<th>{% trans "Event" %}</th>
<th>{% trans "Product" %}</th>
<th>{% trans "Order date" %}</th>
<th class="text-right">{% trans "Status" %}</th>
<th class="text-right"></th>
</tr>
</thead>
<tbody>
{% for op in usages %} {% for op in usages %}
<tr> <li class="row">
<td> <dl>
<strong> <div class="col-md-4 col-sm-5 col-xs-12">
{{ op.order.code }}-{{ op.positionid }} <dt class="sr-only">{% trans "Order" %}</dt>
</strong> <dd><strong>
{% if op.order.testmode %} <a href="{% abseventurl op.order.event "presale:event.order" order=op.order.code secret=op.order.secret %}" target="_blank">
<span class="label label-warning">{% trans "TEST MODE" %}</span> <i class="fa fa-shopping-cart" aria-hidden="true"></i>
{% endif %} {{ op.order.code }}-{{ op.positionid }}
</td> </a>
<td> </strong>
{{ op.order.event }} <small>{% include "pretixpresale/event/fragment_order_status.html" with order=op.order event=op.order.event %}</small>
{% if op.subevent %} </dd>
<br> <dd><time datetime="{{ op.order.datetime|date:"Y-m-d H:i" }}" class="text-muted small">{{ op.order.datetime|date:"SHORT_DATETIME_FORMAT" }}</time></dd>
{{ op.subevent|default:"" }} {% if op.order.testmode %}
{% endif %} <dd>
</td> <small>
<td> {% textblob "warning" %}
{{ op.item.name }} {% trans "TEST MODE" %}
{% if op.variation %} {{ op.variation }}{% endif %} {% endtextblob %}
</td> </small>
<td> </dd>
{{ op.order.datetime|date:"SHORT_DATETIME_FORMAT" }} {% endif %}
</td> </div>
<td class="text-right flip"> <div class="col-md-6 col-sm-5 col-xs-8">
{% if op.canceled %} <dt class="sr-only">{% trans "Product" %}</dt>
{% trans "Canceled" %} <i class="{{ class }} fa fa-times-circle text-danger" aria-hidden="true"></i> <dd>{{ op.item.name }}
{% else %} {% if op.variation %} - {{ op.variation }}{% endif %}
{% include "pretixcontrol/orders/fragment_order_status.html" with order=op.order %} </dd>
{% endif %} <dt class="sr-only">{% trans "Event" %}</dt>
</td> <dd>
<td class="text-right flip"> <small class="text-muted">
<a href="{% abseventurl op.order.event "presale:event.order" order=op.order.code secret=op.order.secret %}" {{ op.order.event }}
target="_blank" {% if op.subevent %}
class="btn btn-default"> <br>{{ op.subevent }}
{% trans "Details" %} {% endif %}
</a> {% if not op.order.event.has_subevents and op.order.event.settings.show_dates_on_frontpage %}
</td> <br>{{ op.order.event.get_date_range_display }}
</tr> {% endif %}
{% endfor %} </small>
</tbody> </dd>
</table> </div>
{% include "pretixcontrol/pagination.html" %} <div class="col-sm-2 col-xs-4">
<dt class="sr-only">{% trans "Actions" %}</dt>
<dd class="text-right">
<a href="{% abseventurl op.order.event "presale:event.order" order=op.order.code secret=op.order.secret %}"
target="_blank">
<span class="fa fa-list-ul" aria-hidden="true"></span>
{% trans "Details" %}
</a></dd>
</div>
</dl>
</li>
{% endfor %}
</ul>
{% else %}
<p class="text-center">{% trans "You havent used this membership yet." %}</p>
{% endif %}
</div>
</div> </div>
{% include "pretixcontrol/pagination.html" %}
{% endblock %} {% endblock %}

View File

@@ -1,16 +1,15 @@
{% extends "pretixpresale/organizers/customer_base.html" %} {% extends "pretixpresale/organizers/customer_base.html" %}
{% load i18n %} {% load i18n %}
{% load icon %}
{% load eventurl %} {% load eventurl %}
{% load urlreplace %}
{% load money %}
{% load bootstrap3 %}
{% load textblob %} {% load textblob %}
{% block title %}{% trans "Your account" %}{% endblock %} {% block title %}{% trans "Memberships" %}{% endblock %}
{% block inner %} {% block inner %}
<div class="panel panel-default"> <div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h3 class="panel-title"> <h3 class="panel-title">
<span class="fa fa-id-badge" aria-hidden="true"></span> <b>{% trans "Memberships" %}</b> ({{ page_obj.paginator.count }}) {% icon "id-badge" %}
<b>{% trans "Memberships" %}</b> ({{ page_obj.paginator.count }})
</h3> </h3>
</div> </div>
<div class="panel-body"> <div class="panel-body">
@@ -22,7 +21,9 @@
<div class="col-xs-5"> <div class="col-xs-5">
<dt> <dt>
{% if m.canceled %}<del>{% endif %} {% if m.canceled %}<del>{% endif %}
{{ m.membership_type.name }} <a href="{% abseventurl request.organizer "presale:organizer.customer.membership" id=m.id %}">
{{ m.membership_type.name }}
</a>
{% if m.membership_type.transferable %} {% if m.membership_type.transferable %}
<span class="text-muted fa fa-users" aria-hidden="true" title="{% trans "Membership is transferable" %}"></span> <span class="text-muted fa fa-users" aria-hidden="true" title="{% trans "Membership is transferable" %}"></span>
{% endif %} {% endif %}
@@ -33,7 +34,11 @@
{% endtextblob %} {% endtextblob %}
</small> </small>
{% endif %} {% endif %}
{% if m.testmode %}<span class="label label-warning">{% trans "TEST MODE" %}</span>{% endif %} {% if m.testmode %}
{% textblob "warning" %}
{% trans "TEST MODE" %}
{% endtextblob %}
{% endif %}
</dt> </dt>
<dd class="text-muted"> <dd class="text-muted">
{% if not m.membership_type.transferable %} {% if not m.membership_type.transferable %}
@@ -61,11 +66,11 @@
<div class="col-xs-2"> <div class="col-xs-2">
<dt class="sr-only">{% trans "Actions" %}</dt> <dt class="sr-only">{% trans "Actions" %}</dt>
<dd class="text-right"> <dd class="text-right">
<a href="{% abseventurl request.organizer "presale:organizer.customer.membership" id=m.id %}" <a href="{% abseventurl request.organizer "presale:organizer.customer.membership" id=m.id %}">
target="_blank"> {% icon "list-ul" %}
<span class="fa fa-list-ul" aria-hidden="true"></span> {% trans "Details" %}
{% trans "Details" %} </a>
</a></dd> </dd>
</div> </div>
</dl> </dl>
</li> </li>

View File

@@ -1,9 +1,8 @@
{% extends "pretixpresale/organizers/customer_base.html" %} {% extends "pretixpresale/organizers/customer_base.html" %}
{% load i18n %} {% load i18n %}
{% load eventurl %} {% load eventurl %}
{% load urlreplace %}
{% load money %} {% load money %}
{% load bootstrap3 %} {% load textblob %}
{% block title %}{% trans "Your account" %}{% endblock %} {% block title %}{% trans "Your account" %}{% endblock %}
{% block inner %} {% block inner %}
<div class="panel panel-default"> <div class="panel panel-default">
@@ -34,8 +33,14 @@
<small>{% include "pretixpresale/event/fragment_order_status.html" with order=o event=o.event %}</small> <small>{% include "pretixpresale/event/fragment_order_status.html" with order=o event=o.event %}</small>
</dd> </dd>
<dd><time datetime="{{ o.datetime|date:"Y-m-d H:i" }}" class="text-muted small">{{ o.datetime|date:"SHORT_DATETIME_FORMAT" }}</time></dd> <dd><time datetime="{{ o.datetime|date:"Y-m-d H:i" }}" class="text-muted small">{{ o.datetime|date:"SHORT_DATETIME_FORMAT" }}</time></dd>
{% if o.testmode and False %} {% if o.testmode %}
<dd><span class="label label-warning">{% trans "TEST MODE" %}</span></dd> <dd>
<small>
{% textblob "warning" %}
{% trans "TEST MODE" %}
{% endtextblob %}
</small>
</dd>
{% endif %} {% endif %}
</div> </div>
<div class="col-md-2 col-sm-2 col-xs-4 text-right"> <div class="col-md-2 col-sm-2 col-xs-4 text-right">

View File

@@ -1,33 +1,39 @@
{% extends "pretixpresale/organizers/base.html" %} {% extends "pretixpresale/organizers/customer_base.html" %}
{% load i18n %} {% load i18n %}
{% load icon %}
{% load eventurl %} {% load eventurl %}
{% block title %}{% trans "Delete profile" %}{% endblock %} {% block title %}{% trans "Delete profile" %}{% endblock %}
{% block content %} {% block inner %}
<h2> <div class="panel panel-default">
{% trans "Delete profile" %} <div class="panel-heading">
</h2> <h3 class="panel-title">
{% icon "user" %} <b>{% trans "Delete profile" %}</b>
</h3>
</div>
<div class="panel-body">
<p>
{% trans "Do you really want to delete the following profile from your account?" %}
</p>
<p>
{{ profile.describe|linebreaksbr }}
</p>
</div>
</div>
<form method="post"> <form method="post">
{% csrf_token %} {% csrf_token %}
<p>
{% trans "Do you really want to delete the following profile from your account?" %}
</p>
<address>
{{ profile.describe|linebreaksbr }}
</address>
<div class="row"> <div class="row">
<div class="col-md-4 col-sm-6"> <div class="col-md-4 col-sm-6">
<a class="btn btn-block btn-default btn-lg" <a class="btn btn-block btn-default btn-lg"
href="{% abseventurl request.organizer "presale:organizer.customer.index" %}"> href="{% abseventurl request.organizer "presale:organizer.customer.profiles" %}">
{% trans "Go back" %} {% trans "Go back" %}
</a> </a>
</div> </div>
<div class="col-md-4 col-md-offset-4 col-sm-6"> <div class="col-md-4 col-md-offset-4 col-sm-6">
<button class="btn btn-block btn-danger btn-lg" type="submit"> <button class="btn btn-block btn-danger btn-lg" type="submit">
{% icon "trash" %}
{% trans "Delete" %} {% trans "Delete" %}
</button> </button>
</div> </div>
<div class="clearfix"></div>
</div> </div>
</form> </form>
{% endblock %} {% endblock %}

View File

@@ -1,10 +1,8 @@
{% extends "pretixpresale/organizers/customer_base.html" %} {% extends "pretixpresale/organizers/customer_base.html" %}
{% load i18n %} {% load i18n %}
{% load icon %}
{% load eventurl %} {% load eventurl %}
{% load urlreplace %} {% block title %}{% trans "Attendee profiles" %}{% endblock %}
{% load money %}
{% load bootstrap3 %}
{% block title %}{% trans "Your account" %}{% endblock %}
{% block inner %} {% block inner %}
<div class="panel panel-default"> <div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
@@ -15,17 +13,24 @@
<div class="panel-body"> <div class="panel-body">
{% if attendee_profiles %} {% if attendee_profiles %}
<ol class="full-width-list alternating-rows"> <ol class="full-width-list alternating-rows">
{% for ap in attendee_profiles %}
<li class="row"> <li class="row">
{{ ap.describe|linebreaksbr }} {% for ap in attendee_profiles %}
{% if forloop.counter0 and forloop.counter0|divisibleby:4 %}
<a href="{% abseventurl request.organizer "presale:organizer.customer.profile.delete" id=ap.id %}" </li>
class="btn btn-danger"> <li class="row">
<span class="fa fa-trash" aria-hidden="true"></span> {% endif %}
{% trans "Delete" %} <div class="col-md-3 col-xs-12">
</a> <p>{{ ap.describe|linebreaksbr }}</p>
</li> <p class="blank-after">
<a href="{% abseventurl request.organizer "presale:organizer.customer.profile.delete" id=ap.id %}"
class="btn btn-danger btn-sm">
{% icon "trash" %}
{% trans "Delete" %}
</a>
</p>
</div>
{% endfor %} {% endfor %}
</li>
</ol> </ol>
{% else %} {% else %}
<p class="text-center">{% trans "You dont have any attendee profiles in your account yet." %}</p> <p class="text-center">{% trans "You dont have any attendee profiles in your account yet." %}</p>