feat(base-table.component): Attribute rowStyle und rowClass hinzugefügt

This commit is contained in:
Developer 02 2024-11-11 16:42:22 +01:00
parent 0f9ac0e637
commit acfd9b4fb8
2 changed files with 8 additions and 2 deletions

View File

@ -13,5 +13,7 @@
[infoPanel]="infoPanel" [infoPanel]="infoPanel"
[titlePanel]="titlePanel" [titlePanel]="titlePanel"
[theme]="theme" [theme]="theme"
[rowStyle] = "rowStyle"
[rowClass] = "rowClass"
(selectedRows)="onSelectedRows($event)"> (selectedRows)="onSelectedRows($event)">
</gui-grid> </gui-grid>

View File

@ -1,6 +1,6 @@
import { Component, Inject, Input, OnDestroy, OnInit, ViewChild, input } from '@angular/core'; import { Component, Inject, Input, OnDestroy, OnInit, ViewChild, input } from '@angular/core';
import { ApiService } from '../../../services/api/user-management.api.service'; import { ApiService } from '../../../services/api/user-management.api.service';
import { GuiGridModule, GuiColumn, GuiColumnMenu, GuiSorting, GuiRowDetail, GuiPaging, GuiPagingDisplay, GuiSearching, GuiCellEdit, GuiInfoPanel, GuiTitlePanel, GuiRowSelection, GuiSelectedRow, GuiGridComponent, GuiGridApi, GuiTheme } from '@generic-ui/ngx-grid'; import { GuiGridModule, GuiColumn, GuiColumnMenu, GuiSorting, GuiRowDetail, GuiPaging, GuiPagingDisplay, GuiSearching, GuiCellEdit, GuiInfoPanel, GuiTitlePanel, GuiRowSelection, GuiSelectedRow, GuiGridComponent, GuiGridApi, GuiTheme, GuiRowStyle, GuiRowClass } from '@generic-ui/ngx-grid';
import { Subscription } from 'rxjs/internal/Subscription'; import { Subscription } from 'rxjs/internal/Subscription';
import { ColorModeService, Theme } from '../../../services/button/color-mode.service'; import { ColorModeService, Theme } from '../../../services/button/color-mode.service';
import { CommonModule } from '@angular/common'; import { CommonModule } from '@angular/common';
@ -111,6 +111,10 @@ export class BaseTableComponent<TModel, TApiService extends ApiService<TModel>>
@Input() columns: Array<GuiColumn> = []; @Input() columns: Array<GuiColumn> = [];
@Input() rowStyle: GuiRowStyle = {}
@Input() rowClass: GuiRowClass = {}
selected: boolean = false; selected: boolean = false;
safelyUnselectAll() { safelyUnselectAll() {
this.selected = true this.selected = true