agik/yii2datatable
最新稳定版本:1.0.6
Composer 安装命令:
composer require agik/yii2datatable
包简介
datatable yii2 models
README 文档
README
#Datatables with ActiveRecord Yii2
##On Controller or Model
use app\models\LevelAccess;
use agik\yii2datatable\Table;
$dt=new Table(LevelAccess::find());
//if using join
$dt->model->joinWith('menu');
//if using join
$dt->model->joinWith('levelUser');
return $dt->getRow();
##On your JS File
var tb=$('#table').dataTable({
"ajax": {
"url": "http://",
'type':'get'
},
"serverSide":true/false,
columns:[
{"data":"table_name.column_name"}
]
});
统计信息
- 总下载量: 150
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 2
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2018-04-23