-
Notifications
You must be signed in to change notification settings - Fork 92
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added Sort Icon in paginator helper #39
Comments
Writing this way if I echo $this->Paginator->sort(
'name',
array(
'asc' => __('Name') . ' <i class="icon-chevron-up text-info pull-right"></i>',
'desc' => __('Name') . ' <i class="icon-chevron-down text-info pull-right"></i>'
),
array(
'escape' => false
)
); |
Wow!! great, I wasn't aware its can be done in params. On Thu, Nov 14, 2013 at 3:13 PM, Yasuo Harada [email protected]:
|
Is there a way to do this with multiple pagination headings (such as in a table, using column headings), whereby only the Paginator->sort that is active has an icon? Also, for anyone using standard bootstrap 3 glyphicons:
|
Maybe like this: $sKey = 'vsnr'; $sName = 'Vers. Nr.';
if(isset($this->request->params['paging']['Order']['options']['sort']) && $this->request->params['paging']['Order']['options']['sort'] == $sKey){
echo $this->Paginator->sort(
$sKey,
array(
'asc' => $sName . ' <i class="fa fa-chevron-up text-info"></i>',
'desc' => $sName . ' <i class="fa fa-chevron-down text-info"></i>'
),
array(
'escape' => false,
)
);
}else{
echo $this->Paginator->sort('vsnr', 'Vers. Nr.');
}
unset($sKey); unset($sName); Order = Modelname Sorry for the bad format and english... Greetz |
Added sort function to show sort icons in pagination header links
Please review my code, if use full and according to standards please add this to BoostCake :)
The text was updated successfully, but these errors were encountered: