Update subtotal after copy row

Question:
I added the copy row. However, the subtotals are not updated. What can I do to force an update of the table?

Solution:
It needs to trigger the JS math function during clone row.

In cl_datagrid.php, in function "display_toolbar", under "if($this->can_copyow){", add the loadcomplete event handler as seen in https://phpgrid.com/example/math-e-g-sum-avg-count-operation/

An easier way would be to simply reload the grid. 

var grid = jQuery("#TABLE_NAME");
grid.trigger("reloadGrid");

Feedback and Knowledge Base