I have Laravel 5.2 Backpacker admin for my new project and I need to make minor adjustments to the generated list view. Ie:
I have amount stored as cents in database, but would need to show as regular amount, so this would basically require to divide all values from
amount
column by 100;I have certain rows, that have the
cancelled
date in them. I would like to set the row class to 'warning' for these.
So far I found only this complete override solution, but was wondering, if it could be done simpler in the crud controller.
I already can modify the header with this:
$this->crud->setColumnDetails('amount', ['label' => 'Total Amount']);
Is there such a simple option for data rows? Like:
$this->crud->setColumnData('amount', $this->crud->amount/100);