Fixes on reordering categories
This commit is contained in:
@@ -12,6 +12,7 @@ class CategoriesDataTable extends DataTable
|
||||
|
||||
public function query(Category $model)
|
||||
{
|
||||
$model = $model::withCount('articles');
|
||||
return self::buildQuery($model);
|
||||
}
|
||||
|
||||
@@ -19,6 +20,7 @@ class CategoriesDataTable extends DataTable
|
||||
{
|
||||
return [
|
||||
Column::make('name')->title('Nom'),
|
||||
Column::make('articles_count')->title('Nb Articles')->class('text-right')->searchable(false),
|
||||
self::makeColumnButtons(),
|
||||
];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user