{% if emp.avatar %}
{% else %}
{% firstof emp.first_name emp.last_name "?" as initial %}
{{ initial|slice:":1"|upper }}
{% endif %}
{{ emp.last_name }} {{ emp.first_name }}{% if emp.patronymic %} {{ emp.patronymic }}{% endif %}
{% if can_edit %}
{% endif %}
Загрузка...
{% if emp.position.name %}
{{ emp.position.name }}
{% elif emp.position_label %}
{{ emp.position_label }}
{% elif emp.position %}
Должность #{{ emp.position }}
{% endif %}
{% if emp.email %}
{% endif %}
{% if emp.phone_number %}
{% endif %}
{% if emp.telegram %}
{{ emp.telegram }}
{% endif %}
{% if emp.whatsapp %}{{ emp.whatsapp }}
{% endif %}
{% if emp.wechat %}{{ emp.wechat }}
{% endif %}
{% if not emp.email and not emp.phone_number and not emp.telegram and not emp.whatsapp and not emp.wechat %}
Контакты не указаны
{% endif %}
{% if emp_depts and emp_depts|length %}
{% for d in emp_depts %}
{% if d.name %}
{% endif %}
{% endif %}
{% endfor %}
{% else %}
{% if d.id %}
{{ d.name }}
{% else %}
{{ d.name }}
{% endif %}
{% if d.role_name %}— {{ d.role_name }}{% endif %}
{% if d.via_assignment %}
внешняя роль
{% endif %}
{% if d.is_head %}
Руководитель
{% endif %}
{% if d.can_edit_role %}
{% endif %}
{% if d.can_edit_role %}
Отделы не указаны
{% endif %}
{% for a in acts %}
{% if a.extra %}
{% endif %}
{% empty %}
{% firstof a.action_display a.action %}
{% if a.comment %}{{ a.comment }}
{% endif %}
{% for k, v in a.extra.items %}
{% endif %}
{% if a.history and a.history|length %}
{{ k }}: {{ v }}
{% endfor %}
Подробнее
{% for h in a.history %}
{% with new_action=h.changes.action.new|default:a.action %}
{% endwith %}
{% endfor %}
{% if new_action == 'hired' %}Принят
{% elif new_action == 'dismissed' %}Уволен
{% elif new_action == 'on_leave' %}В отпуске
{% elif new_action == 'returned_from_leave' %}Вернулся из отпуска
{% elif new_action == 'on_maternity' %}В декрете
{% elif new_action == 'returned_from_maternity' %}Вернулся из декрета
{% elif new_action == 'transferred' %}Переведен
{% elif new_action == 'rehired' %}Восстановлен
{% else %}{% firstof a.action_display a.action %}{% endif %}
{% firstof h.history_date_display h.history_date %}{% if h.history_user %} • {{ h.history_user }}{% endif %}
{% if h.changes %}
{% for field, diff in h.changes.items %}
{% if field != 'action' %}
{% endif %}
{% if field == 'date' %}Дата события
{% elif field == 'comment' %}Комментарий
{% elif field == 'extra' %}Дополнительно
{% elif field == 'employee_id' %}Сотрудник
{% else %}{{ field }}{% endif %}
:
{% if field == 'extra' and diff.new %}
{% if diff.new.items %}
{% for ek, ev in diff.new.items %}
{% if not forloop.first %}, {% endif %}{{ ek }}: {{ ev }}
{% endfor %}
{% else %}
{{ diff.new }}
{% endif %}
{% else %}
{{ diff.new }}
{% endif %}
{% endif %}
{% endfor %}
Событий нет.
{% endfor %}
Навыки
{% with skills=emp.skills %}
{% if skills %}
{% for s in skills %}
{% firstof s.name s as sk_name %}
{% if sk_name %}
{{ sk_name }}
{% if perms.employees.manage_employee_skills or request.user.is_staff or request.user.is_superuser or is_me %}
{% endif %}
{% endif %}
{% endfor %}
{% else %}
{% endif %}
{% endwith %}
{% if perms.employees.manage_employee_skills or request.user.is_staff or request.user.is_superuser or is_me %}
{% endif %}
{% if perms.employees.manage_employee_skills or request.user.is_staff or request.user.is_superuser or is_me %}