{% extends 'django_ledger/layouts/base.html' %}
{% load i18n %}
{% load static %}

{% block content %}

    <section class="section">
        <div class="container">
            <div class="columns is-centered">
                <div class="column is-6">
                    <div class="card">
                        <div class="card-header">
                            <div class="card-header-title">{% trans 'My Entities' %}</div>
                        </div>
                        <div class="card-content content">
                            <ul>
                                {% for entity in entities %}
                                    <li>{{ entity.name }}
                                        <a href="{{ entity.get_dashboard_url }}"
                                           class="button is-small is-primary">{% trans 'View' %}</a>
                                        <a href="{{ entity.get_delete_url }}"
                                           class="button is-small is-danger">{% trans 'Delete' %}</a>
                                    </li>
                                {% endfor %}
                            </ul>
                            <a href="{% url 'django_ledger:entity-create' %}"
                               class="button is-fullwidth is-primary is-outlined djetler_my_1">{% trans 'New Entity' %}</a>
                        </div>
                    </div>
                </div>
            </div>
        </div>

    </section>

{% endblock %}