-
Notifications
You must be signed in to change notification settings - Fork 54
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add duplicate confirmation for admins
Fixes #943. We cheat a little in that the badge gets created before we ask for confirmation, but at least this way admins get a chance to immediately undo their mistake.
- Loading branch information
Showing
2 changed files
with
73 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
{% extends "base.html" %}{% set admin_area=True %} | ||
{% block title %}That attendee already has a badge{% endblock %} | ||
{% block content %} | ||
<div class="panel panel-default"> | ||
<div class="panel-body"> | ||
<h2>This attendee already has a badge!</h2> | ||
|
||
We already have a <a href="form?id={{ attendee.id }}">{{ attendee.full_name }}</a> with email address {{ attendee.email }} in our database with a | ||
{% if attendee.paid == c.PAID_BY_GROUP and attendee.group.status == c.WAITLISTED %} | ||
waitlisted | ||
{% elif attendee.paid == c.HAS_PAID or attendee.paid == c.PAID_BY_GROUP %} | ||
paid | ||
{% elif attendee.paid == c.NEED_NOT_PAY %} | ||
complementary | ||
{% elif attendee.paid == c.NOT_PAID %} | ||
unpaid | ||
{% else %} | ||
{{ attendee.paid_label }} | ||
{% endif %} | ||
{{ attendee.badge_type_label }} | ||
{% if attendee.ribbon != c.NO_RIBBON %} | ||
({{ attendee.ribbon_label }}) | ||
{% endif %} | ||
badge{% if attendee.group %} | ||
(with the group <a href="./group/form?id={{ attendee.group.id }}">{{ attendee.group.name }}</a>) | ||
{% endif %}. | ||
|
||
<br/> <br/> | ||
|
||
If you're <strong>absolutely</strong> sure that this is someone else, please confirm this. We highly recommend | ||
editing the attendee's name if at all possible, as badges with duplicate names may be picked up by the wrong | ||
person. | ||
{% if attendee.paid == c.PAID_BY_GROUP and attendee.group.status == c.WAITLISTED %} | ||
Please keep in mind that dealers have an option to buy their badge once the Marketplace fills up, so you | ||
normally do not need to create an additional badge for them. | ||
{% endif %} | ||
If you are at all not sure what to do, contact your Registration department at {{ c.REGDESK_EMAIL }}. | ||
|
||
<br/> <br/> | ||
|
||
<table style="width:auto" align="center"> | ||
<tr> | ||
<td class="btn-group"> | ||
<a class="btn btn-default" href="form?id={{ attendee.id }}">Let me go back and edit their info!</a> | ||
<a class="btn btn-default" href="{{ return_to }}">Take me back to where I was going!</a> | ||
</td> | ||
<td> </td> | ||
<td> | ||
<form method="post" action="delete"> | ||
<input type="hidden" name="id" value="{{ attendee.id }}"/> | ||
{{ csrf_token() }} | ||
<button class="btn btn-danger" type="submit">Whoops, undo this badge!</button> | ||
</form> | ||
</td> | ||
</tr> | ||
</table> | ||
</div> | ||
</div> | ||
|
||
{% endblock %} |