Skip to content

Commit

Permalink
Issue #PS-1275 chore: Modified mapping
Browse files Browse the repository at this point in the history
  • Loading branch information
Rushikesh-Sonawane99 committed Aug 2, 2024
2 parents 7dfe65c + 546d20f commit 6d8d082
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
5 changes: 5 additions & 0 deletions src/pages/learner/[userId].tsx
Original file line number Diff line number Diff line change
Expand Up @@ -219,6 +219,11 @@ const LearnerProfile: React.FC = () => {
} else if (item?.type === 'text') {
return String(field?.value);
} else {
if(field.value ==='FEMALE' || field.value ==='MALE')
{
console.log(true)
return field?.value?.toLowerCase();
}
return field?.value;
}
}
Expand Down
9 changes: 7 additions & 2 deletions src/pages/user-profile/[userId].tsx
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,11 @@ const TeacherProfile = () => {
} else if (item?.type === 'text') {
return String(field?.value);
} else {
if(field.value ==='FEMALE' || field.value ==='MALE')
{
console.log(true)
return field?.value?.toLowerCase();
}
return field?.value;
}
}
Expand Down Expand Up @@ -612,7 +617,7 @@ const TeacherProfile = () => {
{filteredSortedForView?.map((item, index) => {
if (String(item.order) === '7') {
return (
<Grid item xs={12}>
<Grid item xs={12} key={index}>
<Typography
fontSize={'12px'}
fontWeight={'600'}
Expand All @@ -633,7 +638,7 @@ const TeacherProfile = () => {
}}
>
{orderedSubjects &&
orderedSubjects?.map((subject: string, index: React.Key | null | undefined) => (
orderedSubjects?.map((subject: any, index: number) => (
<Button
key={index}
size="small"
Expand Down

0 comments on commit 6d8d082

Please sign in to comment.