-
Notifications
You must be signed in to change notification settings - Fork 57
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Hemashree M S <[email protected]>
- Loading branch information
1 parent
3999889
commit 7ce2dbe
Showing
18 changed files
with
266 additions
and
0 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
import React from 'react'; | ||
import { useLocation } from 'react-router-dom'; | ||
import { Nurse } from '../data/Nurse'; | ||
import hoslocation from '../../public/assets/location.png'; | ||
import degree from '../../public/assets/qualification.png'; | ||
|
||
const Nurses = () => { | ||
const location = useLocation(); | ||
const { city } = location.state || { city: 'Unknown City' }; | ||
|
||
const filteredNurses = Nurse.filter(nurse => nurse.location === city); | ||
|
||
return ( | ||
<div className='block m-auto w-3/4'> | ||
<h1 className='text-green-500 text-3xl text-left font-semibold my-12'>Finding Best Nurses in {city}</h1> | ||
{filteredNurses.length > 0 ? ( | ||
<div className='grid lg:grid-cols-3 md:grid-cols-2 grid-cols-1 gap-4 mb-20'> | ||
{filteredNurses.map(({ id, name, hospital, profile, qualification }) => ( | ||
<div key={id} className='flex flex-col items-center border p-4 rounded-lg shadow-md hover:opacity-75 transition duration-300'> | ||
<div className='flex w-full items-center justify-evenly'> | ||
<div className='w-24 h-24 mr-4'> | ||
<img src={profile} alt={`${name}'s profile`} className='w-full h-full object-cover rounded-md' /> | ||
</div> | ||
<div className='flex flex-col gap-2'> | ||
<h2 className='text-lg font-semibold ml-3'>{name}</h2> | ||
<p className='text-gray-600 flex items-center gap-3'><img src={hoslocation} alt="" className='h-5 w-5'/>{hospital}</p> | ||
<p className='text-gray-600 flex items-center gap-3'><img src={degree} alt="" className='h-5 w-5'/>{qualification}</p> | ||
</div> | ||
</div> | ||
<button className='mt-4 px-4 py-2 bg-green-500 text-white rounded hover:bg-green-600 transition duration-300'>Book Now</button> | ||
</div> | ||
))} | ||
</div> | ||
) : ( | ||
<p className='text-red-500 text-2xl mb-20 text-center'>No nurses found in {city}</p> | ||
)} | ||
</div> | ||
); | ||
}; | ||
|
||
export default Nurses; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
import React from 'react'; | ||
import { useLocation } from 'react-router-dom'; | ||
import { Patient } from '../data/Patient'; | ||
import ageyrs from '../../public/assets/age.png'; | ||
import serve from '../../public/assets/services.png'; | ||
|
||
const Patients = () => { | ||
const location = useLocation(); | ||
const { city } = location.state || { city: 'Unknown City' }; | ||
|
||
const filteredPatients = Patient.filter(patient => patient.location === city); | ||
|
||
return ( | ||
<div className='block m-auto w-3/4'> | ||
<h1 className='text-green-500 text-3xl text-left font-semibold my-12'>Finding all Patients in {city}</h1> | ||
{filteredPatients.length > 0 ? ( | ||
<div className='grid lg:grid-cols-3 md:grid-cols-2 grid-cols-1 gap-4 mb-20'> | ||
{filteredPatients.map(({ id, name, age, profile, service }) => ( | ||
<div key={id} className='flex flex-col items-center border p-4 rounded-lg shadow-md hover:opacity-75 transition duration-300'> | ||
<div className='flex w-full items-center justify-evenly'> | ||
<div className='w-24 h-24 mr-4'> | ||
<img src={profile} alt={`${name}'s profile`} className='w-full h-full object-cover rounded-md' /> | ||
</div> | ||
<div className='flex flex-col gap-2'> | ||
<h2 className='text-lg font-semibold ml-3'>{name}</h2> | ||
<p className='text-gray-600 flex items-center gap-3'><img src={ageyrs} alt="" className='h-5 w-5'/>{age}</p> | ||
<p className='text-gray-600 flex items-center gap-3'><img src={serve} alt="" className='h-5 w-5'/>{service}</p> | ||
</div> | ||
</div> | ||
<button className='mt-4 px-4 py-2 bg-green-500 text-white rounded hover:bg-green-600 transition duration-300'>Enquire Now</button> | ||
</div> | ||
))} | ||
</div> | ||
) : ( | ||
<p className='text-red-500 text-2xl mb-20 text-center'>No patients found in {city}</p> | ||
)} | ||
</div> | ||
); | ||
}; | ||
|
||
export default Patients; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
import React, { useState } from 'react'; | ||
import patient from '../../public/assets/patient.jpg'; | ||
import nurse from '../../public/assets/nurse-services.jpg'; | ||
import { useNavigate } from 'react-router-dom'; | ||
|
||
const Services = () => { | ||
const [city, setCity] = useState('Delhi'); // Default city | ||
const navigate = useNavigate(); | ||
|
||
const handleCityChange = (e) => { | ||
setCity(e.target.value); | ||
}; | ||
|
||
const handleNavigation = (path) => { | ||
navigate(path, { state: { city } }); | ||
}; | ||
|
||
return ( | ||
<div> | ||
<div className='bg-green-400 block m-auto w-3/4 rounded-md p-10 my-10'> | ||
<h1 className='md:text-5xl text-3xl text-center text-white font-bold mb-10'>Find the Best Nurses</h1> | ||
<label | ||
className="block uppercase tracking-wide text-black-700 dark:text-white text text-xs font-bold mb-2" | ||
form="grid-first-name" | ||
> | ||
Select your city | ||
</label> | ||
<select | ||
className="appearance-none block w-full bg-gray-200 dark:text-white dark:bg-gray-700 text-gray-700 border dark:border-[#333333] rounded py-3 px-4 mb-3 leading-tight focus:outline-none focus:bg-white" | ||
id="grid-first-name" | ||
value={city} | ||
onChange={handleCityChange} | ||
> | ||
<option>Delhi</option> | ||
<option>Bangalore</option> | ||
<option>Mumbai</option> | ||
<option>Chennai</option> | ||
<option>Kolkata</option> | ||
</select> | ||
</div> | ||
<div className='block w-3/4 m-auto'> | ||
<div className='w-full flex md:flex-row flex-col md:gap-0 gap-10 items-center justify-between mb-20'> | ||
<div onClick={() => handleNavigation('/findpatients')} className="img-container relative w-full md:w-2/5 h- cursor-pointer"> | ||
<img src={patient} alt="Patient" className='rounded-lg' /> | ||
<button className='absolute inset-0 opacity-0 hover:opacity-100 transition duration-300 ease-in-out bg-black/50 text-white text-3xl py-2 px-4 rounded-lg focus:outline-none'> | ||
Find Patient | ||
</button> | ||
</div> | ||
<div onClick={() => handleNavigation('/findnurses')} className="img-container relative w-full md:w-2/5 cursor-pointer"> | ||
<img src={nurse} alt="Nurse" className='rounded-lg' /> | ||
<button className='absolute inset-0 opacity-0 hover:opacity-100 transition duration-300 ease-in-out bg-black/50 text-white text-3xl py-2 px-4 rounded-lg focus:outline-none'> | ||
Find Nurse | ||
</button> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
) | ||
} | ||
|
||
export default Services; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
import profile1 from '../../public/assets/profile1.png'; | ||
import profile2 from '../../public/assets/profile2.png'; | ||
import profile3 from '../../public/assets/profile3.png'; | ||
import profile4 from '../../public/assets/profile4.png'; | ||
import profile5 from '../../public/assets/profile5.png'; | ||
|
||
export const Nurse = [ | ||
{ | ||
id: 1, | ||
location: "Delhi", | ||
profile: profile1, | ||
name: "Jones", | ||
qualification: "Mbbs", | ||
hospital: "AIMS", | ||
}, | ||
{ | ||
id: 2, | ||
location: "Delhi", | ||
profile: profile2, | ||
name: "Jones", | ||
qualification: "Mbbs", | ||
hospital: "AIMS", | ||
}, | ||
{ | ||
id: 3, | ||
location: "Bangalore", | ||
profile: profile3, | ||
name: "Jones", | ||
qualification: "Mbbs", | ||
hospital: "AIMS", | ||
}, | ||
{ | ||
id: 4, | ||
location: "Bangalore", | ||
profile: profile4, | ||
name: "Jones", | ||
qualification: "Mbbs", | ||
hospital: "AIMS", | ||
}, | ||
{ | ||
id: 5, | ||
location: "Delhi", | ||
profile: profile5, | ||
name: "Jones", | ||
qualification: "Mbbs", | ||
hospital: "AIMS", | ||
}, | ||
{ | ||
id: 6, | ||
location: "Delhi", | ||
profile: profile1, | ||
name: "Jones", | ||
qualification: "Mbbs", | ||
hospital: "AIMS", | ||
}, | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
import profile1 from '../../public/assets/profile1.png'; | ||
import profile2 from '../../public/assets/profile2.png'; | ||
import profile3 from '../../public/assets/profile3.png'; | ||
import profile4 from '../../public/assets/profile4.png'; | ||
import profile5 from '../../public/assets/profile5.png'; | ||
|
||
export const Patient = [ | ||
{ | ||
id: 1, | ||
name: 'John Cena', | ||
profile: profile1, | ||
location: 'Delhi', | ||
age: '65 years', | ||
service: 'Caretaking', | ||
}, | ||
{ | ||
id: 2, | ||
name: 'John Cena', | ||
profile: profile2, | ||
location: 'Bangalore', | ||
age: '65 years', | ||
service: 'Caretaking', | ||
}, | ||
{ | ||
id: 3, | ||
name: 'John Cena', | ||
profile: profile3, | ||
location: 'Delhi', | ||
age: '65 years', | ||
service: 'Caretaking', | ||
}, | ||
{ | ||
id: 4, | ||
name: 'John Cena', | ||
profile: profile4, | ||
location: 'Delhi', | ||
age: '65 years', | ||
service: 'Caretaking', | ||
}, | ||
{ | ||
id: 5, | ||
name: 'John Cena', | ||
profile: profile5, | ||
location: 'Kolkata', | ||
age: '65 years', | ||
service: 'Caretaking', | ||
}, | ||
{ | ||
id: 6, | ||
name: 'John Cena', | ||
profile: profile1, | ||
location: 'Mumbai', | ||
age: '65 years', | ||
service: 'Caretaking', | ||
}, | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters