simplify timesheet edit form if only one customer is existing (#443)

This commit is contained in:
Kevin Papst
2018-11-28 15:05:12 +01:00
committed by GitHub
parent 8fddf627bf
commit 2d6109d587
4 changed files with 69 additions and 25 deletions

View File

@@ -35,10 +35,15 @@ class CustomerRepository extends AbstractRepository
}
/**
* @param null|bool $visible
* @return int
*/
public function countCustomer()
public function countCustomer($visible = null)
{
if (null !== $visible) {
return $this->count(['visible' => (int) $visible]);
}
return $this->count([]);
}