templates/web/person/index.html.twig line 1

  1. {% extends 'base.html.twig' %}
    
    {% block title %}{{title}}{% endblock %}
    
    {% block body %}
            <div class="container">
                {{ category.html|raw }}
                <form action="#">
                    <div class="row mb-7">
                        <div class="col-lg-4 mt-5">
                            <label for="searchEmployee">{% trans %}vyhledat.zamestnance{% endtrans %}</label>
                            <div class="input-wrapper input-wrapper--search">
                                <input type="text" id="searchEmployee" class="input">
                                <img class="input-wrapper__icon" src="{{ asset('build/svg/search.svg') }}" alt="search">
                            </div>
                        </div>
                        <div class="col-lg-4 mt-5">
                            <label for="item">{% trans %}oddeleni{% endtrans %}</label>
                            <div class="input-wrapper input-wrapper--select">
                                <select id="PersonDepartmentSelect" class="input">
                                    <option value="0">{% trans %}vse{% endtrans %}</option>
                                   {% for department in get_category_sub_categories(69) %}
                                        <option value="{{ department.slug }}">{{ department.name }}</option>
                                   {% endfor %}
                                </select>
                            </div>
                        </div>
                    </div>
                </form>
            </div>
    
            <div class="container">
                <div class="mb-10">
                    <div class="table-wrap">
                        <table class="table-empl mt-5" cellspacing="0" cellpadding="0">
                            <thead>
                            <tr>
                                <td><h5>{% trans %}jmeno{% endtrans %}</h5></td>
                                <td><h5>{% trans %}email{% endtrans %}</h5></td>
                                <td><h5> {% trans %}mistnost{% endtrans %}</h5></td>
                                <td><h5>{% trans %}telefon{% endtrans %}</h5></td>
                                <td><h5>{% trans %}oddeleni{% endtrans %}</h5></td>
                            </tr>
                            </thead>
                            <tbody id="employeeList">
                            {% for person in persons %}
                                <tr>
                                    <td>
                                        <a>
                                            <div class="member member--table">
                                                {% if person.personUploadGroups|length > 0 %}
                                                    {% if person.personUploadGroups[0].UploadGroup.upload|length > 0 %}
                                                        <img alt="Member photo" src="{{ asset(person.personUploadGroups[0].UploadGroup.upload[0].path) }}" class="member__photo">
                                                    {% else %}
                                                        <img alt="Member photo" src="{{ asset('build/img/person.png') }}" class="member__photo">
                                                    {% endif %}
                                                {% else %}
                                                    <img alt="Member photo" src="{{ asset('build/img/person.png') }}" class="member__photo">
                                                {% endif %}
                                                <div class="member__info">
                                                    <div class="member__name">
                                                        <a href="{{ path('app_web_person_detail', { 'slug': person.slug }) }}">{{ person.titleBefore }} {{ person.name }} {{ person.surname }}{% if person.titleAfter %}, {% endif %}{{ person.titleAfter }}</a>
                                                    </div>
                                                </div>
                                            </div>
                                        </a>
                                    </td>
                                    <td><a href="">{{person.email}}</a></td>
                                    <td>{{ person.room }}</td>
                                    <td><a href="">{{ person.phone }}</a></td>
                                    <td>
                                        {% for categoryPerson in get_person_departments(person)  %}
                                            {{ categoryPerson.category.name }}<br>
                                        {% endfor %}
                                    </td>
                                </tr>
                            {% endfor %}
                            </tbody>
    
                        </table>
                    </div>
                </div>
            </div>
    {% endblock %}