opt-cc/static/src/app/request/confirm-promotion/confirm-promotion.component...

65 lines
2.7 KiB
HTML

<div class="confirm-promotion-container">
<h3>{{'request.confirm.promotion.headline' | translate}}</h3>
<div class="table-container">
<table class="table table-hover">
<thead>
<tr>
<th class="col-sm-1">{{'request.confirm.promotion.table.head.participant' | translate}}</th>
<th class="col-sm-1">{{'request.confirm.promotion.table.head.rank.before' | translate}}</th>
<th class="col-sm-1">{{'request.confirm.promotion.table.head.rank.after' | translate}}</th>
<th class="col-sm-1 ">{{'request.confirm.promotion.table.head.requester' | translate}}</th>
<th class="col-sm-1 text-center">{{'request.confirm.promotion.table.head.date' | translate}}</th>
<th class="col-sm-1 text-center">{{'request.confirm.promotion.table.head.status' | translate}}</th>
<th class="col-sm-2 text-right"></th>
<th class="col-sm-1 text-right">{{'request.confirm.promotion.table.head.action' | translate}}</th>
</tr>
</thead>
<tbody *ngFor="let promotion of promotions">
<tr>
<td>
{{promotion.userId.username}}
</td>
<td *ngFor="let rank of (ranks | rankfilter: promotion.oldRankLvl)">
{{rank.name}}
</td>
<td *ngFor="let rank of (ranks | rankfilter: promotion.newRankLvl)">
{{rank.name}}
</td>
<td>
{{promotion.proposer.username}}
</td>
<td class="text-center">
{{promotion.timestamp | date: 'dd.MM.yyyy'}}
</td>
<td class="text-center">
<span *ngIf="promotion.confirmed === 0">
{{'request.confirm.promotion.table.status.progressing' | translate}}
</span>
<span *ngIf="promotion.confirmed === 1">
{{'request.confirm.promotion.table.status.accepted' | translate}}
</span>
<span *ngIf="promotion.confirmed !== 0 && promotion.confirmed !== 1">
{{'request.confirm.promotion.table.status.rejected' | translate}}
</span>
</td>
<td>
<textarea style="width: 100%;"
rows="3"
placeholder="{{'request.confirm.promotion.table.reject.reason.placeholder' | translate}}"
#rejectReason></textarea>
</td>
<td class="text-right">
<a class="action" (click)="confirm(promotion, true)">
{{'request.confirm.promotion.table.button.action.accept' | translate}}
</a>
<a class="action" (click)="confirm(promotion, false, rejectReason.value)">
{{'request.confirm.promotion.table.button.action.reject' | translate}}
</a>
</td>
</tr>
</tbody>
</table>
</div>
</div>