@@ -72,14 +72,14 @@ function CompanyApplication() {
7272 await applicationAPI . updateApplicationStatus ( applicationId , newStatus ) ;
7373 setApplications (
7474 applications . map ( ( app ) =>
75- app . id === applicationId ? { ...app , status : newStatus } : app
76- )
75+ app . id === applicationId ? { ...app , status : newStatus } : app ,
76+ ) ,
7777 ) ;
7878 alert ( `Application ${ newStatus . toLowerCase ( ) } successfully!` ) ;
7979 } catch ( err ) {
8080 console . error ( "Failed to update status:" , err ) ;
8181 alert (
82- err . response ?. data ?. message || "Failed to update application status"
82+ err . response ?. data ?. message || "Failed to update application status" ,
8383 ) ;
8484 }
8585 } ;
@@ -152,7 +152,7 @@ function CompanyApplication() {
152152 < div className = "flex items-center gap-3 mb-2" >
153153 < span
154154 className = { `px-3 py-1 text-xs font-semibold rounded-full border ${ getStatusColor (
155- application . status
155+ application . status ,
156156 ) } `}
157157 >
158158 { application . status || "Pending" }
@@ -161,7 +161,7 @@ function CompanyApplication() {
161161 < Clock className = "w-4 h-4" />
162162 Applied{ " " }
163163 { formatDate (
164- application . appliedAt || application . createdAt
164+ application . appliedAt || application . createdAt ,
165165 ) }
166166 </ span >
167167 </ div >
@@ -206,7 +206,7 @@ function CompanyApplication() {
206206 setExpandedId (
207207 expandedId === application . id
208208 ? null
209- : application . id
209+ : application . id ,
210210 )
211211 }
212212 className = "text-blue-600 text-sm font-medium hover:text-blue-700 flex items-center gap-1"
@@ -228,32 +228,37 @@ function CompanyApplication() {
228228 ) }
229229
230230 { /* Resume Section */ }
231- { application . user ?. document && application . user . document . length > 0 && (
232- < div className = "mt-3 p-3 bg-blue-50 rounded-lg border border-blue-200" >
233- < div className = "flex items-center justify-between" >
234- < div className = "flex items-center gap-2" >
235- < FileText className = "w-5 h-5 text-blue-600" />
236- < div >
237- < p className = "text-sm font-semibold text-gray-900" >
238- { application . user . document [ 0 ] . fileName || 'Resume' }
239- </ p >
240- < p className = "text-xs text-gray-500" >
241- Uploaded { new Date ( application . user . document [ 0 ] . uploadedAt ) . toLocaleDateString ( ) }
242- </ p >
231+ { application . user ?. document &&
232+ application . user . document . length > 0 && (
233+ < div className = "mt-3 p-3 bg-blue-50 rounded-lg border border-blue-200" >
234+ < div className = "flex items-center justify-between" >
235+ < div className = "flex items-center gap-2" >
236+ < FileText className = "w-5 h-5 text-blue-600" />
237+ < div >
238+ < p className = "text-sm font-semibold text-gray-900" >
239+ { application . user . document [ 0 ] . fileName ||
240+ "Resume" }
241+ </ p >
242+ < p className = "text-xs text-gray-500" >
243+ Uploaded{ " " }
244+ { new Date (
245+ application . user . document [ 0 ] . uploadedAt ,
246+ ) . toLocaleDateString ( ) }
247+ </ p >
248+ </ div >
243249 </ div >
250+ < a
251+ href = { application . user . document [ 0 ] . fileUrl }
252+ target = "_blank"
253+ rel = "noopener noreferrer"
254+ className = "px-3 py-1.5 bg-blue-600 text-white rounded-md text-xs font-semibold hover:bg-blue-700 transition-colors flex items-center gap-1"
255+ >
256+ View Resume
257+ < ExternalLink className = "w-3 h-3" />
258+ </ a >
244259 </ div >
245- < a
246- href = { application . user . document [ 0 ] . fileUrl }
247- target = "_blank"
248- rel = "noopener noreferrer"
249- className = "px-3 py-1.5 bg-blue-600 text-white rounded-md text-xs font-semibold hover:bg-blue-700 transition-colors flex items-center gap-1"
250- >
251- View Resume
252- < ExternalLink className = "w-3 h-3" />
253- </ a >
254260 </ div >
255- </ div >
256- ) }
261+ ) }
257262 </ div >
258263
259264 < div className = "flex flex-col gap-2 ml-4" >
0 commit comments