subtotal method
Insert subtotal rows grouping on groupOnCol and aggregating
aggregateCol with the specified aggregate function.
Implementation
Future<SubtotalResult> subtotal(
AggregateType aggregate, {
required int groupOnCol,
required int aggregateCol,
String caption = '',
int backColor = 0xFFE0E0E0,
int foreColor = 0xFF000000,
bool addOutline = true,
Font? font,
}) async {
final req = SubtotalRequest()
..gridId = _gridId
..aggregate = aggregate
..groupOnCol = groupOnCol
..aggregateCol = aggregateCol
..caption = caption
..background = backColor
..foreground = foreColor
..addOutline = addOutline;
if (font != null) {
req.font = font;
}
final result = await VolvoxGridService.Subtotal(req);
notifyListeners();
return result;
}