@@ -240,7 +240,7 @@ |
||
| 240 | 240 | $loginLink .= "?response_type=" . URL_RESPONSE_TYPES; |
| 241 | 241 | if (strpos($url, 'admin') !== false) { |
| 242 | 242 | $loginLink .= "&redirect_uri=" . urlencode(REDIRECT_URI_ADMIN); |
| 243 | - } else { |
|
| 243 | + }else { |
|
| 244 | 244 | $loginLink .= "&redirect_uri=" . urlencode(REDIRECT_URI); |
| 245 | 245 | } |
| 246 | 246 | $loginLink .= "&nonce=" . $nonce; |
@@ -35,7 +35,7 @@ discard block |
||
| 35 | 35 | $result = MicroReferenceController::getAllMicroReferencesForJobApplication($jobPosterApplicationId, $locale); |
| 36 | 36 | $json = json_encode($result, JSON_PRETTY_PRINT); |
| 37 | 37 | echo($json); |
| 38 | - } else { |
|
| 38 | + }else { |
|
| 39 | 39 | $result = array(); |
| 40 | 40 | $json = json_encode($result, JSON_PRETTY_PRINT); |
| 41 | 41 | echo($json); |
@@ -59,12 +59,12 @@ discard block |
||
| 59 | 59 | |
| 60 | 60 | $json = json_encode($result, JSON_PRETTY_PRINT); |
| 61 | 61 | echo($json); |
| 62 | - } else { |
|
| 62 | + }else { |
|
| 63 | 63 | header('HTTP/1.0 403 Forbidden'); |
| 64 | 64 | echo json_encode(array("failed" => "Only Draft applications can be modified."), JSON_FORCE_OBJECT); |
| 65 | 65 | exit; |
| 66 | 66 | } |
| 67 | - } else { |
|
| 67 | + }else { |
|
| 68 | 68 | $result = array(); |
| 69 | 69 | $json = json_encode($result, JSON_PRETTY_PRINT); |
| 70 | 70 | echo($json); |
@@ -97,12 +97,12 @@ discard block |
||
| 97 | 97 | |
| 98 | 98 | $json = json_encode($result, JSON_PRETTY_PRINT); |
| 99 | 99 | echo($json); |
| 100 | - } else { |
|
| 100 | + }else { |
|
| 101 | 101 | header('HTTP/1.0 403 Forbidden'); |
| 102 | 102 | echo json_encode(array("failed" => "Only Draft applications can be modified."), JSON_FORCE_OBJECT); |
| 103 | 103 | exit; |
| 104 | 104 | } |
| 105 | - } else { |
|
| 105 | + }else { |
|
| 106 | 106 | $result = array(); |
| 107 | 107 | $json = json_encode($result, JSON_PRETTY_PRINT); |
| 108 | 108 | echo($json); |
@@ -35,7 +35,7 @@ discard block |
||
| 35 | 35 | $result = WorkSampleController::getAllWorkSamplesForJobApplication($jobPosterApplicationId, $locale); |
| 36 | 36 | $json = json_encode($result, JSON_PRETTY_PRINT); |
| 37 | 37 | echo($json); |
| 38 | - } else { |
|
| 38 | + }else { |
|
| 39 | 39 | $result = array(); |
| 40 | 40 | $json = json_encode($result, JSON_PRETTY_PRINT); |
| 41 | 41 | echo($json); |
@@ -59,12 +59,12 @@ discard block |
||
| 59 | 59 | |
| 60 | 60 | $json = json_encode($result, JSON_PRETTY_PRINT); |
| 61 | 61 | echo($json); |
| 62 | - } else { |
|
| 62 | + }else { |
|
| 63 | 63 | header('HTTP/1.0 403 Forbidden'); |
| 64 | 64 | echo json_encode(array("failed" => "Only Draft applications can be modified."), JSON_FORCE_OBJECT); |
| 65 | 65 | exit; |
| 66 | 66 | } |
| 67 | - } else { |
|
| 67 | + }else { |
|
| 68 | 68 | $result = array(); |
| 69 | 69 | $json = json_encode($result, JSON_PRETTY_PRINT); |
| 70 | 70 | echo($json); |
@@ -95,12 +95,12 @@ discard block |
||
| 95 | 95 | |
| 96 | 96 | $json = json_encode($result, JSON_PRETTY_PRINT); |
| 97 | 97 | echo($json); |
| 98 | - } else { |
|
| 98 | + }else { |
|
| 99 | 99 | header('HTTP/1.0 403 Forbidden'); |
| 100 | 100 | echo json_encode(array("failed" => "Only Draft applications can be modified."), JSON_FORCE_OBJECT); |
| 101 | 101 | exit; |
| 102 | 102 | } |
| 103 | - } else { |
|
| 103 | + }else { |
|
| 104 | 104 | $result = array(); |
| 105 | 105 | $json = json_encode($result, JSON_PRETTY_PRINT); |
| 106 | 106 | echo($json); |
@@ -16,7 +16,7 @@ |
||
| 16 | 16 | $previousEntry = TeamCultureDAO::getTeamCultureNonLocalizedForManagerProfile($managerProfileId); |
| 17 | 17 | if ($previousEntry) { |
| 18 | 18 | $result = TeamCultureDAO::updateTeamCultureForManagerProfile($teamCulture, $managerProfileId); |
| 19 | - } else { |
|
| 19 | + }else { |
|
| 20 | 20 | $result = TeamCultureDAO::createTeamCultureForManagerProfile($teamCulture, $managerProfileId); |
| 21 | 21 | } |
| 22 | 22 | return $result; |
@@ -21,7 +21,7 @@ |
||
| 21 | 21 | public static function getProfilePic($user_id) { |
| 22 | 22 | if (ProfilePicDAO::profilePicExistsForUser($user_id)) { |
| 23 | 23 | return ProfilePicDAO::getProfilePic($user_id); |
| 24 | - } else { |
|
| 24 | + }else { |
|
| 25 | 25 | return NULL; |
| 26 | 26 | } |
| 27 | 27 | } |
@@ -19,23 +19,29 @@ discard block |
||
| 19 | 19 | <div class="page-hero__navigation-item box med-1of5 lg-1of6" id="navigationHomeLinkWrapper" aria-hidden="false"> |
| 20 | 20 | <?php if (strpos($url, 'admin') !== false) : ?> |
| 21 | 21 | <a href="/admin/" id="navigationHomeLink">Home</a> |
| 22 | - <?php else : ?> |
|
| 22 | + <?php else { |
|
| 23 | + : ?> |
|
| 23 | 24 | <a href="/" id="navigationHomeLink">Home</a> |
| 24 | - <?php endif; ?> |
|
| 25 | + <?php endif; |
|
| 26 | +} |
|
| 27 | +?> |
|
| 25 | 28 | </div> |
| 26 | 29 | |
| 27 | 30 | <?php /* Checks to see if the page is the admin portal and then displays the admin home link. */ ?> |
| 28 | 31 | <?php $url = 'http://' . $_SERVER['SERVER_NAME'] . $_SERVER['REQUEST_URI']; ?> |
| 29 | 32 | <?php if (strpos($url, 'admin') !== false) : ?> |
| 30 | 33 | <?php /* No link for you! */ ?> |
| 31 | - <?php else : ?> |
|
| 34 | + <?php else { |
|
| 35 | + : ?> |
|
| 32 | 36 | <?php /* Browse Jobs */ ?> |
| 33 | 37 | <div class="page-hero__navigation-item box med-1of5 lg-1of6" id="navigationBrowseLinkWrapper" aria-hidden="false"> |
| 34 | 38 | <a href="#BrowseJobs" id="navigationBrowseLink" onclick="JobPostAPI.showBrowseJobs();TalentCloudAPI.setNav('navigationBrowseLinkWrapper');"> |
| 35 | 39 | Browse Jobs |
| 36 | 40 | </a> |
| 37 | 41 | </div> |
| 38 | - <?php endif; ?> |
|
| 42 | + <?php endif; |
|
| 43 | +} |
|
| 44 | +?> |
|
| 39 | 45 | |
| 40 | 46 | <?php /* Dashboard */ ?> |
| 41 | 47 | <div class="page-hero__navigation-item box med-1of5 lg-1of6 hidden" id="navigationDashboardLinkWrapper" aria-hidden="true"> |
@@ -61,11 +67,14 @@ discard block |
||
| 61 | 67 | <a href="#CreateEditProfile" id="navigationProfileLink" onclick="CreateEditProfileAPI.showCreateEditProfile();TalentCloudAPI.setNav('navigationProfileLinkWrapper');"> |
| 62 | 68 | My Profile |
| 63 | 69 | </a> |
| 64 | - <?php else :?> |
|
| 70 | + <?php else { |
|
| 71 | + :?> |
|
| 65 | 72 | <a href="#MyProfile" id="navigationProfileLink" onclick="JobSeekerAPI.showMyJobSeekerProfile();TalentCloudAPI.setNav('navigationProfileLinkWrapper');"> |
| 66 | 73 | My Profile |
| 67 | 74 | </a> |
| 68 | - <?php endif; ?> |
|
| 75 | + <?php endif; |
|
| 76 | +} |
|
| 77 | +?> |
|
| 69 | 78 | |
| 70 | 79 | </div> |
| 71 | 80 | |
@@ -75,18 +84,24 @@ discard block |
||
| 75 | 84 | <a href="javascript:void(0)" id="navigationPosterLink" onclick="CreateJobPosterAPI.showCreateJobPosterForm(this);TalentCloudAPI.setNav('navigationPosterLinkWrapper');">Job Poster |
| 76 | 85 | </a> |
| 77 | 86 | </div> |
| 78 | - <?php else : ?> |
|
| 87 | + <?php else { |
|
| 88 | + : ?> |
|
| 79 | 89 | <?php /* No link for you! */ ?> |
| 80 | - <?php endif; ?> |
|
| 90 | + <?php endif; |
|
| 91 | +} |
|
| 92 | +?> |
|
| 81 | 93 | |
| 82 | 94 | <?php /* Register */ |
| 83 | 95 | if (strpos($url, 'admin') !== false) : ?> |
| 84 | 96 | <div class="page-hero__navigation-item box med-1of5 lg-1of6 hidden" id="navigationRegisterLinkWrapper" aria-hidden="true"> |
| 85 | 97 | <?php echo("<a href=\"\" id=\"navigationRegisterLink\">Register</a>"); ?> |
| 86 | 98 | </div> |
| 87 | - <?php else : ?> |
|
| 99 | + <?php else { |
|
| 100 | + : ?> |
|
| 88 | 101 | <div class="page-hero__navigation-item box med-1of5 lg-1of6" id="navigationRegisterLinkWrapper" aria-hidden="false"> |
| 89 | - <?php echo("<a href=\"https://account.gccollab.ca/register?redirect_uri=https%3A%2F%2Ftc.gccollab.ca%2F\" id=\"navigationRegisterLink\">Register</a>"); ?> |
|
| 102 | + <?php echo("<a href=\"https://account.gccollab.ca/register?redirect_uri=https%3A%2F%2Ftc.gccollab.ca%2F\" id=\"navigationRegisterLink\">Register</a>"); |
|
| 103 | +} |
|
| 104 | +?> |
|
| 90 | 105 | </div> |
| 91 | 106 | <?php endif; ?> |
| 92 | 107 | |
@@ -102,9 +117,12 @@ discard block |
||
| 102 | 117 | |
| 103 | 118 | <?php if ($hasUser != null) : ?> |
| 104 | 119 | <div class="page-hero__navigation-item box med-1of5 lg-1of6 hidden" id="navigationLoginLinkWrapper" aria-hidden="true"> |
| 105 | - <?php else :?> |
|
| 120 | + <?php else { |
|
| 121 | + :?> |
|
| 106 | 122 | <div class="page-hero__navigation-item box med-1of5 lg-1of6" id="navigationLoginLinkWrapper" aria-hidden="false"> |
| 107 | - <?php endif; ?> |
|
| 123 | + <?php endif; |
|
| 124 | +} |
|
| 125 | +?> |
|
| 108 | 126 | <?php |
| 109 | 127 | $loginLink = ""; |
| 110 | 128 | $loginLink .= OPENID_URI . AUTH_URI; |
@@ -119,13 +137,16 @@ discard block |
||
| 119 | 137 | ?> |
| 120 | 138 | </div> |
| 121 | 139 | |
| 122 | - <?php else : ?> |
|
| 140 | + <?php else { |
|
| 141 | + : ?> |
|
| 123 | 142 | |
| 124 | 143 | <?php if ($hasUser != null) : ?> |
| 125 | 144 | <div class="page-hero__navigation-item box med-1of5 lg-1of6 hidden" id="navigationLoginLinkWrapper"> |
| 126 | 145 | <?php else :?> |
| 127 | 146 | <div class="page-hero__navigation-item box med-1of5 lg-1of6" id="navigationLoginLinkWrapper"> |
| 128 | - <?php endif; ?> |
|
| 147 | + <?php endif; |
|
| 148 | +} |
|
| 149 | +?> |
|
| 129 | 150 | <?php |
| 130 | 151 | $loginLink = ""; |
| 131 | 152 | $loginLink .= OPENID_URI . AUTH_URI; |
@@ -156,9 +177,12 @@ discard block |
||
| 156 | 177 | <div id="h1"> |
| 157 | 178 | <?php if (strpos($url, 'admin') !== false) : ?> |
| 158 | 179 | <h1 class="visuallyHidden">Talent Cloud - Admin Portal</h1> |
| 159 | - <?php else :?> |
|
| 180 | + <?php else { |
|
| 181 | + :?> |
|
| 160 | 182 | <h1 class="visuallyHidden">Talent Cloud - Applicant Portal</h1> |
| 161 | - <?php endif; ?> |
|
| 183 | + <?php endif; |
|
| 184 | +} |
|
| 185 | +?> |
|
| 162 | 186 | </div> |
| 163 | 187 | |
| 164 | 188 | <div class="landing-hero" id="landingHero"> |
@@ -22,7 +22,7 @@ |
||
| 22 | 22 | $url = 'http://' . $_SERVER['SERVER_NAME'] . $_SERVER['REQUEST_URI']; |
| 23 | 23 | if (strpos($url, 'admin') !== false) { |
| 24 | 24 | echo '<p id="adminTagline" class="centered">Changing government through it\'s people</p>'; |
| 25 | - } else { |
|
| 25 | + }else { |
|
| 26 | 26 | |
| 27 | 27 | } |
| 28 | 28 | ?> |
@@ -40,7 +40,7 @@ |
||
| 40 | 40 | } |
| 41 | 41 | |
| 42 | 42 | return ["manager_profile_id"=>$profileId]; |
| 43 | - } else { |
|
| 43 | + }else { |
|
| 44 | 44 | $profileId = ManagerProfileDAO::createManagerProfile($managerProfile, $managerProfileDetails); |
| 45 | 45 | return ["manager_profile_id"=>$profileId]; |
| 46 | 46 | } |
@@ -70,7 +70,7 @@ discard block |
||
| 70 | 70 | $questionAnswers = self::getApplicationQuestionAnswers($jobPosterApplication->getJob_poster_application_id()); |
| 71 | 71 | $jobApplicationWithAnswers = new JobApplicationWithAnswers($jobPosterApplication, $questionAnswers); |
| 72 | 72 | return $jobApplicationWithAnswers; |
| 73 | - } else { |
|
| 73 | + }else { |
|
| 74 | 74 | return false; |
| 75 | 75 | } |
| 76 | 76 | } |
@@ -165,7 +165,7 @@ discard block |
||
| 165 | 165 | $workSamples = WorkSampleController::getAllWorkSamplesForJobApplication($jobPosterApplicationId, $locale); |
| 166 | 166 | |
| 167 | 167 | return new FullJobApplication($jobPosterApplication, $jobSeekerProfile, $questionAnswers, $skillDeclarations, $microReferences, $workSamples); |
| 168 | - } else { |
|
| 168 | + }else { |
|
| 169 | 169 | return false; |
| 170 | 170 | } |
| 171 | 171 | } |
@@ -174,7 +174,7 @@ discard block |
||
| 174 | 174 | $isDraft = self::jobApplicationIsDraft($jobPosterApplicationId); |
| 175 | 175 | if ($isDraft) { |
| 176 | 176 | return JobApplicationDAO::setJobAppliationStatus($jobPosterApplicationId, "Submitted"); |
| 177 | - } else { |
|
| 177 | + }else { |
|
| 178 | 178 | return ["false"=>"Cannot submit an application which is not a draft"]; |
| 179 | 179 | } |
| 180 | 180 | } |