次のことを試してみてください。GridView
で
はfalse
としてshowFooter
を設定します。
'panel' => [
'showFooter' => false,
//Other settings you may wan
'heading' => '<h3 class="panel-title"><i class="iconLeft fa fa-th-list"></i> '.Yii::t('app/buttons', 'list').' '.$title.'</h3>',
'type' => 'success',
//'before' => Html::a('<i class="iconLeft fa fa-plus"></i> '.Yii::t('app/buttons', 'create'), ['create'], ['class' => 'btn btn-success']),
//'after' => Html::a('<i class="iconLeft fa fa-repeat"></i> '.Yii::t('app/buttons', 'reset_grid'), ['index'], ['class' => 'btn btn-info']),
],
そして、明示的にページャのオプションを追加します。
'pager' => [
'options' => ['class' => 'pagination'], // set class name used in ui list of pagination
'prevPageLabel' => '<i class="fa fa-angle-left"></i>', // Set the label for the "previous" page button
'nextPageLabel' => '<i class="fa fa-angle-right"></i>', // Set the label for the "next" page button
'firstPageLabel' => '<i class="fa fa-angle-double-left"></i>', // Set the label for the "first" page button
'lastPageLabel' => '<i class="fa fa-angle-double-right"></i>', // Set the label for the "last" page button
'nextPageCssClass' => 'next', // Set CSS class for the "next" page button
'prevPageCssClass' => 'prev', // Set CSS class for the "previous" page button
'firstPageCssClass' => 'first', // Set CSS class for the "first" page button
'lastPageCssClass' => 'last', // Set CSS class for the "last" page button
'maxButtonCount' => 10, // Set maximum number of page buttons that can be displayed
],
また、あなたが\yii\widgets\Pjax::begin();
を設定する必要はありませんし、 \yii\widgets\Pjax::end();
kartik\grid\GridView
はデフォルトでPjax
を使用しているためです。
明らかに、 'GridView'のために' $ gridDataProvider'も使う必要がありました。 –