|
@@ -71,37 +71,47 @@
|
|
|
|
|
|
|
|
|
<insert id="insertPatientCare" parameterType="PatientDTO" useGeneratedKeys="true">
|
|
|
- INSERT
|
|
|
- INTO patient_care
|
|
|
- ( patient_name, gender, ward_number, room_number, final_clinic_date, hospitalization_date, state,
|
|
|
- center_code, jumin, patient_phone, guardian_phone, symptom_start_date, confirmation_date, disisolation_date,
|
|
|
- basal_disease_yn, drug_yn, drug_content, pregnancy_status, pregnancy_week, id, pw,
|
|
|
- create_date, update_date, create_by, update_by)
|
|
|
-
|
|
|
- VALUES ( #{patientName}, #{gender}, #{wardNumber}, #{roomNumber}, NOW(), NOW(), #{state},
|
|
|
- #{centerCode}, #{jumin}, #{patientPhone}, #{guardianPhone}, #{symptomStartDate}, #{confirmationDate}, #{disisolationDate},
|
|
|
- #{basalDiseaseYn}, #{drugYn}, #{drugContent}, #{pregnancyStatus}, #{pregnancyWeek}, #{id}, #{pw},
|
|
|
- NOW(), '', #{staffId}, '')
|
|
|
+ <selectKey keyProperty="patientIdx" resultType="int" order="AFTER">
|
|
|
+ <![CDATA[
|
|
|
+ SELECT CURRENT_VAL AS patientIdx FROM db_serial WHERE NAME = 'patient_care_ai_patient_idx';
|
|
|
+ ]]>
|
|
|
+ </selectKey>
|
|
|
+ <![CDATA[
|
|
|
+ INSERT
|
|
|
+ INTO patient_care
|
|
|
+ ( patient_name, gender, ward_number, room_number, final_clinic_date, hospitalization_date, state,
|
|
|
+ center_code, jumin, patient_phone, guardian_phone, symptom_start_date, confirmation_date, disisolation_date,
|
|
|
+ basal_disease_yn, drug_yn, drug_content, pregnancy_status, pregnancy_week, id, pw,
|
|
|
+ create_date, create_by, update_by)
|
|
|
+
|
|
|
+ VALUES ( #{patientName}, #{gender}, #{wardNumber}, #{roomNumber}, NOW(), NOW(), #{state},
|
|
|
+ #{centerCode}, #{jumin}, #{patientPhone}, #{guardianPhone}, #{symptomStartDate}, #{confirmationDate}, #{disisolationDate},
|
|
|
+ #{basalDiseaseYn}, #{drugYn}, #{drugContent}, #{pregnancyStatus}, #{pregnancyWeek}, #{id}, #{pw},
|
|
|
+ NOW(), #{createBy}, '')
|
|
|
+ ]]>
|
|
|
</insert>
|
|
|
|
|
|
- <insert id="insertPatientDiseases" parameterType="PatientDTO" useGeneratedKeys="true">
|
|
|
- INSERT
|
|
|
- INTO patient_disease
|
|
|
- ( patient_idx, high_blood_pressure_check, low_blood_pressure_check, organ_transplant_check, diabetes_check,
|
|
|
- respiratory_disease_check, immunological_disease_check, dyspnea_check, cold_fit_check, muscle_pain_check,
|
|
|
- headache_check, sore_throat_check, smell_palate_check, fatigue_check, heart_disease,
|
|
|
- liver_disease, [operation], operation_content, allergy_check, kidney_disease,
|
|
|
- cancer_check, cancer_name, etc_check, etc_content )
|
|
|
- VALUES ( #{patientIdx}, #{highBloodPressureCheck}, #{lowBloodPressureCheck}, #{organTransplantCheck}, #{diabetesCheck},
|
|
|
- #{respiratoryDiseaseCheck}, #{immunologicalDiseaseCheck}, #{dyspneaCheck}, #{coldFitCheck}, #{musclePainCheck},
|
|
|
- #{headacheCheck}, #{soreThroatCheck}, #{smellPalateCheck}, #{fatigueCheck}, #{heartDisease},
|
|
|
- #{liverDisease}, #{operation}, #{operationContent}, #{allergyCheck}, #{kidneyDisease},
|
|
|
- #{cancerCheck}, #{cancerName}, #{etcCheck}, #{etcContent} )
|
|
|
+ <insert id="insertPatientDisease" parameterType="PatientDTO" useGeneratedKeys="true">
|
|
|
+ <![CDATA[
|
|
|
+ INSERT
|
|
|
+ INTO patient_disease
|
|
|
+ ( patient_idx, high_blood_pressure_check, low_blood_pressure_check, organ_transplant_check, diabetes_check,
|
|
|
+ respiratory_disease_check, immunological_disease_check, dyspnea_check, cold_fit_check, muscle_pain_check,
|
|
|
+ headache_check, sore_throat_check, smell_palate_check, fatigue_check, heart_disease,
|
|
|
+ liver_disease, `operation`, operation_content, allergy_check, kidney_disease,
|
|
|
+ cancer_check, cancer_name, etc_check, etc_content )
|
|
|
+ VALUES ( #{patientIdx}, #{highBloodPressureCheck}, #{lowBloodPressureCheck}, #{organTransplantCheck}, #{diabetesCheck},
|
|
|
+ #{respiratoryDiseaseCheck}, #{immunologicalDiseaseCheck}, #{dyspneaCheck}, #{coldFitCheck}, #{musclePainCheck},
|
|
|
+ #{headacheCheck}, #{soreThroatCheck}, #{smellPalateCheck}, #{fatigueCheck}, #{heartDisease},
|
|
|
+ #{liverDisease}, #{operation}, #{operationContent}, #{allergyCheck}, #{kidneyDisease},
|
|
|
+ #{cancerCheck}, #{cancerName}, #{etcCheck}, #{etcContent} )
|
|
|
+ ]]>
|
|
|
</insert>
|
|
|
|
|
|
<insert id="insertPatientSymptom" parameterType="PatientDTO" useGeneratedKeys="true">
|
|
|
+ <![CDATA[
|
|
|
INSERT
|
|
|
- INTO patient_symptom
|
|
|
+ INTO patient_symptom
|
|
|
( patient_idx, fever_check, cough_check, colic, cold_fit_check, sputum_check,
|
|
|
ocin_check, fever_right, fever_left, fatigue_check, etc_check, etc_content,
|
|
|
chest_pain, nose_check, vomiting_check, muscle_pain_check, sore_throat_check, diarrhea_check,
|
|
@@ -110,6 +120,7 @@
|
|
|
VALUES ( #{patientIdx}, #{feverCheck}, #{coughCheck}, #{colic}, #{coldFitCheck}, #{sputumCheck},
|
|
|
#{ocinCheck}, #{feverRight}, #{feverLeft}, #{fatigueCheck}, #{etcCheck}, #{etcContent},
|
|
|
#{chestPain}, #{noseCheck}, #{vomitingCheck}, #{musclePainCheck}, #{soreThroatCheck}, #{diarrheaCheck},
|
|
|
- #{headacheCheck}, #{dyspneaCheck}, #{pulseRate}, #{respirationRate}, #{bloodPressureLevel}, #{oxygenSaturation )
|
|
|
+ #{headacheCheck}, #{dyspneaCheck}, #{pulseRate}, #{respirationRate}, #{bloodPressureLevel}, #{oxygenSaturation} )
|
|
|
+ ]]>
|
|
|
</insert>
|
|
|
</mapper>
|