123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436 |
- <?xml version="1.0" encoding="EUC-KR"?>
- <?xml-stylesheet href="../../../com/commonweb/css/common.css" type="text/css" ?>
- <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">
- <xhtml:head>
- <xhtml:title>위탁수탁관리</xhtml:title>
- <model id="model1">
- <instance id="instance1">
- <root xmlns="">
- <main>
- <csmtinfo>
- <csmtinlist>
- <ioflag/>
- <cdnm/>
- <csmtcnt/>
- <remark1/>
- <instcd/>
- <csmtdd/>
- <goodscd/>
- <csmtkgcnt/>
- <csmtflag/>
- </csmtinlist>
- </csmtinfo>
- <cond>
- <csmtdd/>
- <deptcd/>
- <selyymmdd/>
- </cond>
- <csrdeptlist/>
- <csmtoutinfo>
- <csmtoutlist>
- <ioflag/>
- <cdnm/>
- <csmtcnt/>
- <remark1/>
- <instcd/>
- <csmtdd/>
- <goodscd/>
- <csmtkgcnt/>
- <csmtflag/>
- </csmtoutlist>
- </csmtoutinfo>
- <csmtrexinfo/>
- <csmtrexioinfo/>
- </main>
- <send>
- <csmtdd/>
- <report/>
- <ioflag/>
- <ymflag/>
- <selyymmdd/>
- <gubuncd>01</gubuncd>
- <kgqtyflag/>
- <kgqtyflagnm/>
- </send>
- </root>
- </instance>
- <script type="javascript" src="../../../com/commonweb/js/common.js"/>
- <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
- <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
- <script type="javascript" ev:event="xforms-ready">
- <![CDATA[
- fInitialize();
- ]]>
- </script>
- <submission id="TRMNG02601" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main/csmtinfo"/>
- <submission id="TRMNG02602" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main/csmtoutinfo"/>
- <submission id="TXMNG02601" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/savedata" resultref="/root/temp"/>
- <submission id="TXMNG02602" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/savedata" resultref="/root/temp2"/>
- <submission id="TRMNG02603" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main/csmtrexinfo"/>
- <submission id="TRMNG02604" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main/csmtrexioinfo"/>
- </model>
- <script type="javascript">
- <![CDATA[
- // 화면 open시와 초기화 버튼 클릭시 화면 초기화 기능을 수행한다.
- function fInitialize()
- {
- model.setValue(ipt_csmtdd.attribute("ref"), getCurrentDate());
- rdo_selyymmdd.select(0); //디폴트 일별조회
-
- rdo_selyymmdd.refresh();
- ipt_csmtdd.refresh();
-
- fSearch();
-
- }
-
- function fSearch() {
- model.setValue("/root/send/gubuncd", model.getValue(rdo_gubuncd.attribute("ref"))); //마스터코드구분 01:물품마스터02:창고마스터
-
- var reqdd = model.getValue(ipt_csmtdd.attribute("ref"));
- btn_sav.disabled = false;
- btn_outsav.disabled = false;
- if (model.getValue(rdo_selyymmdd.attribute("ref")) == 'MM' ) {
- reqdd = reqdd.substr(0,6) ;
- btn_sav.disabled = true;
- btn_outsav.disabled = true;
- } else if (model.getValue(rdo_selyymmdd.attribute("ref")) == 'YY' ){
- reqdd = reqdd.substr(0,4);
- btn_sav.disabled = true;
- btn_outsav.disabled = true;
- }
-
- model.setValue("/root/send/csmtdd", reqdd );
-
- submit("TRMNG02601");
-
- var ioflag;
- var unityn;
- var exchngamt;
-
- for(var i = grd_csmtinlist.fixedRows; i < grd_csmtinlist.rows; i++) {
- ioflag = grd_csmtinlist.valueMatrix(i, grd_csmtinlist.colRef("ioflag"));
- unityn = grd_csmtinlist.valueMatrix(i, grd_csmtinlist.colRef("unityn"));
- exchngamt = grd_csmtinlist.valueMatrix(i, grd_csmtinlist.colRef("exchngamt"));
-
- if(unityn == "Y") {
- grd_csmtinlist.isReadOnly(i, grd_csmtinlist.colRef("csmtcnt"),i, grd_csmtinlist.colRef("csmtcnt")) = false;
- grd_csmtinlist.isReadOnly(i, grd_csmtinlist.colRef("csmtkgcnt"),i, grd_csmtinlist.colRef("csmtkgcnt")) = true;
- } else {
- grd_csmtinlist.isReadOnly(i, grd_csmtinlist.colRef("csmtkgcnt"),i, grd_csmtinlist.colRef("csmtkgcnt")) = false;
- grd_csmtinlist.isReadOnly(i, grd_csmtinlist.colRef("csmtcnt"),i, grd_csmtinlist.colRef("csmtcnt")) = true;
- }
-
- if(ioflag == "N") {
- grd_csmtinlist.rowStatus(i) = "1";
- }
- }
-
- grd_csmtinlist.mergecol(1)=false;
- grd_csmtinlist.mergecol(2)=false;
- grd_csmtinlist.mergecol(3)=false;
- grd_csmtinlist.mergecol(4)=false;
- grd_csmtinlist.mergecells="bycol";
-
- submit("TRMNG02602");
-
- //var ioflag;
- for(var i = grd_csmtoutlist.fixedRows; i < grd_csmtoutlist.rows; i++) {
- ioflag = grd_csmtoutlist.valueMatrix(i, grd_csmtoutlist.colRef("ioflag"));
-
- if(ioflag == "N") {
- grd_csmtoutlist.rowStatus(i) = "1";
- }
- }
- grd_csmtinlist.subtotalPosition = "below";
- grd_csmtinlist.subtotal("sum", -1, grd_csmtinlist.colRef("csmtcnt") , "#,###", "", grd_csmtinlist.colRef("cdnm"), "합계");
- grd_csmtinlist.subtotal("sum", -1, grd_csmtinlist.colRef("csmtkgcnt") , "#,###.##", "", grd_csmtinlist.colRef("cdnm"), "합계");
-
- grd_csmtoutlist.subtotalPosition = "below";
- grd_csmtoutlist.subtotal("sum", -1, grd_csmtoutlist.colRef("csmtcnt") , "#,###", "", grd_csmtoutlist.colRef("cdnm"), "합계");
- grd_csmtoutlist.subtotal("sum", -1, grd_csmtoutlist.colRef("csmtkgcnt") , "#,###", "", grd_csmtoutlist.colRef("cdnm"), "합계");
- }
-
- function fPrintRex() {
- submit("TRMNG02603");
-
- model.makeNode("/root/send/report/csmtrexinfo");
- copyNodesetType("/root/send/report/csmtrexinfo", "/root/main/csmtrexinfo");
-
- exeReportPreview("RPMNG02600", "XMLSTR", "/root/send/report/csmtrexinfo");
-
- }
-
- function InOutPrintRex(ioflag, ymflag) {
-
- model.setValue("/root/send/ioflag", ioflag);
- model.setValue("/root/send/ymflag", ymflag);
- model.setValue("/root/send/kgqtyflag", "1");
- model.setValue("/root/send/kgqtyflagnm", "Kg");
-
- var reqdd = model.getValue(ipt_csmtdd.attribute("ref"));
-
- if (ymflag == "Y") {
- reqdd = reqdd.substr(0,4);
- } else if (ymflag == "M") {
- reqdd = reqdd.substr(0,6);
- }
-
- model.setValue("/root/send/csmtdd", reqdd);
-
- submit("TRMNG02604");
-
- model.makeNode("/root/send/report/csmtrexioinfo");
-
- copyNodesetType("/root/send/report/csmtrexioinfo", "/root/main/csmtrexioinfo/csmtrexiolist");
-
- model.makeValue("/root/send/report/kgqtyflag", "1");
- model.makeValue("/root/send/report/kgqtyflagnm", "Kg");
-
- exeReportPreview("RPMNG02601", "XMLSTR", "/root/send/report/csmtrexioinfo");
-
- if(ioflag == "IN") {
-
- model.setValue("/root/send/kgqtyflag", "2");
- model.setValue("/root/send/kgqtyflagnm", "장");
-
- submit("TRMNG02604");
-
- model.makeNode("/root/send/report/csmtrexioinfo");
-
- copyNodesetType("/root/send/report/csmtrexioinfo", "/root/main/csmtrexioinfo/csmtrexiolist");
-
- model.makeValue("/root/send/report/kgqtyflag", "2");
- model.makeValue("/root/send/report/kgqtyflagnm", "장");
-
- exeReportPreview("RPMNG02601", "XMLSTR", "/root/send/report/csmtrexioinfo");
- }
- }
- ]]>
- </script>
- </xhtml:head>
- <xhtml:body pagewidth="1100" pageheight="600" guideline="1,1107;2,546;" style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
- <group id="grp_tle" style="left:0px; top:0px; width:1080px; height:13px; ">
- <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:186px; height:14px; ">위탁 수탁 관리</caption>
- </group>
- <group id="grp_biz" scroll="auto" style="left:0px; top:60px; width:540px; height:453px; ">
- <caption id="caption12" class="tit_2" style="left:5px; top:9px; width:121px; height:14px; ">수탁량관리</caption>
- <line id="line1" class="line_1" style="x1:0px; y1:25px; x2:540px; y2:26px; "/>
- <button id="btn_sav" class="btn5_letter2" style="left:495px; top:3px; width:42px; height:19px; ">
- <caption>저장</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- model.makeValue("/root/send/savedata/csmtinlist", getGridUpdateData(grd_csmtinlist) );
-
- //alert(instance1.selectNodesXml("/root/send"));
- submit("TXMNG02601");
-
- fSearch();
- ]]>
- </script>
- </button>
- <datagrid id="grd_csmtinlist" nodeset="/root/main/csmtinfo/csmtinlist" caption="물품코드^품목명^장^Kg^특이사항^기관번호^년월^품목코드^Kg^구분코드^exchngamt^unityn^caption1^망순번" colsep="^" colwidth="0, 150, 65, 65, 225, 74, 100, 65, 76, 100, 100, 100" mergecellsfixedrows="bycolrec" rowheader="update" rowsep="|" style="left:0px; top:29px; width:540px; height:421px; ">
- <col ref="ioflag"/>
- <col ref="cdnm" visibility="visible"/>
- <col ref="csmtcnt" type="input" style="text-align:right; "/>
- <col ref="csmtkgcnt" type="input" visibility="visible" format="#,###.###" style="text-align:right; "/>
- <col ref="remark1" type="input" visibility="visible"/>
- <col ref="instcd" type="input" visibility="hidden"/>
- <col ref="csmtdd" visibility="hidden"/>
- <col ref="goodscd" visibility="hidden"/>
- <col ref="csmtkgcnt" type="hidden" visibility="hidden"/>
- <col ref="csmtflag" visibility="hidden"/>
- <col ref="exchngamt" visibility="hidden"/>
- <col ref="unityn" visibility="hidden"/>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- var remark1 = "";
- if(grd_csmtinlist.col == grd_csmtinlist.colRef("remark1")) {
- remark1 = grd_csmtinlist.valueMatrix(grd_csmtinlist.row, grd_csmtinlist.col);
-
- for(var i = grd_csmtinlist.fixedRows; i < grd_csmtinlist.rows; i++) {
-
- if (grd_csmtinlist.rowStatus(i) == "1" || grd_csmtinlist.rowStatus(i) == "3" ) {
- grd_csmtinlist.rowStatus(i) = "1";
- } else if (grd_csmtinlist.rowStatus(i) == "2" || grd_csmtinlist.rowStatus(i) == "0") {
- grd_csmtinlist.rowStatus(i) = "2";
- }
- grd_csmtinlist.valueMatrix(i, grd_csmtinlist.col) = remark1;
- }
- }
-
- var exchngamt = 0;
- var csmtcnt = 0;
-
- if(grd_csmtinlist.col == grd_csmtinlist.colRef("csmtcnt")) {
- csmtcnt = grd_csmtinlist.valueMatrix(grd_csmtinlist.row, grd_csmtinlist.colRef("csmtcnt"));
- exchngamt = grd_csmtinlist.valueMatrix(grd_csmtinlist.row, grd_csmtinlist.colRef("exchngamt"));
-
- grd_csmtinlist.valueMatrix(grd_csmtinlist.row, grd_csmtinlist.colRef("csmtkgcnt")) = csmtcnt * exchngamt;
-
-
- }
-
- ]]>
- </script>
- <script type="javascript" ev:event="onkeypress">
- <![CDATA[
- var row = grd_csmtinlist.row;
- if(event.keyCode == 13) { // Enter 쳤을 경우 아래 수량으로
- if(grd_csmtinlist.col == grd_csmtinlist.colRef("csmtcnt")) { //불출수량이나 미불출수량 엔터시
- if(grd_csmtinlist.row + 1 < grd_csmtinlist.rows) {
- grd_csmtinlist.row = row + 1;
- }
- }
- }
- ]]>
- </script>
- </datagrid>
- <button id="button2" class="btn2_letter4" style="left:428px; top:3px; width:64px; height:19px; ">
- <caption>월계출력</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- InOutPrintRex("IN","M");
- ]]>
- </script>
- </button>
- <button id="button4" class="btn2_letter4" style="left:361px; top:3px; width:64px; height:19px; ">
- <caption>년계출력</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- InOutPrintRex("IN","Y");
- ]]>
- </script>
- </button>
- <select1 id="rdo_gubuncd" ref="/root/send/gubuncd" disabled="true" visibility="hidden" appearance="full" cols="2" overflow="visible" style="left:140px; top:5px; width:165px; height:15px; border-style:none; ">
- <choices>
- <item>
- <label>물품마스터</label>
- <value>01</value>
- </item>
- <item>
- <label>창고마스터</label>
- <value>02</value>
- </item>
- </choices>
- </select1>
- </group>
- <shape id="roundrect1" class="roundrect_search" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:20px; width:1083px; height:35px; background-color:#fffbf2; border-color:#ffd799; ">.,m</shape>
- <caption id="cap_csrreqdeptcd" class="search_name" style="left:15px; top:30px; width:67px; height:17px; ">일자:</caption>
- <button id="btn_search" class="btn1_letter2" navindex="2" style="left:957px; top:26px; width:56px; height:22px; ">
- <caption>조회</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- fSearch();
- ]]>
- </script>
- </button>
- <input id="ipt_csmtdd" ref="/root/main/cond/csmtdd" class="input_default" inputtype="date" maxlength="6" format="yyyy-mm-dd" style="left:77px; top:28px; width:93px; height:19px; ">
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- fSearch();
- ]]>
- </script>
- </input>
- <line id="line2" class="line_4" style="x1:952px; y1:25px; x2:952px; y2:50px; "/>
- <group id="group1" scroll="auto" style="left:540px; top:60px; width:542px; height:453px; ">
- <caption id="caption1" class="tit_2" style="left:7px; top:6px; width:121px; height:13px; ">위탁량관리</caption>
- <line id="line3" class="line_1" style="x1:0px; y1:24px; x2:538px; y2:24px; "/>
- <button id="btn_outsav" class="btn5_letter2" style="left:496px; top:3px; width:42px; height:19px; ">
- <caption>저장</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- model.makeValue("/root/send/savedata/csmtoutlist", getGridUpdateData(grd_csmtoutlist) );
- submit("TXMNG02602");
-
- fSearch();
- ]]>
- </script>
- </button>
- <datagrid id="grd_csmtoutlist" nodeset="/root/main/csmtoutinfo/csmtoutlist" caption="물품코드^품목명^Kg/장^Kg/장^비고^기관번호^년월^품목코드^구분코드^caption1^망순번" colsep="^" colwidth="0, 150, 65, 66, 289, 100, 65, 76, 100" mergecellsfixedrows="bycolrec" rowheader="update" rowsep="|" style="left:0px; top:29px; width:540px; height:421px; ">
- <col ref="ioflag"/>
- <col ref="cdnm" visibility="visible"/>
- <col ref="csmtkgcnt" type="input" visibility="visible" format="#,###" style="text-align:right; "/>
- <col ref="csmtcnt" type="input" visibility="hidden" format="#,###" style="text-align:right; "/>
- <col ref="remark1" type="input" visibility="visible"/>
- <col ref="instcd" type="input" visibility="hidden"/>
- <col ref="csmtdd" visibility="hidden"/>
- <col ref="goodscd" visibility="hidden"/>
- <col ref="csmtflag" visibility="hidden"/>
- <script type="javascript" ev:event="onkeypress">
- <![CDATA[
- var row = grd_csmtoutlist.row;
- if(event.keyCode == 13) { // Enter 쳤을 경우 아래 수량으로
- if(grd_csmtoutlist.col == grd_csmtoutlist.colRef("csmtcnt")) { //불출수량이나 미불출수량 엔터시
- if(grd_csmtoutlist.row + 1 < grd_csmtoutlist.rows) {
- grd_csmtoutlist.row = row + 1;
- }
- }
- }
- ]]>
- </script>
- </datagrid>
- <button id="button3" class="btn2_letter4" style="left:429px; top:3px; width:64px; height:19px; ">
- <caption>월계출력</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- InOutPrintRex("OUT","M");
- ]]>
- </script>
- </button>
- <button id="button5" class="btn2_letter4" style="left:362px; top:3px; width:64px; height:19px; ">
- <caption>년계출력</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- InOutPrintRex("OUT","Y");
- ]]>
- </script>
- </button>
- </group>
- <button id="btn_prt" class="btn1_letter2" style="left:1015px; top:26px; width:56px; height:22px; ">
- <caption>출력</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
-
- fPrintRex();
- ]]>
- </script>
- </button>
- <caption id="caption2" class="search_name" style="left:180px; top:29px; width:85px; height:17px; ">일자구분:</caption>
- <select1 id="rdo_selyymmdd" ref="/root/main/cond/selyymmdd" appearance="full" cols="3" overflow="visible" style="left:265px; top:29px; width:175px; height:20px; border-style:none; ">
- <choices>
- <item>
- <label>일별</label>
- <value>DD</value>
- </item>
- <item>
- <label>월별</label>
- <value>MM</value>
- </item>
- <item>
- <label>년별</label>
- <value>YY</value>
- </item>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- fSearch();
-
- ]]>
- </script>
- </select1>
- <select1 id="radio1" ref="/root/send/gubuncd" disabled="true" visibility="hidden" appearance="full" cols="2" overflow="visible" style="left:485px; top:30px; width:390px; height:15px; border-style:none; ">
- <choices>
- <item>
- <label>물품마스터</label>
- <value>01</value>
- </item>
- <item>
- <label>창고마스터</label>
- <value>02</value>
- </item>
- </choices>
- </select1>
- </xhtml:body>
- </xhtml:html>
|