Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't work with Data Provider with ListView and findAll(). #77

Open
kongoon opened this issue Aug 12, 2018 · 1 comment
Open

Don't work with Data Provider with ListView and findAll(). #77

kongoon opened this issue Aug 12, 2018 · 1 comment

Comments

@kongoon
Copy link

kongoon commented Aug 12, 2018

$news = new ActiveDataProvider([
            'query' => Post::find()->multilingual(),
            'sort' => [
                'defaultOrder' => [
                    'id' => SORT_DESC
                ]
            ]
        ]);

<?= ListView::widget([
            'summary' => false,
            'dataProvider' => $jobs,
            'itemView' => '_list'
        ]) ?>
@kongoon kongoon changed the title Don't work with use with Data Provider and ListView. Don't work with Data Provider and ListView. Aug 18, 2018
@kongoon kongoon changed the title Don't work with Data Provider and ListView. Don't work with Data Provider with ListView and findAll(). Aug 18, 2018
@asv2108
Copy link

asv2108 commented Jan 22, 2019

$query = Bank::find()->multilingual()->joinWith(['translation']);
$dataProvider = new ActiveDataProvider([
'query' => $query,
]);

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants