SPAEB00201_수가코드선택.xrw 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341
  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>수가코드선택</xhtml:title>
  6. <model id="model1">
  7. <instance id="instance1">
  8. <root xmlns="">
  9. <main>
  10. <ocdlst>
  11. <item>
  12. <sel/>
  13. <calcscorcd/>
  14. <ordnm/>
  15. <hngnm/>
  16. <engnm/>
  17. <oldordcd/>
  18. <fromdd/>
  19. <prcpexecdeptcd/>
  20. </item>
  21. </ocdlst>
  22. </main>
  23. <send>
  24. <srchcdnm/>
  25. <srchcond>cd</srchcond>
  26. <garbage>1</garbage>
  27. <srchchkreg/>
  28. <globalinstance>
  29. <instance1/>
  30. </globalinstance>
  31. <srchdept/>
  32. <srchnocode/>
  33. </send>
  34. <init>
  35. <initsugadept>
  36. <initsugadeptcdid/>
  37. <initsugadeptcdnm/>
  38. </initsugadept>
  39. <dept_info>
  40. <initprcpexecdeptcd>
  41. <prcpexecdeptcdid/>
  42. <prcpexecdeptcdnm/>
  43. </initprcpexecdeptcd>
  44. </dept_info>
  45. </init>
  46. <hidden>
  47. </hidden>
  48. <temp/>
  49. </root>
  50. </instance>
  51. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  52. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  53. <script type="javascript" src="../../../com/commonweb/js/stringHelper.js"/>
  54. <script type="javascript" src="../../../ast/examcureweb/js/AEZ0001.js"/>
  55. <script type="javascript" ev:event="xforms-ready">
  56. <![CDATA[
  57. cmb_deptcd.deselect(0);
  58. cmb_deptcd.disabled = true;
  59. checkbox1.value = "";
  60. checkbox1.disabled = true;
  61. aezfSetSuppDeptcd();
  62. fInit();
  63. submit("TRAEB00203");
  64. submit("TRAEB00205"); // 수행부서 코드 가져오기
  65. // model.setValue("/root/send/srchdept", model.getValue("/root/send/globalinstance/instance1"));
  66. model.refresh();
  67. ]]>
  68. </script>
  69. <submission id="TRAEB00202" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" replace="instance" resultref="/root/main/ocdlst"/>
  70. <submission id="TRAEB00203" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" replace="instance" resultref="/root/init"/>
  71. <submission id="TRAEB00204" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" replace="instance" resultref="/root/main/ocdlst"/>
  72. <submission id="TRAEB00205" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/globalinstance" replace="instance" resultref="/root/init/dept_info"/>
  73. <bind id="bind_prcpexecdeptcd" ref="/root/main/ocdlst/item/prcpexecdeptcd" readonly="../prcpexecdeptcd!=''"/>
  74. </model>
  75. <script type="javascript">
  76. <![CDATA[
  77. /**
  78. * SPAEB00201_PARAM1 : 검색구분(cd/nm)
  79. * SPAEB00201_PARAM2 : 검색조건(코드/명칭)
  80. * SPAEB00201_PARAM3 : multiyn
  81. * SPAEB00201_PARAM4 : multi선택 시 setting할 목적노드
  82. * SPAEB00201_PARAM5 : code값을 setting할 목적노드
  83. * SPAEB00201_PARAM6 : name값을 setting할 목적노드
  84. * SPAEB00201_PARAM7 : 수가를 setting할 목적노드
  85. */ var vMultiYn = "";
  86. function fInit(){
  87. model.removeNodeset(grd_ocdlst.nodeset);
  88. if( checkOpener() ){
  89. opener.model.makeNode("/root/temp/okflag");
  90. model.setValue("/root/send/srchcond" , opener.javascript.getParameter("SPAEB00201_PARAM1"));
  91. model.setValue("/root/send/srchcdnm" , opener.javascript.getParameter("SPAEB00201_PARAM2"));
  92. vMultiYn = opener.javascript.getParameter("SPAEB00201_PARAM3");
  93. if( vMultiYn == "N" ) {
  94. grd_ocdlst.colHidden(1) = false;
  95. }
  96. if(model.getValue("/root/send/srchcdnm") != "" ) {
  97. fGetCalcScorCdList();
  98. }
  99. }
  100. model.setFocus("ipt_cdnm");
  101. model.refresh();
  102. }
  103. /**
  104. * 수가코드내역조회
  105. */
  106. function fGetCalcScorCdList(){
  107. //alert(checkbox1.value);
  108. //alert(model.getValue("/root/send/srchchkreg"));
  109. //return;
  110. if ( model.getValue("/root/send/srchchkreg") == "Y" ) {
  111. if ( model.getValue("/root/send/srchdept") == "" ) {
  112. messageBox("수행부서를 선택하십시오.","I999");
  113. return;
  114. }
  115. submit("TRAEB00204");
  116. return;
  117. }
  118. if( model.getValue("/root/send/srchdept") == "" ) {
  119. if( ipt_cdnm.value.length < 3 ){
  120. messageBox("검색어를 세자이상 " , "C001");
  121. model.setFocus("ipt_cdnm");
  122. return ;
  123. }
  124. }
  125. submit("TRAEB00202");
  126. }
  127. /**
  128. * opener id에 따른 분화
  129. */
  130. function fSetData(){
  131. if( checkOpener() ){
  132. var sDestXPath = opener.javascript.getParameter("SPAEB00201_PARAM4");
  133. var sDestXPathCd = opener.javascript.getParameter("SPAEB00201_PARAM5");
  134. var sDestXPathNm = opener.javascript.getParameter("SPAEB00201_PARAM6");
  135. //var sDestXPathAmt = opener.javascript.getParameter("SPAEB00201_PARAM7");
  136. //alert('sDestXPath->'+sDestXPath+', sDestXPathCd->'+sDestXPathCd+', sDestXPathNm->'+sDestXPathNm);
  137. // /root/main/examcurecdlist/item
  138. //return;
  139. var idx = 0 ;
  140. if( vMultiYn == "N" ){
  141. idx = grd_ocdlst.row;
  142. if( idx < 1) return -1;
  143. opener.model.setValue( sDestXPathCd , model.getValue("/root/main/ocdlst/item[" + idx + "]/calcscorcd" ) );
  144. opener.model.setValue(sDestXPathNm, model.getValue("/root/main/ocdlst/item[" + idx + "]/ordnm" ) );
  145. //opener.model.setValue(sDestXPathAmt, model.getValue("/root/main/ocdlst/item[" + idx + "]/scoreamt" ) );
  146. }
  147. else {
  148. var nodeList = instance1.selectNodes(grd_ocdlst.nodeset + "[sel='Y']");
  149. if( nodeList.length > 0) {
  150. var rCSV = getNodeListCSV(nodeList);
  151. setCSVToNode("/root/temp", rCSV);
  152. copyNodeListType(sDestXPath, "/root/temp/list", "replace", opener.model, model );
  153. }
  154. else return -1;
  155. }
  156. opener.model.setValue("/root/temp/okflag", "ok");
  157. return 1;
  158. }
  159. }
  160. ]]>
  161. </script>
  162. </xhtml:head>
  163. <xhtml:body pagewidth="910" pageheight="563" guideline="1,1190;1,907;" style="margin-left:8; margin-top:8; margin-right:8; margin-bottom:8; ">
  164. <group id="group3" scroll="auto" style="left:0px; top:0px; width:890px; height:515px; ">
  165. <datagrid id="grd_ocdlst" nodeset="/root/main/ocdlst/item" autoresize="true" caption="선택^처방코드^처방명^한글명^영문명^구코드^적용일자^수가수행부서" colsep="^" colwidth="30, 79, 168, 172, 153, 66, 73, 94" dataheight="25" explorerbar="sortshow" extendlastcol="scroll" mergecellsfixedrows="bycolrec" rowheader="seq" rowheight="25" rowsep="|" style="left:0px; top:49px; width:875px; height:463px; ">
  166. <col checkvalue="Y,N" ref="sel" type="checkbox"/>
  167. <col ref="calcscorcd" style="left:53px; top:23px; width:71px; height:23px; "/>
  168. <col ref="ordnm"/>
  169. <col ref="hngnm"/>
  170. <col ref="engnm"/>
  171. <col ref="oldordcd"/>
  172. <col ref="fromdd" format="yyyy-mm-dd"/>
  173. <col ref="prcpexecdeptcd" type="combo">
  174. <choices>
  175. <itemset nodeset="/root/init/dept_info/initprcpexecdeptcd">
  176. <label ref="prcpexecdeptcdnm"/>
  177. <value ref="prcpexecdeptcdid"/>
  178. </itemset>
  179. </choices>
  180. </col>
  181. <script type="javascript" ev:event="ondblclick">
  182. <![CDATA[
  183. if( fSetData() == 1){
  184. window.close();
  185. }
  186. ]]>
  187. </script>
  188. </datagrid>
  189. <group id="group2" style="left:0px; top:0px; width:890px; height:40px; vertical-align:top; ">
  190. <shape id="roundrect1" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:0px; width:875px; height:40px; background-color:#fffbf2; border-color:#ffd799; "/>
  191. <caption id="caption2" class="search_name" style="left:16px; top:12px; width:86px; height:17px; ">검색조건 :</caption>
  192. <button id="btn_search" class="btn1_letter2" style="left:810px; top:12px; width:56px; height:22px; ">
  193. <caption>조회</caption>
  194. <script type="javascript" ev:event="DOMActivate">
  195. <![CDATA[
  196. fGetCalcScorCdList();
  197. ]]>
  198. </script>
  199. </button>
  200. <line id="line13" style="x1:794px; y1:11px; x2:794px; y2:32px; border-color:#ffe4bb; border-left-style:solid; "/>
  201. <select1 id="cmb_srchcond2" ref="/root/send/srchcond" class="combo_search" appearance="minimal" style="left:105px; top:11px; width:80px; height:19px; ">
  202. <choices>
  203. <item>
  204. <label>코드</label>
  205. <value>cd</value>
  206. </item>
  207. <item>
  208. <label>구코드</label>
  209. <value>old</value>
  210. </item>
  211. <item>
  212. <label>처방명</label>
  213. <value>ordnm</value>
  214. </item>
  215. <item>
  216. <label>한글명</label>
  217. <value>hngnm</value>
  218. </item>
  219. <item>
  220. <label>영문명</label>
  221. <value>engnm</value>
  222. </item>
  223. <item>
  224. <label>수행부서별</label>
  225. <value>dept</value>
  226. </item>
  227. </choices>
  228. <script type="javascript" ev:event="xforms-select">
  229. <![CDATA[
  230. cmb_deptcd.deselect(0);
  231. cmb_deptcd.disabled = true;
  232. checkbox1.value = "";
  233. checkbox1.disabled = true;
  234. //ipt_cdnm.disabled = false;
  235. model.setFocus("ipt_cdnm");
  236. if ( cmb_srchcond2.value == "dept" ) {
  237. cmb_deptcd.disabled = false;
  238. checkbox1.disabled = false;
  239. ipt_cdnm.value = "";
  240. //model.setValue("/root/send/srchcdnm","");
  241. model.setFocus("cmb_deptcd");
  242. }
  243. ]]>
  244. </script>
  245. </select1>
  246. <input id="ipt_cdnm" ref="/root/send/srchcdnm" class="input_search" style="left:188px; top:11px; width:227px; height:19px; ">
  247. <script type="javascript" ev:event="onkeyup">
  248. <![CDATA[
  249. inputEnterKey("btn_search", "DOMActivate");
  250. ]]>
  251. </script>
  252. </input>
  253. <select1 id="cmb_deptcd" ref="/root/send/srchdept" appearance="minimal" style="left:425px; top:11px; width:100px; height:19px; ">
  254. <choices>
  255. <itemset nodeset="/root/init/initsugadept">
  256. <label ref="initsugadeptcdnm"/>
  257. <value ref="initsugadeptcdid"/>
  258. </itemset>
  259. </choices>
  260. <script type="javascript" ev:event="xforms-select">
  261. <![CDATA[
  262. //model.setValue("/root/send/srchcdnm", "");
  263. ipt_cdnm.value = "";
  264. cmb_srchcond2.value = "dept";
  265. ]]>
  266. </script>
  267. </select1>
  268. <select id="checkbox1" ref="/root/send/srchchkreg" overflow="visible" appearance="full" style="left:540px; top:12px; width:100px; height:20px; border-style:none; ">
  269. <choices>
  270. <item>
  271. <label>미등록수가코드</label>
  272. <value>Y</value>
  273. </item>
  274. </choices>
  275. </select>
  276. <select id="chk_con" ref="/root/send/srchnocode" overflow="visible" appearance="full" style="left:680px; top:12px; width:100px; height:15px; border-style:none; ">
  277. <choices>
  278. <item>
  279. <label>처방불가수가</label>
  280. <value>Y</value>
  281. </item>
  282. </choices>
  283. </select>
  284. </group>
  285. <line id="line1" class="line_1" style="x1:0px; y1:46px; x2:885px; y2:46px; "/>
  286. </group>
  287. <group id="group4" scroll="auto" style="left:0px; top:516px; width:885px; height:29px; ">
  288. <button id="button9" class="btn4_letter2" style="left:806px; top:3px; width:56px; height:22px; ">
  289. <caption>취소</caption>
  290. <script type="javascript" ev:event="DOMActivate">
  291. <![CDATA[
  292. if( checkOpener() ){
  293. opener.model.setValue("/root/temp/okflag", "");
  294. window.close();
  295. }
  296. ]]>
  297. </script>
  298. </button>
  299. <button id="button4" class="btn4_letter2" style="left:747px; top:3px; width:56px; height:22px; ">
  300. <caption>확인</caption>
  301. <script type="javascript" ev:event="DOMActivate">
  302. <![CDATA[
  303. if( fSetData() == 1){
  304. window.close();
  305. }
  306. ]]>
  307. </script>
  308. </button>
  309. </group>
  310. <button id="button1" class="btn2_letter4" style="left:5px; top:520px; width:64px; height:19px; ">
  311. <caption>엑셀저장</caption>
  312. <script type="javascript" ev:event="DOMActivate">
  313. <![CDATA[
  314. var file = window.fileDialog("save","","false","","xls","Excel Files(*.xls)|*.xls");
  315. grd_ocdlst.saveExcel(file);
  316. ]]>
  317. </script>
  318. </button>
  319. </xhtml:body>
  320. </xhtml:html>