Column Grouping
simple column grouping,summation of a column value, inline editing
HIDE CODE
<?php $xcrud = Xcrud::get_instance(); $xcrud->table('payments'); $xcrud->unset_remove(); $xcrud->column_hide('customerNumber'); $xcrud->group_by_columns('customerNumber');//Allows only one field $xcrud->group_sum_columns('amount');//Allows only one field $xcrud->columns('customerNumber,checkNumber,amount'); $xcrud->fields_inline('customerNumber,checkNumber,paymentDate,amount'); echo $xcrud->render(); ?>
Payments
# | Checknumber | Amount | ||
---|---|---|---|---|
Customernumber: 10364 (1 items) | ||||
1 | OM31496 | 3 | View Edit | |
total | 3 | |||
Customernumber: 103600 (1 items) | ||||
2 | OM31491 | 3 | View Edit | |
total | 3 | |||
Customernumber: 11310 (1 items) | ||||
3 | HQ5502 | 40000 | View Edit | |
total | 40000 | |||
Customernumber: 112 (1 items) | ||||
4 | HQ55022 | 40000 | View Edit | |
total | 40000 | |||
Customernumber: 113 (1 items) | ||||
5 | GG31455 | 45870 | View Edit | |
total | 45870 | |||
Customernumber: 114 (3 items) | ||||
6 | MA76552 | 82261 | View Edit | |
7 | NP60385 | 7565 | View Edit | |
8 | NR27552 | 44894 | View Edit | |
total | 134720 | |||
Customernumber: 119 (2 items) | ||||
9 | DB933704 | 19501.82 | View Edit | |
10 | LN373447 | 47924.19 | View Edit | |
total | 67426.01 |