2021-03-16 15:00:08 -04:00
|
|
|
{% extends base_template %}
|
|
|
|
{% load form_helpers %}
|
2021-07-12 15:36:51 -04:00
|
|
|
{% load render_table from django_tables2 %}
|
2021-03-16 15:00:08 -04:00
|
|
|
|
2021-03-17 22:37:13 -07:00
|
|
|
{% render_errors form %}
|
|
|
|
|
2021-03-16 15:00:08 -04:00
|
|
|
{% block content %}
|
2021-07-20 13:21:09 -04:00
|
|
|
{% if perms.extras.add_journalentry %}
|
2021-03-17 23:32:08 -07:00
|
|
|
<form action="{% url 'extras:journalentry_add' %}" method="post" enctype="multipart/form-data">
|
2021-07-20 13:21:09 -04:00
|
|
|
<div class="container">
|
|
|
|
<div class="field-group">
|
|
|
|
<h4>New Journal Entry</h4>
|
|
|
|
{% csrf_token %}
|
|
|
|
{% for field in form.hidden_fields %}
|
|
|
|
{{ field }}
|
|
|
|
{% endfor %}
|
|
|
|
{% render_field form.kind %}
|
|
|
|
{% render_field form.comments %}
|
2021-03-16 15:00:08 -04:00
|
|
|
</div>
|
2021-07-20 13:21:09 -04:00
|
|
|
<div class="col col-md-12 text-end my-3">
|
|
|
|
<a href="{{ object.get_absolute_url }}" class="btn btn-outline-danger">Cancel</a>
|
|
|
|
<button type="submit" class="btn btn-primary">Save</button>
|
|
|
|
</div>
|
|
|
|
</div>
|
2021-03-17 23:32:08 -07:00
|
|
|
</form>
|
2021-07-20 13:21:09 -04:00
|
|
|
{% endif %}
|
2021-12-15 10:34:20 -05:00
|
|
|
<div class="card">
|
|
|
|
<div class="card-body table-responsive">
|
|
|
|
{% render_table table 'inc/table.html' %}
|
|
|
|
{% include 'inc/paginator.html' with paginator=table.paginator page=table.page %}
|
|
|
|
</div>
|
2021-12-13 15:36:51 -05:00
|
|
|
</div>
|
2021-03-16 15:00:08 -04:00
|
|
|
{% endblock %}
|