{% extends 'layout/page.html' %}

{% block title %}
  People
{% endblock %}

{% block content %}
  {% include 'person-searchform.twig' %}

  {% if q and not people %}
    <p class="lead">
      <strong>No results found.</strong>
      Nothing was found for those search parameters.
      {% if not (q matches '/active:0/') %}
        <a href="{{ current_path(true) ~ ' active:0' }}">Try again with inactive people.</a>
      {% endif %}
    </p>
  {% endif %}

  {% if people %}
    <table id="people" class="table table-striped table-hover">
      <thead>
        <tr>
          <th>#</th>
          <th>Name</th>
          <th>Company</th>
          <th>Phone</th>
        </tr>
      </thead>
      <tbody>
      {% for person in people %}
        <tr>
          <td class="num">
            <a href="/person/{{ person.id }}">{{ loop.index }}</a>
          </td>
          <td>
            <a href="/person/{{ person.id }}">{{ person.name }}</a>
          </td>
          <td>
            <a href="/person/{{ person.id }}">{{ person.company }}</a>
          </td>
          <td>
            <a href="/person/{{ person.id }}">{{ person.pretty_phone }}</a>
          </td>
        </a>
        </tr>
      {% endfor %}
      </tbody>
    </table>
    <style>
      #people a { display: block }
    </style>
  {% endif %}
{% endblock %}

{% extends 'layout/page.html' %}

{% block title %}
  People
{% endblock %}

{% block content %}
  {% include 'person-searchform.twig' %}

  {% if q and not people %}
    <p class="lead">
      <strong>No results found.</strong>
      Nothing was found for those search parameters.
      {% if not (q matches '/active:0/') %}
        <a href="{{ current_path(true) ~ ' active:0' }}">Try again with inactive people.</a>
      {% endif %}
    </p>
  {% endif %}

  {% if people %}
    <table id="people" class="table table-striped table-hover">
      <thead>
        <tr>
          <th>#</th>
          <th>Name</th>
          <th>Company</th>
          <th>Phone</th>
          <th>Email</th>
        </tr>
      </thead>
      <tbody>
      {% for person in people %}
        <tr>
          <td class="num">
            <a href="/person/{{ person.id }}">{{ loop.index }}</a>
          </td>
          <td>
            <a href="/person/{{ person.id }}">{{ person.name }}</a>
          </td>
          <td>
            <a href="/person/{{ person.id }}">{{ person.company }}</a>
          </td>
          <td>
            <a href="/person/{{ person.id }}">{{ person.pretty_phone }}</a>
          </td>
          <td>
            <a href="/person/{{ person.id }}">{{ person.email }}</a>
          </td>
        </a>
        </tr>
      {% endfor %}
      </tbody>
    </table>
    <style>
      #people a { display: block }
    </style>
  {% endif %}
{% endblock %}

Include email in search results
Include email in search results
