@@ -15,7 +15,7 @@ discard block |
||
15 | 15 | * for multiple paths. |
16 | 16 | * example https://github.com/doctrine/DoctrineORMModule |
17 | 17 | */ |
18 | - 'paths' => array( __DIR__ . '/../src/Cv/Entity'), |
|
18 | + 'paths' => array(__DIR__.'/../src/Cv/Entity'), |
|
19 | 19 | ), |
20 | 20 | ), |
21 | 21 | 'eventmanager' => array( |
@@ -35,7 +35,7 @@ discard block |
||
35 | 35 | 'translation_file_patterns' => array( |
36 | 36 | array( |
37 | 37 | 'type' => 'gettext', |
38 | - 'base_dir' => __DIR__ . '/../language', |
|
38 | + 'base_dir' => __DIR__.'/../language', |
|
39 | 39 | 'pattern' => '%s.mo', |
40 | 40 | ), |
41 | 41 | ), |
@@ -165,7 +165,7 @@ discard block |
||
165 | 165 | 'resume-recruiter' => array( |
166 | 166 | 'label' => /*@translate*/ 'Talent-Pool', |
167 | 167 | 'route' => 'lang/cvs', |
168 | - 'active_on' => [ 'lang/cvs/edit', 'lang/cvs/view' ], |
|
168 | + 'active_on' => ['lang/cvs/edit', 'lang/cvs/view'], |
|
169 | 169 | 'resource' => 'navigation/resume-recruiter', |
170 | 170 | 'order' => 10, |
171 | 171 | 'pages' => array( |
@@ -198,7 +198,7 @@ discard block |
||
198 | 198 | |
199 | 199 | // Where to look for view templates not mapped above |
200 | 200 | 'template_path_stack' => array( |
201 | - __DIR__ . '/../view', |
|
201 | + __DIR__.'/../view', |
|
202 | 202 | ), |
203 | 203 | ), |
204 | 204 |
@@ -82,7 +82,7 @@ discard block |
||
82 | 82 | $name = $this->default; |
83 | 83 | } |
84 | 84 | |
85 | - if (!isset(static::$orderMap[ $name ])) { |
|
85 | + if (!isset(static::$orderMap[$name])) { |
|
86 | 86 | throw new \InvalidArgumentException(sprintf( |
87 | 87 | 'Unknown status name "%s" for "%s"', |
88 | 88 | $name, static::class |
@@ -90,6 +90,6 @@ discard block |
||
90 | 90 | } |
91 | 91 | |
92 | 92 | $this->name = $name; |
93 | - $this->order = static::$orderMap[ $name ]; |
|
93 | + $this->order = static::$orderMap[$name]; |
|
94 | 94 | } |
95 | 95 | } |
96 | 96 | \ No newline at end of file |
@@ -24,7 +24,7 @@ |
||
24 | 24 | { |
25 | 25 | protected $targetDocument = Cv::class; |
26 | 26 | |
27 | - protected $filesProperties = [ 'attachments' ]; |
|
27 | + protected $filesProperties = ['attachments']; |
|
28 | 28 | |
29 | 29 | /** |
30 | 30 | * |
@@ -49,7 +49,7 @@ |
||
49 | 49 | |
50 | 50 | public function getSubscribedEvents() |
51 | 51 | { |
52 | - return [ Events::onFlush ]; |
|
52 | + return [Events::onFlush]; |
|
53 | 53 | } |
54 | 54 | |
55 | 55 | /** |
@@ -29,7 +29,7 @@ discard block |
||
29 | 29 | { |
30 | 30 | $coordinates = $location->getCoordinates()->getCoordinates(); |
31 | 31 | $coordinate = doubleval($coordinates[0]).'%'.doubleval($coordinates[1]); |
32 | - $coordinate = strtr($coordinate,[ |
|
32 | + $coordinate = strtr($coordinate, [ |
|
33 | 33 | '%'=>',', |
34 | 34 | ','=>'.' |
35 | 35 | ]); |
@@ -55,15 +55,15 @@ discard block |
||
55 | 55 | */ |
56 | 56 | static public function validateDate($value) |
57 | 57 | { |
58 | - if ($value instanceof \SolrObject || is_array($value)){ |
|
58 | + if ($value instanceof \SolrObject || is_array($value)) { |
|
59 | 59 | return $value; |
60 | 60 | } |
61 | 61 | $value = trim($value); |
62 | - $date = \DateTime::createFromFormat(Manager::SOLR_DATE_FORMAT,$value); |
|
62 | + $date = \DateTime::createFromFormat(Manager::SOLR_DATE_FORMAT, $value); |
|
63 | 63 | $check = $date && ($date->format(Manager::SOLR_DATE_FORMAT) === $value); |
64 | - if($check){ |
|
64 | + if ($check) { |
|
65 | 65 | return $date; |
66 | - }else{ |
|
66 | + } else { |
|
67 | 67 | return $value; |
68 | 68 | } |
69 | 69 | } |
@@ -62,7 +62,7 @@ |
||
62 | 62 | if ($this->value['params']['status'] != 'all'){ |
63 | 63 | $queryBuilder->field('status.name')->equals($this->value['params']['status']); |
64 | 64 | } |
65 | - }else{ |
|
65 | + } else{ |
|
66 | 66 | $queryBuilder->field('status.name')->equals(Status::CREATED); |
67 | 67 | } |
68 | 68 |
@@ -37,7 +37,7 @@ discard block |
||
37 | 37 | * |
38 | 38 | * @var bool |
39 | 39 | */ |
40 | - protected $useGeoLocation=false; |
|
40 | + protected $useGeoLocation = false; |
|
41 | 41 | |
42 | 42 | /** |
43 | 43 | * @var ServiceLocatorInterface |
@@ -65,7 +65,7 @@ discard block |
||
65 | 65 | $entities = []; |
66 | 66 | $solrObjects = []; |
67 | 67 | |
68 | - foreach($response['response']['docs'] as $doc){ |
|
68 | + foreach ($response['response']['docs'] as $doc) { |
|
69 | 69 | $solrObjects[$doc->id] = $doc; |
70 | 70 | } |
71 | 71 | |
@@ -75,9 +75,9 @@ discard block |
||
75 | 75 | $qb = $repository->createQueryBuilder(); |
76 | 76 | $qb->hydrate(true)->field('id')->in($keys); |
77 | 77 | $result = $qb->getQuery()->execute(); |
78 | - foreach($result as $document){ |
|
78 | + foreach ($result as $document) { |
|
79 | 79 | $solrObject = $solrObjects[$document->getId()]; |
80 | - $entity = new $class($document,$solrObject); |
|
80 | + $entity = new $class($document, $solrObject); |
|
81 | 81 | $entity->setFacets($facets); |
82 | 82 | $entities[] = $entity; |
83 | 83 | } |
@@ -39,7 +39,7 @@ discard block |
||
39 | 39 | */ |
40 | 40 | protected $facets; |
41 | 41 | |
42 | - public function __construct(JobInterface $job,$solr) |
|
42 | + public function __construct(JobInterface $job, $solr) |
|
43 | 43 | { |
44 | 44 | $this->document = $job; |
45 | 45 | $blacklist = ['getPublisher']; |
@@ -51,12 +51,12 @@ discard block |
||
51 | 51 | { |
52 | 52 | $document = $this->document; |
53 | 53 | $methods = get_class_methods($document); |
54 | - foreach($methods as $method){ |
|
55 | - if(0 === strpos($method,'get') && !in_array($method,$blacklist)){ |
|
56 | - $value = call_user_func(array($document,$method)); |
|
57 | - if(!is_null($value)){ |
|
58 | - $setter = 'set'.substr($method,3); |
|
59 | - call_user_func(array($this,$setter),$value); |
|
54 | + foreach ($methods as $method) { |
|
55 | + if (0 === strpos($method, 'get') && !in_array($method, $blacklist)) { |
|
56 | + $value = call_user_func(array($document, $method)); |
|
57 | + if (!is_null($value)) { |
|
58 | + $setter = 'set'.substr($method, 3); |
|
59 | + call_user_func(array($this, $setter), $value); |
|
60 | 60 | } |
61 | 61 | } |
62 | 62 | } |