mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-31 17:38:48 +00:00
fix datatable multi select checkboxes (#1784)
* fix datatable multi select checkboxes * template cleanup * fix unit tests
This commit is contained in:
@@ -9,13 +9,7 @@
|
||||
</th>
|
||||
<!-- Columns -->
|
||||
<th *ngIf="multiselect">
|
||||
<label
|
||||
class="mdl-checkbox mdl-js-checkbox mdl-js-ripple-effect mdl-data-table__select"
|
||||
[class.is-checked]="isSelectAllChecked"
|
||||
for="table-header"
|
||||
(click)="onSelectAllClick($event)">
|
||||
<input type="checkbox" id="table-header" class="mdl-checkbox__input" />
|
||||
</label>
|
||||
<md-checkbox [checked]="isSelectAllChecked" (change)="onSelectAllClick($event)"></md-checkbox>
|
||||
</th>
|
||||
<th class="mdl-data-table__cell--non-numeric non-selectable {{col.cssClass}}"
|
||||
*ngFor="let col of data.getColumns()"
|
||||
@@ -57,12 +51,7 @@
|
||||
</td>
|
||||
|
||||
<td *ngIf="multiselect">
|
||||
<label
|
||||
class="mdl-checkbox mdl-js-checkbox mdl-js-ripple-effect mdl-data-table__select"
|
||||
[attr.for]="'row[' + idx + ']'"
|
||||
[class.is-checked]="row.isSelected">
|
||||
<input type="checkbox" [attr.id]="'row[' + idx + ']'" class="mdl-checkbox__input" [(ngModel)]="row.isSelected" />
|
||||
</label>
|
||||
<md-checkbox [(ngModel)]="row.isSelected"></md-checkbox>
|
||||
</td>
|
||||
<td *ngFor="let col of data.getColumns()" [ngSwitch]="col.type"
|
||||
class="mdl-data-table__cell--non-numeric non-selectable data-cell {{col.cssClass}}"
|
||||
|
Reference in New Issue
Block a user