membershipworks: Add admin links to event reports
All checks were successful
Ruff / ruff (push) Successful in 20s
All checks were successful
Ruff / ruff (push) Successful in 20s
This commit is contained in:
parent
138236a8eb
commit
fc5a911c76
@ -3,6 +3,9 @@
|
|||||||
{% load render_table from django_tables2 %}
|
{% load render_table from django_tables2 %}
|
||||||
|
|
||||||
{% block title %}Event Report Index{% endblock %}
|
{% block title %}Event Report Index{% endblock %}
|
||||||
|
{% block admin_link %}
|
||||||
|
{% url 'admin:membershipworks_eventext_changelist' %}
|
||||||
|
{% endblock %}
|
||||||
{% block breadcrumbs %}<li class="breadcrumb-item active" aria-current="page">MW Event Reports</li>{% endblock %}
|
{% block breadcrumbs %}<li class="breadcrumb-item active" aria-current="page">MW Event Reports</li>{% endblock %}
|
||||||
{% block content %}
|
{% block content %}
|
||||||
{% include "cmsmanage/components/download_table.dj.html" %}
|
{% include "cmsmanage/components/download_table.dj.html" %}
|
||||||
|
@ -3,6 +3,9 @@
|
|||||||
{% load render_table from django_tables2 %}
|
{% load render_table from django_tables2 %}
|
||||||
|
|
||||||
{% block title %}Event Report {{ month|date:"N Y" }}{% endblock %}
|
{% block title %}Event Report {{ month|date:"N Y" }}{% endblock %}
|
||||||
|
{% block admin_link %}
|
||||||
|
{% url 'admin:membershipworks_eventext_changelist' %}?start__year={{ month|date:"Y" }}&start__month={{ month|date:"m" }}
|
||||||
|
{% endblock %}
|
||||||
{% block breadcrumbs %}
|
{% block breadcrumbs %}
|
||||||
<li class="breadcrumb-item">
|
<li class="breadcrumb-item">
|
||||||
<a href="{% url 'membershipworks:event-index-report' %}">MW Event Reports</a>
|
<a href="{% url 'membershipworks:event-index-report' %}">MW Event Reports</a>
|
||||||
|
@ -3,6 +3,9 @@
|
|||||||
{% load render_table from django_tables2 %}
|
{% load render_table from django_tables2 %}
|
||||||
|
|
||||||
{% block title %}Event Report {{ year|date:"Y" }}{% endblock %}
|
{% block title %}Event Report {{ year|date:"Y" }}{% endblock %}
|
||||||
|
{% block admin_link %}
|
||||||
|
{% url 'admin:membershipworks_eventext_changelist' %}?start__year={{ year|date:"Y" }}
|
||||||
|
{% endblock %}
|
||||||
{% block breadcrumbs %}
|
{% block breadcrumbs %}
|
||||||
<li class="breadcrumb-item">
|
<li class="breadcrumb-item">
|
||||||
<a href="{% url 'membershipworks:event-index-report' %}">MW Event Reports</a>
|
<a href="{% url 'membershipworks:event-index-report' %}">MW Event Reports</a>
|
||||||
|
@ -126,8 +126,11 @@ class DurationColumn(tables.Column):
|
|||||||
|
|
||||||
|
|
||||||
class EventTable(tables.Table):
|
class EventTable(tables.Table):
|
||||||
title = tables.Column(
|
title = tables.TemplateColumn(
|
||||||
linkify=lambda record: f"https://membershipworks.com/admin/#!event/admin/{record.url}"
|
template_code=(
|
||||||
|
'<a title="MembershipWorks" href="https://membershipworks.com/admin/#!event/admin/{{ record.url }}">{{ value }}</a> '
|
||||||
|
'<a title="Admin" href="{% url "admin:membershipworks_eventext_change" record.pk %}"><i class="bi bi-pencil-square"></i></a> '
|
||||||
|
),
|
||||||
)
|
)
|
||||||
occurred = tables.BooleanColumn(visible=False)
|
occurred = tables.BooleanColumn(visible=False)
|
||||||
start = tables.DateColumn("N d, Y")
|
start = tables.DateColumn("N d, Y")
|
||||||
|
Loading…
Reference in New Issue
Block a user