CGridView Footer

Olá.Eu tenho esta CGridView:


$this->widget('zii.widgets.grid.CGridView', array(

    'id' => 'encomenda-linha',

    'dataProvider' => $encomendaLinhasProvider,

    'htmlOptions' => array('style' => 'padding:0'),

    'columns' => array('ritmo.artist',

        'ritmo.title',

        array(

            'header' => Yii::t('app', 'Price'),

            'name' => 'ritmo.price',

            'htmlOptions' => array('style' => 'width:10px;'),

            'value' => '$data->ritmo->price." €"'

        ),

        array(

            'header' => Yii::t('app', 'Totals'),

            'name' => 'ritmo.price',

            'htmlOptions' => array('style' => 'width:10px;'),

            'footer' => CHtml::encode('$data->enc->totalValue').' €'

        ),

        array(

            'class' => 'CButtonColumn',

            'template' => '{delete}',

            'buttons' => array(

                'delete' => array(

                    

                    'url' => 'Yii::app()->createUrl("encomenda/deletelinha",array("id"=>$data->idencomenda_linha))',

                    'imageUrl' => Yii::app()->request->baseUrl . '/images/cross.png',

                    

            )),

            'deleteConfirmation'=>Yii::t('app','Are you sure you want to delete the style?'),

        )

    )

));

e contrui este sumário:




<div style="float:right;">

    <table style="background-color: #5E747B">

        <tr>

            <td><?php echo Yii::t('app', 'Amount :') ?></td>

            <td style="text-align: right;"><?php echo $encomendaLinhasProvider->data[0]->enc->totalValue . ' €' ?></td>        

        </tr>

        <tr>

            <td><?php echo Yii::t('app', 'PayPal Fee (if aplicable) :') ?></td>

            <td style="text-align: right;"><?php $valor=$encomendaLinhasProvider->data[0]->enc->totalValue + ($encomendaLinhasProvider->data[0]->enc->totalValue * 3.4 / 100) + 0.35; 

                                                 echo number_format($valor, 2, ',', ' ') . ' €' ?></td>        

        </tr>


    </table>

</div>

Como posso emves do div transforar no footer da CGridView para que quando faça um delete à linha da CGridView actualize tambem os totais?

Obrigado.