aboutsummaryrefslogtreecommitdiffstats
path: root/templates/web/base/admin/users.html
blob: 757046bcfa61e5f6c7ac5f87c99a1d60379d3c0b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
[% INCLUDE 'admin/header.html' title=loc('Search Users') %]
[% PROCESS 'admin/report_blocks.html' %]

<div class="fms-admin-info">
    [% loc("User search finds matches in users' names and email addresses.") %]
</div>
<form method="get" action="[% c.uri_for('users') %]" enctype="application/x-www-form-urlencoded" accept-charset="utf-8">
    <p><label for="search">[% loc('Search:') %]</label>
        <input class="form-control" type="text" name="search"  size="30" id="search" value="[% searched | html %]">
</form>

[% IF users.size %]

<table cellspacing="0" cellpadding="2" border="1">
    <tr>
        <th>[% loc('Name') %]</th>
        <th>[% loc('Email') %]</th>
        <th>[% loc('Body') %]</th>
      [% IF c.cobrand.moniker != 'zurich' %]
        <th>[% loc('Flagged') %]</th>
      [% END %]
        <th>*</th>
    </tr>
[%- FOREACH user IN users %]
    <tr>
        <td>[% PROCESS value_or_nbsp value=user.name %]</td> 
        <td><a href="[% c.uri_for( 'reports', search => user.email ) %]">[% PROCESS value_or_nbsp value=user.email %]</a></td> 
        <td>[% PROCESS value_or_nbsp value=user.from_body.name %]
            [% IF user.has_body_permission_to('moderate') %] * [% END %]
        </td>
      [% IF c.cobrand.moniker != 'zurich' %]
        <td>[% user.flagged == 2 ? loc('(Email in abuse table)') : user.flagged ? loc('Yes') : '&nbsp;' %]</td>
      [% END %]
        <td>[% IF user.id %]<a href="[% c.uri_for( 'user_edit', user.id ) %]">[% loc('Edit') %]</a>[% END %]</td>
    </tr>
[%- END -%]
</table>

[% ELSIF searched %]

<div class="fms-admin-warning">
    [% loc("Searching found no users.") %]
</div>

[% END %]

[% IF NOT searched %]
<h2>[% loc('Add user') %]</h2>
[% INCLUDE 'admin/user-form.html', user = '' %]
[% END %]

[% INCLUDE 'admin/footer.html' %]