SMRSI03900_영양팀 계정별 입고 일계표.xrw 8.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208
  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. <rsihinnulist/>
  11. </main>
  12. <send>
  13. <instcd/>
  14. <goodflag/>
  15. <fromwindd/>
  16. <towindd/>
  17. </send>
  18. <init/>
  19. <temp/>
  20. </root>
  21. </instance>
  22. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  23. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  24. <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
  25. <script type="javascript" src="../../../mis/miscommonweb/js/MIS.js"/>
  26. <script type="javascript" src="../../../mis/miscommonweb/js/RSZ001.js"/>
  27. <script type="javascript" src="../../../com/commonweb/js/stringHelper.js"/>
  28. <script type="javascript" ev:event="xforms-ready">
  29. <![CDATA[
  30. fInitialize();
  31. ]]>
  32. </script>
  33. <script type="javascript">
  34. <![CDATA[
  35. function fInitialize()
  36. {
  37. misfGridInit(grd_rsihinnulist);
  38. misfComboComCdList("Z0007", cmb_instcd);
  39. cmb_instcd.value = getUserInfo("dutplceinstcd");
  40. opt_goodflag.value = "SF";
  41. // 현재 날짜 기본 입력(6개월 간격 설정)
  42. var reqdate = getCurrentDate().toDate("YYYYMMDD");
  43. model.setValue(ipt_fromwindd.attribute("ref"), reqdate.getDateFormat("YYYYMM") + "01" );
  44. model.setValue(ipt_towindd.attribute("ref"), getCurrentDate());
  45. misfMsterDetailSet(grd_rsihinnulist, null, "TRRSI03901", "N");
  46. model.refresh();
  47. }
  48. function fGridGTSN(fGubun, fStart)
  49. {
  50. // GTSN
  51. misfGridIUD(grd_rsihinnulist, "A");
  52. //grd_rsihinnulist.insertRow(grd_rsihinnulist.rows-1, "above", "false", "true");
  53. grd_rsihinnulist.rowstyle(grd_rsihinnulist.row, "data", "background-color") = "#ccffff";
  54. grd_rsihinnulist.rowstyle(grd_rsihinnulist.row, "data", "font-weight") = "bold";
  55. var row = grd_rsihinnulist.row;
  56. var gubun = fGubun;
  57. grd_rsihinnulist.issubtotal(row) = true;
  58. if(fStart != "")
  59. {
  60. grd_rsihinnulist.valueMatrix(row, grd_rsihinnulist.colRef("windd")) = fStart;
  61. }
  62. grd_rsihinnulist.valueMatrix(row, grd_rsihinnulist.colRef("gubunnm")) = gubun;
  63. for(var r=0; r < grd_rsihinnulist.rows; r++)
  64. {
  65. if( grd_rsihinnulist.issubtotal(r) == false && row != r)
  66. {
  67. if(grd_rsihinnulist.valueMatrix(r, grd_rsihinnulist.colRef("gubunnm")) == gubun )
  68. {
  69. for(var c=3; c < grd_rsihinnulist.cols; c++)
  70. {
  71. grd_rsihinnulist.cellFormat(row, c) = '#,###';
  72. if(grd_rsihinnulist.valueMatrix(row, c) == '')
  73. {
  74. grd_rsihinnulist.valueMatrix(row, c) = 0;
  75. }
  76. grd_rsihinnulist.valueMatrix(row, c) = parseInt(grd_rsihinnulist.valueMatrix(row, c)) + parseInt(grd_rsihinnulist.valueMatrix(r, c));
  77. }
  78. }
  79. }
  80. }
  81. }
  82. function fGridTotal()
  83. {
  84. grd_rsihinnulist.subtotal("clear", 0, 0);
  85. for(var i=0; i < 16; i++)
  86. {
  87. grd_rsihinnulist.subTotal("sum", 1, i+3, "format:#,###; ", "background-color:#ffff99; font-weight:bold; ", 1, "합계");
  88. }
  89. fGridGTSN('G', "총합");
  90. fGridGTSN('T');
  91. fGridGTSN('S');
  92. fGridGTSN('N');
  93. // 총합계
  94. for(var i=0; i < 16; i++)
  95. {
  96. grd_rsihinnulist.subTotal("sum", -1, i+3, "format:#,###; ", "background-color:#ffff99; font-weight:bold; ", 1, "계");
  97. }
  98. }
  99. function fGridMerge()
  100. {
  101. for(var i=2; i<grd_rsihinnulist.cols; i++)
  102. {
  103. grd_rsihinnulist.mergecol(i) = false;
  104. }
  105. }
  106. ]]>
  107. </script>
  108. <submission id="TRRSI03901" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main/rsihinnulist"/>
  109. </model>
  110. </xhtml:head>
  111. <xhtml:body style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
  112. <group id="grp_tle" style="left:0px; top:0px; width:1195px; height:13px; ">
  113. <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:173px; height:14px; ">영양팀 계정별 입고 일계표</caption>
  114. </group>
  115. <group id="grp_biz" scroll="auto" style="left:0px; top:38; width:1195px; height:744px; ">
  116. <group id="grp_sea" style="left:0px; top:10px; width:1195px; height:40px; vertical-align:top; ">
  117. <shape id="roundrect1" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:0px; width:1195px; height:40px; background-color:#fffbf2; border-color:#ffd799; "/>
  118. <caption id="cap_instcd" class="search_name" style="left:15px; top:9; width:99px; height:17px; ">기관코드 :</caption>
  119. <select1 id="cmb_instcd" ref="/root/send/instcd" class="combo_s_essential" appearance="minimal" style="left:105px; top:8px; width:205px; height:19px; text-align:center; ">
  120. <choices>
  121. <itemset>
  122. <label/>
  123. <value/>
  124. </itemset>
  125. </choices>
  126. </select1>
  127. <input id="ipt_fromwindd" ref="/root/send/fromwindd" class="input_s_essential" inputtype="date" format="yyyy-mm-dd" style="left:456px; top:9px; width:134px; height:19px; text-align:center; "/>
  128. <caption id="cap_day" class="search_name" style="left:365px; top:10px; width:99px; height:17px; ">조회일자 :</caption>
  129. <line id="line30" class="line_4" style="x1:1110px; y1:9px; x2:1110px; y2:32px; "/>
  130. <button id="btn_search" class="btn1_letter2" style="left:1125px; top:10px; width:56px; height:22px; font-weight:bold; ">
  131. <caption>조회</caption>
  132. <script type="javascript" ev:event="DOMActivate">
  133. <![CDATA[
  134. submit("TRRSI03901");
  135. fGridTotal();
  136. fGridMerge();
  137. grd_rsihinnulist.refresh();
  138. ]]>
  139. </script>
  140. </button>
  141. <output id="opt_goodflag" ref="/root/send/goodflag" visibility="hidden" style="left:920px; top:10px; width:100px; height:19px; "/>
  142. <input id="ipt_towindd" ref="/root/send/towindd" class="input_s_essential" inputtype="date" format="yyyy-mm-dd" style="left:607px; top:9px; width:134px; height:19px; text-align:center; "/>
  143. <caption id="caption1" style="left:592px; top:10px; width:15px; height:20px; ">~</caption>
  144. </group>
  145. <caption id="cap_title" class="tit_2" style="left:5px; top:59px; width:206px; height:14px; ">영양팀 계정별 입고 일계표</caption>
  146. <line id="line2" class="line_1" style="x1:0px; y1:74px; x2:1195px; y2:74px; "/>
  147. <datagrid id="grd_rsihinnulist" nodeset="/root/main/rsihinnulist" caption="^^1^2^3^4^5^6^7^8^9^10^11^12^13^14^15^계|^^곡류^두류^견과 종실류^채소류^과실류^육류^난류^어패류^우유류^음료류^조미료류^특수의료용도식품류^기타^기타2^기타3^" colsep="^" colwidth="77, 26, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65" ellipsis="true" extendlastcol="scroll" frozencols="2" mergecells="bycol" rowheader="seq" rowsep="|" subtotalposition="below" tooltip="true" style="left:0px; top:79px; width:1194px; height:664px; ">
  148. <col ref="windd" style="text-align:center; "/>
  149. <col ref="gubunnm" style="text-align:center; "/>
  150. <col ref="lrgcd01" format="#,###" style="text-align:right; "/>
  151. <col ref="lrgcd02" format="#,###" style="text-align:right; "/>
  152. <col ref="lrgcd03" format="#,###" style="text-align:right; "/>
  153. <col ref="lrgcd04" format="#,###" style="text-align:right; "/>
  154. <col ref="lrgcd05" format="#,###" style="text-align:right; "/>
  155. <col ref="lrgcd06" format="#,###" style="text-align:right; "/>
  156. <col ref="lrgcd07" format="#,###" style="text-align:right; "/>
  157. <col ref="lrgcd08" format="#,###" style="text-align:right; "/>
  158. <col ref="lrgcd09" format="#,###" style="text-align:right; "/>
  159. <col ref="lrgcd10" format="#,###" style="text-align:right; "/>
  160. <col ref="lrgcd11" format="#,###" style="text-align:right; "/>
  161. <col ref="lrgcd12" format="#,###" style="text-align:right; "/>
  162. <col ref="lrgcd13" format="#,###" style="text-align:right; "/>
  163. <col ref="lrgcd14" format="#,###" style="text-align:right; "/>
  164. <col ref="lrgcd15" format="#,###" style="text-align:right; "/>
  165. <col ref="lrgcdtot" format="#,###" style="text-align:right; "/>
  166. </datagrid>
  167. </group>
  168. <group id="grp_btn" scroll="auto" style="left:0px; top:12px; width:1195px; height:27px; ">
  169. <line id="line19" class="line_2" style="x1:0; y1:25; x2:1195; y2:25; "/>
  170. <line id="line22" class="line_6" style="x1:0px; y1:25; x2:1195px; y2:25; "/>
  171. <button id="btn_init" class="btn4_letter3" style="left:1127px; top:3px; width:68px; height:22px; ">
  172. <caption>초기화</caption>
  173. <script type="javascript" ev:event="DOMActivate">
  174. <![CDATA[
  175. fInitialize();
  176. ]]>
  177. </script>
  178. </button>
  179. </group>
  180. </xhtml:body>
  181. </xhtml:html>