Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Grouping some rows and reusing the templates #2159

Open
bureaug opened this issue Aug 16, 2023 · 0 comments
Open

Grouping some rows and reusing the templates #2159

bureaug opened this issue Aug 16, 2023 · 0 comments

Comments

@bureaug
Copy link

bureaug commented Aug 16, 2023

I am looking for ways to group only specific rows, while leaving others ungrouped and displayed as "regular" rows. As the grouped row will have the same structure as the rows being grouped, I am also looking for DRY solution when it comes to the column templates.

<ngx-datatable [rows]="rawData">
  <ngx-datatable-column>...</ngx-datatable-column>
  <ngx-datatable-column>...</ngx-datatable-column>
  <ngx-datatable-column>...</ngx-datatable-column>
  <ngx-datatable-row-detail 
     (toggle)="onDetailToggle($event)">[...here go the same columns as above...]</ngx-datatable-row-detail>
</ngx-datatable>

I need to show grouped results for some of the table rows while making it possible to expand the grouped row and display the ungrouped values.
The original question: https://stackoverflow.com/questions/76907830/angular-self-referencing-template-ngx-datatable

Please tell us about your environment:

MacOS 12.6.7

  • Table version:
    Swimlane Datatable 18.0.0

  • Angular version:
    Angular 11.2.4

  • Browser: [all | Chrome XX | Firefox XX | IE XX | Safari XX | Mobile Chrome XX | Android X.X Web Browser | iOS XX Safari | iOS XX UIWebView | iOS XX WKWebView ]
    Any browser

  • Language: [all | TypeScript X.X | ES6/7 | ES5]
    Typescript 3.5.2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant