Skip to content

Commit 42abb08

Browse files
Merge pull request #5393 from topcoder-platform/gigs-housekeep
Gigs housekeep
2 parents 7a4c0f8 + 61eb569 commit 42abb08

File tree

4 files changed

+35
-14
lines changed

4 files changed

+35
-14
lines changed

.circleci/config.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -289,7 +289,7 @@ workflows:
289289
filters:
290290
branches:
291291
only:
292-
- free
292+
- gigs-housekeep
293293
# This is beta env for production soft releases
294294
- "build-prod-beta":
295295
context : org-global

src/shared/components/Gigs/GigApply/index.jsx

Lines changed: 17 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -48,23 +48,30 @@ export default function GigApply(props) {
4848
<h2>{application.error ? 'OOPS!' : 'APPLICATION SUBMITTED'}</h2>
4949
{
5050
application.error ? (
51-
<p>Looks like there is a problem on our end. Please try again.<br />If this persists please contact <a href="mailto:[email protected]">[email protected]</a>.</p>
51+
<React.Fragment>
52+
<p styleName="error-text">{application.errorObj.message || JSON.stringify(application.errorObj)}</p>
53+
<p>Looks like there is a problem on our end. Please try again.<br />If this persists please contact <a href="mailto:[email protected]">[email protected]</a>.</p>
54+
<p>Please send us an email at <a href="mailto:[email protected]">[email protected]</a> with the subject ‘Gig Error’<br />and paste the URL for the gig you are attempting to apply for so that we know of your interest.</p>
55+
</React.Fragment>
5256
) : (
5357
<p>We will contact you via email if it seems like a fit!</p>
5458
)
5559
}
5660
<div styleName="cta-buttons">
5761
{
5862
application.error ? (
59-
<a
60-
href="#"
61-
styleName="primaryBtn"
62-
onClick={(e) => {
63-
e.preventDefault();
64-
window.location.reload();
65-
}}
66-
>APPLY AGAIN
67-
</a>
63+
<React.Fragment>
64+
<a
65+
href="#"
66+
styleName="primaryBtn"
67+
onClick={(e) => {
68+
e.preventDefault();
69+
window.location.reload();
70+
}}
71+
>APPLY AGAIN
72+
</a>
73+
<Link to={`${config.GIGS_PAGES_PATH}`}>VIEW OTHER GIGS</Link>
74+
</React.Fragment>
6875
) : (
6976
<Link to={`${config.GIGS_PAGES_PATH}`} styleName="primaryBtn">GO TO GIG LIST</Link>
7077
)

src/shared/components/Gigs/GigApply/style.scss

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -241,11 +241,16 @@
241241
text-decoration: none;
242242
}
243243
}
244+
245+
.error-text {
246+
color: #ef476f;
247+
}
244248
}
245249
/* stylelint-disable */
246250
.cta-buttons {
247251
display: flex;
248252
justify-content: center;
253+
align-items: flex-start;
249254
margin-top: 47px;
250255

251256
@include xs-to-sm {
@@ -271,6 +276,10 @@
271276
@include xs-to-sm {
272277
text-align: center;
273278
}
279+
280+
&:last-child {
281+
margin-left: 20px;
282+
}
274283
}
275284
}
276285
/* stylelint-enable */

src/shared/containers/Gigs/RecruitCRMJobs.jsx

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,9 @@ const sortByOptions = [
2121
{ label: 'Latest Updated Descending', selected: false },
2222
];
2323
// Locations
24-
let locations = [];
24+
let locations = [{
25+
label: 'All', selected: true,
26+
}];
2527

2628
class RecruitCRMJobsContainer extends React.Component {
2729
constructor(props) {
@@ -123,12 +125,15 @@ class RecruitCRMJobsContainer extends React.Component {
123125
jobsToDisplay = _.filter(jobs, (job) => {
124126
const country = job.country === 'Anywhere' || job.country === 'Any' ? 'All' : job.country;
125127
// build dropdown
126-
const found = _.find(locations, { label: country });
127-
if (!found) {
128+
const found = _.findIndex(locations, { label: country });
129+
if (found === -1) {
128130
locations.push({
129131
label: country, selected: location.toLowerCase() === country.toLowerCase(),
130132
});
133+
} else {
134+
locations[found].selected = location.toLowerCase() === country.toLowerCase();
131135
}
136+
locations[0].selected = location === 'All';
132137
// filter
133138
if (location === 'Anywhere' || location === 'Any' || location === 'All') return true;
134139
return location.toLowerCase() === job.country.toLowerCase();

0 commit comments

Comments
 (0)