[% INCLUDE 'admin/header.html' title=loc('Search Users') %] [% PROCESS 'admin/report_blocks.html' %] [% BLOCK role_select %] [% END %] [% INCLUDE status_message %]
[% loc("User search finds matches in users' names and email addresses.") %]

[% IF roles %]

[% INCLUDE role_select label='role' %] [% END %]

[% IF users.size %]
[% IF c.cobrand.moniker != 'zurich' %] [% END %] [%- FOREACH user IN users %] [% IF c.cobrand.moniker != 'zurich' %] [% END %] [%- END -%]
* [% loc('Name') %] [% loc('Email') %] [% loc('Body') %][% loc('Flagged') %]*
[% IF user.from_body %] [% END %] [% IF user.from_body %][% END %] [% PROCESS value_or_nbsp value=user.email %] [% PROCESS value_or_nbsp value=user.from_body.name %] [% IF user.is_superuser %] * [% END %] [% user.flagged == 2 ? loc('User in abuse table') : user.flagged ? loc('Yes') : ' ' %][% IF user.id %][% loc('Edit') %][% END %] [% IF user.id %][% loc('Timeline') %][% END %]

[% IF c.user.is_superuser %] [% INCLUDE role_select label='roles' %] [% ELSE %] [% END %]

[% ELSIF searched || role_selected %]
[% loc("Searching found no users.") %]
[% END %] [% IF NOT ( searched || role_selected )%]

[% loc('Add user') %]

[% INCLUDE 'admin/users/form.html', user = '' %] [% ELSE %] [% loc('Add user') %] [% END %] [% INCLUDE 'admin/footer.html' %]