Skip to content

Commit

Permalink
fix #851 SummeryPlugin SummaryRow is not being cleared and is duplica…
Browse files Browse the repository at this point in the history
…ted instead
  • Loading branch information
vegegoku committed Oct 29, 2023
1 parent db0f8a1 commit 7680e32
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
import java.util.Collection;
import java.util.List;
import org.dominokit.domino.ui.datatable.DataTable;
import org.dominokit.domino.ui.datatable.TableRow;
import org.dominokit.domino.ui.datatable.plugins.DataTablePlugin;
import org.dominokit.domino.ui.elements.TFootElement;
import org.dominokit.domino.ui.utils.BaseDominoElement;
Expand All @@ -43,7 +42,7 @@
*/
public class SummaryPlugin<T, S> implements DataTablePlugin<T> {

private List<TableRow<S>> summaryRows = new ArrayList<>();
private List<SummaryRow<T, S>> summaryRows = new ArrayList<>();
private DataTable<T> dataTable;
private TFootElement footer;

Expand Down Expand Up @@ -82,6 +81,7 @@ public SummaryPlugin<T, S> setSummaryRecords(Collection<S> records) {
SummaryRow<T, S> summaryRow = new SummaryRow<>(recordsList.get(i), i, this.dataTable);
summaryRow.render();
footer.appendChild(summaryRow);
summaryRows.add(summaryRow);
}
return this;
}
Expand Down

0 comments on commit 7680e32

Please sign in to comment.