@@ -28,11 +28,11 @@ |
||
28 | 28 | { |
29 | 29 | $request = $event->getRequest(); |
30 | 30 | $uri = $request->getPathInfo(); |
31 | - if(!preg_match('!'.$this->indicator.'!', $uri)) { |
|
31 | + if (!preg_match('!'.$this->indicator.'!', $uri)) { |
|
32 | 32 | return; |
33 | 33 | } |
34 | 34 | |
35 | - if(false == ($user = $this->getUser())){ |
|
35 | + if (false == ($user = $this->getUser())) { |
|
36 | 36 | return; |
37 | 37 | } |
38 | 38 |
@@ -17,7 +17,7 @@ |
||
17 | 17 | public function onListTasks(TaskListEvent $event) |
18 | 18 | { |
19 | 19 | |
20 | - foreach($this->getTasks() as $task) { |
|
20 | + foreach ($this->getTasks() as $task) { |
|
21 | 21 | $event->addTask($task); |
22 | 22 | } |
23 | 23 |
@@ -16,15 +16,15 @@ |
||
16 | 16 | |
17 | 17 | public function onListMessages(MessageListEvent $event) { |
18 | 18 | |
19 | - foreach($this->getMessages() as $msg) { |
|
19 | + foreach ($this->getMessages() as $msg) { |
|
20 | 20 | $event->addMessage($msg); |
21 | 21 | } |
22 | 22 | } |
23 | 23 | |
24 | 24 | protected function getMessages() { |
25 | 25 | return array( |
26 | - new MessageModel(new UserModel('Karl kettenkit'),'Dude! do something!', new \DateTime('-3 days')), |
|
27 | - new MessageModel(new UserModel('Jack Trockendoc'),'This is some subject', new \DateTime('-10 month')), |
|
26 | + new MessageModel(new UserModel('Karl kettenkit'), 'Dude! do something!', new \DateTime('-3 days')), |
|
27 | + new MessageModel(new UserModel('Jack Trockendoc'), 'This is some subject', new \DateTime('-10 month')), |
|
28 | 28 | ); |
29 | 29 | } |
30 | 30 |
@@ -16,7 +16,7 @@ |
||
16 | 16 | |
17 | 17 | public function onListNotifications(NotificationListEvent $event) { |
18 | 18 | |
19 | - foreach($this->getNotifications() as $notify){ |
|
19 | + foreach ($this->getNotifications() as $notify) { |
|
20 | 20 | $event->addNotification($notify); |
21 | 21 | } |
22 | 22 |
@@ -45,12 +45,12 @@ |
||
45 | 45 | |
46 | 46 | protected function activateByRoute($route, $items) { |
47 | 47 | |
48 | - foreach($items as $item) { /** @var $item MenuItemModel */ |
|
49 | - if($item->hasChildren()) { |
|
48 | + foreach ($items as $item) { /** @var $item MenuItemModel */ |
|
49 | + if ($item->hasChildren()) { |
|
50 | 50 | $this->activateByRoute($route, $item->getChildren()); |
51 | 51 | } |
52 | 52 | else { |
53 | - if($item->getRoute() == $route) { |
|
53 | + if ($item->getRoute() == $route) { |
|
54 | 54 | $item->setIsActive(true); |
55 | 55 | } |
56 | 56 | } |
@@ -22,7 +22,7 @@ |
||
22 | 22 | { |
23 | 23 | $loader = new Loader\YamlFileLoader( |
24 | 24 | $container, |
25 | - new FileLocator(__DIR__ . '/../Resources/config') |
|
25 | + new FileLocator(__DIR__.'/../Resources/config') |
|
26 | 26 | ); |
27 | 27 | |
28 | 28 | $loader->load('services.yml'); |
@@ -222,14 +222,14 @@ |
||
222 | 222 | return \Display::return_icon('badges-default.png', null, null, ICON_SIZE_BIG, null, true); |
223 | 223 | } |
224 | 224 | |
225 | - return api_get_path(WEB_UPLOAD_PATH) . 'badges/' . sha1($this->name) . '-small.png'; |
|
225 | + return api_get_path(WEB_UPLOAD_PATH).'badges/'.sha1($this->name).'-small.png'; |
|
226 | 226 | } |
227 | 227 | |
228 | 228 | if (empty($this->icon)) { |
229 | 229 | return \Display::return_icon('badges-default.png', null, null, ICON_SIZE_HUGE, null, true); |
230 | 230 | } |
231 | 231 | |
232 | - return api_get_path(WEB_UPLOAD_PATH) . "badges/{$this->icon}"; |
|
232 | + return api_get_path(WEB_UPLOAD_PATH)."badges/{$this->icon}"; |
|
233 | 233 | } |
234 | 234 | |
235 | 235 | /** |
@@ -215,8 +215,8 @@ discard block |
||
215 | 215 | // We are sure that the extra field exists. |
216 | 216 | foreach ($extra_fields as $extras) { |
217 | 217 | if (isset($user[$extras[1]])) { |
218 | - $key = $extras[1]; |
|
219 | - $value = $user[$extras[1]]; |
|
218 | + $key = $extras[1]; |
|
219 | + $value = $user[$extras[1]]; |
|
220 | 220 | UserManager::update_extra_field_value($user_id, $key, $value); |
221 | 221 | } |
222 | 222 | } |
@@ -253,7 +253,7 @@ discard block |
||
253 | 253 | global $current_tag; |
254 | 254 | switch ($data) { |
255 | 255 | case 'Contact': |
256 | - $user = array (); |
|
256 | + $user = array(); |
|
257 | 257 | break; |
258 | 258 | default: |
259 | 259 | $current_tag = $data; |
@@ -350,7 +350,7 @@ discard block |
||
350 | 350 | |
351 | 351 | if (in_array($ext_import_file, $allowed_file_mimetype)) { |
352 | 352 | if (strcmp($file_type, 'csv') === 0 && $ext_import_file == $allowed_file_mimetype[0]) { |
353 | - $users = parse_csv_data($_FILES['import_file']['tmp_name']); |
|
353 | + $users = parse_csv_data($_FILES['import_file']['tmp_name']); |
|
354 | 354 | $errors = validate_data($users); |
355 | 355 | $error_kind_file = false; |
356 | 356 | } elseif (strcmp($file_type, 'xml') === 0 && $ext_import_file == $allowed_file_mimetype[1]) { |
@@ -12,7 +12,7 @@ |
||
12 | 12 | $isDRH = api_is_drh(); |
13 | 13 | |
14 | 14 | if (!$isStudent && !$isStudentBoss && !$isDRH) { |
15 | - header('Location: ' . api_get_path(WEB_CODE_PATH) . 'social/skills_wheel.php'); |
|
15 | + header('Location: '.api_get_path(WEB_CODE_PATH).'social/skills_wheel.php'); |
|
16 | 16 | exit; |
17 | 17 | } |
18 | 18 |