SMANS02000_중야식통합식수.xrw 7.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175
  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. <list>
  11. <item>
  12. <emplno/>
  13. <name/>
  14. <dutplcedeptnm/>
  15. <deptnm/>
  16. <instnm/>
  17. <count/>
  18. <amount/>
  19. </item>
  20. </list>
  21. </main>
  22. <send>
  23. <fromdd/>
  24. <todd/>
  25. <fromdd2/>
  26. <todd2/>
  27. <globalinstance>
  28. <instance1/>
  29. </globalinstance>
  30. </send>
  31. <hidden/>
  32. </root>
  33. </instance>
  34. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  35. <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
  36. <script type="javascript" ev:event="xforms-ready">
  37. <![CDATA[
  38. var fromdd = getCurrentDate().substring(0, 6) + '0100'; // 적용일자 현재일자 셋팅
  39. var todd = getCurrentDate().substring(0, 6) + '3199'; // 적용일자 현재일자 셋팅
  40. model.removenode("/root/main/list/item");
  41. model.setValue("/root/send/fromdd", fromdd);
  42. model.setValue("/root/send/todd", todd);
  43. model.refresh();
  44. ]]>
  45. </script>
  46. <submission id="TRANS02001" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" replace="instance" resultref="/root/main/list"/>
  47. </model>
  48. </xhtml:head>
  49. <xhtml:body pagewidth="1211" pageheight="784" style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
  50. <group id="grp_tle" style="left:0px; top:0px; width:1195px; height:13px; ">
  51. <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:209px; height:14px; ">중.야식 통합식수현황</caption>
  52. </group>
  53. <group id="grp_biz" scroll="auto" style="left:0px; top:13px; width:1195px; height:744px; ">
  54. <caption id="caption1" class="tit_2" style="left:5px; top:50px; width:200px; height:14px; ">월별 통합식수 리스트</caption>
  55. <line id="line1" class="line_1" style="x1:0px; y1:65px; x2:1183px; y2:65px; "/>
  56. <group id="grp_sea" style="left:0px; top:10px; width:1195px; height:30px; vertical-align:top; ">
  57. <shape id="roundrect1" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:0px; width:1193px; height:30px; background-color:#fffbf2; border-color:#ffd799; "/>
  58. <caption id="caption2" class="search_name" style="left:15px; top:7px; width:86px; height:17px; ">조회기간 :</caption>
  59. <line id="line13" class="line_4" style="x1:1110px; y1:4px; x2:1110px; y2:26px; "/>
  60. <button id="btn_sea" class="btn1_letter2" navindex="4" style="left:1120px; top:4px; width:56px; height:22px; ">
  61. <caption>조회</caption>
  62. <script type="javascript" ev:event="DOMActivate">
  63. <![CDATA[
  64. if (model.getValue("/root/send/fromdd") == ""){
  65. messageBox("조회시작일자는", "I003");
  66. model.setFocus("ipt_fromdd");
  67. return;
  68. }
  69. if (model.getValue("/root/send/todd") == ""){
  70. messageBox("조회종료일자는", "I003");
  71. model.setFocus("ipt_todd");
  72. return;
  73. }
  74. if (model.getValue("/root/send/fromdd") > model.getValue("/root/send/todd")){
  75. messageBox("조회 시작일자는 종료일자 보다 클 수", "I004");
  76. model.setFocus("ipt_fromdd");
  77. return;
  78. }
  79. var fromdd = model.getValue("/root/send/fromdd"); // 적용일자 현재일자 셋팅
  80. var todd = model.getValue("/root/send/fromdd") ; // 적용일자 현재일자 셋팅
  81. var fromdd2 = fromdd.substring(0,6) + '010000';
  82. var todd2 = fromdd.substring(0,6) + '010000';
  83. model.setValue("/root/send/fromdd2", fromdd2);
  84. model.setValue("/root/send/todd2", todd2);
  85. submit("TRANS02001");
  86. grd_sicksulist.subtotalPosition = "below";
  87. grd_sicksulist.subtotal("clear", -1, i, "format:(-,+)#,###; roundmode:round; roundpostion:2", "background-color:#99ff99; font-weight:bold; text-align:center", 2, "총계" );
  88. for(var i=0; i < grd_sicksulist.cols; i++){
  89. if(i >= grd_sicksulist.colRef("count")){
  90. grd_sicksulist.subtotal("sum", -1, i, "format:(-,+)#,###; roundmode:round; roundpostion:2", "background-color:#99ff99; font-weight:bold; text-align:center", 2, "총계" );
  91. }
  92. }
  93. grd_sicksulist.refresh();
  94. ]]>
  95. </script>
  96. </button>
  97. <input id="ipt_todd" ref="/root/send/todd" class="input_default" navindex="2" visibility="hidden" inputtype="date" format="yyyy-mm" style="left:402px; top:6px; width:85px; height:19px; "/>
  98. <input id="ipt_fromdd" ref="/root/send/fromdd" format="yyyy-mm" style="left:106px; top:6px; width:85px; height:19px; text-align:center; ">
  99. <script type="javascript" ev:event="xforms-value-changed">
  100. <![CDATA[
  101. var fromdd = model.getValue("/root/send/fromdd");
  102. var temp1 = fromdd+ '0100';
  103. var temp2 = fromdd+ '3199';
  104. model.setValue("/root/send/fromdd", temp1);
  105. model.setValue("/root/send/todd" , temp2);
  106. model.refresh();
  107. ]]>
  108. </script>
  109. </input>
  110. <button id="btn_next" class="icon_next" style="left:208px; top:8px; width:13px; height:15px; ">
  111. <caption/>
  112. <script type="javascript" ev:event="onclick">
  113. <![CDATA[
  114. var dd = model.getValue("/root/send/fromdd") + "01";
  115. dd = dd.toDate().getAddDate(1, "M");
  116. var dd1 = dd.getDateFormat("YYYYMM") + '0100';
  117. var dd2 = dd.getDateFormat("YYYYMM") + '3199';
  118. model.setValue("/root/send/fromdd", dd1);
  119. model.setValue("/root/send/todd" , dd2);
  120. model.refresh();
  121. ]]>
  122. </script>
  123. </button>
  124. <button id="btn_before" class="icon_pre" style="left:193px; top:8px; width:13px; height:15px; ">
  125. <caption/>
  126. <script type="javascript" ev:event="onclick">
  127. <![CDATA[
  128. var dd = model.getValue("/root/send/fromdd") + "01";
  129. dd = dd.toDate().getAddDate(-1, "M");
  130. var dd1 = dd.getDateFormat("YYYYMM")+ '0100';
  131. var dd2 = dd.getDateFormat("YYYYMM") + '3199';
  132. model.setValue("/root/send/fromdd", dd1);
  133. model.setValue("/root/send/todd" , dd2);
  134. model.refresh();
  135. ]]>
  136. </script>
  137. </button>
  138. </group>
  139. <button id="btn_excsave" class="btn2_letter4" style="left:1120px; top:45px; width:64px; height:19px; ">
  140. <caption>엑셀저장</caption>
  141. <script type="javascript" ev:event="DOMActivate">
  142. <![CDATA[
  143. var fileName = window.fileDialog("save", ",", false, "", "xls", "Excel Files(*.xls)|*.xls|All Files (*.*)|*.*");
  144. if (fileName != "") {
  145. grd_sicksulist.saveExcel(fileName);
  146. }
  147. ]]>
  148. </script>
  149. </button>
  150. <datagrid id="grd_sicksulist" nodeset="/root/main/list/item" class="datagrid2" caption="사번^성명^본원부서^칠곡부서^소속^사용수^총금액" colsep="^" colwidth="70, 100, 300, 300, 100, 100, 100" explorerbar="sortshow" frozencols="7" mergecellsfixedrows="bycolrec" rowheader="seq" rowsep="|" selectionmode="free" style="left:0px; top:71px; width:1183px; height:669px; ">
  151. <col disabled="true" ref="emplno" style="text-align:center; "/>
  152. <col disabled="true" ref="name" style="text-align:center; "/>
  153. <col disabled="true" ref="dutplcedeptnm" style="text-align:center; "/>
  154. <col disabled="true" ref="deptnm" style="text-align:center; "/>
  155. <col disabled="true" ref="instnm" style="text-align:center; "/>
  156. <col disabled="true" ref="count" format="#,###" style="text-align:center; "/>
  157. <col disabled="true" ref="amount" format="#,###" style="text-align:center; "/>
  158. <script type="javascript" ev:event="onaftersort">
  159. <![CDATA[
  160. grd_sicksulist.gridtoinstance();
  161. ]]>
  162. </script>
  163. </datagrid>
  164. </group>
  165. </xhtml:body>
  166. </xhtml:html>