update to Symfony 4.4 (#1275)
This commit is contained in:
@@ -302,7 +302,10 @@ class TimesheetController extends BaseApiController
|
||||
*/
|
||||
public function postAction(Request $request): Response
|
||||
{
|
||||
$timesheet = $this->service->createNewTimesheet($this->getUser(), $request);
|
||||
/** @var User $user */
|
||||
$user = $this->getUser();
|
||||
|
||||
$timesheet = $this->service->createNewTimesheet($user, $request);
|
||||
|
||||
$mode = $this->getTrackingMode();
|
||||
|
||||
@@ -520,7 +523,10 @@ class TimesheetController extends BaseApiController
|
||||
*/
|
||||
public function activeAction(): Response
|
||||
{
|
||||
$data = $this->repository->getActiveEntries($this->getUser());
|
||||
/** @var User $user */
|
||||
$user = $this->getUser();
|
||||
|
||||
$data = $this->repository->getActiveEntries($user);
|
||||
|
||||
$view = new View($data, 200);
|
||||
$view->getContext()->setGroups(['Default', 'Subresource', 'Timesheet']);
|
||||
@@ -600,7 +606,10 @@ class TimesheetController extends BaseApiController
|
||||
throw new AccessDeniedHttpException('You are not allowed to re-start this timesheet');
|
||||
}
|
||||
|
||||
$copyTimesheet = $this->service->createNewTimesheet($this->getUser());
|
||||
/** @var User $user */
|
||||
$user = $this->getUser();
|
||||
|
||||
$copyTimesheet = $this->service->createNewTimesheet($user);
|
||||
|
||||
$copyTimesheet
|
||||
->setBegin($this->dateTime->createDateTime())
|
||||
|
||||
Reference in New Issue
Block a user