Merge pull request #4434 from MaximilianKrambach/stopProopagation
fix click events in user + mediafile views
This commit is contained in:
commit
8c68e93596
@ -107,6 +107,7 @@
|
||||
<div
|
||||
*ngIf="getFileSettings(file).length > 0"
|
||||
[matMenuTriggerFor]="singleFileMenu"
|
||||
(click)="$event.stopPropagation()"
|
||||
[matMenuTriggerData]="{ file: file }"
|
||||
[matTooltip]="formatIndicatorTooltip(file)"
|
||||
>
|
||||
@ -123,6 +124,7 @@
|
||||
<button
|
||||
mat-icon-button
|
||||
[matMenuTriggerFor]="singleFileMenu"
|
||||
(click)="$event.stopPropagation()"
|
||||
[matMenuTriggerData]="{ file: file }"
|
||||
[disabled]="isMultiSelect"
|
||||
>
|
||||
|
@ -81,7 +81,7 @@
|
||||
<div *ngIf="user.is_active">
|
||||
<mat-checkbox
|
||||
class="checkboxPresent"
|
||||
(click)="setPresent(user)"
|
||||
(click)="setPresent(user, $event)"
|
||||
[checked]="user.is_present"
|
||||
[disabled]="isMultiSelect"
|
||||
>
|
||||
|
@ -394,8 +394,10 @@ export class UserListComponent extends ListViewBaseComponent<ViewUser, User> imp
|
||||
* Sets the user present
|
||||
*
|
||||
* @param viewUser the viewUser Object
|
||||
* @param event the mouse event (to prevent propagaton to row triggers)
|
||||
*/
|
||||
public async setPresent(viewUser: ViewUser): Promise<void> {
|
||||
public async setPresent(viewUser: ViewUser, event: MouseEvent): Promise<void> {
|
||||
event.stopPropagation();
|
||||
viewUser.user.is_present = !viewUser.user.is_present;
|
||||
await this.repo.update(viewUser.user, viewUser);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user