SMAEB03500_조영제약품코드관리.xrw 8.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221
  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. <goodlist>
  11. <item>
  12. <goodcd/>
  13. <goodnm/>
  14. <speccd/>
  15. <safestocqty/>
  16. <instcd/>
  17. <suppdeptcd/>
  18. </item>
  19. </goodlist>
  20. </main>
  21. <send>
  22. <srch>
  23. <srchgoodcd/>
  24. <srchgoodnm/>
  25. </srch>
  26. <globalinstance>
  27. <instance1/>
  28. </globalinstance>
  29. <req>
  30. <data>
  31. </data>
  32. <suppdeptcd/>
  33. </req>
  34. </send>
  35. <hidden>
  36. <item>
  37. </item>
  38. </hidden>
  39. <temp>
  40. <goodcd/>
  41. <goodnm/>
  42. <speccd/>
  43. <safestocqty/>
  44. </temp>
  45. </root>
  46. </instance>
  47. <submission id="TRAEB03501" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" replace="instance" resultref="/root/main/goodlist"/>
  48. <submission id="TXAEB03501" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/req" replace="instance" resultref="/root/hidden"/>
  49. </model>
  50. </xhtml:head>
  51. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  52. <script type="javascript" src="../../../com/commonweb/js/stringHelper.js"/>
  53. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  54. <script type="javascript" src="../../../ast/commonweb/js/AST.js"/>
  55. <script type="javascript" src="../../../ast/examcureweb/js/AEZ0001.js"/>
  56. <script type="javascript" src="../../../mis/miscommonweb/js/MIS.js"/>
  57. <script type="javascript" src="../../../mis/miscommonweb/js/RSZ001.js"/>
  58. <script type="javascript" ev:event="xforms-ready">
  59. <![CDATA[
  60. //globalinstance 셋팅
  61. //aezfSetSuppDeptcd();
  62. // 메뉴 파라미터가 지정되어 있으면 해당 값으로 셋팅하고 그렇치 않으면 기본값 셋팅
  63. var suppdeptcd = "";
  64. suppdeptcd = getScreenMenuParameter();
  65. if (suppdeptcd == "" || suppdeptcd == null || suppdeptcd == "null"){
  66. aezfSetSuppDeptcd();
  67. }else{
  68. model.setValue("/root/send/globalinstance/instance1", suppdeptcd);
  69. }
  70. model.removeNodeset("/root/main/goodlist/item");
  71. model.refresh();
  72. ]]>
  73. </script>
  74. <script type="javascript">
  75. <![CDATA[
  76. function fnGetMainList(){
  77. model.removeNodeset("/root/main/goodlist/item");
  78. submit("TRAEB03501");
  79. }
  80. ]]>
  81. </script>
  82. <xhtml:body guideline="1,1195;2,786;" style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
  83. <shape id="roundrect1" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:5px; top:20px; width:1190px; height:35px; background-color:#fffbf2; border-color:#ffd799; "/>
  84. <caption id="caption19" class="tit_1" style="left:0px; top:0px; width:170px; height:15px; ">조영제/재료 코드 관리</caption>
  85. <line id="line2" class="line_1" style="x1:0px; y1:85px; x2:1195px; y2:85px; "/>
  86. <button id="btn_grdadd" class="btn2_letter3" style="left:1085px; top:60px; width:53px; height:19px; ">
  87. <caption>행추가</caption>
  88. <script type="javascript" ev:event="DOMActivate">
  89. <![CDATA[
  90. grd_goodlist.addRow();
  91. grd_goodlist.row = grd_goodlist.rows;
  92. var cnt = parseInt(grd_goodlist.row);
  93. model.setValue("/root/main/goodlist/item[" + cnt + "]/suppdeptcd", model.getValue("/root/send/globalinstance/instance1") );
  94. grd_goodlist.isReadOnly(cnt, 1) = false;
  95. ]]>
  96. </script>
  97. </button>
  98. <button id="btn_grddel" class="btn2_letter3" style="left:1142px; top:60px; width:53px; height:19px; ">
  99. <caption>행삭제</caption>
  100. <script type="javascript" ev:event="onclick">
  101. <![CDATA[
  102. // grd_goodlist.addStatus(grd_goodlistt.row,"delete");
  103. deleteSelectedRows(grd_goodlist, true);
  104. ]]>
  105. </script>
  106. </button>
  107. <group id="grp_btn" style="left:0px; top:757px; width:1195px; height:27px; ">
  108. <line id="line32" class="line_6" style="x1:0px; y1:0px; x2:1195px; y2:0px; "/>
  109. <button id="button1" class="btn4_letter2" style="left:1078px; top:4px; width:56px; height:22px; ">
  110. <caption>저장</caption>
  111. <script type="javascript" ev:event="DOMActivate">
  112. <![CDATA[
  113. if(!astfNullValidation("/root/main/goodlist/item", "goodcd", "제품코드를")) return false;
  114. if(!astfNullValidation("/root/main/goodlist/item", "goodnm", "제품명을")) return false;
  115. model.setValue("/root/send/req/suppdeptcd", model.getValue("/root/send/globalinstance/instance1"));
  116. for(i = 1; i < grd_goodlist.rows; i++)
  117. {
  118. var goodcd = model.getValue("/root/main/goodlist/item[" + i + "]/goodcd");
  119. var cnt = model.getXPathValue("count(/root/main/goodlist/item[goodcd = '" + goodcd + "'])");
  120. if(cnt > 1)
  121. {
  122. messageBox("약품코드[" + goodcd + "]가 ", "E006");
  123. return false;
  124. }
  125. }
  126. if ( messageBox("","Q002")==6 ) {
  127. var update = getGridUpdateData(grd_goodlist);
  128. if(update == ""){
  129. messageBox("업데이트 정보가 없습니다.", "I");
  130. return 0;
  131. } else {
  132. model.setValue("/root/send/req/data", update);
  133. if (submit("TXAEB03501")) {
  134. // 저장 후 팝업인 경우 변경 여부 returng하고 창을 닫는다
  135. submit("TRAEB03501");
  136. }
  137. }
  138. }
  139. ]]>
  140. </script>
  141. </button>
  142. <button id="btn_close" class="btn4_letter2" style="left:1138px; top:4px; width:56px; height:22px; ">
  143. <caption>닫기</caption>
  144. <script type="javascript" ev:event="DOMActivate">
  145. <![CDATA[
  146. window.close();
  147. ]]>
  148. </script>
  149. </button>
  150. </group>
  151. <datagrid id="grd_goodlist" nodeset="/root/main/goodlist/item" caption="조영제/재료코드^조영제/재료명^안전재고량^용량^" colsep="^" colwidth="160, 540, 109, 118, 79, 121" mergecellsfixedrows="bycolrec" rowheader="update" rowsep="|" style="left:0px; top:90px; width:1195px; height:665px; ">
  152. <col disabled="true" editable="false" ref="goodcd" type="inputbutton">
  153. <script type="javascript" ev:event="onbuttonclick">
  154. <![CDATA[
  155. modal("SPAEB00402", "", "200", "200", "popup", "/root/hidden/pseursrvinfo", "/root/init/pseursrvinfo");
  156. model.refresh();
  157. var selectedrow = grd_goodlist.selectedCells.item(0).row;
  158. if(model.getValue("/root/temp/goodcd") != "")
  159. {
  160. model.setValue("/root/main/goodlist/item[" + selectedrow + "]/goodcd", model.getValue("/root/temp/goodcd"));
  161. model.setValue("/root/main/goodlist/item[" + selectedrow + "]/goodnm", model.getValue("/root/temp/goodnm"));
  162. model.setValue("/root/main/goodlist/item[" + selectedrow + "]/safestocqty", model.getValue("/root/temp/safestocqty"));
  163. model.setValue("/root/main/goodlist/item[" + selectedrow + "]/speccd", model.getValue("/root/temp/speccd"));
  164. model.refresh();
  165. }
  166. model.setValue("/root/temp/goodcd", "");
  167. ]]>
  168. </script>
  169. </col>
  170. <col ref="goodnm" type="input" maxbyte="200"/>
  171. <col ref="safestocqty" type="input" format="#,###" maxlength="10" style="text-align:right; "/>
  172. <col ref="speccd" type="input" maxbyte="20" maxlength="20" style="text-align:center; "/>
  173. <col ref="instcd" visibility="hidden"/>
  174. <col ref="suppdeptcd" visibility="hidden"/>
  175. </datagrid>
  176. <caption id="caption1" class="search_name" style="left:20px; top:30px; width:124px; height:17px; ">조영제/재료코드 :</caption>
  177. <caption id="caption2" class="search_name" style="left:308px; top:30px; width:108px; height:17px; ">조영제재료명 :</caption>
  178. <button id="btn_sea" class="btn1_letter2" style="left:1126px; top:27px; width:56px; height:22px; ">
  179. <caption>조회</caption>
  180. <script type="javascript" ev:event="DOMActivate">
  181. <![CDATA[
  182. fnGetMainList();
  183. ]]>
  184. </script>
  185. </button>
  186. <input id="input8" ref="/root/send/srch/srchgoodcd" class="input_search" style="left:150px; top:30px; width:100px; height:19px; ">
  187. <script type="javascript" ev:event="onkeyup">
  188. <![CDATA[
  189. if ( event.keyCode == 13 ) {
  190. setInputNodeCurText();
  191. submit("TRAEB03501");
  192. }
  193. ]]>
  194. </script>
  195. </input>
  196. <input id="input1" ref="/root/send/srch/srchgoodnm" class="input_search" style="left:424px; top:28px; width:100px; height:19px; ">
  197. <script type="javascript" ev:event="onkeyup">
  198. <![CDATA[
  199. if ( event.keyCode == 13 ) {
  200. setInputNodeCurText();
  201. submit("TRAEB03501");
  202. }
  203. ]]>
  204. </script>
  205. </input>
  206. </xhtml:body>
  207. </xhtml:html>