@@ -25,24 +25,24 @@ discard block |
||
25 | 25 | */ |
26 | 26 | class IndexController extends AbstractActionController |
27 | 27 | { |
28 | - /** @var DefaultListener */ |
|
29 | - private $defaultListener; |
|
28 | + /** @var DefaultListener */ |
|
29 | + private $defaultListener; |
|
30 | 30 | |
31 | - private $config; |
|
31 | + private $config; |
|
32 | 32 | |
33 | - /** |
|
34 | - * @var ModuleManager |
|
35 | - */ |
|
36 | - private $moduleManager; |
|
33 | + /** |
|
34 | + * @var ModuleManager |
|
35 | + */ |
|
36 | + private $moduleManager; |
|
37 | 37 | |
38 | - public function __construct( |
|
38 | + public function __construct( |
|
39 | 39 | ModuleManagerInterface $moduleManager, |
40 | 40 | $config |
41 | 41 | ) |
42 | - { |
|
43 | - $this->config = $config; |
|
44 | - $this->moduleManager = $moduleManager; |
|
45 | - } |
|
42 | + { |
|
43 | + $this->config = $config; |
|
44 | + $this->moduleManager = $moduleManager; |
|
45 | + } |
|
46 | 46 | |
47 | 47 | /** |
48 | 48 | * Home site |
@@ -106,7 +106,7 @@ discard block |
||
106 | 106 | { |
107 | 107 | $viewModel = new ViewModel(); |
108 | 108 | $viewModel->setTemplate('error/index') |
109 | - ->setVariable('message', 'An unexpected error had occured. Please try again later.'); |
|
109 | + ->setVariable('message', 'An unexpected error had occured. Please try again later.'); |
|
110 | 110 | return $viewModel; |
111 | 111 | } |
112 | 112 | } |
@@ -30,12 +30,12 @@ discard block |
||
30 | 30 | */ |
31 | 31 | class OrganizationContext implements Context |
32 | 32 | { |
33 | - use CommonContextTrait; |
|
33 | + use CommonContextTrait; |
|
34 | 34 | |
35 | 35 | /** |
36 | 36 | * @var JobContext |
37 | 37 | */ |
38 | - private $jobContext; |
|
38 | + private $jobContext; |
|
39 | 39 | |
40 | 40 | /** |
41 | 41 | * @BeforeScenario |
@@ -47,51 +47,51 @@ discard block |
||
47 | 47 | $this->jobContext = $scope->getEnvironment()->getContext(JobContext::class); |
48 | 48 | } |
49 | 49 | |
50 | - /** |
|
51 | - * @Given I go to my organization page |
|
52 | - */ |
|
53 | - public function iGoToMyOrganizationPage() |
|
54 | - { |
|
50 | + /** |
|
51 | + * @Given I go to my organization page |
|
52 | + */ |
|
53 | + public function iGoToMyOrganizationPage() |
|
54 | + { |
|
55 | 55 | $url = $this->buildUrl('lang/my-organization'); |
56 | - $this->visit($url); |
|
57 | - } |
|
56 | + $this->visit($url); |
|
57 | + } |
|
58 | 58 | |
59 | - /** |
|
60 | - * @When I hover over name form |
|
61 | - */ |
|
62 | - public function iMouseOverOrganizationNameForm() |
|
63 | - { |
|
64 | - $locator = '#sf-nameForm .sf-summary'; |
|
65 | - $this->coreContext->iHoverOverTheElement($locator); |
|
66 | - } |
|
59 | + /** |
|
60 | + * @When I hover over name form |
|
61 | + */ |
|
62 | + public function iMouseOverOrganizationNameForm() |
|
63 | + { |
|
64 | + $locator = '#sf-nameForm .sf-summary'; |
|
65 | + $this->coreContext->iHoverOverTheElement($locator); |
|
66 | + } |
|
67 | 67 | |
68 | - /** |
|
69 | - * @Given I go to create new organization page |
|
70 | - */ |
|
71 | - public function iGoToCreateNewOrganizationPage() |
|
72 | - { |
|
73 | - //$this->visit('/organizations/edit'); |
|
68 | + /** |
|
69 | + * @Given I go to create new organization page |
|
70 | + */ |
|
71 | + public function iGoToCreateNewOrganizationPage() |
|
72 | + { |
|
73 | + //$this->visit('/organizations/edit'); |
|
74 | 74 | $url = $this->buildUrl('lang/organizations/edit'); |
75 | 75 | $this->visit($url); |
76 | - } |
|
76 | + } |
|
77 | 77 | |
78 | - /** |
|
79 | - * @Given I go to organization overview page |
|
80 | - */ |
|
81 | - public function iGoToOrganizationOverviewPage() |
|
82 | - { |
|
83 | - //$this->visit('/organizations'); |
|
84 | - $url = $this->buildUrl('lang/organizations'); |
|
85 | - $this->visit($url); |
|
86 | - } |
|
78 | + /** |
|
79 | + * @Given I go to organization overview page |
|
80 | + */ |
|
81 | + public function iGoToOrganizationOverviewPage() |
|
82 | + { |
|
83 | + //$this->visit('/organizations'); |
|
84 | + $url = $this->buildUrl('lang/organizations'); |
|
85 | + $this->visit($url); |
|
86 | + } |
|
87 | 87 | |
88 | 88 | /** |
89 | 89 | * @Given I want to see list organization profiles |
90 | 90 | */ |
91 | - public function iWantToSeeListOrganizationProfiles() |
|
91 | + public function iWantToSeeListOrganizationProfiles() |
|
92 | 92 | { |
93 | - $url = $this->buildUrl('lang/organizations/profile'); |
|
94 | - $this->visit($url); |
|
93 | + $url = $this->buildUrl('lang/organizations/profile'); |
|
94 | + $this->visit($url); |
|
95 | 95 | } |
96 | 96 | |
97 | 97 | /** |
@@ -100,7 +100,7 @@ discard block |
||
100 | 100 | * @internal param string $name |
101 | 101 | * @internal param TableNode|null $table |
102 | 102 | */ |
103 | - public function iHaveOrganization($name) |
|
103 | + public function iHaveOrganization($name) |
|
104 | 104 | { |
105 | 105 | $user = $this->getUserContext()->getCurrentUser(); |
106 | 106 | $organization = $this->findOrganizationByName($name,false); |
@@ -103,9 +103,9 @@ discard block |
||
103 | 103 | public function iHaveOrganization($name) |
104 | 104 | { |
105 | 105 | $user = $this->getUserContext()->getCurrentUser(); |
106 | - $organization = $this->findOrganizationByName($name,false); |
|
106 | + $organization = $this->findOrganizationByName($name, false); |
|
107 | 107 | $repo = $this->getRepository('Organizations/Organization'); |
108 | - if(!$organization instanceof Organization){ |
|
108 | + if (!$organization instanceof Organization) { |
|
109 | 109 | |
110 | 110 | $organization = new Organization(); |
111 | 111 | $organizationName = new OrganizationName($name); |
@@ -118,7 +118,7 @@ discard block |
||
118 | 118 | $organization->setParent($parent); |
119 | 119 | $organization->setProfileSetting(Organization::PROFILE_ALWAYS_ENABLE); |
120 | 120 | $permissions = $organization->getPermissions(); |
121 | - $permissions->grant($user,Permissions::PERMISSION_ALL); |
|
121 | + $permissions->grant($user, Permissions::PERMISSION_ALL); |
|
122 | 122 | |
123 | 123 | $repo->store($organization); |
124 | 124 | $repo->getDocumentManager()->refresh($organization); |
@@ -128,19 +128,19 @@ discard block |
||
128 | 128 | /** |
129 | 129 | * @Given organization :name have jobs: |
130 | 130 | */ |
131 | - public function organizationHavePublishedJob($name,TableNode $table) |
|
131 | + public function organizationHavePublishedJob($name, TableNode $table) |
|
132 | 132 | { |
133 | 133 | $user = $this->getUserContext()->getCurrentUser(); |
134 | - if(is_null($user)){ |
|
134 | + if (is_null($user)) { |
|
135 | 135 | throw new FailedExpectationException('Need to login first'); |
136 | 136 | } |
137 | 137 | |
138 | 138 | $organization = $this->findOrganizationByName($name); |
139 | - foreach($table->getColumnsHash() as $index=>$definitions){ |
|
139 | + foreach ($table->getColumnsHash() as $index=>$definitions) { |
|
140 | 140 | $definitions['user'] = $user->getLogin(); |
141 | - $status = isset($definitions['status']) ? $definitions['status']:'draft'; |
|
141 | + $status = isset($definitions['status']) ? $definitions['status'] : 'draft'; |
|
142 | 142 | unset($definitions['status']); |
143 | - $this->jobContext->buildJob($status,$definitions,$organization); |
|
143 | + $this->jobContext->buildJob($status, $definitions, $organization); |
|
144 | 144 | } |
145 | 145 | } |
146 | 146 | |
@@ -149,7 +149,7 @@ discard block |
||
149 | 149 | * @param $name |
150 | 150 | * @param $setting |
151 | 151 | */ |
152 | - public function profileSetting($name,$setting) |
|
152 | + public function profileSetting($name, $setting) |
|
153 | 153 | { |
154 | 154 | $repo = $this->getRepository('Organizations/Organization'); |
155 | 155 | $organization = $this->findOrganizationByName($name); |
@@ -169,12 +169,12 @@ discard block |
||
169 | 169 | $contact = $organization->getContact(); |
170 | 170 | |
171 | 171 | $definitions = $table->getRowsHash(); |
172 | - foreach($definitions as $name=>$value){ |
|
172 | + foreach ($definitions as $name=>$value) { |
|
173 | 173 | $field = Inflector::camelize($name); |
174 | 174 | $method = 'set'.$field; |
175 | - $callback = array($contact,$method); |
|
176 | - if(is_callable($callback)){ |
|
177 | - call_user_func_array($callback,[$value]); |
|
175 | + $callback = array($contact, $method); |
|
176 | + if (is_callable($callback)) { |
|
177 | + call_user_func_array($callback, [$value]); |
|
178 | 178 | } |
179 | 179 | } |
180 | 180 | $this->getRepository('Organizations/Organization')->store($organization); |
@@ -186,14 +186,14 @@ discard block |
||
186 | 186 | * @param string $name |
187 | 187 | * @throws FailedExpectationException |
188 | 188 | */ |
189 | - public function iGoToOrganizationProfilePage($name=null) |
|
189 | + public function iGoToOrganizationProfilePage($name = null) |
|
190 | 190 | { |
191 | - if(is_null($name)){ |
|
191 | + if (is_null($name)) { |
|
192 | 192 | $organization = $this->getUserContext()->getCurrentUser()->getOrganization()->getOrganization(); |
193 | - }else{ |
|
193 | + } else { |
|
194 | 194 | $organization = $this->findOrganizationByName($name); |
195 | 195 | } |
196 | - $url = $this->buildUrl('lang/organizations/profileDetail',[ |
|
196 | + $url = $this->buildUrl('lang/organizations/profileDetail', [ |
|
197 | 197 | 'id' => $organization->getId() |
198 | 198 | ]); |
199 | 199 | |
@@ -210,10 +210,10 @@ discard block |
||
210 | 210 | /* @var OrganizationRepository $repo */ |
211 | 211 | $repo = $this->getRepository('Organizations/Organization'); |
212 | 212 | $result = $repo->findByName($name); |
213 | - $organization = count($result) > 0 ? $result[0]:null; |
|
214 | - if(!$organization instanceof Organization && $throwException){ |
|
213 | + $organization = count($result) > 0 ? $result[0] : null; |
|
214 | + if (!$organization instanceof Organization && $throwException) { |
|
215 | 215 | throw new FailedExpectationException( |
216 | - sprintf('Organization %s is not found.',$name) |
|
216 | + sprintf('Organization %s is not found.', $name) |
|
217 | 217 | ); |
218 | 218 | } |
219 | 219 | return $organization; |
@@ -232,8 +232,8 @@ discard block |
||
232 | 232 | $jobRepo = $this->getRepository('Jobs/Job'); |
233 | 233 | $result = $jobRepo->findByOrganization($org->getId()); |
234 | 234 | |
235 | - foreach($result as $job){ |
|
236 | - $jobRepo->remove($job,true); |
|
235 | + foreach ($result as $job) { |
|
236 | + $jobRepo->remove($job, true); |
|
237 | 237 | } |
238 | 238 | } |
239 | 239 | |
@@ -244,7 +244,7 @@ discard block |
||
244 | 244 | { |
245 | 245 | $user = $this->getUserContext()->getCurrentUser(); |
246 | 246 | $organization = $user->getOrganization()->getOrganization(); |
247 | - $url = $this->buildUrl('lang/organizations/edit',['id' => $organization->getId()]); |
|
247 | + $url = $this->buildUrl('lang/organizations/edit', ['id' => $organization->getId()]); |
|
248 | 248 | $this->visit($url); |
249 | 249 | } |
250 | 250 | |
@@ -255,7 +255,7 @@ discard block |
||
255 | 255 | public function iAttachLogoFromFile($file) |
256 | 256 | { |
257 | 257 | $elementId = 'organizationLogo-original'; |
258 | - $this->minkContext->attachFileToField($elementId,$file); |
|
258 | + $this->minkContext->attachFileToField($elementId, $file); |
|
259 | 259 | } |
260 | 260 | |
261 | 261 | /** |
@@ -264,7 +264,7 @@ discard block |
||
264 | 264 | public function iRemoveLogoFromOrganization() |
265 | 265 | { |
266 | 266 | $elementId = '#organizationLogo-original-delete'; |
267 | - $element = $this->minkContext->getSession()->getPage()->find('css',$elementId); |
|
267 | + $element = $this->minkContext->getSession()->getPage()->find('css', $elementId); |
|
268 | 268 | $element->click(); |
269 | 269 | } |
270 | 270 | } |
@@ -190,7 +190,7 @@ |
||
190 | 190 | { |
191 | 191 | if(is_null($name)){ |
192 | 192 | $organization = $this->getUserContext()->getCurrentUser()->getOrganization()->getOrganization(); |
193 | - }else{ |
|
193 | + } else{ |
|
194 | 194 | $organization = $this->findOrganizationByName($name); |
195 | 195 | } |
196 | 196 | $url = $this->buildUrl('lang/organizations/profileDetail',[ |
@@ -33,7 +33,7 @@ discard block |
||
33 | 33 | * |
34 | 34 | * @var String |
35 | 35 | */ |
36 | - protected $repositoryName="Organizations/Organization"; |
|
36 | + protected $repositoryName = "Organizations/Organization"; |
|
37 | 37 | |
38 | 38 | /** |
39 | 39 | * Sortable fields |
@@ -91,12 +91,12 @@ discard block |
||
91 | 91 | */ |
92 | 92 | $auth = $this->authService; |
93 | 93 | $user = $auth->getUser(); |
94 | - $ignored = [null,'guest',UserInterface::ROLE_USER]; |
|
95 | - if(!in_array($user->getRole(),$ignored)){ |
|
94 | + $ignored = [null, 'guest', UserInterface::ROLE_USER]; |
|
95 | + if (!in_array($user->getRole(), $ignored)) { |
|
96 | 96 | $queryBuilder->field('permissions.view')->equals($user->getId()); |
97 | 97 | } |
98 | 98 | |
99 | - if (isset($params['q']) && $params['q'] && $params['q'] != 'en/organizations/profile' ) { |
|
99 | + if (isset($params['q']) && $params['q'] && $params['q'] != 'en/organizations/profile') { |
|
100 | 100 | $queryBuilder->text($params['q'])->language('none'); |
101 | 101 | } |
102 | 102 | |
@@ -106,14 +106,14 @@ discard block |
||
106 | 106 | |
107 | 107 | $queryBuilder->sort($this->filterSort($value['sort'])); |
108 | 108 | |
109 | - if(isset($params['type']) && $params['type'] === 'profile'){ |
|
109 | + if (isset($params['type']) && $params['type'] === 'profile') { |
|
110 | 110 | //@TODO: we should use aggregate query here |
111 | 111 | $queryBuilder->field('profileSetting') |
112 | - ->in([Organization::PROFILE_ALWAYS_ENABLE,Organization::PROFILE_ACTIVE_JOBS]) |
|
112 | + ->in([Organization::PROFILE_ALWAYS_ENABLE, Organization::PROFILE_ACTIVE_JOBS]) |
|
113 | 113 | ; |
114 | 114 | |
115 | 115 | $filters = $this->getOrganizationProfileFilters($queryBuilder); |
116 | - if(count($filters) > 0){ |
|
116 | + if (count($filters) > 0) { |
|
117 | 117 | $queryBuilder->field('id')->notIn($filters); |
118 | 118 | } |
119 | 119 | |
@@ -133,8 +133,8 @@ discard block |
||
133 | 133 | $results = $queryBuilder->getQuery()->execute(); |
134 | 134 | |
135 | 135 | $filters = []; |
136 | - foreach($results->toArray() as $organization){ |
|
137 | - if($organization->getProfileSetting()==Organization::PROFILE_ACTIVE_JOBS){ |
|
136 | + foreach ($results->toArray() as $organization) { |
|
137 | + if ($organization->getProfileSetting() == Organization::PROFILE_ACTIVE_JOBS) { |
|
138 | 138 | $qb = $jobRepository->createQueryBuilder(); |
139 | 139 | $qb |
140 | 140 | ->field('organization')->equals($organization->getId()) |
@@ -142,7 +142,7 @@ discard block |
||
142 | 142 | ->field('isDraft')->notEqual(true) |
143 | 143 | ; |
144 | 144 | $count = $qb->getQuery()->execute()->count(); |
145 | - if($count == 0){ |
|
145 | + if ($count == 0) { |
|
146 | 146 | $filters[] = $organization->getId(); |
147 | 147 | } |
148 | 148 | } |
@@ -37,7 +37,7 @@ |
||
37 | 37 | /* @TODO: $jobRepository should be removed when using aggregation query in filtering profile */ |
38 | 38 | $authService = $container->get('AuthenticationService'); |
39 | 39 | $jobRepository = $container->get('Core/RepositoryService')->get('Jobs/Job'); |
40 | - $filter = new PaginationQuery($jobRepository,$authService); |
|
40 | + $filter = new PaginationQuery($jobRepository, $authService); |
|
41 | 41 | return $filter; |
42 | 42 | } |
43 | 43 | } |
@@ -33,6 +33,6 @@ |
||
33 | 33 | $translator = $container->get('translator'); |
34 | 34 | $imageFileCacheManager = $container->get('Organizations\ImageFileCache\Manager'); |
35 | 35 | $options = $container->get('Jobs/JobboardSearchOptions'); |
36 | - return new ProfileController($repo,$jobRepository,$translator,$imageFileCacheManager,['count' => $options->getPerPage()]); |
|
36 | + return new ProfileController($repo, $jobRepository, $translator, $imageFileCacheManager, ['count' => $options->getPerPage()]); |
|
37 | 37 | } |
38 | 38 | } |
@@ -28,27 +28,27 @@ |
||
28 | 28 | */ |
29 | 29 | class FileController extends AbstractActionController |
30 | 30 | { |
31 | - /** |
|
32 | - * @var RepositoryService |
|
33 | - */ |
|
34 | - private $repositories; |
|
31 | + /** |
|
32 | + * @var RepositoryService |
|
33 | + */ |
|
34 | + private $repositories; |
|
35 | 35 | |
36 | - /** |
|
37 | - * @var EventManager |
|
38 | - */ |
|
39 | - private $coreFileEvents; |
|
36 | + /** |
|
37 | + * @var EventManager |
|
38 | + */ |
|
39 | + private $coreFileEvents; |
|
40 | 40 | |
41 | - public function __construct( |
|
42 | - RepositoryService $repositories, |
|
43 | - EventManager $eventManager |
|
44 | - ) |
|
45 | - { |
|
46 | - $this->repositories = $repositories; |
|
47 | - $this->coreFileEvents = $eventManager; |
|
48 | - } |
|
41 | + public function __construct( |
|
42 | + RepositoryService $repositories, |
|
43 | + EventManager $eventManager |
|
44 | + ) |
|
45 | + { |
|
46 | + $this->repositories = $repositories; |
|
47 | + $this->coreFileEvents = $eventManager; |
|
48 | + } |
|
49 | 49 | |
50 | 50 | |
51 | - protected function attachDefaultListeners() |
|
51 | + protected function attachDefaultListeners() |
|
52 | 52 | { |
53 | 53 | parent::attachDefaultListeners(); |
54 | 54 | $events = $this->getEventManager(); |
@@ -73,7 +73,7 @@ discard block |
||
73 | 73 | $response = $this->getResponse(); |
74 | 74 | |
75 | 75 | try { |
76 | - $repository = $this->repositories->get($module . '/' . $entityName); |
|
76 | + $repository = $this->repositories->get($module.'/'.$entityName); |
|
77 | 77 | } catch (\Exception $e) { |
78 | 78 | $response->setStatusCode(404); |
79 | 79 | $this->getEvent()->setParam('exception', $e); |
@@ -107,7 +107,7 @@ discard block |
||
107 | 107 | |
108 | 108 | $this->acl($file); |
109 | 109 | |
110 | - $headers=$response->getHeaders(); |
|
110 | + $headers = $response->getHeaders(); |
|
111 | 111 | |
112 | 112 | $headers->addHeaderline('Content-Type', $file->getType()) |
113 | 113 | ->addHeaderline('Content-Length', $file->getLength()); |
@@ -26,6 +26,6 @@ |
||
26 | 26 | $repositories = $container->get('repositories'); |
27 | 27 | $coreFileEvents = $container->get('Core/File/Events'); |
28 | 28 | |
29 | - return new FileController($repositories,$coreFileEvents); |
|
29 | + return new FileController($repositories, $coreFileEvents); |
|
30 | 30 | } |
31 | 31 | } |
@@ -42,24 +42,24 @@ discard block |
||
42 | 42 | 'log' => array( |
43 | 43 | 'Core/Log' => array( |
44 | 44 | 'writers' => array( |
45 | - array( |
|
46 | - 'name' => 'stream', |
|
45 | + array( |
|
46 | + 'name' => 'stream', |
|
47 | 47 | 'priority' => 1000, |
48 | 48 | 'options' => array( |
49 | - 'stream' => __DIR__ .'/../../../log/yawik.log', |
|
49 | + 'stream' => __DIR__ .'/../../../log/yawik.log', |
|
50 | + ), |
|
50 | 51 | ), |
51 | - ), |
|
52 | 52 | ), |
53 | 53 | ), |
54 | 54 | 'Log/Core/Mail' => array( |
55 | 55 | 'writers' => array( |
56 | - array( |
|
57 | - 'name' => 'stream', |
|
56 | + array( |
|
57 | + 'name' => 'stream', |
|
58 | 58 | 'priority' => 1000, |
59 | 59 | 'options' => array( |
60 | - 'stream' => __DIR__ .'/../../../log/mails.log', |
|
60 | + 'stream' => __DIR__ .'/../../../log/mails.log', |
|
61 | + ), |
|
61 | 62 | ), |
62 | - ), |
|
63 | 63 | ), |
64 | 64 | ), |
65 | 65 | ), |
@@ -290,12 +290,12 @@ discard block |
||
290 | 290 | ), |
291 | 291 | // Configuration of the controller service manager (Which loads controllers) |
292 | 292 | 'controllers' => array( |
293 | - 'factories' => [ |
|
294 | - 'Core/Index' => LazyControllerFactory::class, |
|
293 | + 'factories' => [ |
|
294 | + 'Core/Index' => LazyControllerFactory::class, |
|
295 | 295 | 'Core/Admin' => AdminControllerFactory::class, |
296 | - 'Core/File' => FileControllerFactory::class, |
|
296 | + 'Core/File' => FileControllerFactory::class, |
|
297 | 297 | 'Core/Content' => LazyControllerFactory::class, |
298 | - ], |
|
298 | + ], |
|
299 | 299 | ), |
300 | 300 | // Configuration of the controller plugin service manager |
301 | 301 | 'controller_plugins' => array( |
@@ -325,7 +325,7 @@ discard block |
||
325 | 325 | 'paginatorservice' => 'Core/PaginatorService', |
326 | 326 | 'paginationParams' => 'Core/PaginationParams', |
327 | 327 | 'searchform' => 'Core/SearchForm', |
328 | - 'notification' => 'Notification', |
|
328 | + 'notification' => 'Notification', |
|
329 | 329 | ) |
330 | 330 | ), |
331 | 331 | // Configure the view service manager |
@@ -423,7 +423,7 @@ discard block |
||
423 | 423 | ), |
424 | 424 | 'aliases' => [ |
425 | 425 | 'snippet' => \Core\View\Helper\Snippet::class, |
426 | - 'ajaxUrl' => \Core\View\Helper\AjaxUrl::class, |
|
426 | + 'ajaxUrl' => \Core\View\Helper\AjaxUrl::class, |
|
427 | 427 | 'proxy' => \Core\View\Helper\Proxy::class, |
428 | 428 | 'form_element' => 'formElement', |
429 | 429 | ], |
@@ -521,17 +521,17 @@ discard block |
||
521 | 521 | ], |
522 | 522 | |
523 | 523 | 'Core/Ajax/Events' => [ |
524 | - 'service' => 'Core/EventManager', |
|
525 | - 'event' => \Core\Listener\Events\AjaxEvent::class, |
|
524 | + 'service' => 'Core/EventManager', |
|
525 | + 'event' => \Core\Listener\Events\AjaxEvent::class, |
|
526 | 526 | ], |
527 | 527 | |
528 | - 'Core/File/Events' => [ |
|
529 | - 'service' => 'Core/EventManager', |
|
530 | - 'event' => \Core\Listener\Events\FileEvent::class, |
|
528 | + 'Core/File/Events' => [ |
|
529 | + 'service' => 'Core/EventManager', |
|
530 | + 'event' => \Core\Listener\Events\FileEvent::class, |
|
531 | 531 | 'listeners' => [ |
532 | 532 | \Core\Listener\DeleteImageSetListener::class => [\Core\Listener\Events\FileEvent::EVENT_DELETE, -1000], |
533 | 533 | ], |
534 | - ] |
|
534 | + ] |
|
535 | 535 | ], |
536 | 536 | |
537 | 537 | ); |
@@ -19,7 +19,7 @@ discard block |
||
19 | 19 | use Zend\I18n\Translator\Resources; |
20 | 20 | use Zend\ServiceManager\Factory\InvokableFactory; |
21 | 21 | |
22 | -$doctrineConfig = include __DIR__ . '/doctrine.config.php'; |
|
22 | +$doctrineConfig = include __DIR__.'/doctrine.config.php'; |
|
23 | 23 | |
24 | 24 | |
25 | 25 | return array( |
@@ -27,7 +27,7 @@ discard block |
||
27 | 27 | 'doctrine' => $doctrineConfig, |
28 | 28 | |
29 | 29 | 'options' => [ |
30 | - 'Core/MailServiceOptions' => [ 'class' => '\Core\Options\MailServiceOptions' ], |
|
30 | + 'Core/MailServiceOptions' => ['class' => '\Core\Options\MailServiceOptions'], |
|
31 | 31 | ], |
32 | 32 | |
33 | 33 | 'Core' => array( |
@@ -47,7 +47,7 @@ discard block |
||
47 | 47 | 'name' => 'stream', |
48 | 48 | 'priority' => 1000, |
49 | 49 | 'options' => array( |
50 | - 'stream' => __DIR__ .'/../../../log/yawik.log', |
|
50 | + 'stream' => __DIR__.'/../../../log/yawik.log', |
|
51 | 51 | ), |
52 | 52 | ), |
53 | 53 | ), |
@@ -58,7 +58,7 @@ discard block |
||
58 | 58 | 'name' => 'stream', |
59 | 59 | 'priority' => 1000, |
60 | 60 | 'options' => array( |
61 | - 'stream' => __DIR__ .'/../../../log/mails.log', |
|
61 | + 'stream' => __DIR__.'/../../../log/mails.log', |
|
62 | 62 | ), |
63 | 63 | ), |
64 | 64 | ), |
@@ -75,7 +75,7 @@ discard block |
||
75 | 75 | 'mode' => true, // true = production|false = development|null = autodetect|IP address(es) csv/array |
76 | 76 | 'bar' => false, // bool = enabled|Toggle nette diagnostics bar. |
77 | 77 | 'strict' => true, // bool = cause immediate death|int = matched against error severity |
78 | - 'log' => __DIR__ . '/../../../log/tracy', // path to log directory (this directory keeps error.log, snoozing mailsent file & html exception trace files) |
|
78 | + 'log' => __DIR__.'/../../../log/tracy', // path to log directory (this directory keeps error.log, snoozing mailsent file & html exception trace files) |
|
79 | 79 | 'email' => null, // in production mode notifies the recipient |
80 | 80 | 'email_snooze' => 900 // interval for sending email in seconds |
81 | 81 | ], |
@@ -220,16 +220,16 @@ discard block |
||
220 | 220 | 'Core/JsonEntityHydrator' => 'Core\Entity\Hydrator\JsonEntityHydratorFactory', |
221 | 221 | 'Core/EntityHydrator' => 'Core\Entity\Hydrator\EntityHydratorFactory', |
222 | 222 | 'Core/Options' => 'Core\Factory\ModuleOptionsFactory', |
223 | - 'Core/DoctrineMongoODM/RepositoryEvents' => [\Core\Repository\DoctrineMongoODM\Event\RepositoryEventsSubscriber::class,'factory'], |
|
224 | - 'DefaultListeners' => ['Core\Listener\DefaultListener','factory'], |
|
225 | - 'templateProviderStrategy' => ['Core\Form\Hydrator\Strategy\TemplateProviderStrategy','factory'], |
|
226 | - 'Core/Listener/DeferredListenerAggregate' => [\Core\Listener\DeferredListenerAggregate::class,'factory'], |
|
223 | + 'Core/DoctrineMongoODM/RepositoryEvents' => [\Core\Repository\DoctrineMongoODM\Event\RepositoryEventsSubscriber::class, 'factory'], |
|
224 | + 'DefaultListeners' => ['Core\Listener\DefaultListener', 'factory'], |
|
225 | + 'templateProviderStrategy' => ['Core\Form\Hydrator\Strategy\TemplateProviderStrategy', 'factory'], |
|
226 | + 'Core/Listener/DeferredListenerAggregate' => [\Core\Listener\DeferredListenerAggregate::class, 'factory'], |
|
227 | 227 | 'Core/Listener/CreatePaginator' => 'Core\Listener\CreatePaginatorListener::factory', |
228 | 228 | 'Core/Locale' => 'Core\I18n\LocaleFactory', |
229 | 229 | \Core\Listener\AjaxRouteListener::class => \Core\Factory\Listener\AjaxRouteListenerFactory::class, |
230 | 230 | \Core\Listener\DeleteImageSetListener::class => \Core\Factory\Listener\DeleteImageSetListenerFactory::class, |
231 | 231 | 'Imagine' => \Core\Factory\Service\ImagineFactory::class, |
232 | - 'Core/Listener/Notification' => [\Core\Listener\NotificationListener::class,'factory'], |
|
232 | + 'Core/Listener/Notification' => [\Core\Listener\NotificationListener::class, 'factory'], |
|
233 | 233 | ), |
234 | 234 | 'abstract_factories' => array( |
235 | 235 | 'Core\Factory\OptionsAbstractFactory', |
@@ -252,7 +252,7 @@ discard block |
||
252 | 252 | 'translation_file_patterns' => array( |
253 | 253 | [ |
254 | 254 | 'type' => 'gettext', |
255 | - 'base_dir' => __DIR__ . '/../language', |
|
255 | + 'base_dir' => __DIR__.'/../language', |
|
256 | 256 | 'pattern' => '%s.mo', |
257 | 257 | ], |
258 | 258 | [ |
@@ -307,9 +307,9 @@ discard block |
||
307 | 307 | 'Core/SearchForm' => 'Core\Factory\Controller\Plugin\SearchFormFactory', |
308 | 308 | 'listquery' => 'Core\Controller\Plugin\ListQuery::factory', |
309 | 309 | 'mail' => 'Core\Controller\Plugin\Mail::factory', |
310 | - 'Core/Mailer' => ['Core\Controller\Plugin\Mailer','factory'], |
|
311 | - 'Core/CreatePaginator' => [\Core\Controller\Plugin\CreatePaginator::class,'factory'], |
|
312 | - 'Core/PaginatorService' => [\Core\Controller\Plugin\CreatePaginatorService::class,'factory'], |
|
310 | + 'Core/Mailer' => ['Core\Controller\Plugin\Mailer', 'factory'], |
|
311 | + 'Core/CreatePaginator' => [\Core\Controller\Plugin\CreatePaginator::class, 'factory'], |
|
312 | + 'Core/PaginatorService' => [\Core\Controller\Plugin\CreatePaginatorService::class, 'factory'], |
|
313 | 313 | ), |
314 | 314 | 'invokables' => array( |
315 | 315 | 'Core/FileSender' => 'Core\Controller\Plugin\FileSender', |
@@ -339,32 +339,32 @@ discard block |
||
339 | 339 | 'exception_template' => 'error/index', |
340 | 340 | // Map template to files. Speeds up the lookup through the template stack. |
341 | 341 | 'template_map' => array( |
342 | - 'noscript-notice' => __DIR__ . '/../view/layout/_noscript-notice.phtml', |
|
343 | - 'layout/layout' => __DIR__ . '/../view/layout/layout.phtml', |
|
344 | - 'error/404' => __DIR__ . '/../view/error/404.phtml', |
|
345 | - 'error/403' => __DIR__ . '/../view/error/403.phtml', |
|
346 | - 'error/index' => __DIR__ . '/../view/error/index.phtml', |
|
347 | - 'main-navigation' => __DIR__ . '/../view/partial/main-navigation.phtml', |
|
348 | - 'pagination-control' => __DIR__ . '/../view/partial/pagination-control.phtml', |
|
349 | - 'core/loading-popup' => __DIR__ . '/../view/partial/loading-popup.phtml', |
|
350 | - 'core/notifications' => __DIR__ . '/../view/partial/notifications.phtml', |
|
351 | - 'form/core/buttons' => __DIR__ . '/../view/form/buttons.phtml', |
|
352 | - 'core/social-buttons' => __DIR__ . '/../view/partial/social-buttons.phtml', |
|
353 | - 'form/core/privacy' => __DIR__ . '/../view/form/privacy.phtml', |
|
354 | - 'core/form/permissions-fieldset' => __DIR__ . '/../view/form/permissions-fieldset.phtml', |
|
355 | - 'core/form/permissions-collection' => __DIR__ . '/../view/form/permissions-collection.phtml', |
|
356 | - 'core/form/container-view' => __DIR__ . '/../view/form/container.view.phtml', |
|
357 | - 'core/form/tree-manage.view' => __DIR__ . '/../view/form/tree-manage.view.phtml', |
|
358 | - 'core/form/tree-manage.form' => __DIR__ . '/../view/form/tree-manage.form.phtml', |
|
359 | - 'core/form/tree-add-item' => __DIR__ . '/../view/form/tree-add-item.phtml', |
|
360 | - 'mail/header' => __DIR__ . '/../view/mail/header.phtml', |
|
361 | - 'mail/footer' => __DIR__ . '/../view/mail/footer.phtml', |
|
362 | - 'mail/footer.en' => __DIR__ . '/../view/mail/footer.en.phtml', |
|
342 | + 'noscript-notice' => __DIR__.'/../view/layout/_noscript-notice.phtml', |
|
343 | + 'layout/layout' => __DIR__.'/../view/layout/layout.phtml', |
|
344 | + 'error/404' => __DIR__.'/../view/error/404.phtml', |
|
345 | + 'error/403' => __DIR__.'/../view/error/403.phtml', |
|
346 | + 'error/index' => __DIR__.'/../view/error/index.phtml', |
|
347 | + 'main-navigation' => __DIR__.'/../view/partial/main-navigation.phtml', |
|
348 | + 'pagination-control' => __DIR__.'/../view/partial/pagination-control.phtml', |
|
349 | + 'core/loading-popup' => __DIR__.'/../view/partial/loading-popup.phtml', |
|
350 | + 'core/notifications' => __DIR__.'/../view/partial/notifications.phtml', |
|
351 | + 'form/core/buttons' => __DIR__.'/../view/form/buttons.phtml', |
|
352 | + 'core/social-buttons' => __DIR__.'/../view/partial/social-buttons.phtml', |
|
353 | + 'form/core/privacy' => __DIR__.'/../view/form/privacy.phtml', |
|
354 | + 'core/form/permissions-fieldset' => __DIR__.'/../view/form/permissions-fieldset.phtml', |
|
355 | + 'core/form/permissions-collection' => __DIR__.'/../view/form/permissions-collection.phtml', |
|
356 | + 'core/form/container-view' => __DIR__.'/../view/form/container.view.phtml', |
|
357 | + 'core/form/tree-manage.view' => __DIR__.'/../view/form/tree-manage.view.phtml', |
|
358 | + 'core/form/tree-manage.form' => __DIR__.'/../view/form/tree-manage.form.phtml', |
|
359 | + 'core/form/tree-add-item' => __DIR__.'/../view/form/tree-add-item.phtml', |
|
360 | + 'mail/header' => __DIR__.'/../view/mail/header.phtml', |
|
361 | + 'mail/footer' => __DIR__.'/../view/mail/footer.phtml', |
|
362 | + 'mail/footer.en' => __DIR__.'/../view/mail/footer.en.phtml', |
|
363 | 363 | //'startpage' => __DIR__ . '/../view/layout/startpage.phtml', |
364 | 364 | ), |
365 | 365 | // Where to look for view templates not mapped above |
366 | 366 | 'template_path_stack' => array( |
367 | - __DIR__ . '/../view', |
|
367 | + __DIR__.'/../view', |
|
368 | 368 | ), |
369 | 369 | ), |
370 | 370 | 'view_helpers' => array( |
@@ -41,7 +41,7 @@ |
||
41 | 41 | $response->setStatusCode(Response::STATUS_CODE_404); |
42 | 42 | return $response; |
43 | 43 | } |
44 | - $jsonModel=new JsonModel(); |
|
44 | + $jsonModel = new JsonModel(); |
|
45 | 45 | $jsonModel->setVariables($this->apiJobDehydrator->dehydrateList($jobs)); |
46 | 46 | $jsonModel->setJsonpCallback($callback); |
47 | 47 |