info.jsp 48 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338
  1. <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
  2. <%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"%>
  3. <%@ taglib prefix="form" uri="http://www.springframework.org/tags/form"%>
  4. <%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
  5. <jsp:include page="${data._INCLUDE}/header.jsp"></jsp:include>
  6. <link rel="stylesheet" href="/resources/bower_components/mdi/css/materialdesignicons.min.css">
  7. <script src="/resources/bower_components/moment/moment.min.js"></script>
  8. <script src="https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.9.4/Chart.min.js"></script>
  9. <script>
  10. var PHR_VALUE_DEFAULT = {
  11. TEMPERATURE: {
  12. VALUE: 36.5,
  13. MIN: 20,
  14. MAX: 50
  15. },
  16. BLOOD_PRESSURE_SYSTOLIC: {
  17. VALUE: 120,
  18. MIN: 50,
  19. MAX: 250
  20. },
  21. BLOOD_PRESSURE_DIASTOLIC: {
  22. VALUE: 80,
  23. MIN: 20,
  24. MAX: 160
  25. },
  26. OXYGEN_SATURATION: {
  27. VALUE: 95,
  28. MIN: 60,
  29. MAX: 100
  30. },
  31. PULSE_RATE: {
  32. VALUE: 65,
  33. MIN: 30,
  34. MAX: 200
  35. },
  36. BLOOD_SUGAR: {
  37. VALUE: 120,
  38. MIN: 10,
  39. MAX: 600
  40. }
  41. }
  42. function ajaxErrorHandler(request, status, error){
  43. if (request.status === 0) {
  44. alert('Not connect.\n Verify Network.');
  45. }
  46. else if (request.status == 400) {
  47. alert('Server understood the request, but request content was invalid. [400]' + '\n\n' + request.responseText);
  48. }
  49. else if (request.status == 401) {
  50. alert('Unauthorized access. [401]' + '\n\n' + request.responseText);
  51. }
  52. else if (request.status == 403) {
  53. alert('Forbidden resource can not be accessed. [403]' + '\n\n' + request.responseText);
  54. }
  55. else if (request.status == 404) {
  56. alert('Requested page not found. [404]' + '\n\n' + request.responseText);
  57. }
  58. else if (request.status == 500) {
  59. alert('Internal server error. [500]' + '\n\n' + request.responseText);
  60. }
  61. else if (request.status == 503) {
  62. alert('Service unavailable. [503]' + '\n\n' + request.responseText);
  63. }
  64. else if (status === 'parsererror') {
  65. alert('Requested JSON parse failed. [Failed]' + '\n\n' + request.responseText);
  66. }
  67. else if (status === 'timeout') {
  68. alert('Time out error. [Timeout]' + '\n\n' + request.responseText);
  69. }
  70. else if (status === 'abort') {
  71. alert('Ajax request aborted. [Aborted]' + '\n\n' + request.responseText);
  72. }
  73. else {
  74. alert('Uncaught Error.' + '\n\n' + request.responseText);
  75. }
  76. }
  77. function gridDateFormatter(date) {
  78. return moment(date).format("YYYY-MM-DD HH:mm:ss");
  79. }
  80. function chartDateFormatter(date) {
  81. return moment(date).format("MM-DD HH:mm:ss");
  82. }
  83. /*
  84. * 비대면 진료 시작
  85. */
  86. function nonFaceStart() {
  87. getAjax("/patient/nonFaceStart", $("#hiddenForm").serialize(), function ( result ) {
  88. $("#nonface").append('<input type="hidden" name="member_name" value="'+result.member_name+'" />');
  89. $("#nonface").append('<input type="hidden" name="member_id" value="'+result.member_id+'" />');
  90. $("#nonface").append('<input type="hidden" name="room_id" value="'+result.room_id+'" />');
  91. $("#nonface").append('<input type="hidden" name="hashData" value="'+result.hashData+'">');
  92. $("#nonface").append('<input type="hidden" name="token" value="'+result.token+'">');
  93. $("#nonface").append('<input type="hidden" name="api_key" value="'+result.api_key+'">');
  94. $("#nonface").append('<input type="hidden" name="classify" value="d">');
  95. var gsWin = window.open('about:blank','nonface');
  96. var frm =document.nonface;
  97. frm.target ="nonface";
  98. frm.method ="post";
  99. frm.submit();
  100. window.location.reload();
  101. }, function(){
  102. }, function(){
  103. });
  104. }
  105. /*
  106. * 건강정보이력 탭 처리
  107. */
  108. function checkValidForPhrData(phrType, phrValue) {
  109. var errorMessage = null;
  110. var errorMessagePrefix = null;
  111. var phrValueDefault = null;
  112. if (phrType === "temperature") {
  113. errorMessagePrefix = "체온을";
  114. phrValueDefault = PHR_VALUE_DEFAULT.TEMPERATURE;
  115. }
  116. else if (phrType === "bloodPressureSystolic") {
  117. errorMessagePrefix = "수축기 혈압을";
  118. phrValueDefault = PHR_VALUE_DEFAULT.BLOOD_PRESSURE_SYSTOLIC;
  119. }
  120. else if (phrType === "bloodPressureDiastolic") {
  121. errorMessagePrefix = "이완기 혈압을";
  122. phrValueDefault = PHR_VALUE_DEFAULT.BLOOD_PRESSURE_DIASTOLIC;
  123. }
  124. else if (phrType === "oxygenSaturation") {
  125. errorMessagePrefix = "산소포화도를";
  126. phrValueDefault = PHR_VALUE_DEFAULT.OXYGEN_SATURATION;
  127. }
  128. else if (phrType === "pulseRate") {
  129. errorMessagePrefix = "맥박을";
  130. phrValueDefault = PHR_VALUE_DEFAULT.PULSE_RATE;
  131. }
  132. else if (phrType === "bloodSugar") {
  133. errorMessagePrefix = "혈당을";
  134. phrValueDefault = PHR_VALUE_DEFAULT.BLOOD_SUGAR;
  135. }
  136. // 널 체크, 숫자 체크, 최대/최소 체크
  137. if (!phrValue || phrValue.length === 0) {
  138. errorMessage = errorMessagePrefix+" 입력해 주세요.";
  139. }
  140. else if (isNaN(phrValue)) {
  141. errorMessage = errorMessagePrefix+" 숫자로 입력해 주세요.";
  142. }
  143. else if (phrValue < phrValueDefault.MIN || phrValue > phrValueDefault.MAX) {
  144. errorMessage = errorMessagePrefix+" "+phrValueDefault.MIN+"~"+phrValueDefault.MAX+" 범위 내로 입력해 주세요.";
  145. }
  146. return errorMessage;
  147. }
  148. function handlePhrData() {
  149. var phrType = $("#phrTypeSelect option:selected").val();
  150. var phrValue = "";
  151. if (phrType === "bloodPressure") {
  152. phrValueSystolic = $("#phrValueSystolic").val();
  153. phrValueDiastolic = $("#phrValueDiastolic").val();
  154. // 유효성 체크
  155. var errorMessage = checkValidForPhrData("bloodPressureSystolic", phrValueSystolic);
  156. if (errorMessage) {
  157. alert(errorMessage);
  158. $("#phrValueSystolic").focus();
  159. return;
  160. }
  161. errorMessage = checkValidForPhrData("bloodPressureDiastolic", phrValueDiastolic);
  162. if (errorMessage) {
  163. alert(errorMessage);
  164. $("#phrValueDiastolic").focus();
  165. return;
  166. }
  167. // 저장 진행
  168. createPhrData(${patientIdx}, "bloodPressure", phrValueSystolic, phrValueDiastolic);
  169. $("#phrValueSystolic").val(PHR_VALUE_DEFAULT.BLOOD_PRESSURE_SYSTOLIC.VALUE);
  170. $("#phrValueDiastolic").val(PHR_VALUE_DEFAULT.BLOOD_PRESSURE_DIASTOLIC.VALUE);
  171. }
  172. else {
  173. phrValue = $("#phrValue").val();
  174. // 유효성 체크
  175. var errorMessage = checkValidForPhrData(phrType, phrValue);
  176. if (errorMessage) {
  177. alert(errorMessage);
  178. $("#phrValue").focus();
  179. return;
  180. }
  181. // 저장 진행
  182. createPhrData(${patientIdx}, phrType, phrValue);
  183. var phrValueDefault = "";
  184. if (phrType === "temperature") {
  185. phrValueDefault = PHR_VALUE_DEFAULT.TEMPERATURE;
  186. }
  187. else if (phrType === "oxygenSaturation") {
  188. phrValueDefault = PHR_VALUE_DEFAULT.OXYGEN_SATURATION;
  189. }
  190. else if (phrType === "pulseRate") {
  191. phrValueDefault = PHR_VALUE_DEFAULT.PULSE_RATE;
  192. }
  193. else if (phrType === "bloodSugar") {
  194. phrValueDefault = PHR_VALUE_DEFAULT.BLOOD_SUGAR;
  195. }
  196. $("#phrValue").val(phrValueDefault);
  197. }
  198. $("#defaultModalPrimary_1").modal("hide");
  199. }
  200. function createPhrData(patientIdx, phrType, phrValue, phrValue2) {
  201. $.ajax({
  202. url : "./api/phrData",
  203. data : {patientIdx: patientIdx, phrType: phrType, phrValue: phrValue, phrValue2: phrValue2, recordedById: "${data._SES_ID}", recordedByName: "${data._SES_NAME}"},
  204. method : "POST",
  205. dataType : "json",
  206. success : function( datas ){
  207. retrievePhrData();
  208. },
  209. error : ajaxErrorHandler
  210. }).done( function(){
  211. });
  212. }
  213. function retrievePhrData() {
  214. var phrType = $("#phrTypeSelect option:selected").val();
  215. var phrName = $("#phrTypeSelect option:selected").text();
  216. var ignoreCache = moment().unix();
  217. var params = {patientIdx: ${patientIdx}, phrType: phrType, ignoreCache:ignoreCache};
  218. $.ajax({
  219. url : "./api/phrDatas",
  220. data : params,
  221. method : "GET",
  222. dataType : "json",
  223. success : function( datas ){
  224. if (phrType==="bloodPressure") {
  225. drawBPChart(datas);
  226. }
  227. else {
  228. drawPhrChart(datas, phrName);
  229. }
  230. var html = "<thead><tr>";
  231. html += "<th>기록일시</th>";
  232. html += "<th>"+phrName+"</th>";
  233. html += "<th>기록자</th>";
  234. html += "</tr></thead>";
  235. html += "<tbody>";
  236. var contents = "<tr><td colspan=3>데이터가 없습니다.</td></tr>" ;
  237. if (datas.length > 0) {
  238. contents = "";
  239. datas.forEach(function(d) {
  240. var danger = d.isWarning ? "text-danger" : "";
  241. var row = "";
  242. row += "<tr>";
  243. row += "<td>" + gridDateFormatter(d.createDate) + "</td>";
  244. if (phrType==="bloodPressure") {
  245. row += "<td><span class='"+danger+"'>" + (isNaN(parseInt(d.phrValue)) ? "--" : parseInt(d.phrValue)) + " / " + (isNaN(parseInt(d.phrValue2)) ? "--" : parseInt(d.phrValue2)) + "</span></td>";
  246. }
  247. else if (phrType==="temperature") {
  248. row += "<td><span class='"+danger+"'>" + parseFloat(d.phrValue).toFixed(1) + "</span></td>";
  249. }
  250. else {
  251. row += "<td><span class='"+danger+"'>" + parseInt(d.phrValue) + "</span></td>";
  252. }
  253. row += "<td>" + d.recordedByName + "</td>";
  254. row += "</tr>";
  255. contents = row + contents;
  256. });
  257. };
  258. html += contents;
  259. html += "</tbody>";
  260. $("#phrDataTable").html(html);
  261. },
  262. error : ajaxErrorHandler
  263. }).done( function(){
  264. });
  265. }
  266. var myChart = null;
  267. function drawPhrChart(data, dataName) {
  268. if (myChart) {
  269. myChart.destroy();
  270. myChart = null;
  271. }
  272. var xDatas = [];
  273. var yDatas = [];
  274. data.forEach(function(d) {
  275. var t = chartDateFormatter(d.createDate);
  276. xDatas.push(t);
  277. yDatas.push(d.phrValue);
  278. });
  279. var ctx = document.getElementById("phrChart").getContext('2d');
  280. myChart = new Chart(ctx, {
  281. type: 'line',
  282. data: {
  283. labels: xDatas,
  284. datasets: [{
  285. label: dataName,
  286. data: yDatas,
  287. fill: false,
  288. backgroundColor: '#fff',
  289. borderColor: '#5b7dff',
  290. borderWidth: 2,
  291. }]
  292. },
  293. options: {
  294. maintainAspectRatio: false,
  295. }
  296. });
  297. }
  298. function drawBPChart(data) {
  299. if (myChart) {
  300. myChart.destroy();
  301. myChart = null;
  302. }
  303. var xDatas = [];
  304. var y1Datas = [];
  305. var y2Datas = [];
  306. data.forEach(function(d) {
  307. var t = chartDateFormatter(d.createDate);
  308. xDatas.push(t);
  309. y1Datas.push(d.phrValue);
  310. y2Datas.push(d.phrValue2);
  311. });
  312. var ctx = document.getElementById("phrChart").getContext('2d');
  313. myChart = new Chart(ctx, {
  314. type: 'line',
  315. data: {
  316. labels: xDatas,
  317. datasets: [{
  318. label: "수축기 혈압",
  319. data: y1Datas,
  320. fill: false,
  321. backgroundColor: '#fff',
  322. borderColor: '#5b7dff',
  323. borderWidth: 2,
  324. },{
  325. label: "이완기 혈압",
  326. data: y2Datas,
  327. fill: false,
  328. backgroundColor: '#fff',
  329. borderColor: 'rgb(255, 99, 132)',
  330. borderWidth: 2,
  331. }]
  332. },
  333. options: {
  334. maintainAspectRatio: false,
  335. }
  336. });
  337. }
  338. /*
  339. * 임상증상 탭 처리
  340. */
  341. function handleSymptomData() {
  342. if ($("input:checkbox[id='etcCheck']").is(":checked") && !$("#etcContent").val().trim()) {
  343. alert("기타 증상이 체크되었습니다. 내용을 입력해 주세요.");
  344. $("#etcContent").val("");
  345. return;
  346. }
  347. var checkedCount = ($("#defaultModalPrimary_2 input[type='checkbox']:checked").length);
  348. if (checkedCount === 0) {
  349. alert("증상을 체크해 주세요.");
  350. return;
  351. }
  352. var symptomObject = {
  353. patientIdx: ${patientIdx},
  354. coughCheck: $("input:checkbox[id='coughCheck']").is(":checked") ? "Y" : "N",
  355. dyspneaCheck: $("input:checkbox[id='dyspneaCheck']").is(":checked") ? "Y" : "N",
  356. coldFitCheck: $("input:checkbox[id='coldFitCheck']").is(":checked") ? "Y" : "N",
  357. musclePainCheck: $("input:checkbox[id='musclePainCheck']").is(":checked") ? "Y" : "N",
  358. headacheCheck: $("input:checkbox[id='headacheCheck']").is(":checked") ? "Y" : "N",
  359. soreThroatCheck: $("input:checkbox[id='soreThroatCheck']").is(":checked") ? "Y" : "N",
  360. smellPalateCheck: $("input:checkbox[id='smellPalateCheck']").is(":checked") ? "Y" : "N",
  361. fatigueCheck: $("input:checkbox[id='fatigueCheck']").is(":checked") ? "Y" : "N",
  362. appetiteLossCheck: $("input:checkbox[id='appetiteLossCheck']").is(":checked") ? "Y" : "N",
  363. sputumCheck: $("input:checkbox[id='sputumCheck']").is(":checked") ? "Y" : "N",
  364. ocinCheck: $("input:checkbox[id='ocinCheck']").is(":checked") ? "Y" : "N",
  365. vomitingCheck: $("input:checkbox[id='vomitingCheck']").is(":checked") ? "Y" : "N",
  366. diarrheaCheck: $("input:checkbox[id='diarrheaCheck']").is(":checked") ? "Y" : "N",
  367. dizzinessCheck: $("input:checkbox[id='dizzinessCheck']").is(":checked") ? "Y" : "N",
  368. noseCheck: $("input:checkbox[id='noseCheck']").is(":checked") ? "Y" : "N",
  369. etcCheck: $("input:checkbox[id='etcCheck']").is(":checked") ? "Y" : "N",
  370. etcContent: $("#etcContent").val(),
  371. recordedByName: "${data._SES_NAME}",
  372. recordedById: "${data._SES_ID}",
  373. }
  374. createSymptomData(symptomObject);
  375. $("#defaultModalPrimary_2 input[type='checkbox']:checked").prop("checked", false);
  376. $("#etcContent").val("");
  377. $("#defaultModalPrimary_2").modal("hide");
  378. }
  379. function createSymptomData(symptomObject) {
  380. $.ajax({
  381. url : "./api/symptomData",
  382. data : symptomObject,
  383. method : "POST",
  384. dataType : "json",
  385. success : function( datas ){
  386. retrieveSymptomData();
  387. },
  388. error : ajaxErrorHandler
  389. }).done( function(){
  390. });
  391. }
  392. function retrieveSymptomData() {
  393. var ignoreCache = moment().unix();
  394. var params = {patientIdx: ${patientIdx}, ignoreCache:ignoreCache};
  395. $.ajax({
  396. url : "./api/symptomDatas",
  397. data : params,
  398. method : "GET",
  399. dataType : "json",
  400. success : function( datas ){
  401. var html = "<tr><td colspan=18>데이터가 없습니다.</td></tr>" ;
  402. var checkSymbol = '<i class="mdi mdi-check-bold"></i>';
  403. if (datas.length > 0) {
  404. html = "";
  405. contents = datas.forEach(function(d) {
  406. html += "<tr>";
  407. html += "<th>" + gridDateFormatter(d.createDate) + "</th>";
  408. html += "<td>" + (d.coughCheck === "Y" ? checkSymbol : "-") + "</td>";
  409. html += "<td>" + (d.dyspneaCheck === "Y" ? checkSymbol : "-") + "</td>";
  410. html += "<td>" + (d.coldFitCheck === "Y" ? checkSymbol : "-") + "</td>";
  411. html += "<td>" + (d.musclePainCheck === "Y" ? checkSymbol : "-") + "</td>";
  412. html += "<td>" + (d.headacheCheck === "Y" ? checkSymbol : "-") + "</td>";
  413. html += "<td>" + (d.soreThroatCheck === "Y" ? checkSymbol : "-") + "</td>";
  414. html += "<td>" + (d.smellPalateCheck === "Y" ? checkSymbol : "-") + "</td>";
  415. html += "<td>" + (d.fatigueCheck === "Y" ? checkSymbol : "-") + "</td>";
  416. html += "<td>" + (d.appetiteLossCheck === "Y" ? checkSymbol : "-") + "</td>";
  417. html += "<td>" + (d.sputumCheck === "Y" ? checkSymbol : "-") + "</td>";
  418. html += "<td>" + (d.ocinCheck === "Y" ? checkSymbol : "-") + "</td>";
  419. html += "<td>" + (d.vomitingCheck === "Y" ? checkSymbol : "-") + "</td>";
  420. html += "<td>" + (d.diarrheaCheck === "Y" ? checkSymbol : "-") + "</td>";
  421. html += "<td>" + (d.dizzinessCheck === "Y" ? checkSymbol : "-") + "</td>";
  422. html += "<td>" + (d.noseCheck === "Y" ? checkSymbol : "-") + "</td>";
  423. html += "<td>" + (d.etcCheck === "Y" ? d.etcContent : "-") + "</td>";
  424. html += "<td>" + d.recordedByName + "</td>";
  425. html += "</tr>";
  426. });
  427. };
  428. $("#symptomDataTable > tbody").html(html);
  429. },
  430. error : ajaxErrorHandler
  431. }).done( function(){
  432. });
  433. }
  434. /*
  435. * 메모 탭 처리
  436. */
  437. function handleMemoData() {
  438. var memoContent = $("#memoContent").val().trim();
  439. if (!memoContent) {
  440. alert("메모 내용을 입력해 주세요.");
  441. $("#memoContent").val("");
  442. return;
  443. }
  444. createMemoData(memoContent);
  445. $("#memoContent").val("");
  446. $("#defaultModalPrimaryMemo").modal("hide");
  447. }
  448. function createMemoData(memoContent) {
  449. $.ajax({
  450. url : "./api/memoData",
  451. data : {patientIdx:${patientIdx}, contents:memoContent, recordedByName:"${data._SES_NAME}", recordedById:"${data._SES_ID}"},
  452. method : "POST",
  453. dataType : "json",
  454. success : function( datas ){
  455. retrieveMemoData();
  456. },
  457. error : ajaxErrorHandler
  458. }).done( function(){
  459. });
  460. }
  461. function retrieveMemoData() {
  462. var ignoreCache = moment().unix();
  463. var params = {patientIdx: ${patientIdx}, ignoreCache:ignoreCache};
  464. $.ajax({
  465. url : "./api/memoDatas",
  466. data : params,
  467. method : "GET",
  468. dataType : "json",
  469. success : function( datas ){
  470. var html = "<tr><td colspan=3>데이터가 없습니다.</td></tr>" ;
  471. if (datas.length > 0) {
  472. html = "";
  473. contents = datas.forEach(function(d) {
  474. html += "<tr>";
  475. html += "<td>" + gridDateFormatter(d.createDate) + "</td>";
  476. html += "<td><pre>" + d.contents + "</pre></td>";
  477. html += "<td>" + d.recordedByName + "</td>";
  478. html += "</tr>";
  479. });
  480. };
  481. $("#memoDataTable > tbody").html(html);
  482. },
  483. error : ajaxErrorHandler
  484. }).done( function(){
  485. });
  486. }
  487. function gotoList() {
  488. var url = "./state";
  489. var refererSearch = '<c:out value="${refererSearch}" />';
  490. var refererPage = '<c:out value="${refererPage}" />';
  491. if (refererSearch !== "" && refererPage !== "") {
  492. url += "?searchText=" + encodeURIComponent(refererSearch) + "&page=" + refererPage;
  493. }
  494. else if (refererSearch !== "") {
  495. url += "?searchText=" + encodeURIComponent(refererSearch);
  496. }
  497. else if (refererPage !== "") {
  498. url += "?page=" + refererPage;
  499. }
  500. location.href = url;
  501. }
  502. $(document).ready(function() {
  503. // 최초 로드시 phrData 체온이 로드됨. 해당 데이터 차트 그려줌.
  504. var datas = [];
  505. <c:forEach var="phr" items="${phrItems}" varStatus="status">
  506. datas.push({createDate: "${phr.createDate}", phrValue: "${phr.phrValue}"});
  507. </c:forEach>
  508. drawPhrChart(datas, "체온");
  509. // 상단 환자 정보 영역 토글 이벤트
  510. $('.toggle .card-header').click(function () {
  511. $('.toggle .card-header a.toggleBtn').toggleClass('active');
  512. $('.toggle .user-info').toggleClass('active');
  513. })
  514. // 탭 클릭 이벤트
  515. $(document).on('click','.tab-item',function(){
  516. var targetTab = $(this).attr('tabindex');
  517. $('.tab-item').removeClass('active');
  518. $('.tab').removeClass('in');
  519. $(this).addClass('active');
  520. $(targetTab).addClass('in');
  521. if (targetTab==="#tabPhr") {
  522. retrievePhrData();
  523. }
  524. else if (targetTab==="#tabSymptom") {
  525. retrieveSymptomData();
  526. }
  527. else if (targetTab==="#tabMemo") {
  528. retrieveMemoData();
  529. }
  530. });
  531. // phrData 기록 추가 클릭 이벤트
  532. $(document).on('click','[data-target="#defaultModalPrimary_1"]',function(){
  533. var selectData = $('#phrTypeSelect').find('option:selected').val();
  534. var healthInfoHTML = '';
  535. var phrValueDefault = null;
  536. if(selectData == 'temperature'){
  537. phrValueDefault = PHR_VALUE_DEFAULT.TEMPERATURE;
  538. healthInfoHTML += '<th>체온</th>';
  539. healthInfoHTML += '<td>';
  540. healthInfoHTML += ' <div class="form-group mb-xl-0">';
  541. healthInfoHTML += ' <input id="phrValue" class="form-control" type="number" placeholder="체온 입력" min="'+phrValueDefault.MIN+'" max="'+phrValueDefault.MAX+'" value="'+phrValueDefault.VALUE+'" step="0.1">';
  542. healthInfoHTML += ' </div>';
  543. healthInfoHTML += '</td>';
  544. }
  545. else if(selectData == 'bloodPressure'){
  546. phrValueDefault1 = PHR_VALUE_DEFAULT.BLOOD_PRESSURE_SYSTOLIC;
  547. phrValueDefault2 = PHR_VALUE_DEFAULT.BLOOD_PRESSURE_DIASTOLIC;
  548. healthInfoHTML += '<th>혈압</th>';
  549. healthInfoHTML += '<td>';
  550. healthInfoHTML += ' <div class="form-group mb-xl-0">';
  551. healthInfoHTML += ' <input id="phrValueSystolic" class="form-control mb-2" type="number" placeholder="수축기 혈압 입력" min="'+phrValueDefault1.MIN+'" max="'+phrValueDefault1.MAX+'" value="'+phrValueDefault1.VALUE+'">';
  552. healthInfoHTML += ' <input id="phrValueDiastolic" class="form-control mb-2" type="number" placeholder="이완기 혈압 입력" min="'+phrValueDefault2.MIN+'" max="'+phrValueDefault2.MAX+'" value="'+phrValueDefault2.VALUE+'">';
  553. healthInfoHTML += ' </div>';
  554. healthInfoHTML += '</td>';
  555. }
  556. else if(selectData == 'pulseRate'){
  557. phrValueDefault = PHR_VALUE_DEFAULT.PULSE_RATE;
  558. healthInfoHTML += '<th>맥박</th>';
  559. healthInfoHTML += '<td>';
  560. healthInfoHTML += ' <div class="form-group mb-xl-0">';
  561. healthInfoHTML += ' <input id="phrValue" class="form-control" type="number" placeholder="맥박 입력"min="'+phrValueDefault.MIN+'" max="'+phrValueDefault.MAX+'" value="'+phrValueDefault.VALUE+'">';
  562. healthInfoHTML += ' </div>';
  563. healthInfoHTML += '</td>';
  564. }
  565. else if(selectData == 'oxygenSaturation'){
  566. phrValueDefault = PHR_VALUE_DEFAULT.OXYGEN_SATURATION;
  567. healthInfoHTML += '<th>산소포화도</th>';
  568. healthInfoHTML += '<td>';
  569. healthInfoHTML += ' <div class="form-group mb-xl-0">';
  570. healthInfoHTML += ' <input id="phrValue" class="form-control" type="number" placeholder="산소포화도 입력" min="'+phrValueDefault.MIN+'" max="'+phrValueDefault.MAX+'" value="'+phrValueDefault.VALUE+'">';
  571. healthInfoHTML += ' </div>';
  572. healthInfoHTML += '</td>';
  573. }
  574. else if(selectData == 'bloodSugar'){
  575. phrValueDefault = PHR_VALUE_DEFAULT.BLOOD_SUGAR;
  576. healthInfoHTML += '<th>혈당</th>';
  577. healthInfoHTML += '<td>';
  578. healthInfoHTML += ' <div class="form-group mb-xl-0">';
  579. healthInfoHTML += ' <input id="phrValue" class="form-control" type="number" placeholder="혈당 입력" min="'+phrValueDefault.MIN+'" max="'+phrValueDefault.MAX+'" value="'+phrValueDefault.VALUE+'"">';
  580. healthInfoHTML += ' </div>';
  581. healthInfoHTML += '</td>';
  582. }
  583. else {
  584. }
  585. $('#healthInfo').html(healthInfoHTML);
  586. setTimeout(function (){
  587. $('#healthInfo').find('.form-group input:first-child').focus();
  588. }, 500);
  589. });
  590. // 임상증상 추가 클릭 이벤트
  591. $(document).on('click','[data-target="#defaultModalPrimary_2"]',function(){
  592. var symptomInfoHtml = '';
  593. symptomInfoHtml += ' <th>임상증상</th>';
  594. symptomInfoHtml += ' <td>';
  595. symptomInfoHtml += ' <div class="form-group mb-xl-0">';
  596. symptomInfoHtml += ' <label class="form-check form-check-inline">';
  597. symptomInfoHtml += ' <input id="coughCheck" class="form-check-input" type="checkbox">';
  598. symptomInfoHtml += ' <span class="form-check-label">';
  599. symptomInfoHtml += ' 기침';
  600. symptomInfoHtml += ' </span>';
  601. symptomInfoHtml += ' </label>';
  602. symptomInfoHtml += ' <label class="form-check form-check-inline">';
  603. symptomInfoHtml += ' <input id="dyspneaCheck" class="form-check-input" type="checkbox">';
  604. symptomInfoHtml += ' <span class="form-check-label">';
  605. symptomInfoHtml += ' 호흡곤란';
  606. symptomInfoHtml += ' </span>';
  607. symptomInfoHtml += ' </label>';
  608. symptomInfoHtml += ' <label class="form-check form-check-inline">';
  609. symptomInfoHtml += ' <input id="coldFitCheck" class="form-check-input" type="checkbox">';
  610. symptomInfoHtml += ' <span class="form-check-label">';
  611. symptomInfoHtml += ' 오한';
  612. symptomInfoHtml += ' </span>';
  613. symptomInfoHtml += ' </label>';
  614. symptomInfoHtml += ' <label class="form-check form-check-inline">';
  615. symptomInfoHtml += ' <input id="musclePainCheck" class="form-check-input" type="checkbox">';
  616. symptomInfoHtml += ' <span class="form-check-label">';
  617. symptomInfoHtml += ' 근육통';
  618. symptomInfoHtml += ' </span>';
  619. symptomInfoHtml += ' </label>';
  620. symptomInfoHtml += ' <label class="form-check form-check-inline">';
  621. symptomInfoHtml += ' <input id="headacheCheck" class="form-check-input" type="checkbox">';
  622. symptomInfoHtml += ' <span class="form-check-label">';
  623. symptomInfoHtml += ' 두통';
  624. symptomInfoHtml += ' </span>';
  625. symptomInfoHtml += ' </label>';
  626. symptomInfoHtml += ' <label class="form-check form-check-inline">';
  627. symptomInfoHtml += ' <input id="soreThroatCheck" class="form-check-input" type="checkbox">';
  628. symptomInfoHtml += ' <span class="form-check-label">';
  629. symptomInfoHtml += ' 인후통';
  630. symptomInfoHtml += ' </span>';
  631. symptomInfoHtml += ' </label>';
  632. symptomInfoHtml += ' <label class="form-check form-check-inline">';
  633. symptomInfoHtml += ' <input id="smellPalateCheck" class="form-check-input" type="checkbox">';
  634. symptomInfoHtml += ' <span class="form-check-label">';
  635. symptomInfoHtml += ' 후각/미각 손실';
  636. symptomInfoHtml += ' </span>';
  637. symptomInfoHtml += ' </label>';
  638. symptomInfoHtml += ' <label class="form-check form-check-inline">';
  639. symptomInfoHtml += ' <input id="fatigueCheck" class="form-check-input" type="checkbox">';
  640. symptomInfoHtml += ' <span class="form-check-label">';
  641. symptomInfoHtml += ' 피로';
  642. symptomInfoHtml += ' </span>';
  643. symptomInfoHtml += ' </label>';
  644. symptomInfoHtml += ' <label class="form-check form-check-inline">';
  645. symptomInfoHtml += ' <input id="appetiteLossCheck" class="form-check-input" type="checkbox">';
  646. symptomInfoHtml += ' <span class="form-check-label">';
  647. symptomInfoHtml += ' 식욕감소';
  648. symptomInfoHtml += ' </span>';
  649. symptomInfoHtml += ' </label>';
  650. symptomInfoHtml += ' <label class="form-check form-check-inline">';
  651. symptomInfoHtml += ' <input id="sputumCheck" class="form-check-input" type="checkbox">';
  652. symptomInfoHtml += ' <span class="form-check-label">';
  653. symptomInfoHtml += ' 가래';
  654. symptomInfoHtml += ' </span>';
  655. symptomInfoHtml += ' </label>';
  656. symptomInfoHtml += ' <label class="form-check form-check-inline">';
  657. symptomInfoHtml += ' <input id="ocinCheck" class="form-check-input" type="checkbox">';
  658. symptomInfoHtml += ' <span class="form-check-label">';
  659. symptomInfoHtml += ' 오심';
  660. symptomInfoHtml += ' </span>';
  661. symptomInfoHtml += ' </label>';
  662. symptomInfoHtml += ' <label class="form-check form-check-inline">';
  663. symptomInfoHtml += ' <input id="vomitingCheck" class="form-check-input" type="checkbox">';
  664. symptomInfoHtml += ' <span class="form-check-label">';
  665. symptomInfoHtml += ' 구토';
  666. symptomInfoHtml += ' </span>';
  667. symptomInfoHtml += ' </label>';
  668. symptomInfoHtml += ' <label class="form-check form-check-inline">';
  669. symptomInfoHtml += ' <input id="diarrheaCheck" class="form-check-input" type="checkbox">';
  670. symptomInfoHtml += ' <span class="form-check-label">';
  671. symptomInfoHtml += ' 설사';
  672. symptomInfoHtml += ' </span>';
  673. symptomInfoHtml += ' </label>';
  674. symptomInfoHtml += ' <label class="form-check form-check-inline">';
  675. symptomInfoHtml += ' <input id="dizzinessCheck" class="form-check-input" type="checkbox">';
  676. symptomInfoHtml += ' <span class="form-check-label">';
  677. symptomInfoHtml += ' 어지러움';
  678. symptomInfoHtml += ' </span>';
  679. symptomInfoHtml += ' </label>';
  680. symptomInfoHtml += ' <label class="form-check form-check-inline">';
  681. symptomInfoHtml += ' <input id="noseCheck" class="form-check-input" type="checkbox">';
  682. symptomInfoHtml += ' <span class="form-check-label">';
  683. symptomInfoHtml += ' 콧물/코막힘';
  684. symptomInfoHtml += ' </span>';
  685. symptomInfoHtml += ' </label>';
  686. symptomInfoHtml += ' <label class="form-check form-check-inline">';
  687. symptomInfoHtml += ' <input id="etcCheck" class="form-check-input" type="checkbox">';
  688. symptomInfoHtml += ' <span class="form-check-label">';
  689. symptomInfoHtml += ' 기타 ( <input type="text" id="etcContent" class="form-control form-control-sm w150" value="" placeholder="증상 내용"> )';
  690. symptomInfoHtml += ' </span>';
  691. symptomInfoHtml += ' </label>';
  692. symptomInfoHtml += ' </div>';
  693. symptomInfoHtml += ' </td>';
  694. $('#symptomInfo').html(symptomInfoHtml);
  695. });
  696. // 의료진 메모 추가 클릭 이벤트
  697. $(document).on('click','[data-target="#defaultModalPrimaryMemo"]',function(){
  698. var memoInfoHTML = '';
  699. memoInfoHTML += '<th>내용</th>';
  700. memoInfoHTML += '<td>';
  701. memoInfoHTML += ' <div class="form-row">';
  702. memoInfoHTML += ' <textarea id="memoContent" class="form-control" rows="15" placeholder="내용을 입력하세요"></textarea>';
  703. memoInfoHTML += ' </div>';
  704. memoInfoHTML += '</td>';
  705. $('#memoInfo').html(memoInfoHTML);
  706. setTimeout(function (){
  707. $('#memoInfo').find('.form-row textarea').focus();
  708. }, 500);
  709. });
  710. });
  711. </script>
  712. </head>
  713. <body>
  714. <form id="nonface" name="nonface" action="https://lemon.medihere.com/app/vc">
  715. </form>
  716. <div class="modal fade" id="legendGuide" tabindex="-1" role="dialog" aria-hidden="true">
  717. <div class="modal-dialog modal-sm" role="document">
  718. <div class="modal-content">
  719. <div class="modal-header">
  720. <h5 class="modal-title">알람 표시 기준 안내</h5>
  721. <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span> </button>
  722. </div>
  723. <div class="modal-body m-1">
  724. <h4>생체측정 알람 표시 기준</h4>
  725. <ul class="legend">
  726. <li class="row fever">
  727. <div class="col-lg-4">체온</div>
  728. <div class="col-lg-8">37.5 이상</div>
  729. </li>
  730. <li class="row bloodPressure">
  731. <div class="col-lg-4">고혈압</div>
  732. <div class="col-lg-8">수축기 149 이상<br>이완기 99 이상</div>
  733. </li>
  734. <li class="row bloodPressure">
  735. <div class="col-lg-4">저혈압</div>
  736. <div class="col-lg-8">수축기 90 이하<br>이완기 60 이하</div>
  737. </li>
  738. <li class="row oxygen">
  739. <div class="col-lg-4">산소포화도</div>
  740. <div class="col-lg-8">94% 이하</div>
  741. </li>
  742. <li class="row pulse">
  743. <div class="col-lg-4">맥박</div>
  744. <div class="col-lg-8">최저 55 이하<br>최고 110 이상</div>
  745. </li>
  746. <li class="row sugar">
  747. <div class="col-lg-4">고혈당</div>
  748. <div class="col-lg-8">200 이상</div>
  749. </li>
  750. <li class="row sugar">
  751. <div class="col-lg-4">저혈당</div>
  752. <div class="col-lg-8">70 이하 </div>
  753. </li>
  754. </ul>
  755. </div>
  756. <div class="modal-footer">
  757. <button type="button" class="btn btn-primary" data-dismiss="modal">닫기</button>
  758. </div>
  759. </div>
  760. </div>
  761. </div>
  762. <div class="modal fade" id="defaultModalPrimary_1" tabindex="-1" role="dialog" aria-hidden="true">
  763. <div class="modal-dialog modal-sm" role="document">
  764. <div class="modal-content">
  765. <div class="modal-header">
  766. <h5 class="modal-title">건강정보 입력</h5>
  767. <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span
  768. aria-hidden="true">&times;</span> </button>
  769. </div>
  770. <div class="modal-body m-3">
  771. <table class="table mobile-table">
  772. <colgroup>
  773. <col style="width: 30%">
  774. <col style="width: 70%">
  775. </colgroup>
  776. <tr>
  777. <th>기록자</th>
  778. <td>
  779. <div class="form-group mb-xl-0">
  780. <input class="form-control" type="text" value="${data._SES_NAME}" readonly>
  781. </div>
  782. </td>
  783. </tr>
  784. <tr id="healthInfo">
  785. <!-- 컨텐츠 동적 생성 -->
  786. </tr>
  787. </table>
  788. </div>
  789. <div class="modal-footer">
  790. <button type="button" class="btn btn-outline-primary" data-dismiss="modal">취소</button>
  791. <button type="button" class="btn btn-primary" onclick="handlePhrData()">등록</button>
  792. </div>
  793. </div>
  794. </div>
  795. </div>
  796. <div class="modal fade" id="defaultModalPrimary_2" tabindex="-1" role="dialog" aria-hidden="true">
  797. <div class="modal-dialog" role="document">
  798. <div class="modal-content">
  799. <div class="modal-header">
  800. <h5 class="modal-title">임상증상 입력</h5>
  801. <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span
  802. aria-hidden="true">&times;</span> </button>
  803. </div>
  804. <div class="modal-body m-3">
  805. <table class="table mobile-table">
  806. <colgroup>
  807. <col style="width: 30%">
  808. <col style="width: 70%">
  809. </colgroup>
  810. <tr>
  811. <th>기록자</th>
  812. <td>
  813. <div class="form-group mb-xl-0">
  814. <input class="form-control" type="text" value="${data._SES_NAME}" readonly>
  815. </div>
  816. </td>
  817. </tr>
  818. <tr id="symptomInfo">
  819. <!-- 컨텐츠 동적 생성 -->
  820. </tr>
  821. </table>
  822. </div>
  823. <div class="modal-footer">
  824. <button type="button" class="btn btn-outline-primary" data-dismiss="modal">취소</button>
  825. <button type="button" class="btn btn-primary" onclick="handleSymptomData()">등록</button>
  826. </div>
  827. </div>
  828. </div>
  829. </div>
  830. <div class="modal fade" id="defaultModalPrimaryMemo" tabindex="-1" role="dialog" aria-hidden="true">
  831. <div class="modal-dialog" role="document">
  832. <div class="modal-content">
  833. <div class="modal-header">
  834. <h5 class="modal-title">의료진 메모 입력</h5>
  835. <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span
  836. aria-hidden="true">&times;</span> </button>
  837. </div>
  838. <div class="modal-body m-3">
  839. <table class="table mobile-table">
  840. <colgroup>
  841. <col style="width: 20%">
  842. <col style="width: 80%">
  843. </colgroup>
  844. <tr>
  845. <th>작성자</th>
  846. <td>
  847. <div class="form-row">
  848. <input type="text" name="" class="form-control" placeholder="이름을 입력하세요" value="${data._SES_NAME}" readonly>
  849. </div>
  850. </td>
  851. </tr>
  852. <tr id="memoInfo">
  853. <!-- 컨텐츠 동적 생성 -->
  854. </tr>
  855. </table>
  856. </div>
  857. <div class="modal-footer">
  858. <button type="button" class="btn btn-outline-primary" data-dismiss="modal">취소</button>
  859. <button type="button" class="btn btn-primary" onclick="handleMemoData()">등록</button>
  860. </div>
  861. </div>
  862. </div>
  863. </div>
  864. <div class="wrapper">
  865. <jsp:include page="${data._INCLUDE}/sidebar.jsp"></jsp:include>
  866. <div class="main">
  867. <jsp:include page="${data._INCLUDE}/top.jsp"></jsp:include>
  868. <main class="content">
  869. <form id="hiddenForm">
  870. <input type="hidden" id="pId" name="pId" value="<c:out value="${info.id}" />">
  871. <input type="hidden" id="pName" name="pName" value="<c:out value="${info.patientName}" />">
  872. <input type="hidden" id="roomId" name="roomId" value="<c:out value="${info.roomNumber}" />">
  873. </form>
  874. <div class="container-fluid p-0">
  875. <div class="row">
  876. <div class="col-12 col-lg-6">
  877. <h1 class="h3 mb-3">건강정보 조회</h1>
  878. </div>
  879. <div class="col-12 col-lg-6 text-right">
  880. <nav aria-label="breadcrumb">
  881. <ol class="breadcrumb">
  882. <li class="breadcrumb-item"><a href="javscript:;">Home</a></li>
  883. <li class="breadcrumb-item">진료관리</li>
  884. <li class="breadcrumb-item active">건강정보 조회</li>
  885. </ol>
  886. </nav>
  887. </div>
  888. </div>
  889. <div class="row">
  890. <div class="col-12">
  891. <div class="card toggle">
  892. <div class="card-header">
  893. <h1 class="h4"><c:out value="${info.patientName}" /> 환자 기본정보</h1>
  894. <a href="#" class="toggleBtn">메뉴</a>
  895. </div>
  896. <div class="card-body">
  897. <table class="table mobile-table user-info">
  898. <colgroup>
  899. <col style="width: 15%">
  900. <col style="width: 35%">
  901. <col style="width: 15%">
  902. <col style="width: 35%">
  903. </colgroup>
  904. <tr>
  905. <th>치료센터</th>
  906. <td><c:out value="${info.centerName}" /></td>
  907. <th>입소일시</th>
  908. <td colspan="2">
  909. <c:out value="${info.hospitalizationDate}" />
  910. </td>
  911. </tr>
  912. <tr>
  913. <th>병동 번호</th>
  914. <td>
  915. <c:out value="${info.wardNumber}동 ${info.roomNumber}호" />
  916. </td>
  917. <th>이름</th>
  918. <td>
  919. <c:out value="${info.patientName}" />
  920. </td>
  921. </tr>
  922. <tr>
  923. <th>성별</th>
  924. <td>
  925. <c:if test="${info.gender eq 'M'}">
  926. </c:if>
  927. <c:if test="${info.gender ne 'M'}">
  928. </c:if>
  929. </td>
  930. <th>생년월일</th>
  931. <td>
  932. <c:out value="${info.jumin}" />
  933. </td>
  934. </tr>
  935. <tr>
  936. <th>연락처</th>
  937. <td>
  938. <c:out value="${info.patientPhone}" />
  939. </td>
  940. <th>보호자 연락처</th>
  941. <td>
  942. <c:out value="${info.guardianPhone}" />
  943. </td>
  944. </tr>
  945. <tr>
  946. <th>증상시작일</th>
  947. <td>
  948. <c:out value="${info.symptomStartDate}" />
  949. </td>
  950. <th>확진일</th>
  951. <td>
  952. <c:out value="${info.confirmationDate}" />
  953. </td>
  954. </tr>
  955. <tr>
  956. <th>격리해제 예정일</th>
  957. <td>
  958. <c:out value="${info.disisolationDate}" />
  959. </td>
  960. <th>상태</th>
  961. <td>
  962. <c:if test="${info.state eq 'H'}">
  963. 입소
  964. </c:if>
  965. <c:if test="${info.state eq 'D'}">
  966. 퇴소
  967. </c:if>
  968. <c:if test="${info.state eq 'T'}">
  969. 지정병원 이송
  970. </c:if>
  971. <c:if test="${info.state eq 'E'}">
  972. 기타
  973. </c:if>
  974. </td>
  975. </tr>
  976. <tr>
  977. <th>최근 약복용<br />(최근 24시간 이내)</th>
  978. <td>
  979. <c:choose>
  980. <c:when test="${info.drugYn eq 'Y'}">
  981. 복용 (<c:out value="${info.drugContent}" />)
  982. </c:when>
  983. <c:otherwise>
  984. 미복용
  985. </c:otherwise>
  986. </c:choose>
  987. </td>
  988. <th>임신</th>
  989. <td>
  990. <c:choose>
  991. <c:when test="${info.pregnancyStatus eq 'N'}">
  992. </c:when>
  993. <c:otherwise>
  994. 유 (<c:out value="${info.pregnancyWeek}주차" />)
  995. </c:otherwise>
  996. </c:choose>
  997. </td>
  998. </tr>
  999. <tr>
  1000. <th rowspan="2">기저질환 여부</th>
  1001. <td colspan="3">
  1002. <c:choose>
  1003. <c:when test="${info.basalDiseaseYn eq 'Y'}">
  1004. </c:when>
  1005. <c:otherwise>
  1006. </c:otherwise>
  1007. </c:choose>
  1008. </td>
  1009. </tr>
  1010. <tr>
  1011. <td colspan="3">
  1012. <%-- <c:if test="${info.highBloodPressureCheck eq 'Y'}">, 고혈압</c:if> --%>
  1013. <%-- <c:if test="${info.lowBloodPressureCheck eq 'Y'}">, 저혈압</c:if> --%>
  1014. <%-- <c:if test="${info.organTransplantCheck eq 'Y'}">, 장기이식(신장, 간 등)</c:if> --%>
  1015. <%-- <c:if test="${info.diabetesCheck eq 'Y'}">, 당뇨</c:if> --%>
  1016. <%-- <c:if test="${info.respiratoryDiseaseCheck eq 'Y'}">, 호흡기질환</c:if> --%>
  1017. <%-- <c:if test="${info.immunologicalDiseaseCheck eq 'Y'}">, 면역질환(류마티스 등)</c:if> --%>
  1018. <%-- <c:if test="${info.heartDisease eq 'Y'}">, 심장질환</c:if> --%>
  1019. <%-- <c:if test="${info.liverDisease eq 'Y'}">, 간질환</c:if> --%>
  1020. <%-- <c:if test="${info.operation eq 'Y'}">, 수술(<c:out value="${info.operationContent}" />)</c:if> --%>
  1021. <%-- <c:if test="${info.allergyCheck eq 'Y'}">, 알레르기</c:if> --%>
  1022. <%-- <c:if test="${info.kidneyDisease eq 'Y'}">, 신장질환</c:if> --%>
  1023. <%-- <c:if test="${info.cancerCheck eq 'Y'}">, 암(<c:out value="${info.cancerName}" />)</c:if> --%>
  1024. <%-- <c:if test="${info.ectCheckDisease eq 'Y'}">, 기타(<c:out value="${info.etcContentDisease}" />)</c:if> --%>
  1025. <c:out value="${disease}" />
  1026. </td>
  1027. </tr>
  1028. <tr>
  1029. <th>현재 증상<br />(입소 당시)</th>
  1030. <td colspan="3">
  1031. <%-- <c:if test="${info.feverCheck eq 'Y'}">, 열감(열나는느낌)</c:if> --%>
  1032. <%-- <c:if test="${info.coughCheck eq 'Y'}">, 기침</c:if> --%>
  1033. <%-- <c:if test="${info.colic eq 'Y'}">, 복통(배아픔)</c:if> --%>
  1034. <%-- <c:if test="${info.coldFitCheck eq 'Y'}">, 오한(추운 느낌)</c:if> --%>
  1035. <%-- <c:if test="${info.sputumCheck eq 'Y'}">, 가래</c:if> --%>
  1036. <%-- <c:if test="${info.ocinCheck eq 'Y'}">, 오심(구역질)</c:if> --%>
  1037. <%-- <c:if test="${info.chestPain eq 'Y'}">, 흉통</c:if> --%>
  1038. <%-- <c:if test="${info.noseCheck eq 'Y'}">, 콧물 또는 코 막힘</c:if> --%>
  1039. <%-- <c:if test="${info.vomitingCheck eq 'Y'}">, 구토</c:if> --%>
  1040. <%-- <c:if test="${info.musclePainCheck eq 'Y'}">, 근육통(몸살)</c:if> --%>
  1041. <%-- <c:if test="${info.soreThroatCheck eq 'Y'}">, 인후통(목 아픔)</c:if> --%>
  1042. <%-- <c:if test="${info.diarrheaCheck eq 'Y'}">, 설사</c:if> --%>
  1043. <%-- <c:if test="${info.headacheCheck eq 'Y'}">, 두통(머리아픔)</c:if> --%>
  1044. <%-- <c:if test="${info.dyspneaCheck eq 'Y'}">, 호흡곤란(숨가쁨)</c:if> --%>
  1045. <%-- <c:if test="${info.fatigueCheck eq 'Y'}">, 권태감(피곤함)</c:if> --%>
  1046. <%-- <c:if test="${info.ectCheckSymptom eq 'Y'}">, 기타(<c:out value="${info.etcContentSymptom}" />)</c:if> --%>
  1047. <c:out value="${symptom}" />
  1048. </td>
  1049. </tr>
  1050. <tr>
  1051. <th>
  1052. 체온
  1053. </th>
  1054. <td>
  1055. <c:out value="우측 ${info.feverRight}℃ / 좌측 ${info.feverRight}℃" />
  1056. </td>
  1057. <th>
  1058. 맥박수
  1059. </th>
  1060. <td>
  1061. <c:out value="${info.pulseRate} 회/분" />
  1062. </td>
  1063. </tr>
  1064. <tr>
  1065. <th>
  1066. 호흡수
  1067. </th>
  1068. <td>
  1069. <c:out value="${info.respirationRate} 회/분" />
  1070. </td>
  1071. <th>
  1072. 혈압
  1073. </th>
  1074. <td>
  1075. <c:out value="수축기 ${info.bloodPressureLevelCon} mmHg / 이완기 ${info.bloodPressureLevelRel} mmHg" />
  1076. </td>
  1077. </tr>
  1078. <tr>
  1079. <th>
  1080. 산소포화도
  1081. </th>
  1082. <td colspan="3">
  1083. <c:out value="${info.oxygenSaturation} %" />
  1084. </td>
  1085. </tr>
  1086. </table>
  1087. <div class="row mt-3">
  1088. <div class="col-12">
  1089. <div class="text-right">
  1090. <button class="btn btn-outline-success" onclick="nonFaceStart();">비대면 진료</button>
  1091. <button class="btn btn-primary" onclick="gotoList()">목록</button>
  1092. </div>
  1093. </div>
  1094. </div>
  1095. </div>
  1096. </div>
  1097. </div>
  1098. </div>
  1099. <div class="row">
  1100. <div class="col-12">
  1101. <div class="card">
  1102. <ul class="tab-nav">
  1103. <li class="tab-item active" tabindex="#tabPhr">건강정보이력</li>
  1104. <li class="tab-item" tabindex="#tabSymptom">임상증상</li>
  1105. <li class="tab-item" tabindex="#tabMemo">의료진 메모</li>
  1106. </ul>
  1107. <div id="tabPhr" class="tab in">
  1108. <div class="card-header">
  1109. <h1 class="h4">
  1110. - 건강정보 조회 <label> <select class="custom-select ml-1 form-control" id=phrTypeSelect name="inputState" onchange="retrievePhrData()">
  1111. <option value="temperature" selected>체온</option>
  1112. <option value="bloodPressure">혈압</option>
  1113. <option value="oxygenSaturation">산소포화도</option>
  1114. <option value="pulseRate">맥박</option>
  1115. <option value="bloodSugar">혈당</option>
  1116. </select>
  1117. </label> <label class="ml-1">
  1118. <button type="button" class="btn btn-primary ml-2" data-toggle="modal" data-target="#defaultModalPrimary_1">기록추가</button>
  1119. </label>
  1120. </h1>
  1121. </div>
  1122. <div class="card-body">
  1123. <div class="graph-area mb-4" style="height:300px;">
  1124. <canvas id="phrChart"></canvas>
  1125. </div>
  1126. <h1 class="h4 text-right"><span class="small showLegend ml-2" data-toggle="modal" data-target="#legendGuide"><i class="mdi mdi-comment-question-outline"></i> 알람 표시 기준</span></h1>
  1127. <div class="table-responsive">
  1128. <table id="phrDataTable" class="table data-table text-center">
  1129. <thead>
  1130. <tr>
  1131. <th>기록일시</th>
  1132. <th>체온</th>
  1133. <th>기록자</th>
  1134. </tr>
  1135. </thead>
  1136. <tbody>
  1137. <c:choose>
  1138. <c:when test="${phrTotal > 0}">
  1139. <c:forEach var="i" begin="1" end="${phrTotal}">
  1140. <tr>
  1141. <td><c:out value="${phrItems[phrTotal-i].createDateFormatted}" /></td>
  1142. <td><span class="${phrItems[phrTotal-i].isWarning ? 'text-danger' : ''}"><c:out value="${phrItems[phrTotal-i].phrValue}" /></span></td>
  1143. <td><c:out value="${phrItems[phrTotal-i].recordedByName}" /></td>
  1144. </tr>
  1145. </c:forEach>
  1146. </c:when>
  1147. <c:otherwise>
  1148. <tr>
  1149. <td colspan=3>데이터가 없습니다.</td>
  1150. </tr>
  1151. </c:otherwise>
  1152. </c:choose>
  1153. </tbody>
  1154. </table>
  1155. </div>
  1156. </div>
  1157. </div>
  1158. <div id="tabSymptom" class="tab">
  1159. <div class="card-header">
  1160. <h1 class="h4">
  1161. - 임상증상 <label class="ml-1">
  1162. <button type="button" class="btn btn-primary ml-2" data-toggle="modal" data-target="#defaultModalPrimary_2">증상추가</button>
  1163. </label>
  1164. </h1>
  1165. </div>
  1166. <div class="card-body">
  1167. <div class="table-responsive">
  1168. <table id="symptomDataTable" class="table data-table text-center">
  1169. <thead>
  1170. <tr>
  1171. <th>기록일시</th>
  1172. <th>기침</th>
  1173. <th>호흡곤란</th>
  1174. <th>오한</th>
  1175. <th>근육통</th>
  1176. <th>두통</th>
  1177. <th>인후통</th>
  1178. <th>후각/미각 손실</th>
  1179. <th>피로</th>
  1180. <th>식욕감소</th>
  1181. <th>가래</th>
  1182. <th>오심</th>
  1183. <th>구토</th>
  1184. <th>설사</th>
  1185. <th>어지러움</th>
  1186. <th>콧물/코막힘</th>
  1187. <th>기타증상</th>
  1188. <th>기록자</th>
  1189. </tr>
  1190. </thead>
  1191. <tbody>
  1192. </tbody>
  1193. </table>
  1194. </div>
  1195. </div>
  1196. </div>
  1197. <div id="tabMemo" class="tab">
  1198. <div class="card-header">
  1199. <h1 class="h4">
  1200. - 의료진 메모
  1201. <button type="button" class="btn btn-primary ml-2" data-toggle="modal" data-target="#defaultModalPrimaryMemo">메모추가</button>
  1202. </h1>
  1203. </div>
  1204. <div class="card-body">
  1205. <div class="table-responsive">
  1206. <table id="memoDataTable" class="table data-table text-center">
  1207. <thead>
  1208. <tr>
  1209. <th>기록일시</th>
  1210. <th>내용</th>
  1211. <th>기록자</th>
  1212. </tr>
  1213. </thead>
  1214. <tbody>
  1215. </tbody>
  1216. </table>
  1217. </div>
  1218. </div>
  1219. </div>
  1220. </div>
  1221. </div>
  1222. </div>
  1223. </div>
  1224. </main>
  1225. <jsp:include page="${data._INCLUDE}/footer.jsp"></jsp:include>
  1226. </div>
  1227. </div>
  1228. </body>
  1229. </html>