Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update/add cycle bureau position #1190

Merged
merged 9 commits into from
Oct 21, 2020
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,11 @@ class BureauResultsCard extends Component {
'Position number': position,
'Skill': getResult(pos, 'skill_code', NO_SKILL),
'Grade': getResult(pos, 'grade', NO_GRADE),
'Bureau': getResult(pos, 'bureau', NO_BUREAU),
'Bureau': getResult(pos, 'bureau_short_desc', NO_BUREAU),
'Tour of duty': getResult(pos, 'post.tour_of_duty', NO_TOUR_OF_DUTY),
'Language': language,
'Post differential | Danger Pay': getDifferentials(pos),
'Bid cycle': getResult(pos, 'latest_bidcycle.name', 'None Listed'),
'TED': getResult(result, 'ted', NO_DATE),
'Incumbent': getResult(pos, 'current_assignment.user', NO_USER_LISTED),
'Posted': getResult(result, COMMON_PROPERTIES.posted, NO_UPDATE_DATE),
Expand Down
2 changes: 2 additions & 0 deletions src/Components/PositionDetailsItem/PositionDetailsItem.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ const PositionDetailsItem = (props) => {
const differentials = <Differentials {...diffProps} />;

const incumbent = get(position, 'current_assignment.user') || NO_USER_LISTED;
const cycle = get(position, 'latest_bidcycle.name', 'None Listed');

const getPostedDate = () => {
const posted = get(position, COMMON_PROPERTIES.posted);
Expand Down Expand Up @@ -126,6 +127,7 @@ const PositionDetailsItem = (props) => {
<CondensedCardDataPoint title="Tour of duty" content={formattedTOD} />
<CondensedCardDataPoint title="Language" content={<LanguageList languages={get(position, 'languages')} propToUse="representation" />} />
<CondensedCardDataPoint title="Post differential | Danger Pay" content={differentials} />
<CondensedCardDataPoint title={isProjectedVacancy ? 'Bid Season' : 'Bid Cycle'} content={cycle} />
<CondensedCardDataPoint title="TED" content={formattedTourEndDate} />
<CondensedCardDataPoint title="Incumbent" content={incumbent} />
{ !isProjectedVacancy && <CondensedCardDataPoint title="Posted" content={postedDate} />}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,11 @@ exports[`PositionDetailsItem matches snapshot 1`] = `
hasFixedTitleWidth={false}
title="Post differential | Danger Pay"
/>
<CondensedCardDataPoint
content="Demo BidCycle 2018-03-13 15:51:10.980576+00:00"
hasFixedTitleWidth={false}
title="Bid Cycle"
/>
<CondensedCardDataPoint
content="None listed"
hasFixedTitleWidth={false}
Expand Down Expand Up @@ -510,6 +515,11 @@ exports[`PositionDetailsItem matches snapshot when there is an obc id 1`] = `
hasFixedTitleWidth={false}
title="Post differential | Danger Pay"
/>
<CondensedCardDataPoint
content="Demo BidCycle 2018-03-13 15:51:10.980576+00:00"
hasFixedTitleWidth={false}
title="Bid Cycle"
/>
<CondensedCardDataPoint
content="None listed"
hasFixedTitleWidth={false}
Expand Down Expand Up @@ -872,6 +882,11 @@ exports[`PositionDetailsItem matches snapshot when various data is missing from
hasFixedTitleWidth={false}
title="Post differential | Danger Pay"
/>
<CondensedCardDataPoint
content="Demo BidCycle 2018-03-13 15:51:10.980576+00:00"
hasFixedTitleWidth={false}
title="Bid Cycle"
/>
<CondensedCardDataPoint
content="None listed"
hasFixedTitleWidth={false}
Expand Down