@@ -102,7 +102,7 @@ discard block |
||
102 | 102 | EntityType::class, |
103 | 103 | array( |
104 | 104 | 'class' => 'AppBundle:Supplier', |
105 | - 'query_builder' => function (EntityRepository $er) { |
|
105 | + 'query_builder' => function(EntityRepository $er) { |
|
106 | 106 | return $er->createQueryBuilder('s') |
107 | 107 | ->where('s.active = 1'); |
108 | 108 | }, |
@@ -143,7 +143,7 @@ discard block |
||
143 | 143 | EntityType::class, |
144 | 144 | array( |
145 | 145 | 'class' => 'AppBundle:FamilyLog', |
146 | - 'query_builder' => function (EntityRepository $er) { |
|
146 | + 'query_builder' => function(EntityRepository $er) { |
|
147 | 147 | return $er->createQueryBuilder('f') |
148 | 148 | ->orderBy('f.path', 'ASC'); |
149 | 149 | }, |
@@ -39,7 +39,7 @@ |
||
39 | 39 | EntityType::class, |
40 | 40 | array( |
41 | 41 | 'class' => 'AppBundle:Supplier', |
42 | - 'query_builder' => function (EntityRepository $er) { |
|
42 | + 'query_builder' => function(EntityRepository $er) { |
|
43 | 43 | return $er->createQueryBuilder('s') |
44 | 44 | ->where('s.active = 1'); |
45 | 45 | }, |
@@ -37,14 +37,14 @@ |
||
37 | 37 | { |
38 | 38 | $builder->addEventListener( |
39 | 39 | FormEvents::PRE_SET_DATA, |
40 | - function (FormEvent $event) { |
|
40 | + function(FormEvent $event) { |
|
41 | 41 | $form = $event->getForm(); |
42 | 42 | $articles = $event->getData(); |
43 | 43 | |
44 | 44 | $formOptions = array( |
45 | 45 | 'class' => 'AppBundle:Supplier', |
46 | 46 | 'query_builder' => |
47 | - function (EntityRepository $er) use ($articles) { |
|
47 | + function(EntityRepository $er) use ($articles) { |
|
48 | 48 | return $er->getSupplierForReassign($articles[0]->getSupplier()); |
49 | 49 | }, |
50 | 50 | 'multiple' => false, |
@@ -35,7 +35,7 @@ |
||
35 | 35 | */ |
36 | 36 | public function buildForm(FormBuilderInterface $builder, array $options) |
37 | 37 | { |
38 | - $builder ->add('username', null, ['label' => "Nom d'utilisateur", 'attr' => ['class' => 'form-control'],]) |
|
38 | + $builder ->add('username', null, ['label' => "Nom d'utilisateur", 'attr' => ['class' => 'form-control'], ]) |
|
39 | 39 | ->add('email', EmailType::class, array( |
40 | 40 | 'required' => false, |
41 | 41 | 'label' => 'E-mail', |
@@ -43,7 +43,7 @@ |
||
43 | 43 | 'format' => 'dd MMM yyyy', |
44 | 44 | 'html5' => false, |
45 | 45 | 'input' => 'datetime', |
46 | - 'attr' => ['class' => 'form-control',], |
|
46 | + 'attr' => ['class' => 'form-control', ], |
|
47 | 47 | ) |
48 | 48 | ) |
49 | 49 | ->add('status', HiddenType::class) |
@@ -68,7 +68,7 @@ |
||
68 | 68 | 'empty_data' => '0,000', |
69 | 69 | 'label' => 'settings.quantity', |
70 | 70 | 'translation_domain' => 'gs_articles', |
71 | - 'attr'=> ['class' => 'form-control text-right',], |
|
71 | + 'attr'=> ['class' => 'form-control text-right', ], |
|
72 | 72 | ) |
73 | 73 | ) |
74 | 74 | ->add( |
@@ -299,7 +299,7 @@ discard block |
||
299 | 299 | */ |
300 | 300 | public function printAction(Inventory $inventory) |
301 | 301 | { |
302 | - $file = $inventory->getDate()->format('Ymd') . '-inventory.pdf'; |
|
302 | + $file = $inventory->getDate()->format('Ymd').'-inventory.pdf'; |
|
303 | 303 | // Create and save the PDF file to print |
304 | 304 | $html = $this->renderView( |
305 | 305 | 'AppBundle:Inventory:print.pdf.twig', |
@@ -313,7 +313,7 @@ discard block |
||
313 | 313 | 200, |
314 | 314 | array( |
315 | 315 | 'Content-Type' => 'application/pdf', |
316 | - 'Content-Disposition' => 'attachment; filename="' . $file . '"' |
|
316 | + 'Content-Disposition' => 'attachment; filename="'.$file.'"' |
|
317 | 317 | ) |
318 | 318 | ); |
319 | 319 | } |
@@ -39,7 +39,7 @@ discard block |
||
39 | 39 | return $this->createForm( |
40 | 40 | OrdersType::class, |
41 | 41 | $orders, |
42 | - ['attr' => ['id' => 'create'], 'action' => $this->generateUrl($route), 'method' => 'POST',] |
|
42 | + ['attr' => ['id' => 'create'], 'action' => $this->generateUrl($route), 'method' => 'POST', ] |
|
43 | 43 | ); |
44 | 44 | } |
45 | 45 | |
@@ -52,22 +52,22 @@ discard block |
||
52 | 52 | */ |
53 | 53 | protected function abstractPrintAction(Orders $orders, $from) |
54 | 54 | { |
55 | - $file = $from . '-' . $orders->getId() . '.pdf'; |
|
55 | + $file = $from.'-'.$orders->getId().'.pdf'; |
|
56 | 56 | $company = $this->getDoctrine()->getManager()->getRepository('AppBundle:Company')->find(1); |
57 | 57 | // Create and save the PDF file to print |
58 | 58 | $html = $this->renderView( |
59 | - 'AppBundle:' . $from . ':print.pdf.twig', |
|
59 | + 'AppBundle:'.$from.':print.pdf.twig', |
|
60 | 60 | ['articles' => $orders->getArticles(), 'orders' => $orders, 'company' => $company, ] |
61 | 61 | ); |
62 | 62 | return new Response( |
63 | 63 | $this->get('knp_snappy.pdf')->getOutputFromHtml( |
64 | 64 | $html, |
65 | - $this->getArray((string)date('d/m/y - H:i:s'), '') |
|
65 | + $this->getArray((string) date('d/m/y - H:i:s'), '') |
|
66 | 66 | ), |
67 | 67 | 200, |
68 | 68 | array( |
69 | 69 | 'Content-Type' => 'application/pdf', |
70 | - 'Content-Disposition' => 'attachment; filename="' . $file . '"' |
|
70 | + 'Content-Disposition' => 'attachment; filename="'.$file.'"' |
|
71 | 71 | ) |
72 | 72 | ); |
73 | 73 | } |
@@ -150,7 +150,7 @@ discard block |
||
150 | 150 | */ |
151 | 151 | public function setAmount($amount) |
152 | 152 | { |
153 | - $this->amount = (double)$amount; |
|
153 | + $this->amount = (double) $amount; |
|
154 | 154 | |
155 | 155 | return $this; |
156 | 156 | } |
@@ -173,7 +173,7 @@ discard block |
||
173 | 173 | */ |
174 | 174 | public function setTva($tva) |
175 | 175 | { |
176 | - $this->tva = (double)$tva; |
|
176 | + $this->tva = (double) $tva; |
|
177 | 177 | |
178 | 178 | return $this; |
179 | 179 | } |