forked from mrvautin/expressCart
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathusers.hbs
30 lines (30 loc) · 1.03 KB
/
users.hbs
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
{{> partials/menu}}
<main role="main" class="col-md-9 ml-sm-auto col-lg-10 px-4">
<div class="col-sm-12">
<h2>{{ @root.__ "Users" }} <span class="float-right"><a href="/admin/user/new" class="btn btn-outline-success">{{ @root.__ "New user" }}</a></span></h2>
</div>
<div class="col-md-12">
<ul class="list-group">
{{#each users}}
<li class="list-group-item">
<strong>{{ @root.__ "User" }}:</strong> {{this.usersName}} - ({{this.userEmail}})
<span class="float-right">
<strong>{{ @root.__ "Role" }}: </strong>
{{#isAnAdmin this.isAdmin}}
<span>Admin</span>
{{#if ../this.isOwner}}
(Owner)
{{/if}}
{{else}}
<span>{{ @root.__ "User" }}</span>
{{/isAnAdmin}}
{{#isAnAdmin @root.session.isAdmin}}
<a href="/admin/user/edit/{{../this._id}}">{{{feather 'edit'}}}</a>
<a href="#" class="userDelete text-danger" data-id="{{../this._id}}">{{{feather 'trash-2'}}}</a>
{{/isAnAdmin}}
</span>
</li>
{{/each}}
</ul>
</div>
</main>