PHPackages                             srun/provider - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. srun/provider

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

srun/provider
=============

The srun4-api's ActiveDataProvider is parsed to use the GridView

1.0.1(2y ago)046proprietaryPHP

Since Feb 14Pushed 2y ago1 watchersCompare

[ Source](https://github.com/srunsoft/srun-provider)[ Packagist](https://packagist.org/packages/srun/provider)[ RSS](/packages/srun-provider/feed)WikiDiscussions master Synced 3w ago

READMEChangelog (1)Dependencies (1)Versions (3)Used By (0)

\##Srun-Provider The srun4-api's ActiveDataProvider is parsed to use the GridView

解析`srun4k-api` 的`ActiveDataProvider` 数据结构以使用 `GirdView`

因为接口返回 `ActiveDataProvider` 数据结构,而页面需要搭配 `GridView` 组件。

所以需要将数据源转换成`DataProvider` ，将 `ArrayDataProvider` 去掉分页逻辑。

### Installation

[](#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 分页大小*/
    ],
]);
```

###  Health Score

23

—

LowBetter than 26% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity9

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity47

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~491 days

Total

2

Last Release

734d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/32881584b4218be963ef7863b7b35de612c2c6e934ef945091fbf18f6c06e51e?d=identicon)[liwenyu](/maintainers/liwenyu)

---

Top Contributors

[![dot-xiaoyuan](https://avatars.githubusercontent.com/u/53287231?v=4)](https://github.com/dot-xiaoyuan "dot-xiaoyuan (5 commits)")

---

Tags

providersrun

### Embed Badge

![Health badge](/badges/srun-provider/health.svg)

```
[![Health](https://phpackages.com/badges/srun-provider/health.svg)](https://phpackages.com/packages/srun-provider)
```

###  Alternatives

[daftspunk/laravel-config-writer

Laravel provider to be able to rewrite configuration

17651.1k1](/packages/daftspunk-laravel-config-writer)[bluemmb/faker-picsum-photos-provider

picsum.photos provider for Faker

29238.7k2](/packages/bluemmb-faker-picsum-photos-provider)[aalaap/faker-youtube

Faker provider for generating fake YouTube video URLs

2291.0k](/packages/aalaap-faker-youtube)[xvladqt/faker-lorem-flickr

loremflickr.com provider for Faker

1583.9k1](/packages/xvladqt-faker-lorem-flickr)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
