2017 © Pedro PelĂĄez
 

yii2-extension yii2-multi-dataprovider

Generates multiple dataprovider result

image

karataserkan/yii2-multi-dataprovider

Generates multiple dataprovider result

  • Thursday, October 6, 2016
  • by karataserkan
  • Repository
  • 1 Watchers
  • 4 Stars
  • 75 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 6 Forks
  • 0 Open issues
  • 3 Versions
  • 15 % Grown

The README.md

yii2 Multi DataProvider

gets data from multiple dataproviders, (*1)

Latest Stable Version Total Downloads Monthly Downloads License, (*2)

Installation

The preferred way to install this extension is through composer., (*3)

Either run, (*4)

$ composer require karataserkan/yii2-multi-dataprovider

or add, (*5)

"karataserkan/yii2-multi-dataprovider": "*"

to the require section of your composer.json file., (*6)

Usage

use karataserkan\yii2MultiDataProvider\MultiDataProvider;

$data1 = new ActiveDataProvider([
    'query' => $query,
]);

$data2 = new ArrayDataProvider([
    'allModels' => [...],
]);

$dataProvider = new MultiDataProvider([
    'dataProviders' => [$data1,$data2],
]);
$dataProvider = new MultiDataProvider([
    'dataProviders' => [$data1,$data2],
    'modelCallback' => function ($model) {
        return new YourModel(['data' => $model]);
    },
]);

Contributing

  1. Fork it ( https://github.com/karataserkan/yii2-multi-dataprovider/fork )
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create a new Pull Request

Credits

The Versions

06/10 2016

dev-master

9999999-dev https://github.com/karataserkan/yii2-multi-dataprovider

Generates multiple dataprovider result

  Sources   Download

GNU

The Requires

 

yii2 dataprovider

06/10 2016

1.0.0

1.0.0.0 https://github.com/karataserkan/yii2-multi-dataprovider

Generates multiple dataprovider result

  Sources   Download

GNU

The Requires

 

yii2 dataprovider

04/10 2016

0.0.1

0.0.1.0 https://github.com/karataserkan/yii2-multi-dataprovider

Generates multiple dataprovider result

  Sources   Download

GNU

The Requires

 

yii2 dataprovider