renaming of folders, files, functions, variables
This commit is contained in:
parent
8419e26a4e
commit
5dc96104a8
@ -27,7 +27,7 @@ interface DataTableProps {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type Props = {
|
type Props = {
|
||||||
handleFormSection5Data: (
|
handlePastTreatmentFormData: (
|
||||||
generalHealth: string | undefined,
|
generalHealth: string | undefined,
|
||||||
presentProblemBefore: string | undefined,
|
presentProblemBefore: string | undefined,
|
||||||
ifYespresentProblemBefore: string | undefined,
|
ifYespresentProblemBefore: string | undefined,
|
||||||
@ -45,7 +45,7 @@ type Props = {
|
|||||||
type: string;
|
type: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
function DataTable({ handleFormSection5Data, patientDataDiplay, type }: Props) {
|
function DataTable({ handlePastTreatmentFormData, patientDataDiplay, type }: Props) {
|
||||||
const [illnessFromData, setIllnessFromData] = React.useState<any>({
|
const [illnessFromData, setIllnessFromData] = React.useState<any>({
|
||||||
id: 0,
|
id: 0,
|
||||||
date: '',
|
date: '',
|
||||||
|
|||||||
@ -32,7 +32,7 @@ interface Patient {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type Props = {
|
type Props = {
|
||||||
handleFormSection2Data: (
|
handleFamilyInformationFormData: (
|
||||||
maritalStatus: string | undefined,
|
maritalStatus: string | undefined,
|
||||||
numberOfChildren: string | undefined,
|
numberOfChildren: string | undefined,
|
||||||
occupation: string | undefined,
|
occupation: string | undefined,
|
||||||
@ -50,8 +50,8 @@ type Props = {
|
|||||||
type: string;
|
type: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
export default function FamilyFormSection({
|
export default function FamilyInformationForm({
|
||||||
handleFormSection2Data,
|
handleFamilyInformationFormData,
|
||||||
patientDataDiplay,
|
patientDataDiplay,
|
||||||
type,
|
type,
|
||||||
}: Props) {
|
}: Props) {
|
||||||
@ -71,7 +71,7 @@ export default function FamilyFormSection({
|
|||||||
});
|
});
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
handleFormSection2Data(
|
handleFamilyInformationFormData(
|
||||||
patient.maritalStatus,
|
patient.maritalStatus,
|
||||||
patient.numberOfChildren,
|
patient.numberOfChildren,
|
||||||
patient.occupation,
|
patient.occupation,
|
||||||
@ -19,7 +19,7 @@ interface Patient {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type Props = {
|
type Props = {
|
||||||
handleFormSection3Data:(
|
handleMedicalHistoryFormData:(
|
||||||
physicianname?: string |undefined,
|
physicianname?: string |undefined,
|
||||||
physiciancity?: string |undefined,
|
physiciancity?: string |undefined,
|
||||||
physicianstate?: string |undefined,
|
physicianstate?: string |undefined,
|
||||||
@ -36,7 +36,7 @@ type Props = {
|
|||||||
type:string;
|
type:string;
|
||||||
}
|
}
|
||||||
|
|
||||||
export default function MedicalHistoryForm({handleFormSection3Data,patientDataDiplay,type}:Props){
|
export default function MedicalHistoryForm({handleMedicalHistoryFormData,patientDataDiplay,type}:Props){
|
||||||
|
|
||||||
const [patient, setPatient] = React.useState<Patient>({
|
const [patient, setPatient] = React.useState<Patient>({
|
||||||
physicianname: '',
|
physicianname: '',
|
||||||
@ -53,7 +53,7 @@ export default function MedicalHistoryForm({handleFormSection3Data,patientDataDi
|
|||||||
});
|
});
|
||||||
|
|
||||||
useEffect(()=>{
|
useEffect(()=>{
|
||||||
handleFormSection3Data(
|
handleMedicalHistoryFormData(
|
||||||
patient.physicianname,
|
patient.physicianname,
|
||||||
patient.physiciancity,
|
patient.physiciancity,
|
||||||
patient.physicianstate,
|
patient.physicianstate,
|
||||||
@ -23,7 +23,7 @@ interface Patient {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type Props = {
|
type Props = {
|
||||||
handleFormSection8Data: (
|
handleOtherDetailsFormData: (
|
||||||
familyHistory: string | undefined,
|
familyHistory: string | undefined,
|
||||||
sleep: string | undefined,
|
sleep: string | undefined,
|
||||||
pillow: string | undefined,
|
pillow: string | undefined,
|
||||||
@ -36,8 +36,8 @@ type Props = {
|
|||||||
type: string;
|
type: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
export default function OtherDetails8({
|
export default function OtherDetailsForm({
|
||||||
handleFormSection8Data,
|
handleOtherDetailsFormData,
|
||||||
patientDataDiplay,
|
patientDataDiplay,
|
||||||
type,
|
type,
|
||||||
}: Props) {
|
}: Props) {
|
||||||
@ -52,7 +52,7 @@ export default function OtherDetails8({
|
|||||||
});
|
});
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
handleFormSection8Data(
|
handleOtherDetailsFormData(
|
||||||
patient.familyHistory,
|
patient.familyHistory,
|
||||||
patient.sleep,
|
patient.sleep,
|
||||||
patient.pillow,
|
patient.pillow,
|
||||||
@ -29,7 +29,7 @@ interface Patient {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type Props = {
|
type Props = {
|
||||||
handleFormSection4Data: (
|
handleInjuryDetailsFormData: (
|
||||||
chiefComplaint: string | undefined,
|
chiefComplaint: string | undefined,
|
||||||
painWorse: any,
|
painWorse: any,
|
||||||
painBetter: any,
|
painBetter: any,
|
||||||
@ -45,8 +45,8 @@ type Props = {
|
|||||||
type: string;
|
type: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
export default function PainAnalysisSection4({
|
export default function PainAnalysisForm({
|
||||||
handleFormSection4Data,
|
handleInjuryDetailsFormData,
|
||||||
patientDataDiplay,
|
patientDataDiplay,
|
||||||
type,
|
type,
|
||||||
}: Props) {
|
}: Props) {
|
||||||
@ -64,7 +64,7 @@ export default function PainAnalysisSection4({
|
|||||||
});
|
});
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
handleFormSection4Data(
|
handleInjuryDetailsFormData(
|
||||||
patient.chiefComplaint,
|
patient.chiefComplaint,
|
||||||
patient.painWorse,
|
patient.painWorse,
|
||||||
patient.painBetter,
|
patient.painBetter,
|
||||||
@ -28,7 +28,7 @@ interface Patient {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type Props = {
|
type Props = {
|
||||||
handleFormSection5Data: (
|
handlePastTreatmentFormData: (
|
||||||
generalHealth: string | undefined,
|
generalHealth: string | undefined,
|
||||||
presentProblemBefore: string | undefined,
|
presentProblemBefore: string | undefined,
|
||||||
ifYespresentProblemBefore: string | undefined,
|
ifYespresentProblemBefore: string | undefined,
|
||||||
@ -46,8 +46,8 @@ type Props = {
|
|||||||
type: string;
|
type: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
export default function PastTreatment5({
|
export default function PastTreatmentForm({
|
||||||
handleFormSection5Data,
|
handlePastTreatmentFormData,
|
||||||
patientDataDiplay,
|
patientDataDiplay,
|
||||||
type,
|
type,
|
||||||
}: Props) {
|
}: Props) {
|
||||||
@ -67,7 +67,7 @@ export default function PastTreatment5({
|
|||||||
});
|
});
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
handleFormSection5Data(
|
handlePastTreatmentFormData(
|
||||||
patient.generalHealth,
|
patient.generalHealth,
|
||||||
patient.presentProblemBefore,
|
patient.presentProblemBefore,
|
||||||
patient.ifYespresentProblemBefore,
|
patient.ifYespresentProblemBefore,
|
||||||
@ -494,7 +494,7 @@ export default function PastTreatment5({
|
|||||||
|
|
||||||
<Grid item xs={12} sx={{ marginLeft: 2, marginBottom: 3 }}>
|
<Grid item xs={12} sx={{ marginLeft: 2, marginBottom: 3 }}>
|
||||||
<Table
|
<Table
|
||||||
handleFormSection5Data={handleFormSection5Data}
|
handlePastTreatmentFormData={handlePastTreatmentFormData}
|
||||||
patientDataDiplay={patientDataDiplay}
|
patientDataDiplay={patientDataDiplay}
|
||||||
type={type}
|
type={type}
|
||||||
/>
|
/>
|
||||||
@ -16,7 +16,7 @@ import {
|
|||||||
RadioGroup,
|
RadioGroup,
|
||||||
TextField,
|
TextField,
|
||||||
} from '@mui/material';
|
} from '@mui/material';
|
||||||
import PersonalSection from './PersonalSection1';
|
import PersonalInformationForm from './PersonalInformationSection';
|
||||||
import { styled } from '@mui/material/styles';
|
import { styled } from '@mui/material/styles';
|
||||||
import ArrowForwardIosSharpIcon from '@mui/icons-material/ArrowForwardIosSharp';
|
import ArrowForwardIosSharpIcon from '@mui/icons-material/ArrowForwardIosSharp';
|
||||||
import MuiAccordion, { AccordionProps } from '@mui/material/Accordion';
|
import MuiAccordion, { AccordionProps } from '@mui/material/Accordion';
|
||||||
@ -24,13 +24,13 @@ import MuiAccordionSummary, {
|
|||||||
AccordionSummaryProps,
|
AccordionSummaryProps,
|
||||||
} from '@mui/material/AccordionSummary';
|
} from '@mui/material/AccordionSummary';
|
||||||
import MuiAccordionDetails from '@mui/material/AccordionDetails';
|
import MuiAccordionDetails from '@mui/material/AccordionDetails';
|
||||||
import MedicalHistory from './MedicalHistorySection3';
|
import MedicalHistory from './MedicalHistorySection';
|
||||||
import FamilyFormSection from './FamilyFormSection2';
|
import FamilyInformationForm from './FamilyInformationSection';
|
||||||
import PainAnalysisSection4 from './PainAnalysisSection4';
|
import PainAnalysisForm from './PainAnalysisSection';
|
||||||
import PastTreatment5 from './PastTreatment5';
|
import PastTreatmentForm from './PastTreatment';
|
||||||
import SystemReviewSection6 from './SyestemReviewSection6';
|
import SystemReviewForm from './SyestemReviewSection';
|
||||||
import RecreationalHobbiesSection7 from './RecreationalHobbiesSection7';
|
import RecreationalHobbiesForm from './RecreationalHobbiesSection';
|
||||||
import OtherDetails8 from './OtherDetails8';
|
import OtherDetailsForm from './OtherDetailsSection';
|
||||||
import PatientImageMarker from '../ImageMarker/PatientImageMarker';
|
import PatientImageMarker from '../ImageMarker/PatientImageMarker';
|
||||||
import ViewPatientImageMarker from '../ImageMarker/ViewPatientImageMarker';
|
import ViewPatientImageMarker from '../ImageMarker/ViewPatientImageMarker';
|
||||||
import AlertDialog from '../Helper/AlertDialogBox';
|
import AlertDialog from '../Helper/AlertDialogBox';
|
||||||
@ -83,23 +83,23 @@ export default function PatientForm({ type }: Props) {
|
|||||||
const [expanded, setExpanded] = React.useState<string | false>('panel1');
|
const [expanded, setExpanded] = React.useState<string | false>('panel1');
|
||||||
const [isChecked, setIsChecked] = React.useState(false);
|
const [isChecked, setIsChecked] = React.useState(false);
|
||||||
const [signature, setSignature] = React.useState<any>();
|
const [signature, setSignature] = React.useState<any>();
|
||||||
const [section1Data, setSection1Data] = React.useState<any>({});
|
const [personalInformation, setPersonalInformation] = React.useState<any>({});
|
||||||
const [section2Data, setSection2Data] = React.useState<any>({});
|
const [familyInformation, setFamilyInformation] = React.useState<any>({});
|
||||||
const [section3Data, setSection3Data] = React.useState<any>({});
|
const [medicalHistory, setMedicalHistory] = React.useState<any>({});
|
||||||
const [section4Data, setSection4Data] = React.useState<any>({});
|
const [injuryDetails, setInjuryDetails] = React.useState<any>({});
|
||||||
const [section5Data, setSection5Data] = React.useState<any>({});
|
const [pastTreatment, setPastTreatment] = React.useState<any>({});
|
||||||
const [section6Data, setSection6Data] = React.useState<any>({});
|
const [systemReviewQuestions, setSystemReviewQuestions] = React.useState<any>({});
|
||||||
const [section7Data, setSection7Data] = React.useState<any>({});
|
const [recreationalActivities, setRecreationalActivities] = React.useState<any>({});
|
||||||
const [section8Data, setSection8Data] = React.useState<any>({});
|
const [otherDetails, setOtherDetails] = React.useState<any>({});
|
||||||
const [allPatientData, setAllPatientData] = React.useState<any>([]);
|
const [allPatientData, setAllPatientData] = React.useState<any>([]);
|
||||||
const [patientDetailsButtonFlag, setPatientDetailsButtonFlag] =
|
const [patientDetailsButtonFlag, setPatientDetailsButtonFlag] =
|
||||||
React.useState<boolean>(false);
|
React.useState<boolean>(false);
|
||||||
|
|
||||||
const handleFormSection1Data = (patient: Patient) => {
|
const handlePersonalInformationFormData = (patient: Patient) => {
|
||||||
setSection1Data(patient);
|
setPersonalInformation(patient);
|
||||||
};
|
};
|
||||||
|
|
||||||
const handleFormSection2Data = (
|
const handleFamilyInformationFormData = (
|
||||||
maritalStatus: string | undefined,
|
maritalStatus: string | undefined,
|
||||||
numberOfChildren: string | undefined,
|
numberOfChildren: string | undefined,
|
||||||
occupation: string | undefined,
|
occupation: string | undefined,
|
||||||
@ -113,7 +113,7 @@ export default function PatientForm({ type }: Props) {
|
|||||||
relationship: string | undefined,
|
relationship: string | undefined,
|
||||||
spousePhone: string | undefined
|
spousePhone: string | undefined
|
||||||
) => {
|
) => {
|
||||||
setSection2Data({
|
setFamilyInformation({
|
||||||
maritalStatus,
|
maritalStatus,
|
||||||
numberOfChildren,
|
numberOfChildren,
|
||||||
occupation,
|
occupation,
|
||||||
@ -129,7 +129,7 @@ export default function PatientForm({ type }: Props) {
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
const handleFormSection3Data = (
|
const handleMedicalHistoryFormData = (
|
||||||
physicianname: string | undefined,
|
physicianname: string | undefined,
|
||||||
physiciancity: string | undefined,
|
physiciancity: string | undefined,
|
||||||
physicianstate: string | undefined,
|
physicianstate: string | undefined,
|
||||||
@ -142,7 +142,7 @@ export default function PatientForm({ type }: Props) {
|
|||||||
visitDetails: string | undefined,
|
visitDetails: string | undefined,
|
||||||
cellPhoneProvider: string | undefined
|
cellPhoneProvider: string | undefined
|
||||||
) => {
|
) => {
|
||||||
setSection3Data({
|
setMedicalHistory({
|
||||||
physicianname,
|
physicianname,
|
||||||
physiciancity,
|
physiciancity,
|
||||||
physicianstate,
|
physicianstate,
|
||||||
@ -157,7 +157,7 @@ export default function PatientForm({ type }: Props) {
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
const handleFormSection4Data = (
|
const handleInjuryDetailsFormData = (
|
||||||
chiefComplaint: string | undefined,
|
chiefComplaint: string | undefined,
|
||||||
painWorse: any,
|
painWorse: any,
|
||||||
painBetter: any,
|
painBetter: any,
|
||||||
@ -169,7 +169,7 @@ export default function PatientForm({ type }: Props) {
|
|||||||
treatmentGoal: string | undefined,
|
treatmentGoal: string | undefined,
|
||||||
selfTreatment: string | undefined
|
selfTreatment: string | undefined
|
||||||
) => {
|
) => {
|
||||||
setSection4Data({
|
setInjuryDetails({
|
||||||
chiefComplaint,
|
chiefComplaint,
|
||||||
painWorse,
|
painWorse,
|
||||||
painBetter,
|
painBetter,
|
||||||
@ -183,7 +183,7 @@ export default function PatientForm({ type }: Props) {
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
const handleFormSection5Data = (
|
const handlePastTreatmentFormData = (
|
||||||
generalHealth: string | undefined,
|
generalHealth: string | undefined,
|
||||||
presentProblemBefore: string | undefined,
|
presentProblemBefore: string | undefined,
|
||||||
ifYespresentProblemBefore: string | undefined,
|
ifYespresentProblemBefore: string | undefined,
|
||||||
@ -197,7 +197,7 @@ export default function PatientForm({ type }: Props) {
|
|||||||
injuriesHospitalization: string | undefined,
|
injuriesHospitalization: string | undefined,
|
||||||
supplementsOrDrugs: string | undefined
|
supplementsOrDrugs: string | undefined
|
||||||
) => {
|
) => {
|
||||||
setSection5Data({
|
setPastTreatment({
|
||||||
generalHealth,
|
generalHealth,
|
||||||
presentProblemBefore,
|
presentProblemBefore,
|
||||||
ifYespresentProblemBefore,
|
ifYespresentProblemBefore,
|
||||||
@ -213,7 +213,7 @@ export default function PatientForm({ type }: Props) {
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
const handleFormSection6Data = (
|
const handleSystemReviewFormData = (
|
||||||
eyes: string | undefined,
|
eyes: string | undefined,
|
||||||
IntestinesBowls: string | undefined,
|
IntestinesBowls: string | undefined,
|
||||||
jointsBones: string | undefined,
|
jointsBones: string | undefined,
|
||||||
@ -232,7 +232,7 @@ export default function PatientForm({ type }: Props) {
|
|||||||
prostate: string | undefined,
|
prostate: string | undefined,
|
||||||
explanation: string | undefined
|
explanation: string | undefined
|
||||||
) => {
|
) => {
|
||||||
setSection6Data({
|
setSystemReviewQuestions({
|
||||||
eyes,
|
eyes,
|
||||||
IntestinesBowls,
|
IntestinesBowls,
|
||||||
jointsBones,
|
jointsBones,
|
||||||
@ -253,7 +253,7 @@ export default function PatientForm({ type }: Props) {
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
const handleFormSection7Data = (
|
const handleRecreationalActivitiesFormData = (
|
||||||
hobbies: string | undefined,
|
hobbies: string | undefined,
|
||||||
educationLevel: string | undefined,
|
educationLevel: string | undefined,
|
||||||
excercise: string | undefined,
|
excercise: string | undefined,
|
||||||
@ -273,7 +273,7 @@ export default function PatientForm({ type }: Props) {
|
|||||||
drugs: string | undefined,
|
drugs: string | undefined,
|
||||||
drugsExplanation: string | undefined
|
drugsExplanation: string | undefined
|
||||||
) => {
|
) => {
|
||||||
setSection7Data({
|
setRecreationalActivities({
|
||||||
hobbies,
|
hobbies,
|
||||||
educationLevel,
|
educationLevel,
|
||||||
excercise,
|
excercise,
|
||||||
@ -295,7 +295,7 @@ export default function PatientForm({ type }: Props) {
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
const handleFormSection8Data = (
|
const handleOtherDetailsFormData = (
|
||||||
familyHistory: string | undefined,
|
familyHistory: string | undefined,
|
||||||
sleep: string | undefined,
|
sleep: string | undefined,
|
||||||
pillow: string | undefined,
|
pillow: string | undefined,
|
||||||
@ -304,7 +304,7 @@ export default function PatientForm({ type }: Props) {
|
|||||||
pregnancy: string | undefined,
|
pregnancy: string | undefined,
|
||||||
menstralCycle: any
|
menstralCycle: any
|
||||||
) => {
|
) => {
|
||||||
setSection8Data({
|
setOtherDetails({
|
||||||
familyHistory,
|
familyHistory,
|
||||||
sleep,
|
sleep,
|
||||||
pillow,
|
pillow,
|
||||||
@ -318,14 +318,14 @@ export default function PatientForm({ type }: Props) {
|
|||||||
const handleSubmit = () => {
|
const handleSubmit = () => {
|
||||||
const saved = JSON.parse(localStorage.getItem('entry') || '{}');
|
const saved = JSON.parse(localStorage.getItem('entry') || '{}');
|
||||||
const newPatientData = {
|
const newPatientData = {
|
||||||
personalInformation: section1Data,
|
personalInformation: personalInformation,
|
||||||
familyInformation: section2Data,
|
familyInformation: familyInformation,
|
||||||
medicalHistory: section3Data,
|
medicalHistory: medicalHistory,
|
||||||
injuryDetails: section4Data,
|
injuryDetails: injuryDetails,
|
||||||
pastTreatment: section5Data,
|
pastTreatment: pastTreatment,
|
||||||
systemReviewQuestions: section6Data,
|
systemReviewQuestions: systemReviewQuestions,
|
||||||
recreationalActivities: section7Data,
|
recreationalActivities: recreationalActivities,
|
||||||
otherDetails: section8Data,
|
otherDetails: otherDetails,
|
||||||
injuryPainDetails: saved.entries,
|
injuryPainDetails: saved.entries,
|
||||||
signature: signature,
|
signature: signature,
|
||||||
};
|
};
|
||||||
@ -339,16 +339,16 @@ export default function PatientForm({ type }: Props) {
|
|||||||
localStorage.setItem('patientData', JSON.stringify(newPatientData));
|
localStorage.setItem('patientData', JSON.stringify(newPatientData));
|
||||||
|
|
||||||
if (
|
if (
|
||||||
section1Data.fullName !== '' &&
|
personalInformation.fullName !== '' &&
|
||||||
section1Data.cellPhone &&
|
personalInformation.cellPhone &&
|
||||||
/^\d{10}$/.test(section1Data.cellPhone) &&
|
/^\d{10}$/.test(personalInformation.cellPhone) &&
|
||||||
section1Data.email &&
|
personalInformation.email &&
|
||||||
/^\S+@\S+\.\S+$/.test(section1Data.email) &&
|
/^\S+@\S+\.\S+$/.test(personalInformation.email) &&
|
||||||
section1Data.age &&
|
personalInformation.age &&
|
||||||
section1Data.age !== '' &&
|
personalInformation.age !== '' &&
|
||||||
Number(section1Data.age) >= 0 &&
|
Number(personalInformation.age) >= 0 &&
|
||||||
section1Data.mailingAddress &&
|
personalInformation.mailingAddress &&
|
||||||
section1Data.mailingAddress !== ''
|
personalInformation.mailingAddress !== ''
|
||||||
) {
|
) {
|
||||||
TextFile();
|
TextFile();
|
||||||
setPatientDetailsButtonFlag(true);
|
setPatientDetailsButtonFlag(true);
|
||||||
@ -432,8 +432,8 @@ export default function PatientForm({ type }: Props) {
|
|||||||
</AccordionSummary>
|
</AccordionSummary>
|
||||||
|
|
||||||
<AccordionDetails>
|
<AccordionDetails>
|
||||||
<PersonalSection
|
<PersonalInformationForm
|
||||||
handleFormSection1Data={handleFormSection1Data}
|
handlePersonalInformationFormData={handlePersonalInformationFormData}
|
||||||
patientDataDiplay={patientData.personalInformation}
|
patientDataDiplay={patientData.personalInformation}
|
||||||
type={type}
|
type={type}
|
||||||
/>
|
/>
|
||||||
@ -454,8 +454,8 @@ export default function PatientForm({ type }: Props) {
|
|||||||
</AccordionSummary>
|
</AccordionSummary>
|
||||||
|
|
||||||
<AccordionDetails>
|
<AccordionDetails>
|
||||||
<FamilyFormSection
|
<FamilyInformationForm
|
||||||
handleFormSection2Data={handleFormSection2Data}
|
handleFamilyInformationFormData={handleFamilyInformationFormData}
|
||||||
patientDataDiplay={patientData.familyInformation}
|
patientDataDiplay={patientData.familyInformation}
|
||||||
type={type}
|
type={type}
|
||||||
/>
|
/>
|
||||||
@ -477,7 +477,7 @@ export default function PatientForm({ type }: Props) {
|
|||||||
|
|
||||||
<AccordionDetails>
|
<AccordionDetails>
|
||||||
<MedicalHistory
|
<MedicalHistory
|
||||||
handleFormSection3Data={handleFormSection3Data}
|
handleMedicalHistoryFormData={handleMedicalHistoryFormData}
|
||||||
patientDataDiplay={patientData.medicalHistory}
|
patientDataDiplay={patientData.medicalHistory}
|
||||||
type={type}
|
type={type}
|
||||||
/>
|
/>
|
||||||
@ -520,8 +520,8 @@ export default function PatientForm({ type }: Props) {
|
|||||||
</AccordionSummary>
|
</AccordionSummary>
|
||||||
|
|
||||||
<AccordionDetails>
|
<AccordionDetails>
|
||||||
<PainAnalysisSection4
|
<PainAnalysisForm
|
||||||
handleFormSection4Data={handleFormSection4Data}
|
handleInjuryDetailsFormData={handleInjuryDetailsFormData}
|
||||||
patientDataDiplay={patientData.injuryDetails}
|
patientDataDiplay={patientData.injuryDetails}
|
||||||
type={type}
|
type={type}
|
||||||
/>
|
/>
|
||||||
@ -542,8 +542,8 @@ export default function PatientForm({ type }: Props) {
|
|||||||
</AccordionSummary>
|
</AccordionSummary>
|
||||||
|
|
||||||
<AccordionDetails>
|
<AccordionDetails>
|
||||||
<PastTreatment5
|
<PastTreatmentForm
|
||||||
handleFormSection5Data={handleFormSection5Data}
|
handlePastTreatmentFormData={handlePastTreatmentFormData}
|
||||||
patientDataDiplay={patientData.pastTreatment}
|
patientDataDiplay={patientData.pastTreatment}
|
||||||
type={type}
|
type={type}
|
||||||
/>
|
/>
|
||||||
@ -564,8 +564,8 @@ export default function PatientForm({ type }: Props) {
|
|||||||
</AccordionSummary>
|
</AccordionSummary>
|
||||||
|
|
||||||
<AccordionDetails>
|
<AccordionDetails>
|
||||||
<SystemReviewSection6
|
<SystemReviewForm
|
||||||
handleFormSection6Data={handleFormSection6Data}
|
handleSystemReviewFormData={handleSystemReviewFormData}
|
||||||
patientDataDiplay={patientData.systemReviewQuestions}
|
patientDataDiplay={patientData.systemReviewQuestions}
|
||||||
type={type}
|
type={type}
|
||||||
/>
|
/>
|
||||||
@ -586,8 +586,8 @@ export default function PatientForm({ type }: Props) {
|
|||||||
</AccordionSummary>
|
</AccordionSummary>
|
||||||
|
|
||||||
<AccordionDetails>
|
<AccordionDetails>
|
||||||
<RecreationalHobbiesSection7
|
<RecreationalHobbiesForm
|
||||||
handleFormSection7Data={handleFormSection7Data}
|
handleRecreationalActivitiesFormData={handleRecreationalActivitiesFormData}
|
||||||
patientDataDiplay={patientData.recreationalActivities}
|
patientDataDiplay={patientData.recreationalActivities}
|
||||||
type={type}
|
type={type}
|
||||||
/>
|
/>
|
||||||
@ -606,8 +606,8 @@ export default function PatientForm({ type }: Props) {
|
|||||||
</AccordionSummary>
|
</AccordionSummary>
|
||||||
|
|
||||||
<AccordionDetails>
|
<AccordionDetails>
|
||||||
<OtherDetails8
|
<OtherDetailsForm
|
||||||
handleFormSection8Data={handleFormSection8Data}
|
handleOtherDetailsFormData={handleOtherDetailsFormData}
|
||||||
patientDataDiplay={patientData.otherDetails}
|
patientDataDiplay={patientData.otherDetails}
|
||||||
type={type}
|
type={type}
|
||||||
/>
|
/>
|
||||||
|
|||||||
@ -16,13 +16,13 @@ import { useEffect } from 'react';
|
|||||||
import { Patient } from '../Interface/Patient';
|
import { Patient } from '../Interface/Patient';
|
||||||
|
|
||||||
type Props = {
|
type Props = {
|
||||||
handleFormSection1Data: (patient: Patient) => void;
|
handlePersonalInformationFormData: (patient: Patient) => void;
|
||||||
patientDataDiplay: any;
|
patientDataDiplay: any;
|
||||||
type: string;
|
type: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
export default function PersonalSection({
|
export default function PersonalInformationForm({
|
||||||
handleFormSection1Data,
|
handlePersonalInformationFormData,
|
||||||
patientDataDiplay,
|
patientDataDiplay,
|
||||||
type,
|
type,
|
||||||
}: Props) {
|
}: Props) {
|
||||||
@ -51,7 +51,7 @@ export default function PersonalSection({
|
|||||||
});
|
});
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
handleFormSection1Data(patient);
|
handlePersonalInformationFormData(patient);
|
||||||
}, [patient]);
|
}, [patient]);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
@ -23,7 +23,7 @@ interface Patient {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type Props = {
|
type Props = {
|
||||||
handleFormSection7Data:(
|
handleRecreationalActivitiesFormData:(
|
||||||
hobbies: string|undefined,
|
hobbies: string|undefined,
|
||||||
educationLevel: string|undefined,
|
educationLevel: string|undefined,
|
||||||
excercise: string|undefined,
|
excercise: string|undefined,
|
||||||
@ -47,7 +47,7 @@ interface Patient {
|
|||||||
type:string;
|
type:string;
|
||||||
}
|
}
|
||||||
|
|
||||||
export default function RecreationalHobbiesSection7({handleFormSection7Data,patientDataDiplay,type}:Props){
|
export default function RecreationalHobbiesForm({handleRecreationalActivitiesFormData,patientDataDiplay,type}:Props){
|
||||||
const [patient, setPatient] = React.useState<Patient>({
|
const [patient, setPatient] = React.useState<Patient>({
|
||||||
hobbies: '',
|
hobbies: '',
|
||||||
educationLevel: '',
|
educationLevel: '',
|
||||||
@ -71,7 +71,7 @@ export default function RecreationalHobbiesSection7({handleFormSection7Data,pati
|
|||||||
|
|
||||||
|
|
||||||
useEffect(()=>{
|
useEffect(()=>{
|
||||||
handleFormSection7Data(
|
handleRecreationalActivitiesFormData(
|
||||||
patient.hobbies,
|
patient.hobbies,
|
||||||
patient.educationLevel,
|
patient.educationLevel,
|
||||||
patient.excercise,
|
patient.excercise,
|
||||||
@ -30,7 +30,7 @@ interface Patient {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type Props = {
|
type Props = {
|
||||||
handleFormSection6Data: (
|
handleSystemReviewFormData: (
|
||||||
eyes: string | undefined,
|
eyes: string | undefined,
|
||||||
IntestinesBowls: string | undefined,
|
IntestinesBowls: string | undefined,
|
||||||
jointsBones: string | undefined,
|
jointsBones: string | undefined,
|
||||||
@ -53,8 +53,8 @@ type Props = {
|
|||||||
type: string;
|
type: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
export default function SystemReviewSection6({
|
export default function SystemReviewForm({
|
||||||
handleFormSection6Data,
|
handleSystemReviewFormData,
|
||||||
patientDataDiplay,
|
patientDataDiplay,
|
||||||
type,
|
type,
|
||||||
}: Props) {
|
}: Props) {
|
||||||
@ -79,7 +79,7 @@ export default function SystemReviewSection6({
|
|||||||
});
|
});
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
handleFormSection6Data(
|
handleSystemReviewFormData(
|
||||||
patient.eyes,
|
patient.eyes,
|
||||||
patient.IntestinesBowls,
|
patient.IntestinesBowls,
|
||||||
patient.jointsBones,
|
patient.jointsBones,
|
||||||
Loading…
x
Reference in New Issue
Block a user