123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410 |
- <?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>
- <acntlist>
- <revacntlist/>
- </acntlist>
- <bugtlist>
- <revbugtapplist/>
- </bugtlist>
- <revbgdtlist>
- <revbugtdetaillist/>
- </revbgdtlist>
- <acntprntlist>
- <orgacntprntlist/>
- </acntprntlist>
- </main>
- <send>
- <retrparam>
- <instcd/>
- <acntyy/>
- <deptcd/>
- <depthngnm/>
- <bugtflag>2</bugtflag>
- </retrparam>
- <retrparam2>
- <instcd/>
- <acntyy/>
- <deptcd/>
- <acntcd/>
- <bugtflag/>
- </retrparam2>
- <retrparam3>
- <instcd/>
- <acntyy/>
- <deptcd/>
- <acntcd/>
- <bugtflag/>
- <assgym/>
- </retrparam3>
- <retrparam4>
- <instcd/>
- <mngtcd>bugtdept</mngtcd>
- </retrparam4>
- <appcancelparams>
- <instcd/>
- <acntyy/>
- <deptcd/>
- <bugtflag/>
- <flag/>
- </appcancelparams>
- <revbugtapplist/>
- <revbugtdetaillist/>
- </send>
- <init>
- <code>
- <codelist/>
- </code>
- </init>
- <temp>
- </temp>
- <hidden>
- <updateflag>Y</updateflag>
- <bugtaddflag>N</bugtaddflag>
- </hidden>
- <contextmenu>
- <assgym>
- <item>
- <label>년간</label>
- <value>-</value>
- </item>
- <item>
- <label>3월</label>
- <value>03</value>
- </item>
- <item>
- <label>4월</label>
- <value>04</value>
- </item>
- <item>
- <label>5월</label>
- <value>05</value>
- </item>
- <item>
- <label>6월</label>
- <value>06</value>
- </item>
- <item>
- <label>7월</label>
- <value>07</value>
- </item>
- <item>
- <label>8월</label>
- <value>08</value>
- </item>
- <item>
- <label>9월</label>
- <value>09</value>
- </item>
- <item>
- <label>10월</label>
- <value>10</value>
- </item>
- <item>
- <label>11월</label>
- <value>11</value>
- </item>
- <item>
- <label>12월</label>
- <value>12</value>
- </item>
- <item>
- <label>1월</label>
- <value>01</value>
- </item>
- <item>
- <label>2월</label>
- <value>02</value>
- </item>
- </assgym>
- </contextmenu>
- <source>
- <slipinfo/>
- </source>
- </root>
- </instance>
- <submission id="TRRBQ00301" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/retrparam" resultref="/root/main/acntlist"/>
- <submission id="TRRBQ00302" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/retrparam2" resultref="/root/main/bugtlist"/>
- <submission id="TRRBQ00303" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/retrparam3" resultref="/root/main/revbgdtlist"/>
- <submission id="TXRBQ00301" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/temp"/>
- <submission id="TRRBQ00305" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/retrparam" resultref="/root/main/bugtexcel"/>
- <submission id="TRRAZ00001" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/retrparam4" resultref="/root/init/code"/>
- <submission id="TXRBQ00302" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/temp"/>
- <submission id="TXRBQ00103" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/appcancelparams" resultref="/root/temp"/>
- <submission id="TXRBQ00303" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/retrparam" resultref="/root/temp"/>
- <submission id="TRRBQ00306" mediatype="application/x-www-form-urlencoded" method="get" ref="/root/send/retrparam" replace="instance" resultref="/root/main/acntprntlist"/>
- </model>
- <script type="javascript" src="../../../com/commonweb/js/common.js"/>
- <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
- <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
- <script type="javascript" src="../../../mis/miscommonweb/js/MIS.js"/>
- <script type="javascript" src="../../../mis/miscommonweb/js/RAC001.js"/>
- <script type="javascript" src="../../../mis/bugtcommonweb/js/RBC001.js"/>
- <script type="javascript" src="../../../mis/acntcommonweb/js/RAD001.js"/>
- <script type="javascript" ev:event="xforms-ready">
- <![CDATA[
- fCheckAuth();
- fResetForm();
-
- ]]>
- </script>
- <script type="javascript">
- <![CDATA[
-
- var Instcd = getUserInfo("dutplceinstcd");
- var Deptcd = getUserInfo("dutplcecd");
- var Deptnm = getUserInfo("dutplcenm");
- var Emplno = getUserInfo("userid");
- var DeptAcnt = "";
-
- //========================================================================================
- //화면 권한 체크
- //========================================================================================
- function fCheckAuth()
- {
- btn_search.disabled = !checkAuth("R");
- btn_save.disabled = !checkAuth("X");
- }
- //========================================================================================
- //화면 로드시 초기화 함수
- //========================================================================================
- function fResetForm()
- {
- grd_revbugtlist.rowHeight(0) = 35;
-
- if(radfCheckInstMngt(getUserInfo("dutplceinstcd"), 'condition4') == "Y")
- {
- DeptAcnt = "Y";
- btn_acntaddrow.visible = false;
- }
- else
- {
- DeptAcnt = "N";
- btn_acntaddrow.visible = true;
- }
-
- model.setValue("/root/send/retrparam/instcd", Instcd);
- model.setValue("/root/send/retrparam/deptcd", Deptcd);
- model.setValue("/root/send/retrparam/depthngnm", Deptnm);
- ipt_acntyy.value = rbcfgetAppAcntyy(Instcd);
-
- model.setValue("/root/send/retrparam4/instcd", Instcd);
- submit("TRRAZ00001");
-
- // if(Deptcd == model.getValue("/root/init/code/codelist/cdid"))
- // {
- // ipt_deptcd.disabled = false;
- // btn_depthelp.disabled = false;
- // ipt_depthngnm.disabled = false;
- // }
-
- btn_search.dispatch("DOMActivate");
- }
- //========================================================================================
- //예산 신청 가능 여부 조회 (기간 조회)
- //========================================================================================
-
-
- //========================================================================================
- //부서코드 Help Open
- //========================================================================================
- function fOpenPopupDeptHelp(pControl, pInstance)
- {
- misfOpenPopUpList("11", pControl, "", pInstance);
- model.refresh();
- }
-
- //========================================================================================
- // 예산 조회 및 권한 예외 처리
- //========================================================================================
- function fRetrieve()
- {
- model.removeNodeset(grd_revbugtlist.nodeset);
- model.removeNodeset(grd_revbugtapplist.nodeset);
- model.removeNodeset(grd_revbugtdetaillist.nodeset);
- model.refresh();
-
-
- var bugtsearchyn = "";
- var bugtinputyn = "";
- var bugtreqyn = "";
- var bugtdeptcd = model.getValue("/root/init/code/codelist/cdid");
- var vAppCheck = rbcfgetAppPossibleDeptCheck(getUserInfo("dutplceinstcd"), ipt_acntyy.value, ipt_deptcd.value);
-
- // alert(bugtdeptcd);
-
- var vDeptcd = model.getValue(ipt_deptcd.attribute("ref"));
-
- if(vDeptcd == Deptcd || bugtdeptcd == Deptcd)
- {
- bugtsearchyn = "Y";
- bugtinputyn = "Y";
- bugtreqyn = "Y";
-
- }
- else
- {
- bugtsearchyn = radfCheckBugtAuth(Instcd, Emplno, vDeptcd, 'BUGTSEARCHYN');
- bugtinputyn = radfCheckBugtAuth(Instcd, Emplno, vDeptcd, 'BUGTINPUTYN');
- bugtreqyn = radfCheckBugtAuth(Instcd, Emplno, vDeptcd, 'BUGTREQYN');
- }
-
- if(bugtsearchyn == 'Y') { btn_save.disabled = false;
- btn_app.disabled = false;
- btn_alldel.disabled = false;
- submit("TRRBQ00301");
- if(grd_revbugtlist.valueMatrix(grd_revbugtlist.fixedRows, grd_revbugtlist.colRef("revsupmbugtappyn")) == "Y")
- {
- bugtinputyn = 'N';
- } }
- else { btn_save.disabled = true;
- btn_app.disabled = true;
- btn_alldel.disabled = true;
- return false; };
- if(bugtinputyn == 'Y' && vAppCheck == 'Y')
- { btn_save.disabled = false;
- btn_excelupload.disabled = false;
- btn_acntaddrow.disabled = false;
- btn_addrow.disabled = false;
- btn_delrow.disabled = false;
- btn_detailaddrow.disabled = false;
- btn_detaildelrow.disabled = false; }
- else { btn_save.disabled = true;
- btn_excelupload.disabled = true;
- btn_acntaddrow.disabled = true;
- btn_addrow.disabled = true;
- btn_delrow.disabled = true;
- btn_detailaddrow.disabled = true;
- btn_detaildelrow.disabled = true; };
- if(bugtreqyn == 'Y') { btn_app.disabled = false;
- btn_alldel.disabled = false;
- btn_cancel.disabled = false; }
- else { btn_app.disabled = true;
- btn_alldel.disabled = true;
- btn_cancel.disabled = true; };
-
- fSetRowColor(grd_revbugtlist);
-
-
- }
-
- function fSetRowColor(pGrid)
- {
- var iCnt = 0;
-
- for(var i=0; i<pGrid.rows;i++)
- {
- if(pGrid.valueMatrix(i, pGrid.colRef("acntcd")) == "99999999")
- {
- pGrid.rowStyle(i, "all", "background-color") = "#dddddd";
- }
- else
- {
- pGrid.rowStyle(i, "all", "background-color") = "#ffffff";
- }
- }
-
- pGrid.frozenBottomRows = 1;
- pGrid.backColorFrozen = "#dddddd";
- }
- function fSetGridDefaultValue()
- {
- for(var i=0; i<grd_revbugtapplist.rows; i++)
- {
- if(grd_revbugtapplist.rowStatus(i) == 1)
- {
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("acntyy")) = grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("acntyy"));
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("deptcd")) = grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("deptcd"));
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("acntcd")) = grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("acntcd"));
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("acntnm")) = grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("acntnm4"));
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("bugtcd")) = "01";
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("bugtnm")) = grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("acntnm"));
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("bugtflag")) = grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("bugtflag"));
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("appamt")) = 0;
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("assgym")) = grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("assgym"));
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("projectid")) = grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("projectid"));
- }
- }
- model.refresh();
- }
-
- function fCheckDupData()
- {
- var iInsCnt = 0;
- var iDupCnt = 0;
- var bDel = false;
-
- for(var i=0; i<grd_revbugtapplist.rows; i++)
- {
- if(i == grd_revbugtapplist.row) continue;
-
- if((grd_revbugtapplist.valueMatrix(i, grd_revbugtapplist.colRef("assgym")) == grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("assgym"))))
- {
- messageBox("같은 예산코드에 동일 배정 [년/월]을 지정할 수", "I004");
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("assgym")) = "";
- return;
- }
-
- if(grd_revbugtapplist.valueMatrix(i, grd_revbugtapplist.colRef("assgym")) == "-" && grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("assgym")) != "-")
- {
- messageBox("년간 배정이 있어 월간 배정을 할 수", "I004");
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("assgym")) = "";
- return;
- }
- if(grd_revbugtapplist.valueMatrix(i, grd_revbugtapplist.colRef("assgym")) != "-" && grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("assgym")) == "-")
- {
- messageBox("월간 배정이 있어 년간 배정을 할 수", "I004");
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("assgym")) = "";
- return;
- }
- }
- }
- function fSave()
- {
- if(grd_revbugtapplist.rows == 1) return;
-
- for(var i=0; i<grd_revbugtapplist.rows; i++)
- {
- if(grd_revbugtapplist.valueMatrix(i, grd_revbugtapplist.colRef("assgym")) == "")
- {
- messageBox("배정월에 공백을 삽입할 수", "I004");
- return;
- }
- }
-
- for(var i=1; i<grd_revbugtdetaillist.rows; i++)
- {
- if(grd_revbugtdetaillist.valueMatrix(i, grd_revbugtdetaillist.colRef("appresn")) == "")
- {
- messageBox("산출 내역에 공백을 삽입할 수", "I004");
- return;
- }
- }
-
- var updtdata_bugtapplist = getGridUpdateData(grd_revbugtapplist);
- var updtdata_bugtdetaillist = getGridUpdateData(grd_revbugtdetaillist);
- if(updtdata_bugtapplist == "" && updtdata_bugtdetaillist == "")
- {
- messageBox("변경된 내역이", "I004");
- return;
- }
-
- if(grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("status")) == "1")
- {
- grd_revbugtapplist.rowStatus(grd_revbugtapplist.row) = 1;
- }
-
- if(updtdata_bugtapplist != "")
- {
- vRowStatus = grd_revbugtapplist.rowStatus(grd_revbugtapplist.row);
-
- model.setValue("/root/send/revbugtapplist", grd_revbugtapplist.getUpdateData());
- submit("TXRBQ00301");
-
-
- if(vRowStatus == 4 || vRowStatus == 5 || vRowStatus == 6)
- {
- submit("TRRBQ00302");
- if(grd_revbugtapplist.rows > 1)
- {
- grd_revbugtapplist.row = 1;
- grd_revbugtapplist.dispatch("onrowchanged");
- }
- }
- else
- {
- grd_revbugtapplist.removeStatus(grd_revbugtapplist.row, "insert");
- grd_revbugtapplist.removeStatus(grd_revbugtapplist.row, "update");
- }
- }
-
- model.setValue("/root/send/revbugtdetaillist", grd_revbugtdetaillist.getUpdateData());
- submit("TXRBQ00302");
- grd_revbugtapplist.dispatch("onrowchanged");
-
- model.setValue("/root/hidden/updateflag", "N");
- }
-
- function fSetRevAmt()
- {
- var iSumAppAmt = 0;
- for(var i=1; i<grd_revbugtapplist.rows; i++)
- {
- iSumAppAmt += parseInt(grd_revbugtapplist.valueMatrix(i, grd_revbugtapplist.colRef("revapptotalamt")) == "" ? 0 : grd_revbugtapplist.valueMatrix(i, grd_revbugtapplist.colRef("revapptotalamt")));
- }
-
- grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("bugtappsumamt")) = iSumAppAmt;
- grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("revsupmappamt"))
- = grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("bugtappsumamt")) - grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("orgbugtamt"));
- }
- function fSetRevAmtAppCancel()
- {
- // 본예산에서 변동사항이 없어도 신청할 수 있다.
- // var vSumAmtflag = false;
- //
- // for(var i = grd_revbugtlist.fixedRows ; i < grd_revbugtlist.rows ; i++)
- // {
- // if(grd_revbugtlist.valueMatrix(i, grd_revbugtlist.colRef("revsupmappamt")) != 0)
- // {
- // vSumAmtflag = true;
- // }
- // }
- //
- // if(vSumAmtflag == false)
- // {
- // messageBox("신청할 예산이 없습니다.", "I000");
- // return;
- // }
- //
- // if(grd_revbugtlist.rows == 1) return;
-
- if(ipt_acntyy.value.length != 4 || (ipt_deptcd.value == "" && ipt_depthngnm.value == ""))
- {
- messageBox("회계년도 또는 부서코드가", "I004");
- return;
- }
-
- var sName = document.controls(event.currentTarget).attribute("id");
- var iRet;
- var sYn;
-
- if(sName == "btn_app")
- {
- if(grd_revbugtlist.valueMatrix(1, grd_revbugtlist.colRef("revsupmbugtappyn")) == "Y")
- {
- messageBox("이미 신청된 예산", "E008");
- return;
- }
- iRet = messageBox("추경예산 신청 하시겠습니까", "Q999");
- }
- else if(sName == "btn_cancel")
- {
- if(grd_revbugtlist.valueMatrix(1, grd_revbugtlist.colRef("revsupmbugtappyn")) == "N")
- {
- messageBox("신청되지 않은 예산", "E008");
- return;
- }
- iRet = messageBox("추경예산 신청 취소 하시겠습니까", "Q999");
- }
- if(iRet == 6)
- {
- if(sName == "btn_app")
- {
- model.setValue("/root/send/appcancelparams/flag", "revapp");
- sYn = "Y";
- }
- else if(sName == "btn_cancel")
- {
- model.setValue("/root/send/appcancelparams/flag", "revcancel");
- sYn = "N";
- }
-
- model.setValue("/root/send/appcancelparams/instcd", model.getValue("/root/send/retrparam/instcd"));
- model.setValue("/root/send/appcancelparams/acntyy", model.getValue("/root/send/retrparam/acntyy"));
- model.setValue("/root/send/appcancelparams/deptcd", model.getValue("/root/send/retrparam/deptcd"));
- model.setValue("/root/send/appcancelparams/bugtflag", model.getValue("/root/send/retrparam/bugtflag"));
-
- if(submit("TXRBQ00103"))
- {
- for(var i=1; i<grd_revbugtlist.rows; i++)
- {
- grd_revbugtlist.valueMatrix(i, grd_revbugtlist.colRef("revsupmbugtappyn")) = sYn;
- }
- }
- }
- btn_search.dispatch("DOMActivate");
- }
-
- function fSetDetailListOrgAmt()
- {
- var iSumAppAmt = 0;
- var iSumTotAmt = 0;
- for(var i=1; i<grd_revbugtdetaillist.rows; i++)
- {
- if(grd_revbugtdetaillist.rowStatus(i) != 4 && grd_revbugtdetaillist.rowStatus(i) != 5 && grd_revbugtdetaillist.rowStatus(i) != 6)
- {
- var sAppAmt = (grd_revbugtdetaillist.valueMatrix(i, grd_revbugtdetaillist.colRef("appamt")) == "") ? 0 : grd_revbugtdetaillist.valueMatrix(i, grd_revbugtdetaillist.colRef("appamt"));
- iSumAppAmt += parseInt(sAppAmt);
-
- var sTotAmt = (grd_revbugtdetaillist.valueMatrix(i, grd_revbugtdetaillist.colRef("sumamt")) == "") ? 0 : grd_revbugtdetaillist.valueMatrix(i, grd_revbugtdetaillist.colRef("sumamt"));
- iSumTotAmt += parseInt(sTotAmt);
- }
- }
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("revsupmbugtappamt")) = iSumAppAmt;
-
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("revapptotalamt")) = iSumTotAmt;
-
- if(grd_revbugtapplist.rowStatus(grd_revbugtapplist.row) != 1 && grd_revbugtapplist.rowStatus(grd_revbugtapplist.row) != 3)
- {
- grd_revbugtapplist.addStatus(grd_revbugtapplist.row, "update");
- }
- }
-
-
-
- //====================================
- // 추경예산 산출내역 변동사항을 체크한다.
- //====================================
- function fRevbugtdetaillistChangeCheck()
- {
- var ChangeCheck = true;
- for(var i = grd_revbugtdetaillist.fixedRows ; i < grd_revbugtdetaillist.rows ; i++)
- {
- if(grd_revbugtdetaillist.rowStatus(i) != 0)
- {
- ChangeCheck = false;
- break;
- }
- }
- return ChangeCheck;
- }
-
- //======================================================
- // 2011.07.26 CYW 출력기능추가
- //======================================================
- function fPrint()
- {
- model.removeNodeset("/root/main/acntprntlist/orgacntprntlist");
- if( submit("TRRBQ00306") ){
- exeReportPreview("RPRBQ00300", "XMLSTR");
- model.refresh();
- }
- }
-
- ]]>
- </script>
- </xhtml:head>
- <xhtml:body pagewidth="1211" pageheight="784" guideline="1,1194;" style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
- <group id="group1" style="left:0px; top:0px; width:1195px; height:13px; ">
- <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:230px; height:14px; ">추경예산 신청</caption>
- <caption id="caption4" class="patient_text_black" style="left:922px; top:0px; width:272px; "/>
- </group>
- <group id="group5" scroll="auto" style="left:0px; top:13; width:1195px; height:27px; ">
- <line id="line7" class="line_6" style="x1:0px; y1:25px; x2:1194px; y2:25px; "/>
- <button id="btn_excelupload" class="btn4_letter4" visibility="visible" style="left:990px; top:3px; width:80px; height:22px; ">
- <caption>엑셀저장</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
-
- model.makeValue("/root/source/slipinfo/acntyy", model.getValue(ipt_acntyy.attribute("ref")));
- model.makeValue("/root/source/slipinfo/deptcd", model.getValue(ipt_deptcd.attribute("ref")));
- model.makeValue("/root/source/slipinfo/depthngnm", model.getValue(ipt_depthngnm.attribute("ref")));
- model.makeValue("/root/source/slipinfo/workflag", "2");
-
- modal("SMRBQ00500","","","","","/root/source", "/root/target");
-
- btn_search.dispatch("DOMActivate");
- ]]>
- </script>
- </button>
- <button id="btn_cancel" class="btn4_letter4" visibility="hidden" style="left:820px; top:3px; width:80px; height:22px; ">
- <caption>신청취소</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- fSetRevAmtAppCancel();
- ]]>
- </script>
- </button>
- <button id="btn_alldel" class="btn4_letter4" visibility="visible" style="left:905px; top:3px; width:80px; height:22px; ">
- <caption>전체삭제</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
-
- if(grd_revbugtlist.valueMatrix(1, grd_revbugtlist.colRef("revsupmbugtappyn")) == "Y")
- {
- messageBox("이미 신청된 예산", "E008");
- return;
- }
-
- if (messageBox("추경 [" + rdo_bugtflag.label + "] 전체 내역을", "Q001") == "6")
- {
- submit("TXRBQ00303");
- btn_search.dispatch("DOMActivate");
- }
- ]]>
- </script>
- </button>
- <button id="btn_save" class="btn4_letter2" disabled="true" style="left:1075px; top:3px; width:56px; height:22px; ">
- <caption>저장</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
-
- fSave();
-
- misfSetReadOnlyCol(grd_revbugtapplist, "acntcd,acntnm,assgym", true);
-
- fSetRevAmt()
- if(model.getValue("/root/hidden/bugtaddflag") == "Y")
- {
- btn_search.dispatch("DOMActivate");
- model.setValue("/root/hidden/bugtaddflag", "N");
- }
-
-
-
- ]]>
- </script>
- </button>
- <button id="btn_app" class="btn4_letter2" disabled="true" style="left:1135px; top:3px; width:56px; height:22px; ">
- <caption>신청</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
-
- fSetRevAmtAppCancel();
- ]]>
- </script>
- </button>
- </group>
- <group id="group2" scroll="auto" style="left:0px; top:40; width:1195px; height:744px; ">
- <group id="group4" style="left:0px; top:10px; width:1194; height:35px; vertical-align:top; ">
- <shape id="roundrect2" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:0px; width:1194; height:35px; background-color:#fffbf2; border-color:#ffd799; "/>
- <caption id="caption7" class="search_name" style="left:16px; top:9px; width:86px; height:17px; ">예산년도 :</caption>
- <caption id="caption8" class="search_name" style="left:286px; top:9px; width:107px; height:17px; ">부서 :</caption>
- <line id="line4" class="line_4" style="x1:1107px; y1:8px; x2:1107px; y2:30px; border-color:#ffe4bb; border-left-style:solid; "/>
- <input id="ipt_depthngnm" ref="/root/send/retrparam/depthngnm" class="input_s_essential" navindex="3" imemode="hangul" style="left:455px; top:8px; width:150px; height:19px; ">
- <script type="javascript" ev:event="onkeypress">
- <![CDATA[
-
- if(event.keyCode == 13)
- {
- racfDeptValidCheck("deptcd,depthngnm", "name");
- if(ipt_deptcd.value != "" &&ipt_depthngnm.value != "")
- {
- btn_search.dispatch("DOMActivate");
- }
- }
-
- ]]>
- </script>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
-
- racfDeptValidCheck("deptcd,depthngnm", "name");
-
- if(ipt_deptcd.value != "" &&ipt_depthngnm.value != "")
- {
- btn_search.dispatch("DOMActivate");
- }
- ]]>
- </script>
- </input>
- <button id="btn_depthelp" class="icon_search" style="left:434px; top:8px; width:16px; height:16px; ">
- <caption/>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- fOpenPopupDeptHelp(ipt_deptcd, "deptcd,depthngnm");
-
- if(ipt_deptcd.value != "" &&ipt_depthngnm.value != "")
- {
- btn_search.dispatch("DOMActivate");
- }
- ]]>
- </script>
- </button>
- <input id="ipt_deptcd" ref="/root/send/retrparam/deptcd" class="input_s_essential" navindex="2" maxlength="10" style="left:350px; top:8px; width:80px; height:19px; ">
- <script type="javascript" ev:event="onkeypress">
- <![CDATA[
-
- if(event.keyCode == 13)
- {
- racfDeptValidCheck("deptcd,depthngnm", "code");
- if(ipt_deptcd.value != "" &&ipt_depthngnm.value != "")
- {
- btn_search.dispatch("DOMActivate");
- }
- }
- ]]>
- </script>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- racfDeptValidCheck("deptcd,depthngnm", "code");
- if(ipt_deptcd.value != "" &&ipt_depthngnm.value != "")
- {
- btn_search.dispatch("DOMActivate");
- }
- ]]>
- </script>
- </input>
- <button id="btn_search" class="btn1_letter2" navindex="4" style="left:1124px; top:7px; width:56px; height:22px; text-align:left; ">
- <caption>조회</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
-
- if(ipt_deptcd.value == "")
- {
- messageBox("부서를 선택하세요", "I000");
- return;
- }
-
- if(ipt_deptcd.value == "")
- {
- messageBox("예산년도를 입력하세요", "I000");
- return;
- }
-
- fRetrieve();
- ]]>
- </script>
- </button>
- <caption id="caption5" class="search_name" style="left:655px; top:9px; width:87px; height:17px; ">예산구분 :</caption>
- <select1 id="rdo_bugtflag" ref="/root/send/retrparam/bugtflag" navindex="27" appearance="full" cellspacing="20" cols="4" overflow="visible" style="left:744px; top:9px; width:301px; height:20px; border-style:none; ">
- <choices>
- <item>
- <label>수입</label>
- <value>1</value>
- </item>
- <item>
- <label>비용</label>
- <value>2</value>
- </item>
- <item>
- <label>구매</label>
- <value>3</value>
- </item>
- <item>
- <label>자본</label>
- <value>4</value>
- </item>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- btn_search.dispatch("DOMActivate");
- ]]>
- </script>
- </select1>
- <button id="button5" class="icon_next" navindex="-1" style="left:195px; top:9px; width:13px; height:15px; ">
- <caption/>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- var vYYYY = model.getValue(ipt_acntyy.attribute("ref"));
- var vNum = parseInt(vYYYY, 10);
-
- if (vNum != 1)
- {
- vNum++;
- }
- else
- {
- return;
- }
- model.setValue(ipt_acntyy.attribute("ref"), vNum);
- ipt_acntyy.refresh();
-
- fRetrieve();
- ]]>
- </script>
- </button>
- <input id="ipt_acntyy" ref="/root/send/retrparam/acntyy" class="input_s_essential" navindex="1" maxlength="4" style="left:125px; top:8px; width:68px; height:19px; text-align:center; ">
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- fRetrieve();
- ]]>
- </script>
- </input>
- <button id="btn_pre" class="icon_pre" navindex="-1" style="left:110px; top:9px; width:13px; height:15px; ">
- <caption/>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- var vYYYY = model.getValue(ipt_acntyy.attribute("ref"));
- var vNum = parseInt(vYYYY, 10);
-
- if (vNum != 1)
- {
- vNum--;
- }
- else
- {
- return;
- }
- model.setValue(ipt_acntyy.attribute("ref"), vNum);
- ipt_acntyy.refresh();
-
- fRetrieve();
- ]]>
- </script>
- </button>
- </group>
- <caption id="caption10" class="tit_2" style="left:5px; top:414px; width:126px; height:13px; ">추경예산 신청현황</caption>
- <datagrid id="grd_revbugtapplist" nodeset="/root/main/bugtlist/revbugtapplist" caption="기관코드^회계년도^부서코드^항 계정코드^항^목 계정코드^목^계정과목^계정명^예산구분^배정월^본예산액 (A)^추경신청액^증감액^적요^계산근거^삭제가능여부^UID상태" colsep="^" colwidth="0, 0, 0, 0, 0, 0, 0, 90, 190, 0, 55, 100, 100, 0, 0, 0, 0, 0" ellipsis="true" mergecellsfixedrows="bycolrec" rowheader="update" rowheight="23" rowsep="|" tooltip="true" style="left:0px; top:434px; width:585px; height:304px; ">
- <col ref="instcd" visibility="hidden"/>
- <col ref="acntyy" visibility="hidden"/>
- <col ref="deptcd" visibility="hidden"/>
- <col ref="supacntcd3" visibility="hidden"/>
- <col ref="supacntnm3" visibility="hidden"/>
- <col ref="supacntcd4" visibility="hidden"/>
- <col ref="supacntnm4" visibility="hidden"/>
- <col editable="false" ref="acntcd" type="inputbutton"/>
- <col ref="acntnm"/>
- <col ref="bugtflag" type="combo" style="text-align:center; ">
- <choices>
- <item>
- <label>수입</label>
- <value>1</value>
- </item>
- <item>
- <label>비용</label>
- <value>2</value>
- </item>
- <item>
- <label>구매</label>
- <value>3</value>
- </item>
- <item>
- <label>자본</label>
- <value>4</value>
- </item>
- </choices>
- </col>
- <col ref="assgym" type="combo" style="text-align:center; ">
- <choices>
- <itemset nodeset="/root/contextmenu/assgym/item">
- <label ref="label"/>
- <value ref="value"/>
- </itemset>
- </choices>
- </col>
- <col ref="orgbugtamt" format="(-)#,###" style="text-align:right; "/>
- <col ref="revapptotalamt" format="(-)#,###" style="text-align:right; "/>
- <col ref="revsupmbugtappamt" format="(-)#,###" style="text-align:right; "/>
- <col ref="mainrec" type="input" visibility="hidden"/>
- <col ref="calcbase" type="input" visibility="hidden"/>
- <col ref="delflag" type="input"/>
- <col ref="status" type="input"/>
- <script type="javascript" ev:event="onbuttonclick">
- <![CDATA[
- if(grd_revbugtapplist.col == grd_revbugtapplist.colRef("acntcd"))
- {
- misfOpenPopUpList("10", grd_revbugtapplist, "", "supacntcd3,supacntnm3,supacntcd4,supacntnm4,acntcd,acntnm", rdo_bugtflag.value, "bugtflag");
- model.refresh();
- }
- ]]>
- </script>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- if(grd_revbugtapplist.col == grd_revbugtapplist.colRef("acntcd"))
- {
- var Vacntcd = grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("acntcd"));
-
- for(var i = grd_revbugtdetaillist.fixedRows ; i < grd_revbugtdetaillist.rows ; i++)
- {
- grd_revbugtdetaillist.valueMatrix(i, grd_revbugtdetaillist.colRef("acntcd")) = Vacntcd;
- grd_revbugtdetaillist.addStatus(i, "update");
- }
- }
- else if(grd_revbugtapplist.col == grd_revbugtapplist.colRef("assgym"))
- {
- fCheckDupData();
-
- var Vassgym = grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("assgym"));
-
- for(var i = grd_revbugtdetaillist.fixedRows ; i < grd_revbugtdetaillist.rows ; i++)
- {
- grd_revbugtdetaillist.valueMatrix(i, grd_revbugtdetaillist.colRef("assgym")) = Vassgym;
- grd_revbugtdetaillist.addStatus(i, "update");
- }
- }
-
- ]]>
- </script>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
-
- if(grd_revbugtapplist.row == 0)
- {
- grd_revbugtlist.dispatch("onrowchanged");
- }
-
- ]]>
- </script>
- <script type="javascript" ev:event="onrowchanged">
- <![CDATA[
-
- if(model.getValue("/root/hidden/updateflag") == "Y")
- {
- grd_revbugtlist.dispatch("onrowchanged");
- return;
- }
-
- model.removeNodeset("/root/main/orgbgdtlist/orgbugtdetaillist");
- model.setValue("/root/send/retrparam3/instcd", grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("instcd")) );
- model.setValue("/root/send/retrparam3/acntyy", grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("acntyy")) );
- model.setValue("/root/send/retrparam3/deptcd", grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("deptcd")) );
- model.setValue("/root/send/retrparam3/acntcd", grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("acntcd")) );
- model.setValue("/root/send/retrparam3/assgym", grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("assgym")) );
- model.setValue("/root/send/retrparam3/bugtflag", grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("bugtflag")) );
- submit("TRRBQ00303");
- if(grd_revbugtlist.valueMatrix(grd_revbugtlist.fixedRows, grd_revbugtlist.colRef("orgbugtappyn")) == "Y")
- {
- // misfSetReadOnlyCol(grd_revbugtdetaillist, "appresn,appbase,sumamt", true);
- }
- else
- {
- //cyw misfSetReadOnlyCol(grd_revbugtdetaillist, "appresn", true);
- }
-
- for(var i=1; i<grd_revbugtdetaillist.rows; i++)
- {
- if(grd_revbugtdetaillist.valueMatrix(i, grd_revbugtdetaillist.colRef("status")) == "1")
- {
- grd_revbugtdetaillist.rowStatus(i) = 1;
- }
- else if(grd_revbugtdetaillist.valueMatrix(i, grd_revbugtdetaillist.colRef("status")) == "0")
- {
- grd_revbugtdetaillist.rowStatus(i) = 0;
- }
- }
-
- grd_revbugtapplist.dispatch("onmouseup");
-
- ]]>
- </script>
- </datagrid>
- <line id="line9" class="line_1" style="x1:0px; y1:70; x2:1194px; y2:70; "/>
- <caption id="caption11" class="tit_2" style="left:5px; top:55px; width:117px; height:14px; ">추경예산 신청</caption>
- <line id="line10" class="line_1" style="x1:0px; y1:431px; x2:1195px; y2:430px; "/>
- <datagrid id="grd_revbugtlist" nodeset="/root/main/acntlist/revacntlist" caption="기관코드^회계년도^부서코드^예산구분^관^항^목^계정과목^계정^본예산 (A)^실적 (B)^집행율 (B/A)^추경후예산액 (C)^추경예산^추경조정^증감액(신청-조정)^증감액(C-A)^가용액^추산액^조정예산^이월조정예산^계정대체^예산신청여부" colsep="^" colwidth="0, 0, 0, 0, 120, 120, 150, 0, 230, 105, 105, 105, 105, 0, 0, 0, 105, 0, 0, 105, 105, 105, 0" mergecells="byrestriccol" rowheader="seq" rowheight="23" rowsep="|" tooltip="true" style="left:0px; top:75px; width:1195px; height:322px; ">
- <col ref="instcd" visibility="hidden"/>
- <col ref="acntyy" visibility="hidden"/>
- <col ref="deptcd" visibility="hidden"/>
- <col ref="bugtflag" visibility="hidden"/>
- <col ref="supacntnm2"/>
- <col ref="supacntnm3"/>
- <col ref="supacntnm4"/>
- <col ref="acntcd" visibility="hidden"/>
- <col ref="acntnm"/>
- <col ref="orgbugtamt" format="(-)#,###" style="text-align:right; "/>
- <col ref="bugtexecamt" format="(-)#,###" style="text-align:right; "/>
- <col ref="exerate" format="#.#%" style="left:599px; top:23px; width:110px; height:23px; text-align:right; "/>
- <col ref="bugtappsumamt" format="(-)#,###" style="text-align:right; "/>
- <col ref="bugtsumamt" format="(-)#,###" style="text-align:right; "/>
- <col ref="revsupmadjtamt" format="(-)#,###" style="text-align:right; "/>
- <col ref="bugtupdownamt" format="(-)#,###" style="text-align:right; "/>
- <col ref="revsupmappamt" format="(-)#,###" style="text-align:right; "/>
- <col ref="availableamt" format="(-)#,###" style="text-align:right; "/>
- <col ref="bugtexpcamt" format="(-)#,###" style="text-align:right; "/>
- <col ref="cntramt" format="(-)#,###" style="text-align:right; "/>
- <col ref="transamt" format="(-)#,###" style="text-align:right; "/>
- <col ref="interchangeamt" format="(-)#,###" style="text-align:right; "/>
- <col ref="revsupmbugtappyn" visibility="hidden"/>
- <script type="javascript" ev:event="onrowchanged">
- <![CDATA[
- model.removeNodeset(grd_revbugtapplist.nodeset);
- model.removeNodeset(grd_revbugtdetaillist.nodeset);
- model.setValue("/root/send/retrparam2/instcd", grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("instcd")) );
- model.setValue("/root/send/retrparam2/acntyy", grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("acntyy")) );
- model.setValue("/root/send/retrparam2/deptcd", grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("deptcd")) );
- model.setValue("/root/send/retrparam2/acntcd", grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("acntcd")) );
- model.setValue("/root/send/retrparam2/bugtflag", grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("bugtflag")) );
-
- submit("TRRBQ00302");
-
- model.setValue("/root/hidden/updateflag", "N");
-
- misfSetReadOnlyCol(grd_revbugtapplist, "acntcd,acntnm,assgym", true);
-
- if(grd_revbugtapplist.rows > 1)
- {
- grd_revbugtapplist.row = 1;
- grd_revbugtapplist.dispatch("onrowchanged");
- }
-
- if(DeptAcnt == "Y")
- {
- var vDeptAcnt = grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("deptacnt"));
- if(vDeptAcnt == "Y")
- {
- btn_addrow.disabled = false;
- }
- else
- {
- btn_addrow.disabled = true;
- }
- }
-
- grd_revbugtlist.dispatch("onmouseup");
- ]]>
- </script>
- </datagrid>
- <button id="btn_excel" class="btn2_letter4" style="left:1080px; top:49px; width:64px; height:19px; ">
- <caption>엑셀저장</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
-
- misfSaveExcel(grd_revbugtlist);
-
- ]]>
- </script>
- </button>
- <button id="btn_delrow" class="btn2_letter3" style="left:530px; top:409px; width:53px; height:19px; ">
- <caption>행삭제</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
-
- if(grd_revbugtapplist.valueMatrix(1, grd_revbugtapplist.colRef("delflag")) == "N")
- {
- messageBox("본예산 신청내역은 삭제 할 수", "I004");
- return;
- }
-
- if(grd_revbugtlist.valueMatrix(1, grd_revbugtlist.colRef("revsupmbugtappyn")) == "Y")
- {
- messageBox("신청된 예산이므로 추가 또는 삭제를 할 수", "I004");
- return;
- }
-
- for(var i = 1 ; i < grd_revbugtapplist.rows ; i++)
- {
- grd_revbugtapplist.select(i, grd_revbugtapplist.colRef("acntcd"), i, grd_revbugtapplist.colRef("mainrec")) = false;
- }
-
- var iRowStatus = grd_revbugtapplist.rowStatus(grd_revbugtapplist.row);
-
- if (iRowStatus == 4 || iRowStatus == 5 || iRowStatus == 6) //delete
- {
- grd_revbugtapplist.removeStatus(grd_revbugtapplist.row, "delete");
-
- for(var i=1; i<grd_revbugtdetaillist.rows; i++)
- {
- grd_revbugtdetaillist.removeStatus(i, "delete");
- }
- }
- else if(iRowStatus == 1 || iRowStatus == 3) //insert
- {
- grd_revbugtapplist.deleteRow(grd_revbugtapplist.row, false);
- grd_revbugtlist.dispatch("onrowchanged");
- }
- else if(iRowStatus == 0 || iRowStatus == 2) //update
- {
- grd_revbugtapplist.addStatus(grd_revbugtapplist.row,"delete");
-
- for(var i=1; i<grd_revbugtdetaillist.rows; i++)
- {
- grd_revbugtdetaillist.addStatus(i, "delete");
- }
- }
-
- fSetRevAmt();
- ]]>
- </script>
- </button>
- <button id="btn_addrow" class="btn2_letter3" style="left:475px; top:409px; width:53px; height:19px; ">
- <caption>행추가</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
-
- if(model.getValue("/root/hidden/updateflag") == "Y")
- {
- grd_revbugtlist.dispatch("onrowchanged");
- }
-
- if(grd_revbugtlist.row >= grd_revbugtlist.fixedRows)
- {
- if(grd_revbugtapplist.rows == grd_revbugtapplist.fixedRows + 1)
- {
- if(grd_revbugtapplist.valueMatrix(grd_revbugtapplist.fixedRows, grd_revbugtapplist.colRef("assgym")) == "-")
- {
- messageBox("년간 배정이 있어 추가 배정이 불가능 합니다.", "I000");
- return false;
- }
- }
-
- if(grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("acntcd")) == "99999999") return;
-
- if(grd_revbugtlist.valueMatrix(grd_revbugtlist.fixedRows, grd_revbugtlist.colRef("revsupmbugtappyn")) == "Y")
- {
- messageBox("신청된 예산이므로 추가 또는 삭제를 할 수", "I004");
- return;
- }
-
-
- model.removeNodeset(grd_revbugtdetaillist.nodeset);
- misfGridIUD(grd_revbugtapplist, "A");
- misfSetReadOnlyCol(grd_revbugtapplist, "acntcd,acntnm,assgym", false, grd_revbugtapplist.row);
-
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("instcd")) = grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("instcd"));
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("acntyy")) = grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("acntyy"));
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("deptcd")) = grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("deptcd"));
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("acntcd")) = grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("acntcd"));
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("acntnm")) = grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("acntnm"));
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("bugtflag")) = grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("bugtflag"));
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("mainrec")) = grd_revbugtlist.valueMatrix(grd_revbugtlist.row, grd_revbugtlist.colRef("acntnm"));
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("orgbugtamt")) = 0;
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("revapptotalamt")) = 0;
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("revsupmbugtappamt")) = 0;
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("status")) = 1;
- model.setValue("/root/hidden/updateflag", "Y");
-
- if(grd_revbugtapplist.rows == grd_revbugtapplist.fixedRows + 1) grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("assgym")) = "-";
- model.refresh();
- }
-
- ]]>
- </script>
- </button>
- <datagrid id="grd_revbugtdetaillist" nodeset="/root/main/revbgdtlist/revbugtdetaillist" autoresize="false" caption="기관코드^회계년도^부서코드^계정코드^예산구분^배정월^산출내역^본예산액^추경근거^본추경차액(입력값)^추경신청액^삭제가능여부^입력상태" colsep="^" colwidth="0, 0, 0, 0, 0, 0, 180, 100, 170, 0, 100, 0, 0" ellipsis="true" mergecellsfixedrows="bycolrec" rowheader="update" rowheight="23" rowsep="|" tooltip="true" style="left:589px; top:434px; width:605px; height:304px; ">
- <col ref="instcd" visibility="hidden"/>
- <col ref="acntyy" visibility="hidden"/>
- <col ref="deptcd" visibility="hidden"/>
- <col ref="acntcd" visibility="hidden"/>
- <col ref="bugtflag" visibility="hidden" style="text-align:center; "/>
- <col ref="assgym" visibility="hidden" style="text-align:center; "/>
- <col ref="appresn" type="input"/>
- <col ref="orgappamt" format="(-)#,###" style="text-align:right; "/>
- <col ref="appbase" type="input" style="text-align:left; "/>
- <col ref="appamt" format="(-)#,###" style="text-align:right; "/>
- <col ref="sumamt" type="input" format="(-)#,###" style="text-align:right; "/>
- <col ref="delflag"/>
- <col ref="status"/>
- <script type="javascript" ev:event="onendedit">
- <![CDATA[
-
- var vCol = grd_revbugtdetaillist.col;
- var vRow = grd_revbugtdetaillist.row;
- var iInsCnt = 0;
- var iDupCnt = 0;
- var bDel = false;
-
- if(vCol == grd_revbugtdetaillist.colRef("appresn"))
- {
- for(var i=0; i<grd_revbugtdetaillist.rows; i++)
- {
- if(i == grd_revbugtdetaillist.row) continue;
-
- if(grd_revbugtdetaillist.valueMatrix(i, grd_revbugtdetaillist.colRef("appresn")) == grd_revbugtdetaillist.valueMatrix(grd_revbugtdetaillist.row, grd_revbugtdetaillist.colRef("appresn")))
- {
- messageBox("신청 내역이 있습니다. 신청 내역을 수정하세요.", "I999");
- grd_revbugtdetaillist.valueMatrix(grd_revbugtdetaillist.row, grd_revbugtdetaillist.colRef("appresn")) = "";
- return false;
- }
- }
- }
-
-
-
- if(vCol == grd_revbugtdetaillist.colRef("sumamt"))
- {
- if(grd_revbugtdetaillist.valueMatrix(grd_revbugtdetaillist.row, grd_revbugtdetaillist.colRef("sumamt")) == ""){grd_revbugtdetaillist.valueMatrix(grd_revbugtdetaillist.row, grd_revbugtdetaillist.colRef("sumamt")) = "0"};
- grd_revbugtdetaillist.valueMatrix(vRow, grd_revbugtdetaillist.colRef("appamt")) =
- parseInt(grd_revbugtdetaillist.valueMatrix(vRow, grd_revbugtdetaillist.colRef("sumamt"))) - parseInt(grd_revbugtdetaillist.valueMatrix(vRow, grd_revbugtdetaillist.colRef("orgappamt")));
-
- fSetDetailListOrgAmt();
-
- model.setValue("/root/hidden/updateflag", "Y");
- }
-
- model.refresh();
- ]]>
- </script>
- </datagrid>
- <button id="btn_detaildelrow" class="btn2_letter3" style="left:1140px; top:409px; width:53px; height:19px; ">
- <caption>행삭제</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
-
- if(grd_revbugtdetaillist.valueMatrix(grd_revbugtdetaillist.row, grd_revbugtdetaillist.colRef("delflag")) == "N")
- {
- messageBox("본예산 신청내역은 삭제 할 수", "I004");
- return;
- }
- if(grd_revbugtlist.valueMatrix(1, grd_revbugtlist.colRef("revsupmbugtappyn")) == "Y")
- {
- messageBox("신청된 예산이므로 삭제 할 수", "I004");
- return;
- }
-
-
- var iRowStatus = grd_revbugtdetaillist.rowStatus(grd_revbugtdetaillist.row);
-
- if (iRowStatus == 4 || iRowStatus == 5 || iRowStatus == 6) //delete
- {
- grd_revbugtdetaillist.removeStatus(grd_revbugtdetaillist.row, "delete");
- }
- else if(iRowStatus == 1 || iRowStatus == 3) //insert
- {
- grd_revbugtdetaillist.deleteRow(grd_revbugtdetaillist.row, false);
- }
- else if(iRowStatus == 0 || iRowStatus == 2) //update
- {
- grd_revbugtdetaillist.addStatus(grd_revbugtdetaillist.row, "delete");
- }
-
- fSetDetailListOrgAmt();
- var iCnt = 0;
- for(var i=1; i<grd_revbugtdetaillist.rows; i++)
- {
- if(grd_revbugtdetaillist.rowStatus(i) == 4 || grd_revbugtdetaillist.rowStatus(i) == 5 || grd_revbugtdetaillist.rowStatus(i) == 6)
- {
- iCnt ++ ;
- }
- }
- if(grd_revbugtdetaillist.rows - grd_revbugtdetaillist.fixedRows == iCnt)
- {
- if(grd_revbugtapplist.rowStatus(grd_revbugtapplist.row) != 1 && grd_revbugtapplist.rowStatus(grd_revbugtapplist.row) != 3)
- {
- grd_revbugtapplist.addStatus(grd_revbugtapplist.row, "delete");
- }
- else
- {
- grd_revbugtapplist.deleteRow(grd_revbugtapplist.row, false);
- }
- }
- else
- {
- if(grd_revbugtapplist.rowStatus(grd_revbugtapplist.row) != 1 && grd_revbugtapplist.rowStatus(grd_revbugtapplist.row) != 3)
- {
- grd_revbugtapplist.rowStatus(grd_revbugtapplist.row) = 2;
- }
- }
-
- model.refresh();
- ]]>
- </script>
- </button>
- <caption id="caption1" class="tit_2" style="left:593px; top:414px; width:126px; height:13px; ">추경예산 산출내역</caption>
- <button id="btn_detailaddrow" class="btn2_letter3" style="left:1085px; top:409px; width:53px; height:19px; ">
- <caption>행추가</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- if(grd_revbugtapplist.rows > 1 && grd_revbugtapplist.row > 0)
- {
- if(grd_revbugtlist.valueMatrix(1, grd_revbugtlist.colRef("revsupmbugtappyn")) == "Y")
- {
- messageBox("신청된 예산이므로 추가 할 수", "I004");
- return;
- }
- if(grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("acntcd")) == "")
- {
- messageBox("본예산 신청할 계정을 선택하세요", "I999");
- return;
- }
- misfGridIUD(grd_revbugtdetaillist, "A");
-
- grd_revbugtdetaillist.valueMatrix(grd_revbugtdetaillist.row, grd_revbugtdetaillist.colRef("instcd")) = grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("instcd"));
- grd_revbugtdetaillist.valueMatrix(grd_revbugtdetaillist.row, grd_revbugtdetaillist.colRef("acntyy")) = grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("acntyy"));
- grd_revbugtdetaillist.valueMatrix(grd_revbugtdetaillist.row, grd_revbugtdetaillist.colRef("deptcd")) = grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("deptcd"));
- grd_revbugtdetaillist.valueMatrix(grd_revbugtdetaillist.row, grd_revbugtdetaillist.colRef("acntcd")) = grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("acntcd"));
- grd_revbugtdetaillist.valueMatrix(grd_revbugtdetaillist.row, grd_revbugtdetaillist.colRef("bugtflag")) = grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("bugtflag"));
- grd_revbugtdetaillist.valueMatrix(grd_revbugtdetaillist.row, grd_revbugtdetaillist.colRef("assgym")) = grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("assgym"));
- grd_revbugtdetaillist.valueMatrix(grd_revbugtdetaillist.row, grd_revbugtdetaillist.colRef("appamt")) = 0;
- grd_revbugtdetaillist.valueMatrix(grd_revbugtdetaillist.row, grd_revbugtdetaillist.colRef("sumamt")) = 0;
- grd_revbugtdetaillist.valueMatrix(grd_revbugtdetaillist.row, grd_revbugtdetaillist.colRef("orgappamt")) = 0;
-
- grd_revbugtdetaillist.row = grd_revbugtdetaillist.rows - 1;
- grd_revbugtdetaillist.col = grd_revbugtdetaillist.colRef("appresn");
- grd_revbugtdetaillist.editCell();
- }
-
- ]]>
- </script>
- </button>
- <button id="btn_acntaddrow" class="btn2_letter4" style="left:403px; top:409px; width:64px; height:19px; ">
- <caption>항목추가</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- if(grd_revbugtlist.valueMatrix(1, grd_revbugtlist.colRef("revsupmbugtappyn")) == "Y")
- {
- messageBox("신청된 예산이므로 추가 또는 삭제를 할 수", "I004");
- return;
- }
-
- model.removeNodeset(grd_revbugtapplist.nodeset);
- model.removeNodeset(grd_revbugtdetaillist.nodeset);
- model.refresh();
- misfGridIUD(grd_revbugtapplist, "A");
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("instcd")) = model.getValue("/root/send/retrparam/instcd");
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("acntyy")) = model.getValue("/root/send/retrparam/acntyy");
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("deptcd")) = model.getValue("/root/send/retrparam/deptcd");
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("acntcd")) = "";
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("acntnm")) = "";
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("bugtflag")) = model.getValue("/root/send/retrparam/bugtflag");
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("assgym")) = "-";
-
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("orgbugtamt")) = 0;
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("revapptotalamt")) = 0;
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("revsupmbugtappamt")) = 0;
-
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("mainrec")) = "";
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("calcbase")) = "";
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("delflag")) = "Y";
- grd_revbugtapplist.valueMatrix(grd_revbugtapplist.row, grd_revbugtapplist.colRef("status")) = "1";
-
-
- grd_revbugtapplist.col = grd_revbugtapplist.colRef("acntcd");
- grd_revbugtapplist.dispatch("onbuttonclick");
-
- model.setValue("/root/hidden/bugtaddflag", "Y");
- ]]>
- </script>
- </button>
- <line id="line1" class="line_1" style="x1:586px; y1:430px; x2:586px; y2:735px; "/>
- <button id="button1" class="btn2_letter2" style="left:1147px; top:49px; width:42px; height:19px; ">
- <caption>출력</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- //2011.08.22 cyw
- fPrint();
-
- ]]>
- </script>
- </button>
- </group>
- </xhtml:body>
- </xhtml:html>
|