@@ -40,12 +40,12 @@ |
||
| 40 | 40 | |
| 41 | 41 | return $this->render( |
| 42 | 42 | 'backend/oconly81/index.html.twig', [ |
| 43 | - 'ocOnly81_user' => $userData, |
|
| 44 | - 'ocOnly81_matrix' => $matrixData[0], |
|
| 45 | - 'ocOnly81_dsum' => $matrixData[1], |
|
| 46 | - 'ocOnly81_tsum' => $matrixData[2], |
|
| 47 | - 'ocOnly81_overall_sum' => $matrixData[3] |
|
| 48 | - ] |
|
| 43 | + 'ocOnly81_user' => $userData, |
|
| 44 | + 'ocOnly81_matrix' => $matrixData[0], |
|
| 45 | + 'ocOnly81_dsum' => $matrixData[1], |
|
| 46 | + 'ocOnly81_tsum' => $matrixData[2], |
|
| 47 | + 'ocOnly81_overall_sum' => $matrixData[3] |
|
| 48 | + ] |
|
| 49 | 49 | ); |
| 50 | 50 | } |
| 51 | 51 | |
@@ -57,8 +57,8 @@ discard block |
||
| 57 | 57 | private function ocOnly81_get_matrixData() |
| 58 | 58 | : array |
| 59 | 59 | { |
| 60 | - for ($i = 0; $i <= 8; $i ++) { |
|
| 61 | - for ($j = 0; $j <= 8; $j ++) { |
|
| 60 | + for ($i = 0; $i <= 8; $i++) { |
|
| 61 | + for ($j = 0; $j <= 8; $j++) { |
|
| 62 | 62 | $matrix[$i][$j] = 0; |
| 63 | 63 | $dsum[$i] = 0; |
| 64 | 64 | $tsum[$i] = 0; |
@@ -75,10 +75,10 @@ discard block |
||
| 75 | 75 | $data = $qb->execute()->fetchAll(); |
| 76 | 76 | |
| 77 | 77 | foreach ($data as $item) { |
| 78 | - $matrix[$item['difficulty'] - 2][$item['terrain'] - 2] ++; |
|
| 78 | + $matrix[$item['difficulty'] - 2][$item['terrain'] - 2]++; |
|
| 79 | 79 | } |
| 80 | 80 | |
| 81 | - for ($i = 0; $i <= 8; $i ++) { |
|
| 81 | + for ($i = 0; $i <= 8; $i++) { |
|
| 82 | 82 | $dsum[$i] = $dsum[$i] + array_sum($matrix[$i]); |
| 83 | 83 | $tsum[$i] = $tsum[$i] + array_sum(array_column($matrix, $i)); |
| 84 | 84 | } |
@@ -118,7 +118,7 @@ discard block |
||
| 118 | 118 | 'count' => 1 |
| 119 | 119 | ]; |
| 120 | 120 | } else { |
| 121 | - $result[$item['user_id']]['count'] ++; |
|
| 121 | + $result[$item['user_id']]['count']++; |
|
| 122 | 122 | } |
| 123 | 123 | } |
| 124 | 124 | |
@@ -76,11 +76,11 @@ |
||
| 76 | 76 | |
| 77 | 77 | return $this->render( |
| 78 | 78 | 'backend/maps/index.html.twig', [ |
| 79 | - 'mapCenterViewLat' => $mapCenterViewLat, |
|
| 80 | - 'mapCenterViewLon' => $mapCenterViewLon, |
|
| 81 | - 'mapZoom' => '6', |
|
| 82 | - 'mapWP' => $mapWP |
|
| 83 | - ] |
|
| 79 | + 'mapCenterViewLat' => $mapCenterViewLat, |
|
| 80 | + 'mapCenterViewLon' => $mapCenterViewLon, |
|
| 81 | + 'mapZoom' => '6', |
|
| 82 | + 'mapWP' => $mapWP |
|
| 83 | + ] |
|
| 84 | 84 | ); |
| 85 | 85 | } |
| 86 | 86 | } |
@@ -144,7 +144,7 @@ discard block |
||
| 144 | 144 | $databaseArray |
| 145 | 145 | ); |
| 146 | 146 | |
| 147 | - $entity->id = (int) $this->connection->lastInsertId(); |
|
| 147 | + $entity->id = (int)$this->connection->lastInsertId(); |
|
| 148 | 148 | |
| 149 | 149 | return $entity; |
| 150 | 150 | } |
@@ -219,9 +219,9 @@ discard block |
||
| 219 | 219 | public function getEntityFromDatabaseArray(array $data) : UserRolesEntity |
| 220 | 220 | { |
| 221 | 221 | $entity = new UserRolesEntity(); |
| 222 | - $entity->id = (int) $data['id']; |
|
| 223 | - $entity->userId = (string) $data['user_id']; |
|
| 224 | - $entity->roleId = (string) $data['role_id']; |
|
| 222 | + $entity->id = (int)$data['id']; |
|
| 223 | + $entity->userId = (string)$data['user_id']; |
|
| 224 | + $entity->roleId = (string)$data['role_id']; |
|
| 225 | 225 | |
| 226 | 226 | return $entity; |
| 227 | 227 | } |
@@ -146,10 +146,10 @@ discard block |
||
| 146 | 146 | |
| 147 | 147 | return $this->render( |
| 148 | 148 | 'backend/roles/team.assignment.html.twig', [ |
| 149 | - 'rolesUserSearchForm' => $form->createView(), |
|
| 150 | - 'user_account_details' => $fetchedUser, |
|
| 151 | - 'roleNames' => $roleNames |
|
| 152 | - ] |
|
| 149 | + 'rolesUserSearchForm' => $form->createView(), |
|
| 150 | + 'user_account_details' => $fetchedUser, |
|
| 151 | + 'roleNames' => $roleNames |
|
| 152 | + ] |
|
| 153 | 153 | ); |
| 154 | 154 | } |
| 155 | 155 | |
@@ -177,10 +177,10 @@ discard block |
||
| 177 | 177 | |
| 178 | 178 | return $this->render( |
| 179 | 179 | 'backend/roles/team.assignment.html.twig', [ |
| 180 | - 'rolesUserSearchForm' => $form->createView(), |
|
| 181 | - 'user_account_details' => $fetchedUser, |
|
| 182 | - 'roleNames' => $roleNames |
|
| 183 | - ] |
|
| 180 | + 'rolesUserSearchForm' => $form->createView(), |
|
| 181 | + 'user_account_details' => $fetchedUser, |
|
| 182 | + 'roleNames' => $roleNames |
|
| 183 | + ] |
|
| 184 | 184 | ); |
| 185 | 185 | } |
| 186 | 186 | |
@@ -209,10 +209,10 @@ discard block |
||
| 209 | 209 | |
| 210 | 210 | return $this->render( |
| 211 | 211 | 'backend/roles/team.assignment.html.twig', [ |
| 212 | - 'rolesUserSearchForm' => $form->createView(), |
|
| 213 | - 'user_account_details' => $fetchedUser, |
|
| 214 | - 'roleNames' => $roleNames |
|
| 215 | - ] |
|
| 212 | + 'rolesUserSearchForm' => $form->createView(), |
|
| 213 | + 'user_account_details' => $fetchedUser, |
|
| 214 | + 'roleNames' => $roleNames |
|
| 215 | + ] |
|
| 216 | 216 | ); |
| 217 | 217 | } |
| 218 | 218 | |
@@ -172,7 +172,7 @@ discard block |
||
| 172 | 172 | $databaseArray |
| 173 | 173 | ); |
| 174 | 174 | |
| 175 | - $entity->id = (int) $this->connection->lastInsertId(); |
|
| 175 | + $entity->id = (int)$this->connection->lastInsertId(); |
|
| 176 | 176 | |
| 177 | 177 | return $entity; |
| 178 | 178 | } |
@@ -268,8 +268,8 @@ discard block |
||
| 268 | 268 | public function getEntityFromDatabaseArray(array $data) |
| 269 | 269 | : SecurityRolesEntity { |
| 270 | 270 | $entity = new SecurityRolesEntity(); |
| 271 | - $entity->id = (int) $data['id']; |
|
| 272 | - $entity->role = (string) $data['role']; |
|
| 271 | + $entity->id = (int)$data['id']; |
|
| 272 | + $entity->role = (string)$data['role']; |
|
| 273 | 273 | |
| 274 | 274 | return $entity; |
| 275 | 275 | } |
@@ -20,21 +20,21 @@ |
||
| 20 | 20 | $builder |
| 21 | 21 | ->add( |
| 22 | 22 | 'content_user_searchfield', null, [ |
| 23 | - 'attr' => [ |
|
| 24 | - 'placeholder' => 'User-Id', |
|
| 25 | - 'autofocus' => 'autofocus', |
|
| 26 | - 'size' => '10%', |
|
| 27 | - 'minlength' => '6', |
|
| 28 | - 'maxlength' => '7', |
|
| 29 | - 'style' => 'width: 250px;', |
|
| 30 | - 'pattern' => '^[0-9]{6,7}', |
|
| 31 | - 'title' => 'Only 6-7 numerics are allowed.', |
|
| 32 | - ], |
|
| 33 | - 'required' => true, |
|
| 34 | - 'disabled' => false, |
|
| 35 | - 'label' => false, |
|
| 36 | - 'trim' => true |
|
| 37 | - ] |
|
| 23 | + 'attr' => [ |
|
| 24 | + 'placeholder' => 'User-Id', |
|
| 25 | + 'autofocus' => 'autofocus', |
|
| 26 | + 'size' => '10%', |
|
| 27 | + 'minlength' => '6', |
|
| 28 | + 'maxlength' => '7', |
|
| 29 | + 'style' => 'width: 250px;', |
|
| 30 | + 'pattern' => '^[0-9]{6,7}', |
|
| 31 | + 'title' => 'Only 6-7 numerics are allowed.', |
|
| 32 | + ], |
|
| 33 | + 'required' => true, |
|
| 34 | + 'disabled' => false, |
|
| 35 | + 'label' => false, |
|
| 36 | + 'trim' => true |
|
| 37 | + ] |
|
| 38 | 38 | ) |
| 39 | 39 | ->add( |
| 40 | 40 | 'search_One', SubmitType::class, [ |
@@ -55,9 +55,9 @@ |
||
| 55 | 55 | } |
| 56 | 56 | |
| 57 | 57 | return $this->render('backend/user/index.html.twig', [ |
| 58 | - 'userSearchForm' => $searchForm->createView(), |
|
| 59 | - 'all_users_by_searchfield' => $fetchedUsers |
|
| 60 | - ] |
|
| 58 | + 'userSearchForm' => $searchForm->createView(), |
|
| 59 | + 'all_users_by_searchfield' => $fetchedUsers |
|
| 60 | + ] |
|
| 61 | 61 | ); |
| 62 | 62 | } |
| 63 | 63 | |
@@ -153,7 +153,7 @@ discard block |
||
| 153 | 153 | $databaseArray |
| 154 | 154 | ); |
| 155 | 155 | |
| 156 | - $entity->userId = (int) $this->connection->lastInsertId(); |
|
| 156 | + $entity->userId = (int)$this->connection->lastInsertId(); |
|
| 157 | 157 | |
| 158 | 158 | return $entity; |
| 159 | 159 | } |
@@ -181,7 +181,7 @@ discard block |
||
| 181 | 181 | ['user_id' => $entity->userId] |
| 182 | 182 | ); |
| 183 | 183 | |
| 184 | - $entity->userId = (int) $this->connection->lastInsertId(); |
|
| 184 | + $entity->userId = (int)$this->connection->lastInsertId(); |
|
| 185 | 185 | |
| 186 | 186 | return $entity; |
| 187 | 187 | } |
@@ -261,16 +261,16 @@ discard block |
||
| 261 | 261 | public function getEntityFromDatabaseArray(array $data) |
| 262 | 262 | : UserEntity { |
| 263 | 263 | $entity = new UserEntity(); |
| 264 | - $entity->userId = (int) $data['user_id']; |
|
| 265 | - $entity->dateCreated = (string) $data['date_created']; |
|
| 266 | - $entity->lastModified = (string) $data['last_modified']; |
|
| 264 | + $entity->userId = (int)$data['user_id']; |
|
| 265 | + $entity->dateCreated = (string)$data['date_created']; |
|
| 266 | + $entity->lastModified = (string)$data['last_modified']; |
|
| 267 | 267 | $entity->username = $data['username']; |
| 268 | 268 | $entity->password = $data['password']; |
| 269 | 269 | $entity->email = $data['email']; |
| 270 | - $entity->emailProblems = (bool) $data['email_problems']; |
|
| 271 | - $entity->latitude = (double) $data['latitude']; |
|
| 272 | - $entity->longitude = (double) $data['longitude']; |
|
| 273 | - $entity->isActive = (bool) $data['is_active_flag']; |
|
| 270 | + $entity->emailProblems = (bool)$data['email_problems']; |
|
| 271 | + $entity->latitude = (double)$data['latitude']; |
|
| 272 | + $entity->longitude = (double)$data['longitude']; |
|
| 273 | + $entity->isActive = (bool)$data['is_active_flag']; |
|
| 274 | 274 | $entity->firstname = $data['first_name']; |
| 275 | 275 | $entity->lastname = $data['last_name']; |
| 276 | 276 | $entity->country = $data['country']; |
@@ -22,29 +22,29 @@ |
||
| 22 | 22 | $builder |
| 23 | 23 | ->add( |
| 24 | 24 | 'email', EmailType::Class, [ |
| 25 | - 'attr' => [ |
|
| 26 | - 'autofocus' => 'autofocus', |
|
| 27 | - 'size' => '10%', |
|
| 28 | - 'style' => 'width: 250px;' |
|
| 29 | - ], |
|
| 30 | - 'required' => true, |
|
| 31 | - 'disabled' => false, |
|
| 32 | - 'label' => false, |
|
| 33 | - 'trim' => true |
|
| 34 | - ] |
|
| 25 | + 'attr' => [ |
|
| 26 | + 'autofocus' => 'autofocus', |
|
| 27 | + 'size' => '10%', |
|
| 28 | + 'style' => 'width: 250px;' |
|
| 29 | + ], |
|
| 30 | + 'required' => true, |
|
| 31 | + 'disabled' => false, |
|
| 32 | + 'label' => false, |
|
| 33 | + 'trim' => true |
|
| 34 | + ] |
|
| 35 | 35 | ) |
| 36 | 36 | ->add( |
| 37 | 37 | 'activationCode', null, [ |
| 38 | - 'attr' => [ |
|
| 39 | - 'size' => '10%', |
|
| 40 | - 'pattern' => '[A-F0-9]{13}', |
|
| 41 | - 'style' => 'width: 250px;' |
|
| 42 | - ], |
|
| 43 | - 'required' => true, |
|
| 44 | - 'disabled' => false, |
|
| 45 | - 'label' => false, |
|
| 46 | - 'trim' => true |
|
| 47 | - ] |
|
| 38 | + 'attr' => [ |
|
| 39 | + 'size' => '10%', |
|
| 40 | + 'pattern' => '[A-F0-9]{13}', |
|
| 41 | + 'style' => 'width: 250px;' |
|
| 42 | + ], |
|
| 43 | + 'required' => true, |
|
| 44 | + 'disabled' => false, |
|
| 45 | + 'label' => false, |
|
| 46 | + 'trim' => true |
|
| 47 | + ] |
|
| 48 | 48 | ) |
| 49 | 49 | ->add( |
| 50 | 50 | 'submit', SubmitType::class, [ |