File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -202,6 +202,7 @@ const CentersPage = () => {
202202 } ) ;
203203
204204 setBlockData ( blockData ) ;
205+ localStorage . setItem ( 'tvetName' , blockData [ 0 ] . blockName ) ;
205206 }
206207
207208 if (
Original file line number Diff line number Diff line change @@ -23,6 +23,7 @@ import {
2323} from '@/utils/app.constant' ;
2424import { logEvent } from '@/utils/googleAnalytics' ;
2525import {
26+ capitalizeFirstLetterOfEachWordInArray ,
2627 extractAddress ,
2728 formatSelectedDate ,
2829 getUserDetailsById ,
@@ -541,6 +542,24 @@ const LearnerProfile: React.FC<any> = () => {
541542 } ;
542543 } ) ;
543544
545+ const updatedLearnerDetails = learnerDetailsByOrder . flatMap ( ( field ) => {
546+ const tvetName = localStorage . getItem ( 'tvetName' ) ;
547+
548+ if ( field . label === 'TVETS_ENROLLMENT_NUMBER' ) {
549+ return [
550+ {
551+ key : 'TVET_NAME' ,
552+ label : 'TVET Name' ,
553+ displayValue : tvetName
554+ ? capitalizeFirstLetterOfEachWordInArray ( tvetName ? [ tvetName ] : [ ] )
555+ : '-' ,
556+ } ,
557+ field ,
558+ ] ;
559+ }
560+ return field ;
561+ } ) ;
562+
544563 //------ Test Report API Integration------
545564
546565 // const handleChangeTest = (event: SelectChangeEvent) => {
@@ -1069,7 +1088,7 @@ const LearnerProfile: React.FC<any> = () => {
10691088 padding = "15px"
10701089 >
10711090 < Grid container spacing = { 4 } >
1072- { learnerDetailsByOrder ?. map (
1091+ { updatedLearnerDetails ?. map (
10731092 (
10741093 item : {
10751094 label ?: string ;
You can’t perform that action at this time.
0 commit comments