SMMNW03100_간호정보조사.xrw 120 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492
  1. <?xml version="1.0" encoding="EUC-KR"?>
  2. <?xml-stylesheet type="text/css" href="../../../com/commonweb/css/common.css" ?>
  3. <xhtml:html xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.w3.org/2002/01/xforms" xmlns:ev="http://www.w3.org/2001/xml-events">
  4. <xhtml:head>
  5. <xhtml:title>병동간호정보조사</xhtml:title>
  6. <model id="model1">
  7. <instance id="instance1">
  8. <root xmlns="">
  9. <main>
  10. <wardrecinfo>
  11. <bfrecddtm/>
  12. <bfrecdd/>
  13. <bfrectm/>
  14. <bfrecuser/>
  15. <recdd/>
  16. <rectm/>
  17. <recuser/>
  18. <patinfo/>
  19. <infooffer/>
  20. <signno/>
  21. <room/>
  22. <patnm/>
  23. <sex/>
  24. <age/>
  25. <pid/>
  26. <fstrgstrnm/>
  27. <fstrgstdt/>
  28. </wardrecinfo>
  29. </main>
  30. <send>
  31. <req/>
  32. <patgnrlinfo/>
  33. <wardrecinfo/>
  34. <bodyases/>
  35. </send>
  36. <init>
  37. <mlist>
  38. <M0068>
  39. <cdid/>
  40. <cdnm/>
  41. </M0068>
  42. <M0069>
  43. <cdid/>
  44. <cdnm/>
  45. </M0069>
  46. <M0070>
  47. <cdid/>
  48. <cdnm/>
  49. </M0070>
  50. <M0072>
  51. <cdid/>
  52. <cdnm/>
  53. </M0072>
  54. <M0073>
  55. <cdid/>
  56. <cdnm/>
  57. </M0073>
  58. <M0074>
  59. <cdid/>
  60. <cdnm/>
  61. </M0074>
  62. <M0634>
  63. <cdid/>
  64. <cdnm/>
  65. </M0634>
  66. </mlist>
  67. <cond>
  68. <unitflag>ward</unitflag>
  69. </cond>
  70. </init>
  71. <hidden>
  72. <paminfo/>
  73. <histinfo/>
  74. <wardrecinfo/>
  75. <bodyases>
  76. <mfmdstatinfo/>
  77. <shpaininfo/>
  78. <resorgninfo/>
  79. <digorgninfo/>
  80. <nvesysinfo/>
  81. <info/>
  82. </bodyases>
  83. <errecinfo/>
  84. <rsltinfo/>
  85. </hidden>
  86. <codeinfo/>
  87. <signinfo>
  88. <signno/>
  89. </signinfo>
  90. <code>
  91. <codeinfo/>
  92. </code>
  93. </root>
  94. </instance>
  95. <script type="javascript" ev:event="xforms-ready">
  96. <![CDATA[
  97. //debugger;
  98. fGetCmbList();
  99. fInit();
  100. if(fGetInitRecInfo()) {
  101. fGetIndtInfo(); //현재수진이력의 입원시간을 가져온다
  102. fInitEvent("init");
  103. model.refresh();
  104. //---------(20101029) 경북대
  105. if (fEssentialBackColor != "") {
  106. //간호정보조사지 필수입력사항 backcolor 지정
  107. ipt_infooffer.attribute("background-color") = fEssentialBackColor;
  108. // 일반정보 필수입력사항 backcolor 지정-> 각자 화면에서 ready시 호출함
  109. //import1.window.javaScript.fessential();
  110. // 신체사정 필수입력사항 backcolor 지정-> 각자 화면에서 ready시 호출함
  111. //import4.window.javaScript.fessential();
  112. // 교육요구 필수입력사항 backcolor 지정
  113. if (model.getValue("/root/codeinfo/codeinfo/codelist[cdgrupid ='172']/cdid") =="Y") {
  114. ivw_edurec.window.javaScript.fessential();
  115. }
  116. }
  117. //---------(20101029) 경북대
  118. //20110308 이선경 (경북대) 신체사정에 쓰일 구분자추가
  119. model.makeValue("/root/init/cond/unitflag", "ward");
  120. } else {
  121. window.close();
  122. }
  123. ]]>
  124. </script>
  125. <script type="javascript">
  126. <![CDATA[
  127. var allgInsYN = "Y";
  128. var NoneInspCode = "-1"; //측정불가코드값
  129. //현재수진이력의 입원시간을 가져온다
  130. function fGetIndtInfo() {
  131. var indd = model.getValue("/root/temp/cond/list/indd");
  132. var recpkspec = (model.getValue("/root/main/wardrecinfo/bfrecddtm")).split("|"); //이전기록일시
  133. var bfrecindd = recpkspec[1]; //이전기록일시 입원일자
  134. if(indd != bfrecindd) {
  135. ipt_indt.value = model.getValue("/root/temp/cond/list/careinrmtm"); //입원시간
  136. }
  137. }
  138. function fGetCmbList() {
  139. //성가병원 기관코드 조회_20090626_SMY
  140. model.removeNodeset("/root/init/mlist");
  141. model.makeNode("/root/init/mlist");
  142. fGetNursHardCdInfo("'077','172','177','U31','W25'", getCurrentDate()); //CareCom.js
  143. zbcfGetCodeList( new Array ( "M0068" //직업
  144. ,"M0069" //교육정도
  145. ,"M0070" //종교
  146. ,"M0151" //결혼상태
  147. ,"M0072" //관계
  148. ,"M0073" //부위
  149. ,"M0376" //혈액형
  150. ,"M0075" //의식상태
  151. ,"M0088" //생존여부
  152. ,"M0090" //알러지
  153. ,"M0098" //동반자
  154. ,"M0100" //지남력
  155. ,"M0102" //요흔
  156. ,"M0103" //부착기구
  157. ,"M0104" //소변색깔
  158. ,"M0105" //소변증상
  159. ,"M0106" //대변색깔
  160. ,"M0107" //대변종류
  161. ,"M0109" //동공빛반사여부
  162. ,"M0110" //동공수치
  163. ,"M0411" //영적요구
  164. ,"M0210" //입원방법
  165. ,"M0418" //입원경로
  166. ,"M0375" //체온부위
  167. ,"M0368" //가족병력내역
  168. ,"M0532" //과거병력내역_20090406_SMY추가
  169. ,"M0634" //통증사정내역
  170. )
  171. , new Array ( "/root/init/mlist" //직업
  172. ,"/root/init/mlist" //교육정도
  173. ,"/root/init/mlist" //종교
  174. ,"/root/init/mlist" //결혼상태
  175. ,"/root/init/mlist" //관계
  176. ,"/root/init/mlist" //부위
  177. ,"/root/init/mlist" //혈액형
  178. ,"/root/init/mlist" //의식상태
  179. ,"/root/init/mlist" //생존여부
  180. ,"/root/init/mlist" //알러지
  181. ,"/root/init/mlist" //동반자
  182. ,"/root/init/mlist" //지남력
  183. ,"/root/init/mlist" //요흔
  184. ,"/root/init/mlist" //부착기구
  185. ,"/root/init/mlist" //소변색깔
  186. ,"/root/init/mlist" //소변증상
  187. ,"/root/init/mlist" //대변색깔
  188. ,"/root/init/mlist" //대변종류
  189. ,"/root/init/mlist" //동공빛반사여부
  190. ,"/root/init/mlist" //동공수치
  191. ,"/root/init/mlist" //영적요구
  192. ,"/root/init/mlist" //입원방법
  193. ,"/root/init/mlist" //입원경로
  194. ,"/root/init/mlist" //체온부위
  195. ,"/root/init/mlist" //가족병력내역
  196. ,"/root/init/mlist" //과거병력내역
  197. ,"/root/init/mlist" //통증사정내역
  198. )
  199. );
  200. model.refresh();
  201. }
  202. function fInitEvent(pFlag) {
  203. fInitEventGnrlInfo();
  204. fInitEventBodyAses(pFlag);
  205. }
  206. //화면 로딩시
  207. function fInit(){
  208. //원목에서 화면 사용할 경우 인증저장 버튼 비활성화
  209. if(getScreenMenuParameter() == "4050400000" || opener.javascript.getParameter("deptcd") == "4050400000"){ //원목 메뉴파라미터
  210. btn_signsave.disabled = true;
  211. }else{
  212. btn_signsave.disabled = false;
  213. }
  214. model.copyNode("/root/hidden/histinfo", "/root/main/histinfo");
  215. model.copyNode("/root/hidden/wardrecinfo", "/root/main/wardrecinfo");
  216. model.makeValue("/root/hidden/histinfo/pasthistinfo/pasthist/pasthistinclyn", "1");
  217. model.makeValue("/root/hidden/histinfo/famyhistinfo/famyhist/famyhistinclyn", "1");
  218. model.makeValue("/root/hidden/histinfo/inhistinfo/inhist/inhistinclyn", "1");
  219. model.makeValue("/root/hidden/histinfo/ophistinfo/ophist/ophistinclyn", "1");
  220. //model.makeValue("/root/hidden/wardrecinfo/rectmedistatinfo/rectmedistat/rectmedistatinfoinclyn", "1");
  221. model.makeValue("/root/hidden/histinfo/allghistinfo/allghist/allghistinclyn", "1");
  222. model.makeValue("/root/hidden/histinfo/vacnhistinfo/vacnhist/vacnhistinfoinclyn", "1");
  223. model.makeValue("/root/hidden/histinfo/smokinfo/smok/smokinclyn", "1");
  224. model.makeValue("/root/hidden/histinfo/drunkinfo/drunk/drunkinclyn", "1");
  225. model.makeValue("/root/hidden/histinfo/gustofoodinfo/gustofood/gustofoodinclyn", "1");
  226. model.makeValue("/root/hidden/histinfo/tnsseffcinfo/tnsseffc/tnsseffcinclyn", "1");
  227. model.copyNode("/root/hidden/bodyases/mfmdstatinfo", "/root/main/wardrecinfo/mfmdstatinfo");
  228. model.makeValue("/root/hidden/bodyases/mfmdstatinfo/mfmdstat/mfmdstatinfoinclyn", "1");
  229. //alert(instance1.selectNodesXml("/root/main/wardrecinfo/mfmdstatinfo"));
  230. //alert(instance1.selectNodesXml("/root/hidden/bodyases/mfmdstatinfo"));
  231. model.copyNode("/root/hidden/bodyases/shpaininfo", "/root/main/wardrecinfo/shpaininfo");
  232. model.makeValue("/root/hidden/bodyases/shpaininfo/shpain/shpaininfoinclyn", "1");
  233. model.copyNode("/root/hidden/bodyases/resorgninfo", "/root/main/wardrecinfo/resorgninfo");
  234. model.makeValue("/root/hidden/bodyases/resorgninfo/resorgn/resorgninfoinclyn", "1");
  235. model.copyNode("/root/hidden/bodyases/digorgninfo", "/root/main/wardrecinfo/digorgninfo");
  236. model.makeValue("/root/hidden/bodyases/digorgninfo/digorgn/digorgninfoinclyn", "1");
  237. model.copyNode("/root/hidden/bodyases/nvesysinfo", "/root/main/wardrecinfo/nvesysinfo");
  238. model.makeValue("/root/hidden/bodyases/nvesysinfo/nvesys/nvesysinfoinclyn", "1");
  239. model.makeNode("/root/hidden/bodyases/skinsectinfo");
  240. model.copyNode("/root/hidden/bodyases/skinsectinfo", "/root/main/wardrecinfo/skinsectinfo");
  241. model.makeValue("/root/hidden/bodyases/skinsectinfo/skinsect/skincolorinfoinclyn", "1");
  242. model.makeValue("/root/hidden/bodyases/skinsectinfo/skinsect/skinstatinfoinclyn", "1");
  243. // 15.06.18 - 비뇨기계, 대변 추가
  244. // 15.08.25 - 비뇨기계, 대변 주석 처리
  245. //model.copyNode("/root/hidden/bodyases/stoolinfo", "/root/main/wardrecinfo/stoolinfo");
  246. //model.makeValue("/root/hidden/bodyases/stoolinfo/stool/stoolinfoinclyn", "1");
  247. //model.copyNode("/root/hidden/bodyases/uriorgninfo", "/root/main/wardrecinfo/uriorgninfo");
  248. //model.makeValue("/root/hidden/bodyases/uriorgninfo/uriorgn/urineinfoinclyn", "1");
  249. // 15.08.25 - 비뇨기계, 대변 주석 처리
  250. //alert(instance1.selectNodesXml("/root/main/wardrecinfo/stoolinfo"));
  251. //alert(instance1.selectNodesXml("/root/hidden/bodyases/stoolinfo"));
  252. //alert(instance1.selectNodesXml("/root/main/wardrecinfo/uriorgninfo"));
  253. //alert(instance1.selectNodesXml("/root/hidden/bodyases/uriorgninfo"));
  254. model.makeNode("/root/temp/cond/list");
  255. getPatientInfoDetails("/root/temp/cond/list");
  256. //각 화면 상단에 선택된 환자 정보 display 필요함. (병실-성명-S/A-등록번호)
  257. var pid;
  258. var room;
  259. var patnm;
  260. var sex;
  261. var age;
  262. var instcd;
  263. var orddeptcd;
  264. var indd;
  265. room = model.getValue("/root/temp/cond/list/roomcd");
  266. patnm = model.getValue("/root/temp/cond/list/hngnm2");
  267. sex = model.getValue("/root/temp/cond/list/sex");
  268. age = model.getValue("/root/temp/cond/list/age");
  269. pid = model.getValue("/root/temp/cond/list/pid");
  270. indd = model.getValue("/root/temp/cond/list/indd");
  271. instcd = model.getValue("/root/temp/cond/list/instcd");
  272. orddeptcd = model.getValue("/root/temp/cond/list/orddeptcd");
  273. cretno = model.getValue("/root/temp/cond/list/cretno");
  274. ioflag = model.getValue("/root/temp/cond/list/ioflag");
  275. /*
  276. model.setValue("/root/main/wardrecinfo/room", room);
  277. model.setValue("/root/main/wardrecinfo/patnm", patnm);
  278. model.setValue("/root/main/wardrecinfo/sex", sex);
  279. model.setValue("/root/main/wardrecinfo/age", age);
  280. model.setValue("/root/main/wardrecinfo/pid", pid);
  281. */
  282. model.makeValue("/root/main/wardrecinfo/room", room);
  283. model.makeValue("/root/main/wardrecinfo/patnm", patnm);
  284. model.makeValue("/root/main/wardrecinfo/sex", sex);
  285. model.makeValue("/root/main/wardrecinfo/age", age);
  286. model.makeValue("/root/main/wardrecinfo/pid", pid);
  287. var scrnid =getScreenID();
  288. var param = "pid▦orddd▦cretno▦ordtype▦scrnid"
  289. +"▩" + pid+"▦" +indd+"▦"+cretno+"▦"+ioflag+"▦"+scrnid+"▩";
  290. fEnrCareComRecInfo_SPMNZ002(param, "/root/main/enrcarecomrecinfo"); //타 간호정보조사지기록 유무확인 model.refresh();
  291. model.refresh();
  292. }
  293. //간호정보조사지 조회
  294. function fGetInitRecInfo() {
  295. /*
  296. model.copyNode("/root/hidden/histinfo", "/root/main/histinfo");
  297. model.setValue("/root/hidden/histinfo/pasthistinfo/pasthist/pasthistinclyn", "1");
  298. model.setValue("/root/hidden/histinfo/famyhistinfo/famyhist/famyhistinclyn", "1");
  299. model.setValue("/root/hidden/histinfo/inhistinfo/inhist/inhistinclyn", "1");
  300. model.setValue("/root/hidden/histinfo/ophistinfo/ophist/ophistinclyn", "1");
  301. model.setValue("/root/hidden/histinfo/rectmedistatinfo/rectmedistat/rectmedistatinfoinclyn", "1");
  302. model.setValue("/root/hidden/histinfo/allghistinfo/allghist/allghistinclyn", "1");
  303. model.setValue("/root/hidden/histinfo/vacnhistinfo/vacnhist/vacnhistinfoinclyn", "1");
  304. model.setValue("/root/hidden/histinfo/smokinfo/smok/smokinclyn", "1");
  305. model.setValue("/root/hidden/histinfo/drunkinfo/drunk/drunkinclyn", "1");
  306. model.setValue("/root/hidden/histinfo/gustofoodinfo/gustofood/gustofoodinclyn", "1");
  307. model.setValue("/root/hidden/histinfo/tnsseffcinfo/tnsseffc/tnsseffcinclyn", "1");
  308. model.copyNode("/root/hidden/bodyases/mfmdstatinfo", "/root/main/wardrecinfo/mfmdstatinfo");
  309. model.setValue("/root/hidden/bodyases/mfmdstatinfo/mfmdstat/mfmdstatinfoinclyn", "1");
  310. model.copyNode("/root/hidden/bodyases/shpaininfo", "/root/main/wardrecinfo/shpaininfo");
  311. model.setValue("/root/hidden/bodyases/shpaininfo/shpain/shpaininfoinclyn", "1");
  312. model.copyNode("/root/hidden/bodyases/resorgninfo", "/root/main/wardrecinfo/resorgninfo");
  313. model.setValue("/root/hidden/bodyases/resorgninfo/resorgn/resorgninfoinclyn", "1");
  314. model.copyNode("/root/hidden/bodyases/digorgninfo", "/root/main/wardrecinfo/digorgninfo");
  315. model.setValue("/root/hidden/bodyases/digorgninfo/digorgn/digorgninfoinclyn", "1");
  316. model.copyNode("/root/hidden/bodyases/nvesysinfo", "/root/main/wardrecinfo/nvesysinfo");
  317. model.setValue("/root/hidden/bodyases/nvesysinfo/nvesys/nvesysinfoinclyn", "1");
  318. model.makeNode("/root/hidden/bodyases/skinsectinfo");
  319. model.copyNode("/root/hidden/bodyases/skinsectinfo", "/root/main/wardrecinfo/skinsectinfo");
  320. model.setValue("/root/hidden/bodyases/skinsectinfo/skinsect/skincolorinfoinclyn", "1");
  321. model.setValue("/root/hidden/bodyases/skinsectinfo/skinsect/skinstatinfoinclyn", "1");
  322. //model.removeNodeset("/root/main/famyfact");
  323. model.makeNode("/root/temp/cond/list");
  324. getPatientInfoDetails("/root/temp/cond/list");
  325. //각 화면 상단에 선택된 환자 정보 display 필요함. (병실-성명-S/A-등록번호)
  326. var pid;
  327. var room;
  328. var patnm;
  329. var sex;
  330. var age;
  331. var instcd;
  332. var orddeptcd;
  333. var indd;
  334. room = model.getValue("/root/temp/cond/list/roomcd");
  335. patnm = model.getValue("/root/temp/cond/list/hngnm");
  336. sex = model.getValue("/root/temp/cond/list/sex");
  337. age = model.getValue("/root/temp/cond/list/age");
  338. pid = model.getValue("/root/temp/cond/list/pid");
  339. indd = model.getValue("/root/temp/cond/list/indd");
  340. instcd = model.getValue("/root/temp/cond/list/instcd");
  341. orddeptcd = model.getValue("/root/temp/cond/list/orddeptcd");
  342. model.setValue("/root/main/wardrecinfo/room", room);
  343. model.setValue("/root/main/wardrecinfo/patnm", patnm);
  344. model.setValue("/root/main/wardrecinfo/sex", sex);
  345. model.setValue("/root/main/wardrecinfo/age", age);
  346. model.setValue("/root/main/wardrecinfo/pid", pid);
  347. //웹용 인자값 셋팅
  348. model.makeValue("/root/send/req/pid", pid);
  349. model.makeValue("/root/send/req/indd", indd);
  350. model.makeValue("/root/send/req/instcd", instcd);
  351. model.makeValue("/root/send/req/recflag", "01");
  352. model.makeValue("/root/send/req/docucode", "0000002435");
  353. model.makeValue("/root/send/req/deptcd", orddeptcd);
  354. */
  355. var pid = model.getValue("/root/temp/cond/list/pid");
  356. var indd = model.getValue("/root/temp/cond/list/indd");
  357. var cretno = model.getValue("/root/temp/cond/list/cretno");
  358. var instcd = model.getValue("/root/temp/cond/list/instcd");
  359. var orddeptcd = model.getValue("/root/temp/cond/list/orddeptcd");
  360. var instUseYN = model.getValue("/root/codeinfo/codeinfo/codelist[cdgrupid ='172']/cdid");//교육요구도 추가 20091216 김홍점
  361. var deptcd = model.getValue("/root/temp/cond/list/wardcd");
  362. var userdept = getUserInfo("dutplcecd");
  363. var spiritdept = model.getValue("/root/codeinfo/codeinfo/codelist[cdgrupid ='U31']/cdid");
  364. var jobkindcd = getUserInfo("jobkindcd");
  365. if(jobkindcd != "0330") {
  366. if(deptcd == spiritdept) {
  367. if(userdept != spiritdept) {
  368. messageBox("환자 개인정보 보호를 위해 해당병동 사용자외엔 조회를 제한합니다", "E");
  369. return false;
  370. }
  371. }
  372. }
  373. //웹용 인자값 셋팅
  374. model.makeValue("/root/send/req/pid", pid);
  375. model.makeValue("/root/send/req/indd", indd);
  376. model.makeValue("/root/send/req/instcd", instcd);
  377. model.makeValue("/root/send/req/recflag", "01");
  378. model.makeValue("/root/send/req/docucode", "0000002435");
  379. model.makeValue("/root/send/req/deptcd", orddeptcd);
  380. if(pid == "") {
  381. messageBox("환자를 선택하지 ", "E007");
  382. window.close();
  383. return;
  384. } else {
  385. if(instUseYN == "Y"){
  386. btn_edurec.visible = true;
  387. btn_SPMMO14900.visible = true;
  388. grp_patinfo.attribute("style")="left:310px; top:50px; width:640px; height:20px;" ;
  389. setParameter("SPMRJ00300_pid", pid);
  390. setParameter("SPMRJ00300_orddd", indd);
  391. setParameter("SPMRJ00300_cretno", cretno);
  392. ivw_edurec.src = "../../../emr/jcimngtweb/xrw/SPMRJ00300_교육요구도사정.xrw";
  393. }else{
  394. grp_patinfo.attribute("style")="left:210px; top:50px; width:640px; height:20px;" ;
  395. btn_edurec.visible = false;
  396. btn_SPMMO14900.visible = false;
  397. }
  398. submit("TRMNW03101", "false"); //저장후 삭제(K), 신규(I), 수정(U)
  399. var exeflag = model.getValue("/root/hidden/paminfo/paminfo/exeflag");
  400. if(exeflag == 'U' ) {
  401. submit("TRMNW03102", false);
  402. //인증번호set_20090722_SMY
  403. model.setValue("/root/signinfo/signno", model.getValue("/root/main/wardrecinfo/signno"));
  404. var existfamyinfo = model.getValue("/root/main/wardrecinfo/existfamyinfo");
  405. setParameter("SPMMR04711_shape", fGetXmlToStr("/root/main/wardrecinfo/genogrmnm/XMD"));
  406. //마지막 기록일시 셋팅
  407. model.makeValue("/root/main/wardrecinfo/bfrecddtm", model.getValue("/root/hidden/paminfo/recinfo[recflag = '01' and indd = '" + indd + "']/recpkspec"));
  408. model.makeValue("/root/main/wardrecinfo/bfrecuser", model.getValue("/root/hidden/paminfo/recinfo[recflag = '01' and indd = '" + indd + "']/bfrecuser"));
  409. //입원일자 셋팅(응급실 경유 환자인 경우 입실체크가 되는 시점(즉 응급실 퇴실시점)의 일자가 병동 입원일자로 조회됨)_20090303_SMY
  410. model.setValue("/root/main/wardrecinfo/indd", model.getValue("/root/temp/cond/list/careinrmdd"));
  411. model.refresh();
  412. //model.copyNode("/root/main/wardrecinfo/famyfact", "/root/main/famyfact");
  413. //model.copyNode("/root/main/wardrecinfo/histinfo", "/root/main/histinfo");
  414. } else {
  415. //이전 기록이 있을 경우 가장 최근의 정보 자동 셋팅
  416. if(model.getValue("/root/hidden/paminfo/recinfo/recpkspec") != ""){
  417. model.setValue("/root/main/wardrecinfo/bfrecddtm", model.getValue("/root/hidden/paminfo/recinfo/recpkspec"));
  418. fChgRecHistInfo();
  419. }else{
  420. submit("TRMNW03104");
  421. var exist = model.getValue("/root/hidden/cominfo/histinfo/existyn");
  422. var existfamyinfo = model.getValue("/root/hidden/cominfo/famyinfo/existfamyinfo");
  423. setParameter("SPMMR04711_shape", fGetXmlToStr("/root/hidden/cominfo/famyinfo/genogrmnm/XMD"));
  424. //가족사항 연동부분
  425. model.removeNodeset("/root/main/famyfact");
  426. if(getNodesetCount("/root/hidden/cominfo/famyfact") > 0){
  427. //model.copyNode("/root/main/famyfact", "/root/hidden/cominfo/famyfact");
  428. for(var i=1; i <= getNodesetCount("/root/hidden/cominfo/famyfact"); i++) {
  429. if(model.getValue("/root/hidden/cominfo/famyfact["+ i +"]/rela") != ""){
  430. model.duplicate("/root/main", "/root/hidden/cominfo/famyfact["+ i +"]");
  431. }
  432. }
  433. }
  434. if(exist == "N") {
  435. model.copyNode("/root/main/histinfo", "/root/hidden/histinfo");
  436. model.setValue("/root/main/histinfo/pasthistinfo/pasthist/pasthistinclyn", "");
  437. model.setValue("/root/main/histinfo/famyhistinfo/famyhist/famyhistinclyn", "");
  438. model.setValue("/root/main/histinfo/inhistinfo/inhist/inhistinclyn", "");
  439. model.setValue("/root/main/histinfo/ophistinfo/ophist/ophistinclyn", "");
  440. model.setValue("/root/main/wardrecinfo/rectmedistatinfo/rectmedistat/rectmedistatinfoinclyn", "");
  441. model.setValue("/root/main/histinfo/allghistinfo/allghist/allghistinclyn", "");
  442. model.setValue("/root/main/histinfo/vacnhistinfo/vacnhist/vacnhistinfoinclyn", "");
  443. model.setValue("/root/main/histinfo/smokinfo/smok/smokinclyn", "");
  444. model.setValue("/root/main/histinfo/drunkinfo/drunk/drunkinclyn", "");
  445. model.setValue("/root/main/histinfo/gustofoodinfo/gustofood/gustofoodinclyn", "");
  446. model.setValue("/root/main/histinfo/tnsseffcinfo/tnsseffc/tnsseffcinclyn", "");
  447. } else {
  448. model.copyNode("/root/main/histinfo", "/root/hidden/cominfo/histinfo");
  449. }
  450. //var recDD = getCurrentDate();
  451. //var recDT = getCurrentTime();
  452. //var recUser = getUserName();
  453. //model.setValue("/root/main/wardrecinfo/bfrecdd", recDD);
  454. //model.setValue("/root/main/wardrecinfo/bfrecdt", recDT);
  455. //model.setValue("/root/main/wardrecinfo/bfrecuser", recUser);
  456. //model.setValue("/root/main/wardrecinfo/recdd", recDD);
  457. //model.setValue("/root/main/wardrecinfo/recdt", recDT);
  458. //model.setValue("/root/main/wardrecinfo/recuser", recUser);
  459. model.setValue("/root/main/wardrecinfo/religncd", model.getValue("/root/hidden/paminfo/paminfo/religncd"));
  460. model.setValue("/root/main/wardrecinfo/baptnm", model.getValue("/root/hidden/paminfo/paminfo/baptnm"));
  461. model.setValue("/root/main/wardrecinfo/tel", model.getValue("/root/hidden/paminfo/paminfo/tel"));
  462. model.setValue("/root/main/wardrecinfo/mphone", model.getValue("/root/hidden/paminfo/paminfo/mphone"));
  463. model.setValue("/root/main/wardrecinfo/etcphone1", model.getValue("/root/hidden/paminfo/paminfo/etcphone1"));
  464. model.setValue("/root/main/wardrecinfo/etcphone2", model.getValue("/root/hidden/paminfo/paminfo/etcphone2"));
  465. //입원일자 셋팅(응급실 경유 환자인 경우 입실체크가 되는 시점(즉 응급실 퇴실시점)의 일자가 병동 입원일자로 조회됨)_20090303_SMY
  466. model.setValue("/root/main/wardrecinfo/indd", model.getValue("/root/temp/cond/list/careinrmdd"));
  467. //model.setValue("/root/main/wardrecinfo/indd", indd);
  468. //기록일시 정보를 쿼리에서 가져옴
  469. model.setValue("/root/main/wardrecinfo/recdd", model.getValue("/root/hidden/paminfo/paminfo/recdd"));
  470. model.setValue("/root/main/wardrecinfo/rectm", model.getValue("/root/hidden/paminfo/paminfo/rectm"));
  471. model.setValue("/root/main/wardrecinfo/recuser", model.getValue("/root/hidden/paminfo/paminfo/recuser"));
  472. model.refresh();
  473. }
  474. }
  475. fMNWCareComFstdtSet( "01", "SRCH" );//recflag : 간호정보조사 플래그 CareCom.js 간호정보조사 최초기록일시 및 사용자 세팅
  476. fNotExistsNodeCreate();
  477. //가계도 연동부분.
  478. if(existfamyinfo == "Y") {
  479. model.setValue("/root/main/wardrecinfo/famytree/existyn", "Y");
  480. opt_existyn.refresh();
  481. }
  482. }
  483. //status = "select";
  484. if(grd_allghist.rows > 1) {
  485. for(var i = 0; i < grd_allghist.cols; i++) {
  486. if(grd_allghist.valueMatrix(1, i) != "") {
  487. allgInsYN = "N";
  488. }
  489. }
  490. }
  491. if(model.getValue("/root/main/wardrecinfo/inmotiveinfo/inmotive/inmotive1") == ""){
  492. model.setValue("/root/main/wardrecinfo/inmotiveinfo/inmotive/inmotive1", "Y");
  493. }
  494. if(model.getValue("/root/main/wardrecinfo/inmotiveinfo/inmotive/illnessflag") == ""){
  495. model.setValue("/root/main/wardrecinfo/inmotiveinfo/inmotive/illnessflag", "Y");
  496. }
  497. if(model.getValue("/root/main/wardrecinfo/gustoinfo/gusto/drunkinfo/drunkinfoyn") == ""){
  498. model.setValue("/root/main/wardrecinfo/gustoinfo/gusto/drunkinfo/drunkinfoyn", "1");
  499. }
  500. if(model.getValue("/root/main/wardrecinfo/gustoinfo/gusto/gustofoodinfo/gustofoodyn") == ""){
  501. model.setValue("/root/main/wardrecinfo/gustoinfo/gusto/gustofoodinfo/gustofoodyn", "1");
  502. }
  503. if(model.getValue("/root/main/wardrecinfo/gustoinfo/gusto/tnsseffcinfo/tnsseffcyn") == ""){
  504. model.setValue("/root/main/wardrecinfo/gustoinfo/gusto/tnsseffcinfo/tnsseffcyn", "1");
  505. }
  506. if(model.getValue("/root/main/wardrecinfo/femaleinfo/female/female/endmensyn") == ""){
  507. model.setValue("/root/main/wardrecinfo/femaleinfo/female/female/endmensyn", "1");
  508. }
  509. model.refresh();
  510. return true;
  511. }
  512. //노드 추가에 따른 존재하지 않는 노드생성
  513. function fNotExistsNodeCreate(){
  514. var bdwtchngtermflag= instance1.selectSingleNode("/root/main/wardrecinfo/apttbdwtchnginfo/apttbdwtchng/bdwtchngtermflag");
  515. var constipt= instance1.selectSingleNode("/root/main/wardrecinfo/stoolinfo/stool/stoolconstipation");
  516. var incdecflag= instance1.selectSingleNode(rdo_incdecflag.attribute("ref"));
  517. var shpaininfoflag= instance1.selectSingleNode(cmb_shpaininfoflag.attribute("ref"));
  518. // 15.06.18 여성, 월경, 비뇨기계, 대변 항목 추가
  519. var femaleaddinfoynflag = instance1.selectSingleNode(chk_femaleaddinfoyn.attribute("ref"));
  520. var mensaddinfoynflag = instance1.selectSingleNode(chk_mensaddinfoyn.attribute("ref"));
  521. var urinecateynflag = instance1.selectSingleNode(rdo_urinecateyn.attribute("ref"));
  522. //var stoolinfoinclynflag = instance1.selectSingleNode(chk_stoolinfoinclyn.attribute("ref"));
  523. //var urineinfoinclynflag = instance1.selectSingleNode(chk_urineinfoinclyn.attribute("ref"));
  524. //15.07.13 소변양(회/일) 추가
  525. var urinevoldaytime = instance1.selectSingleNode(cmb_urinevoldaytime.attribute("ref"));
  526. if ( bdwtchngtermflag == null ) {
  527. model.makeValue("/root/main/wardrecinfo/apttbdwtchnginfo/apttbdwtchng/bdwtchngtermflag","");
  528. }
  529. if ( rdo_incdecflag != null){
  530. if ( incdecflag == null ) {
  531. model.makeNode(rdo_incdecflag.attribute("ref"));
  532. }
  533. }
  534. if ( constipt == null ) {
  535. model.makeValue("/root/main/wardrecinfo/stoolinfo/stool/stoolconstipation","");
  536. }
  537. if(shpaininfoflag == null) {
  538. model.makeValue(cmb_shpaininfoflag.attribute("ref"), "");
  539. }
  540. if(model.getValue(rdo_shpaininfoinclyn.attribute("ref")) == "1") {
  541. cmb_shpaininfoflag.disabled = false;
  542. } else {
  543. cmb_shpaininfoflag.disabled = true;
  544. }
  545. // 15.06.16 추가 - 여성정보 추가사정
  546. if(femaleaddinfoynflag == null) {
  547. model.makeValue(chk_femaleaddinfoyn.attribute("ref"), "");
  548. }
  549. if(mensaddinfoynflag == null) {
  550. model.makeValue(chk_mensaddinfoyn.attribute("ref"), "");
  551. }
  552. if(urinecateynflag == null) {
  553. model.makeValue(rdo_urinecateyn.attribute("ref"), "");
  554. }
  555. //if(stoolinfoinclynflag == null) {
  556. // model.makeValue(chk_stoolinfoinclyn.attribute("ref"), "");
  557. //}
  558. //if(urineinfoinclynflag == null) {
  559. // model.makeValue(chk_urineinfoinclyn.attribute("ref"), "");
  560. //}
  561. if(urinevoldaytime == null) {
  562. model.makeValue(cmb_urinevoldaytime.attribute("ref"), "");
  563. }
  564. }
  565. function fGetXmlToStr(xPath) {
  566. var str = instance1.selectNodesXml(xPath);
  567. return str;
  568. }
  569. function fChkInclYN() {
  570. //병력 XML
  571. var pasthistyn = model.getValue("/root/main/histinfo/pasthistinfo/pasthist/pasthistinclyn");
  572. var famyhistyn = model.getValue("/root/main/histinfo/famyhistinfo/famyhist/famyhistinclyn");
  573. var inhistyn = model.getValue("/root/main/histinfo/inhistinfo/inhist/inhistinclyn");
  574. var ophistyn = model.getValue("/root/main/histinfo/ophistinfo/ophist/ophistinclyn");
  575. var rectmedistatyn = model.getValue("/root/main/wardrecinfo/rectmedistatinfo/rectmedistat/rectmedistatinfoinclyn");
  576. var allhistinclyn = model.getValue("/root/main/histinfo/allghistinfo/allghist/allghistinclyn");
  577. //신체사정XML
  578. var mfmdstatyn = model.getValue("/root/main/wardrecinfo/mfmdstatinfo/mfmdstat/mfmdstatinfoinclyn"); // 기형상태
  579. var shpaininfoyn = model.getValue("/root/main/wardrecinfo/shpaininfo/shpain/shpaininfoinclyn"); // 통증
  580. var resorgninfoyn = model.getValue("/root/main/wardrecinfo/resorgninfo/resorgn/resorgninfoinclyn"); // 호흡기계
  581. var digorgninfoyn = model.getValue("/root/main/wardrecinfo/digorgninfo/digorgn/digorgninfoinclyn"); // 소화기계
  582. var nvesysinfoyn = model.getValue("/root/main/wardrecinfo/nvesysinfo/nvesys/nvesysinfoinclyn"); // 신경계
  583. var skincolorinfoyn = model.getValue("/root/main/wardrecinfo/skinsectinfo/skinsect/skincolorinfoinclyn"); // 피부색
  584. var skinstatinfoyn = model.getValue("/root/main/wardrecinfo/skinsectinfo/skinsect/skinstatinfoinclyn"); // 피부상태
  585. // 15.08.25 - 비뇨기계, 대변 주석처리
  586. //var urineinfoinclyn = model.getValue("/root/main/wardrecinfo/uriorgninfo/uriorgn/urineinfoinclyn");
  587. //var stoolinfoinclyn = model.getValue("/root/main/wardrecinfo/stoolinfo/stool/stoolinfoinclyn");
  588. // 15.08.25 - 비뇨기계, 대변 주석처리
  589. //신체사정
  590. if(mfmdstatyn == "1") {
  591. model.makeValue("/root/send/wardrecinfo/mfmdstatinfo", fGetXmlToStr("/root/hidden/bodyases/mfmdstatinfo/mfmdstat"));
  592. } else {
  593. model.makeValue("/root/send/wardrecinfo/mfmdstatinfo", fGetXmlToStr("/root/main/wardrecinfo/mfmdstatinfo/mfmdstat"));
  594. }
  595. if(shpaininfoyn == "1") {//통증 : 무(default)/유 선택20100122 김홍점
  596. model.makeValue("/root/send/wardrecinfo/shpaininfo", fGetXmlToStr("/root/hidden/bodyases/shpaininfo/shpain"));
  597. }else {
  598. model.makeValue("/root/send/wardrecinfo/shpaininfo", fGetXmlToStr("/root/main/wardrecinfo/shpaininfo/shpain"));
  599. }
  600. if(resorgninfoyn == "1") {
  601. model.makeValue("/root/send/wardrecinfo/resorgninfo", fGetXmlToStr("/root/hidden/bodyases/resorgninfo/resorgn"));
  602. } else {
  603. model.makeValue("/root/send/wardrecinfo/resorgninfo", fGetXmlToStr("/root/main/wardrecinfo/resorgninfo/resorgn"));
  604. }
  605. if(digorgninfoyn == "1") {
  606. model.makeValue("root/send/wardrecinfo/digorgninfo", fGetXmlToStr("/root/hidden/bodyases/digorgninfo/digorgn"));
  607. } else {
  608. model.makeValue("/root/send/wardrecinfo/digorgninfo", fGetXmlToStr("/root/main/wardrecinfo/digorgninfo/digorgn"));
  609. }
  610. if(nvesysinfoyn == "1") {
  611. model.makeValue("/root/send/wardrecinfo/nvesysinfo", fGetXmlToStr("/root/hidden/bodyases/nvesysinfo/nvesys"));
  612. } else {
  613. model.makeValue("/root/send/wardrecinfo/nvesysinfo",
  614. fGetXmlToStr("/root/main/wardrecinfo/nvesysinfo/nvesys"));
  615. }
  616. model.makeNode("/root/temp/wardrecinfo/skinsectinfo");
  617. model.copyNode("/root/temp/wardrecinfo/skinsectinfo", "/root/main/wardrecinfo/skinsectinfo");
  618. if(skincolorinfoyn != "1" && skinstatinfoyn != "1") {
  619. model.makeValue("/root/temp/wardrecinfo/skinsectinfo", fGetXmlToStr("/root/main/wardrecinfo/skinsectinfo/skinsect"));
  620. } else {
  621. if(skincolorinfoyn == "1") {
  622. model.setValue("/root/temp/wardrecinfo/skinsectinfo/skinsect/skincolorinfoinclyn", model.getValue("/root/hidden/bodyases/skinsectinfo/skinsect/skincolorinfoinclyn"));
  623. model.copyNode("/root/temp/wardrecinfo/skinsectinfo/skinsect/skincolor", "/root/hidden/bodyases/skinsectinfo/skinsect/skincolor");
  624. }
  625. if(skinstatinfoyn == "1") {
  626. model.setValue("/root/temp/wardrecinfo/skinsectinfo/skinsect/skinstatinfoinclyn", model.getValue("/root/hidden/bodyases/skinsectinfo/skinsect/skinstatinfoinclyn"));
  627. model.copyNode("/root/temp/wardrecinfo/skinsectinfo/skinsect/skinstat", "/root/hidden/bodyases/skinsectinfo/skinsect/skinstat");
  628. }
  629. }
  630. model.makeValue("/root/send/wardrecinfo/skinsectinfo", fGetXmlToStr("/root/temp/wardrecinfo/skinsectinfo/skinsect"));
  631. // 15.06.22 - 추가
  632. // 15.08.25 - 비뇨기계, 대변 주석처리
  633. //if(urineinfoinclyn == "1") {
  634. // model.makeValue("root/send/wardrecinfo/uriorgninfo", fGetXmlToStr("/root/hidden/bodyases/uriorgninfo/uriorgn"));
  635. //} else {
  636. // model.makeValue("/root/send/wardrecinfo/uriorgninfo", fGetXmlToStr("/root/main/wardrecinfo/uriorgninfo/uriorgn"));
  637. //}
  638. //if(stoolinfoinclyn == "1") {
  639. // model.makeValue("root/send/wardrecinfo/stoolinfo", fGetXmlToStr("/root/hidden/bodyases/stoolinfo/stool"));
  640. //} else {
  641. // model.makeValue("/root/send/wardrecinfo/stoolinfo", fGetXmlToStr("/root/main/wardrecinfo/stoolinfo/stool"));
  642. //}
  643. //alert(instance1.selectNodesXml("/root/send/wardrecinfo/uriorgninfo"));
  644. //alert(instance1.selectNodesXml("/root/send/wardrecinfo/stoolinfo"));
  645. // 15.08.25 - 비뇨기계, 대변 주석처리
  646. //병력
  647. if(pasthistyn == "1") {
  648. model.makeValue("/root/send/wardrecinfo/pasthistinfo", fGetXmlToStr("/root/hidden/histinfo/pasthistinfo/pasthist"));
  649. } else {
  650. model.makeValue("/root/send/wardrecinfo/pasthistinfo", fGetXmlToStr("/root/main/histinfo/pasthistinfo/pasthist"));
  651. }
  652. if(famyhistyn == "1") {
  653. model.makeValue("/root/send/wardrecinfo/famyhistinfo", fGetXmlToStr("/root/hidden/histinfo/famyhistinfo/famyhist"));
  654. } else {
  655. model.makeValue("/root/send/wardrecinfo/famyhistinfo", fGetXmlToStr("/root/main/histinfo/famyhistinfo/famyhist"));
  656. }
  657. if(inhistyn == "1") {
  658. model.makeValue("/root/send/wardrecinfo/inhistinfo", fGetXmlToStr("/root/hidden/histinfo/inhistinfo/inhist"));
  659. } else {
  660. model.makeValue("/root/send/wardrecinfo/inhistinfo", fGetXmlToStr("/root/main/histinfo/inhistinfo/inhist"));
  661. }
  662. if(ophistyn == "1") {
  663. model.makeValue("/root/send/wardrecinfo/ophistinfo", fGetXmlToStr("/root/hidden/histinfo/ophistinfo/ophist"));
  664. } else {
  665. model.makeValue("/root/send/wardrecinfo/ophistinfo", fGetXmlToStr("/root/main/histinfo/ophistinfo/ophist"));
  666. }
  667. if(rectmedistatyn == "1") {
  668. model.makeValue("/root/send/wardrecinfo/rectmedistatinfo", fGetXmlToStr("/root/hidden/wardrecinfo/rectmedistatinfo/rectmedistat"));
  669. } else {
  670. model.makeValue("/root/send/wardrecinfo/rectmedistatinfo", fGetXmlToStr("/root/main/wardrecinfo/rectmedistatinfo/rectmedistat"));
  671. }
  672. if(allhistinclyn == "1") {
  673. model.makeValue("/root/send/wardrecinfo/allghistinfo", fGetXmlToStr("/root/hidden/histinfo/allghistinfo/allghist"));
  674. } else {
  675. model.makeValue("/root/send/wardrecinfo/allghistinfo", fGetXmlToStr("/root/main/histinfo/allghistinfo/allghist"));
  676. }
  677. //model.makeValue("/root/send/wardrecinfo/vacnhistinfo", fGetXmlToStr("/root/hidden/histinfo/vacnhistinfo/vacnhist"));
  678. //model.makeValue("/root/send/wardrecinfo/smokinfo", fGetXmlToStr("/root/hidden/histinfo/smokinfo/smok"));
  679. //model.makeValue("/root/send/wardrecinfo/drunkinfo", fGetXmlToStr("/root/hidden/histinfo/drunkinfo/drunk"));
  680. //model.makeValue("/root/send/wardrecinfo/gustofoodinfo", fGetXmlToStr("/root/hidden/histinfo/gustofoodinfo/gustofood"));
  681. //model.makeValue("/root/send/wardrecinfo/tnsseffcinfo", fGetXmlToStr("/root/hidden/histinfo/tnsseffcinfo/tnsseffc"));
  682. //다른 기록지에서 저장한 이력을 조회하여 저장한다.
  683. model.makeValue("/root/send/wardrecinfo/vacnhistinfo", fGetXmlToStr("/root/main/histinfo/vacnhistinfo/vacnhist"));
  684. model.makeValue("/root/send/wardrecinfo/smokinfo", fGetXmlToStr("/root/main/histinfo/smokinfo/smok"));
  685. model.makeValue("/root/send/wardrecinfo/drunkinfo", fGetXmlToStr("/root/main/histinfo/drunkinfo/drunk"));
  686. model.makeValue("/root/send/wardrecinfo/gustofoodinfo", fGetXmlToStr("/root/main/histinfo/gustofoodinfo/gustofood"));
  687. model.makeValue("/root/send/wardrecinfo/tnsseffcinfo", fGetXmlToStr("/root/main/histinfo/tnsseffcinfo/tnsseffc"));
  688. }
  689. function fPatgnrlInfo(certFlag) {
  690. var userid = getUserId();
  691. model.removeNodeset("/root/send/wardinfo");
  692. //환자기본정보
  693. model.makeValue("/root/send/wardrecinfo/privacy", model.getValue("/root/main/wardrecinfo/privacy"));
  694. model.makeValue("/root/send/wardrecinfo/jobcd", model.getValue("/root/main/wardrecinfo/jobcd"));
  695. model.makeValue("/root/send/wardrecinfo/jobnm", model.getValue("/root/main/wardrecinfo/jobnm"));
  696. model.makeValue("/root/send/wardrecinfo/educgrdecd", model.getValue("/root/main/wardrecinfo/educgrdecd"));
  697. model.makeValue("/root/send/wardrecinfo/educgrdenm", model.getValue("/root/main/wardrecinfo/educgrdenm"));
  698. model.makeValue("/root/send/wardrecinfo/religncd", model.getValue("/root/main/wardrecinfo/religncd"));
  699. model.makeValue("/root/send/wardrecinfo/relignnm", model.getValue("/root/main/wardrecinfo/relignnm"));
  700. model.makeValue("/root/send/wardrecinfo/marystatcd", model.getValue("/root/main/wardrecinfo/marystatcd"));
  701. model.makeValue("/root/send/wardrecinfo/marystatnm", model.getValue("/root/main/wardrecinfo/marystatnm"));
  702. model.makeValue("/root/send/wardrecinfo/baptnm", model.getValue("/root/main/wardrecinfo/baptnm"));
  703. // model.makeValue("/root/send/wardrecinfo/spo", model.getValue("/root/main/wardrecinfo/spo2"));
  704. model.makeValue("/root/send/wardrecinfo/relignreq", model.getValue("/root/main/wardrecinfo/relignreq"));
  705. //연락처구분, 기타연락처구분 추가
  706. model.makeValue("/root/send/wardrecinfo/telflag", model.getValue("/root/main/wardrecinfo/telflag"));
  707. model.makeValue("/root/send/wardrecinfo/tel", model.getValue("/root/main/wardrecinfo/tel"));
  708. model.makeValue("/root/send/wardrecinfo/mphone", model.getValue("/root/main/wardrecinfo/mphone"));
  709. model.makeValue("/root/send/wardrecinfo/etctelflag", model.getValue("/root/main/wardrecinfo/etctelflag"));
  710. model.makeValue("/root/send/wardrecinfo/etcphone1", model.getValue("/root/main/wardrecinfo/etcphone1"));
  711. model.makeValue("/root/send/wardrecinfo/etcphone2", model.getValue("/root/main/wardrecinfo/etcphone2"));
  712. //가계도
  713. model.makeValue("/root/send/wardrecinfo/famytree", fGetXmlToStr("/root/main/wardrecinfo/famytree/existyn"));
  714. //입원정보
  715. model.makeValue("/root/send/wardrecinfo/indd", model.getValue("/root/main/wardrecinfo/indd"));
  716. model.makeValue("/root/send/wardrecinfo/indt", model.getValue("/root/main/wardrecinfo/indt"));
  717. model.makeValue("/root/send/wardrecinfo/inpathcd", model.getValue("/root/main/wardrecinfo/inpathcd"));
  718. model.makeValue("/root/send/wardrecinfo/inpathnm", model.getValue("/root/main/wardrecinfo/inpathnm"));
  719. model.makeValue("/root/send/wardrecinfo/inmthdcd", model.getValue("/root/main/wardrecinfo/inmthdcd"));
  720. model.makeValue("/root/send/wardrecinfo/inmthdnm", model.getValue("/root/main/wardrecinfo/inmthdnm"));
  721. model.makeValue("/root/send/wardrecinfo/inacompstcd", model.getValue("/root/main/wardrecinfo/inacompstcd"));
  722. model.makeValue("/root/send/wardrecinfo/inacompstnm", model.getValue("/root/main/wardrecinfo/inacompstnm"));
  723. //일반정보
  724. model.makeValue("/root/send/wardrecinfo/basebdinfoinclyn", model.getValue("/root/main/wardrecinfo/basebdinfoinclyn"));
  725. /*
  726. model.makeValue("/root/send/wardrecinfo/lowbp", model.getValue("/root/main/wardrecinfo/lowbp"));
  727. model.makeValue("/root/send/wardrecinfo/highbp", model.getValue("/root/main/wardrecinfo/highbp"));
  728. model.makeValue("/root/send/wardrecinfo/pulse", model.getValue("/root/main/wardrecinfo/pulse"));
  729. model.makeValue("/root/send/wardrecinfo/breth", model.getValue("/root/main/wardrecinfo/breth"));
  730. model.makeValue("/root/send/wardrecinfo/bdtp", model.getValue("/root/main/wardrecinfo/bdtp"));
  731. model.makeValue("/root/send/wardrecinfo/bdtppartcd", model.getValue("/root/main/wardrecinfo/bdtppartcd"));
  732. model.makeValue("/root/send/wardrecinfo/bdht", model.getValue("/root/main/wardrecinfo/bdht"));
  733. model.makeValue("/root/send/wardrecinfo/bdwt", model.getValue("/root/main/wardrecinfo/bdwt"));
  734. */
  735. model.makeValue("/root/send/wardrecinfo/bdbtype", model.getValue("/root/main/wardrecinfo/bdbtype"));
  736. model.makeValue("/root/send/wardrecinfo/bdbtyperh", model.getValue("/root/main/wardrecinfo/bdbtyperh"));
  737. //신체정보 측정불가체크시 측정불가코드값 저장로직 추가_20090306_SMY
  738. //혈압
  739. // if(model.getValue("/root/main/wardrecinfo/bpinspyn") == "Y"){
  740. // model.makeValue("/root/send/wardrecinfo/lowbp", NoneInspCode);
  741. // model.makeValue("/root/send/wardrecinfo/highbp", NoneInspCode);
  742. // }else{
  743. // model.makeValue("/root/send/wardrecinfo/lowbp", model.getValue("/root/main/wardrecinfo/lowbp"));
  744. // model.makeValue("/root/send/wardrecinfo/highbp", model.getValue("/root/main/wardrecinfo/highbp"));
  745. // }
  746. // //맥박
  747. // if(model.getValue("/root/main/wardrecinfo/pulseinspyn") == "Y"){
  748. // model.makeValue("/root/send/wardrecinfo/pulse", NoneInspCode);
  749. // }else{
  750. // model.makeValue("/root/send/wardrecinfo/pulse", model.getValue("/root/main/wardrecinfo/pulse"));
  751. // }
  752. // //호흡
  753. // if(model.getValue("/root/main/wardrecinfo/brethinspyn") == "Y"){
  754. // model.makeValue("/root/send/wardrecinfo/breth", NoneInspCode);
  755. // }else{
  756. // model.makeValue("/root/send/wardrecinfo/breth", model.getValue("/root/main/wardrecinfo/breth"));
  757. // }
  758. // //체온
  759. // if(model.getValue("/root/main/wardrecinfo/bdtpinspyn") == "Y"){
  760. // model.makeValue("/root/send/wardrecinfo/bdtp", NoneInspCode);
  761. // model.makeValue("/root/send/wardrecinfo/bdtppartcd", NoneInspCode);
  762. // }else{
  763. // model.makeValue("/root/send/wardrecinfo/bdtp", model.getValue("/root/main/wardrecinfo/bdtp"));
  764. // model.makeValue("/root/send/wardrecinfo/bdtppartcd", model.getValue("/root/main/wardrecinfo/bdtppartcd"));
  765. // }
  766. //신장
  767. if(model.getValue("/root/main/wardrecinfo/bdhtinspyn") == "Y"){
  768. model.makeValue("/root/send/wardrecinfo/bdht", NoneInspCode);
  769. }else{
  770. model.makeValue("/root/send/wardrecinfo/bdht", model.getValue("/root/main/wardrecinfo/bdht"));
  771. }
  772. //체중
  773. if(model.getValue("/root/main/wardrecinfo/bdwtinspyn") == "Y"){
  774. model.makeValue("/root/send/wardrecinfo/bdwt", NoneInspCode);
  775. }else{
  776. model.makeValue("/root/send/wardrecinfo/bdwt", model.getValue("/root/main/wardrecinfo/bdwt"));
  777. }
  778. //SpO2
  779. if(model.getValue("/root/main/wardrecinfo/spo2inspyn") == "Y"){
  780. model.makeValue("/root/send/wardrecinfo/spo", NoneInspCode);
  781. }else{
  782. model.makeValue("/root/send/wardrecinfo/spo", model.getValue("/root/main/wardrecinfo/spo2"));
  783. }
  784. //입원동기 등등(xml)
  785. model.makeValue("/root/send/wardrecinfo/inmotiveinfo", fGetXmlToStr("/root/main/wardrecinfo/inmotiveinfo/inmotive"));
  786. model.makeValue("/root/send/wardrecinfo/gustoinfo", fGetXmlToStr("/root/main/wardrecinfo/gustoinfo/gusto"));
  787. model.makeValue("/root/send/wardrecinfo/femaleinfo", fGetXmlToStr("/root/main/wardrecinfo/femaleinfo/female"));
  788. model.makeValue("/root/send/wardrecinfo/spcffact", fGetXmlToStr("/root/main/wardrecinfo/spcffact/spcf"));
  789. //가족사항(가족연락처table)
  790. var updtdata = getGridUpdateData(grd_famyfact);
  791. model.makeValue("/root/send/wardrecinfo/famyfact", updtdata);
  792. //병력
  793. fChkInclYN();
  794. //신체사정
  795. model.makeValue("/root/send/wardrecinfo/shpaininfo", fGetXmlToStr("/root/main/wardrecinfo/shpaininfo/shpain"));
  796. model.makeValue("/root/send/wardrecinfo/apttbdwtchnginfo", fGetXmlToStr("/root/main/wardrecinfo/apttbdwtchnginfo/apttbdwtchng"));
  797. model.makeValue("/root/send/wardrecinfo/slepstatinfo", fGetXmlToStr("/root/main/wardrecinfo/slepstatinfo/slepstat"));
  798. model.makeValue("/root/send/wardrecinfo/cscsstatinfo", fGetXmlToStr("/root/main/wardrecinfo/cscsstatinfo/cscsstat"));
  799. model.makeValue("/root/send/wardrecinfo/mensinfo", fGetXmlToStr("/root/main/wardrecinfo/mensinfo/mens"));
  800. model.makeValue("/root/send/wardrecinfo/cirorgninfo", fGetXmlToStr("/root/main/wardrecinfo/cirorgninfo/cirorgn"));
  801. //'15.06.22 - 추가
  802. // 15.08.25 - 주석 해제
  803. model.makeValue("/root/send/wardrecinfo/uriorgninfo", fGetXmlToStr("/root/main/wardrecinfo/uriorgninfo/uriorgn"));
  804. model.makeValue("/root/send/wardrecinfo/stoolinfo", fGetXmlToStr("/root/main/wardrecinfo/stoolinfo/stool"));
  805. // 15.08.25 - 주석 해제
  806. model.makeValue("/root/send/wardrecinfo/actinfo", fGetXmlToStr("/root/main/wardrecinfo/actinfo/act"));
  807. model.makeValue("/root/send/wardrecinfo/visdsordinfo", fGetXmlToStr("/root/main/wardrecinfo/visdsordinfo/visdsord"));
  808. model.makeValue("/root/send/wardrecinfo/heardsordinfo", fGetXmlToStr("/root/main/wardrecinfo/heardsordinfo/heardsord"));
  809. model.makeValue("/root/send/wardrecinfo/tootstatinfo", fGetXmlToStr("/root/main/wardrecinfo/tootstatinfo/tootstat"));
  810. //수행구분(I, U에 따른 입력, 수정을위한 구분)
  811. model.makeValue("/root/send/wardrecinfo/exeflag", model.getValue("/root/hidden/paminfo/paminfo/exeflag"));
  812. //웹 테스트
  813. model.makeValue("/root/send/wardrecinfo/pid", model.getValue("/root/temp/cond/list/pid"));
  814. model.makeValue("/root/send/wardrecinfo/indd", model.getValue("/root/temp/cond/list/indd"));
  815. model.makeValue("/root/send/wardrecinfo/instcd", model.getValue("/root/temp/cond/list/instcd"));
  816. model.makeValue("/root/send/wardrecinfo/deptcd", model.getValue("/root/temp/cond/list/orddeptcd"));
  817. model.makeValue("/root/send/wardrecinfo/infooffer", model.getValue("/root/main/wardrecinfo/infooffer"));
  818. //알러지
  819. if(grd_allghist.rows > 1) {
  820. if(allgInsYN == "Y") {
  821. grd_allghist.addStatus(1, "insert");
  822. }
  823. }
  824. model.makeValue("/root/send/wardrecinfo/allginfo", grd_allghist.getUpdateData());
  825. model.makeValue("/root/send/wardrecinfo/recflag", "01");
  826. model.makeValue("/root/send/wardrecinfo/docucode", "0000002435");
  827. model.makeValue("/root/send/wardrecinfo/userid", userid);
  828. if(model.getValue("/root/properties/parameters/SPMMR04711_shape/SPMMR04711_shapevalue") == "") {
  829. //model.makeValue("/root/send/wardrecinfo/genogrmnm", "<XMD/>");
  830. model.makeValue("/root/send/wardrecinfo/genogrmnm", "");
  831. } else {
  832. model.makeValue("/root/send/wardrecinfo/genogrmnm", model.getValue("/root/properties/parameters/SPMMR04711_shape/SPMMR04711_shapevalue"));
  833. }
  834. model.makeValue("/root/send/wardrecinfo/certflag", certFlag);
  835. model.makeValue("/root/send/wardrecinfo/recdd", model.getValue("/root/main/wardrecinfo/recdd"));
  836. model.makeValue("/root/send/wardrecinfo/rectm", model.getValue("/root/main/wardrecinfo/rectm"));
  837. model.makeValue("/root/send/wardrecinfo/recdt", model.getValue("/root/main/wardrecinfo/recdd") + model.getValue("/root/main/wardrecinfo/rectm"));
  838. //----------(20110108)
  839. fnNRScalc();
  840. //----------(20110108)
  841. //------------(20101219) 경북대
  842. model.makeValue("/root/send/wardrecinfo/nrs1cd", model.getValue("/root/main/wardrecinfo/nrs1cd"));
  843. model.makeValue("/root/send/wardrecinfo/nrs1nm", model.getValue("/root/main/wardrecinfo/nrs1nm"));
  844. model.makeValue("/root/send/wardrecinfo/nrs21cd", model.getValue("/root/main/wardrecinfo/nrs21cd"));
  845. model.makeValue("/root/send/wardrecinfo/nrs21nm", model.getValue("/root/main/wardrecinfo/nrs21nm"));
  846. model.makeValue("/root/send/wardrecinfo/nrs22cd", model.getValue("/root/main/wardrecinfo/nrs22cd"));
  847. model.makeValue("/root/send/wardrecinfo/nrs22nm", model.getValue("/root/main/wardrecinfo/nrs22nm"));
  848. model.makeValue("/root/send/wardrecinfo/nrs23cd", model.getValue("/root/main/wardrecinfo/nrs23cd"));
  849. model.makeValue("/root/send/wardrecinfo/nrs23nm", model.getValue("/root/main/wardrecinfo/nrs23nm"));
  850. model.makeValue("/root/send/wardrecinfo/nrsscore", model.getValue("/root/main/wardrecinfo/nrsscore"));
  851. //------------(20101219) 경북대
  852. }
  853. function fSetSignData() {
  854. var xWardRecPath = Sign.XPATH_SIGNINFO + "/wardrecinfo";
  855. var xHistPath = Sign.XPATH_SIGNINFO + "/histinfo";
  856. var xFamyPath = Sign.XPATH_SIGNINFO + "/famyfactinfo";
  857. /****************************** 환자기본정보 **************************************/
  858. //직업
  859. var jobcd = model.getValue(xWardRecPath + "/jobcd");
  860. if(jobcd != "") {
  861. if(jobcd == "10") {
  862. if(model.getValue(xWardRecPath + "/jobnm") == "") {
  863. model.setValue(xWardRecPath + "/jobcd", cmb_job.label);
  864. } else {
  865. model.setValue(xWardRecPath + "/jobcd", model.getValue(xWardRecPath + "/jobnm"));
  866. }
  867. } else {
  868. model.setValue(xWardRecPath + "/jobcd", cmb_job.label);
  869. }
  870. }
  871. //교육정도
  872. var educgrde = model.getValue(xWardRecPath + "/educgrdecd");
  873. if(educgrde != "") {
  874. if(educgrde == "15") {
  875. if(model.getValue(xWardRecPath + "/educgrdenm") != "") {
  876. model.setValue(xWardRecPath + "/educgrdecd", model.getValue(xWardRecPath + "/educgrdenm"));
  877. } else {
  878. model.setValue(xWardRecPath + "/educgrdecd", cmb_educgrde.label);
  879. }
  880. } else {
  881. model.setValue(xWardRecPath + "/educgrdecd", cmb_educgrde.label);
  882. }
  883. }
  884. //종교
  885. var relign = model.getValue(xWardRecPath + "/religncd");
  886. if(relign != "") {
  887. if(relign == "01") {
  888. model.setValue(xWardRecPath + "/religncd", cmb_relign.label);
  889. if(model.getValue(xWardRecPath + "/baptnm") != "") {
  890. model.setValue(xWardRecPath + "/religncd", model.getValue(xWardRecPath + "/religncd") + "(" + model.getValue(xWardRecPath + "/baptnm") + ")");
  891. }
  892. } else if( relign == "09") {
  893. if(model.getValue(xWardRecPath + "/relignnm") == "") {
  894. model.setValue(xWardRecPath + "/religncd", cmb_relign.label);
  895. } else {
  896. model.setValue(xWardRecPath + "/religncd", model.getValue(xWardRecPath + "/relignnm"));
  897. }
  898. } else {
  899. model.setValue(xWardRecPath + "/religncd", cmb_relign.label);
  900. }
  901. }
  902. //영적요구
  903. var relignreq = model.getValue(xWardRecPath + "/relignreq");
  904. if (relignreq != ""){
  905. model.setValue(xWardRecPath + "/relignreq", cmb_relignreq.label);
  906. }
  907. //결혼상태
  908. var marystat = model.getValue(xWardRecPath + "/marystatcd");
  909. if(marystat != "") {
  910. if(marystat == "06") {
  911. if(model.getValue(xWardRecPath + "/marystatnm") != "") {
  912. model.setValue(xWardRecPath + "/marystatcd", model.getValue(xWardRecPath + "/marystatnm"));
  913. } else {
  914. model.setValue(xWardRecPath + "/marystatcd", cmb_marystat.label);
  915. }
  916. } else {
  917. model.setValue(xWardRecPath + "/marystatcd", cmb_marystat.label);
  918. }
  919. }
  920. // 15.08.25 - 개인정보사정 미 동의시 [개인정보사정미동의] 내용표기
  921. var privacy = model.getValue(xWardRecPath + "/privacy");
  922. if(privacy != "") {
  923. if(privacy == "Y") {
  924. model.setValue(xWardRecPath + "/jobcd", trim(chk_privacy.label));
  925. model.setValue(xWardRecPath + "/religncd", chk_privacy.label);
  926. model.setValue(xWardRecPath + "/marystatcd", chk_privacy.label);
  927. }
  928. }
  929. /****************************** 가족사항 **************************************/
  930. //가족사항 관계
  931. var rows = grd_famyfact.rows;
  932. var rela;
  933. for(var i = 1 ; i < rows; i++) {
  934. rela = model.getValue(xFamyPath + "/famyfact[" + i + "]/rela");
  935. if( !isNull(rela) ) {
  936. model.setValue(xFamyPath + "/famyfact[" + i + "]/rela", grd_famyfact.labelMatrix(i, grd_famyfact.colRef("rela")));
  937. }
  938. }
  939. /****************************** 입원정보 **************************************/
  940. //입원경로
  941. var inpath = model.getValue(xWardRecPath + "/inpathcd");
  942. if(inpath != "") {
  943. if(inpath == "08") {
  944. if(model.getValue(xWardRecPath + "/inpathnm") != "") {
  945. model.setValue(xWardRecPath + "/inpathcd", model.getValue(xWardRecPath + "/inpathnm"));
  946. } else {
  947. model.setValue(xWardRecPath + "/inpathcd", cmb_inpath.label);
  948. }
  949. } else {
  950. model.setValue(xWardRecPath + "/inpathcd", cmb_inpath.label);
  951. }
  952. }
  953. //입원방법
  954. var inmthd = model.getValue(xWardRecPath + "/inmthdcd");
  955. if(inmthd != "") {
  956. if(inmthd == "08") {
  957. if(model.getValue(xWardRecPath + "/inmthdnm") != "") {
  958. model.setValue(xWardRecPath + "/inmthdcd", model.getValue(xWardRecPath + "/inmthdnm"));
  959. } else {
  960. model.setValue(xWardRecPath + "/inmthdcd", cmb_inmthd.label);
  961. }
  962. } else {
  963. model.setValue(xWardRecPath + "/inmthdcd", cmb_inmthd.label);
  964. }
  965. }
  966. //입원시동반자
  967. var inacompst = model.getValue(xWardRecPath + "/inacompstcd");
  968. if(inacompst != "") {
  969. if(inacompst == "04") {
  970. if(model.getValue(xWardRecPath + "/inacompstnm") != "") {
  971. model.setValue(xWardRecPath + "/inacompstcd", model.getValue(xWardRecPath + "/inacompstnm"));
  972. } else {
  973. model.setValue(xWardRecPath + "/inacompstcd", cmb_inacompst.label);
  974. }
  975. } else {
  976. model.setValue(xWardRecPath + "/inacompstcd", cmb_inacompst.label);
  977. }
  978. }
  979. //병원도착전 24시간내 항생제 투약여부
  980. var antibiodrugyn = model.getValue(xWardRecPath + "/rectmedistatinfo/rectmedistat/antibiodrugyn");
  981. if(antibiodrugyn != "") {
  982. model.setValue(xWardRecPath + "/rectmedistatinfo/rectmedistat/antibiodrugyn", cmb_antibiodrugyn.label);
  983. }
  984. /****************************** 입원동기와 병에대한 인식 **************************************/
  985. //입원동기와 병에대한 인식
  986. var inmotive1 = model.getValue(xWardRecPath + "/inmotiveinfo/inmotive/inmotive1");
  987. var illnessflag = model.getValue(xWardRecPath + "/inmotiveinfo/inmotive/illnessflag");
  988. if( inmotive1 != "") {
  989. model.setValue(xWardRecPath + "/inmotiveinfo/inmotive/inmotive1", rdo_inmotv.label);
  990. }
  991. if( illnessflag != "") {
  992. model.setValue(xWardRecPath + "/inmotiveinfo/inmotive/illnessflag", rdo_illnessflag.label);
  993. }
  994. /****************************** 기본 신체정보 **************************************/
  995. //혈액형
  996. var bdbtype = model.getValue(xWardRecPath + "/bdbtype");
  997. if(bdbtype != "") {
  998. model.setValue(xWardRecPath + "/bdbtype", cmb_bdbtype.label);
  999. }
  1000. //체온
  1001. var bdtppart = model.getValue(xWardRecPath + "/bdtppartcd");
  1002. if(bdtppart != "") {
  1003. model.setValue(xWardRecPath + "/bdtppartcd", cmb_bdtp.label);
  1004. }
  1005. /****************************** 기호정보 **************************************/
  1006. /*
  1007. //입원전 1개월간 흡연력
  1008. var smokinfoyn = model.getValue(xWardRecPath + "/gustoinfo/gusto/smokinfo/smokinfoyn");
  1009. var smokinfocnt = model.getValue(xWardRecPath + "/gustoinfo/gusto/smokinfo/smokinfocnt");
  1010. if(smokinfoyn != "") {
  1011. if(smokinfoyn == "2" && smokinfocnt != ""){
  1012. model.setValue(xWardRecPath + "/gustoinfo/gusto/smokinfo/smokinfoyn", rdo_smokinfo.label + "(" + smokinfocnt + ")");
  1013. }else{
  1014. model.setValue(xWardRecPath + "/gustoinfo/gusto/smokinfo/smokinfoyn", rdo_smokinfo.label);
  1015. }
  1016. }
  1017. */
  1018. //흡연정보
  1019. var smokinfoyn = model.getValue(xWardRecPath + "/gustoinfo/gusto/smokinfo/smokinfoyn");
  1020. var bfsmokinfoyn = model.getValue(xWardRecPath + "/gustoinfo/gusto/smokinfo/bfsmokinfoyn");
  1021. if(smokinfoyn != "") {
  1022. if(bfsmokinfoyn != ""){
  1023. model.setValue(xWardRecPath + "/gustoinfo/gusto/smokinfo/smokinfoyn", rdo_smokinfo.label + "(" + rdo_bfsmokinfo.label + ")");
  1024. }else{
  1025. model.setValue(xWardRecPath + "/gustoinfo/gusto/smokinfo/smokinfoyn", rdo_smokinfo.label);
  1026. }
  1027. }
  1028. //금연상담여부
  1029. var nosmokcnstyn = model.getValue(xWardRecPath + "/gustoinfo/gusto/smokinfo/nosmokcnstyn");
  1030. if(nosmokcnstyn == "1") {
  1031. var str = rdo_nosmokcnstyn.label;
  1032. if(model.getValue(xWardRecPath + "/gustoinfo/gusto/smokinfo/nosmokcnst") != "") {
  1033. if(model.getValue(xWardRecPath + "/gustoinfo/gusto/smokinfo/nosmokcnst") == "03") {
  1034. if(model.getValue(xWardRecPath + "/gustoinfo/gusto/smokinfo/nosmokcnstnm") != "") {
  1035. str += "(" + ipt_nosmokcnstnm.label + ")";
  1036. model.setValue(xWardRecPath + "/gustoinfo/gusto/smokinfo/nosmokcnstyn", str);
  1037. } else {
  1038. str += "(" + cmb_nosmokcnst.label + ")";
  1039. model.setValue(xWardRecPath + "/gustoinfo/gusto/smokinfo/nosmokcnstyn", str);
  1040. }
  1041. } else {
  1042. str += "(" + cmb_nosmokcnst.label + ")";
  1043. model.setValue(xWardRecPath + "/gustoinfo/gusto/smokinfo/nosmokcnstyn", str);
  1044. }
  1045. } else {
  1046. model.setValue(xWardRecPath + "/gustoinfo/gusto/smokinfo/nosmokcnstyn", rdo_nosmokcnstyn.label);
  1047. }
  1048. } else {
  1049. model.setValue(xWardRecPath + "/gustoinfo/gusto/smokinfo/nosmokcnstyn", rdo_nosmokcnstyn.label);
  1050. }
  1051. //음주정보
  1052. var drunkinfoyn = model.getValue(xWardRecPath + "/gustoinfo/gusto/drunkinfo/drunkinfoyn");
  1053. if(drunkinfoyn != "") {
  1054. if(drunkinfoyn == "2") {
  1055. if(model.getValue(xWardRecPath + "/gustoinfo/gusto/drunkinfo/drunkinfokind") != "") {
  1056. if(model.getValue(xWardRecPath + "/gustoinfo/gusto/drunkinfo/drunkinfoterm") != "") {
  1057. model.setValue(xWardRecPath + "/gustoinfo/gusto/drunkinfo/drunkinfoyn", model.getValue(xWardRecPath + "/gustoinfo/gusto/drunkinfo/drunkinfokind") + " "
  1058. + model.getValue(xWardRecPath + "/gustoinfo/gusto/drunkinfo/drunkinfoterm") + cap_drunkinfoterm.label);
  1059. }else{
  1060. model.setValue(xWardRecPath + "/gustoinfo/gusto/drunkinfo/drunkinfoyn", model.getValue(xWardRecPath + "/gustoinfo/gusto/drunkinfo/drunkinfokind"));
  1061. }
  1062. } else {
  1063. if(model.getValue(xWardRecPath + "/gustoinfo/gusto/drunkinfo/drunkinfoterm") != "") {
  1064. model.setValue(xWardRecPath + "/gustoinfo/gusto/drunkinfo/drunkinfoyn", model.getValue(xWardRecPath + "/gustoinfo/gusto/drunkinfo/drunkinfoterm") + cap_drunkinfoterm.label);
  1065. }else{
  1066. model.setValue(xWardRecPath + "/gustoinfo/gusto/drunkinfo/drunkinfoyn", rdo_drunkinfo.label);
  1067. }
  1068. }
  1069. } else {
  1070. model.setValue(xWardRecPath + "/gustoinfo/gusto/drunkinfo/drunkinfoyn", rdo_drunkinfo.label);
  1071. }
  1072. }
  1073. //기호식품
  1074. var gustofoodyn = model.getValue(xWardRecPath + "/gustoinfo/gusto/gustofoodinfo/gustofoodyn");
  1075. if(gustofoodyn != "") {
  1076. if(gustofoodyn == "2") {
  1077. if(model.getValue(xWardRecPath + "/gustoinfo/gusto/gustofoodinfo/gustofooddetl") != "") {
  1078. model.setValue(xWardRecPath + "/gustoinfo/gusto/gustofoodinfo/gustofoodyn", model.getValue(xWardRecPath + "/gustoinfo/gusto/gustofoodinfo/gustofooddetl"));
  1079. } else {
  1080. model.setValue(xWardRecPath + "/gustoinfo/gusto/gustofoodinfo/gustofoodyn", rdo_gustofoodyn.label);
  1081. }
  1082. } else {
  1083. model.setValue(xWardRecPath + "/gustoinfo/gusto/gustofoodinfo/gustofoodyn", rdo_gustofoodyn.label);
  1084. }
  1085. }
  1086. //수혈부작용
  1087. var tnsseffcyn = model.getValue(xWardRecPath + "/gustoinfo/gusto/tnsseffcinfo/tnsseffcyn");
  1088. if(tnsseffcyn != "") {
  1089. if(tnsseffcyn == "2") {
  1090. if(model.getValue(xWardRecPath + "/gustoinfo/gusto/tnsseffcinfo/tnsseffcdetl") != "") {
  1091. model.setValue(xWardRecPath + "/gustoinfo/gusto/tnsseffcinfo/tnsseffcyn", model.getValue(xWardRecPath + "/gustoinfo/gusto/tnsseffcinfo/tnsseffcdetl"));
  1092. } else {
  1093. model.setValue(xWardRecPath + "/gustoinfo/gusto/tnsseffcinfo/tnsseffcyn", rdo_tnsseffcyn.label);
  1094. }
  1095. } else {
  1096. model.setValue(xWardRecPath + "/gustoinfo/gusto/tnsseffcinfo/tnsseffcyn", rdo_tnsseffcyn.label);
  1097. }
  1098. }
  1099. /****************************** 여성정보 **************************************/
  1100. //폐경여부
  1101. var endmensyn = model.getValue(xWardRecPath + "/femaleinfo/female/female/endmensyn");
  1102. var endmensdd = model.getValue(xWardRecPath + "/femaleinfo/female/female/endmensdd");
  1103. if(endmensyn != "") {
  1104. if(endmensyn == "2") {
  1105. if(endmensdd != "") {
  1106. model.setValue(xWardRecPath + "/femaleinfo/female/female/endmensyn", rdo_endmensyn.label + "(" + endmensdd.substr(0,4) + "-" + endmensdd.substr(4,2) + "-" + endmensdd.substr(6,2) + ")" );
  1107. } else {
  1108. model.setValue(xWardRecPath + "/femaleinfo/female/female/endmensyn", rdo_endmensyn.label);
  1109. }
  1110. } else {
  1111. model.setValue(xWardRecPath + "/femaleinfo/female/female/endmensyn", rdo_endmensyn.label);
  1112. }
  1113. }
  1114. //최종월경일
  1115. var lastmensdd = model.getValue(xWardRecPath + "/femaleinfo/female/female/lastmensdd");
  1116. if(lastmensdd != ""){
  1117. model.setValue(xWardRecPath + "/femaleinfo/female/female/lastmensdd", lastmensdd.substr(0,4) + "-" + lastmensdd.substr(4,2) + "-" + lastmensdd.substr(6,2));
  1118. } else {
  1119. model.setValue(xWardRecPath + "/femaleinfo/female/female/lastmensdd", "사정불필요");
  1120. }
  1121. // G
  1122. var prgbthhisg = model.getValue(xWardRecPath + "/femaleinfo/female/female/prgbthhisg");
  1123. if (prgbthhisg == "" || prgbthhisg == null){
  1124. model.setValue(xWardRecPath + "/femaleinfo/female/female/prgbthhisg", "사정불필요");
  1125. }
  1126. // P
  1127. var prgbthhisp = model.getValue(xWardRecPath + "/femaleinfo/female/female/prgbthhisp");
  1128. if (prgbthhisp == "" || prgbthhisp == null){
  1129. model.setValue(xWardRecPath + "/femaleinfo/female/female/prgbthhisp", "사정불필요");
  1130. }
  1131. // A
  1132. var prgbthhisa = model.getValue(xWardRecPath + "/femaleinfo/female/female/prgbthhisa");
  1133. if (prgbthhisa == "" || prgbthhisa == null){
  1134. model.setValue(xWardRecPath + "/femaleinfo/female/female/prgbthhisa", "사정불필요");
  1135. }
  1136. // SA
  1137. var prgbthhissa = model.getValue(xWardRecPath + "/femaleinfo/female/female/prgbthhissa");
  1138. if (prgbthhissa == "" || prgbthhissa == null){
  1139. model.setValue(xWardRecPath + "/femaleinfo/female/female/prgbthhissa", "사정불필요");
  1140. }
  1141. // AA
  1142. var prgbthhisaa = model.getValue(xWardRecPath + "/femaleinfo/female/female/prgbthhisaa");
  1143. if (prgbthhisaa == "" || prgbthhisaa == null){
  1144. model.setValue(xWardRecPath + "/femaleinfo/female/female/prgbthhisaa", "사정불필요");
  1145. }
  1146. // L
  1147. var prgbthhisl = model.getValue(xWardRecPath + "/femaleinfo/female/female/prgbthhisl");
  1148. if (prgbthhisl == "" || prgbthhisl == null){
  1149. model.setValue(xWardRecPath + "/femaleinfo/female/female/prgbthhisl", "사정불필요");
  1150. }
  1151. /****************************** 병력 **************************************/
  1152. //과거병력
  1153. var rows = grd_pasthist.rows;
  1154. var histspec;
  1155. for(var i = 1 ; i < rows; i++) {
  1156. histspec = model.getValue(xHistPath + "/pasthistinfo/pasthist/pasthist[" + i + "]/histspec");
  1157. if(histspec != "") {
  1158. model.setValue(xHistPath + "/pasthistinfo/pasthist/pasthist[" + i + "]/histspec", grd_pasthist.labelMatrix(i, grd_pasthist.colRef("histspec")));
  1159. }
  1160. }
  1161. //가족병력
  1162. var famyrel;
  1163. var existyn;
  1164. rows = grd_famyhist.rows;
  1165. for(var i = 1 ; i < rows; i++) {
  1166. famyrel = model.getValue(xHistPath + "/famyhistinfo/famyhist/famyhist[" + i + "]/famyrel");
  1167. existyn = model.getValue(xHistPath + "/famyhistinfo/famyhist/famyhist[" + i + "]/existyn");
  1168. histspec = model.getValue(xHistPath + "/famyhistinfo/famyhist/famyhist[" + i + "]/histspec");
  1169. if(famyrel != "") {
  1170. model.setValue(xHistPath + "/famyhistinfo/famyhist/famyhist[" + i + "]/famyrel", grd_famyhist.labelMatrix(i, grd_famyhist.colRef("famyrel")));
  1171. }
  1172. if(existyn != "") {
  1173. model.setValue(xHistPath + "/famyhistinfo/famyhist/famyhist[" + i + "]/existyn", grd_famyhist.labelMatrix(i, grd_famyhist.colRef("existyn")));
  1174. }
  1175. if(histspec != "") {
  1176. model.setValue(xHistPath + "/famyhistinfo/famyhist/famyhist[" + i + "]/histspec", grd_famyhist.labelMatrix(i, grd_famyhist.colRef("histspec")));
  1177. }
  1178. }
  1179. //allergy구분
  1180. rows = grd_allghist.rows;
  1181. var flag;
  1182. for(var i = 1 ; i < rows; i++) {
  1183. flag = model.getValue(xHistPath + "/allghistinfo/allghist/allghist[" + i + "]/flag");
  1184. if(flag != "") {
  1185. model.setValue(xHistPath + "/allghistinfo/allghist/allghist[" + i + "]/flag", grd_allghist.labelMatrix(i, grd_allghist.colRef("flag")));
  1186. }
  1187. }
  1188. /****************************** 신체사정 **************************************/
  1189. //기형상태
  1190. var mfmdstatLen = grd_mfmdstat.rows;
  1191. var part;
  1192. var direc;
  1193. if(mfmdstatLen > 0) {
  1194. for(var i = 0; i < mfmdstatLen; i++) {
  1195. part = model.getValue(xWardRecPath + "/mfmdstatinfo/mfmdstat/mfmdstat[" + i + "]/part");
  1196. direc = model.getValue(xWardRecPath + "/mfmdstatinfo/mfmdstat/mfmdstat[" + i + "]/direc");
  1197. if(part != "" ) {
  1198. model.setValue(xWardRecPath + "/mfmdstatinfo/mfmdstat/mfmdstat[" + i + "]/part", grd_mfmdstat.labelMatrix(i, grd_mfmdstat.colRef("part")));
  1199. }
  1200. if(direc != "") {
  1201. model.setValue(xWardRecPath + "/mfmdstatinfo/mfmdstat/mfmdstat[" + i + "]/direc", grd_mfmdstat.labelMatrix(i, grd_mfmdstat.colRef("direc")));
  1202. }
  1203. }
  1204. }
  1205. //20120625_김병국(통증사정 정보 추가) :XSLT보이기용.
  1206. var shpaininfoinclyn = model.getValue(xWardRecPath + "/shpaininfo/shpain/shpaininfoinclyn");
  1207. var shpaininfoflag = cmb_shpaininfoflag.label;
  1208. var shpaininfo = "";
  1209. if(shpaininfoinclyn != "") {
  1210. shpaininfo = rdo_shpaininfoinclyn.label;
  1211. if(shpaininfoinclyn == "1") {
  1212. if(shpaininfoflag != "") {
  1213. shpaininfo += "(" + shpaininfoflag + ")";
  1214. }
  1215. }
  1216. model.makeValue(xWardRecPath + "/shpaininfo/shpain/shpaininfoinclyn", shpaininfo);
  1217. model.makeValue(xWardRecPath + "/shpaininfo/shpain/shpaininfochgdd", "20100125");//20100125 일부터 동통에서 통증으로 변경됨.
  1218. }
  1219. /****************************** 식욕 및 체중변화 **************************************/
  1220. //식욕변화
  1221. var apptchngyn = model.getValue(xWardRecPath + "/apttbdwtchnginfo/apttbdwtchng/apptchngyn");
  1222. str = rdo_apttchngyn.label;
  1223. if(apptchngyn != "") {
  1224. if(apptchngyn == "2") {
  1225. if(model.getValue(xWardRecPath + "/apttbdwtchnginfo/apttbdwtchng/apptaddyn") != "") {
  1226. str += "(" + rdo_apttchngflag.label+ ")";
  1227. }
  1228. }
  1229. model.setValue(xWardRecPath + "/apttbdwtchnginfo/apttbdwtchng/apptchngyn", str);
  1230. }
  1231. //식욕상태
  1232. var apptstatflag = model.getValue(xWardRecPath + "/apttbdwtchnginfo/apttbdwtchng/apptstatflag");
  1233. if(apptstatflag != "") {
  1234. model.setValue(xWardRecPath + "/apttbdwtchnginfo/apttbdwtchng/apptstatflag", rdo_apttstatflag.label);
  1235. }
  1236. //체중변화
  1237. var bdwtchngyn = model.getValue(xWardRecPath + "/apttbdwtchnginfo/apttbdwtchng/bdwtchngyn");
  1238. var incdecflag = model.getValue(xWardRecPath + "/apttbdwtchnginfo/apttbdwtchng/incdecflag");
  1239. var bdwtchnggrde = model.getValue(xWardRecPath + "/apttbdwtchnginfo/apttbdwtchng/bdwtchnggrde");
  1240. var bdwtchngterm = model.getValue(xWardRecPath + "/apttbdwtchnginfo/apttbdwtchng/bdwtchngterm");
  1241. var bdwtchngtermflag = model.getValue(xWardRecPath + "/apttbdwtchnginfo/apttbdwtchng/bdwtchngtermflag");
  1242. str = rdo_bdwtchngyn.label;
  1243. if(bdwtchngyn != "") {
  1244. if(bdwtchngyn == "2") {
  1245. if( !isNull(incdecflag) && bdwtchnggrde != "" && bdwtchngtermflag != "") {
  1246. str += "(" + rdo_incdecflag.label+ ": " + bdwtchnggrde + "kg " + "/ 기간 : " + rdo_bdwtchngtermflag.label + " (" + bdwtchngterm + ") )";
  1247. } else if(bdwtchnggrde != "" && bdwtchngtermflag == "") {
  1248. str += "(" + rdo_incdecflag.label+ ": " + bdwtchnggrde + "kg )";
  1249. } else if(bdwtchnggrde == "" && bdwtchngtermflag != "") {
  1250. str += "(" + "기간 : " + rdo_bdwtchngtermflag.label + " ( " + bdwtchngterm + ") )";
  1251. }
  1252. }
  1253. model.setValue(xWardRecPath + "/apttbdwtchnginfo/apttbdwtchng/bdwtchngyn", str);
  1254. }
  1255. //편식
  1256. var onemealyn = model.getValue(xWardRecPath + "/apttbdwtchnginfo/apttbdwtchng/onemealyn");
  1257. if(apptstatflag != "") {
  1258. model.setValue(xWardRecPath + "/apttbdwtchnginfo/apttbdwtchng/onemealyn", rdo_onemealyn.label);
  1259. }
  1260. /****************************** 수면상태 **************************************/
  1261. //수면장애
  1262. var slepdsordyn = model.getValue(xWardRecPath + "/slepstatinfo/slepstat/slepdsordyn");
  1263. var slepdsordtm = model.getValue(xWardRecPath + "/slepstatinfo/slepstat/slepdsordtm");
  1264. str = rdo_slepdsord.label;
  1265. if(slepdsordyn != "") {
  1266. if(slepdsordyn == "2") {
  1267. if(slepdsordtm != "") {
  1268. str += "(" + slepdsordtm + "시간/일)";
  1269. }
  1270. }
  1271. model.setValue(xWardRecPath + "/slepstatinfo/slepstat/slepdsordyn", str);
  1272. }
  1273. //약물복용
  1274. var dugtmedyn = model.getValue(xWardRecPath + "/slepstatinfo/slepstat/dugtmedyn");
  1275. var dugtmeddetl = model.getValue(xWardRecPath + "/slepstatinfo/slepstat/dugtmeddetl");
  1276. str = rdo_drugtmedyn.label;
  1277. if(dugtmedyn != "") {
  1278. if(dugtmedyn == "2") {
  1279. if(dugtmeddetl != "") {
  1280. str += "(" + dugtmeddetl + ")";
  1281. }
  1282. }
  1283. model.setValue(xWardRecPath + "/slepstatinfo/slepstat/dugtmedyn", str);
  1284. }
  1285. /****************************** 의식상태 **************************************/
  1286. //지남력
  1287. var cscsstathuman = model.getValue(xWardRecPath + "/cscsstatinfo/cscsstat/cscsstathuman");
  1288. var cscsstattm = model.getValue(xWardRecPath + "/cscsstatinfo/cscsstat/cscsstattm");
  1289. var cscsstatplce = model.getValue(xWardRecPath + "/cscsstatinfo/cscsstat/cscsstatplce");
  1290. if(cscsstathuman != "") {
  1291. model.setValue(xWardRecPath + "/cscsstatinfo/cscsstat/cscsstathuman", cmb_cscsstathuman.label);
  1292. }
  1293. if(cscsstattm != "") {
  1294. model.setValue(xWardRecPath + "/cscsstatinfo/cscsstat/cscsstattm", cmb_cscsstattm.label);
  1295. }
  1296. if(cscsstatplce != "") {
  1297. model.setValue(xWardRecPath + "/cscsstatinfo/cscsstat/cscsstatplce", cmb_cscsstatplce.label);
  1298. }
  1299. //의식상태
  1300. var cscsstat = model.getValue(xWardRecPath + "/cscsstatinfo/cscsstat/cscsstat");
  1301. if(cscsstat != "") {
  1302. model.setValue(xWardRecPath + "/cscsstatinfo/cscsstat/cscsstat", cmb_cscsstat.label);
  1303. }
  1304. //의사소통
  1305. var communication = model.getValue(xWardRecPath + "/cscsstatinfo/cscsstat/communication");
  1306. if( communication != "") {
  1307. model.setValue(xWardRecPath + "/cscsstatinfo/cscsstat/communication", rdo_communication.label);
  1308. }
  1309. //정서상태
  1310. var emotstat = model.getValue(xWardRecPath + "/cscsstatinfo/cscsstat/emotstat");
  1311. if(emotstat != "") {
  1312. model.setValue(xWardRecPath + "/cscsstatinfo/cscsstat/emotstat", cmb_emotstat.label);
  1313. }
  1314. /****************************** 월경 **************************************/
  1315. //월경
  1316. var mensyn = model.getValue(xWardRecPath + "/mensinfo/mens/mensyn");
  1317. if(mensyn != "") {
  1318. model.setValue(xWardRecPath + "/mensinfo/mens/mensyn", rdo_mensyn.label);
  1319. } else{
  1320. model.setValue(xWardRecPath + "/mensinfo/mens/mensyn", "사정불필요");
  1321. }
  1322. //상태
  1323. var mensstat = model.getValue(xWardRecPath + "/mensinfo/mens/mensstat");
  1324. if(mensstat != "") {
  1325. model.setValue(xWardRecPath + "/mensinfo/mens/mensstat", rdo_mensstat.label);
  1326. } else{
  1327. model.setValue(xWardRecPath + "/mensinfo/mens/mensstat", "사정불필요");
  1328. }
  1329. //월경통
  1330. var menspainyn = model.getValue(xWardRecPath + "/mensinfo/mens/menspainyn");
  1331. if(menspainyn != "") {
  1332. model.setValue(xWardRecPath + "/mensinfo/mens/menspainyn", rdo_menspainyn.label);
  1333. } else{
  1334. model.setValue(xWardRecPath + "/mensinfo/mens/menspainyn", "사정불필요");
  1335. }
  1336. //월경주기 20090820
  1337. var mensday = model.getValue(xWardRecPath + "/mensinfo/mens/mensday");
  1338. var mensweek = model.getValue(xWardRecPath + "/mensinfo/mens/mensweek");
  1339. if( (getCurrentDate() >= '20090821' ) && ( !isNull(mensday) || !isNull(mensweek) )) {
  1340. model.makeValue(xWardRecPath + "/mensinfo/mens/mensdayweek", mensday+"일 " + mensweek+"일 주기");
  1341. model.setValue(xWardRecPath + "/mensinfo/mens/mensday", "");
  1342. model.setValue(xWardRecPath + "/mensinfo/mens/mensweek", "");
  1343. } else{
  1344. model.makeValue(xWardRecPath + "/mensinfo/mens/mensdayweek", "사정불필요");
  1345. }
  1346. // 양
  1347. var mensvol = model.getValue(xWardRecPath + "/mensinfo/mens/mensvol");
  1348. if (mensvol == "" || mensvol == null){
  1349. model.setValue(xWardRecPath + "/mensinfo/mens/mensvol", "사정불필요");
  1350. }
  1351. // 초경
  1352. var fstmensage = model.getValue(xWardRecPath + "/mensinfo/mens/fstmensage");
  1353. if (fstmensage == "" || fstmensage == null){
  1354. model.setValue(xWardRecPath + "/mensinfo/mens/fstmensage", "사정불필요");
  1355. }
  1356. // 월경 기타
  1357. var mensetc = model.getValue(xWardRecPath + "/mensinfo/mens/mensetc");
  1358. if (mensetc == "" || mensetc == null){
  1359. model.setValue(xWardRecPath + "/mensinfo/mens/mensetc", "사정불필요");
  1360. }
  1361. /****************************** 순환기계 **************************************/
  1362. //순환장애
  1363. var cirdsordkind = model.getValue(xWardRecPath + "/cirorgninfo/cirorgn/cirorgn/cirdsordkind");
  1364. var arr = new Array();
  1365. arr = chk_cycdsordkind.label.split(" ");
  1366. if(cirdsordkind != "") {
  1367. model.setValue(xWardRecPath + "/cirorgninfo/cirorgn/cirorgn/cirdsordkind", arr);
  1368. }
  1369. //부종
  1370. var edema = model.getValue(xWardRecPath + "/cirorgninfo/cirorgn/cirorgn/edemakind");
  1371. var edemadetll = model.getValue(xWardRecPath + "/cirorgninfo/cirorgn/cirorgn/edemadetll");
  1372. str = cmb_edema.label;
  1373. if(edema != "") {
  1374. if(edema == "7") {
  1375. if(edemadetll != "") {
  1376. str = edemadetll;
  1377. }
  1378. }
  1379. model.setValue(xWardRecPath + "/cirorgninfo/cirorgn/cirorgn/edemakind", str);
  1380. }
  1381. //요흔
  1382. var yohnyn = model.getValue(xWardRecPath + "/cirorgninfo/cirorgn/cirorgn/yohnyn");
  1383. var yohn = model.getValue(xWardRecPath + "/cirorgninfo/cirorgn/cirorgn/yohnddetl");
  1384. str = rdo_yohnyn.label;
  1385. if(yohnyn != "") {
  1386. if(yohnyn == "2") {
  1387. if(yohn != "") {
  1388. str = yohn;
  1389. }
  1390. }
  1391. model.setValue(xWardRecPath + "/cirorgninfo/cirorgn/cirorgn/yohnyn", str);
  1392. }
  1393. //부착기구
  1394. var cyccateyn = model.getValue(xWardRecPath + "/cirorgninfo/cirorgn/cirorgn/cyccateyn");
  1395. var cyccatekind = model.getValue(xWardRecPath + "/cirorgninfo/cirorgn/cirorgn/cyccatekind");
  1396. var catedetl = model.getValue(xWardRecPath + "/cirorgninfo/cirorgn/cirorgn/catedetl");
  1397. str = rdo_cyccateyn.label;
  1398. if(cyccateyn != "") {
  1399. if(cyccateyn == "2") {
  1400. if(cyccatekind != "") {
  1401. if(cyccatekind == "3") {
  1402. if(catedetl != "") {
  1403. str += "(" + catedetl + ")";
  1404. }
  1405. } else {
  1406. str += "(" + cmb_cyccatekind.label + ")";
  1407. }
  1408. }
  1409. }
  1410. model.setValue(xWardRecPath + "/cirorgninfo/cirorgn/cirorgn/cyccateyn", str);
  1411. }
  1412. // 15.06.18 - 추가
  1413. /****************************** 비뇨기계 **************************************/
  1414. // 비뇨기계 부착기구
  1415. var urinecateyn = model.getValue(xWardRecPath + "/uriorgninfo/uriorgn/urinecateyn");
  1416. if(urinecateyn != "") {
  1417. model.setValue(xWardRecPath + "/uriorgninfo/uriorgn/urinecateyn", rdo_urinecateyn.label);
  1418. }
  1419. // 비뇨기계 소변양(회/일)
  1420. var urinevoldaytime = model.getValue(xWardRecPath + "/uriorgninfo/uriorgn/urinevoldaytime");
  1421. if(urinevoldaytime != "") {
  1422. model.setValue(xWardRecPath + "/uriorgninfo/uriorgn/urinevoldaytime", cmb_urinevoldaytime.label);
  1423. }
  1424. // 15.06.18 - 추가
  1425. /****************************** 대변 **************************************/
  1426. //대변색깔
  1427. var stoolcolor = model.getValue(xWardRecPath + "/stoolinfo/stool/stoolcolor");
  1428. if(stoolcolor != "") {
  1429. model.setValue(xWardRecPath + "/stoolinfo/stool/stoolcolor", cmb_stoolcolor.label);
  1430. }
  1431. //대변종류
  1432. var stoolkind = model.getValue(xWardRecPath + "/stoolinfo/stool/stoolkind");
  1433. if(stoolkind != "") {
  1434. model.setValue(xWardRecPath + "/stoolinfo/stool/stoolkind", cmb_stoolkind.label);
  1435. }
  1436. //변비
  1437. var constipt = model.getValue(xWardRecPath + "/stoolinfo/stool/stoolconstipation");
  1438. if(constipt == "Y") {
  1439. model.makeValue(xWardRecPath + "/stoolinfo/stool/stoolcateconstipation", "유");
  1440. }else {
  1441. model.makeValue(xWardRecPath + "/stoolinfo/stool/stoolcateconstipation", "무");
  1442. }
  1443. //대변부착기구
  1444. var stoolcateyn = model.getValue(xWardRecPath + "/stoolinfo/stool/stoolcateyn");
  1445. var stoolcatekind = model.getValue(xWardRecPath + "/stoolinfo/stool/stoolcatekind");
  1446. str = rdo_stoolcateyn.label;
  1447. if(stoolcateyn != "") {
  1448. if(stoolcatekind != "") {
  1449. str += "(" + stoolcatekind + ")";
  1450. }
  1451. model.setValue(xWardRecPath + "/stoolinfo/stool/stoolcateyn", str);
  1452. }
  1453. /****************************** 기타 활동 및 장애 **************************************/
  1454. //활동
  1455. var actfreeyn = model.getValue(xWardRecPath + "/actinfo/act/actfreeyn");
  1456. if(actfreeyn != "") {
  1457. model.setValue(xWardRecPath + "/actinfo/act/actfreeyn", rdo_actfreeyn.label);
  1458. }
  1459. //보조기구
  1460. var supptoolkind = model.getValue(xWardRecPath + "/actinfo/act/supptoolkind");
  1461. arr = chk_supptoolkind.label.split('▦');
  1462. if(supptoolkind != "") {
  1463. model.setValue(xWardRecPath + "/actinfo/act/supptoolkind", arr);
  1464. }
  1465. //신경계 동공
  1466. var pupilsymmetryyn = model.getValue(xWardRecPath + "/nvesysinfo/nvesys/nvesys/pupilsymmetryyn");
  1467. if(pupilsymmetryyn != "") {
  1468. model.setValue(xWardRecPath + "/nvesysinfo/nvesys/nvesys/pupilsymmetryyn", rdo_pupilsymmetryyn.label);
  1469. }
  1470. //좌
  1471. var pupilleft = model.getValue(xWardRecPath + "/nvesysinfo/nvesys/nvesys/pupilleft");
  1472. if(pupilleft != "") {
  1473. model.setValue(xWardRecPath + "/nvesysinfo/nvesys/nvesys/pupilleft", cmb_pupilleft.label);
  1474. }
  1475. //좌 빛반사
  1476. var pupilleftrflx = model.getValue(xWardRecPath + "/nvesysinfo/nvesys/nvesys/pupilleftrflx");
  1477. if(pupilleftrflx != "") {
  1478. model.setValue(xWardRecPath + "/nvesysinfo/nvesys/nvesys/pupilleftrflx", cmb_pupilleftrflx.label);
  1479. }
  1480. //우
  1481. var pupilrght = model.getValue(xWardRecPath + "/nvesysinfo/nvesys/nvesys/pupilrght");
  1482. if(pupilrght != "") {
  1483. model.setValue(xWardRecPath + "/nvesysinfo/nvesys/nvesys/pupilrght", cmb_pupilrght.label);
  1484. }
  1485. //우 빛반사
  1486. var pupilrghtrflx = model.getValue(xWardRecPath + "/nvesysinfo/nvesys/nvesys/pupilrghtrflx");
  1487. if(pupilrghtrflx != "") {
  1488. model.setValue(xWardRecPath + "/nvesysinfo/nvesys/nvesys/pupilrghtrflx", cmb_pupilrghtrflx.label);
  1489. }
  1490. //시력장애
  1491. var visdsordyn = model.getValue(xWardRecPath + "/visdsordinfo/visdsord/visdsordyn");
  1492. var visdsordpos = model.getValue(xWardRecPath + "/visdsordinfo/visdsord/visdsordpos");
  1493. var visdsordleft = model.getValue(xWardRecPath + "/visdsordinfo/visdsord/visdsordleft");
  1494. var visdsordrght = model.getValue(xWardRecPath + "/visdsordinfo/visdsord/visdsordrght");
  1495. var visdsordkind = model.getValue(xWardRecPath + "/visdsordinfo/visdsord/visdsordkind");
  1496. var visdsordblind = model.getValue(xWardRecPath + "/visdsordinfo/visdsord/visdsordblind");
  1497. str = rdo_visdsordyn.label;
  1498. if(visdsordyn != "") {
  1499. if(visdsordyn == "2") {
  1500. if(visdsordpos != "") {
  1501. if(visdsordleft != "" && visdsordrght != "") {
  1502. str += "(좌: " + visdsordleft + " 우: " + visdsordrght + ")";
  1503. } else if(visdsordpos == "1") {
  1504. str += "(좌: " + visdsordleft + ")";
  1505. } else if(visdsordpos == "2") {
  1506. str += "(우: " + visdsordrght + ")";
  1507. }
  1508. }
  1509. if(visdsordkind != "") {
  1510. arr = chk_visdsordkind.label.split(" ");
  1511. str += " (" + arr + ")";
  1512. }
  1513. if(visdsordblind != "") {
  1514. arr = chk_blindnesspos.label.split(" ");
  1515. str += " (" + arr + ")";
  1516. }
  1517. }
  1518. model.setValue(xWardRecPath + "/visdsordinfo/visdsord/visdsordyn", str);
  1519. }
  1520. //청력장애
  1521. var heardsordyn = model.getValue(xWardRecPath + "/heardsordinfo/heardsord/heardsordyn");
  1522. var heardsordpos = model.getValue(xWardRecPath + "/heardsordinfo/heardsord/heardsordpos");
  1523. var heardsordleft = model.getValue(xWardRecPath + "/heardsordinfo/heardsord/heardsordleft");
  1524. var heardsordrght = model.getValue(xWardRecPath + "/heardsordinfo/heardsord/heardsordrght");
  1525. var heardsordkind = model.getValue(xWardRecPath + "/heardsordinfo/heardsord/heardsordkind");
  1526. str = rdo_heardsordyn.label;
  1527. if(heardsordyn != "") {
  1528. if(heardsordyn == "2") {
  1529. if(heardsordpos != "") {
  1530. if(heardsordpos == "1 2" || heardsordpos == "2 1") {
  1531. if(heardsordleft != "" && heardsordrght != "") {
  1532. str += "(좌: " + heardsordleft + " 우: " + heardsordrght + ")";
  1533. } else if(heardsordleft != "" && heardsordrght == "") {
  1534. str += "(좌: " + heardsordleft + ")";
  1535. } else if(heardsordleft == "" && heardsordrght != "") {
  1536. str += "(우: " + heardsordrght + ")";
  1537. }
  1538. } else if(heardsordpos == "1") {
  1539. if(heardsordleft != "") {
  1540. str += "(좌: " + heardsordleft + ")";
  1541. }
  1542. } else if(heardsordpos == "2") {
  1543. if(heardsordrght != "") {
  1544. str += "(우: " + heardsordrght + ")";
  1545. }
  1546. }
  1547. }
  1548. if(heardsordkind != "") {
  1549. arr = heardsordkind.split(" ");
  1550. str += ", " + arr;
  1551. }
  1552. }
  1553. model.setValue(xWardRecPath + "/heardsordinfo/heardsord/heardsordyn", str);
  1554. }
  1555. //치아상태
  1556. var tootstatkind = model.getValue(xWardRecPath + "/tootstatinfo/tootstat/tootstatkind");
  1557. if(tootstatkind != "") {
  1558. arr = chk_tootstatkind.label.split(" ");
  1559. model.setValue(xWardRecPath + "/tootstatinfo/tootstat/tootstatkind", arr);
  1560. }
  1561. }
  1562. function fMake_SignData() {
  1563. //JCI 교육요구도 추가 (20100113 김홍점)
  1564. var instUseYN = model.getValue("/root/codeinfo/codeinfo/codelist[cdgrupid ='172']/cdid");//교육요구도 추가 20091216 김홍점
  1565. if ( instUseYN =="Y" ){
  1566. Sign.addnode("/root/temp/signdata/edurecinfo");
  1567. }
  1568. Sign.addnode("/root/main/wardrecinfo");
  1569. Sign.addnode("/root/main/histinfo");
  1570. //가족사항 정보 생성(그리드형식)
  1571. model.removeNodeset("/root/main/famyfactinfo");
  1572. model.makeNode("/root/main/famyfactinfo");
  1573. for(var i=1; i <= getNodesetCount("/root/main/famyfact"); i++) {
  1574. if(model.getValue("/root/main/famyfact["+ i +"]/rela") != ""){
  1575. model.duplicate("/root/main/famyfactinfo", "/root/main/famyfact["+ i +"]");
  1576. }
  1577. }
  1578. Sign.addnode("/root/main/famyfactinfo");
  1579. fSetSignData();
  1580. }
  1581. //이전기록일시 변경
  1582. function fChgRecHistInfo(){
  1583. var recpkspec = (model.getValue("/root/main/wardrecinfo/bfrecddtm")).split("|");
  1584. var bfrecpid = recpkspec[0];
  1585. var bfrecindd = recpkspec[1];
  1586. var bfreccretno = recpkspec[2];
  1587. var bfrecflag = recpkspec[3];
  1588. var bfrecinstcd = recpkspec[4];
  1589. model.removeNodeset("/root/send/req");
  1590. model.makeNode("/root/send/req");
  1591. model.makeValue("/root/send/req/pid", bfrecpid);
  1592. model.makeValue("/root/send/req/indd", bfrecindd);
  1593. model.makeValue("/root/send/req/cretno", bfreccretno);
  1594. model.makeValue("/root/send/req/instcd", bfrecinstcd);
  1595. model.makeValue("/root/send/req/recflag", bfrecflag);
  1596. //model.makeValue("/root/send/req/docucode", "0000002435");
  1597. //model.makeValue("/root/send/req/deptcd", orddeptcd);
  1598. if (bfrecflag == '10'){ //응급실입실기록지
  1599. model.resetInstanceNode("/root/main");
  1600. if(submit("TRMNW03105", false)){
  1601. /* 응급실입실기록지 중 병동간호정보조사지와 같은 item항목을 조회해줌
  1602. : 과거병력, 최근투약상태, 수술이력, 시력장애, 청력장애, 치아상태, 피부계 중 피부상태만, Allergy, 환자기본정보중 연락처/휴대폰/비상연락처(입원시동반자는 제외), 흡연력
  1603. */
  1604. //이전기록자
  1605. model.setValue("/root/main/wardrecinfo/bfrecddtm", model.getValue("/root/hidden/errecinfo/wardrecinfo/recpkspec"));
  1606. model.setValue("/root/main/wardrecinfo/bfrecdd", model.getValue("/root/hidden/errecinfo/wardrecinfo/bfrecdd"));
  1607. model.setValue("/root/main/wardrecinfo/bfrectm", model.getValue("/root/hidden/errecinfo/wardrecinfo/bfrectm"));
  1608. model.setValue("/root/main/wardrecinfo/bfrecuser", model.getValue("/root/hidden/errecinfo/wardrecinfo/bfrecuser"));
  1609. model.setValue("/root/main/wardrecinfo/recdd", model.getValue("/root/hidden/errecinfo/wardrecinfo/recdd"));
  1610. model.setValue("/root/main/wardrecinfo/rectm", model.getValue("/root/hidden/errecinfo/wardrecinfo/rectm"));
  1611. model.setValue("/root/main/wardrecinfo/recuser", model.getValue("/root/hidden/errecinfo/wardrecinfo/recuser"));
  1612. //환자기본정보
  1613. model.setValue("/root/main/wardrecinfo/bdwt", model.getValue("/root/hidden/errecinfo/wardrecinfo/bdwt"));//20100608 khj 몸무게추가
  1614. model.setValue("/root/main/wardrecinfo/tel", model.getValue("/root/hidden/errecinfo/wardrecinfo/tel"));
  1615. model.setValue("/root/main/wardrecinfo/mphone", model.getValue("/root/hidden/errecinfo/wardrecinfo/mphone"));
  1616. model.setValue("/root/main/wardrecinfo/etcphone1", model.getValue("/root/hidden/errecinfo/wardrecinfo/etcphone1"));
  1617. model.setValue("/root/main/wardrecinfo/etcphone2", model.getValue("/root/hidden/errecinfo/wardrecinfo/etcphone2"));
  1618. model.copyNode("/root/main/histinfo/pasthistinfo", "/root/hidden/errecinfo/histinfo/pasthistinfo"); //과거병력
  1619. model.copyNode("/root/main/wardrecinfo/rectmedistatinfo", "/root/hidden/errecinfo/wardrecinfo/rectmedistatinfo"); //최근투약상태
  1620. model.copyNode("/root/main/histinfo/ophistinfo", "/root/hidden/errecinfo/histinfo/ophistinfo"); //수술이력
  1621. model.copyNode("/root/main/histinfo/allghistinfo", "/root/hidden/errecinfo/histinfo/allghistinfo"); //Allergy
  1622. model.copyNode("/root/main/wardrecinfo/visdsordinfo", "/root/hidden/errecinfo/wardrecinfo/visdsordinfo"); //시력장애
  1623. model.copyNode("/root/main/wardrecinfo/heardsordinfo", "/root/hidden/errecinfo/wardrecinfo/heardsordinfo"); //청력장애
  1624. model.copyNode("/root/main/wardrecinfo/tootstatinfo", "/root/hidden/errecinfo/wardrecinfo/tootstatinfo"); //치아상태
  1625. model.copyNode("/root/main/wardrecinfo/skinsectinfo", "/root/hidden/errecinfo/wardrecinfo/skinsectinfo"); //피부계
  1626. model.copyNode("/root/main/wardrecinfo/gustoinfo", "/root/hidden/errecinfo/wardrecinfo/gustoinfo"); //흡연력
  1627. model.setValue("/root/main/wardrecinfo/inpathcd", "02"); //응급실에서 오는 환자인 경우 [입원정보]에서 입원경로 중 "응급실" 자동 체크
  1628. //각 화면 상단에 선택된 환자 정보 display 필요함. (병실-성명-S/A-등록번호), 응급일 경우 정보세팅 - by 박영우 20091204
  1629. var pid;
  1630. var room;
  1631. var patnm;
  1632. var sex;
  1633. var age;
  1634. var instcd;
  1635. var orddeptcd;
  1636. var indd;
  1637. room = model.getValue("/root/temp/cond/list/roomcd");
  1638. patnm = model.getValue("/root/temp/cond/list/hngnm");
  1639. sex = model.getValue("/root/temp/cond/list/sex");
  1640. age = model.getValue("/root/temp/cond/list/age");
  1641. pid = model.getValue("/root/temp/cond/list/pid");
  1642. indd = model.getValue("/root/temp/cond/list/indd");
  1643. instcd = model.getValue("/root/temp/cond/list/instcd");
  1644. orddeptcd = model.getValue("/root/temp/cond/list/orddeptcd");
  1645. model.makeValue("/root/main/wardrecinfo/room", room);
  1646. model.makeValue("/root/main/wardrecinfo/patnm", patnm);
  1647. model.makeValue("/root/main/wardrecinfo/sex", sex);
  1648. model.makeValue("/root/main/wardrecinfo/age", age);
  1649. model.makeValue("/root/main/wardrecinfo/pid", pid);
  1650. }
  1651. }else{ //병동간호정보조사지
  1652. submit("TRMNW03102", false);
  1653. setParameter("SPMMR04711_shape", fGetXmlToStr("/root/main/wardrecinfo/genogrmnm/XMD"));
  1654. }
  1655. /*
  1656. var recDD = getCurrentDate();
  1657. var recDT = getCurrentTime();
  1658. var recUser = getUserName();
  1659. model.setValue("/root/main/wardrecinfo/recdd", recDD);
  1660. model.setValue("/root/main/wardrecinfo/recdt", recDT);
  1661. model.setValue("/root/main/wardrecinfo/recuser", recUser);
  1662. */
  1663. fNotExistsNodeCreate();
  1664. //입원일자 셋팅(응급실 경유 환자인 경우 입실체크가 되는 시점(즉 응급실 퇴실시점)의 일자가 병동 입원일자로 조회됨)_20090303_SMY
  1665. model.setValue("/root/main/wardrecinfo/indd", model.getValue("/root/temp/cond/list/careinrmdd"));
  1666. model.refresh();
  1667. }
  1668. function fCareBodyAssBlock(){
  1669. var msgblock = "";
  1670. // 통증 유무 check가 되지 않은 경우
  1671. if ( (rdo_shpaininfoinclyn != null && isNull(model.getValue(rdo_shpaininfoinclyn.attribute("ref"))) )
  1672. ){
  1673. msgblock += " [통증]";
  1674. }
  1675. // 식욕및체중변화 식욕변화/식욕상태/체중변화의 각 항목에 기록이 되지 않은 경우
  1676. if ( (rdo_apttchngyn != null && isNull(model.getValue(rdo_apttchngyn.attribute("ref"))) )
  1677. || (rdo_apttchngyn != null && model.getValue(rdo_apttchngyn.attribute("ref")) =="2" && rdo_apttchngflag != null && isNull(model.getValue(rdo_apttchngflag.attribute("ref"))) )
  1678. || (rdo_onemealyn != null && isNull(model.getValue(rdo_onemealyn.attribute("ref"))) )
  1679. || (rdo_apttstatflag != null && isNull(model.getValue(rdo_apttstatflag.attribute("ref"))) )
  1680. || (rdo_bdwtchngyn != null && isNull(model.getValue(rdo_bdwtchngyn.attribute("ref"))) )
  1681. || (rdo_bdwtchngyn != null && model.getValue(rdo_bdwtchngyn.attribute("ref")) == "2"
  1682. && (
  1683. // rdo_incdecflag != null && isNull(model.getValue(rdo_incdecflag.attribute("ref")))
  1684. // || ipt_chnggrde != null && isNull(model.getValue(ipt_chnggrde.attribute("ref")))
  1685. (!( rdo_incdecflag != null && isNull(model.getValue(rdo_incdecflag.attribute("ref")))) && ipt_chnggrde != null && isNull(model.getValue(ipt_chnggrde.attribute("ref"))) )//체중변화증가/감소선택 했을때만 체중기록필수입력체크(소경화ITC요청)
  1686. || rdo_bdwtchngtermflag != null && isNull(model.getValue(rdo_bdwtchngtermflag.attribute("ref")))
  1687. //|| ipt_term != null && isNull(model.getValue(ipt_term.attribute("ref")))
  1688. )
  1689. )
  1690. ){
  1691. msgblock += " [식욕 및 체중변화]";
  1692. }
  1693. // 의식상태 지남력/의식상태/의사소통/정서상태의 각 항목에 기록이 되지않은 경우
  1694. if ( (cmb_cscsstathuman != null && isNull(model.getValue(cmb_cscsstathuman.attribute("ref"))) )
  1695. || (cmb_cscsstattm != null && isNull(model.getValue(cmb_cscsstattm.attribute("ref"))) )
  1696. || (cmb_cscsstatplce != null && isNull(model.getValue(cmb_cscsstatplce.attribute("ref"))) )
  1697. || (cmb_cscsstat != null && isNull(model.getValue(cmb_cscsstat.attribute("ref"))) )
  1698. || (rdo_communication != null && isNull(model.getValue(rdo_communication.attribute("ref"))) )
  1699. || (cmb_emotstat != null && isNull(model.getValue(cmb_emotstat.attribute("ref"))) )
  1700. ){
  1701. msgblock += " [의식상태]";
  1702. }
  1703. // 소화기계 해당없음 또는 행추가하여 기록하지 않은 경우
  1704. if ( (chk_digorgninfoinclyn != null && isNull(model.getValue(chk_digorgninfoinclyn.attribute("ref")))
  1705. && grd_digorgn != null && isNull(model.getValue(grd_digorgn.attribute("nodeset")+ "[1]/symp") ) && isNull(model.getValue(grd_digorgn.attribute("nodeset")+ "[1]/cate") ) )
  1706. ){
  1707. msgblock += " [소화기계]";
  1708. }
  1709. // 비뇨기계 소변횟수/소변량/소변냄새 항목에 기록하지 않은 경우
  1710. if ( (ipt_urinetims != null && isNull(model.getValue(ipt_urinetims.attribute("ref"))) && rdo_urinecateyn != null && model.getValue(rdo_urinecateyn.attribute("ref")) =="1")
  1711. || (ipt_urineday != null && isNull(model.getValue(ipt_urineday.attribute("ref"))) && rdo_urinecateyn != null && model.getValue(rdo_urinecateyn.attribute("ref")) =="1")
  1712. || (ipt_urinevol != null && isNull(model.getValue(ipt_urinevol.attribute("ref"))) )
  1713. || (cmb_urinevoldaytime != null && isNull(model.getValue(cmb_urinevoldaytime.attribute("ref"))) )
  1714. || (ipt_urinesmell != null && isNull(model.getValue(ipt_urinesmell.attribute("ref"))) )
  1715. || (rdo_urinecateyn != null && isNull(model.getValue(rdo_urinecateyn.attribute("ref"))) )
  1716. ){
  1717. msgblock += " [비뇨기계]";
  1718. }
  1719. // 대변 대변횟수/마지막대변일/대변색깔/대변종류 항목에 기록하지 않은 경우
  1720. if ( (ipt_stooltims != null && isNull(model.getValue(ipt_stooltims.attribute("ref"))) && rdo_stoolcateyn != null && model.getValue(rdo_stoolcateyn.attribute("ref")) =="1")
  1721. || (ipt_stoolday != null && isNull(model.getValue(ipt_stoolday.attribute("ref"))) && rdo_stoolcateyn != null && model.getValue(rdo_stoolcateyn.attribute("ref")) =="1")
  1722. || (ipt_laststoolday != null && isNull(model.getValue(ipt_laststoolday.attribute("ref"))) )
  1723. || (cmb_stoolcolor != null && isNull(model.getValue(cmb_stoolcolor.attribute("ref"))) )
  1724. || (cmb_stoolkind != null && isNull(model.getValue(cmb_stoolkind.attribute("ref"))) )
  1725. || (rdo_stoolcateyn != null && isNull(model.getValue(rdo_stoolcateyn.attribute("ref"))) )
  1726. ){
  1727. msgblock += " [대변]";
  1728. }
  1729. // 활동 활동 항목에 기록하지 않은 경우
  1730. if ( (rdo_actfreeyn != null && isNull(model.getValue(rdo_actfreeyn.attribute("ref"))) )
  1731. ){
  1732. msgblock += " [활동]";
  1733. }
  1734. // 신경계 해당없음 또는 동공 항목 중 대칭 또는 비대칭을 기록하지 않은 경우
  1735. if ( (chk_nvesysinfoinclyn != null && isNull(model.getValue(chk_nvesysinfoinclyn.attribute("ref"))) )
  1736. && (rdo_pupilsymmetryyn != null && isNull(model.getValue(rdo_pupilsymmetryyn.attribute("ref"))) )
  1737. ){
  1738. msgblock += " [신경계]";
  1739. }
  1740. // 시력장애 시력장애 항목 중 무/유 기록하지 않은 경우
  1741. if ( (rdo_visdsordyn != null && isNull(model.getValue(rdo_visdsordyn.attribute("ref"))) )
  1742. ){
  1743. msgblock += " [시력장애]";
  1744. }
  1745. // 청력장애 청력장애 항목 중 무/유 기록하지 않은 경우
  1746. if ( (rdo_heardsordyn != null && isNull(model.getValue(rdo_heardsordyn.attribute("ref"))) )
  1747. ){
  1748. msgblock += " [청력장애]";
  1749. }
  1750. // 치아상태 치아상태에 check가 되지 않은 경우
  1751. if ( (chk_tootstatkind != null && isNull(model.getValue(chk_tootstatkind.attribute("ref")).getTrim()) )
  1752. ){
  1753. msgblock += " [치아상태]";
  1754. }
  1755. return msgblock;
  1756. }
  1757. ]]>
  1758. </script>
  1759. <script type="javascript" src="../../../emr/carecomweb/js/CareCom.js"/>
  1760. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  1761. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  1762. <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
  1763. <script type="javascript" src="../../../com/commonweb/js/stringHelper.js"/>
  1764. <script type="javascript" src="../../../com/basiccodeweb/js/ZBC001.js"/>
  1765. <script type="javascript" src="../../../emr/formmngtweb/js/MRF03800.js"/>
  1766. <script type="javascript" src="../../../emr/carecomweb/js/ENRSignEngine.js"/>
  1767. <submission id="TRMNW00001" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/codeinfo/codelist"/>
  1768. <submission id="TRMNW03101" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/req" resultref="/root/hidden/paminfo"/>
  1769. <submission id="TRMNW03102" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/req" resultref="/root/main"/>
  1770. <submission id="TRMNW03103" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/req" resultref="/root/init/newpat"/>
  1771. <submission id="TRMNW03104" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/req" resultref="/root/hidden/cominfo"/>
  1772. <submission id="TRMNW03105" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/req" resultref="/root/hidden/errecinfo"/>
  1773. <submission id="TXMNW03101" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/wardrecinfo" resultref="/root/hidden/rsltinfo"/>
  1774. <submission id="TXMNW03102" mediatype="application/x-www-form-urlencoded" method="post" resultref="/root/hidden/rsltinfo"/>
  1775. <submission id="TRZBC00101" mediatype="application/x-www-form-urlencoded" method="post"/>
  1776. <submission id="TRMNZ00201" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main/enrcarecomrecinfo"/>
  1777. <submission id="TRMNW04802" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main/detlgrup"/>
  1778. </model>
  1779. </xhtml:head>
  1780. <xhtml:body guideline="1,1426;" style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
  1781. <group id="group1" style="left:0px; top:0px; width:1195px; height:13px; ">
  1782. <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:189px; height:15px; ">간호초기평가(일반병동)</caption>
  1783. </group>
  1784. <group id="group3" scroll="auto" style="left:0px; top:13px; width:1195px; height:744px; ">
  1785. <group id="grp_patinfo" scroll="auto" style="left:210px; top:50px; width:640px; height:20px; ">
  1786. <caption id="caption10" ref="/root/main/wardrecinfo/pid" style="left:534px; top:0px; width:96px; height:20px; font-family:돋움; "/>
  1787. <caption id="caption1" ref="/root/main/wardrecinfo/room" style="left:53px; top:0px; width:52px; height:20px; font-family:돋움; "/>
  1788. <caption id="caption2" ref="/root/main/wardrecinfo/patnm" style="left:180px; top:0px; width:60px; height:20px; font-family:돋움; "/>
  1789. <caption id="caption3" class="search_name" style="left:112px; top:1px; width:68px; height:17px; ">환자명:</caption>
  1790. <caption id="caption4" ref="/root/main/wardrecinfo/sex" style="left:308px; top:0px; width:32px; height:20px; font-family:돋움; "/>
  1791. <caption id="caption68" class="search_name" style="left:0px; top:1px; width:55px; height:17px; ">병실:</caption>
  1792. <caption id="caption5" class="search_name" style="left:250px; top:1px; width:58px; height:17px; ">성별:</caption>
  1793. <caption id="caption7" ref="/root/main/wardrecinfo/age" style="left:408px; top:0px; width:37px; height:20px; font-family:돋움; "/>
  1794. <caption id="caption8" class="search_name" style="left:350px; top:1px; width:58px; height:17px; ">나이:</caption>
  1795. <caption id="caption9" class="search_name" style="left:450px; top:1px; width:81px; height:17px; ">등록번호:</caption>
  1796. </group>
  1797. <input id="ipt_bfrecdd" ref="/root/main/wardrecinfo/bfrecdd" class="input_default" disabled="true" visibility="hidden" inputtype="date" style="left:83px; top:45px; width:100px; height:19px; "/>
  1798. <output id="opt_bfrectm" ref="/root/main/wardrecinfo/bfrectm" class="output_fix" visibility="hidden" format="hh:nn" style="left:186px; top:45px; width:50px; height:19px; "/>
  1799. <button id="btn_gnrlinfo" class="btn_sw" group="tab" selected="true" style="left:0px; top:49px; width:100px; height:22px; ">
  1800. <caption>일반정보</caption>
  1801. <toggle case="case1" ev:event="onclick"/>
  1802. </button>
  1803. <button id="btn_bodyasses" class="btn_sw" group="tab" style="left:100px; top:49px; width:100px; height:22px; ">
  1804. <caption>신체사정</caption>
  1805. <toggle case="case2" ev:event="onclick"/>
  1806. </button>
  1807. <button id="btn_edurec" class="btn_sw" visibility="hidden" group="tab" style="left:200px; top:49px; width:100px; height:22px; ">
  1808. <caption>교육요구도</caption>
  1809. <toggle case="case_edurec" ev:event="onclick"/>
  1810. </button>
  1811. <switch id="switch1" style="left:0px; top:70px; width:1194px; height:670px; border-color:#c7a3cf; border-style:solid; ">
  1812. <case id="case1" selected="true" style="left:0px; top:0px; width:1194px; height:674px; ">
  1813. <import id="import1" instancetype="merge" src="..\..\..\emr\wardcareweb\xrw\SMMNW07600_일반정보.xrw" style="left:0px; top:0px; width:1194px; height:670px; "/>
  1814. </case>
  1815. <case id="case2" style="left:0px; top:0px; width:1194px; height:673px; border-color:transparent; ">
  1816. <import id="import4" instancetype="merge" src="..\..\..\emr\wardcareweb\xrw\SMMNW07700_신체사정.xrw" style="left:0px; top:0px; width:1194px; height:670px; "/>
  1817. </case>
  1818. <case id="case_edurec" style="left:0px; top:0px; width:1194px; height:673px; border-color:transparent; ">
  1819. <iviewer id="ivw_edurec" style="left:0px; top:0px; width:1194px; height:670px; "/>
  1820. </case>
  1821. </switch>
  1822. <line id="line64" class="line_3" style="x1:0px; y1:41px; x2:1194px; y2:41px; "/>
  1823. <line id="line13" class="line_1" style="x1:0px; y1:13px; x2:1194px; y2:13px; "/>
  1824. <caption id="cap_bfrecdt" class="cell_1" style="left:0px; top:18px; width:80px; height:23px; vertical-align:middle; ">이전기록일시</caption>
  1825. <caption id="cap_bfrecuser" class="cell_1" style="left:205px; top:18px; width:67px; height:23px; vertical-align:middle; ">이전기록자</caption>
  1826. <output id="opt_bfrecuser" ref="/root/main/wardrecinfo/bfrecuser" class="output_fix" style="left:274px; top:20px; width:75px; height:19px; "/>
  1827. <caption id="cap_recdt" class="cell_1" style="left:351px; top:18px; width:56px; height:23px; vertical-align:middle; ">기록일시</caption>
  1828. <input id="ipt_recdd" ref="/root/main/wardrecinfo/recdd" class="input_default" inputtype="date" style="left:409px; top:20px; width:90px; height:19px; "/>
  1829. <input id="ipt_rectm" ref="/root/main/wardrecinfo/rectm" class="input_default" format="hh:nn" validateformat="true" style="left:500px; top:20px; width:50px; height:19px; "/>
  1830. <caption id="cap_recuser" class="cell_1" style="left:553px; top:18px; width:47px; height:23px; vertical-align:middle; ">기록자</caption>
  1831. <output id="opt_recuser" ref="/root/main/wardrecinfo/recuser" class="output_fix" style="left:601px; top:20px; width:75px; height:19px; "/>
  1832. <caption id="cap_sinfodnor" class="cell_1" style="left:677px; top:18px; width:68px; height:23px; vertical-align:middle; ">정보제공자</caption>
  1833. <input id="ipt_infooffer" ref="/root/main/wardrecinfo/infooffer" class="input_default" maxlength="10" style="left:747px; top:20px; width:97px; height:19px; "/>
  1834. <button id="btn_save" class="btn2_letter4" style="left:1062px; top:49px; width:64px; height:19px; ">
  1835. <caption>임시저장</caption>
  1836. <script type="javascript" ev:event="DOMActivate">
  1837. <![CDATA[
  1838. //debugger;
  1839. fPatgnrlInfo("T");
  1840. if(submit("TXMNW03101") == true) {
  1841. grd_famyfact.clearStatus();
  1842. model.setValue("/root/send/wardrecinfo", "");
  1843. messageBox("저장이 ", "I001");
  1844. // //mrfmform formnm,formtypecls, ocrtagprntyn (서식명칭, 서식type, ocrtag출력여부)
  1845. // //fPrint(prntflag) 저장시 prntflag 필요없음, 저장이 필요없으면 'A'
  1846. // //iveiwer.window.javascript.fGetOCRInfo(
  1847. // // iviewer1.window.javascript.fGetOCRInfo("0000001778", "20694", "20070824", "1", "I", "3", "Y");
  1848. //
  1849. // // iviewer1.window.javascript.fGetOCRInfo("0000001778", "20694", "20070824", "1", "I", "3", "Y");
  1850. // // iviewer1.window.javascript.fPrint("A");
  1851. model.makeValue("/root/hidden/paminfo/paminfo/exeflag", "U");
  1852. } else {
  1853. messageBox("저장이 실패하였습니다. ", "E");
  1854. }
  1855. ]]>
  1856. </script>
  1857. </button>
  1858. <iviewer id="iviewer1" visibility="hidden" style="left:280px; top:75px; width:390px; height:110px; "/>
  1859. <button id="btn_signsave" class="btn5_letter4" style="left:1129px; top:49px; width:64px; height:19px; ">
  1860. <caption>인증저장</caption>
  1861. <script type="javascript" ev:event="DOMActivate">
  1862. <![CDATA[
  1863. //debugger;
  1864. var msgstr = "";
  1865. var instUseYN = model.getValue("/root/codeinfo/codeinfo/codelist[cdgrupid ='172']/cdid");//교육요구도 추가 20091216 김홍점
  1866. //가족사항 : 관계 필수 입력
  1867. for(var i = 1 ; i < grd_famyfact.rows; i++) {
  1868. var rela = model.getValue("/root/main/famyfact[" + i + "]/rela");
  1869. if(rela == "") {
  1870. var msg1 = "[가족사항 - 관계]";
  1871. msgstr += msg1;
  1872. break;
  1873. }
  1874. }
  1875. //필수입력사항 blocking
  1876. if(model.getValue("/root/main/wardrecinfo/spo2") == "" && model.getValue("/root/main/wardrecinfo/spo2inspyn") != "Y"){
  1877. var msg2 = "[SpO2]";
  1878. if(msgstr == ""){
  1879. msgstr += msg2;
  1880. }else{
  1881. msgstr += ", " + msg2;
  1882. }
  1883. }
  1884. if(model.getValue("/root/main/wardrecinfo/infooffer") == ""){
  1885. var msg9 = "[정보제공자]";
  1886. if(msgstr == ""){
  1887. msgstr += msg9;
  1888. }else{
  1889. msgstr += ", " + msg9;
  1890. }
  1891. }
  1892. // '16.04.18 - 발병일자 필수 입력
  1893. if(model.getValue("/root/main/wardrecinfo/inmotiveinfo/inmotive/attackdd") == ""){
  1894. var msg15 = "[발병일자]";
  1895. if(msgstr == ""){
  1896. msgstr += msg15;
  1897. }else{
  1898. msgstr += ", " + msg15;
  1899. }
  1900. }
  1901. // '16.04.18 - 발병시간 필수 입력
  1902. if(model.getValue("/root/main/wardrecinfo/inmotiveinfo/inmotive/attackdt") == ""){
  1903. var msg16 = "[발병시간]";
  1904. if(msgstr == ""){
  1905. msgstr += msg16;
  1906. }else{
  1907. msgstr += ", " + msg16;
  1908. }
  1909. }
  1910. if(model.getValue("/root/main/wardrecinfo/inmotiveinfo/inmotive/inmotive1") == "" || model.getValue("/root/main/wardrecinfo/inmotiveinfo/inmotive/inmotive2") == ""){
  1911. var msg10 = "[입원동기]";
  1912. if(msgstr == ""){
  1913. msgstr += msg10;
  1914. }else{
  1915. msgstr += ", " + msg10;
  1916. }
  1917. }
  1918. if(model.getValue("/root/main/wardrecinfo/gustoinfo/gusto/smokinfo/smokinfoyn") == ""){
  1919. var msg3 = "[흡연정보]";
  1920. if(msgstr == ""){
  1921. msgstr += msg3;
  1922. }else{
  1923. msgstr += ", " + msg3;
  1924. }
  1925. }
  1926. if(model.getValue("/root/main/wardrecinfo/gustoinfo/gusto/smokinfo/smokinfoyn") == "2"){
  1927. if(model.getValue("/root/main/wardrecinfo/gustoinfo/gusto/smokinfo/bfsmokinfoyn") == ""){
  1928. var msg13 = "[입원전1개월이내 흡연여부]";
  1929. if(msgstr == ""){
  1930. msgstr += msg13;
  1931. }else{
  1932. msgstr += ", " + msg13;
  1933. }
  1934. }
  1935. }
  1936. if(model.getValue("/root/main/wardrecinfo/gustoinfo/gusto/smokinfo/nosmokcnstyn") == ""){
  1937. var msg4 = "[금연상담여부]";
  1938. if(msgstr == ""){
  1939. msgstr += msg4;
  1940. }else{
  1941. msgstr += ", " + msg4;
  1942. }
  1943. }else if(model.getValue("/root/main/wardrecinfo/gustoinfo/gusto/smokinfo/nosmokcnstyn") == "1"){
  1944. if(model.getValue("/root/main/wardrecinfo/gustoinfo/gusto/smokinfo/smokinfoyn")=="4" ||
  1945. (model.getValue("/root/main/wardrecinfo/gustoinfo/gusto/smokinfo/smokinfoyn")=="2"
  1946. &model.getValue("/root/main/wardrecinfo/gustoinfo/gusto/smokinfo/bfsmokinfoyn")=="Y")){
  1947. if(model.getValue("/root/main/wardrecinfo/gustoinfo/gusto/smokinfo/nosmokcnst")==""
  1948. && model.getValue("/root/main/wardrecinfo/gustoinfo/gusto/smokinfo/nosmokcnstnm")=="") {
  1949. var msg8 = "[금연상담여부사유]";
  1950. if(msgstr == ""){
  1951. msgstr += msg8;
  1952. }else{
  1953. msgstr += ", " + msg8;
  1954. }
  1955. }
  1956. }
  1957. }
  1958. if(model.getValue("/root/main/wardrecinfo/rectmedistatinfo/rectmedistat/antibiodrugyn") == ""){
  1959. var msg5 = "[병원도착전 24시간내 항생제 투약여부]";
  1960. if(msgstr == ""){
  1961. msgstr += msg5;
  1962. }else{
  1963. msgstr += ", " + msg5;
  1964. }
  1965. }
  1966. //20090626_SMY추가
  1967. if(model.getValue("/root/codeinfo/codeinfo/codelist[cdgrupid = '077' and supcdid = '02' and cdid = '"+ getUserInfo("dutplceinstcd") +"']/cdid") || model.getValue("/root/codeinfo/codeinfo/codelist[cdgrupid = '077' and supcdid = '03' and cdid = '"+ getUserInfo("dutplceinstcd") +"']/cdid")){ //supcdid='02' : 의정부성모, 03 : 부천성가병원
  1968. if(model.getValue("/root/main/wardrecinfo/bdht") == "" && model.getValue("/root/main/wardrecinfo/bdhtinspyn") != "Y"){
  1969. var msg6 = "[신장]";
  1970. if(msgstr == ""){
  1971. msgstr += msg6;
  1972. }else{
  1973. msgstr += ", " + msg6;
  1974. }
  1975. }
  1976. if(model.getValue("/root/main/wardrecinfo/bdwt") == "" && model.getValue("/root/main/wardrecinfo/bdwtinspyn") != "Y"){
  1977. var msg7 = "[체중]";
  1978. if(msgstr == ""){
  1979. msgstr += msg7;
  1980. }else{
  1981. msgstr += ", " + msg7;
  1982. }
  1983. }
  1984. }
  1985. //------------(20110121) 경북대
  1986. //해당인스턴스가 있는지 확인한다.
  1987. if ( instance1.selectSingleNode("/root/main/wardrecinfo/nrs1cd") != null) {
  1988. if(model.getValue("/root/main/wardrecinfo/nrs1cd") == ""){
  1989. var msg8 = "[영양상태지표]";
  1990. if(msgstr == ""){
  1991. msgstr += msg8;
  1992. }else{
  1993. msgstr += ", " + msg8;
  1994. }
  1995. }
  1996. }
  1997. if ( instance1.selectSingleNode("/root/main/wardrecinfo/nrs21cd") != null) {
  1998. if(model.getValue("/root/main/wardrecinfo/nrs21cd") == ""){
  1999. var msg9 = "[임상상태지표1]";
  2000. if(msgstr == ""){
  2001. msgstr += msg9;
  2002. }else{
  2003. msgstr += ", " + msg9;
  2004. }
  2005. }
  2006. }
  2007. if ( instance1.selectSingleNode("/root/main/wardrecinfo/nrs22cd") != null) {
  2008. if(model.getValue("/root/main/wardrecinfo/nrs22cd") == ""){
  2009. var msg10 = "[영양상태지표2]";
  2010. if(msgstr == ""){
  2011. msgstr += msg10;
  2012. }else{
  2013. msgstr += ", " + msg10;
  2014. }
  2015. }
  2016. }
  2017. if ( instance1.selectSingleNode("/root/main/wardrecinfo/nrs23cd") != null) {
  2018. if(model.getValue("/root/main/wardrecinfo/nrs23cd") == ""){
  2019. var msg11 = "[영양상태지표3]";
  2020. if(msgstr == ""){
  2021. msgstr += msg11;
  2022. }else{
  2023. msgstr += ", " + msg11;
  2024. }
  2025. }
  2026. }
  2027. //20110308 이선경(경북대) 통증여부가 '유'일때 통증관리기록이 있는지 체크
  2028. if(model.getValue("/root/main/wardrecinfo/shpaininfo/shpain/shpaininfoinclyn") == "2") {
  2029. model.makeValue("/root/send/pid", model.getValue("/root/temp/cond/list/pid"));
  2030. model.makeValue("/root/send/indd", model.getValue("/root/temp/cond/list/indd"));
  2031. model.makeValue("/root/send/cretno", model.getValue("/root/temp/cond/list/cretno"));
  2032. model.makeValue("/root/send/genrdd", getCurrentDate());
  2033. model.makeValue("/root/send/genrtm", getCurrentDateTime().substring(9,13));
  2034. model.makeValue("/root/send/stdradio", "0");
  2035. model.makeValue("/root/send/req/indd", model.getValue("/root/temp/cond/list/indd"));
  2036. model.makeValue("/root/send/req/cretno", model.getValue("/root/temp/cond/list/cretno"));
  2037. submit('TRMNW04802');
  2038. if(getNodesetCount("/root/main/detlgrup/detlgruplist") == 0) {
  2039. var msg12 = "[통증관리기록]";
  2040. if(msgstr == ""){
  2041. msgstr += msg12;
  2042. }else{
  2043. msgstr += ", " + msg12;
  2044. }
  2045. }
  2046. } else { // '16.04.18 - AYS 추가
  2047. if(model.getValue("/root/main/wardrecinfo/shpaininfo/shpain/shpaininfoflag") == "") {
  2048. var msg14 = "[통증]";
  2049. if(msgstr == ""){
  2050. msgstr += msg14;
  2051. }else{
  2052. msgstr += ", " + msg14;
  2053. }
  2054. }
  2055. }
  2056. //------------(20110121) 경북대
  2057. if ( instUseYN =="Y"){
  2058. var msgblock = fCareBodyAssBlock();
  2059. if( msgblock != ""){
  2060. msgstr += "\n" + msgblock;
  2061. }
  2062. }
  2063. if(msgstr != "" ){
  2064. messageBox(msgstr + " 은(는) ", "I003");//필수입력입니다
  2065. return;
  2066. }
  2067. //------------(20110121) 경북대
  2068. //aaaaaaaaaaaaaaa
  2069. //return
  2070. //------------(20110121) 경북대
  2071. fPatgnrlInfo("C");
  2072. //20100115 JCI 김홍점 교육요구도 적용병원만 데이타 저장 및 인증데이타 생성
  2073. if ( instUseYN =="Y"){
  2074. model.removenode('/root/temp/signdata');
  2075. if ( !ivw_edurec.window.javascript.fSave() ){
  2076. return;
  2077. }
  2078. var xEduRecPath = '/root/temp/signdata/edurecinfo';
  2079. fMNWCareInfoRecMakeForJCI(xEduRecPath, ivw_edurec, "N");//carecom.js (srcPath, destObj , 응급간호정보조사여부 구분 erYn)
  2080. }
  2081. //최초기록자
  2082. fMNWCareComFstdtSet( "01", "SAVE" );
  2083. Sign.certreload = true ;
  2084. if (Sign.signprocess() == true){
  2085. //src="C:\CMCProject\application\webapps\emr\formmngtweb\xrw\SSMRF03800_OCR뷰어.xrw"
  2086. // alert("인증성공" );
  2087. // alert("1. 인증성공여부 false / true \n\n" + Sign.signedInfos[0]); // 인증성공여부 false / true
  2088. // alert("2. 인증할 데이터 정보 (미기록 노드 제거전 원본 노드) \n\n" + Sign.signedInfos[3]); // 인증할 데이터 정보 (미기록 노드 제거전 원본 노드)
  2089. // alert("2.--> text 데이터(없는 노드 포함된) text 형태 변형 결과 \n\n" + Sign.signedInfos[4]); // [3] 데이터(없는 노드 포함된) text 형태 변형 결과
  2090. // alert("3. 인증할 데이터 정보(미기록 노드 제거된 정보) \n\n" + Sign.signedInfos[1]); // 인증할 데이터 정보(미기록 노드 제거된 정보)
  2091. // alert("3. -->text 데이터(없는 노드 제거된) text 형태 변형 결과 \n\n" + Sign.signedInfos[5]); // ★[1] 데이터(없는 노드 제거된) text 형태 변형 결과 >>> [5]
  2092. // alert("3. -->text --> sign 공인인증 처리후 데이터 \n\n" + Sign.signedInfos[2]); // ★공인인증 처리후 데이터 >>> [2]
  2093. //
  2094. model.makeValue("/root/send/wardrecinfo/pid", model.getValue("/root/temp/cond/list/pid"));
  2095. model.makeValue("/root/send/wardrecinfo/indd", model.getValue("/root/temp/cond/list/indd"));
  2096. //model.makeValue("/root/send/wardrecinfo/signno", model.getValue("/root/main/wardrecinfo/signno"));
  2097. model.makeValue("/root/send/wardrecinfo/signno", model.getValue("/root/signinfo/signno")); //20090722_SMY변경
  2098. model.makeValue("/root/send/wardrecinfo/cretno", model.getValue("/root/temp/cond/list/cretno"));
  2099. model.makeValue("/root/send/wardrecinfo/recdd", model.getValue("/root/main/wardrecinfo/recdd"));
  2100. model.makeValue("/root/send/wardrecinfo/rectm", model.getValue("/root/main/wardrecinfo/rectm"));
  2101. //model.makeValue("/root/send/wardrecinfo/recsaveflag", model.getValue("Y"));
  2102. model.makeValue("/root/send/wardrecinfo/recsaveflag", "Y");
  2103. model.makeValue("/root/send/wardrecinfo/signflag", "02");
  2104. model.makeValue("/root/send/wardrecinfo/signgenrflag", model.getValue("/root/temp/cond/list/ioflag"));
  2105. model.makeValue("/root/send/wardrecinfo/formcd", "0000002435");
  2106. model.makeValue("/root/send/wardrecinfo/orddeptcd", model.getValue("/root/temp/cond/list/orddeptcd"));
  2107. model.makeValue("/root/send/wardrecinfo/orddrid", model.getValue("/root/temp/cond/list/medispclid"));
  2108. model.makeValue("/root/send/wardrecinfo/signbfcnts", Sign.signedInfos[1]);
  2109. model.makeValue("/root/send/wardrecinfo/signaftcnts", Sign.signedInfos[2]);
  2110. model.makeValue("/root/send/wardrecinfo/wardcd", model.getValue("/root/temp/cond/list/wardcd"));
  2111. model.makeValue("/root/send/wardrecinfo/roomcd", model.getValue("/root/temp/cond/list/roomcd"));
  2112. model.makeValue("/root/send/wardrecinfo/instcd", model.getValue("/root/temp/cond/list/instcd"));
  2113. if(submit("TXMNW03101") == true) {
  2114. grd_famyfact.clearStatus();
  2115. model.setValue("/root/send/wardrecinfo", "");
  2116. messageBox("저장이 ", "I001");
  2117. // //mrfmform formnm,formtypecls, ocrtagprntyn (서식명칭, 서식type, ocrtag출력여부)
  2118. // //fPrint(prntflag) 저장시 prntflag 필요없음, 저장이 필요없으면 'A'
  2119. // //iveiwer.window.javascript.fGetOCRInfo(
  2120. // // iviewer1.window.javascript.fGetOCRInfo("0000001778", "20694", "20070824", "1", "I", "3", "Y");
  2121. //iviewer1.window.javascript.fGetOCRInfo("0000001778", "20694", "20070824", "1", "I", "3", "Y");
  2122. //iviewer1.window.javascript.fPrint("A");
  2123. model.makeValue("/root/hidden/paminfo/paminfo/exeflag", "U");
  2124. //fGetInitRecInfo(); //재조회
  2125. //fInitEvent();
  2126. } else {
  2127. messageBox("저장이 실패하였습니다. ", "E");
  2128. }
  2129. }
  2130. ]]>
  2131. </script>
  2132. </button>
  2133. <input id="ipt_signno" ref="/root/main/wardrecinfo/signno" visibility="hidden" style="left:860px; top:45px; width:50px; height:19px; "/>
  2134. <select1 id="cmb_bfrecddtm" ref="/root/main/wardrecinfo/bfrecddtm" class="combo_default" navindex="16" appearance="minimal" style="left:83px; top:20px; width:120px; height:19px; ">
  2135. <choices>
  2136. <itemset nodeset="/root/hidden/paminfo/recinfo">
  2137. <label ref="bfrecddtm"/>
  2138. <value ref="recpkspec"/>
  2139. </itemset>
  2140. </choices>
  2141. <script type="javascript" ev:event="xforms-value-changed">
  2142. <![CDATA[
  2143. fChgRecHistInfo();
  2144. fMNWCareComFstdtSet( "01", "SRCH" );//recflag : 간호정보조사 플래그 CareCom.js 간호정보조사 최초기록일시 및 사용자 세팅
  2145. model.refresh();
  2146. ]]>
  2147. </script>
  2148. </select1>
  2149. <button id="button1" class="btn2_letter6" style="left:973px; top:49px; width:86px; height:19px; ">
  2150. <caption>전체기록삭제</caption>
  2151. <script type="javascript" ev:event="DOMActivate">
  2152. <![CDATA[
  2153. setCareInfoDel("TXMNW03101"); //CareCom.js
  2154. fGetIndtInfo(); //현재수진이력의 입원시간을 가져온다
  2155. ]]>
  2156. </script>
  2157. </button>
  2158. <caption id="caption11" class="cell_1" style="left:1044px; top:18px; width:71px; height:23px; vertical-align:middle; ">최초기록자</caption>
  2159. <output id="output1" ref="/root/main/wardrecinfo/fstrgstdt" class="output_fix" style="left:927px; top:20px; width:115px; height:19px; "/>
  2160. <caption id="caption12" class="cell_1" style="left:845px; top:18px; width:80px; height:23px; vertical-align:middle; ">최초기록일시</caption>
  2161. <output id="output2" ref="/root/main/wardrecinfo/fstrgstrnm" class="output_fix" style="left:1116px; top:20px; width:75px; height:19px; "/>
  2162. </group>
  2163. <group id="group4" scroll="auto" style="left:0px; top:756px; width:1195px; height:22px; ">
  2164. <line id="line62" class="line_6" style="x1:0px; y1:0px; x2:1194px; y2:0px; "/>
  2165. <caption id="caption13" style="left:1169px; top:4px; width:26px; height:15px; ">[표]</caption>
  2166. </group>
  2167. </xhtml:body>
  2168. </xhtml:html>