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: 14133454 (1 items) | ||||
1 | HJ32686 | 100 | View Edit | |
total | 100 | |||
Customernumber: 141 (9 items) | ||||
2 | ID10962 | 20 | View Edit | |
3 | IN446258 | 20 | View Edit | |
4 | JE105477 | 1200 | View Edit | |
5 | JN355280 | 1200 | View Edit | |
6 | JN722010 | 100.11 | View Edit | |
7 | KT52578 | 63843.55 | View Edit | |
8 | MC46946 | 35420.74 | View Edit | |
9 | MF629602 | 20009.53 | View Edit | |
10 | NU627706 | 26155 | View Edit | |
total | 147968.93 |