@@ -29,7 +29,6 @@ |
||
29 | 29 | * Attach to an event manager |
30 | 30 | * |
31 | 31 | * @param EventManagerInterface $events |
32 | - * @param integer $priority |
|
33 | 32 | */ |
34 | 33 | public function attach(EventManagerInterface $events) |
35 | 34 | { |
@@ -77,7 +77,7 @@ |
||
77 | 77 | } |
78 | 78 | $resolver = $e->getApplication()->getServiceManager()->get('ViewResolver'); |
79 | 79 | |
80 | - $template = $viewModel->getTemplate() . '.ajax'; |
|
80 | + $template = $viewModel->getTemplate().'.ajax'; |
|
81 | 81 | if ($resolver->resolve($template)) { |
82 | 82 | $viewModel->setTemplate($template); |
83 | 83 | } else { |
@@ -14,6 +14,9 @@ |
||
14 | 14 | |
15 | 15 | class OrganizationName extends AbstractRepository |
16 | 16 | { |
17 | + /** |
|
18 | + * @param string $name |
|
19 | + */ |
|
17 | 20 | public function findbyName($name, $create = true) |
18 | 21 | { |
19 | 22 | $entity = $this->findOneBy(array('name' => $name)); |
@@ -34,7 +34,7 @@ |
||
34 | 34 | } |
35 | 35 | |
36 | 36 | /** |
37 | - * @return string|\Zend\View\Helper\HelperInterface |
|
37 | + * @return string |
|
38 | 38 | */ |
39 | 39 | public function getViewHelper() |
40 | 40 | { |
@@ -30,11 +30,11 @@ |
||
30 | 30 | */ |
31 | 31 | class Module |
32 | 32 | { |
33 | - /** |
|
34 | - * Loads module specific configuration. |
|
35 | - * |
|
36 | - * @return array |
|
37 | - */ |
|
33 | + /** |
|
34 | + * Loads module specific configuration. |
|
35 | + * |
|
36 | + * @return array |
|
37 | + */ |
|
38 | 38 | public function getConfig() |
39 | 39 | { |
40 | 40 | return ModuleConfigLoader::load(__DIR__ . '/config'); |
@@ -37,7 +37,7 @@ discard block |
||
37 | 37 | */ |
38 | 38 | public function getConfig() |
39 | 39 | { |
40 | - return ModuleConfigLoader::load(__DIR__ . '/config'); |
|
40 | + return ModuleConfigLoader::load(__DIR__.'/config'); |
|
41 | 41 | } |
42 | 42 | |
43 | 43 | /** |
@@ -50,7 +50,7 @@ discard block |
||
50 | 50 | return array( |
51 | 51 | 'Zend\Loader\StandardAutoloader' => array( |
52 | 52 | 'namespaces' => array( |
53 | - __NAMESPACE__ => __DIR__ . '/src/' . __NAMESPACE__, |
|
53 | + __NAMESPACE__ => __DIR__.'/src/'.__NAMESPACE__, |
|
54 | 54 | ), |
55 | 55 | ), |
56 | 56 | ); |
@@ -26,11 +26,11 @@ |
||
26 | 26 | // 'driver' => 'odm_default', |
27 | 27 | // |
28 | 28 | // 'generate_proxies' => true, |
29 | - 'proxy_dir' => 'cache/DoctrineMongoODMModule/Proxy', |
|
29 | + 'proxy_dir' => 'cache/DoctrineMongoODMModule/Proxy', |
|
30 | 30 | // 'proxy_namespace' => 'DoctrineMongoODMModule\Proxy', |
31 | 31 | // |
32 | 32 | // 'generate_hydrators' => true, |
33 | - 'hydrator_dir' => 'cache/DoctrineMongoODMModule/Hydrator', |
|
33 | + 'hydrator_dir' => 'cache/DoctrineMongoODMModule/Hydrator', |
|
34 | 34 | // 'hydrator_namespace' => 'DoctrineMongoODMModule\Hydrator', |
35 | 35 | // |
36 | 36 | // 'default_db' => '', |
@@ -131,7 +131,7 @@ |
||
131 | 131 | { |
132 | 132 | $viewModel = new ViewModel(); |
133 | 133 | $viewModel->setTemplate('error/index') |
134 | - ->setVariable('message', 'An unexpected error had occured. Please try again later.'); |
|
134 | + ->setVariable('message', 'An unexpected error had occured. Please try again later.'); |
|
135 | 135 | return $viewModel; |
136 | 136 | } |
137 | 137 | } |
@@ -41,10 +41,10 @@ |
||
41 | 41 | |
42 | 42 | $plugin = new InvitationHandler(); |
43 | 43 | $plugin->setEmailValidator($validator) |
44 | - ->setMailerPlugin($mailer) |
|
45 | - ->setTranslator($translator) |
|
46 | - ->setUserRepository($repository) |
|
47 | - ->setUserTokenGenerator($generator); |
|
44 | + ->setMailerPlugin($mailer) |
|
45 | + ->setTranslator($translator) |
|
46 | + ->setUserRepository($repository) |
|
47 | + ->setUserTokenGenerator($generator); |
|
48 | 48 | |
49 | 49 | return $plugin; |
50 | 50 | } |
@@ -128,10 +128,10 @@ discard block |
||
128 | 128 | // ) |
129 | 129 | // ); |
130 | 130 | $qb->addAnd($qb->expr()->field('user')->equals($userId)) |
131 | - ->addAnd( |
|
132 | - $qb->expr()->addOr($qb->expr()->field('parent')->exists(false)) |
|
133 | - ->addOr($qb->expr()->field('parent')->equals(null)) |
|
134 | - ); |
|
131 | + ->addAnd( |
|
132 | + $qb->expr()->addOr($qb->expr()->field('parent')->exists(false)) |
|
133 | + ->addOr($qb->expr()->field('parent')->equals(null)) |
|
134 | + ); |
|
135 | 135 | |
136 | 136 | $q = $qb->getQuery(); |
137 | 137 | $entity = $q->getSingleResult(); |
@@ -252,7 +252,7 @@ discard block |
||
252 | 252 | if ($userOrg->hasAssociation()) { |
253 | 253 | $qb->addAnd( |
254 | 254 | $qb->expr()->addOr($qb->expr()->field('parent')->equals($userOrg->getId())) |
255 | - ->addOr($qb->expr()->field('_id')->equals($userOrg->getId())) |
|
255 | + ->addOr($qb->expr()->field('_id')->equals($userOrg->getId())) |
|
256 | 256 | ); |
257 | 257 | } |
258 | 258 |
@@ -106,7 +106,7 @@ discard block |
||
106 | 106 | /** |
107 | 107 | * Finds the main organization of an user. |
108 | 108 | * |
109 | - * @param string|UserInterface $userOrId |
|
109 | + * @param string $userOrId |
|
110 | 110 | * |
111 | 111 | * @return null|OrganizationInterface |
112 | 112 | */ |
@@ -142,7 +142,7 @@ discard block |
||
142 | 142 | /** |
143 | 143 | * Finds the organization, an user is employed by. |
144 | 144 | * |
145 | - * @param string|UserInterface $userOrId |
|
145 | + * @param string $userOrId |
|
146 | 146 | * |
147 | 147 | * @return null|OrganizationInterface |
148 | 148 | */ |
@@ -270,7 +270,7 @@ discard block |
||
270 | 270 | /** |
271 | 271 | * Look for an drafted Document of a given user |
272 | 272 | * |
273 | - * @param $user |
|
273 | + * @param \Auth\Entity\AnonymousUser $user |
|
274 | 274 | * @return \Organizations\Entity\Organization|null |
275 | 275 | */ |
276 | 276 | public function findDraft($user) |
@@ -225,7 +225,7 @@ discard block |
||
225 | 225 | $organizationNameQb = $this->getDocumentManager()->createQueryBuilder('Organizations\Entity\OrganizationName'); |
226 | 226 | $organizationNameQb->hydrate(false) |
227 | 227 | ->select(array('id', 'name')) |
228 | - ->field('name')->equals(new \MongoRegex('/' . $query . '/i')) |
|
228 | + ->field('name')->equals(new \MongoRegex('/'.$query.'/i')) |
|
229 | 229 | ->sort('name') |
230 | 230 | ->limit(5); |
231 | 231 | |
@@ -260,7 +260,7 @@ discard block |
||
260 | 260 | |
261 | 261 | foreach ($result as $id => $item) { |
262 | 262 | $organizations[$id] = $item; |
263 | - $organizationNameId = (string)$organizations[$id]['organizationName']; |
|
263 | + $organizationNameId = (string) $organizations[$id]['organizationName']; |
|
264 | 264 | $organizations[$id]['organizationName'] = $organizationNames[$organizationNameId]; |
265 | 265 | } |
266 | 266 |
@@ -380,10 +380,10 @@ |
||
380 | 380 | return $this; |
381 | 381 | } |
382 | 382 | |
383 | - /** |
|
384 | - * (non-PHPdoc) |
|
385 | - * @see \Jobs\Entity\JobInterface::getOrganization() |
|
386 | - */ |
|
383 | + /** |
|
384 | + * (non-PHPdoc) |
|
385 | + * @see \Jobs\Entity\JobInterface::getOrganization() |
|
386 | + */ |
|
387 | 387 | public function getOrganization() |
388 | 388 | { |
389 | 389 | return $this->organization; |
@@ -503,7 +503,7 @@ discard block |
||
503 | 503 | } |
504 | 504 | /** |
505 | 505 | * Gets the number of unread applications |
506 | - * @return Collection |
|
506 | + * @return integer |
|
507 | 507 | */ |
508 | 508 | public function getUnreadApplications() |
509 | 509 | { |
@@ -917,7 +917,7 @@ discard block |
||
917 | 917 | } |
918 | 918 | |
919 | 919 | /** |
920 | - * @return Job |
|
920 | + * @return JobSnapshot |
|
921 | 921 | */ |
922 | 922 | public function makeSnapshot() |
923 | 923 | { |
@@ -480,7 +480,7 @@ discard block |
||
480 | 480 | if ($removePermissions) { |
481 | 481 | $this->getPermissions()->revoke($this->user, Permissions::PERMISSION_ALL); |
482 | 482 | } |
483 | - $this->user=null; |
|
483 | + $this->user = null; |
|
484 | 484 | } |
485 | 485 | |
486 | 486 | return $this; |
@@ -705,7 +705,7 @@ discard block |
||
705 | 705 | $organization = $this->organization; |
706 | 706 | if (isset($organization) && isset($organization->image)) { |
707 | 707 | $organizationImage = $organization->image; |
708 | - return "/file/Organizations.OrganizationImage/" . $organizationImage->id; |
|
708 | + return "/file/Organizations.OrganizationImage/".$organizationImage->id; |
|
709 | 709 | } |
710 | 710 | return $this->logoRef; |
711 | 711 | } |