我安装了Kartik gridview扩展,工作正常.
原文链接:https://www.f2er.com/php/139123.html但是我无法在文档中找到或遗漏它,我如何在页脚中显示列的总和.
<?PHP $gridColumns = [ ['class' => 'yii\grid\SerialColumn'],'id',[ //'attribute'=>'service_name','attribute'=>'service_name','value'=>'serviceName.services',],[ 'attribute'=>'room_category','value'=>'roomCategory.room_category' ],'charges_cash','charges_cashless',['class' => 'yii\grid\ActionColumn'] ]; echo ExportMenu::widget([ 'dataProvider' => $dataProvider,'columns' => $gridColumns,'fontAwesome' => true,'showPageSummary' => true,'dropdownOptions' => [ 'label' => 'Export All','class' => 'btn btn-default' ] ]) ?> </div></div> <?= GridView::widget([ 'dataProvider' => $dataProvider,'filterModel' => $searchModel,'columns' => [ ['class' => 'yii\grid\SerialColumn'],//'service_name',[ //'attribute'=>'service_name',// 'room_category',[ 'attribute'=>'room_category','value'=>'roomCategory.room_category' ],['class' => 'yii\grid\ActionColumn'],'showFooter' => true ]); ?> </div>
寻求这方面的一些帮助.
谢谢.