@@ -148,9 +148,13 @@ |
||
148 | 148 | <td><?=$userEvent['username']; ?></td> |
149 | 149 | <td> |
150 | 150 | <?php |
151 | - if ($userEvent['action_type'] == "Change Password") echo('Password Changed'); |
|
152 | - else if ($userEvent['action_type'] == "Ask New Password") echo('Asked New Password'); |
|
153 | - else if ($userEvent['action_type'] == "Account Blocked") echo('Account Blocked'); |
|
151 | + if ($userEvent['action_type'] == "Change Password") { |
|
152 | + echo('Password Changed'); |
|
153 | + } else if ($userEvent['action_type'] == "Ask New Password") { |
|
154 | + echo('Asked New Password'); |
|
155 | + } else if ($userEvent['action_type'] == "Account Blocked") { |
|
156 | + echo('Account Blocked'); |
|
157 | + } |
|
154 | 158 | ?> |
155 | 159 | </td> |
156 | 160 | </tr> |
@@ -95,11 +95,11 @@ discard block |
||
95 | 95 | User::UNCONFIRMED, |
96 | 96 | User::DEACTIVATED |
97 | 97 | ); |
98 | - }else if ($userObject->userStatus == User::UNCONFIRMED) { |
|
98 | + } else if ($userObject->userStatus == User::UNCONFIRMED) { |
|
99 | 99 | $possibleStatus=array( |
100 | 100 | User::DEACTIVATED |
101 | 101 | ); |
102 | - }else if ($userObject->userStatus == User::DEACTIVATED) { |
|
102 | + } else if ($userObject->userStatus == User::DEACTIVATED) { |
|
103 | 103 | $possibleStatus=array( |
104 | 104 | User::UNCONFIRMED |
105 | 105 | ); |
@@ -109,7 +109,7 @@ discard block |
||
109 | 109 | foreach ($possibleStatus as $status) { |
110 | 110 | if ($status == "Unconfirmed") { |
111 | 111 | echo '<option value="'.$status.'">Password Reset</option>'; |
112 | - }else { |
|
112 | + } else { |
|
113 | 113 | echo '<option value="'.$status.'">'.$status.'</option>'; |
114 | 114 | } |
115 | 115 | } |
@@ -206,7 +206,8 @@ discard block |
||
206 | 206 | <label class="col-form-label">Administrator :</label> <input |
207 | 207 | class="form-group col" type="checkbox" name="administrator" |
208 | 208 | value="1" id="administrator" |
209 | - <?php if ($userObject->isAdministrator == 1) echo("checked")?>> |
|
209 | + <?php if ($userObject->isAdministrator == 1) { |
|
210 | + echo("checked")?>> |
|
210 | 211 | </div> |
211 | 212 | |
212 | 213 | <div class="form-group row"> |
@@ -216,7 +217,8 @@ discard block |
||
216 | 217 | <SELECT class="custom-select" name="job"> |
217 | 218 | <?php |
218 | 219 | // Current job appear first in selector |
219 | - echo '<option value="'.$userObject->userJob.'">'.$userObject->userJob.'</option>'; |
|
220 | + echo '<option value="'.$userObject->userJob.'">'.$userObject->userJob.'</option>'; |
|
221 | +} |
|
220 | 222 | // add other possible job |
221 | 223 | foreach ($jobs as $job) { |
222 | 224 | if ($job != $userObject->userJob) { |
@@ -43,23 +43,23 @@ discard block |
||
43 | 43 | //Check that reported old password is correct, if unconfirmed we use the temp password value |
44 | 44 | if ($userObject->userStatus == User::UNCONFIRMED) { |
45 | 45 | $checkCurrentPassword=password_verify($old_password, $currentTempPassword); |
46 | - }else { |
|
46 | + } else { |
|
47 | 47 | $checkCurrentPassword=password_verify($old_password, $currentPassword); |
48 | 48 | } |
49 | 49 | |
50 | 50 | if ($mdp1 != $mdp2) { |
51 | 51 | $answer['result']="DifferentPassword"; |
52 | 52 | |
53 | - }else if (!$checkCurrentPassword) { |
|
53 | + } else if (!$checkCurrentPassword) { |
|
54 | 54 | $answer['result']="WrongOldPassword"; |
55 | 55 | |
56 | - }else if (strlen($mdp1) < 8 || preg_match('/[^a-z0-9]/i', $mdp1) || strtolower($mdp1) == $mdp1) { |
|
56 | + } else if (strlen($mdp1) < 8 || preg_match('/[^a-z0-9]/i', $mdp1) || strtolower($mdp1) == $mdp1) { |
|
57 | 57 | $answer['result']="IncorrectFormat"; |
58 | 58 | |
59 | - }else if (password_verify($mdp1, $currentTempPassword) || password_verify($mdp1, $currentPassword) || password_verify($mdp1, $twoPreviousPassword[0]) || password_verify($mdp1, $twoPreviousPassword[1])) { |
|
59 | + } else if (password_verify($mdp1, $currentTempPassword) || password_verify($mdp1, $currentPassword) || password_verify($mdp1, $twoPreviousPassword[0]) || password_verify($mdp1, $twoPreviousPassword[1])) { |
|
60 | 60 | $answer['result']="SamePrevious"; |
61 | 61 | |
62 | - }else if ($mdp1 == $mdp2 && strtolower($mdp1) != $mdp1 && $checkCurrentPassword && !password_verify($mdp1, $currentTempPassword) && !password_verify($mdp1, $twoPreviousPassword[0]) && !password_verify($mdp1, $twoPreviousPassword[1]) && !password_verify($mdp1, $currentPassword)) { |
|
62 | + } else if ($mdp1 == $mdp2 && strtolower($mdp1) != $mdp1 && $checkCurrentPassword && !password_verify($mdp1, $currentTempPassword) && !password_verify($mdp1, $twoPreviousPassword[0]) && !password_verify($mdp1, $twoPreviousPassword[1]) && !password_verify($mdp1, $currentPassword)) { |
|
63 | 63 | $answer['result']="OK"; |
64 | 64 | //Update the database with new password |
65 | 65 | $userObject->updateUserPassword($mdp1, User::ACTIVATED); |
@@ -70,12 +70,12 @@ discard block |
||
70 | 70 | |
71 | 71 | echo(json_encode($answer)); |
72 | 72 | |
73 | - }else { |
|
73 | + } else { |
|
74 | 74 | |
75 | 75 | require 'views/change_password_view.php'; |
76 | 76 | |
77 | 77 | } |
78 | 78 | |
79 | -}else { |
|
79 | +} else { |
|
80 | 80 | require 'includes/no_access.php'; |
81 | 81 | } |
@@ -25,6 +25,6 @@ |
||
25 | 25 | |
26 | 26 | require 'views/my_account_view.php'; |
27 | 27 | |
28 | -}else { |
|
28 | +} else { |
|
29 | 29 | require 'includes/no_access.php'; |
30 | 30 | } |
31 | 31 | \ No newline at end of file |
@@ -63,14 +63,14 @@ |
||
63 | 63 | header('Location: /index.php'); |
64 | 64 | exit; |
65 | 65 | //if error when moving file. |
66 | - }else { |
|
66 | + } else { |
|
67 | 67 | echo 'Failed ! Err'.$_FILES['documentationfile']["error"]; |
68 | 68 | } |
69 | - }else { |
|
69 | + } else { |
|
70 | 70 | echo $erreur; |
71 | 71 | } |
72 | 72 | |
73 | -}else { |
|
73 | +} else { |
|
74 | 74 | require 'includes/no_access.php'; |
75 | 75 | } |
76 | 76 |
@@ -32,6 +32,6 @@ |
||
32 | 32 | $usersInStudy=$studyObject->getAllRolesByUsers(); |
33 | 33 | |
34 | 34 | require 'views/supervisor/download_manager_view.php'; |
35 | -}else { |
|
35 | +} else { |
|
36 | 36 | require 'includes/no_access.php'; |
37 | 37 | } |
@@ -50,18 +50,18 @@ |
||
50 | 50 | echo($htmlReport); |
51 | 51 | echo("Report Sent by Email"); |
52 | 52 | |
53 | - }else { |
|
53 | + } else { |
|
54 | 54 | |
55 | 55 | if (GAELO_DATE_FORMAT == 'd.m.Y') { |
56 | 56 | $importFormat="DD/MM/YYYY"; |
57 | 57 | |
58 | - }else if (GAELO_DATE_FORMAT == 'm.d.Y') { |
|
58 | + } else if (GAELO_DATE_FORMAT == 'm.d.Y') { |
|
59 | 59 | $importFormat="MM/DD/YYYY"; |
60 | 60 | } |
61 | 61 | |
62 | 62 | require 'views/supervisor/import_patients_view.php'; |
63 | 63 | } |
64 | 64 | |
65 | -}else { |
|
65 | +} else { |
|
66 | 66 | require 'includes/no_access.php'; |
67 | 67 | } |
@@ -29,14 +29,14 @@ |
||
29 | 29 | $trackerData=Tracker::getTrackerByRoleStudy($askedRole, $linkpdo, $_SESSION['study']); |
30 | 30 | require 'views/supervisor/tracker/tracker_script.php'; |
31 | 31 | require 'views/supervisor/tracker/tracker_'.(strtolower($askedRole)).'.php'; |
32 | - }else if ($askedRole == "Message") { |
|
32 | + } else if ($askedRole == "Message") { |
|
33 | 33 | $trackerMessages=Tracker::getMessageStudy($_SESSION['study'], $linkpdo); |
34 | 34 | require 'views/supervisor/tracker/tracker_script.php'; |
35 | 35 | require 'views/supervisor/tracker/tracker_message.php'; |
36 | - }else { |
|
36 | + } else { |
|
37 | 37 | require 'includes/no_access.php'; |
38 | 38 | } |
39 | 39 | |
40 | -}else { |
|
40 | +} else { |
|
41 | 41 | require 'includes/no_access.php'; |
42 | 42 | } |
43 | 43 | \ No newline at end of file |
@@ -31,7 +31,7 @@ discard block |
||
31 | 31 | |
32 | 32 | require 'views/supervisor/supervisor_root_view.php'; |
33 | 33 | |
34 | -}else { |
|
34 | +} else { |
|
35 | 35 | require 'includes/no_access.php'; |
36 | 36 | } |
37 | 37 | |
@@ -52,7 +52,7 @@ discard block |
||
52 | 52 | $jsonObject['code']="<a onclick='linkPatientInfos(".$patientObject->patientCode.")' href='javascript:void(0);'>".$patientObject->patientCode."</a>"; |
53 | 53 | if (!$patientObject->patientWithdraw) { |
54 | 54 | $jsonObject['withdraw']="Included"; |
55 | - }else { |
|
55 | + } else { |
|
56 | 56 | $jsonObject['withdraw']="Withdrawn"; |
57 | 57 | } |
58 | 58 | $jsonObject['visit_modality']=$visitObject->visitGroupObject->groupModality; |