{% extends view.base_template|default:"base.html" %}
{% load i18n %}
{% load lazycrud %}

{% block title %}{{ object }}{% endblock %}

{% block content %}
<div class="row">
    <div class="col-lg-12">
        <h1 class="page-header">
        {% block page_header %}
            {{ object }}
        {% endblock page_header %}
        </h1>
    </div>
</div>
<div class="row">
    <div class="col-lg-12">
        <div class="pull-right">
    {% block buttons %}
        {% if view.list_url %}
            <a class="btn btn-primary" role="button" href="{{ view.list_url }}"><i class="fa fa-angle-left"></i> {% trans 'Back to list' %}</a>
        {% endif %}
        {% if view.update_url %}
            <a class="btn btn-warning" role="button" href="{% url view.update_url pk=object.pk %}"><i class="fa fa-edit"></i> {% trans 'Edit' %}</a>
        {% endif %}
        {% if view.delete_url %}
            <a class="btn btn-danger" role="button" href="{% url view.delete_url pk=object.pk %}"><i class="fa fa-times"></i> {% trans 'Delete' %}</a>
        {% endif %}
    {% endblock %}
        </div>
    </div>
</div>
<hr>
<div class="row">
    {% block left_col %}
    <div class="{{ view.left_col_class|default:'col-md-6' }}">
        <dl class="dl-horizontal">
        {% for name in view.fields %}
            {{ object|dl_item:name }}
        {% endfor %}
        </dl>
    </div>
    {% endblock %}
    {% block right_col %}{% endblock %}
</div>
{% endblock %}
