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

How sort on pivot table ? #17

Open
120dev opened this issue Jul 25, 2016 · 0 comments
Open

How sort on pivot table ? #17

120dev opened this issue Jul 25, 2016 · 0 comments

Comments

@120dev
Copy link

120dev commented Jul 25, 2016

Hello, how to sort a table from a pivot table?

$table = Table::create(
            Article::Articles()
                   ->sorted()
                   ->paginate(),
            ['id', 'libelle', 'ref', 'created_at']
        );

        $table->addColumn('famille', 'Famille', function ($model) {
            return $model->famille->libelle;
        });

Adding a table from a pivot posed no problem, though it generated a execption during sorts on this cell because it is not there.

mbp120_ 2016-07-25 a 17 12 50

Thanks

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

1 participant