Skip to content

Commit 389903d

Browse files
authored
Merge branch 'dev' into pm-1373
2 parents ce59d56 + 86575bb commit 389903d

File tree

1 file changed

+21
-1
lines changed
  • src/apps/copilots/src/pages/copilot-opportunity-details

1 file changed

+21
-1
lines changed

src/apps/copilots/src/pages/copilot-opportunity-details/index.tsx

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ import {
3636
} from '../../services/copilot-opportunities'
3737
import { FormattedMembers, useMembers } from '../../services/members'
3838
import { copilotRoutesMap } from '../../copilots.routes'
39+
import { ProjectType } from '../../constants'
3940

4041
import { ApplyOpportunityModal } from './apply-opportunity-modal'
4142
import {
@@ -141,6 +142,21 @@ const CopilotOpportunityDetails: FC<{}> = () => {
141142

142143
const application = copilotApplications && copilotApplications[0]
143144

145+
const getOpportunityType = (type: string): ProjectType => {
146+
switch (type) {
147+
case 'ai':
148+
return ProjectType.ai
149+
case 'datascience':
150+
return ProjectType.datascience
151+
case 'dev':
152+
return ProjectType.developement
153+
case 'design':
154+
return ProjectType.design
155+
default:
156+
return ProjectType.qa
157+
}
158+
}
159+
144160
return (
145161
<ContentLayout
146162
title='Copilot Opportunity'
@@ -223,7 +239,11 @@ const CopilotOpportunityDetails: FC<{}> = () => {
223239
<IconOutline.CogIcon className={styles.icon} />
224240
<div className={styles.infoText}>
225241
<span className={styles.infoHeading}>Type</span>
226-
<span className={styles.infoValue}>{opportunity?.type}</span>
242+
<span
243+
className={styles.infoValue}
244+
>
245+
{opportunity?.type && getOpportunityType(opportunity?.type)}
246+
</span>
227247
</div>
228248
</div>
229249
<div className={styles.infoColumn}>

0 commit comments

Comments
 (0)