SMMNW14500_IV팀 호출.xrw 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352
  1. <?xml version="1.0" encoding="EUC-KR"?>
  2. <?xml-stylesheet href="../../../com/commonweb/css/common.css" type="text/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>소아IV팀 호출</xhtml:title>
  6. <model id="model1">
  7. <instance id="instance1">
  8. <root xmlns="">
  9. <init/>
  10. <main>
  11. <cond>
  12. <pid/>
  13. <calldeptcd/>
  14. <callremfact/>
  15. <callremfactdesc/>
  16. <hngnm/>
  17. <sex/>
  18. <age/>
  19. <roomcd/>
  20. <acptflag/>
  21. <calltm/>
  22. <calldd/>
  23. <callno/>
  24. <capinfo/>
  25. <cnclflag/>
  26. <calltelno/>
  27. <calluserid/>
  28. <orddeptcd/>
  29. </cond>
  30. <paminfo/>
  31. </main>
  32. <send>
  33. <savedata/>
  34. </send>
  35. <temp>
  36. <patinfo/>
  37. </temp>
  38. <temp2>
  39. <patinfo/>
  40. </temp2>
  41. </root>
  42. </instance>
  43. <script type="javascript" ev:event="xforms-ready">
  44. <![CDATA[
  45. // Duty별 IV팀 근무자 조회, 진료과 코드 조회
  46. model.makeValue("/root/send/instcd" , getUserInfo("dutplceinstcd"));
  47. model.makeValue("/root/send/srchdd" , getCurrentDate()); // 조회기준일자
  48. submit("TRMNW14501");
  49. // 간호공통코드 조회
  50. model.makeValue("/root/send/cdgrupid", "'I05', 'I06', 'I07'");
  51. model.makeValue("/root/send/srchdd" , getCurrentDate()); // 조회기준일자
  52. submit("TRMNW00001", false);
  53. // 부서콤보 조회
  54. submit("TRMNW11001", false);
  55. var pid="";
  56. var indd="";
  57. var cretno="";
  58. model.makeNode("/root/main/paminfo");
  59. var node = getGlobalVariable("paminfo");
  60. setCSVToNode("/root/main/paminfo", node);
  61. //팝업화면이 아닐경우 상단에 환자 정보가 있는지 여부를 확인하고
  62. if (model.getValue("/root/main/paminfo/list/pid") != "") { //상단정보에 환자가 셋팅되어 있을 경우
  63. pid = model.getValue("/root/main/paminfo/list/pid");
  64. } else {
  65. //팝업으로 뜬화면인가 여부확인.팝업일 경우 팝업화면 파라메터를 가지고온다.
  66. if(checkOpener()) {
  67. pid = opener.javascript.getParameter("SMMNW14100_PID");
  68. }
  69. }
  70. //환자 등록번호가 존재할 경우에는
  71. if(pid != "") {
  72. model.setValue(ipt_pid.attribute("ref"), pid);
  73. ipt_pid.refresh();
  74. fSearchPatInfo();
  75. }
  76. ]]>
  77. </script>
  78. <submission id="TRMNW00001" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/init/codeinfo"/>
  79. <submission id="TRMNW14501" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/init/cmblist"/>
  80. <submission id="TRMNW14500" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/reqdata" resultref="/root/temp/patinfo"/>
  81. <submission id="TXMNW14500" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/savedata" resultref="/root/temp/patinfo"/>
  82. <submission id="TRMNW11001" mediatype="application/x-www-form-urlencoded" method="post" resultref="/root/init/deptinfo"/>
  83. <submission id="TRMNW10902" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/reqdata" resultref="/root/init/roominfo"/>
  84. </model>
  85. <script type="javascript">
  86. <![CDATA[
  87. function fSearchPatInfo() {
  88. model.makeValue("/root/send/reqdata/pid", model.getValue(ipt_pid.attribute("ref")));
  89. submit("TRMNW14500");
  90. model.copyNode("/root/main/cond", "/root/temp/patinfo/patlist");
  91. model.makeValue("/root/send/reqdata/wardcd", model.getValue("/root/main/cond/calldeptcd"));
  92. submit("TRMNW10902", false);
  93. if(model.getValue("/root/temp/patinfo/patlist/acptflag") == "0") {
  94. model.setValue("/root/main/cond/capinfo", "호출 하지 않은 환자입니다.");
  95. btn_save.disabled = false;
  96. combo1.visible = false;
  97. combo1.disabled = true;
  98. cmb_calltelno.visible = true;
  99. cmb_calldeptcd.disabled = false;
  100. cmb_orddeptcd.disabled = false;
  101. cmb_callremfact.disabled = false;
  102. tar_callremfactdesc.disabled = false;
  103. cmb_roomcd.disabled = false;
  104. } else if(model.getValue("/root/temp/patinfo/patlist/acptflag") == "1") {
  105. model.setValue("/root/main/cond/capinfo", "이미 호출한 환자입니다.");
  106. btn_save.disabled = true;
  107. combo1.visible = true;
  108. combo1.disabled = true;
  109. cmb_calltelno.visible = false;
  110. cmb_calldeptcd.disabled = true;
  111. cmb_orddeptcd.disabled = true;
  112. cmb_callremfact.disabled = true;
  113. tar_callremfactdesc.disabled = true;
  114. cmb_roomcd.disabled = true;
  115. }else{
  116. model.setValue("/root/main/cond/capinfo", "");
  117. btn_save.disabled = false;
  118. combo1.visible = false;
  119. combo1.disabled = true;
  120. cmb_calltelno.visible = true;
  121. cmb_calldeptcd.disabled = false;
  122. cmb_orddeptcd.disabled = false;
  123. cmb_callremfact.disabled = false;
  124. tar_callremfactdesc.disabled = false;
  125. cmb_roomcd.disabled = false;
  126. }
  127. if(model.getValue("/root/main/cond/orddeptcd") == "" || model.getValue("/root/main/cond/orddeptcd") == "-"){
  128. if(model.getValue("/root/main/cond/pid") == model.getValue("/root/main/paminfo/list/pid")){
  129. model.setValue("/root/main/cond/orddeptcd", model.getValue("/root/main/paminfo/list/orddeptcd")) ;
  130. }
  131. }
  132. if(model.getValue("/root/main/cond/pid") != "" && model.getValue("/root/main/cond/calldeptcd") == ""){
  133. model.setValue("/root/main/cond/calldeptcd", getUserInfo("dutplcecd")) ;
  134. }
  135. model.refresh();
  136. }
  137. ]]>
  138. </script>
  139. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  140. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  141. <script type="javascript" src="../../../com/commonweb/js/stringHelper.js"/>
  142. <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
  143. <script type="javascript" src="../../../com/departmentcodeweb/js/ZSD001.js"/>
  144. </xhtml:head>
  145. <xhtml:body pagewidth="385" pageheight="235" style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
  146. <group id="grp_biz" scroll="auto" style="left:0px; top:0px; width:365px; height:235px; ">
  147. <caption id="caption6" class="tit_2" style="left:0px; top:5px; width:178px; height:15px; ">소아IV팀 호출</caption>
  148. <line id="line1" class="line_1" style="x1:0px; y1:20px; x2:360px; y2:20px; "/>
  149. <select1 id="cmb_callremfact" ref="/root/main/cond/callremfact" appearance="minimal" style="left:77px; top:123px; width:178px; height:19px; ">
  150. <choices>
  151. <itemset nodeset="/root/init/codeinfo/codelist[cdgrupid='I06']">
  152. <label ref="cdnm"/>
  153. <value ref="cdid"/>
  154. </itemset>
  155. </choices>
  156. <script type="javascript" ev:event="xforms-value-changed">
  157. <![CDATA[
  158. ]]>
  159. </script>
  160. </select1>
  161. <input id="ipt_pid" ref="/root/main/cond/pid" style="left:77px; top:26px; width:100px; height:19px; ">
  162. <script type="javascript" ev:event="onkeypress">
  163. <![CDATA[
  164. if(event.keyCode == 13) {
  165. setInputNodeCurText();
  166. fSearchPatInfo();
  167. }
  168. ]]>
  169. </script>
  170. <script type="javascript" ev:event="DOMFocusOut">
  171. <![CDATA[
  172. setInputNodeCurText();
  173. fSearchPatInfo();
  174. ]]>
  175. </script>
  176. </input>
  177. <input id="ipt_hngnm" ref="/root/main/cond/hngnm" disabled="true" style="left:257px; top:26px; width:100px; height:19px; "/>
  178. <line id="line2" class="line_2" style="x1:0px; y1:47px; x2:360px; y2:47px; "/>
  179. <caption id="caption2" class="cell_1" style="left:0px; top:25px; width:75px; height:23px; text-align:center; ">등록번호</caption>
  180. <caption id="caption3" class="cell_1" style="left:180px; top:25px; width:75px; height:23px; text-align:center; ">환자명</caption>
  181. <select1 id="cmb_calldeptcd" ref="/root/main/cond/calldeptcd" appearance="minimal" style="left:77px; top:50px; width:100px; height:19px; ">
  182. <choices>
  183. <itemset nodeset="/root/init/deptinfo/deptlist">
  184. <label ref="depthngnm"/>
  185. <value ref="deptcd"/>
  186. </itemset>
  187. </choices>
  188. <script type="javascript" ev:event="xforms-value-changed">
  189. <![CDATA[
  190. model.setValue("/root/main/cond/roomcd","");
  191. model.removeNodeset("/root/send/reqdata");
  192. model.makeNode("/root/send/reqdata");
  193. model.makeValue("/root/send/reqdata/wardcd", model.getValue("/root/main/cond/calldeptcd"));
  194. submit("TRMNW10902", false);
  195. model.refresh();
  196. ]]>
  197. </script>
  198. </select1>
  199. <line id="line3" class="line_2" style="x1:0px; y1:71px; x2:360px; y2:71px; "/>
  200. <caption id="caption4" class="cell_1" style="left:0px; top:49px; width:75px; height:23px; text-align:center; ">호출부서</caption>
  201. <line id="line6" class="line_2" style="x1:0px; y1:95px; x2:360px; y2:95px; "/>
  202. <caption id="caption1" class="cell_1" style="left:0px; top:122px; width:75px; height:66px; text-align:center; ">IV목적</caption>
  203. <caption id="caption8" class="cell_1" style="left:180px; top:49px; width:75px; height:23px; text-align:center; ">병실(입원)</caption>
  204. <input id="ipt_acptflag" ref="/root/main/cond/acptflag" visibility="hidden" style="left:0px; top:210px; width:100px; height:19px; "/>
  205. <button id="btn_save" class="btn4_letter2" style="left:305px; top:192px; width:56px; height:22px; ">
  206. <caption>호출</caption>
  207. <script type="javascript" ev:event="DOMActivate">
  208. <![CDATA[
  209. var pid = model.getValue(ipt_pid.attribute("ref"));
  210. var hngnm = model.getValue(ipt_hngnm.attribute("ref"));
  211. var calltelno = model.getValue(cmb_calltelno.attribute("ref"));
  212. var callremfact = model.getValue(cmb_callremfact.attribute("ref"));
  213. var calldeptcd = model.getValue(cmb_calldeptcd.attribute("ref"));
  214. var calldeptnm = cmb_calldeptcd.label;
  215. var orddeptcd = model.getValue(cmb_orddeptcd.attribute("ref"));
  216. var orddeptnm = cmb_orddeptcd.label;
  217. if(pid == "") {
  218. messageBox("환자를 선택하십시오.", "E");
  219. return;
  220. }
  221. if(hngnm == "") {
  222. messageBox("환자를 선택하십시오.", "E");
  223. return;
  224. }
  225. if(calldeptcd == "" || calldeptnm == "") {
  226. messageBox("호출부서를 선택하십시오.", "E");
  227. return;
  228. }
  229. if(calltelno == "") {
  230. messageBox("IV팀을 선택하십시오.\n\n(선택 사항이 없는 경우 IV팀 근무표를 확인하십시오.)", "E");
  231. return;
  232. }
  233. if(orddeptcd == "" || orddeptnm == "") {
  234. messageBox("진료과를 선택하십시오.", "E");
  235. return;
  236. }
  237. if(callremfact== "") {
  238. messageBox("IV목적을 선택하십시오.", "E");
  239. return;
  240. }
  241. var rtn = messageBox("호출 하시겠습니까?", "Q");
  242. if(rtn=="6") {
  243. if(model.getValue("/root/main/cond/roomcd") == '-'){
  244. model.setValue("/root/main/cond/roomcd",'');
  245. }
  246. model.copyNode("/root/temp2/patinfo", "/root/main/cond");
  247. model.copyNode("/root/send/savedata", "/root/temp2/patinfo");
  248. model.makeValue("/root/send/savedata/calldeptnm", cmb_calldeptcd.label);
  249. model.makeValue("/root/send/savedata/callremfactnm", cmb_callremfact.label);
  250. model.makeValue("/root/send/savedata/orddeptnm", cmb_orddeptcd.label);
  251. if(submit("TXMNW14500")) {
  252. messageBox("저장되었습니다. ", "I");
  253. fSearchPatInfo();
  254. }
  255. }
  256. ]]>
  257. </script>
  258. </button>
  259. <input id="ipt_calldd" ref="/root/main/cond/calldd" visibility="hidden" style="left:180px; top:74px; width:85px; height:19px; "/>
  260. <input id="ipt_calltm" ref="/root/main/cond/calltm" visibility="hidden" style="left:267px; top:74px; width:45px; height:19px; "/>
  261. <input id="ipt_callno" ref="/root/main/cond/callno" visibility="hidden" style="left:315px; top:74px; width:45px; height:19px; "/>
  262. <caption id="caption10" ref="/root/main/cond/capinfo" style="left:0px; top:188px; width:305px; height:20px; font-weight:bold; color:#0000ff; text-align:left; "/>
  263. <select1 id="cmb_acptflag" ref="/root/main/cond/acptflag" disabled="true" appearance="minimal" style="left:257px; top:74px; width:100px; height:19px; ">
  264. <choices>
  265. <itemset nodeset="/root/init/codeinfo/codelist[cdgrupid='I05']">
  266. <label ref="cdnm"/>
  267. <value ref="cdid"/>
  268. </itemset>
  269. </choices>
  270. </select1>
  271. <caption id="caption9" class="cell_1" style="left:180px; top:73px; width:75px; height:23px; text-align:center; ">접수구분</caption>
  272. <line id="line7" class="line_3" style="x1:0px; y1:187px; x2:360px; y2:187px; "/>
  273. <textarea id="tar_callremfactdesc" ref="/root/main/cond/callremfactdesc" style="left:77px; top:144px; width:285px; height:41px; "/>
  274. <caption id="caption7" style="left:335px; top:219px; width:27px; height:14px; ">[표]</caption>
  275. <select1 id="cmb_calltelno" ref="/root/main/cond/calltelno" appearance="minimal" style="left:77px; top:74px; width:100px; height:19px; ">
  276. <choices>
  277. <itemset nodeset="/root/init/cmblist/ivcmblist">
  278. <label ref="nursnm"/>
  279. <value ref="nurstel"/>
  280. </itemset>
  281. </choices>
  282. <script type="javascript" ev:event="xforms-value-changed">
  283. <![CDATA[
  284. var calltelno = model.getValue("/root/main/cond/calltelno");
  285. model.setValue("/root/main/cond/calluserid", model.getValue("/root/init/cmblist/ivcmblist[nurstel='"+calltelno+"']/userid"));
  286. ipt_calluserid.refresh();
  287. ]]>
  288. </script>
  289. </select1>
  290. <caption id="caption5" class="cell_1" style="left:0px; top:73px; width:75px; height:23px; text-align:center; ">IV팀</caption>
  291. <input id="ipt_sex" ref="/root/main/cond/sex" visibility="hidden" style="left:195px; top:0px; width:20px; height:19px; "/>
  292. <input id="ipt_age" ref="/root/main/cond/age" visibility="hidden" style="left:220px; top:0px; width:20px; height:19px; "/>
  293. <select1 id="combo1" ref="/root/main/cond/calltelno" visibility="hidden" appearance="minimal" style="left:77px; top:74px; width:100px; height:19px; ">
  294. <choices>
  295. <itemset nodeset="/root/init/codeinfo/codelist[cdgrupid='I07']">
  296. <label ref="cdnm"/>
  297. <value ref="cdid"/>
  298. </itemset>
  299. </choices>
  300. </select1>
  301. <input id="ipt_calluserid" ref="/root/main/cond/calluserid" visibility="hidden" style="left:55px; top:74px; width:20px; height:19px; "/>
  302. <select1 id="cmb_orddeptcd" ref="/root/main/cond/orddeptcd" appearance="minimal" style="left:77px; top:98px; width:178px; height:19px; ">
  303. <choices>
  304. <itemset nodeset="/root/init/cmblist/orddeptlist">
  305. <label ref="depthngnm"/>
  306. <value ref="deptcd"/>
  307. </itemset>
  308. </choices>
  309. </select1>
  310. <caption id="caption11" class="cell_1" style="left:0px; top:97px; width:75px; height:23px; text-align:center; ">진료과</caption>
  311. <line id="line4" class="line_2" style="x1:0px; y1:120px; x2:360px; y2:120px; "/>
  312. <select1 id="cmb_roomcd" ref="/root/main/cond/roomcd" appearance="minimal" style="left:257px; top:50px; width:100px; height:19px; ">
  313. <choices>
  314. <itemset nodeset="/root/init/roominfo/room">
  315. <label ref="roomnm"/>
  316. <value ref="roomcd"/>
  317. </itemset>
  318. </choices>
  319. </select1>
  320. </group>
  321. </xhtml:body>
  322. </xhtml:html>