-
Notifications
You must be signed in to change notification settings - Fork 36
/
Copy pathpost.html
28 lines (28 loc) · 1002 Bytes
/
post.html
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
<div>
<p class="lead">
<b>{{ post.user.name }}</b>
wrote on <em>{{ post.created | date:'MMM d, y h:mm a' }}</em>
</p>
<p ng-if="post.image_ref">
<img ng-src="{{ apiHost }}/image/{{ post.image_ref }}" />
</p>
<p class="lead">{{ post.text }}</p>
<p>Location: <span class="label label-info">{{ post.country }}</span></p>
<p class="pull-right">
<button type="button"
class="btn btn-sm btn-primary"
ng-click="guestbookCtlr.editPost(post)" disabled>Edit</button>
<button type="button"
class="btn btn-sm btn-danger"
ng-click="guestbookCtlr.deletePost(post)">Delete</button>
</p>
<p>
<button type="button"
class="btn btn-sm btn-default"
ng-click="guestbookCtlr.likePost(post)">
<span class="badge">{{ post.like_count }}</span>
<ng-pluralize count="post.like_count"
when="{'0': 'Likes', 'one': 'Like', 'other': 'Likes'}"></ng-pluralize>
</button>
</p>
</div>