Controller/CronsController.php
public function editAction(Request $request, $type, $alias)
    {
        $this->performAccessChecks();

        $value = $request->get('value');

        $response = new Response();

        try {
            $this->cronService->updateCron($alias, $type, $value);
            $response->setStatusCode(
                200,
                $this->translator->trans('cron.edit.done', ['%type%' => $type, '%alias%' => $alias], 'smileezcron')
            );
        } catch (NotFoundException $e) {
            $response->setStatusCode(500, $e->getMessage());
        } catch (InvalidArgumentException $e) {
            $response->setStatusCode(500, $e->getMessage());
        }

        return $response;
    }
public function editAction(Request $request, $type, $alias)
    {
        $this->performAccessChecks();

        $value = $request->get('value');

        $response = new Response();

        try {
            $this->cronService->updateCron($alias, $type, $value);
            $response->setStatusCode(
                200,
                $this->translator->trans('cron.edit.done', ['%type%' => $type, '%alias%' => $alias], 'smileezcron')
            );
        } catch (NotFoundException $e) {
            $response->setStatusCode(500, $e->getMessage());
        } catch (InvalidArgumentException $e) {
            $response->setStatusCode(500, $e->getMessage());
        }

        return $response;
    }
public function editAction ( Request $ request , $ type , $ alias ) { $ this -> performAccessChecks ( ) ; $ value = $ request -> get ( 'value' ) ; $ response = new Response ( ) ; try { $ this -> cronService -> updateCron ( $ alias , $ type , $ value ) ; $ response -> setStatusCode ( 200 , $ this -> translator -> trans ( 'cron.edit.done' , [ '%type%' => $ type , '%alias%' => $ alias ] , 'smileezcron' ) ) ; } catch ( NotFoundException $ e ) { $ response -> setStatusCode ( 500 , $ e -> getMessage ( ) ) ; } catch ( InvalidArgumentException $ e ) { $ response -> setStatusCode ( 500 , $ e -> getMessage ( ) ) ; } return $ response ; }
Edition cron definition

@param Request $request
@param string  $type cron property identifier
@param string  $alias cron alias identifier
@return Response
Edition cron definition