Permalink
Browse files

Order clients and projects by name in listings

  • Loading branch information...
lovett committed Feb 5, 2019
1 parent da7be92 commit 968ff601bc1d776e33b482e319c747b16075cf2b
Showing with 4 additions and 2 deletions.
  1. +1 −1 app/Client.php
  2. +3 −1 app/Project.php
@@ -119,7 +119,7 @@ function ($join) {
}
);
$builder = $builder->orderBy('clients.updated_at', 'DESC');
$builder = $builder->orderByRaw('LOWER(clients.name) ASC');
$builder = $builder->groupBy('clients.id');
@@ -246,7 +246,9 @@ function ($join) {
$query->groupBy('projects.id');
return $query->with('client')->orderByRaw('LOWER(projects.name) ASC');
$query = $query->orderByRaw('LOWER(projects.name) ASC');
return $query->with('client');
}
/**

0 comments on commit 968ff60

Please sign in to comment.