73 lines
3.1 KiB
HTML
73 lines
3.1 KiB
HTML
{% extends "administration/base.html" %}
|
|
|
|
{% load i18n %}
|
|
{% load utils %}
|
|
|
|
{% block content %}
|
|
<section class="pf-c-page__main-section pf-m-light">
|
|
<div class="pf-c-content">
|
|
<h1>
|
|
<i class="pf-icon pf-icon-blueprint"></i>
|
|
{% trans 'Property Mappings' %}
|
|
</h1>
|
|
<p>{% trans "Control how passbook exposes and interprets information." %}
|
|
</p>
|
|
</div>
|
|
</section>
|
|
<section class="pf-c-page__main-section pf-m-no-padding-mobile">
|
|
<div class="pf-c-card">
|
|
<div class="pf-c-toolbar" id="page-layout-table-simple-toolbar-top">
|
|
<div class="pf-c-toolbar__action-group">
|
|
<div class="pf-c-dropdown">
|
|
<button class="pf-m-primary pf-c-dropdown__toggle" type="button">
|
|
<span class="pf-c-dropdown__toggle-text">{% trans 'Create' %}</span>
|
|
<i class="fas fa-caret-down pf-c-dropdown__toggle-icon" aria-hidden="true"></i>
|
|
</button>
|
|
<ul class="pf-c-dropdown__menu" hidden>
|
|
{% for type, name in types.items %}
|
|
<li>
|
|
<a class="pf-c-dropdown__menu-item"
|
|
href="{% url 'passbook_admin:property-mapping-create' %}?type={{ type }}&back={{ request.get_full_path }}">{{ name }}</a>
|
|
</li>
|
|
{% endfor %}
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
{% include 'partials/pagination.html' %}
|
|
</div>
|
|
<table class="pf-c-table pf-m-compact pf-m-grid-xl" role="grid">
|
|
<thead>
|
|
<tr role="row">
|
|
<th role="columnheader" scope="col">{% trans 'Name' %}</th>
|
|
<th role="columnheader" scope="col">{% trans 'Type' %}</th>
|
|
<th role="cell"></th>
|
|
</tr>
|
|
</thead>
|
|
<tbody role="rowgroup">
|
|
{% for property_mapping in object_list %}
|
|
<tr role="row">
|
|
<td role="cell">
|
|
<span>
|
|
{{ property_mapping.name }}
|
|
</span>
|
|
</td>
|
|
<td role="cell">
|
|
<span>
|
|
{{ property_mapping|verbose_name }}
|
|
</span>
|
|
</td>
|
|
<td>
|
|
<a class="pf-c-button pf-m-secondary" href="{% url 'passbook_admin:property-mapping-update' pk=property_mapping.pk %}?back={{ request.get_full_path }}">{% trans 'Edit' %}</a>
|
|
<a class="pf-c-button pf-m-danger" href="{% url 'passbook_admin:property-mapping-delete' pk=property_mapping.pk %}?back={{ request.get_full_path }}">{% trans 'Delete' %}</a>
|
|
</td>
|
|
</tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
</table>
|
|
<div class="pf-c-toolbar" id="page-layout-table-simple-toolbar-bottom">
|
|
{% include 'partials/pagination.html' %}
|
|
</div>
|
|
</div>
|
|
</section>
|
|
{% endblock %}
|