SMRSD02300_수탁물품 정산처리.xrw 27 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579
  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. <list>
  11. <gooddelive>
  12. <gooddelivelist/>
  13. </gooddelive>
  14. <custdelive>
  15. <custdelivelist/>
  16. </custdelive>
  17. </list>
  18. </main>
  19. <send>
  20. <gooddelive>
  21. <instcd/>
  22. <delivefrdd/>
  23. <delivetodd/>
  24. <maincustlastsuplplce/>
  25. <maincustlastsuplplcenm/>
  26. <goodflag/>
  27. <targetflag/>
  28. <userid/>
  29. <gooddelivelist/>
  30. <delivedeptcd/>
  31. <genwinyn/>
  32. <genpurcdd/>
  33. <goodcd/>
  34. <goodnm/>
  35. </gooddelive>
  36. <gooddelivedet>
  37. <instcd/>
  38. <delivefrdd/>
  39. <delivetodd/>
  40. <maincustlastsuplplce/>
  41. <goodflag/>
  42. <delivedeptcd/>
  43. <genwinyn/>
  44. <suppcustcd/>
  45. <goodcd/>
  46. </gooddelivedet>
  47. </send>
  48. <init>
  49. <deliveprcsflag>
  50. <label>미불출</label>
  51. <value>1</value>
  52. <label>불출</label>
  53. <value>2</value>
  54. </deliveprcsflag>
  55. <getwinyn>
  56. <label>전체</label>
  57. <value/>
  58. <label>정산</label>
  59. <value>Y</value>
  60. <label>미정산</label>
  61. <value>N</value>
  62. </getwinyn>
  63. <workflag/>
  64. <nonusegoodview>
  65. <label>포함</label>
  66. <value>Y</value>
  67. <label>제외</label>
  68. <value/>
  69. </nonusegoodview>
  70. </init>
  71. <hidden>
  72. <nonusegoodview/>
  73. </hidden>
  74. </root>
  75. </instance>
  76. <script type="javascript" ev:event="xforms-ready">
  77. <![CDATA[
  78. //화면 Control을 초기화한다
  79. fInitialize();
  80. ]]>
  81. </script>
  82. <submission id="TRRSD02301" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/gooddelivedet" resultref="/root/main/list/gooddelive"/>
  83. <submission id="TRRSD02302" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/gooddelive" resultref="/root/main/list/custdelive"/>
  84. <submission id="TRRSD02202" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/goodorder" resultref="/root/main/list/goodorder"/>
  85. <submission id="TXRSD02301" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/gooddelive" resultref="/root/hidden/temp">"</submission>
  86. </model>
  87. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  88. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  89. <script type="javascript" src="../../../mis/miscommonweb/js/MIS.js"/>
  90. <script type="javascript" src="../../../mis/miscommonweb/js/RSZ001.js"/>
  91. <script type="javascript" src="../../../com/commonweb/js/stringHelper.js"/>
  92. <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
  93. <script type="javascript">
  94. <![CDATA[
  95. // 화면 open시와 초기화 버튼 클릭시 화면 초기화 기능을 수행한다.
  96. function fInitialize() {
  97. misfGridInit(grd_custdelive);
  98. misfGridInit(grd_gooddelive);
  99. rszfUserInstList(cmb_instcd,getUserInfo("userid"));
  100. model.setValue(cmb_instcd.attribute("ref") , getUserInfo("dutplceinstcd"));
  101. var curdate = getCurrentDate();
  102. var cvtdate = curdate.toDate("YYYYMMDD");
  103. model.setValue(ipt_delivefrdd.attribute("ref") ,cvtdate.getAddDate(-10,"D").getDateFormat("YYYYMMDD"));
  104. model.setValue(ipt_delivetodd.attribute("ref") , curdate);
  105. model.setValue(ipt_genpurcdd.attribute("ref"), model.getValue(ipt_delivefrdd.attribute("ref")).substr(0,6)+"01");
  106. misfMsterDetailSet(grd_custdelive,null, "TRRSD02302" ,"Y");
  107. misfMsterDetailSet(grd_gooddelive,grd_custdelive, "TRRSD02301" ,"Y");
  108. // hidden col
  109. model.setValue(opt_goodflag.attribute("ref") , "Y");
  110. //부서가 구매팀인지 확인해서 구매팀일 경우 부서찾기 항목을 visibility true 아니면 false
  111. // -------------------------------------------------------------------------------------
  112. // 기관별 구매시스템 기본정보를 조회한다
  113. // vPathResult = "/root/init/RscsysinftLists";
  114. // -------------------------------------------------------------------------------------
  115. rszfRscsysinftLists(getUserInfo("dutplceinstcd"));
  116. // -------------------------------------------------------------------------------------
  117. // 구매 인터페이스 거래처정보를 조회한다
  118. // vPathResult = "/root/init/RscifcustLists";
  119. // pInstcd" : (조회값) 기관코드
  120. // pEntrregno" : (조회값) 거래처
  121. // pMaindeptcd" : (조회값) 관리부서코드
  122. // pCombo : 콤보구분
  123. // pAllYN : 전체구분
  124. // ------------------------------------------------------------------------------------*/
  125. model.setValue(opt_delivedeptcd.attribute("ref"), getRscsysinftInfo("purcdept"));
  126. rdo_workflag.selectedIndex = 0;
  127. rdo_nonusegoodview.select(0);
  128. model.refresh();
  129. }
  130. function fCheckGrid()
  131. {
  132. for(var r = grd_gooddelive.fixedRows; r < grd_gooddelive.rows; r++)
  133. {
  134. if(grd_gooddelive.valueMatrix( r, grd_gooddelive.colRef("genwin")) != 'Y' ){
  135. grd_gooddelive.valueMatrix(r, grd_gooddelive.colRef("genwin")) = 'Y';
  136. grd_gooddelive.rowStatus(r) = "2";
  137. }
  138. }
  139. }
  140. function fCheckRetrieveData()
  141. {
  142. if(model.getValue(cmb_instcd.attribute("ref")).length== 0 )
  143. {
  144. model.setFocus("cmb_instcd");
  145. return false;
  146. }
  147. if(model.getValue(ipt_delivefrdd.attribute("ref")).length== 0 )
  148. {
  149. model.setFocus("ipt_delivefrdd");
  150. return false;
  151. }
  152. if(model.getValue(ipt_delivetodd.attribute("ref")).length== 0 )
  153. {
  154. model.setFocus("ipt_delivetodd");
  155. return false;
  156. }
  157. if(model.getValue(ipt_genpurcdd.attribute("ref")).length== 0 )
  158. {
  159. model.setFocus("ipt_genpurcdd");
  160. return false;
  161. }
  162. return true;
  163. }
  164. function fGridShowSetting (showflag) {
  165. if( showflag == 1 ) {
  166. cap_custList.attribute("visibility") = "visible";
  167. grd_custdelive.attribute("visibility") = "visible";
  168. lin_custList.attribute("visibility") = "visible";
  169. cap_good.attribute("left") = "380" ;
  170. lin_good.attribute("x1") = "380" ;
  171. grd_gooddelive.attribute("left") = "380" ;
  172. grd_gooddelive.attribute("width") = "815" ;
  173. } else {
  174. grd_custdelive.attribute("visibility") = "hidden";
  175. cap_custList.attribute("visibility") = "hidden";
  176. lin_custList.attribute("visibility") = "hidden";
  177. cap_good.attribute("left") = cap_custList.attribute("left") ;
  178. lin_good.attribute("x1") = lin_custList.attribute("x1") ;
  179. grd_gooddelive.attribute("left") = grd_custdelive.attribute("left") ;
  180. grd_gooddelive.attribute("width") = group5.attribute("width") ;
  181. model.setValue("/root/send/gooddelivedet/suppcustcd" , "" );
  182. }
  183. }
  184. function fDefualtSetting () {
  185. model.setValue("/root/send/gooddelivedet/instcd" , model.getValue(cmb_instcd.attribute("ref")) );
  186. model.setValue("/root/send/gooddelivedet/maincustlastsuplplce" , model.getValue(ipt_maincustlastsuplplce.attribute("ref")) );
  187. model.setValue("/root/send/gooddelivedet/goodflag" , model.getValue(opt_goodflag.attribute("ref")) );
  188. model.setValue("/root/send/gooddelivedet/delivedeptcd" , model.getValue(opt_delivedeptcd.attribute("ref")) );
  189. model.setValue("/root/send/gooddelivedet/delivefrdd" , model.getValue(ipt_delivefrdd.attribute("ref")) );
  190. model.setValue("/root/send/gooddelivedet/delivetodd" , model.getValue(ipt_delivetodd.attribute("ref")) );
  191. model.setValue("/root/send/gooddelivedet/genwinyn" , model.getValue(cmb_genwinyn.attribute("ref")) );
  192. model.setValue("/root/send/gooddelivedet/goodcd" , model.getValue(ipt_goodcd.attribute("ref")) );
  193. }
  194. ]]>
  195. </script>
  196. </xhtml:head>
  197. <xhtml:body style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
  198. <group id="group1" style="left:0px; top:0px; width:1195; height:13px; ">
  199. <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:189px; height:14px; ">수탁물품 정산처리</caption>
  200. </group>
  201. <group id="group5" scroll="auto" style="left:0px; top:38px; width:1195px; height:744px; ">
  202. <caption id="cap_good" class="tit_2" style="left:381px; top:73px; width:157px; height:13px; ">불출부서 집계내역</caption>
  203. <group id="group6" style="left:0px; top:5px; width:1195px; height:60px; vertical-align:top; ">
  204. <shape id="roundrect3" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:0px; width:1195px; height:60px; background-color:#fffbf2; border-color:#ffd799; "/>
  205. <button id="btn_search" class="btn1_letter2" navindex="8" style="left:1124px; top:22px; width:56px; height:22px; text-align:left; ">
  206. <caption>조회</caption>
  207. <script type="javascript" ev:event="DOMActivate">
  208. <![CDATA[
  209. if(fCheckRetrieveData() == false)return;
  210. misfGridInit(grd_custdelive);
  211. misfGridInit(grd_gooddelive);
  212. // misfMsterDetailRetrieve();
  213. if ( model.getValue(rdo_workflag.attribute("ref")) == 1 )
  214. submit("TRRSD02302");
  215. else {
  216. fDefualtSetting();
  217. submit("TRRSD02301");
  218. }
  219. // for(cnt = grd_gooddelive.fixedRows; cnt< grd_gooddelive.rows; cnt++) {
  220. // if (model.getValue(grd_gooddelive.nodeset + "[" + cnt + "]/deliveunit") !=
  221. // model.getValue(grd_gooddelive.nodeset + "[" + cnt + "]/delivepackunit") ) {
  222. // grd_gooddelive.cellstyle("background-color", cnt, 10) = "#FFFF00";
  223. // grd_gooddelive.cellstyle("background-color", cnt, 11) = "#FFFF00";
  224. // }
  225. // }
  226. ]]>
  227. </script>
  228. </button>
  229. <line id="line14" class="line_4" style="x1:1109px; y1:7px; x2:1109px; y2:55px; border-color:#ffe4bb; border-left-style:solid; "/>
  230. <button id="button1" class="icon_search" style="left:927px; top:10px; width:16px; height:16px; ">
  231. <caption/>
  232. <script type="javascript" ev:event="DOMActivate">
  233. <![CDATA[
  234. rszfOpenPopUpListByWndName(ipt_maincustlastsuplplce,"","maincustlastsuplplce,maincustlastsuplplcenm","SPRSD00220","instcd","cmb_instcd");
  235. model.refresh();
  236. ]]>
  237. </script>
  238. </button>
  239. <input id="ipt_maincustlastsuplplcenm" ref="/root/send/gooddelive/maincustlastsuplplcenm" class="input_fix" appearance="input" style="left:945px; top:8px; width:135px; height:19px; ">
  240. <script type="javascript" ev:event="xforms-value-changed">
  241. <![CDATA[
  242. if(ipt_maincustlastsuplplcenm.value.length == 0)
  243. ipt_maincustlastsuplplce.value = "";
  244. else
  245. rszfValidationCheck("TRRSD00221", "reqcustomlist", "instcd,refcond,retrnm",
  246. model.getValue(cmb_instcd.attribute("ref")) +",," + model.getValue(ipt_maincustlastsuplplcenm.attribute("ref")),"","maincustlastsuplplce,maincustlastsuplplcenm" ,
  247. ipt_maincustlastsuplplcenm,"SPRSD00220","instcd","cmb_instcd");
  248. model.refresh();
  249. ]]>
  250. </script>
  251. </input>
  252. <input id="ipt_maincustlastsuplplce" ref="/root/send/gooddelive/maincustlastsuplplce" class="input_search" style="left:844px; top:8px; width:81px; height:19px; ">
  253. <script type="javascript" ev:event="xforms-value-changed">
  254. <![CDATA[
  255. if(ipt_maincustlastsuplplce.value.length == 0)
  256. ipt_maincustlastsuplplcenm.value = "";
  257. else
  258. rszfValidationCheck("TRRSD00221", "reqcustomlist", "instcd,refcond,retrnm",
  259. model.getValue(cmb_instcd.attribute("ref")) +",," + model.getValue(ipt_maincustlastsuplplce.attribute("ref")),"","maincustlastsuplplce,maincustlastsuplplcenm" ,
  260. ipt_maincustlastsuplplce,"SPRSD00220","instcd","cmb_instcd");
  261. model.refresh();
  262. ]]>
  263. </script>
  264. </input>
  265. <select1 id="cmb_instcd" ref="/root/send/gooddelive/instcd" class="combo_s_essential" appearance="minimal" style="left:100px; top:8px; width:155px; height:19px; ">
  266. <choices>
  267. <itemset nodeset="/root/init/instcd">
  268. <label ref="cdnm"/>
  269. <value ref="cdid"/>
  270. </itemset>
  271. </choices>
  272. </select1>
  273. <caption id="caption10" class="search_name" style="left:15px; top:9px; width:101px; height:17px; ">기관코드 :</caption>
  274. <caption id="caption1" class="search_name" style="left:289px; top:9px; width:87px; height:17px; ">출고일자 :</caption>
  275. <caption id="caption2" class="search_name" style="left:745px; top:9px; width:93px; height:17px; ">거 래 처 :</caption>
  276. <caption id="caption23" style="left:492px; top:10px; width:15px; height:20px; font-weight:bold; vertical-align:middle; ">~</caption>
  277. <input id="ipt_delivetodd" ref="/root/send/gooddelive/delivetodd" class="input_s_essential" inputtype="date" style="left:510px; top:10px; width:111px; height:19px; "/>
  278. <input id="ipt_delivefrdd" ref="/root/send/gooddelive/delivefrdd" class="input_s_essential" inputtype="date" style="left:374px; top:8px; width:111px; height:19px; ">
  279. <script type="javascript" ev:event="xforms-value-changed">
  280. <![CDATA[
  281. model.setValue(ipt_genpurcdd.attribute("ref"), model.getValue(ipt_delivefrdd.attribute("ref")).substr(0,6)+"01");
  282. ipt_genpurcdd.refresh();
  283. ]]>
  284. </script>
  285. </input>
  286. <output id="opt_goodflag" ref="/root/send/gooddelive/goodflag" visibility="hidden" style="left:1095px; top:10px; width:10px; height:19px; "/>
  287. <select1 id="cmb_genwinyn" ref="/root/send/gooddelive/genwinyn" class="combo_s_essential" appearance="minimal" style="left:100px; top:35px; width:155px; height:19px; ">
  288. <choices>
  289. <itemset nodeset="/root/init/getwinyn">
  290. <label ref="label"/>
  291. <value ref="value"/>
  292. </itemset>
  293. </choices>
  294. </select1>
  295. <caption id="caption7" class="search_name" style="left:15px; top:36px; width:101px; height:17px; ">정산유무 :</caption>
  296. <caption id="caption8" class="search_name" style="left:290px; top:36px; width:135px; height:17px; ">정산일자 :</caption>
  297. <input id="ipt_genpurcdd" ref="/root/send/gooddelive/genpurcdd" class="input_s_essential" inputtype="date" style="left:374px; top:35px; width:111px; height:19px; font-weight:bold; color:#3366ff; "/>
  298. <caption id="cap_paycond" class="search_name" style="left:505px; top:36px; width:99px; height:17px; ">작업구분 :</caption>
  299. <select1 id="rdo_workflag" ref="/root/init/workflag" overflow="visible" appearance="full" cols="2" style="left:592px; top:36px; width:135px; height:20px; border-style:none; ">
  300. <choices>
  301. <item>
  302. <label>거래처별</label>
  303. <value>1</value>
  304. </item>
  305. <item>
  306. <label>물품별</label>
  307. <value>2</value>
  308. </item>
  309. </choices>
  310. <script type="javascript" ev:event="xforms-value-changed">
  311. <![CDATA[
  312. fGridShowSetting(rdo_workflag.value);
  313. btn_search.dispatch("DOMActivate");
  314. ]]>
  315. </script>
  316. </select1>
  317. <output id="opt_delivedeptcd" ref="/root/send/gooddelive/delivedeptcd" visibility="hidden" style="left:1085px; top:10px; width:10px; height:19px; "/>
  318. <input id="ipt_goodnm" ref="/root/send/gooddelive/goodnm" class="input_search" style="left:945px; top:36px; width:135px; height:19px; ">
  319. <script type="javascript" ev:event="xforms-value-changed">
  320. <![CDATA[
  321. if(ipt_goodnm.value != "")
  322. {
  323. rszfValidationCheck("TRRSD00191", "goodlist" , "refcond,instcd,goodflag,goodnm,nonusegoodview",
  324. "goodnm," + cmb_instcd.value + "," + opt_goodflag.value + "," + ipt_goodnm.value + "," + rdo_nonusegoodview.value ,"","goodcd,goodnm",
  325. ipt_goodcd,"SPRSD00210","instcd,goodflag","cmb_instcd,opt_goodflag");
  326. }else
  327. {
  328. ipt_goodcd.value = "";
  329. ipt_goodnm.value = "";
  330. }
  331. model.refresh();
  332. ]]>
  333. </script>
  334. </input>
  335. <input id="ipt_goodcd" ref="/root/send/gooddelive/goodcd" class="input_search" imemode="disabled" style="left:844px; top:36px; width:81px; height:19px; text-align:center; ">
  336. <script type="javascript" ev:event="xforms-value-changed">
  337. <![CDATA[
  338. if(ipt_goodcd.value != "")
  339. {
  340. rszfValidationCheck("TRRSD00191", "goodlist" , "refcond,instcd,goodflag,goodcd,nonusegoodview",
  341. "goodcd," + cmb_instcd.value + "," + opt_goodflag.value + "," + ipt_goodcd.value + "," + rdo_nonusegoodview.value,"","goodcd,goodnm",
  342. ipt_goodcd,"SPRSD00210","instcd,goodflag","cmb_instcd,opt_goodflag");
  343. }else{
  344. ipt_goodcd.value = "";
  345. ipt_goodnm.value = "";
  346. }
  347. model.refresh();
  348. ]]>
  349. </script>
  350. </input>
  351. <button id="btn_goodSearchs" class="icon_search" style="left:927px; top:36px; width:16px; height:16px; ">
  352. <caption/>
  353. <script type="javascript" ev:event="DOMActivate">
  354. <![CDATA[
  355. // 자산코드 팝업창 오픈
  356. rszfOpenPopUpListByWndName(ipt_goodcd,"","goodcd,goodnm","SPRSD00210","instcd,goodflag,nonusegoodview","cmb_instcd,opt_goodflag,rdo_nonusegoodview");
  357. // rszfOpenPopUpListByWndName(grd_gooddmnd,"","goodcd,goodnm","SPRSD00190","instcd,goodflag,nonusegoodview","cmb_instcd,cmb_goodflag,rdo_nonusegoodview");
  358. model.refresh();
  359. ]]>
  360. </script>
  361. </button>
  362. <caption id="caption5" class="search_name" style="left:745px; top:36px; width:101px; height:17px; ">물품코드 :</caption>
  363. <select1 id="rdo_nonusegoodview" ref="/root/hidden/nonusegoodview" visibility="hidden" appearance="full" cols="2" style="left:1090px; top:36px; width:15px; height:17px; border-style:none; ">
  364. <choices>
  365. <itemset nodeset="/root/init/nonusegoodview">
  366. <label ref="label"/>
  367. <value ref="value"/>
  368. </itemset>
  369. </choices>
  370. </select1>
  371. </group>
  372. <line id="lin_good" class="line_1" style="x1:380px; y1:89px; x2:1195px; y2:89px; "/>
  373. <datagrid id="grd_gooddelive" nodeset="/root/main/list/gooddelive/gooddelivelist" caption="정산^NO^출고일자^물품코드^물품코드^품명^규격^모델^거래처^제조회사^단위^단위^단가^불출수량^불출금액^정산일자^기관^물품구분" colsep="^" colwidth="40, 40, 70, 75, 22, 240, 132, 90, 100, 90, 30, 30, 90, 65, 100, 100, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100, 100" dataheight="25" ellipsis="true" explorerbar="sortshow" mergecellsfixedrows="bycolrec" rowheader="update" rowsep="|" tooltip="true" style="left:380px; top:95px; width:815px; height:645px; ">
  374. <col checkvalue="Y,N" ref="genwin" type="checkbox"/>
  375. <col ref="rownumber" style="text-align:right; "/>
  376. <col ref="delivedd" visibility="hidden" format="yyyy/mm/dd"/>
  377. <col ref="goodcd"/>
  378. <col ref="allsizespecid"/>
  379. <col ref="goodnm"/>
  380. <col ref="goodspec"/>
  381. <col ref="goodmodel"/>
  382. <col ref="maincustlastsuplplcenm" visibility="hidden"/>
  383. <col ref="prodcmpynm"/>
  384. <col ref="deliveunit"/>
  385. <col ref="delivepackunit"/>
  386. <col ref="goodunitcost" format="#,###" style="text-align:right; "/>
  387. <col ref="deliveqty" format="#,###" style="text-align:right; "/>
  388. <col ref="deliveamt" format="#,###" style="text-align:right; "/>
  389. <col ref="purcdmnddd" style="text-align:center; "/>
  390. <col ref="instcd" visibility="hidden"/>
  391. <col ref="goodflag" visibility="hidden"/>
  392. <col ref="delivedeptcd" visibility="hidden"/>
  393. <col ref="goodspecid" visibility="hidden"/>
  394. <col ref="maincustlastsuplplce" visibility="hidden"/>
  395. <col ref="suppcustcd" visibility="hidden"/>
  396. <col ref="delivepackcntperunit" visibility="hidden"/>
  397. <col ref="delivepackcnt" visibility="hidden"/>
  398. <col ref="pregenwin" visibility="hidden"/>
  399. <col ref="purcdmndno" visibility="hidden"/>
  400. <col ref="purcdmndseq" visibility="hidden"/>
  401. <col ref="windd" visibility="hidden"/>
  402. <col ref="winno" visibility="hidden"/>
  403. <col ref="winseqno" visibility="hidden"/>
  404. <col ref="allsizespecid" visibility="hidden"/>
  405. <col ref="reqdeptcd" visibility="hidden"/>
  406. <col ref="windeptcd" visibility="hidden"/>
  407. <script type="javascript" ev:event="xforms-value-changed">
  408. <![CDATA[
  409. if(grd_gooddelive.col == grd_gooddelive.colRef("winqty"))
  410. {
  411. if(model.getValue(grd_gooddelive.nodeset + "[" + (grd_gooddelive.row - grd_gooddelive.fixedRows + 1)+ "]/winqty") != "0")
  412. {
  413. model.setValue(grd_gooddelive.nodeset + "[" + (grd_gooddelive.row - grd_gooddelive.fixedRows + 1)+ "]/genwin","Y");
  414. }
  415. else
  416. {
  417. model.setValue(grd_gooddelive.nodeset + "[" + (grd_gooddelive.row - grd_gooddelive.fixedRows + 1)+ "]/genwin","N");
  418. }
  419. }
  420. ]]>
  421. </script>
  422. <script type="javascript" ev:event="onaftersort">
  423. <![CDATA[
  424. grd_gooddelive.gridToInstance();
  425. ]]>
  426. </script>
  427. </datagrid>
  428. <button id="btn_choices" class="btn2_letter4" style="left:1128px; top:69px; width:64px; height:19px; ">
  429. <caption>Choice</caption>
  430. <script type="javascript" ev:event="DOMActivate">
  431. <![CDATA[
  432. fCheckGrid();
  433. ]]>
  434. </script>
  435. </button>
  436. <button id="btn_excel" class="btn5_letter6" style="left:1039px; top:69px; width:86px; height:19px; ">
  437. <caption>Excel Save</caption>
  438. <script type="javascript" ev:event="DOMActivate">
  439. <![CDATA[
  440. // misfSaveExcel(grd_gooddelive , "수탁물품정산처리");
  441. var fileName = window.fileDialog("save", ",", false, "수탁물품정산처리", "xls", "Excel Files(*.xls)|*.xls|All Files (*.*)|*.*");
  442. if (fileName != "")
  443. {
  444. grd_gooddelive.saveExcel(fileName, "SheetName", true, true, "", "", false);
  445. }
  446. ]]>
  447. </script>
  448. </button>
  449. <caption id="caption3" style="left:863px; top:72px; width:157px; height:15px; ">수불단위와 구매단위가 다름</caption>
  450. <caption id="caption4" class="color_6" style="left:845px; top:70px; width:15px; height:15px; background-color:#FFFF00; "/>
  451. <caption id="cap_custList" class="tit_2" style="left:5px; top:73px; width:157px; height:13px; ">거래처별 내역</caption>
  452. <line id="lin_custList" class="line_1" visibility="visible" style="x1:0px; y1:89px; x2:375px; y2:89px; "/>
  453. <datagrid id="grd_custdelive" nodeset="/root/main/list/custdelive/custdelivelist" caption="보조거래처^보조거래처^수량^금액^거래처^기관^물품구분^출고부서" colsep="^" colwidth="70, 120, 60, 85, 40, 40, 40, 40" dataheight="25" ellipsis="true" explorerbar="sortshow" rowheader="seq" rowsep="|" tooltip="true" style="left:0px; top:95px; width:375px; height:645px; ">
  454. <col ref="suppcustcd"/>
  455. <col ref="suppcustnm"/>
  456. <col ref="deliveqty" format="#,###" style="text-align:right; "/>
  457. <col ref="deliveamt" format="#,###" style="text-align:right; "/>
  458. <col ref="maincustlastsuplplce" visibility="hidden"/>
  459. <col ref="instcd" visibility="hidden"/>
  460. <col ref="goodflag" visibility="hidden"/>
  461. <col ref="delivedeptcd" visibility="hidden"/>
  462. <script type="javascript" ev:event="onaftersort">
  463. <![CDATA[
  464. grd_gooddelive.gridToInstance();
  465. ]]>
  466. </script>
  467. <script type="javascript" ev:event="onrowchanged">
  468. <![CDATA[
  469. if ( grd_custdelive.rows - grd_custdelive.fixedRows > 0 ) {
  470. fDefualtSetting();
  471. model.setValue("/root/send/gooddelivedet/suppcustcd" , grd_custdelive.valueMatrix( grd_custdelive.row, grd_custdelive.colRef("suppcustcd") ) );
  472. submit("TRRSD02301");
  473. grd_custdelive.dispatch("onmouseup");
  474. }
  475. ]]>
  476. </script>
  477. </datagrid>
  478. <button id="bbt_large" class="icon_pre_month" visibility="hidden" style="left:594px; top:72px; width:16px; height:16px; ">
  479. <caption/>
  480. <script type="javascript" ev:event="DOMActivate">
  481. <![CDATA[
  482. bbt_reqdata.dispatch("DOMActivate");
  483. bbt_reqdata.selected = true;
  484. ]]>
  485. </script>
  486. </button>
  487. <button id="bbt_right" class="icon_next_month" visibility="hidden" style="left:612px; top:72px; width:16px; height:16px; ">
  488. <caption/>
  489. <script type="javascript" ev:event="DOMActivate">
  490. <![CDATA[
  491. bbt_reqdata.dispatch("DOMActivate");
  492. bbt_reqdata.selected = true;
  493. ]]>
  494. </script>
  495. </button>
  496. </group>
  497. <group id="group4" scroll="auto" style="left:0px; top:12px; width:1195px; height:27px; ">
  498. <button id="btn_print" class="btn6_letter2" visibility="hidden" style="left:0; top:3px; width:56px; height:22px; ">
  499. <caption>출력</caption>
  500. </button>
  501. <line id="line2" class="line_6" style="x1:0px; y1:25; x2:1195px; y2:25; "/>
  502. <button id="button5" class="btn4_letter3" style="left:1127px; top:3px; width:68px; height:22px; ">
  503. <caption>초기화</caption>
  504. <script type="javascript" ev:event="DOMActivate">
  505. <![CDATA[
  506. fInitialize();
  507. ]]>
  508. </script>
  509. </button>
  510. <button id="btn_save" class="btn4_letter2" style="left:1070px; top:3px; width:56px; height:22px; ">
  511. <caption>저장</caption>
  512. <script type="javascript" ev:event="DOMActivate">
  513. <![CDATA[
  514. if ( fCheckRetrieveData() == false ) return ;
  515. if( getGridUpdateData(grd_gooddelive) == "" )
  516. {
  517. messageBox("생성할 내역이" ,"I004");
  518. return;
  519. }
  520. model.setValue("/root/send/gooddelive/gooddelivelist" ,grd_gooddelive.getUpdateData());
  521. gUserid = getUserInfo("userid"); // 사용자
  522. var vdate = new Date();
  523. var YYYY = vdate.getFullYear();
  524. var MM = vdate.getMonth() + 1; // 1월=0,12월=11이므로 1 더함
  525. var DD = vdate.getDate();
  526. var HH = vdate.getHours();
  527. var MI = vdate.getMinutes();
  528. var SS = vdate.getSeconds();
  529. var TargetFlag = '◎'+gUserid+"_" + YYYY +"" + MM +"" + DD +"" + HH +"" + MI +"" + SS; // 사용자
  530. model.setValue("/root/send/gooddelive/targetflag" , TargetFlag ); // 발주대상을 발취하기위한 KEY
  531. model.setValue("/root/send/gooddelive/userid" , gUserid ); // 사용자
  532. submit("TXRSD02301");
  533. if (model.getValue(gvErrorMsgPath + "/type") != "error") btn_search.dispatch("DOMActivate");
  534. /*
  535. for(cnt = grd_gooddelive.fixedRows; cnt< grd_gooddelive.rows; cnt++) {
  536. if (model.getValue(grd_gooddelive.nodeset + "[" + cnt + "]/deliveunit" ) != model.getValue(grd_gooddelive.nodeset + "[" + cnt + "]/delivepackunit") ) {
  537. if (model.getValue(grd_gooddelive.nodeset+"["+ cnt +"]/genwin" ) == "Y") {
  538. messageBox(cnt + " 번째 물품은 수불단위와 구매단위가 달라 정산처리 " ,"E001");
  539. return false;
  540. }
  541. }
  542. }
  543. */
  544. ]]>
  545. </script>
  546. </button>
  547. </group>
  548. </xhtml:body>
  549. </xhtml:html>