forked from mmmaly/chcemvediet
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
* #334 Create BulkDeleteAdminMixin * #334 Indent li * #334 Create admin delete mixin templates * #334 Add empty div for amend workaround * #334 Workaround with fixed amend templatetag
- Loading branch information
1 parent
c91e384
commit 67d7867
Showing
11 changed files
with
126 additions
and
226 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
42 changes: 4 additions & 38 deletions
42
chcemvediet/apps/inforequests/templates/admin/inforequests/action/delete_confirmation.html
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 |
---|---|---|
@@ -1,45 +1,11 @@ | ||
{% extends "admin/delete_confirmation.html" %} | ||
{% load amend prepend before after set_attributes from poleno.amend %} | ||
{% load amend from poleno.amend %} | ||
|
||
{% block content %} | ||
{% amend %} | ||
{{ block.super }} | ||
{% after path="./ul[last()]" %} | ||
{% if outbound %} | ||
<p>The following outbound messages will be deleted:</p> | ||
<ul>{{ outbound|unordered_list }}</ul> | ||
{% endif %} | ||
{% if inbound %} | ||
<p>The following inbound messages will be marked undecided:</p> | ||
<ul>{{ inbound|unordered_list }}</ul> | ||
{% endif %} | ||
{% endafter %} | ||
{% if snoozed_actions %} | ||
{% prepend path=".//form" %} | ||
<p> | ||
<label><input name="snooze" type="checkbox" /> Extend snooze of previous actions by | ||
{{ ADMIN_EXTEND_SNOOZE_BY_DAYS }} days from today? All of the following actions will be | ||
snoozed: | ||
</label> | ||
</p> | ||
<ul>{{ snoozed_actions|unordered_list }}</ul> | ||
{% endprepend %} | ||
{% endif %} | ||
{% before path=".//form//input[@type='submit']" %} | ||
{% if delete_warnings %} | ||
<ul class="messagelist"> | ||
{% for warning in delete_warnings %} | ||
<li class="warning">{{ warning }}</li> | ||
{% endfor %} | ||
</ul> | ||
{% endif %} | ||
{% if delete_constraints %} | ||
<div class="errornote"> | ||
<p>Delete not allowed.</p> | ||
<ul>{{ delete_constraints|unordered_list }}</ul> | ||
</div> | ||
{% set_attributes path=".//form//input[@type='submit']" disabled=True %} | ||
{% endif %} | ||
{% endbefore %} | ||
{% include "admin/inforequests/mixins/delete_nested_inforequest_email_mixin.html" %} | ||
{% include "admin/inforequests/mixins/snoozed_actions_mixin.html" %} | ||
{% include "utils/admin/bulk_delete_mixin.html" %} | ||
{% endamend %} | ||
{% endblock %} |
42 changes: 4 additions & 38 deletions
42
...t/apps/inforequests/templates/admin/inforequests/action/delete_selected_confirmation.html
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 |
---|---|---|
@@ -1,45 +1,11 @@ | ||
{% extends "admin/delete_selected_confirmation.html" %} | ||
{% load amend prepend before after set_attributes from poleno.amend %} | ||
{% load amend from poleno.amend %} | ||
|
||
{% block content %} | ||
{% amend %} | ||
{{ block.super }} | ||
{% after path="./ul[last()]" %} | ||
{% if outbound %} | ||
<p>The following outbound messages will be deleted:</p> | ||
<ul>{{ outbound|unordered_list }}</ul> | ||
{% endif %} | ||
{% if inbound %} | ||
<p>The following inbound messages will be marked undecided:</p> | ||
<ul>{{ inbound|unordered_list }}</ul> | ||
{% endif %} | ||
{% endafter %} | ||
{% if snoozed_actions %} | ||
{% prepend path=".//form" %} | ||
<p> | ||
<label><input name="snooze" type="checkbox" /> Extend snooze of previous actions by | ||
{{ ADMIN_EXTEND_SNOOZE_BY_DAYS }} days from today? All of the following actions will be | ||
snoozed: | ||
</label> | ||
</p> | ||
<ul>{{ snoozed_actions|unordered_list }}</ul> | ||
{% endprepend %} | ||
{% endif %} | ||
{% before path=".//form//input[@type='submit']" %} | ||
{% if delete_warnings %} | ||
<ul class="messagelist"> | ||
{% for warning in delete_warnings %} | ||
<li class="warning">{{ warning }}</li> | ||
{% endfor %} | ||
</ul> | ||
{% endif %} | ||
{% if delete_constraints %} | ||
<div class="errornote"> | ||
<p>Delete not allowed.</p> | ||
<ul>{{ delete_constraints|unordered_list }}</ul> | ||
</div> | ||
{% set_attributes path=".//form//input[@type='submit']" disabled=True %} | ||
{% endif %} | ||
{% endbefore %} | ||
{% include "admin/inforequests/mixins/delete_nested_inforequest_email_mixin.html" %} | ||
{% include "admin/inforequests/mixins/snoozed_actions_mixin.html" %} | ||
{% include "utils/admin/bulk_delete_mixin.html" %} | ||
{% endamend %} | ||
{% endblock %} |
23 changes: 3 additions & 20 deletions
23
chcemvediet/apps/inforequests/templates/admin/inforequests/branch/delete_confirmation.html
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 |
---|---|---|
@@ -1,27 +1,10 @@ | ||
{% extends "admin/delete_confirmation.html" %} | ||
{% load amend before after set_attributes from poleno.amend %} | ||
{% load amend from poleno.amend %} | ||
|
||
{% block content %} | ||
{% amend %} | ||
{{ block.super }} | ||
{% after path="./ul[last()]" %} | ||
{% if outbound %} | ||
<p>The following outbound messages will be deleted:</p> | ||
<ul>{{ outbound|unordered_list }}</ul> | ||
{% endif %} | ||
{% if inbound %} | ||
<p>The following inbound messages will be marked undecided:</p> | ||
<ul>{{ inbound|unordered_list }}</ul> | ||
{% endif %} | ||
{% endafter %} | ||
{% if delete_constraints %} | ||
{% before path=".//form" %} | ||
<div class="errornote"> | ||
<p>Delete not allowed.</p> | ||
<ul>{{ delete_constraints|unordered_list }}</ul> | ||
</div> | ||
{% endbefore %} | ||
{% set_attributes path=".//form//input[@type='submit']" disabled=True %} | ||
{% endif %} | ||
{% include "admin/inforequests/mixins/delete_nested_inforequest_email_mixin.html" %} | ||
{% include "utils/admin/bulk_delete_mixin.html" %} | ||
{% endamend %} | ||
{% endblock %} |
23 changes: 3 additions & 20 deletions
23
...t/apps/inforequests/templates/admin/inforequests/branch/delete_selected_confirmation.html
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 |
---|---|---|
@@ -1,27 +1,10 @@ | ||
{% extends "admin/delete_selected_confirmation.html" %} | ||
{% load amend before after set_attributes from poleno.amend %} | ||
{% load amend from poleno.amend %} | ||
|
||
{% block content %} | ||
{% amend %} | ||
{{ block.super }} | ||
{% after path="./ul[last()]" %} | ||
{% if outbound %} | ||
<p>The following outbound messages will be deleted:</p> | ||
<ul>{{ outbound|unordered_list }}</ul> | ||
{% endif %} | ||
{% if inbound %} | ||
<p>The following inbound messages will be marked undecided:</p> | ||
<ul>{{ inbound|unordered_list }}</ul> | ||
{% endif %} | ||
{% endafter %} | ||
{% before path=".//form//input[@type='submit']" %} | ||
{% if delete_constraints %} | ||
<div class="errornote"> | ||
<p>Delete not allowed.</p> | ||
<ul>{{ delete_constraints|unordered_list }}</ul> | ||
</div> | ||
{% set_attributes path=".//form//input[@type='submit']" disabled=True %} | ||
{% endif %} | ||
{% endbefore %} | ||
{% include "admin/inforequests/mixins/delete_nested_inforequest_email_mixin.html" %} | ||
{% include "utils/admin/bulk_delete_mixin.html" %} | ||
{% endamend %} | ||
{% endblock %} |
12 changes: 2 additions & 10 deletions
12
.../apps/inforequests/templates/admin/inforequests/inforequestemail/delete_confirmation.html
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 |
---|---|---|
@@ -1,17 +1,9 @@ | ||
{% extends "admin/delete_confirmation.html" %} | ||
{% load amend before set_attributes from poleno.amend %} | ||
{% load amend from poleno.amend %} | ||
|
||
{% block content %} | ||
{% amend %} | ||
{{ block.super }} | ||
{% if delete_constraints %} | ||
{% before path=".//form" %} | ||
<div class="errornote"> | ||
<p>Delete not allowed.</p> | ||
<ul>{{ delete_constraints|unordered_list }}</ul> | ||
</div> | ||
{% endbefore %} | ||
{% set_attributes path=".//form//input[@type='submit']" disabled=True %} | ||
{% endif %} | ||
{% include "utils/admin/bulk_delete_mixin.html" %} | ||
{% endamend %} | ||
{% endblock %} |
Oops, something went wrong.