|
@@ -201,28 +201,45 @@ function handlePhrData() {
|
|
|
}
|
|
|
// 수축기 F 이완기 F
|
|
|
else if (errorMessage1 && errorMessage2) {
|
|
|
- // 맥박 F
|
|
|
- if (errorMessage3) {
|
|
|
- alert(errorMessage1);
|
|
|
- $("#phrValueSystolic").focus();
|
|
|
- return;
|
|
|
+
|
|
|
+ // 미입력 에러
|
|
|
+ if ((!phrValueSystolic || phrValueSystolic.length === 0) && (!phrValueDiastolic || phrValueDiastolic.length === 0)) {
|
|
|
+ // 맥박 F
|
|
|
+ if (errorMessage3) {
|
|
|
+ alert(errorMessage3);
|
|
|
+ $("#phrValuePulseRate").focus();
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ // 맥박 S
|
|
|
+ else {
|
|
|
+ // 맥박만 저장
|
|
|
+ createPhrData(mPatientIdx, "pulseRate", recordedDate, phrValuePulseRate);
|
|
|
+ }
|
|
|
}
|
|
|
- // 맥박 S
|
|
|
+ // min max 오류
|
|
|
else {
|
|
|
- // 맥박만 저장
|
|
|
- createPhrData(mPatientIdx, "pulseRate", recordedDate, phrValuePulseRate);
|
|
|
+ if (errorMessage1) {
|
|
|
+ alert(errorMessage1);
|
|
|
+ $("#phrValueSystolic").focus();
|
|
|
+ return;
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
// 수축기 S 이완기 S
|
|
|
else if (!errorMessage1 && !errorMessage2) {
|
|
|
// 맥박 F
|
|
|
if (errorMessage3) {
|
|
|
- // alert(errorMessage3);
|
|
|
- // $("#phrValuePulseRate").focus();
|
|
|
- // return;
|
|
|
-
|
|
|
- // 혈압만 저장
|
|
|
- createPhrData(mPatientIdx, "bloodPressure", recordedDate, phrValueSystolic, phrValueDiastolic);
|
|
|
+ // 미입력 오류
|
|
|
+ if (!phrValuePulseRate || phrValuePulseRate.length === 0) {
|
|
|
+ // 혈압만 저장
|
|
|
+ createPhrData(mPatientIdx, "bloodPressure", recordedDate, phrValueSystolic, phrValueDiastolic);
|
|
|
+ }
|
|
|
+ // min max 오류
|
|
|
+ else {
|
|
|
+ alert(errorMessage3);
|
|
|
+ $("#phrValuePulseRate").focus();
|
|
|
+ return;
|
|
|
+ }
|
|
|
}
|
|
|
// 맥박 S
|
|
|
else {
|