Hi, I have a grid that shows data for some items during the a year and a text field and 2 buttons to change the years like the attachment.
When i either click one of the buttons or type the year it will refresh the table data and columns to reflect the chosen year.
But the way i'm doing it it is updating the colModel, but the columns are not being updated and so the groupheader of the grid still showing the year that is loaded, am i missing something?
Here is the code for the table update of the colModel, the buildColumnModel method only creates a new array setting a new parent named after the new year and the 12 columns for each month.
var $filterText = this.toolbar().find(".filterValue"),
oldVal = Number($filterText.val());
$filterText.val(--oldVal);
let date = new moment().year(oldVal);
date = date.startOf('year');
this.colModel = buildColumnModel(date, true);
this.option( 'colModel', grid.option( 'colModel') );
this.refresh();
Thanks,