@@ -11,7 +11,7 @@ discard block |
||
11 | 11 | use Symfony\Component\Form\FormBuilderInterface; |
12 | 12 | use Symfony\Component\OptionsResolver\OptionsResolverInterface; |
13 | 13 | |
14 | -class FormDemoModelType extends AbstractType{ |
|
14 | +class FormDemoModelType extends AbstractType { |
|
15 | 15 | |
16 | 16 | public function buildForm(FormBuilderInterface $builder, array $options) |
17 | 17 | { |
@@ -33,7 +33,7 @@ discard block |
||
33 | 33 | ->add('someChoices', 'choice', array('choices' => $choices, 'expanded' => true, 'multiple' => true)) |
34 | 34 | ->add('username') |
35 | 35 | ->add('email') |
36 | - ->add('termsAccepted','checkbox') |
|
36 | + ->add('termsAccepted', 'checkbox') |
|
37 | 37 | ->add('message', 'textarea') |
38 | 38 | ->add('price') |
39 | 39 | ->add('date', 'date', array('widget' => 'single_text')) |
@@ -30,8 +30,8 @@ |
||
30 | 30 | * |
31 | 31 | * @return $this |
32 | 32 | */ |
33 | - public function addTask(TaskInterface $taskInterface){ |
|
34 | - $this->tasks[] = $taskInterface; |
|
33 | + public function addTask(TaskInterface $taskInterface) { |
|
34 | + $this->tasks[] = $taskInterface; |
|
35 | 35 | return $this; |
36 | 36 | } |
37 | 37 |
@@ -19,40 +19,40 @@ |
||
19 | 19 | /** |
20 | 20 | * Used to receive notification data |
21 | 21 | */ |
22 | - const THEME_NOTIFICATIONS = 'theme.notifications'; |
|
22 | + const THEME_NOTIFICATIONS = 'theme.notifications'; |
|
23 | 23 | /** |
24 | 24 | * Used to receive message data |
25 | 25 | */ |
26 | - const THEME_MESSAGES = 'theme.messages'; |
|
26 | + const THEME_MESSAGES = 'theme.messages'; |
|
27 | 27 | /** |
28 | 28 | * Used to receive task data |
29 | 29 | */ |
30 | - const THEME_TASKS = 'theme.tasks'; |
|
30 | + const THEME_TASKS = 'theme.tasks'; |
|
31 | 31 | /** |
32 | 32 | * |
33 | 33 | */ |
34 | - const THEME_NAVBAR_USER = 'theme.navbar_user'; |
|
34 | + const THEME_NAVBAR_USER = 'theme.navbar_user'; |
|
35 | 35 | /** |
36 | 36 | * used to receive breadcrumb data |
37 | 37 | */ |
38 | - const THEME_BREADCRUMB = 'theme.breadcrumb'; |
|
38 | + const THEME_BREADCRUMB = 'theme.breadcrumb'; |
|
39 | 39 | /** |
40 | 40 | * used to receive the current user for the sidebar |
41 | 41 | */ |
42 | - const THEME_SIDEBAR_USER = 'theme.sidebar_user'; |
|
42 | + const THEME_SIDEBAR_USER = 'theme.sidebar_user'; |
|
43 | 43 | /** |
44 | 44 | * Used for searching |
45 | 45 | * @unused |
46 | 46 | */ |
47 | - const THEME_SIDEBAR_SEARCH = 'theme.sidebar_search'; |
|
47 | + const THEME_SIDEBAR_SEARCH = 'theme.sidebar_search'; |
|
48 | 48 | /** |
49 | 49 | * Used to receive the sidebar menu data |
50 | 50 | */ |
51 | - const THEME_SIDEBAR_SETUP_MENU = 'theme.sidebar_setup_menu'; |
|
51 | + const THEME_SIDEBAR_SETUP_MENU = 'theme.sidebar_setup_menu'; |
|
52 | 52 | /** |
53 | 53 | * Used to receive the sidebar menu data |
54 | 54 | */ |
55 | - const THEME_SIDEBAR_SETUP_MENU_KNP = 'theme.sidebar_setup_menu_knp'; |
|
55 | + const THEME_SIDEBAR_SETUP_MENU_KNP = 'theme.sidebar_setup_menu_knp'; |
|
56 | 56 | /** |
57 | 57 | * |
58 | 58 | */ |
@@ -74,9 +74,9 @@ |
||
74 | 74 | */ |
75 | 75 | public function getActive() { |
76 | 76 | |
77 | - foreach($this->getItems() as $item) { |
|
77 | + foreach ($this->getItems() as $item) { |
|
78 | 78 | /** @var $item MenuItemInterface */ |
79 | - if($item->isActive()) return $item; |
|
79 | + if ($item->isActive()) return $item; |
|
80 | 80 | } |
81 | 81 | return null; |
82 | 82 | } |
@@ -30,11 +30,11 @@ |
||
30 | 30 | */ |
31 | 31 | protected $isOnline = false; |
32 | 32 | |
33 | - function __construct($username='', $avatar = '', $memberSince = null, $isOnline = true) |
|
33 | + function __construct($username = '', $avatar = '', $memberSince = null, $isOnline = true) |
|
34 | 34 | { |
35 | 35 | $this->avatar = $avatar; |
36 | 36 | $this->isOnline = $isOnline; |
37 | - $this->memberSince = $memberSince ?:new \DateTime(); |
|
37 | + $this->memberSince = $memberSince ?: new \DateTime(); |
|
38 | 38 | $this->username = $username; |
39 | 39 | } |
40 | 40 |
@@ -19,15 +19,15 @@ |
||
19 | 19 | /** |
20 | 20 | * |
21 | 21 | */ |
22 | - const COLOR_AQUA = 'aqua'; |
|
22 | + const COLOR_AQUA = 'aqua'; |
|
23 | 23 | /** |
24 | 24 | * |
25 | 25 | */ |
26 | - const COLOR_GREEN = 'green'; |
|
26 | + const COLOR_GREEN = 'green'; |
|
27 | 27 | /** |
28 | 28 | * |
29 | 29 | */ |
30 | - const COLOR_RED = 'red'; |
|
30 | + const COLOR_RED = 'red'; |
|
31 | 31 | /** |
32 | 32 | * |
33 | 33 | */ |
@@ -51,11 +51,11 @@ |
||
51 | 51 | * @param null $sentAt |
52 | 52 | * @param UserInterface $to |
53 | 53 | */ |
54 | - function __construct(UserInterface $from = null, $subject= '', $sentAt = null, UserInterface $to = null) |
|
54 | + function __construct(UserInterface $from = null, $subject = '', $sentAt = null, UserInterface $to = null) |
|
55 | 55 | { |
56 | 56 | $this->to = $to; |
57 | 57 | $this->subject = $subject; |
58 | - $this->sentAt = $sentAt ? : new \DateTime(); |
|
58 | + $this->sentAt = $sentAt ?: new \DateTime(); |
|
59 | 59 | $this->from = $from; |
60 | 60 | } |
61 | 61 |
@@ -25,7 +25,7 @@ |
||
25 | 25 | protected function findTemplate(Request $request, $format, $code, $debug) |
26 | 26 | { |
27 | 27 | |
28 | - if(strpos($request->getPathInfo(), '/admin') !== 0) { |
|
28 | + if (strpos($request->getPathInfo(), '/admin') !== 0) { |
|
29 | 29 | return parent::findTemplate($request, $format, $code, $debug); |
30 | 30 | } |
31 | 31 |
@@ -58,7 +58,7 @@ |
||
58 | 58 | $list = array(); |
59 | 59 | if ($active) { |
60 | 60 | $list[] = $active; |
61 | - while(null !== ($item = $active->getActiveChild())) { |
|
61 | + while (null !== ($item = $active->getActiveChild())) { |
|
62 | 62 | $list[] = $item; |
63 | 63 | $active = $item; |
64 | 64 | } |