member_webapp/@overflow/notification/component/list/list.component.html

32 lines
1.4 KiB
HTML
Raw Normal View History

2018-04-19 12:24:45 +00:00
<h1>Notifications</h1>
2018-05-25 07:29:06 +00:00
<div *ngIf="!notificationPage; else content">
No data
2018-04-24 05:31:20 +00:00
</div>
2018-05-25 07:29:06 +00:00
<ng-template #content>
<div class="ui-g-12" dir="rtl">
<button type="button" label="Mark all as read" pButton class="ui-button-width-fit" (click)="onMarkAllAsRead()"></button>
</div>
<div>왜 이 div가 없으면 위에 버튼이 안눌릴까요 ㅠㅠ 한참 헤맸자농ㅠㅠ </div>
<p-table [value]="notificationPage.content" selectionMode="single" (onRowSelect)="onRowSelect($event)" >
<ng-template pTemplate="header">
<tr>
<th style="width:9em">Date</th>
<th style="width:12em">Title</th>
<th pResizableColumn>Message</th>
<th style="width:8em">User</th>
</tr>
</ng-template>
<ng-template pTemplate="body" let-notification let-rowIndex="rowIndex" >
<tr [pSelectableRow]="notification" [ngStyle]="notification.confirmDate ? '' : {'background-color': 'lightblue'}">
<td>{{notification.createDate | date: 'dd/MM/yyyy'}}</td>
<td>{{notification.title}}</td>
<td>{{notification.message}}</td>
<td>{{notification.member.name}}</td>
</tr>
</ng-template>
</p-table>
<p-paginator #paginator [rows]="notificationPage.size" [totalRecords]="notificationPage.totalElements"
(onPageChange)="onPaginate($event)" [first]="2"></p-paginator>
</ng-template>