Skip to content

Commit

Permalink
Avoid FCQN in doc-blocks
Browse files Browse the repository at this point in the history
  • Loading branch information
nowiko committed Feb 1, 2016
1 parent fb48b08 commit 85a197b
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 14 deletions.
26 changes: 13 additions & 13 deletions Controller/DashboardController.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,16 @@
use FOA\CronBundle\Manager\CronManager;
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
use Oro\Bundle\SecurityBundle\Annotation\AclAncestor;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpFoundation\RedirectResponse;

/**
* Display dashboard and manage CRUD operations
*/
class DashboardController extends Controller
{
/**
* Displays the current crons and a form to add a new one.
* Displays the current crontab and a form to add a new one.
*
* @AclAncestor("foa_cron_management_index")
*
Expand All @@ -41,8 +43,8 @@ public function indexAction()
/**
* Add a cron to the cron table
*
* @param \Symfony\Component\HttpFoundation\Request $request
* @return \Symfony\Component\HttpFoundation\RedirectResponse|Response
* @param Request $request
* @return RedirectResponse|Response
*/
public function addAction(Request $request)
{
Expand Down Expand Up @@ -72,7 +74,7 @@ public function addAction(Request $request)
* Edit a cron
*
* @param $id - the line of the cron in the cron table
* @return \Symfony\Component\HttpFoundation\RedirectResponse|\Symfony\Component\HttpFoundation\Response
* @return RedirectResponse|Response
*/
public function editAction($id)
{
Expand Down Expand Up @@ -102,7 +104,7 @@ public function editAction($id)
* Wake up a cron from the cron table
*
* @param $id - the line of the cron in the cron table
* @return \Symfony\Component\HttpFoundation\RedirectResponse
* @return RedirectResponse
*/
public function wakeupAction($id)
{
Expand All @@ -112,7 +114,7 @@ public function wakeupAction($id)
$this->addFlash('error', $cronManager->getError());

/**
* @var \FOA\CronBundle\Manager\Cron $cron
* @var Cron $cron
*/
$cron = $cronList[$id];
$cron->setSuspended(false);
Expand All @@ -128,7 +130,7 @@ public function wakeupAction($id)
* Suspend a cron from the cron table
*
* @param $id - the line of the cron in the cron table
* @return \Symfony\Component\HttpFoundation\RedirectResponse
* @return RedirectResponse
*/
public function suspendAction($id)
{
Expand All @@ -138,7 +140,7 @@ public function suspendAction($id)
$this->addFlash('error', $cronManager->getError());

/**
* @var \FOA\CronBundle\Manager\Cron $cron
* @var Cron $cron
*/
$cron = $cronList[$id];
$cron->setSuspended(true);
Expand All @@ -154,7 +156,7 @@ public function suspendAction($id)
* Remove a cron from the cron table
*
* @param $id - the line of the cron in the cron table
* @return \Symfony\Component\HttpFoundation\RedirectResponse
* @return RedirectResponse
*/
public function removeAction($id)
{
Expand All @@ -173,15 +175,15 @@ public function removeAction($id)
*
* @param $id - the line of the cron in the cron table
* @param $type - the type of file, log or error
* @return \Symfony\Component\HttpFoundation\Response
* @return Response
*/
public function fileAction($id, $type)
{
$cronManager = new CronManager();
$cronList = $cronManager->get();

/**
* @var \FOA\CronBundle\Manager\Cron $cron
* @var Cron $cron
*/
$cron = $cronList[$id];

Expand All @@ -207,9 +209,7 @@ protected function addFlash($type, $message)
return;
}

/* @var \Symfony\Component\HttpFoundation\Session\SessionInterface $session */
$session = $this->get('session');

$session->getFlashBag()->add($type, $message);
}
}
3 changes: 3 additions & 0 deletions FOACronBundle.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@

use Symfony\Component\HttpKernel\Bundle\Bundle;

/**
* Integration of Cron management board and Akeneo
*/
class FOACronBundle extends Bundle
{
}
2 changes: 1 addition & 1 deletion Manager/CronManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ public function add(Cron $cron)
/**
* Remove a cron from the cron table
*
* @param $index The line number
* @param $index - the line number
*/
public function remove($index)
{
Expand Down

0 comments on commit 85a197b

Please sign in to comment.