srun/provider
最新稳定版本:1.0.1
Composer 安装命令:
composer require srun/provider
包简介
The srun4-api's ActiveDataProvider is parsed to use the GridView
关键字:
README 文档
README
##Srun-Provider The srun4-api's ActiveDataProvider is parsed to use the GridView
解析srun4k-api 的ActiveDataProvider 数据结构以使用 GirdView
因为接口返回 ActiveDataProvider 数据结构,而页面需要搭配 GridView 组件。
所以需要将数据源转换成DataProvider ,将 ArrayDataProvider 去掉分页逻辑。
Installation
Either run
composer require srun/provider
or add
"srun/provider":"*"
to the require section of your composer.json file.
Usage
return new \srun\provider\ApiDataProvider([ 'allModels' => $data, /*@var array 数据源*/ 'totalCount' => $totalCount, /*@var int 总数*/ 'pagination' => [ 'pageSize' => 10, /*@var int 分页大小*/ ], ]);
统计信息
- 总下载量: 39
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: proprietary
- 更新时间: 2024-06-20