SMRST05900_자재수불증감분석.xrw 8.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185
  1. <?xml version="1.0" encoding="EUC-KR"?>
  2. <?xml-stylesheet type="text/css" href="../../../com/commonweb/css/common.css" ?>
  3. <xhtml:html xmlns:ex="http://www.comsquare.co.kr/xforms/excel" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:my="http://www.comsquare.co.kr/example" xmlns:ms="urn:schemas-microsoft-com:xslt" 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" xmlns:cs="http://www.comsquare.co.kr/xforms">
  4. <xhtml:head>
  5. <xhtml:title>자재 수불 증감 분석</xhtml:title>
  6. <model id="model1">
  7. <instance id="instance1">
  8. <root xmlns="">
  9. <main>
  10. <mtallist>
  11. <winacntnm/>
  12. <befinputamt/>
  13. <inputamt/>
  14. <befyyinputamt/>
  15. <befyyinputavg/>
  16. <subinputamt/>
  17. <cmt/>
  18. </mtallist>
  19. </main>
  20. <send>
  21. <goodreq>
  22. <instcd/>
  23. <inputmonth/>
  24. </goodreq>
  25. <savedata/>
  26. </send>
  27. <init>
  28. </init>
  29. <temp/>
  30. </root>
  31. </instance>
  32. <script type="javascript" ev:event="xforms-ready">
  33. <![CDATA[
  34. fInitialize();
  35. ]]>
  36. </script>
  37. <submission id="TRRST05901" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/goodreq" resultref="/root/main/mtallist"/>
  38. <submission id="TXRST05901" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/savedata" resultref="/root/temp"/>
  39. </model>
  40. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  41. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  42. <script type="javascript" src="../../../mis/miscommonweb/js/MIS.js"/>
  43. <script type="javascript" src="../../../mis/miscommonweb/js/RSZ001.js"/>
  44. <script type="javascript" src="../../../com/commonweb/js/stringHelper.js"/>
  45. <script type="javascript" src="../../../com/basiccodeweb/js/ZBC001.js"/>
  46. <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
  47. <script type="javascript">
  48. <![CDATA[
  49. // 화면 open시와 초기화 버튼 클릭시 화면 초기화 기능을 수행한다.
  50. function fInitialize()
  51. {
  52. rszfUserReqInstList(cmb_instcd,getUserInfo("userid"),"%","B");
  53. cmb_instcd.refresh();
  54. model.setValue(cmb_instcd.attribute("ref"), getUserInfo("dutplceinstcd"));
  55. cmb_instcd.refresh();
  56. model.setValue(ipt_inputmonth.attribute("ref"), getCurrentDate().substr(0, 6));
  57. ipt_inputmonth.refresh();
  58. fSetGridTitle();
  59. }
  60. function fSetGridTitle() {
  61. var inputmonth = model.getValue(ipt_inputmonth.attribute("ref"));
  62. var inputnm = inputmonth.substr(2,2) + "년 " + String(Number(inputmonth.substr(4,2))) + "월입고";
  63. var befinputnm;
  64. var tmp;
  65. if(inputmonth.substr(4, 2) == "01") {
  66. tmp = String(Number(inputmonth.substr(0,4)) - 1);
  67. befinputnm = tmp.substr(2,2) + "년 " + "12월입고";
  68. } else {
  69. befinputnm = inputmonth.substr(2,2) + "년 " + String(Number(inputmonth.substr(4,2)) - 1) + "월입고";
  70. }
  71. grd_mtallist.valueMatrix(0, grd_mtallist.colRef("befinputamt")) = befinputnm;
  72. grd_mtallist.valueMatrix(0, grd_mtallist.colRef("inputamt")) = inputnm;
  73. grd_mtallist.valueMatrix(0, grd_mtallist.colRef("befyyinputamt")) = "전년 " + String(Number(inputmonth.substr(4, 2))) + "월입고";
  74. }
  75. ]]>
  76. </script>
  77. </xhtml:head>
  78. <xhtml:body style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
  79. <group id="grp_tle" style="left:0px; top:0px; width:1195px; height:13px; ">
  80. <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:243px; height:14px; ">자재 수불 증감 분석</caption>
  81. </group>
  82. <group id="grp_biz" scroll="auto" style="left:0px; top:12px; width:1195px; height:744px; ">
  83. <shape id="roundrect1" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:10px; width:1195px; height:40px; "/>
  84. <select1 id="cmb_instcd" ref="/root/send/goodreq/instcd" class="combo_s_essential" appearance="minimal" style="left:95px; top:19px; width:120px; height:19px; ">
  85. <choices>
  86. <itemset nodeset="/root/init/instcd">
  87. <label ref="cdnm"/>
  88. <value ref="cdid"/>
  89. </itemset>
  90. </choices>
  91. </select1>
  92. <caption id="caption14" class="search_name" style="left:5px; top:19px; width:91px; height:17px; ">기관코드 :</caption>
  93. <line id="line14" class="line_4" style="x1:1060px; y1:17px; x2:1060px; y2:44px; "/>
  94. <button id="btn_search" class="btn1_letter2" navindex="7" style="left:1070px; top:20px; width:56px; height:22px; text-align:left; ">
  95. <caption>조회</caption>
  96. <script type="javascript" ev:event="DOMActivate">
  97. <![CDATA[
  98. submit("TRRST05901");
  99. fSetGridTitle();
  100. grd_mtallist.refresh();
  101. ]]>
  102. </script>
  103. </button>
  104. <datagrid id="grd_mtallist" nodeset="/root/main/mtallist" caption="품명^09년 4월입고^09년 5월입고^전년 5월입고^전년도 평균입고^전월입고차액^증감율^증감율^증감사유^instcd^inputmonth^winacnt" colsep="^" colwidth="166, 120, 120, 100, 0, 100, 48, 23, 478, 100, 100, 100" mergecellsfixedrows="bycolrec" rowheader="update" rowsep="|" style="left:0px; top:80px; width:1195px; height:565px; ">
  105. <col ref="winacntnm" style="text-align:left; "/>
  106. <col ref="befinputamt" format="#,###.##" style="text-align:right; "/>
  107. <col ref="inputamt" format="#,###.##" style="text-align:right; "/>
  108. <col ref="befyyinputamt" format="#,###.##" style="text-align:right; "/>
  109. <col ref="befyyinputavg" visibility="hidden" format="#,###.##" style="text-align:right; "/>
  110. <col ref="subinputamt" format="(-)#,###.##" style="text-align:right; "/>
  111. <col ref="incrateamt" format="(-)#,####.##" style="text-align:right; "/>
  112. <col ref="percent" style="text-align:center; "/>
  113. <col ref="cmt" type="input"/>
  114. <col ref="instcd" visibility="hidden"/>
  115. <col ref="inputmonth" visibility="hidden"/>
  116. <col ref="winacnt" visibility="hidden"/>
  117. </datagrid>
  118. <caption id="caption5" class="tit_2" style="left:5px; top:60px; width:136px; height:14px; ">자재 수불 증감 분석</caption>
  119. <line id="line1" class="line_1" style="x1:0px; y1:75px; x2:1195px; y2:75px; "/>
  120. <caption id="caption1" class="search_name" style="left:230px; top:20px; width:91px; height:17px; ">입고년월 :</caption>
  121. <input id="ipt_inputmonth" ref="/root/send/goodreq/inputmonth" class="input_s_essential" inputtype="date" maxlength="6" format="yyyy-mm" style="left:318px; top:20px; width:75px; height:19px; ">
  122. <script type="javascript" ev:event="xforms-value-changed">
  123. <![CDATA[
  124. fSetGridTitle();
  125. ]]>
  126. </script>
  127. </input>
  128. <button id="btn_save" class="btn5_letter2" style="left:1150px; top:55px; width:42px; height:19px; ">
  129. <caption>저장</caption>
  130. <script type="javascript" ev:event="DOMActivate">
  131. <![CDATA[
  132. model.makeValue("/root/send/savedata/mtallist", getGridUpdateData(grd_mtallist));
  133. if(submit("TXRST05901")) {
  134. messageBox("저장이 완료되었습니다.", "E");
  135. btn_search.dispatch("DOMActivate");
  136. }
  137. ]]>
  138. </script>
  139. </button>
  140. <button id="btn_print" class="btn1_letter2" style="left:1130px; top:20px; width:56px; height:22px; ">
  141. <caption>출력</caption>
  142. <script type="javascript" ev:event="DOMActivate">
  143. <![CDATA[
  144. model.makeNode("/root/send/report/mtallist");
  145. model.makeValue("/root/send/report/inputmonth", model.getValue(ipt_inputmonth.attribute("ref")));
  146. copyNodesetType("/root/send/report/mtallist", "/root/main/mtallist");
  147. exeReportPreview("RPRST05901", "XMLSTR", "/root/send/report");
  148. ]]>
  149. </script>
  150. </button>
  151. <button id="button1" class="btn2_letter4" style="left:1085px; top:55px; width:100px; height:20px; ">
  152. <caption>엑셀저장</caption>
  153. <script type="javascript" ev:event="DOMActivate">
  154. <![CDATA[
  155. var fileName = window.fileDialog("save", ",", false, "자재수불증감분석", "xls", "Excel Files(*.xls)|*.xls|All Files (*.*)|*.*");
  156. if (fileName != "")
  157. {
  158. grd_mtallist.saveExcel(fileName, "자재수불증감분석");
  159. }
  160. ]]>
  161. </script>
  162. </button>
  163. </group>
  164. </xhtml:body>
  165. </xhtml:html>