Changeset 9af201e for frontend/src/App.js
- Timestamp:
- 09/04/26 19:08:08 (11 days ago)
- Branches:
- master
- Children:
- cdcff72
- Parents:
- e1f74f6
- File:
-
- 1 edited
-
frontend/src/App.js (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
frontend/src/App.js
re1f74f6 r9af201e 65 65 66 66 return ( 67 <Router>68 <div className="min-h-screen bg-gray-50">69 {user && <Navbar />}70 <main className={user ? "container mx-auto px-4 py-8" : ""}>71 <Routes>72 <Route path="/login" element={<Login />} />67 <Router> 68 <div className="min-h-screen bg-gray-50"> 69 {user && <Navbar />} 70 <main className={user ? "container mx-auto px-4 py-8" : ""}> 71 <Routes> 72 <Route path="/login" element={<Login />} /> 73 73 74 <Route path="/" element={75 <ProtectedRoute>76 <Dashboard />77 </ProtectedRoute>78 } />74 <Route path="/" element={ 75 <ProtectedRoute> 76 <Dashboard /> 77 </ProtectedRoute> 78 } /> 79 79 80 {/* Patient Routes */}81 <Route path="/patients" element={<ProtectedRoute><PatientList /></ProtectedRoute>} />82 <Route path="/patients/new" element={<ProtectedRoute><PatientForm /></ProtectedRoute>} />83 <Route path="/patients/:id" element={<ProtectedRoute><PatientDetail /></ProtectedRoute>} />84 <Route path="/patients/:id/edit" element={<ProtectedRoute><PatientForm /></ProtectedRoute>} />80 {/* Patient Routes */} 81 <Route path="/patients" element={<ProtectedRoute><PatientList /></ProtectedRoute>} /> 82 <Route path="/patients/new" element={<ProtectedRoute><PatientForm /></ProtectedRoute>} /> 83 <Route path="/patients/:id" element={<ProtectedRoute><PatientDetail /></ProtectedRoute>} /> 84 <Route path="/patients/:id/edit" element={<ProtectedRoute><PatientForm /></ProtectedRoute>} /> 85 85 86 {/* Doctor Routes */}87 <Route path="/doctors" element={<ProtectedRoute><DoctorList /></ProtectedRoute>} />88 <Route path="/doctors/new" element={<ProtectedRoute><DoctorForm /></ProtectedRoute>} />89 <Route path="/doctors/:id" element={<ProtectedRoute><DoctorDetail /></ProtectedRoute>} />90 <Route path="/doctors/:id/edit" element={<ProtectedRoute><DoctorForm /></ProtectedRoute>} />86 {/* Doctor Routes */} 87 <Route path="/doctors" element={<ProtectedRoute><DoctorList /></ProtectedRoute>} /> 88 <Route path="/doctors/new" element={<ProtectedRoute><DoctorForm /></ProtectedRoute>} /> 89 <Route path="/doctors/:id" element={<ProtectedRoute><DoctorDetail /></ProtectedRoute>} /> 90 <Route path="/doctors/:id/edit" element={<ProtectedRoute><DoctorForm /></ProtectedRoute>} /> 91 91 92 {/* Department Routes */}93 <Route path="/departments" element={<ProtectedRoute><DepartmentList /></ProtectedRoute>} />94 <Route path="/departments/:departmentId" element={<ProtectedRoute><DepartmentDetail /></ProtectedRoute>} />95 <Route path="/departments/:departmentId/doctors" element={<ProtectedRoute><DoctorsByDepartment /></ProtectedRoute>} />92 {/* Department Routes */} 93 <Route path="/departments" element={<ProtectedRoute><DepartmentList /></ProtectedRoute>} /> 94 <Route path="/departments/:departmentId" element={<ProtectedRoute><DepartmentDetail /></ProtectedRoute>} /> 95 <Route path="/departments/:departmentId/doctors" element={<ProtectedRoute><DoctorsByDepartment /></ProtectedRoute>} /> 96 96 97 {/* Appointment Routes */}98 <Route path="/appointments" element={<ProtectedRoute><AppointmentList /></ProtectedRoute>} />99 <Route path="/appointments/new" element={<ProtectedRoute><AppointmentForm /></ProtectedRoute>} />97 {/* Appointment Routes */} 98 <Route path="/appointments" element={<ProtectedRoute><AppointmentList /></ProtectedRoute>} /> 99 <Route path="/appointments/new" element={<ProtectedRoute><AppointmentForm /></ProtectedRoute>} /> 100 100 101 {/* Medical Record Routes */}102 <Route path="/medical-records" element={<ProtectedRoute><MedicalRecordList /></ProtectedRoute>} />103 <Route path="/medical-records/:id" element={<ProtectedRoute><MedicalRecordDetail /></ProtectedRoute>} />101 {/* Medical Record Routes */} 102 <Route path="/medical-records" element={<ProtectedRoute><MedicalRecordList /></ProtectedRoute>} /> 103 <Route path="/medical-records/:id" element={<ProtectedRoute><MedicalRecordDetail /></ProtectedRoute>} /> 104 104 105 {/* Medical Report Routes */}106 <Route path="/medical-reports" element={<ProtectedRoute><MedicalReportList /></ProtectedRoute>} />105 {/* Medical Report Routes */} 106 <Route path="/medical-reports" element={<ProtectedRoute><MedicalReportList /></ProtectedRoute>} /> 107 107 108 {/* Lab Test Routes */}109 <Route path="/lab-tests" element={<ProtectedRoute><LabTestList /></ProtectedRoute>} />110 <Route path="/lab-tests/results" element={<ProtectedRoute><LabResultForm /></ProtectedRoute>} />108 {/* Lab Test Routes */} 109 <Route path="/lab-tests" element={<ProtectedRoute><LabTestList /></ProtectedRoute>} /> 110 <Route path="/lab-tests/results" element={<ProtectedRoute><LabResultForm /></ProtectedRoute>} /> 111 111 112 {/* Procedure Routes */}113 <Route path="/procedures" element={<ProtectedRoute><ProcedureList /></ProtectedRoute>} />114 <Route path="/procedures/results" element={<ProtectedRoute><ProcedureResultForm /></ProtectedRoute>} />112 {/* Procedure Routes */} 113 <Route path="/procedures" element={<ProtectedRoute><ProcedureList /></ProtectedRoute>} /> 114 <Route path="/procedures/results" element={<ProtectedRoute><ProcedureResultForm /></ProtectedRoute>} /> 115 115 116 {/* Billing Routes */}117 <Route path="/billing" element={<ProtectedRoute><BillingList /></ProtectedRoute>} />118 <Route path="/billing/:id" element={<ProtectedRoute><BillingDetail /></ProtectedRoute>} />116 {/* Billing Routes */} 117 <Route path="/billing" element={<ProtectedRoute><BillingList /></ProtectedRoute>} /> 118 <Route path="/billing/:id" element={<ProtectedRoute><BillingDetail /></ProtectedRoute>} /> 119 119 120 {/* Referral Routes */}121 <Route path="/referrals" element={<ProtectedRoute><ReferralList /></ProtectedRoute>} />122 </Routes>123 </main>124 </div>125 </Router>120 {/* Referral Routes */} 121 <Route path="/referrals" element={<ProtectedRoute><ReferralList /></ProtectedRoute>} /> 122 </Routes> 123 </main> 124 </div> 125 </Router> 126 126 ); 127 127 }
Note:
See TracChangeset
for help on using the changeset viewer.
