SPMNP01500_수술명조회.xrw 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161
  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. <optreelists>
  11. <optreelist>
  12. <depth/>
  13. <opgrp1/>
  14. <opgrp2/>
  15. <opgrp3/>
  16. <opgrp4/>
  17. <opcode/>
  18. <instcd/>
  19. <opgname/>
  20. </optreelist>
  21. </optreelists>
  22. </main>
  23. <send>
  24. <treeflag>N</treeflag>
  25. <instcd>012</instcd>
  26. </send>
  27. <Cond>
  28. <opcode/>
  29. <opname/>
  30. <oplist/>
  31. </Cond>
  32. </root>
  33. </instance>
  34. <script type="javascript" ev:event="xforms-ready">
  35. <![CDATA[
  36. fSearchClick();
  37. ]]>
  38. </script>
  39. <submission id="TRMNP01502" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main/optreelists"/>
  40. </model>
  41. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  42. <script type="javascript">
  43. <![CDATA[
  44. /*
  45. 버튼 컨트롤들을 클릭했을때 공통으로 타는 함수입니다.
  46. control : "search" 는 조회 버튼 클릭
  47. "init"은 신규 버튼 클릭
  48. "save"는 저장 버튼 클릭
  49. grid : 그리드 컨트롤을 넘겨줍니다.
  50. param : 기타 param을 넘겨줍니다.
  51. */
  52. function fClicked(control, grid, param){
  53. if ("search" == control){
  54. fSearchClick(grid, param);
  55. model.resetInstanceNode("/root/send");
  56. } else if ("init" == control){
  57. model.reset();
  58. } else {
  59. messageBox("처리를 수행","E002");
  60. }
  61. model.refresh();
  62. }
  63. /*
  64. 조회버튼 클릭 타는 함수입니다.
  65. grid.explorerbar = "sortshow" sort설정합니다.
  66. ipt_usercdnm_flag는 검색조건의 사용자코드 or 사용자명입니다.
  67. radio1은 사용자코드 or 사용자명 선택 라디오 버튼입니다.
  68. submit을 날립니다.
  69. .
  70. */
  71. function fSearchClick(grid,param){
  72. model.removeNodeset("/root/send");
  73. model.makeValue("/root/send/instcd" ,"012");
  74. model.makeValue("/root/send/treeflag", "N");
  75. submit("TRMNP01502");
  76. }
  77. function fResetNode(node, destinationelement){
  78. // model.setValue(node + "/" + destinationelement, "");
  79. alert(model.elementName("/root/main/item"));
  80. }
  81. /*
  82. model.getValue(); 를 함수로 만들었습니다.
  83. param1 : node는 grid의 xPath입니다.
  84. param2 : row는 grid에서 선택한 row값입니다.
  85. param3 : element는 getvalue할 해당 element 명입니다.
  86. 해당 getvalue값을 return 해줍니다.
  87. return 하지 않으면 해당값을 가져올 수 없습니다.
  88. */
  89. function fGetValue(node, row, element) {
  90. var rtnValue = model.getValue(node + "[" + row + "]/" + element);
  91. return rtnValue;
  92. }
  93. /*
  94. model.setValue();를 함수로 만들었습니다.
  95. param1 : node는 setvalue할 컨트롤의 xPath입니다.
  96. param2 : destinationelement는 setvalue할 element명 입니다.
  97. param3 : sourceelement는 setvalue할 값입니다.
  98. */
  99. function fSetValue(node, destinationelement, sourceelement) {
  100. model.setValue(node + "/" + destinationelement, sourceelement);
  101. }
  102. function fDblclick(pIdx) {
  103. var xPath ="/root/main/optreelists/optreelist";
  104. var Idx = pIdx + 1;
  105. var sDepth = model.getValue(xPath +"["+Idx+"]/depth");
  106. if (sDepth != "3" ) {
  107. return;
  108. }
  109. //var clscd = model.getValue("/root/main/cond/clscd");
  110. //model.setValue("/root/main/cond/clsnm", model.getValue("/root/main/educclslist/educclslistinfo[clscd='" + clscd + "']/clsnm"));
  111. var iParam_code = fGetValue(xPath, Idx, "opcode" );
  112. var iParam_name = fGetValue(xPath, Idx, "opgname");
  113. var iParam = iParam_code + "|" + iParam_name;
  114. // alert(iParam);
  115. opener.javascript.setParameter("SendData", iParam);
  116. window.close();
  117. }
  118. ]]>
  119. </script>
  120. </xhtml:head>
  121. <xhtml:body pagewidth="450" pageheight="610" style="border-color:#c7a3cf; ">
  122. <group id="group5" scroll="auto" style="left:0px; top:13px; width:444px; height:590px; border-color:#c7a3cf; border-style:solid; ">
  123. <treeview id="trv_opcode" ref="/root/Cond/opcode" expanddepth="0" image="../../../com/commonweb/images/icon_folder_close.gif" itemsettype="depth" selectedimage="../../../com/commonweb/images/icon_folder_open.gif" style="left:4px; top:9px; width:435px; height:578px; ">
  124. <itemset nodeset="/root/main/optreelists/optreelist">
  125. <label ref="opgname"/>
  126. <value ref="opgrp4"/>
  127. <depth ref="depth"/>
  128. </itemset>
  129. <script type="javascript" ev:event="ondblclick">
  130. <![CDATA[
  131. fDblclick(trv_opcode.focusIndex);
  132. ]]>
  133. </script>
  134. </treeview>
  135. <line id="line1" class="line_1" style="x1:3px; y1:4px; x2:439px; y2:4px; "/>
  136. </group>
  137. <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:442px; height:13px; ">수술명조회</caption>
  138. </xhtml:body>
  139. </xhtml:html>