PHP code example of marshmallow / nova-totals-footer

1. Go to this page and download the library: Download marshmallow/nova-totals-footer library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

marshmallow / nova-totals-footer example snippets


use Laravel\Nova\Fields\Currency;

Currency::make('Revenue', 'revenue')
    ->hod: 'sum',     // sum, count, avg, min, max
        title: 'Total',
        prefix: '$',
        postfix: '.00',
        hideTitle: true,   // true, false (default)
        align: 'right',    // left, right (default), center
        titleAlign: 'right', // left, right (default), center
        decimals: 2,       // number of decimals to format the total with (default: 0)
    ),

use Marshmallow\NovaTotalsFooter\NovaTotalsFooter;

NovaTotalsFooter::hideHeader();