{{ header }}{{ column_left }}
<div id="content">
  <div class="page-header">
    <div class="container-fluid">
      <div class="pull-right">
        <a href="{{ add }}" data-toggle="tooltip" title="{{ button_add }}" class="btn btn-primary"><i class="fa fa-plus"></i></a>
        <a href="{{ cancel }}" data-toggle="tooltip" title="{{ button_cancel }}" class="btn btn-default"><i class="fa fa-reply"></i></a></div>
      <h1>{{ heading_title }}</h1>
      <ul class="breadcrumb">
        {% for breadcrumb in breadcrumbs %}
        <li><a href="{{ breadcrumb.href }}">{{ breadcrumb.text }}</a></li>
        {% endfor %}
      </ul>
    </div>
  </div>
  <div class="container-fluid">
    {% if error_warning %}
      <div class="alert alert-danger alert-dismissible"><i class="fa fa-exclamation-circle"></i> {{ error_warning }}</div>
    {% endif %}
    {% if success %}
      <div class="alert alert-success alert-dismissible"><i class="fa fa-check-circle"></i> {{ success }}</div>
    {% endif %}
    <div class="panel panel-default">
      <div class="panel-heading">
        <h3 class="panel-title"><i class="fa fa-list"></i> {{ text_list }}</h3>
      </div>
      <div class="panel-body">
      <table class="table table-bordered table-hover">
        <thead>
          <tr>
            <td class="text-left">{{ column_name }}</td>
            <td class="text-center">{{ column_action }}</td>
          </tr>
        </thead>
        <tbody>
        {% if templates %}
          {% for template in templates %}
            <tr>
              <td class="text-left">{{ template.name }}</td>
              <td class="text-right">
                <a href="{{ template.link_edit }}" data-toggle="tooltip" title="{{ button_edit }}" class="btn btn-primary"><i class="fa fa-pencil"></i></a>&nbsp;
                <a href="{{ template.link_delete }}" data-toggle="tooltip" title="{{ button_delete }}" class="btn btn-danger profile-delete"><i class="fa fa-minus-circle"></i></a>
              </td>
            </tr>
          {% endfor %}
        {% else %}
          <tr>
            <td class="text-center" colspan="2">{{ text_no_results }}</td>
          </tr>
        {% endif %}
        </tbody>
      </table>
    </div>
    </div>
  </div>
</div>
<script type="text/javascript"><!--
  $(document).ready(function() {
    $('a.profile-delete').click(function(event) {
      event.preventDefault();
      var url = $(this).attr('href');
      var confirm_box = confirm('{{ text_confirm_delete }}');
      if (confirm_box) {
        window.location = url;
      }
    });
  });
//--></script>
{{ footer }}