SMRAD03300_구매검수자료내역조회.xrw 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283
  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. <grnt>
  11. <grntlist2>
  12. <kydate/>
  13. <kyseq/>
  14. <ibgoymd/>
  15. <ibgoseq/>
  16. <acctid/>
  17. <acntnm/>
  18. <custcode/>
  19. <custnm/>
  20. <keumak/>
  21. </grntlist2>
  22. </grnt>
  23. </main>
  24. <send>
  25. <paydedu>
  26. <instcd/>
  27. <fromdd/>
  28. <todd/>
  29. <totamt/>
  30. </paydedu>
  31. <save>
  32. <grntlist1/>
  33. </save>
  34. </send>
  35. <custinfo>
  36. <custlist>
  37. <aactno/>
  38. <bankcd/>
  39. <depor/>
  40. <custnm/>
  41. </custlist>
  42. </custinfo>
  43. <acntinfo>
  44. <acntlist>
  45. <acntnm/>
  46. </acntlist>
  47. </acntinfo>
  48. <hidden>
  49. <item>
  50. <pumno/>
  51. </item>
  52. </hidden>
  53. </root>
  54. </instance>
  55. <script type="javascript" ev:event="xforms-ready">
  56. <![CDATA[
  57. initialize();
  58. ]]>
  59. </script>
  60. <submission id="TRRAD01502" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/paydedu" resultref="/root/custinfo"/>
  61. <submission id="TRRAD02501" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/paydedu" resultref="/root/acntinfo"/>
  62. <submission id="TRRAD03301" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/paydedu" resultref="/root/main/grnt"/>
  63. <submission id="TXRAD02401" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/save" resultref="/root/hidden"/>
  64. </model>
  65. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  66. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  67. <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
  68. <script type="javascript" src="../../../mis/miscommonweb/js/MIS.js"/>
  69. <script type="javascript" src="../../../mis/paybaseinfomngtweb/js/RWC001.js"/>
  70. <script type="javascript" src="../../../mis/humtrafactmngtweb/js/RPB001.js"/>
  71. <script type="javascript" src="../../../mis/paybaseinfomngtweb/js/RWC001.js"/>
  72. <script type="javascript" src="../../../mis/miscommonweb/js/RAC001.js"/>
  73. <script type="javascript" src="../../../mis/acntcommonweb/js/RAD001.js"/>
  74. <script type="javascript">
  75. <![CDATA[
  76. function fOpenPopupDeptHelp(pControl, pInstance)
  77. {
  78. misfOpenPopUpList("02", pControl, "", pInstance);
  79. model.refresh();
  80. }
  81. function fOpenPopupHelp(pHelper, pControl, pInstance, pCdgrupid, pValueControl, pNodeName)
  82. {
  83. misfOpenPopUpList(pHelper, pControl, pCdgrupid, pInstance, pValueControl, pNodeName);
  84. model.refresh();
  85. }
  86. function initialize(){
  87. misfGridInit(grd_grntpsn1);
  88. misfMsterDetailSet(grd_grntpsn1,null, "TRRAD03301" ,"Y");
  89. var curdate = getCurrentDate();
  90. model.setValue(cmb_instcd.attribute("ref") , getUserInfo("dutplceinstcd"));
  91. var deptcd = getUserInfo("dutplcecd");
  92. var deptnm = getUserInfo("dutplcenm");
  93. model.setValue("/root/send/paydedu/fromdd", curdate.substr(0, 6));
  94. //model.setValue("/root/send/paydedu/todd", getCurrentDate().toDate().getAddDate(+1,"D").getDateFormat("YYYYMMDD"));
  95. //var emplno = getUserInfo("userid");
  96. //var emplnm = getUserInfo("usernm");
  97. //model.setValue("/root/send/paydedu/slipyn", "Y");
  98. misfComboInstCdListMulti("cmb_instcd",getCurrentDate(),"","N");
  99. model.setFocus("ipt_unsldd");
  100. //misfComboComCdListMulti("R0001","grd_grntpsn1.bankcode");
  101. //btn_search.dispatch("DOMActivate");
  102. model.refresh();
  103. }
  104. function Popup(){
  105. var ymd = model.getValue("/root/main/grnt/grntlist1/junpyodate");
  106. var mdeptcd = model.getValue("/root/main/grnt/grntlist1/makedeptcd");
  107. var ydeptcd = model.getValue("/root/main/grnt/grntlist1/yogudeptcd");
  108. if (ymd != "" && mdeptcd != "" && ydeptcd != ""){
  109. model.setValue("/root/popdata/junpyodate", ymd);
  110. model.setValue("/root/popdata/makedeptcd", mdeptcd);
  111. model.setValue("/root/popdata/yogudeptcd", ydeptcd);
  112. model.setValue("/root/popdata/pumgubun", "3");
  113. modal("SPRAD00400", "", "", "", "SPRAD00400","/root/popdata","/root/popdata");
  114. }
  115. }
  116. function Maxseq(){
  117. var flag = model.getValue("/root/main/grnt/grntlist2[" + grd_grntpsn1.row + "]/flag");
  118. if (flag == "Y"){
  119. var ymd = model.getValue("/root/main/grnt/grntlist2[" + grd_grntpsn1.row + "]/ymdwrite");
  120. var maxseq = 0;
  121. var maxseq1 = 0;
  122. var maxseq2 = 0;
  123. var ymd1 = "";
  124. /*
  125. for (var i = 1; i < grd_grntpsn1.rows; i++){
  126. ymd1 = model.getValue("/root/main/grnt/grntlist2[" + i + "]/ymdwrite");
  127. if (ymd == ymd1){
  128. maxseq1 = model.getValue("/root/main/grnt/grntlist2[" + i + "]/maxseq");
  129. if (isNaN(maxseq1)){
  130. maxseq1 = 0;
  131. }
  132. if (parseInt(maxseq1) > parseInt(maxseq)){
  133. maxseq = maxseq1;
  134. }
  135. }
  136. }
  137. if (maxseq == 0){
  138. maxseq = 1;
  139. }
  140. */
  141. for (var i = 1; i < grd_grntpsn1.rows; i++){
  142. ymd1 = model.getValue("/root/main/grnt/grntlist2[" + i + "]/ymdwrite");
  143. //if (ymd == ymd1){
  144. maxseq1 = model.getValue("/root/main/grnt/grntlist2[" + i + "]/gipyoseq");
  145. if (isNaN(maxseq1)){
  146. maxseq1 = 0;
  147. }
  148. if (parseInt(maxseq1) > parseInt(maxseq)){
  149. maxseq = maxseq1;
  150. }
  151. //}
  152. }
  153. maxseq = parseInt(maxseq) + 1;
  154. model.setValue("/root/main/grnt/grntlist2[" + grd_grntpsn1.row + "]/gipyoseq", maxseq);
  155. grd_grntpsn1.rowStatus(grd_grntpsn1.row) = 2;
  156. }else{
  157. model.setValue("/root/main/grnt/grntlist2[" + grd_grntpsn1.row + "]/gipyoseq", "");
  158. if (model.getValue("/root/main/grnt/grntlist2[" + grd_grntpsn1.row + "]/seqwrite") == ""){
  159. grd_grntpsn1.rowStatus(grd_grntpsn1.row) = 0;
  160. }
  161. }
  162. model.refresh();
  163. }
  164. ]]>
  165. </script>
  166. </xhtml:head>
  167. <xhtml:body>
  168. <group id="group1" style="left:0px; top:0px; width:1195px; height:13px; ">
  169. <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:800px; height:14px; ">구매검수자료내역조회</caption>
  170. </group>
  171. <group id="group2" scroll="auto" style="left:0px; top:38; width:1195px; height:744px; ">
  172. <shape id="roundrect1" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:10px; width:1194px; height:35px; background-color:#fffbf2; border-color:#ffd799; "/>
  173. <button id="btn_search" class="btn1_letter2" style="left:1128px; top:16px; width:56px; height:22px; ">
  174. <caption>조회</caption>
  175. <script type="javascript" ev:event="DOMActivate">
  176. <![CDATA[
  177. misfMsterDetailRetrieve();
  178. var totamt = 0;
  179. var amt = 0;
  180. for (var i = 1; i < grd_grntpsn1.rows; i++){
  181. amt = model.getValue("/root/main/grnt/grntlist2[" + i +"]/keumak");
  182. if (isNaN(amt) || amt == ""){
  183. amt = 0;
  184. }
  185. totamt = parseFloat(totamt) + parseFloat(amt);
  186. }
  187. model.setValue("/root/send/paydedu/totamt", totamt);
  188. model.refresh();
  189. ]]>
  190. </script>
  191. </button>
  192. <line id="line13" class="line_4" visibility="hidden" style="x1:1121px; y1:16px; x2:1121px; y2:38px; "/>
  193. <line id="line1" class="line_1" style="x1:0px; y1:71px; x2:1192px; y2:71px; "/>
  194. <select1 id="cmb_instcd" ref="/root/send/paydedu/instcd" class="combo_s_essential" disabled="true" appearance="minimal" style="left:78px; top:17px; width:115px; height:19px; ">
  195. <choices>
  196. <itemset>
  197. <label/>
  198. <value/>
  199. </itemset>
  200. </choices>
  201. </select1>
  202. <caption id="caption2" class="search_name" style="left:12px; top:18px; width:61px; height:17px; ">기관 :</caption>
  203. <datagrid id="grd_grntpsn1" nodeset="/root/main/grnt/grntlist2" caption="계약일자^계약일자^입고일자^입고일자^품목계정^품목계정^거래처^거래처^금액" colsep="^" colwidth="106, 49, 107, 59, 76, 230, 58, 303, 156" dataheight="25" ellipsis="true" explorerbar="sortshow" mergecellsfixedrows="bycolrec" rowheader="seq" rowheight="25" rowsep="|" tooltip="true" style="left:0px; top:77px; width:1192px; height:665px; ">
  204. <col ref="kydate" format="yyyy-mm-dd" style="text-align:center; "/>
  205. <col ref="kyseq"/>
  206. <col ref="ibgoymd" format="yyyy-mm-dd" style="text-align:center; "/>
  207. <col ref="ibgoseq"/>
  208. <col ref="acctid"/>
  209. <col ref="acntnm"/>
  210. <col ref="custcode"/>
  211. <col ref="custnm"/>
  212. <col ref="keumak" format="(-)#,###" style="text-align:right; "/>
  213. <script type="javascript" ev:event="xforms-value-changed">
  214. <![CDATA[
  215. if (grd_grntpsn1.colAttribute(grd_grntpsn1.col,"ref") == "flag"){
  216. Maxseq();
  217. }
  218. model.refresh();
  219. /*
  220. if (grd_grntpsn1.colAttribute(grd_grntpsn1.col,"ref") == "flagwrite" && model.getValue("/root/send/paydedu/newgb") == "I") {
  221. var flagwrite = model.getValue("/root/main/grnt/grntlist2[" + grd_grntpsn1.row + "]/flagwrite");
  222. if (flagwrite == "Y"){
  223. var seq = model.getValue("/root/send/paydedu/flagseq");
  224. if (isNaN(seq) || seq == null || seq == ""){
  225. seq = 0;
  226. }
  227. seq = parseInt(seq) + 1;
  228. model.setValue("/root/main/grnt/grntlist2[" + grd_grntpsn1.row + "]/flagseq", seq);
  229. model.setValue("/root/send/paydedu/flagseq", seq);
  230. }else{
  231. model.setValue("/root/main/grnt/grntlist2[" + grd_grntpsn1.row + "]/flagseq", "");
  232. model.setValue("/root/main/grnt/grntlist2[" + grd_grntpsn1.row + "]/ymdgive", "");
  233. }
  234. model.refresh();
  235. }
  236. */
  237. ]]>
  238. </script>
  239. <script type="javascript" ev:event="onaftersort">
  240. <![CDATA[
  241. grd_grntpsn1.gridToInstance();
  242. ]]>
  243. </script>
  244. </datagrid>
  245. <input id="ipt_unsldd" ref="/root/send/paydedu/fromdd" class="input_s_essential" navindex="1" inputtype="date" format="yyyy-mm" style="left:355px; top:17px; width:100px; height:19px; text-align:center; ">
  246. <script type="javascript" ev:event="xforms-value-changed">
  247. <![CDATA[
  248. //btn_search.dispatch("DOMActivate");
  249. /*
  250. for (var i = 1; i < grd_grntpsn1.rows;i++){
  251. model.setValue("/root/main/grnt/grntlist2[" + i + "]/junpyodate", model.getValue("/root/main/grnt/grntlist1/junpyodate"));
  252. }
  253. model.refresh();
  254. */
  255. ]]>
  256. </script>
  257. </input>
  258. <caption id="caption1" class="tit_2" style="left:5px; top:56px; width:131px; height:14px; ">구매검수현황</caption>
  259. <caption id="caption4" style="left:925px; top:50px; width:45px; height:20px; font-weight:bold; ">총금액</caption>
  260. <input id="input2" ref="/root/send/paydedu/totamt" editable="false" format="(-)#,###" style="left:981px; top:51px; width:139px; height:19px; font-weight:bold; text-align:right; "/>
  261. <caption id="caption3" class="search_name" style="left:265px; top:18px; width:86px; height:17px; ">기준년월 :</caption>
  262. <button id="btn_savegrntpsn1excel" class="btn2_letter4" style="left:1127px; top:51px; width:64px; height:19px; ">
  263. <caption>엑셀저장</caption>
  264. <script type="javascript" ev:event="DOMActivate">
  265. <![CDATA[
  266. var fileName = window.fileDialog ("save", ",", false, "excel", "xls", "All Files (*.*)|*.*|Excel Files(*.xls)|*.xls");
  267. if (fileName != "")
  268. {
  269. grd_grntpsn1.saveExcel(fileName);
  270. }
  271. ]]>
  272. </script>
  273. </button>
  274. </group>
  275. <group id="grp_btn" scroll="auto" style="left:0px; top:12; width:1195px; height:27px; ">
  276. <line id="line9" class="line_6" style="x1:0; y1:25; x2:1195; y2:25; "/>
  277. </group>
  278. </xhtml:body>
  279. </xhtml:html>