mattdanger/phalcon-table-sort
Composer 安装命令:
composer require mattdanger/phalcon-table-sort
包简介
Phalcon HTML table sort component
README 文档
README
Phalcon HTML table sort component
Requirements
- Phalcon v1.4.x
Installing
Install using Composer:
{
"require": {
"mattdanger/phalcon-table-sort": "dev-master"
}
}
You'll also need to add each function to the Volt service:
$di->set('view', function () use ($config) { $view = new View(); // ... $view->registerEngines(array( '.volt' => function ($view, $di) use ($config) { $volt = new VoltEngine($view, $di); $volt->getCompiler()->addFunction('sortLink', function ($resolvedArgs, $expArgs) { return 'TableSort\Sort::sortLink(' . $resolvedArgs . ')'; }); $volt->getCompiler()->addFunction('sortIcon', function ($resolvedArgs, $expArgs) { return 'TableSort\Sort::sortIcon(' . $resolvedArgs . ')'; }); // ... return $volt; }, // ... )); return $view; });
Using Helpers
Here's a list of what's included:
sortLink($key, $default_sort = 'ASC')
Return a formatted URI string with sort order
sortIcon($key, $default = FALSE)
Return a sort icon
统计信息
- 总下载量: 23.46k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 2
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2016-03-02