{% extends "base.html" %}

{% block content_title %}Cursos{% endblock %}
{% block box_title %}Detalhes Curso: <span class="label label-info">{{ object.pk }}</span>{% endblock %}

{% block box_body %}

    <div class="page-header">
        <a class="btn btn-large btn-default" title="Lista" href="{% url 'curso_home' %}"><i class="fa fa-list fa-1x"></i></a>
        <a class="btn btn-large btn-warning" title="Editar" href="{% url 'curso_atualizar' object.pk %}"><i class="fa fa-edit fa-1x"></i></a>
        <a class="btn btn-large btn-info" title="Imprimir" href="{% url 'imprime_curso' object.pk %}" ><i class="fa fa-print fa-1x"></i> </a>
        <a class="btn btn-large btn-danger" title="Excluir" href="{% url 'curso_deletar' object.pk %}"><i class="fa fa-remove fa-1x"></i></a>
    </div>

    <div class="row">
        <div class="col-md-4">
            <div class="panel panel-primary">
                <div class="panel-heading">
                    <h3 class="panel-title">
                        Descrição</h3>
                    <span class="pull-right clickable"></span>
                </div>
                <div class="panel-body">
                    {{ object.descricao }}
                </div>
            </div>
        </div>
        <div class="col-md-4">
            <div class="panel panel-primary">
                <div class="panel-heading">
                    <h3 class="panel-title">
                        Quantidade de Vagas</h3>
                    <span class="pull-right clickable"></span>
                </div>
                <div class="panel-body">
                    {{ object.quant_vaga }}
                </div>
            </div>
        </div>
        <div class="col-md-4">
            <div class="panel panel-primary">
                <div class="panel-heading">
                    <h3 class="panel-title">
                        Carga Horária</h3>
                    <span class="pull-right clickable"></span>
                </div>
                <div class="panel-body">
                    {{ object.carga_horaria }}
                </div>
            </div>
        </div>
    </div>

    <div class="row">
        <div class="col-md-3">
            <div class="panel panel-primary">
                <div class="panel-heading">
                    <h3 class="panel-title">
                        Semestre</h3>
                    <span class="pull-right clickable"></span>
                </div>
                <div class="panel-body">
                    {{ object.semestre }}
                </div>
            </div>
        </div>
        <div class="col-md-3">
            <div class="panel panel-primary">
                <div class="panel-heading">
                    <h3 class="panel-title">
                        Turno</h3>
                    <span class="pull-right clickable"></span>
                </div>
                <div class="panel-body">
                    {{ object.turno }}
                </div>
            </div>
        </div>
        <div class="col-md-3">
            <div class="panel panel-primary">
                <div class="panel-heading">
                    <h3 class="panel-title">
                        Pré-Requisito</h3>
                    <span class="pull-right clickable"></span>
                </div>
                <div class="panel-body">
                    {{ object.get_pre_requisito_display }}
                </div>
            </div>
        </div>
        <div class="col-md-3">
            <div class="panel panel-primary">
                <div class="panel-heading">
                    <h3 class="panel-title">
                        Ativo</h3>
                    <span class="pull-right clickable"></span>
                </div>
                <div class="panel-body">
                    {{ object.get_ativo_display }}
                </div>
            </div>
        </div>
    </div>


    <div class="row">
        <div class="col-md-2">
            <div class="panel panel-info">
                <div class="panel-heading clickable">
                    <h3 class="panel-title">
                        Quem Cadastrou</h3>
                    <span class="pull-right "></span>
                </div>
                <div class="panel-body">
                    {% if object.quem_criou %}
                        {{ object.quem_criou }}
                    {% else %}
                        Não Informado!
                    {% endif %}
                </div>
            </div>
        </div>
        <div class="col-md-2">
            <div class="panel panel-info">
                <div class="panel-heading clickable">
                    <h3 class="panel-title">
                        Data Cadastro</h3>
                    <span class="pull-right "></span>
                </div>
                <div class="panel-body">
                    {{ object.data_criacao|date:"d/m/Y"|default:"--/--/---" }}
                </div>
            </div>
        </div>
        <div class="col-md-2">
            <div class="panel panel-info">
                <div class="panel-heading clickable">
                    <h3 class="panel-title">
                        Hora Cadastro</h3>
                    <span class="pull-right "></span>
                </div>
                <div class="panel-body">
                    {{ object.hora_criacao|time:"h:i:s"|default:"--:--" }}
                </div>
            </div>
        </div>

        <div class="col-md-2">
            <div class="panel panel-info">
                <div class="panel-heading clickable">
                    <h3 class="panel-title">
                        Quem Alterou</h3>
                    <span class="pull-right "></span>
                </div>
                <div class="panel-body">
                    {% if object.quem_alterou %}
                        {{ object.quem_alterou }}
                    {% else %}
                        Não Informado!
                    {% endif %}
                </div>
            </div>
        </div>
        <div class="col-md-2">
            <div class="panel panel-info">
                <div class="panel-heading clickable">
                    <h3 class="panel-title">
                        Data Alteração</h3>
                    <span class="pull-right "></span>
                </div>
                <div class="panel-body">
                    {{ object.data_alteracao|date:"d/m/Y" }}
                </div>
            </div>
        </div>
        <div class="col-md-2">
            <div class="panel panel-info">
                <div class="panel-heading clickable">
                    <h3 class="panel-title">
                        Hora Alteração</h3>
                    <span class="pull-right "></span>
                </div>
                <div class="panel-body">
                    {{ object.hora_alteracao|time:"h:i:s" }}
                </div>
            </div>
        </div>
    </div>

{% endblock %}