Filtering data doesn't change the count of grouping

Hi, I have a treetable as bellow. It shows the count grouped by “cardType” correctly, but the count doesn’t change when I filter by any other columns. Can anybody tell me how to make the count column dynamically change when I filter the data? Thanks.

{
	view:"treetable",
	id:"tableWidget",
	autoheight:true,
	resizeColumn:true,
	resizeRow:true,
	url:dataQueryUrl,
	footer: true,
	columns:[
		{
			id:groupedColumnId,
			header:[groupedColumnTitle, {content:"multiSelectFilter", separator:";"}], 
			adjust:true,  
			fillspace:true,
			template:function(obj, common){
				if (obj.$group) {
					return common.treetable(obj, common) + obj.title;
				} else {
					return '';
				}
			},
			footer: "Total"
		},
		{id:"nodeId", header:["System ID", {content:"textFilter"}], sort:"string", fillspace:true, template:
			function(obj){
				if (obj.nodeId === undefined)
					return '';
				else
					return "<a href='#details' onclick='spNetworkModuleViewRouter(&quot;"+ obj.nodeId + "&quot;); return false;'>" + obj.nodeId + "</span></a>";
		}},
			
		{id:"nodeName", header:["System Name", {content:"textFilter"}], sort:"string", fillspace:true},
		{id:"location", header:["Location", {content:"textFilter"}], sort:"string", fillspace:true},
		{id:"version", header:["Software Version", {content:"textFilter"}], sort:"string", fillspace:true},
		{id:"chassisType", header:["Chassis Type", {content:"multiSelectFilter"}], sort:"string", fillspace:true},
		{id:"serialNumber", header:["Serial Number", {content:"textFilter"}], sort:"string", fillspace:true},
		{id:"partNumber", header:["Part Number", {content:"textFilter"}], sort:"string", fillspace:true},
		{id:"count", header:["Total Number of Cards", {content:"textFilter"}], sort:"int", fillspace:true, footer: {content:"summColumn"}}
	],
	scheme:{
		$group:{
			by:groupedColumnId,
			map:{
				title:[groupedColumnId],
				count:[groupedColumnId, "count"]
			}
		}
	}
}

$group key in scheme affects the data only once. The result is a real data value and can be used for filtering/sorting, but won’t be changed by these means.

Footer is re-rendered on filtering/sorting, so the first goal of such task is to set the proper value to the footer. Here you can create a custom footer and count the data excluding the groups.

https://webix.com/snippet/a5c85319

How this custom footer works:

  • Iterator master.data.each depends on the applied filters.

  • In the tree/treetable dataset, all items have ‘system’ properties, such as $level, $parent and$countthat reflect the actual position of each item in the hierarchical structure. In the above sample,$count is used for counting needed items.

Column values can be covered by column template where you can render anything, including the number of nested items. The template will be refreshed as well as the footer.

The only thing you need to consider is the filtering for this column. By default, Webix filters operate with the real data, while the visual part of the needed behavior is set with the rendering-only methods. Can you please clarify the needed behavior for the filter here?