我一直在搜索,但找不到像这样显示分页链接的方法:
在网格视图上。
我的网格有这个配置:
<?php
$dataProvider=$model->search();
$dataProvider->pagination = array('pageSize'=>1); // Forced to show 1 item per page to make sure the pagination is triggered.
$widget = $this->widget('bootstrap.widgets.TbExtendedGridView', array(
'id'=>'_grid',
// 'filter'=>new CallReport,
'fixedHeader' => true,
'responsiveTable' => true,
'headerOffset' => 30, // 40px is the height of the main navigation at bootstrap
'selectableRows'=>1,
'selectionChanged'=>'function(id){
if ( $.fn.yiiGridView.getSelection(id).length ) {
$("#selectBtnID").fadeIn("fast");
} else {
$("#selectBtnID").fadeOut("fast");
}
}',
'afterAjaxUpdate'=>'function(id){
if ( $.fn.yiiGridView.getSelection(id).length ) {
$("#selectBtnID").fadeIn("fast");
} else {
$("#selectBtnID").fadeOut("fast");
}
}',
'type'=>'striped bordered',
'enablePagination' => true,
'pager' => array(
'cssFile' => false,
'header' => false,
'firstPageLabel' => 'First',
'prevPageLabel' => 'Previous',
'nextPageLabel' => 'Next',
'lastPageLabel' => 'Last',
),
'summaryText'=>'Displaying {start}-{end} of {count} results.',
'dataProvider' => $dataProvider,
'template' => "{items}",
'columns' => array(
array('name' => 'call_date','header' => 'Call Date'),
array('name'=>'remarks', 'header'=>'Remarks'),
array('name'=>'appointment_date', 'header'=>'Appointment Date'),
array('name'=>'appointment_venue', 'header'=>'Appointment Venue'),
array('name'=>'appointment_remarks', 'header'=>'Appointment Remarks'),
array('name'=>'issues_concern', 'header'=>'Issues/Concern'),
array('name'=>'supervisor_message', 'header'=>'Supervisor Message'),
),
));
?>
谁知道如何实现这一目标?
TIA