2018-10-05 16:34:08 +02:00
|
|
|
<os-head-bar plusButton=true (plusButtonClicked)=onPlusButton()>
|
|
|
|
<!-- Title -->
|
|
|
|
<div class="title-slot">
|
2018-11-06 16:57:36 +01:00
|
|
|
<h2 translate>Elections</h2>
|
2018-10-05 16:34:08 +02:00
|
|
|
</div>
|
|
|
|
|
|
|
|
<!-- Menu -->
|
|
|
|
<div class="menu-slot">
|
|
|
|
<button type="button" mat-icon-button [matMenuTriggerFor]="assignmentMenu">
|
|
|
|
<mat-icon>more_vert</mat-icon>
|
|
|
|
</button>
|
|
|
|
</div>
|
2018-09-11 16:38:23 +02:00
|
|
|
</os-head-bar>
|
2018-07-31 15:46:55 +02:00
|
|
|
|
2018-11-08 17:38:44 +01:00
|
|
|
<mat-table class="os-listview-table on-transition-fade" [dataSource]="dataSource" matSort>
|
2018-09-11 16:38:23 +02:00
|
|
|
<!-- name column -->
|
|
|
|
<ng-container matColumnDef="title">
|
2018-11-08 17:38:44 +01:00
|
|
|
<mat-header-cell *matHeaderCellDef mat-sort-header>Title</mat-header-cell>
|
|
|
|
<mat-cell *matCellDef="let assignment">{{ assignment.getTitle() }}</mat-cell>
|
2018-09-11 16:38:23 +02:00
|
|
|
</ng-container>
|
|
|
|
<ng-container matColumnDef="phase">
|
2018-11-08 17:38:44 +01:00
|
|
|
<mat-header-cell *matHeaderCellDef mat-sort-header>Phase</mat-header-cell>
|
2018-09-11 16:38:23 +02:00
|
|
|
<mat-cell *matCellDef="let assignment">
|
|
|
|
<mat-chip-list>
|
2018-11-08 17:38:44 +01:00
|
|
|
<mat-chip color="primary" selected>{{ assignment.phase }}</mat-chip>
|
2018-09-11 16:38:23 +02:00
|
|
|
</mat-chip-list>
|
|
|
|
</mat-cell>
|
|
|
|
</ng-container>
|
|
|
|
<ng-container matColumnDef="candidates">
|
2018-11-08 17:38:44 +01:00
|
|
|
<mat-header-cell *matHeaderCellDef mat-sort-header>Candidates</mat-header-cell>
|
2018-09-11 16:38:23 +02:00
|
|
|
<mat-cell *matCellDef="let assignment">
|
|
|
|
<mat-chip-list>
|
2018-11-08 17:38:44 +01:00
|
|
|
<mat-chip color="accent" selected>{{ assignment.candidateAmount }}</mat-chip>
|
2018-09-11 16:38:23 +02:00
|
|
|
</mat-chip-list>
|
|
|
|
</mat-cell>
|
|
|
|
</ng-container>
|
2018-08-28 13:54:25 +02:00
|
|
|
|
2018-09-11 16:38:23 +02:00
|
|
|
<mat-header-row *matHeaderRowDef="['title', 'phase', 'candidates']"></mat-header-row>
|
2018-11-08 17:38:44 +01:00
|
|
|
<mat-row (click)="selectAssignment(row)" *matRowDef="let row; columns: ['title', 'phase', 'candidates']"></mat-row>
|
2018-09-11 16:38:23 +02:00
|
|
|
</mat-table>
|
2018-07-31 15:46:55 +02:00
|
|
|
|
2018-09-11 16:38:23 +02:00
|
|
|
<mat-paginator class="on-transition-fade" [pageSizeOptions]="[25, 50, 75, 100, 125]"></mat-paginator>
|
2018-10-05 16:34:08 +02:00
|
|
|
|
|
|
|
<mat-menu #assignmentMenu="matMenu">
|
|
|
|
<button mat-menu-item (click)="downloadAssignmentButton()">
|
|
|
|
<mat-icon>archive</mat-icon>
|
|
|
|
<span translate>Export ...</span>
|
|
|
|
</button>
|
|
|
|
</mat-menu>
|