123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406 |
- <?xml version="1.0" encoding="EUC-KR"?>
- <?xml-stylesheet type="text/css" href="../../../com/commonweb/css/common.css" ?>
- <xhtml:html xmlns:ex="http://www.comsquare.co.kr/xforms/excel" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:ms="urn:schemas-microsoft-com:xslt" xmlns:my="http://www.comsquare.co.kr/example" 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" xmlns:cs="http://www.comsquare.co.kr/xforms">
- <xhtml:head>
- <xhtml:title>검사 예약 제어 정보 관리</xhtml:title>
- <model id="model1">
- <instance id="instance1">
- <root xmlns="">
- <init>
- <itemtype>
- <typeinfo>
- <cd>R</cd>
- <nm>조건</nm>
- </typeinfo>
- <typeinfo>
- <cd>C</cd>
- <nm>제어</nm>
- </typeinfo>
- </itemtype>
- <opcode>
- <cdinfo>
- <cd>EQ</cd>
- <nm>일치</nm>
- <rflag>Y</rflag>
- <cflag/>
- </cdinfo>
- <cdinfo>
- <cd>NE</cd>
- <nm>불일치</nm>
- <rflag>Y</rflag>
- <cflag/>
- </cdinfo>
- <cdinfo>
- <cd>OV</cd>
- <nm>이상</nm>
- <rflag>Y</rflag>
- <cflag/>
- </cdinfo>
- <cdinfo>
- <cd>BW</cd>
- <nm>이하</nm>
- <rflag>Y</rflag>
- <cflag/>
- </cdinfo>
- <cdinfo>
- <cd>EX</cd>
- <nm>초과</nm>
- <rflag>Y</rflag>
- <cflag/>
- </cdinfo>
- <cdinfo>
- <cd>UR</cd>
- <nm>미만</nm>
- <rflag>Y</rflag>
- <cflag/>
- </cdinfo>
- <cdinfo>
- <cd>IN</cd>
- <nm>이내</nm>
- <rflag>Y</rflag>
- <cflag/>
- </cdinfo>
- <cdinfo>
- <cd>NI</cd>
- <nm>이외</nm>
- <rflag>Y</rflag>
- <cflag/>
- </cdinfo>
- </opcode>
- <srch>
- <deptlist>
- <deptinfo>
- <deptcd/>
- <deptnm/>
- </deptinfo>
- </deptlist>
- <roomlist>
- <roominfo>
- <deptcd/>
- <roomcd/>
- <cdcnts/>
- <roomnm/>
- </roominfo>
- </roomlist>
- <ctrllist>
- <ctrlinfo>
- <itemseq/>
- <itemnm/>
- </ctrlinfo>
- </ctrllist>
- </srch>
- <rgst>
- <excdlist>
- <excdinfo>
- <excucd>T</excucd>
- <excunm>전체</excunm>
- </excdinfo>
- </excdlist>
- </rgst>
- </init>
- <main>
- <ctrllist>
- <ctrlinfo>
- <rsrvplce/>
- <suppdeptcd/>
- <suppdeptnm/>
- <excuroomcd/>
- <excuroomnm/>
- <excucd/>
- <excunm/>
- <ctrlseq/>
- <termcnt/>
- <ctrldesc/>
- <ctrltype/>
- <fromdd/>
- <todd/>
- </ctrlinfo>
- </ctrllist>
- <termlist>
- <terminfo>
- <rsrvplce/>
- <suppdeptcd/>
- <excuroomcd/>
- <excucd/>
- <ctrlseq/>
- <termseq/>
- <itemtype/>
- <itemseq/>
- <itemnm/>
- <opcode/>
- <valtype/>
- <valseq/>
- <val/>
- <valnm/>
- <inflag/>
- </terminfo>
- </termlist>
- <itemlist>
- <iteminfo>
- <itemtype/>
- <itemseq/>
- <itemid/>
- <itemnm/>
- <acqid/>
- <valtype/>
- <addflag/>
- <acqidarr/>
- <acqnmarr/>
- </iteminfo>
- </itemlist>
- </main>
- <temp>
- <qrylist>
- <qryinfo>
- <acqid/>
- <acqnm/>
- <itemseq/>
- <itemid/>
- <itemnm/>
- </qryinfo>
- </qrylist>
- <addval/>
- <iptval>
- <val/>
- <valnm/>
- </iptval>
- <enumlist>
- <enuminfo>
- <itemseq/>
- <itemnm/>
- </enuminfo>
- </enumlist>
- <enumval>
- <val/>
- <valnm/>
- </enumval>
- <srchlist>
- <srchinfo>
- <val/>
- <valnm/>
- </srchinfo>
- </srchlist>
- <refval>
- <val/>
- <valnm/>
- </refval>
- <term>
- <itemtype/>
- <itemseq/>
- <itemnm/>
- <opcode/>
- <opnm/>
- <valtype/>
- <valseq/>
- <val/>
- <valnm/>
- <acqid/>
- <inflag/>
- </term>
- <rslt>
- <ctrlseq/>
- </rslt>
- </temp>
- <send>
- <srch>
- <rsrvplce>A</rsrvplce>
- <suppdeptcd/>
- <excuroomcd/>
- <excucd/>
- <itemseq/>
- <srchflag>D</srchflag>
- <srchstr/>
- <deptcd/>
- <roomcd/>
- </srch>
- <term>
- <rsrvplce/>
- <suppdeptcd/>
- <excuroomcd/>
- <excucd/>
- <ctrlseq/>
- </term>
- <rgst>
- <rsrvplce>A</rsrvplce>
- <suppdeptcd/>
- <excuroomcd/>
- <excucd/>
- <ctrlseq/>
- <ctrldesc/>
- <fromdd/>
- <todd/>
- <ctrlflag/>
- <termlist>
- <terminfo>
- <termseq/>
- <itemtype/>
- <itemseq/>
- <itemnm/>
- <opcode/>
- <valtype/>
- <inflag/>
- <aoflag/>
- <valseq/>
- <val/>
- <valnm/>
- <invalnm/>
- </terminfo>
- </termlist>
- </rgst>
- </send>
- <hidden>
- <valtype>
- <qryyn/>
- <drctyn/>
- <srchyn/>
- <enumyn/>
- <refyn/>
- </valtype>
- <addflag/>
- <aoflag>O</aoflag>
- <popup/>
- </hidden>
- </root>
- </instance>
- <submission id="TRPEA00201" mediatype="application/x-www-form-urlencoded" method="post" resultref="/root/main/itemlist/iteminfo"/>
- <submission id="TRPEA00202" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/srch" resultref="/root/init/srch"/>
- <submission id="TRPEA00203" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/srch" resultref="/root/init/srch/roomlist/roominfo"/>
- <submission id="TRPEA00204" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/srch" resultref="/root/init/rgst/excdlist/excdinfo"/>
- <submission id="TRPEA00205" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/srch" resultref="/root/main/ctrllist/ctrlinfo"/>
- <submission id="TRPEA00206" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/term" resultref="/root/send/rgst/termlist/terminfo"/>
- <submission id="TXPEA00203" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/rgst" resultref="/root/temp/rslt"/>
- <submission id="TXPEA00205" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/term"/>
- </model>
- <script type="javascript">
- <![CDATA[
-
- var CURR_PLCE = "";
- var CURR_DEPT = "";
- var CURR_ROOM = "";
- var CURR_CODE = "";
-
- function fSearchTerms() {
-
- grd_ctrl.rebuildStyle();
-
- submit("TRPEA00205");
-
- btn_newrgst.dispatch("DOMActivate");
- }
-
- function fClearValues() {
-
- // 항목 그리드 초기화
- grd_item.nodeset = "/";
-
- // 연산 그리드 초기화
- grd_opcode.nodeset = "/";
-
- // 조건 값 초기화
- model.resetInstanceNode("/root/temp/qrylist/qryinfo");
- grd_qry.refresh();
-
- model.setValue("/root/temp/addval", "");
- ipt_addval.refresh();
-
- model.setValue("/root/temp/iptval/val", "");
- model.setValue("/root/temp/iptval/valnm", "");
- ipt_drct.hint = "";
- ipt_drct.refresh();
-
- model.resetInstanceNode("/root/temp/enumlist/enuminfo");
- rdo_enum.refresh();
-
- model.setValue("/root/temp/enumval/val", "");
- model.setValue("/root/temp/enumval/valnm", "");
- rdo_enum.refresh();
-
- model.resetInstanceNode("/root/temp/srchlist/srchinfo");
- grd_srch.refresh();
-
- model.resetInstanceNode("/root/temp/term");
-
- rdo_itemtype.refresh();
- cap_item.refresh();
- cap_opnm.refresh();
- cap_valnm.refresh();
- cap_valnm.hint = "";
-
- // 값 형식 설정
- fSetValType("");
- }
-
- function fSetValType(valtype) {
-
- model.resetInstanceNode("/root/hidden/valtype");
-
- chk_drct.refresh();
- chk_srch.refresh();
- chk_enum.refresh();
- chk_qry.refresh();
- chk_ref.refresh();
-
- var color = "#fffbf2";
-
- if (valtype.indexOf("D") < 0) {
- grp_drct.attribute("background-color") = color;
- model.setValue("/root/temp/iptval/val", "");
- model.setValue("/root/temp/iptval/valnm", "");
- ipt_drct.hint = "";
- ipt_drct.refresh();
- chk_drct.disabled = true;
- } else {
- grp_drct.attribute("background-color") = "#ffffff";
- chk_drct.disabled = false;
- }
-
- if (valtype.indexOf("S") < 0) {
- grp_srch.attribute("background-color") = color;
- model.resetInstanceNode("/root/temp/term/srchlist/srchinfo");
- grd_srch.refresh();
- chk_srch.disabled = true;
- } else {
- grp_srch.attribute("background-color") = "#ffffff";
- chk_srch.disabled = false;
- }
-
- if (valtype.indexOf("E") < 0) {
- grp_enum.attribute("background-color") = color;
- chk_enum.disabled = true;
- } else {
- grp_enum.attribute("background-color") = "#ffffff";
- chk_enum.disabled = false;
- }
-
- if (valtype.indexOf("Q") < 0) {
- grp_qry.attribute("background-color") = color;
- chk_qry.disabled = true;
- } else {
- grp_qry.attribute("background-color") = "#ffffff";
- chk_qry.disabled = false;
- }
-
- if (valtype.indexOf("R") < 0) {
- grp_ref.attribute("background-color") = color;
- chk_ref.disabled = true;
- } else {
- grp_ref.attribute("background-color") = "#ffffff";
- chk_ref.disabled = false;
- }
-
- ipt_drct.visible = false;
- btn_drctipt.visible = false;
- btn_drctex.visible = false;
- rdo_enum.visible = false;
- chk_enumarr.visible = false;
- btn_srch.visible = false;
- btn_srchipt.visible = false;
- btn_delsrch.visible = false;
- grd_srch.visible = false;
- grd_qry.visible = false;
- btn_refipt.visible = false;
- cmb_ref.visible = false;
-
- ipt_addval.disabled = true;
- }
-
- function fSetTypeChk(valtype, chkyn) {
-
- model.setValue("/root/temp/term/valtype", valtype);
-
- if (valtype == "D") {
-
- model.setValue("/root/temp/iptval/val", "");
- model.setValue("/root/temp/iptval/valnm", "");
- ipt_drct.hint = "";
- ipt_drct.refresh();
-
- model.setValue("/root/hidden/valtype/qryyn", "");
- chk_qry.refresh();
- model.setValue("/root/hidden/valtype/srchyn", "");
- chk_srch.refresh();
- model.setValue("/root/hidden/valtype/enumyn", "");
- chk_enum.refresh();
- model.setValue("/root/hidden/valtype/refyn", "");
- chk_ref.refresh();
-
- ipt_drct.visible = btn_drctipt.visible = btn_drctex.visible = chkyn == "Y" ? true : false;
-
- rdo_enum.visible = false;
- chk_enumarr.visible = false;
- btn_srch.visible = false;
- btn_srchipt.visible = false;
- btn_delsrch.visible = false;
- grd_srch.visible = false;
- grd_qry.visible = false;
- btn_refipt.visible = false;
- cmb_ref.visible = false;
-
- } else if (valtype == "S") {
-
- model.setValue("/root/hidden/valtype/qryyn", "");
- chk_qry.refresh();
- model.setValue("/root/hidden/valtype/drctyn", "");
- chk_drct.refresh();
- model.setValue("/root/hidden/valtype/enumyn", "");
- chk_enum.refresh();
- model.setValue("/root/hidden/valtype/refyn", "");
- chk_ref.refresh();
-
- btn_srch.visible = btn_srchipt.visible = grd_srch.visible = btn_delsrch.visible = chkyn == "Y" ? true : false;
-
- ipt_drct.visible = false;
- btn_drctipt.visible = false;
- btn_drctex.visible = false;
- rdo_enum.visible = false;
- chk_enumarr.visible = false;
- grd_qry.visible = false;
- btn_refipt.visible = false;
- cmb_ref.visible = false;
-
- } else if (valtype == "E") {
-
- model.setValue("/root/hidden/valtype/qryyn", "");
- chk_qry.refresh();
- model.setValue("/root/hidden/valtype/drctyn", "");
- chk_drct.refresh();
- model.setValue("/root/hidden/valtype/srchyn", "");
- chk_srch.refresh();
- model.setValue("/root/hidden/valtype/refyn", "");
- chk_ref.refresh();
-
- var opcode = model.getValue("/root/temp/term/opcode");
- if (opcode == "IN" || opcode == "NI") {
- chk_enumarr.visible = chkyn == "Y" ? true : false;
- rdo_enum.visible = false;
- } else {
- rdo_enum.visible = chkyn == "Y" ? true : false;
- chk_enumarr.visible = false;
- }
-
- ipt_drct.visible = false;
- btn_drctipt.visible = false;
- btn_drctex.visible = false;
- btn_srch.visible = false;
- btn_srchipt.visible = false;
- btn_delsrch.visible = false;
- grd_srch.visible = false;
- grd_qry.visible = false;
- btn_refipt.visible = false;
- cmb_ref.visible = false;
-
- } else if (valtype == "Q") {
-
- model.setValue("/root/hidden/valtype/drctyn", "");
- chk_drct.refresh();
- model.setValue("/root/hidden/valtype/srchyn", "");
- chk_srch.refresh();
- model.setValue("/root/hidden/valtype/enumyn", "");
- chk_enum.refresh();
- model.setValue("/root/hidden/valtype/refyn", "");
- chk_ref.refresh();
-
- grd_qry.visible = chkyn == "Y" ? true : false;
-
- ipt_drct.visible = false;
- btn_drctipt.visible = false;
- btn_drctex.visible = false;
- rdo_enum.visible = false;
- chk_enumarr.visible = false;
- btn_srch.visible = false;
- btn_srchipt.visible = false;
- btn_delsrch.visible = false;
- grd_srch.visible = false;
- btn_refipt.visible = false;
- cmb_ref.visible = false;
-
- } else if (valtype == "R") {
-
- model.setValue("/root/temp/refval/val", "");
- model.setValue("/root/temp/refval/valnm", "");
- cmb_ref.refresh();
-
- model.setValue("/root/hidden/valtype/qryyn", "");
- chk_qry.refresh();
- model.setValue("/root/hidden/valtype/drctyn", "");
- chk_drct.refresh();
- model.setValue("/root/hidden/valtype/srchyn", "");
- chk_srch.refresh();
- model.setValue("/root/hidden/valtype/enumyn", "");
- chk_enum.refresh();
-
- btn_refipt.visible = cmb_ref.visible = chkyn == "Y" ? true : false;
-
- ipt_drct.visible = false;
- btn_drctipt.visible = false;
- btn_drctex.visible = false;
- rdo_enum.visible = false;
- chk_enumarr.visible = false;
- btn_srch.visible = false;
- btn_srchipt.visible = false;
- btn_delsrch.visible = false;
- grd_srch.visible = false;
- grd_qry.visible = false;
- }
-
- if (model.getValue("/root/hidden/addflag") == "Y") {
- ipt_addval.disabled = false;
- } else {
- ipt_addval.disabled = true;
- }
- }
-
- function fSetTermInfo() {
-
- grd_ctrl.attribute("height") = "220px";
- btn_expand.attribute("background-image") = "../../../com/commonweb/images/btn_send_bottom.gif";
-
- var row = grd_ctrl.row;
- grd_ctrl.rebuildStyle();
- grd_ctrl.focusColor = grd_ctrl.rowStyle(row, "all", "background-color") = "#ffcdcd";
- if (row > grd_ctrl.bottomRow) {
- grd_ctrl.bottomRow = row;
- }
-
- var rsrvplce = model.getValue("/root/main/ctrllist/ctrlinfo[" + row + "]/rsrvplce");
- var suppdeptcd = model.getValue("/root/main/ctrllist/ctrlinfo[" + row + "]/suppdeptcd");
- var excuroomcd = model.getValue("/root/main/ctrllist/ctrlinfo[" + row + "]/excuroomcd");
- var excucd = model.getValue("/root/main/ctrllist/ctrlinfo[" + row + "]/excucd");
- var ctrlseq = model.getValue("/root/main/ctrllist/ctrlinfo[" + row + "]/ctrlseq");
-
- CURR_PLCE = rsrvplce;
- CURR_DEPT = suppdeptcd;
- CURR_ROOM = excuroomcd;
- CURR_CODE = excucd;
-
- model.setValue("/root/send/term/rsrvplce", rsrvplce);
- model.setValue("/root/send/term/suppdeptcd", suppdeptcd);
- model.setValue("/root/send/term/excuroomcd", excuroomcd);
- model.setValue("/root/send/term/excucd", excucd);
- model.setValue("/root/send/term/ctrlseq", ctrlseq);
-
- submit("TRPEA00206", false);
-
- var cnt = instance1.selectNodes("/root/send/rgst/termlist/terminfo").length;
- for (var i = 1; i <= cnt; i++) {
- var inflag = model.getValue("/root/send/rgst/termlist/terminfo[" + i + "]/inflag");
- var aoflag = model.getValue("/root/send/rgst/termlist/terminfo[" + i + "]/aoflag");
-
- var invalnm = fGetInFlagName(inflag, aoflag) + model.getValue("/root/send/rgst/termlist/terminfo[" + i + "]/valnm");
- model.makeValue("/root/send/rgst/termlist/terminfo[" + i + "]/invalnm", invalnm);
- }
-
- grd_rgst.refresh();
-
- for (var i = 1; i <= cnt; i++) {
- grd_rgst.tooltipText(i, grd_rgst.colRef("invalnm")) = model.getValue("/root/send/rgst/termlist/terminfo[" + i + "]/valnm");
- }
-
- model.setValue("/root/send/rgst/rsrvplce", rsrvplce);
- model.setValue("/root/send/rgst/suppdeptcd", suppdeptcd);
-
- cmb_rgstplce.refresh();
- cmb_rgstdept.refresh();
-
- cmb_rgstdept.dispatch("xforms-value-changed");
-
- model.setValue("/root/send/rgst/excuroomcd", excuroomcd);
- cmb_rgstroom.refresh();
-
- model.setValue("/root/send/rgst/excucd", excucd);
- cmb_rgstexcd.refresh();
-
- cmb_rgstexcd.dispatch("xforms-value-changed");
-
- model.setValue("/root/send/rgst/ctrlseq", ctrlseq);
-
- var ctrldesc = model.getValue("/root/main/ctrllist/ctrlinfo[" + row + "]/ctrldesc");
- var fromdd = model.getValue("/root/main/ctrllist/ctrlinfo[" + row + "]/fromdd");
- var todd = model.getValue("/root/main/ctrllist/ctrlinfo[" + row + "]/todd");
-
- model.setValue("/root/send/rgst/ctrldesc", ctrldesc);
- tar_rgstdesc.refresh();
-
- model.setValue("/root/send/rgst/fromdd", fromdd);
- ipt_fromdd.refresh();
-
- model.setValue("/root/send/rgst/todd", todd);
- ipt_todd.refresh();
- }
-
- function fSetRgstStatus(isNew) {
- cap_status.value = btn_rgst.value = isNew ? "등록" : "수정";
- cap_status.attribute("color") = isNew ? "black" : "blue";
- }
-
- // -1 : 위로, 1 : 아래로, 0 : 삭제
- function fMoveTerm(mov) {
-
- if (mov != 0 && grd_rgst.rows < 2) {
- return;
- }
-
- var toprow = grd_rgst.topRow;
- var bottomrow = grd_rgst.bottomRow;
-
- var row = grd_rgst.row;
-
- if (row + mov == 0 || row + mov == grd_rgst.rows) {
- return;
- }
-
- var rpath = "/root/send/rgst/termlist/terminfo";
- var tpath = "/root/temp/templist/terminfo";
-
- var cnt = instance1.selectNodes(rpath).length;
- var idx = 1;
- var del = 0;
-
- // index 설정
- for (var i = 1; i <= cnt; i++) {
-
- if (mov == 0 && grd_rgst.isSelected(i)) { // 삭제
- del++;
- continue;
- } else if (i == row + mov) {
- idx = i + ( mov * -1 );
- } else if (i == row) {
- idx = i + mov;
- } else {
- idx = i;
- }
-
- model.makeValue(tpath + "[" + ( i - del ) + "]/ctrlseq", model.getValue(rpath + "[" + idx + "]/ctrlseq"));
- model.makeValue(tpath + "[" + ( i - del ) + "]/termseq", i - del);
- model.makeValue(tpath + "[" + ( i - del ) + "]/itemtype", model.getValue(rpath + "[" + idx + "]/itemtype"));
- model.makeValue(tpath + "[" + ( i - del ) + "]/itemseq", model.getValue(rpath + "[" + idx + "]/itemseq"));
- model.makeValue(tpath + "[" + ( i - del ) + "]/itemnm", model.getValue(rpath + "[" + idx + "]/itemnm"));
- model.makeValue(tpath + "[" + ( i - del ) + "]/opcode", model.getValue(rpath + "[" + idx + "]/opcode"));
- model.makeValue(tpath + "[" + ( i - del ) + "]/valtype", model.getValue(rpath + "[" + idx + "]/valtype"));
- model.makeValue(tpath + "[" + ( i - del ) + "]/valseq", model.getValue(rpath + "[" + idx + "]/valseq"));
- model.makeValue(tpath + "[" + ( i - del ) + "]/val", model.getValue(rpath + "[" + idx + "]/val"));
- model.makeValue(tpath + "[" + ( i - del ) + "]/valnm", model.getValue(rpath + "[" + idx + "]/valnm"));
- model.makeValue(tpath + "[" + ( i - del ) + "]/invalnm", model.getValue(rpath + "[" + idx + "]/invalnm"));
- model.makeValue(tpath + "[" + ( i - del ) + "]/inflag", model.getValue(rpath + "[" + idx + "]/inflag"));
- model.makeValue(tpath + "[" + ( i - del ) + "]/aoflag", model.getValue(rpath + "[" + idx + "]/aoflag"));
- }
-
- model.removenode("/root/send/rgst/termlist");
- model.makeNode("/root/send/rgst/termlist");
-
- cnt = instance1.selectNodes(tpath).length;
-
- // opcode 설정
- for (var i = 1; i <= cnt; i++) {
-
- var itemseq = model.getValue(tpath + "[" + i + "]/itemseq");
- var prevseq = i == 1 ? "" : model.getValue(tpath + "[" + ( i - 1 ) + "]/itemseq");
- var nextseq = i == cnt ? "" : model.getValue(tpath + "[" + ( i + 1 ) + "]/itemseq");
-
- var opcode = model.getValue(tpath + "[" + i + "]/opcode");
- var prevop = i == 1 ? "" : model.getValue(tpath + "[" + ( i - 1 ) + "]/opcode");
- var nextop = i == cnt ? "" : model.getValue(tpath + "[" + ( i + 1 ) + "]/opcode");
-
- var prevflag = true;
- var nextflag = true;
-
- if (itemseq == prevseq) {
- if (opcode == "EQ" && ( prevop == "EQ" || prevop == "IN" )) {
- opcode = "IN";
- } else if (opcode == "NE" && ( prevop == "NE" || prevop == "NI" )) {
- opcode = "NI";
- } else if (( opcode == "IN" && ( prevop != "IN" && prevop != "EQ" ) )
- || ( opcode == "NI" && ( prevop != "NI" && prevop != "NE" ) )) {
- prevflag = false;
- }
- } else {
- prevflag = false;
- }
-
- if (itemseq == nextseq) {
- if (opcode == "EQ" && ( nextop == "EQ" || nextop == "IN" )) {
- opcode = "IN";
- } else if (opcode == "NE" && ( nextop == "NE" || nextop == "NI" )) {
- opcode = "NI";
- } else if (( opcode == "IN" && ( nextop != "IN" && nextop != "EQ" ) )
- || ( opcode == "NI" && ( nextop != "NI" && nextop != "NE" ) )) {
- nextflag = false;
- }
- } else {
- nextflag = false;
- }
-
- if (( !prevflag && !nextflag ) || itemseq != prevseq && itemseq != nextseq) {
- if (opcode == "IN") {
- opcode = "EQ";
- } else if (opcode == "NI") {
- opcode = "NE";
- }
- }
-
- model.makeValue(tpath + "[" + i + "]/ctrlseq", model.getValue(tpath + "[" + i + "]/ctrlseq"));
- model.makeValue(tpath + "[" + i + "]/termseq", model.getValue(tpath + "[" + i + "]/termseq"));
- model.makeValue(tpath + "[" + i + "]/itemtype", model.getValue(tpath + "[" + i + "]/itemtype"));
- model.makeValue(tpath + "[" + i + "]/itemseq", model.getValue(tpath + "[" + i + "]/itemseq"));
- model.makeValue(tpath + "[" + i + "]/itemnm", model.getValue(tpath + "[" + i + "]/itemnm"));
- model.makeValue(tpath + "[" + i + "]/opcode", opcode);
- model.makeValue(tpath + "[" + i + "]/valtype", model.getValue(tpath + "[" + i + "]/valtype"));
- model.makeValue(tpath + "[" + i + "]/valseq", model.getValue(tpath + "[" + i + "]/valseq"));
- model.makeValue(tpath + "[" + i + "]/val", model.getValue(tpath + "[" + i + "]/val"));
- model.makeValue(tpath + "[" + i + "]/valnm", model.getValue(tpath + "[" + i + "]/valnm"));
- model.makeValue(tpath + "[" + i + "]/invalnm", model.getValue(tpath + "[" + i + "]/invalnm"));
- model.makeValue(tpath + "[" + i + "]/inflag", model.getValue(tpath + "[" + i + "]/inflag"));
- model.makeValue(tpath + "[" + i + "]/aoflag", model.getValue(tpath + "[" + i + "]/aoflag"));
- }
-
- // inflag 설정
- for (var i = 1; i <= cnt; i++) {
-
- var itemseq = model.getValue(tpath + "[" + i + "]/itemseq");
- var prevseq = i == 1 ? "" : model.getValue(tpath + "[" + ( i - 1 ) + "]/itemseq");
- var nextseq = i == cnt ? "" : model.getValue(tpath + "[" + ( i + 1 ) + "]/itemseq");
-
- var opcode = model.getValue(tpath + "[" + i + "]/opcode");
- var prevop = i == 1 ? "" : model.getValue(tpath + "[" + ( i - 1 ) + "]/opcode");
- var nextop = i == cnt ? "" : model.getValue(tpath + "[" + ( i + 1 ) + "]/opcode");
-
- var inflag = "";
- var inflagdp = "";
-
- if (opcode == "IN" || opcode == "NI") {
- if (itemseq != prevseq || ( itemseq == prevseq && opcode != prevop )) {
- inflag = "B";
- inflagdp = "┌ ";
- } else if (itemseq != nextseq || ( itemseq == nextseq && opcode != nextop )) {
- inflag = "E";
- inflagdp = "└ ";
- } else {
- inflag = "I";
- inflagdp = "│ ";
- }
- }
-
- // 순서 변경시 포괄 적용 항목은 모두 초기화됨
-
- model.makeValue(rpath + "[" + i + "]/ctrlseq", model.getValue(tpath + "[" + i + "]/ctrlseq"));
- model.makeValue(rpath + "[" + i + "]/termseq", model.getValue(tpath + "[" + i + "]/termseq"));
- model.makeValue(rpath + "[" + i + "]/itemtype", model.getValue(tpath + "[" + i + "]/itemtype"));
- model.makeValue(rpath + "[" + i + "]/itemseq", model.getValue(tpath + "[" + i + "]/itemseq"));
- model.makeValue(rpath + "[" + i + "]/itemnm", model.getValue(tpath + "[" + i + "]/itemnm"));
- model.makeValue(rpath + "[" + i + "]/opcode", opcode);
- model.makeValue(rpath + "[" + i + "]/valtype", model.getValue(tpath + "[" + i + "]/valtype"));
- model.makeValue(rpath + "[" + i + "]/valseq", model.getValue(tpath + "[" + i + "]/valseq"));
- model.makeValue(rpath + "[" + i + "]/val", model.getValue(tpath + "[" + i + "]/val"));
- model.makeValue(rpath + "[" + i + "]/valnm", model.getValue(tpath + "[" + i + "]/valnm"));
- model.makeValue(rpath + "[" + i + "]/invalnm", inflagdp + model.getValue(tpath + "[" + i + "]/valnm"));
- model.makeValue(rpath + "[" + i + "]/inflag", inflag);
- model.makeValue(rpath + "[" + i + "]/aoflag", inflag != "" ? "O" : "");
- }
-
- model.removenode("/root/temp/templist");
-
- grd_rgst.refresh();
-
- cnt = instance1.selectNodes("/root/send/rgst/termlist/terminfo").length;
- for (var i = 1; i <= cnt; i++) {
- grd_rgst.tooltipText(i, grd_rgst.colRef("invalnm")) = model.getValue("/root/send/rgst/termlist/terminfo[" + i + "]/valnm");
- }
-
- grd_rgst.row = row + mov;
-
- if (mov == 0) {
- grd_rgst.topRow = toprow;
- } else if (mov < 0 && row + mov < toprow) {
- grd_rgst.topRow = toprow - 1;
- } else if (mov > 0 && row + mov > bottomrow) {
- grd_rgst.bottomRow = bottomrow + 1;
- }
- }
-
- function fGetInFlagName(inflag, aoflag) {
-
- var invalnm = "";
-
- for (var j = 0; j < inflag.length; j++) {
- if (inflag.substr(j, 1) == "B") {
- invalnm += "┌";
- } else if (inflag.substr(j, 1) == "E") {
- invalnm += "└";
- } else if (inflag.substr(j, 1) == "I") {
- invalnm += "│";
- }
-
- invalnm += aoflag.substr(j, 1) == "A" ? "&" : "";
- }
-
- invalnm += ( inflag.length > 0 ? " " : "" );
-
- return invalnm;
- }
- ]]>
- </script>
- <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" ev:event="xforms-ready">
- <![CDATA[
-
- if (getUserId() == "PAM") {
- btn_itemmng.visible = true;
- btn_easyrgst.visible = true;
- }
-
- grp_drctex.attribute("top") = "245px";
-
- chk_enumarr.attribute("top") = rdo_enum.attribute("top");
- chk_enumarr.attribute("height") = rdo_enum.attribute("height");
-
- // 제어 항목 조회
- submit("TRPEA00201");
-
- // 수행부서 & 검사실 조회
- submit("TRPEA00202", false);
-
- addComboItem("cmb_deptcd", "전체", "T");
- addComboItem("cmb_roomcd", "전체", "T");
- //model.makeValue("/root/init/srch/roomlist/roominfo/deptcd", ""); // nodeset 동적 변경을 위해 해당 항목 미리 만들어둠 (안만들면 오류 발생)
-
- cmb_deptcd.select(0);
-
- // 등록 기본 항목 기본 세팅
- cmb_rgstdept.select(0);
-
- // 제어 항목 설정
- model.makeValue("/root/init/srch/ctrllist/ctrlinfo/itemseq", "T");
- model.makeValue("/root/init/srch/ctrllist/ctrlinfo/itemnm", "전체");
- var cnt = instance1.selectNodes("/root/main/itemlist/iteminfo").length;
- var idx = 2;
- for (var i = 1; i <= cnt; i++) {
- if (model.getValue("/root/main/itemlist/iteminfo[" + i + "]/itemtype") == "C") {
- model.makeValue("/root/init/srch/ctrllist/ctrlinfo[" + idx + "]/itemseq", model.getValue("/root/main/itemlist/iteminfo[" + i + "]/itemseq"));
- model.makeValue("/root/init/srch/ctrllist/ctrlinfo[" + idx + "]/itemnm", model.getValue("/root/main/itemlist/iteminfo[" + i + "]/itemnm"));
- idx++;
- }
- }
- cmb_ctrl.refresh();
- cmb_ctrl.select(0);
-
- fSearchTerms();
-
- model.setValue("/root/send/rgst/fromdd", getCurrentDate());
- model.setValue("/root/send/rgst/todd", "99991231");
-
- ipt_fromdd.refresh();
- ipt_todd.refresh();
- ]]>
- </script>
- </xhtml:head>
- <xhtml:body style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
- <caption id="cap_title" class="tit_1" style="left:0px; top:0px; width:165px; height:14px; font-family:돋움; vertical-align:middle; ">검사 예약 제어 정보 관리</caption>
- <caption id="caption7" class="tit_2" style="left:0px; top:70px; width:124px; height:13px; font-weight:bold; ">등록된 제어 내역</caption>
- <datagrid id="grd_rgst" nodeset="/root/send/rgst/termlist/terminfo" backcoloralternate="transparent" caption="제어순번^항번^구분^항목순번^항목^연산^형식^포괄^포괄구분^값순번^코드^비교값^비교값" colsep="^" colwidth="0, 35, 35, 0, 90, 45, 35, 0, 0, 0, 90, 0, 222" ellipsis="true" mergecellsfixedrows="bycolrec" rowsep="|" tooltip="true" style="left:625px; top:345px; width:570px; height:280px; ">
- <col ref="ctrlseq"/>
- <col ref="termseq" style="text-align:center; "/>
- <col disabled="true" ref="itemtype" type="combo" style="text-align:center; ">
- <choices>
- <itemset nodeset="/root/init/itemtype/typeinfo">
- <label ref="nm"/>
- <value ref="cd"/>
- </itemset>
- </choices>
- </col>
- <col ref="itemseq"/>
- <col ref="itemnm" style="text-align:center; "/>
- <col disabled="true" ref="opcode" type="combo" style="text-align:center; ">
- <choices>
- <itemset nodeset="/root/init/opcode/cdinfo">
- <label ref="nm"/>
- <value ref="cd"/>
- </itemset>
- </choices>
- </col>
- <col disabled="true" ref="valtype" type="combo" style="text-align:center; ">
- <choices>
- <item>
- <label>직접</label>
- <value>D</value>
- </item>
- <item>
- <label>조회</label>
- <value>S</value>
- </item>
- <item>
- <label>열거</label>
- <value>E</value>
- </item>
- <item>
- <label>참조</label>
- <value>R</value>
- </item>
- <item>
- <label>질의</label>
- <value>Q</value>
- </item>
- </choices>
- </col>
- <col ref="inflag" style="text-align:right; "/>
- <col ref="aoflag" style="text-align:right; "/>
- <col ref="valseq"/>
- <col ref="val" style="text-align:center; "/>
- <col ref="valnm"/>
- <col ref="invalnm" style="text-align:left; "/>
- <script type="javascript" ev:event="ondblclick">
- <![CDATA[
- if (!grd_rgst.isCell(event.target)) {
- return;
- }
-
- var itemseq = model.getValue("/root/send/rgst/termlist/terminfo[" + grd_rgst.row + "]/itemseq");
-
- if (itemseq == 44 || itemseq == 119) { // 팝업메시지 & 가셔야할곳
- model.setValue("/root/hidden/popup", model.getValue("/root/send/rgst/termlist/terminfo[" + grd_rgst.row + "]/valnm"));
- tar_popup.refresh();
- grp_popup.visible = true;
- }
- ]]>
- </script>
- </datagrid>
- <caption id="caption9" class="tit_2" style="left:625px; top:325px; width:75px; height:13px; ">제어 문항</caption>
- <button id="btn_rgst" class="btn4_letter2" style="left:1139px; top:738px; width:56px; height:22px; ">
- <caption>등록</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
-
- if (instance1.selectNodes("/root/send/rgst/termlist/terminfo[termseq != '']").length < 1 &&
- model.getValue("/root/send/rgst/ctrldesc") == "" ) {
- messageBox("등록할 조건 내역이 없습니다.", "E999");
- return;
- }
-
- // 기본 항목 변경 내역 확인
- if (model.getValue("/root/send/rgst/ctrlseq") != "" &&
- ( model.getValue("/root/send/rgst/rsrvplce") != CURR_PLCE ||
- model.getValue("/root/send/rgst/suppdeptcd") != CURR_DEPT ||
- model.getValue("/root/send/rgst/excuroomcd") != CURR_ROOM ||
- model.getValue("/root/send/rgst/excucd") != CURR_CODE )) {
-
- if (messageBox("기본 항목이 변경되었습니다.\n새로운 제어문으로 등록하시겠습니까?", "Q999") != 6) {
- return;
- }
-
- model.setValue("/root/send/rgst/ctrlseq", "");
- }
-
- var prevRow = 0
- var prevBottomRow = grd_ctrl.bottomRow;
-
- if (model.getValue("/root/send/rgst/ctrlseq") != "") { // 수정하는 경우
- prevRow = grd_ctrl.row;
- }
-
- submit("TXPEA00203");
-
- fClearValues();
-
- fSearchTerms();
-
- if (prevRow > 0) {
- grd_ctrl.row = prevRow;
- grd_ctrl.bottomRow = prevBottomRow;
- } else {
-
- var rsrvplce = model.getValue("/root/send/rgst/rsrvplce");
- var suppdeptcd = model.getValue("/root/send/rgst/suppdeptcd");
- var excuroomcd = model.getValue("/root/send/rgst/excuroomcd");
- var excucd = model.getValue("/root/send/rgst/excucd");
- var ctrlseq = model.getValue("/root/temp/rslt/ctrlseq");
-
- var cnt = instance1.selectNodes("/root/main/ctrllist/ctrlinfo").length;
- for (var i = 1; i <= cnt; i++) {
- if (rsrvplce == model.getValue("/root/main/ctrllist/ctrlinfo[" + i + "]/rsrvplce") &&
- suppdeptcd == model.getValue("/root/main/ctrllist/ctrlinfo[" + i + "]/suppdeptcd") &&
- excuroomcd == model.getValue("/root/main/ctrllist/ctrlinfo[" + i + "]/excuroomcd") &&
- excucd == model.getValue("/root/main/ctrllist/ctrlinfo[" + i + "]/excucd") &&
- ctrlseq == model.getValue("/root/main/ctrllist/ctrlinfo[" + i + "]/ctrlseq")) {
-
- grd_ctrl.row = i;
- grd_ctrl.bottomRow = i;
- break;
- }
- }
- }
-
- ]]>
- </script>
- </button>
- <button id="btn_itemmng" class="btn3_letter6" visibility="hidden" style="left:1033px; top:738px; width:104px; height:22px; ">
- <caption>제어항목관리</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- open("../../../pam/pamexcuweb/xrw/SPPEA00201_검사예약정보항목관리.xrw", "", "", "" ,"", "", "");
- ]]>
- </script>
- </button>
- <button id="btn_easyrgst" class="btn3_letter4" visibility="hidden" style="left:951px; top:738px; width:80px; height:22px; ">
- <caption>간편등록</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- open("SPPEA00203", "");
- ]]>
- </script>
- </button>
- <button id="btn_delterm" class="btn2_letter2" style="left:1088px; top:65px; width:42px; height:19px; ">
- <caption>삭제</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- var row = grd_ctrl.row;
-
- if (row < 1) {
- return;
- }
-
- if (messageBox("선택된 기본항목에 해당하는 모든 제어문이 삭제됩니다.\n삭제하시겠습니까?", "Q999") != 6) {
- return;
- }
-
- model.setValue("/root/send/term/rsrvplce", model.getValue("/root/main/ctrllist/ctrlinfo[" + row + "]/rsrvplce"));
- model.setValue("/root/send/term/suppdeptcd", model.getValue("/root/main/ctrllist/ctrlinfo[" + row + "]/suppdeptcd"));
- model.setValue("/root/send/term/excuroomcd", model.getValue("/root/main/ctrllist/ctrlinfo[" + row + "]/excuroomcd"));
- model.setValue("/root/send/term/excucd", model.getValue("/root/main/ctrllist/ctrlinfo[" + row + "]/excucd"));
- model.setValue("/root/send/term/ctrlseq", model.getValue("/root/main/ctrllist/ctrlinfo[" + row + "]/ctrlseq"));
-
- submit("TXPEA00205");
-
- fSearchTerms();
- ]]>
- </script>
- </button>
- <button id="btn_newrgst" class="btn2_letter4" style="left:551px; top:320px; width:64px; height:19px; ">
- <caption>신규등록</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
-
- fSetRgstStatus(true);
-
- fClearValues();
-
- CURR_PLCE = "";
- CURR_DEPT = "";
- CURR_ROOM = "";
- CURR_CODE = "";
-
- model.setValue("/root/send/rgst/ctrlseq", "");
-
- model.setValue("/root/send/rgst/ctrldesc", "");
- tar_rgstdesc.refresh();
-
- model.resetInstanceNode("/root/send/rgst/termlist/terminfo");
- grd_rgst.refresh();
-
- grd_ctrl.focusColor = "#ece1ec";
- grd_ctrl.rebuildStyle();
- ]]>
- </script>
- </button>
- <button id="btn_delrgst" class="btn2_letter2" style="left:1153px; top:320px; width:42px; height:19px; ">
- <caption>삭제</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- fMoveTerm(0);
- ]]>
- </script>
- </button>
- <button id="btn_up" style="left:1099px; top:320px; width:26px; height:19px; background-image:../../../com/commonweb/images/btn_send_up.gif; ">
- <caption/>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- if (grd_rgst.selectedRows > 1) {
- messageBox("행 이동은 단일 행 선택시만 가능합니다.", "E999");
- return;
- }
- fMoveTerm(-1);
- ]]>
- </script>
- </button>
- <button id="btn_down" style="left:1126px; top:320px; width:26px; height:19px; background-image:../../../com/commonweb/images/btn_send_down.gif; ">
- <caption/>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- if (grd_rgst.selectedRows > 1) {
- messageBox("행 이동은 단일 행 선택시만 가능합니다.", "E999");
- return;
- }
- fMoveTerm(1);
- ]]>
- </script>
- </button>
- <caption id="caption4" class="cell_1" style="left:625px; top:630px; width:58px; height:105px; text-align:left; ">제어설명</caption>
- <textarea id="tar_rgstdesc" ref="/root/send/rgst/ctrldesc" scroll="autovscroll" maxbyte="4000" style="left:684px; top:630px; width:510px; height:105px; padding:5; "/>
- <caption id="caption14" class="tit_2" style="left:0px; top:325px; width:142px; height:13px; font-weight:bold; ">
- <![CDATA[제어문 등록 & 수정]]>
- </caption>
- <group id="group2" style="left:0px; top:392px; width:615px; height:368px; background-color:#fffbf2; border-color:#ffd799; border-style:solid; ">
- <caption id="cap_valnm" ref="/root/temp/term/valnm" style="left:209px; top:337px; width:275px; height:20px; text-align:center; background-color:#ffffa0; border-color:#999999; border-style:solid; "/>
- <group id="grp_qry" style="left:409px; top:179px; width:195px; height:150px; background-color:#fffbf2; border-color:#c0c0c0; border-style:solid; ">
- <select id="chk_qry" ref="/root/hidden/valtype/qryyn" disabled="true" overflow="visible" appearance="full" style="left:5px; top:5px; width:70px; height:20px; border-style:none; ">
- <choices>
- <item>
- <label>질의 항목</label>
- <value>Y</value>
- </item>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- fSetTypeChk("Q", chk_qry.value);
- ]]>
- </script>
- </select>
- <datagrid id="grd_qry" nodeset="/root/temp/qrylist/qryinfo" visibility="hidden" allowselection="false" autoresize="true" backcoloralternate="transparent" caption="acqid^구분^itemseq^itemid^항목" colsep="^" colwidth="0, 80, 0, 0, 100" extendlastcol="scroll" mergecellsfixedrows="bycolrec" rowsep="|" style="left:4px; top:25px; width:185px; height:119px; ">
- <col ref="acqid" visibility="hidden"/>
- <col ref="acqnm"/>
- <col ref="itemseq" visibility="hidden"/>
- <col ref="itemid" visibility="hidden"/>
- <col ref="itemnm"/>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
-
- if (!grd_qry.isCell(event.target)) {
- return;
- }
-
- model.setValue("/root/temp/term/valseq", grd_qry.valueMatrix(grd_qry.row, grd_qry.colRef("itemseq")));
- model.setValue("/root/temp/term/val", grd_qry.valueMatrix(grd_qry.row, grd_qry.colRef("itemid")));
- model.setValue("/root/temp/term/valnm", grd_qry.valueMatrix(grd_qry.row, grd_qry.colRef("itemnm")));
- cap_valnm.hint = model.getValue("/root/temp/term/valnm");
- cap_valnm.refresh();
-
- model.setValue("/root/temp/addval", "");
- ipt_addval.refresh();
- ]]>
- </script>
- </datagrid>
- </group>
- <group id="grp_drct" style="left:209px; top:29px; width:195px; height:50px; background-color:#fffbf2; border-color:#c0c0c0; border-style:solid; ">
- <select id="chk_drct" ref="/root/hidden/valtype/drctyn" disabled="true" overflow="visible" appearance="full" style="left:5px; top:5px; width:75px; height:20px; border-style:none; ">
- <choices>
- <item>
- <label>직접 입력</label>
- <value>Y</value>
- </item>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- fSetTypeChk("D", chk_drct.value);
- ]]>
- </script>
- </select>
- <input id="ipt_drct" ref="/root/temp/iptval/valnm" visibility="hidden" style="left:5px; top:25px; width:184px; height:19px; ">
- <script type="javascript" ev:event="onkeyup">
- <![CDATA[
- if (event.keyCode == "13") {
- model.setValue("/root/temp/iptval/valnm", ipt_drct.currentText);
- ipt_drct.refresh();
- btn_drctipt.dispatch("DOMActivate");
- }
- ]]>
- </script>
- </input>
- <button id="btn_drctipt" class="btn2_letter2" visibility="hidden" style="left:147px; top:4px; width:42px; height:19px; ">
- <caption>입력</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
-
- var val = model.getValue("/root/temp/iptval/valnm");
-
- model.setValue("/root/temp/iptval/val", val);
-
- model.setValue("/root/temp/term/val", val);
- model.setValue("/root/temp/term/valnm", val);
-
- model.setValue("/root/temp/iptval/val", "");
- model.setValue("/root/temp/iptval/valnm", "");
- ipt_drct.hint = "";
- ipt_drct.refresh();
-
- cap_valnm.hint = model.getValue("/root/temp/term/valnm");
- cap_valnm.refresh();
-
- model.setValue("/root/temp/addval", "");
- ipt_addval.refresh();
-
- grp_drctex.visible = false;
- ]]>
- </script>
- </button>
- <button id="btn_drctex" class="btn2_letter2" visibility="hidden" style="left:80px; top:4px; width:42px; height:19px; ">
- <caption>확장</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- grp_drctex.visible = true;
- ]]>
- </script>
- </button>
- </group>
- <datagrid id="grd_item" allowselection="false" backcoloralternate="transparent" colsep="^" colwidth="0, 0, 0, 0, 0, 0, 0, 0, 100" extendlastcol="scroll" mergecellsfixedrows="bycolrec" rowsep="|" style="left:9px; top:84px; width:115px; height:245px; ">
- <col ref="itemtype" visibility="hidden"/>
- <col ref="itemseq" visibility="hidden"/>
- <col ref="itemid" visibility="hidden"/>
- <col ref="valtype" visibility="hidden"/>
- <col ref="acqid" visibility="hidden"/>
- <col ref="addflag" visibility="hidden"/>
- <col ref="acqidarr" visibility="hidden"/>
- <col ref="acqnmarr" visibility="hidden"/>
- <col ref="itemnm"/>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
-
- if (!grd_item.isCell(event.target)) {
- return;
- }
-
- // 조건 값 초기화
- model.resetInstanceNode("/root/temp/qrylist/qryinfo");
- grd_qry.refresh();
-
- model.setValue("/root/temp/addval", "");
- ipt_addval.refresh();
-
- model.setValue("/root/temp/iptval/val", "");
- model.setValue("/root/temp/iptval/valnm", "");
- ipt_drct.refresh();
-
- model.setValue("/root/temp/enumval/val", "");
- model.setValue("/root/temp/enumval/valnm", "");
- model.resetInstanceNode("/root/temp/enumlist/enuminfo");
- rdo_enum.refresh();
- chk_enumarr.refresh();
-
- model.resetInstanceNode("/root/temp/srchlist/srchinfo");
- grd_srch.refresh();
-
- model.resetInstanceNode("/root/temp/term");
-
- cap_opnm.refresh();
- cap_valnm.refresh();
-
- var row = grd_item.row;
-
- model.setValue("/root/temp/term/itemtype", grd_item.valueMatrix(row, grd_item.colRef("itemtype")));
- model.setValue("/root/temp/term/itemseq", grd_item.valueMatrix(row, grd_item.colRef("itemseq")));
- model.setValue("/root/temp/term/itemnm", grd_item.valueMatrix(row, grd_item.colRef("itemnm")));
- model.setValue("/root/temp/term/acqid", grd_item.valueMatrix(row, grd_item.colRef("acqid")));
-
- cap_item.refresh();
-
- // 값 형식 설정
- var valtype = grd_item.valueMatrix(row, grd_item.colRef("valtype"));
- fSetValType(valtype);
-
- // 가산 여부 저장
- model.setValue("/root/hidden/addflag", grd_item.valueMatrix(row, grd_item.colRef("addflag")));
-
- // 참조 및 열거형 값목록 세팅
- model.resetInstanceNode("/root/temp/qrylist/qryinfo");
- model.resetInstanceNode("/root/temp/enumlist/enuminfo");
-
- var cnt = instance1.selectNodes("/root/main/itemlist/iteminfo").length;
-
- var acqidarr = grd_item.valueMatrix(row, grd_item.colRef("acqidarr")).split(",");
- var acqnmarr = grd_item.valueMatrix(row, grd_item.colRef("acqnmarr")).split(",");
-
- var eidx = 1;
- var qidx = 1;
-
- for (var i = 0; i < acqidarr.length; i++) {
-
- for (var j = 1; j <= cnt; j++) {
-
- var acqid = acqidarr[i];
- var acqnm = acqnmarr[i];
-
- if (model.getValue("/root/main/itemlist/iteminfo[" + j + "]/acqid") == acqid) {
-
- var path = "/root/main/itemlist/iteminfo[" + j + "]/";
- var itemtype = model.getValue(path + "itemtype");
-
- if (itemtype == "E") {
-
- model.makeValue("/root/temp/enumlist/enuminfo[" + eidx + "]/itemseq", model.getValue(path + "itemseq"));
- model.makeValue("/root/temp/enumlist/enuminfo[" + eidx + "]/itemnm", model.getValue(path + "itemnm"));
- eidx++;
-
- } else if (itemtype == "Q") {
-
- model.makeValue("/root/temp/qrylist/qryinfo[" + qidx + "]/acqid", acqid);
- model.makeValue("/root/temp/qrylist/qryinfo[" + qidx + "]/acqnm", acqnm);
- model.makeValue("/root/temp/qrylist/qryinfo[" + qidx + "]/itemseq", model.getValue(path + "itemseq"));
- model.makeValue("/root/temp/qrylist/qryinfo[" + qidx + "]/itemid", model.getValue(path + "itemid"));
- model.makeValue("/root/temp/qrylist/qryinfo[" + qidx + "]/itemnm", model.getValue(path + "itemnm"));
- qidx++;
- }
- }
- }
- }
-
- grd_qry.refresh();
- rdo_enum.refresh();
- chk_enumarr.refresh();
-
- // 첫번째 연산 항목 선택
- grd_opcode.row = 0;
- model.setValue("/root/temp/term/opcode", grd_opcode.valueMatrix(0, grd_opcode.colRef("cd")));
- model.setValue("/root/temp/term/opnm", grd_opcode.valueMatrix(0, grd_opcode.colRef("nm")));
- cap_opnm.refresh();
-
- ]]>
- </script>
- </datagrid>
- <caption id="cap_opnm" ref="/root/temp/term/opnm" style="left:134px; top:337px; width:65px; height:20px; text-align:center; background-color:#ffffa0; border-color:#999999; border-style:solid; "/>
- <caption id="cap_item" ref="/root/temp/term/itemnm" style="left:9px; top:337px; width:115px; height:20px; text-align:center; background-color:#ffffa0; border-color:#999999; border-style:solid; "/>
- <datagrid id="grd_opcode" allowselection="false" backcoloralternate="transparent" colsep="^" colwidth="0, 50" extendlastcol="scroll" mergecellsfixedrows="bycolrec" rowsep="|" style="left:134px; top:29px; width:65px; height:300px; ">
- <col ref="cd" visibility="hidden"/>
- <col ref="nm" style="text-align:center; "/>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
-
- if (!grd_opcode.isCell(event.target)) {
- return;
- }
-
- var valtype = grd_item.valueMatrix(grd_item.row, grd_item.colRef("valtype"))
-
- var opcode = grd_opcode.valueMatrix(grd_opcode.row, grd_opcode.colRef("cd"));
-
- model.setValue("/root/temp/term/opcode", opcode);
- model.setValue("/root/temp/term/opnm", grd_opcode.valueMatrix(grd_opcode.row, grd_opcode.colRef("nm")));
- cap_opnm.refresh();
-
- // 열거형 타입이 있는 경우, 연산자에 따라 Radio, Check 변경
- if (valtype.indexOf("E") >= 0) {
-
- var chkyn = model.getValue("/root/hidden/valtype/enumyn");
-
- if (opcode == "IN" || opcode == "NI") {
-
- chk_enumarr.visible = chkyn == "Y" ? true : false;
- rdo_enum.visible = false;
-
- } else {
-
- var val = model.getValue("/root/temp/enumval/val");
- if (val.length > 0) {
- val = val.split(" ")[0];
-
- var valnm = model.getValue("/root/main/itemlist/iteminfo[itemseq = '" + val + "']/itemnm");
-
- model.setValue("/root/temp/enumval/val", val);
- model.setValue("/root/temp/enumval/valnm", valnm);
- rdo_enum.refresh();
- chk_enumarr.refresh();
-
- model.setValue("/root/temp/term/val", val);
- model.setValue("/root/temp/term/valnm", valnm);
- cap_valnm.refresh();
- }
-
- chk_enumarr.visible = false;
- rdo_enum.visible = chkyn == "Y" ? true : false;
- }
- } else {
-
- }
- ]]>
- </script>
- </datagrid>
- <group id="grp_enum" style="left:409px; top:29px; width:195px; height:145px; background-color:#fffbf2; border-color:#c0c0c0; border-style:solid; ">
- <select id="chk_enum" ref="/root/hidden/valtype/enumyn" disabled="true" overflow="visible" appearance="full" style="left:5px; top:5px; width:70px; height:20px; border-style:none; ">
- <choices>
- <item>
- <label>열거 항목</label>
- <value>Y</value>
- </item>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- fSetTypeChk("E", chk_enum.value);
- ]]>
- </script>
- </select>
- <select1 id="rdo_enum" ref="/root/temp/enumval/val" visibility="hidden" appearance="full" cols="1" rows="100" vcellspacing="5" overflow="scroll" style="left:9px; top:25px; width:175px; height:114px; ">
- <choices>
- <itemset nodeset="/root/temp/enumlist/enuminfo">
- <label ref="itemnm"/>
- <value ref="itemseq"/>
- </itemset>
- </choices>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
- var itemid = model.getValue("/root/main/itemlist/iteminfo[itemseq = '" + rdo_enum.value + "']/itemid");
-
- model.setValue("/root/temp/term/valseq", rdo_enum.value);
- model.setValue("/root/temp/term/val", itemid);
- model.setValue("/root/temp/term/valnm", rdo_enum.label);
- cap_valnm.hint = model.getValue("/root/temp/term/valnm");
- cap_valnm.refresh();
-
- model.setValue("/root/temp/addval", "");
- ipt_addval.refresh();
- ]]>
- </script>
- </select1>
- <select id="chk_enumarr" ref="/root/temp/enumval/val" visibility="hidden" overflow="scroll" appearance="full" cols="1" rows="100" vcellspacing="5" style="left:9px; top:79px; width:175px; height:60px; border-style:none; ">
- <choices>
- <itemset nodeset="/root/temp/enumlist/enuminfo">
- <label ref="itemnm"/>
- <value ref="itemseq"/>
- </itemset>
- </choices>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
-
- var seqarr = model.getValue("/root/temp/enumval/val").split(" ");
-
- var valseq = "";
- var val = "";
- var valnm = "";
-
- for (var i = 0; i < seqarr.length; i++) {
-
- valseq += seqarr[i];
- val += model.getValue("/root/main/itemlist/iteminfo[itemseq = '" + seqarr[i] + "']/itemid");
- valnm += model.getValue("/root/main/itemlist/iteminfo[itemseq = '" + seqarr[i] + "']/itemnm");
-
- if (i < seqarr.length - 1) {
- valseq += ",";
- val += ",";
- valnm += ",";
- }
- }
-
- model.setValue("/root/temp/term/valseq", valseq);
- model.setValue("/root/temp/term/val", val);
- model.setValue("/root/temp/term/valnm", valnm);
- cap_valnm.hint = model.getValue("/root/temp/term/valnm");
- cap_valnm.refresh();
-
- model.setValue("/root/temp/addval", "");
- ipt_addval.refresh();
- ]]>
- </script>
- </select>
- </group>
- <caption id="caption5" class="tit_2" style="left:134px; top:9px; width:51px; height:13px; ">연산</caption>
- <caption id="caption6" class="tit_2" style="left:209px; top:9px; width:39px; height:13px; ">값</caption>
- <caption id="caption16" class="tit_2" style="left:9px; top:64px; width:74px; height:13px; ">항목</caption>
- <caption id="cap_grid" class="tit_2" style="left:9px; top:9px; width:49px; height:13px; ">구분</caption>
- <button id="btn_add" class="btn2_letter2" style="left:562px; top:337px; width:42px; height:19px; background-image:../../../com/commonweb/images/btn1_letter2.gif; ">
- <caption>추가</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
-
- if (model.getValue("/root/temp/term/itemseq") == "") {
- messageBox("항목이 설정되지 않았습니다.", "E999");
- return;
- }
-
- if (model.getValue("/root/temp/term/itemtype") != "C") {
- if ( model.getValue("/root/temp/term/opcode") == "") {
- messageBox("연산자가 설정되지 않았습니다.", "E999");
- return;
- }
-
- if (model.getValue("/root/temp/term/valnm") == "") {
- messageBox("값이 설정되지 않았습니다.", "E999");
- return;
- }
- }
-
- var idx = instance1.selectNodes("/root/send/rgst/termlist/terminfo[termseq != '']").length + 1;
-
- var opcode = model.getValue("/root/temp/term/opcode");
-
- var cnt = 0;
-
- if (opcode == "IN" || opcode == "NI") {
-
- var inflag = "";
- var inflagdp = "";
-
- var valtype = model.getValue("/root/temp/term/valtype");
-
- if (valtype == "D") { // 직접
-
- var val = model.getValue("/root/temp/term/val");
-
- if (val.indexOf(",") > 0) {
-
- var valarr = val.split(",");
-
- for (var i = 0; i < valarr.length; i++) {
-
- if (i == 0) {
- inflag = "B";
- inflagdp = "┌ ";
- } else if (i == valarr.length - 1) {
- inflag = "E";
- inflagdp = "└ ";
- } else {
- inflag = "I";
- inflagdp = "│ ";
- }
-
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/ctrlseq", model.getValue("/root/temp/term/ctrlseq"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/termseq", idx);
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/itemtype", model.getValue("/root/temp/term/itemtype"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/itemseq", model.getValue("/root/temp/term/itemseq"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/itemnm", model.getValue("/root/temp/term/itemnm"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/opcode", opcode);
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/valtype", model.getValue("/root/temp/term/valtype"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/valseq", "");
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/val", valarr[i]);
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/valnm", valarr[i]);
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/invalnm", inflagdp + valarr[i]);
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/inflag", inflag);
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/aoflag", "O");
-
- idx++;
- }
- }
-
- } else if (valtype == "E") { // 열거
-
- var valseqarr = model.getValue("/root/temp/term/valseq").split(",");
- var valarr = model.getValue("/root/temp/term/val").split(",");
- var valnmarr = model.getValue("/root/temp/term/valnm").split(",");
-
- for (var i = 0; i < valseqarr.length; i++) {
-
- if (i == 0) {
- inflag = "B";
- inflagdp = "┌ ";
- } else if (i == valseqarr.length - 1) {
- inflag = "E";
- inflagdp = "└ ";
- } else {
- inflag = "I";
- inflagdp = "│ ";
- }
-
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/ctrlseq", model.getValue("/root/temp/term/ctrlseq"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/termseq", idx);
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/itemtype", model.getValue("/root/temp/term/itemtype"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/itemseq", model.getValue("/root/temp/term/itemseq"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/itemnm", model.getValue("/root/temp/term/itemnm"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/opcode", opcode);
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/valtype", model.getValue("/root/temp/term/valtype"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/valseq", valseqarr[i]);
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/val", valarr[i]);
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/valnm", valnmarr[i]);
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/invalnm", inflagdp + valnmarr[i]);
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/inflag", inflag);
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/aoflag", "O");
-
- idx++;
- }
-
- } else if (valtype == "S") { // 조회
-
- cnt = instance1.selectNodes("/root/temp/srchlist/srchinfo").length;
-
- // 이내, 혹은 이외 이지만 건수가 1개밖에 없을 경우, 일치 혹은 불일치로 변경
- if (cnt == 1) {
- if (opcode == "IN") {
- opcode = "EQ";
- } else if (opcode == "NI") {
- opcode = "NE";
- }
- }
-
- for (var i = 1; i <= cnt; i++) {
-
- if (cnt > 1 && i == 1) {
- inflag = "B";
- inflagdp = "┌ ";
- } else if (cnt > 1 && i == cnt) {
- inflag = "E";
- inflagdp = "└ ";
- } else {
- inflag = "I";
- inflagdp = "│ ";
- }
-
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/ctrlseq", model.getValue("/root/temp/term/ctrlseq"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/termseq", idx);
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/itemtype", model.getValue("/root/temp/term/itemtype"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/itemseq", model.getValue("/root/temp/term/itemseq"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/itemnm", model.getValue("/root/temp/term/itemnm"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/opcode", opcode);
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/valtype", model.getValue("/root/temp/term/valtype"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/valseq", "");
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/val", model.getValue("/root/temp/srchlist/srchinfo[" + i + "]/val"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/valnm", model.getValue("/root/temp/srchlist/srchinfo[" + i + "]/valnm"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/invalnm", inflagdp + model.getValue("/root/temp/srchlist/srchinfo[" + i + "]/valnm"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/inflag", inflag);
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/aoflag", "O");
-
- idx++;
- }
- }
- } else {
-
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/ctrlseq", model.getValue("/root/temp/term/ctrlseq"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/termseq", idx);
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/itemtype", model.getValue("/root/temp/term/itemtype"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/itemseq", model.getValue("/root/temp/term/itemseq"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/itemnm", model.getValue("/root/temp/term/itemnm"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/opcode", opcode);
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/valtype", model.getValue("/root/temp/term/valtype"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/valseq", model.getValue("/root/temp/term/valseq"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/val", model.getValue("/root/temp/term/val"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/valnm", model.getValue("/root/temp/term/valnm"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/invalnm", model.getValue("/root/temp/term/valnm"));
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/inflag", "");
- model.makeValue("/root/send/rgst/termlist/terminfo[" + idx + "]/aoflag", "");
- }
-
- grd_rgst.refresh();
-
- cnt = instance1.selectNodes("/root/send/rgst/termlist/terminfo").length;
- for (var i = 1; i <= cnt; i++) {
- grd_rgst.tooltipText(i, grd_rgst.colRef("invalnm")) = model.getValue("/root/send/rgst/termlist/terminfo[" + i + "]/valnm");
- }
-
- grd_rgst.row = grd_rgst.rows - 1;
- grd_rgst.bottomRow = grd_rgst.rows - 1;
-
- fClearValues();
- ]]>
- </script>
- </button>
- <select1 id="rdo_itemtype" ref="/root/temp/term/itemtype" appearance="full" cellspacing="5" cols="2" overflow="visible" style="left:9px; top:29px; width:100px; height:20px; border-style:none; ">
- <choices>
- <itemset nodeset="/root/init/itemtype/typeinfo">
- <label ref="nm"/>
- <value ref="cd"/>
- </itemset>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- var itemtype = model.getValue("/root/temp/term/itemtype");
-
- grd_item.nodeset = "/root/main/itemlist/iteminfo[itemtype = '" + itemtype + "']";
-
- // 항목 및 연산 코드 설정
- model.setValue("/root/temp/term/opcode", "");
- if (itemtype == "R") {
- grd_opcode.nodeset = "/root/init/opcode/cdinfo";
- } else {
- grd_opcode.nodeset = "/";
- }
-
- // 값 형식 초기화
- fSetValType("");
-
- ]]>
- </script>
- </select1>
- <group id="grp_srch" style="left:209px; top:84px; width:195px; height:185px; background-color:#fffbf2; border-color:#c0c0c0; border-style:solid; ">
- <select id="chk_srch" ref="/root/hidden/valtype/srchyn" disabled="true" overflow="visible" appearance="full" style="left:5px; top:5px; width:70px; height:20px; border-style:none; ">
- <choices>
- <item>
- <label>조회 입력</label>
- <value>Y</value>
- </item>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- fSetTypeChk("S", chk_srch.value);
- ]]>
- </script>
- </select>
- <button id="btn_srch" class="icon_search" visibility="hidden" style="left:79px; top:6px; width:16px; height:16px; ">
- <caption/>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- setParameter("SPPEA00202_srchcd", model.getValue("/root/temp/term/acqid"));
- setParameter("SPPEA00202_opcode", model.getValue("/root/temp/term/opcode"));
- setParameter("SPPEA00202_suppdeptcd", model.getValue("/root/send/rgst/suppdeptcd"));
- modal("SPPEA00202");
-
- grd_srch.refresh();
- grd_srch.resizeCells();
-
- var cnt = instance1.selectNodes("/root/temp/srchlist/srchinfo").length;
-
- if (model.getValue("/root/temp/term/opcode") != "IN" &&
- model.getValue("/root/temp/term/opcode") != "NI" &&
- cnt > 1) {
-
- messageBox("2개 이상의 조회 항목은 연산을 [이내], 혹은 [이외]로 지정해햐 합니다.", "E999");
- return;
- }
-
- ]]>
- </script>
- </button>
- <button id="btn_srchipt" class="btn2_letter2" visibility="hidden" style="left:147px; top:4px; width:42px; height:19px; ">
- <caption>입력</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
-
- var cnt = instance1.selectNodes("/root/temp/srchlist/srchinfo").length;
-
- if (cnt < 1) {
- return;
- }
-
- if (model.getValue("/root/temp/term/opcode") != "IN" &&
- model.getValue("/root/temp/term/opcode") != "NI" &&
- cnt > 1) {
-
- messageBox("2개 이상의 조회 항목은 연산을 [이내], 혹은 [이외]로 지정해햐 합니다.", "E999");
- return;
- }
-
- var valnm = model.getValue("/root/temp/srchlist/srchinfo/valnm");
-
- if (cnt > 1) {
- valnm += " 외 " + ( cnt - 1 ) + " 건";
- }
-
- model.setValue("/root/temp/term/val", model.getValue("/root/temp/srchlist/srchinfo/val"));
- model.setValue("/root/temp/term/valnm", valnm);
-
- cap_valnm.hint = model.getValue("/root/temp/term/valnm");
- cap_valnm.refresh();
-
- model.setValue("/root/temp/addval", "");
- ipt_addval.refresh();
-
- ]]>
- </script>
- </button>
- <datagrid id="grd_srch" nodeset="/root/temp/srchlist/srchinfo" visibility="hidden" autoresize="true" colsep="^" colwidth="0, 150" extendlastcol="scroll" mergecellsfixedrows="bycolrec" rowheader="seq" rowsep="|" style="left:4px; top:25px; width:184px; height:154px; ">
- <col ref="val"/>
- <col ref="valnm"/>
- </datagrid>
- <button id="btn_delsrch" class="btn2_letter2" visibility="hidden" style="left:104px; top:4px; width:42px; height:19px; ">
- <caption>삭제</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- grd_srch.deleteRow(grd_srch.row, true);
- ]]>
- </script>
- </button>
- </group>
- <group id="grp_ref" style="left:209px; top:279px; width:195px; height:50px; background-color:#fffbf2; border-color:#c0c0c0; border-style:solid; ">
- <select id="chk_ref" ref="/root/hidden/valtype/refyn" disabled="true" overflow="visible" appearance="full" style="left:5px; top:5px; width:70px; height:20px; border-style:none; ">
- <choices>
- <item>
- <label>참조 항목</label>
- <value>Y</value>
- </item>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- fSetTypeChk("R", chk_ref.value);
- ]]>
- </script>
- </select>
- <button id="btn_refipt" class="btn2_letter2" visibility="hidden" style="left:147px; top:4px; width:42px; height:19px; ">
- <caption>입력</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
-
- model.setValue("/root/temp/term/val", model.getValue("/root/temp/refval/val"));
- model.setValue("/root/temp/term/valnm", cmb_ref.label);
-
- cap_valnm.hint = model.getValue("/root/temp/term/valnm");
- cap_valnm.refresh();
-
- model.setValue("/root/temp/addval", "");
- ipt_addval.refresh();
-
- ]]>
- </script>
- </button>
- <select1 id="cmb_ref" ref="/root/temp/refval/val" visibility="hidden" appearance="minimal" style="left:5px; top:25px; width:184px; height:19px; ">
- <choices>
- <itemset nodeset="/root/main/itemlist/iteminfo[itemtype = 'R']">
- <label ref="itemnm"/>
- <value ref="itemid"/>
- </itemset>
- </choices>
- </select1>
- </group>
- <caption id="cap_addval" style="left:489px; top:339px; width:25px; height:15px; ">+/-</caption>
- <input id="ipt_addval" ref="/root/temp/addval" disabled="true" style="left:514px; top:337px; width:40px; height:19px; ">
- <script type="javascript" ev:event="onkeyup">
- <![CDATA[
- if (event.keyCode == "13") {
-
- if (model.getValue("/root/temp/addval") != "") {
- messageBox("이미 가산 항목이 입력되었습니다.\n항목을 다시 선택한 후 입력해 주십시오.", "E999");
- return;
- }
-
- var val = ipt_addval.currentText;
-
- model.setValue("/root/temp/addval", val);
- ipt_addval.refresh();
-
- var iVal = parseInt(val);
-
- if (String(iVal) == "NaN") {
- messageBox("가산 값은 숫자만 입력할 수 있습니다.", "E999");
- model.setValue("/root/temp/addval", "");
- ipt_addval.refresh();
- model.setFocus("ipt_addval");
- return;
- }
-
- if (iVal >= 0) {
- val = " +" + val;
- } else {
- val = " " + val;
- }
-
-
-
- model.setValue("/root/temp/term/val", model.getValue("/root/temp/term/val") + val);
- model.setValue("/root/temp/term/valnm", model.getValue("/root/temp/term/valnm") + val);
- cap_valnm.hint = model.getValue("/root/temp/term/valnm");
- cap_valnm.refresh();
- }
- ]]>
- </script>
- </input>
- </group>
- <caption id="cap_status" style="left:504px; top:323px; width:31px; height:15px; font-weight:bold; text-align:left; vertical-align:middle; ">등록</caption>
- <caption id="caption18" style="left:469px; top:323px; width:35px; height:15px; ">상태 :</caption>
- <line id="line1" class="line_1" style="x1:0px; y1:85px; x2:1195px; y2:85px; "/>
- <line id="line2" class="line_1" style="x1:625px; y1:340px; x2:1195px; y2:340px; "/>
- <caption id="caption8" class="cell_1" style="left:625px; top:739px; width:58px; height:21px; text-align:left; ">적용기간</caption>
- <caption id="caption11" style="left:774px; top:743px; width:15px; height:15px; text-align:center; ">~</caption>
- <input id="ipt_fromdd" ref="/root/send/rgst/fromdd" inputtype="date" style="left:684px; top:740px; width:90px; height:19px; "/>
- <input id="ipt_todd" ref="/root/send/rgst/todd" inputtype="date" style="left:788px; top:740px; width:90px; height:19px; "/>
- <shape id="roundrect1" class="roundrect_search" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:20px; width:1195px; height:41px; background-color:#fffbf2; border-color:#ffd799; "/>
- <caption id="caption35" class="search_name" style="left:5px; top:33px; width:76px; height:17px; ">예약처 :</caption>
- <select1 id="cmb_rsrvplce" ref="/root/send/srch/rsrvplce" class="combo_search" navindex="1" appearance="minimal" style="left:83px; top:31px; width:55px; height:19px; ">
- <choices>
- <item>
- <label>전체</label>
- <value>A</value>
- </item>
- <item>
- <label>통합</label>
- <value>T</value>
- </item>
- <item>
- <label>입원</label>
- <value>I</value>
- </item>
- <item>
- <label>외래</label>
- <value>O</value>
- </item>
- <item>
- <label>건진</label>
- <value>S</value>
- </item>
- </choices>
- </select1>
- <caption id="caption1" class="search_name" style="left:150px; top:33px; width:86px; height:17px; ">수행부서 :</caption>
- <select1 id="cmb_deptcd" ref="/root/send/srch/suppdeptcd" class="combo_search" navindex="2" appearance="minimal" style="left:241px; top:31px; width:120px; height:19px; ">
- <choices>
- <itemset nodeset="/root/init/srch/deptlist/deptinfo">
- <label ref="deptnm"/>
- <value ref="deptcd"/>
- </itemset>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- var deptcd = model.getValue("/root/send/srch/suppdeptcd");
- cmb_roomcd.choices.itemset.attribute("nodeset") = "/root/init/srch/roomlist/roominfo[deptcd='" + deptcd + "' or roomcd='T']";
- cmb_roomcd.refresh();
- cmb_roomcd.select(0);
- ]]>
- </script>
- </select1>
- <caption id="caption2" class="search_name" style="left:376px; top:33px; width:74px; height:17px; ">검사실 :</caption>
- <select1 id="cmb_roomcd" ref="/root/send/srch/excuroomcd" class="combo_search" navindex="3" appearance="minimal" style="left:454px; top:31px; width:170px; height:19px; ">
- <choices>
- <itemset nodeset="/root/init/srch/roomlist/roominfo">
- <label ref="roomnm"/>
- <value ref="roomcd"/>
- </itemset>
- </choices>
- </select1>
- <caption id="caption3" class="search_name" style="left:805px; top:33px; width:20px; height:17px; "/>
- <button id="btn_search" class="btn1_letter2" navindex="6" style="left:1130px; top:30px; width:56px; height:22px; background-image:../../../com/commonweb/images/btn1_letter2.gif; ">
- <caption>조회</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- fSearchTerms();
- ]]>
- </script>
- </button>
- <line id="line13" style="x1:1120px; y1:30px; x2:1120px; y2:55px; border-color:#FFD799; border-left-style:solid; "/>
- <line id="line3" class="line_1" style="x1:0px; y1:340px; x2:615px; y2:340px; "/>
- <caption id="caption12" style="left:0px; top:347px; width:80px; height:20px; text-align:center; background-color:#cce8ff; ">예약처</caption>
- <select1 id="cmb_rgstplce" ref="/root/send/rgst/rsrvplce" appearance="minimal" style="left:0px; top:370px; width:80px; height:19px; background-color:#ffffa0; ">
- <choices>
- <item>
- <label>전체</label>
- <value>A</value>
- </item>
- <item>
- <label>통합</label>
- <value>T</value>
- </item>
- <item>
- <label>입원</label>
- <value>I</value>
- </item>
- <item>
- <label>외래</label>
- <value>O</value>
- </item>
- <item>
- <label>건진</label>
- <value>S</value>
- </item>
- </choices>
- </select1>
- <caption id="caption13" style="left:81px; top:347px; width:120px; height:20px; text-align:center; background-color:#cce8ff; ">수행부서</caption>
- <select1 id="cmb_rgstdept" ref="/root/send/rgst/suppdeptcd" appearance="minimal" style="left:81px; top:370px; width:120px; height:19px; background-color:#ffffa0; ">
- <choices>
- <itemset nodeset="/root/init/srch/deptlist/deptinfo">
- <label ref="deptnm"/>
- <value ref="deptcd"/>
- </itemset>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
-
- var deptcd = model.getValue("/root/send/rgst/suppdeptcd");
- cmb_rgstroom.choices.itemset.attribute("nodeset") = "/root/init/srch/roomlist/roominfo[deptcd='" + deptcd + "' or roomcd='T']";
- cmb_rgstroom.refresh();
- cmb_rgstroom.select(0);
-
- model.setValue("/root/send/srch/deptcd", model.getValue("/root/send/rgst/suppdeptcd"));
- model.setValue("/root/send/srch/roomcd", "T");
-
- submit("TRPEA00204", false);
- addComboItem("cmb_rgstexcd", "전체", "T");
- cmb_rgstexcd.select(0);
-
- ]]>
- </script>
- </select1>
- <caption id="caption15" style="left:202px; top:347px; width:120px; height:20px; text-align:center; background-color:#cce8ff; ">검사실</caption>
- <select1 id="cmb_rgstroom" ref="/root/send/rgst/excuroomcd" appearance="minimal" style="left:202px; top:370px; width:120px; height:19px; background-color:#ffffa0; ">
- <choices>
- <itemset nodeset="/root/init/srch/roomlist/roominfo">
- <label ref="roomnm"/>
- <value ref="roomcd"/>
- </itemset>
- </choices>
- </select1>
- <caption id="caption17" style="left:323px; top:347px; width:292px; height:20px; text-align:center; background-color:#cce8ff; ">검사명</caption>
- <select1 id="cmb_rgstexcd" ref="/root/send/rgst/excucd" appearance="minimal" style="left:323px; top:370px; width:292px; height:19px; background-color:#ffffa0; ">
- <choices>
- <itemset nodeset="/root/init/rgst/excdlist/excdinfo">
- <label ref="excunm"/>
- <value ref="excucd"/>
- </itemset>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- cmb_rgstexcd.hint = cmb_rgstexcd.label;
- ]]>
- </script>
- </select1>
- <button id="btn_expand" style="left:1061px; top:65px; width:26px; height:19px; background-image:../../../com/commonweb/images/btn_send_bottom.gif; ">
- <caption/>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
-
- if (btn_expand.attribute("background-image") == "../../../com/commonweb/images/btn_send_bottom.gif") {
- grd_ctrl.attribute("height") = "670px";
- btn_expand.attribute("background-image") = "../../../com/commonweb/images/btn_send_top.gif";
- } else {
- grd_ctrl.attribute("height") = "220px";
- btn_expand.attribute("background-image") = "../../../com/commonweb/images/btn_send_bottom.gif";
- }
-
-
- ]]>
- </script>
- </button>
- <line id="line4" class="line_3" style="x1:0px; y1:345px; x2:615px; y2:345px; "/>
- <line id="line5" class="line_3" style="x1:0px; y1:390px; x2:615px; y2:390px; "/>
- <line id="line6" class="line_3" style="x1:0px; y1:368px; x2:615px; y2:368px; "/>
- <button id="btn_excel" class="btn2_letter4" style="left:1131px; top:65px; width:64px; height:19px; ">
- <caption>엑셀저장</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- var filename = window.fileDialog("save", ",", false, "검사 예약 제어 정보", "xls", "Excel Files(*.xls)|*.xls|All Files (*.*)|*.*");
- grd_ctrl.saveExcel(filename, "sheetname:제어 내역;colhiddenextend:true;rowhiddenextend:false;");
- messageBox("엑셀 저장이 완료되었습니다.", "I999");
- ]]>
- </script>
- </button>
- <select1 id="radio1" ref="/root/hidden/aoflag" appearance="full" cellspacing="3" cols="2" overflow="visible" style="left:864px; top:322px; width:100px; height:15px; border-style:none; ">
- <choices>
- <item>
- <label>그리고</label>
- <value>A</value>
- </item>
- <item>
- <label>또는</label>
- <value>O</value>
- </item>
- </choices>
- </select1>
- <caption id="caption10" style="left:799px; top:323px; width:65px; height:15px; ">포괄 구분 :</caption>
- <button id="btn_include" class="btn2_letter4" style="left:969px; top:320px; width:64px; height:19px; ">
- <caption>포괄적용</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- if (grd_rgst.selectedRows < 2) {
- messageBox("포괄적용은 2개 이상의 행을 선택했을 때만 가능합니다.", "E999");
- return;
- }
-
- var cnt = grd_rgst.selectedRows;
- for (var i = 0; i < cnt; i++) {
-
- var row = grd_rgst.selectedRow(i);
-
- /*
- var opcode = model.getValue("/root/send/rgst/termlist/terminfo[" + row + "]/opcode");
- if (opcode == "IN" || opcode == "NI") {
- messageBox("선택된 항목 중 이내/이외 항목이 있습니다.\n이내/이외 항목은 포괄 적용에 포함될 수 없습니다.", "E999");
- return;
- }
- */
-
- var itemtype = model.getValue("/root/send/rgst/termlist/terminfo[" + row + "]/itemtype");
- if (itemtype == "C") {
- messageBox("선택된 항목 중 제어항이 있습니다.\n제어항은 포괄 적용에 포함될 수 없습니다.", "E999");
- return;
- }
- }
-
- // 기존 포괄 항목 체크
- var flag = true;
- var isfirst = true;
- var eqflag = true;
-
- for (var i = 0; i < cnt; i++) {
-
- var row = grd_rgst.selectedRow(i);
-
- var curflag = model.getValue("/root/send/rgst/termlist/terminfo[" + row + "]/inflag").substr(0, 1);
-
- if (curflag == "B") {
- flag = false;
- } else if (curflag == "E") {
- if (isfirst) {
- flag = false;
- break;
- } else {
- flag = !flag;
- }
- }
-
- isfirst = false;
-
- if (( i == 0 && curflag != "B" ) || ( i == cnt - 1 && curflag != "E" ) ||
- ( i > 0 && curflag == "B" ) || ( i < cnt - 1 && curflag == "E" )) {
- eqflag = false;
- }
- }
-
- if (!flag){
- messageBox("다중 포괄은 기존 포괄을 감싸는 영역을 지정해야 합니다.", "E999");
- return;
- }
-
- var inflag = "";
- var inflagdp = "";
- var invalnm = "";
-
- for (var i = 0; i < cnt; i++) {
-
- var row = grd_rgst.selectedRow(i);
-
- var aoflag = model.getValue("/root/hidden/aoflag");
- var aoflagdp = aoflag == "A" ? "&" : "";
- var prevaoflag = model.getValue("/root/send/rgst/termlist/terminfo[" + row + "]/aoflag");
-
- // 동일 영역 설정시 aoflag 만 변경함
- if (eqflag) {
-
- inflag = model.getValue("/root/send/rgst/termlist/terminfo[" + row + "]/inflag");
-
- aoflag += prevaoflag.substr(1, prevaoflag.length - 1);
- model.setValue("/root/send/rgst/termlist/terminfo[" + row + "]/aoflag", aoflag);
-
- invalnm = fGetInFlagName(inflag, aoflag) + model.getValue("/root/send/rgst/termlist/terminfo[" + row + "]/valnm");
- model.setValue("/root/send/rgst/termlist/terminfo[" + row + "]/invalnm", invalnm);
- continue;
- }
-
- aoflag += prevaoflag;
- model.setValue("/root/send/rgst/termlist/terminfo[" + row + "]/aoflag", aoflag);
-
- if (i == 0) {
- inflag = "B";
- inflagdp = "┌" + aoflagdp;
- } else if (i == cnt - 1) {
- inflag = "E";
- inflagdp = "└" + aoflagdp;
- } else {
- inflag = "I";
- inflagdp = "│" + aoflagdp;
- }
-
- // 안에서 밖으로 감싸나감
- inflag += model.getValue("/root/send/rgst/termlist/terminfo[" + row + "]/inflag");
- model.setValue("/root/send/rgst/termlist/terminfo[" + row + "]/inflag", inflag);
-
- invalnm = fGetInFlagName(inflag, aoflag) + model.getValue("/root/send/rgst/termlist/terminfo[" + row + "]/valnm");
- model.setValue("/root/send/rgst/termlist/terminfo[" + row + "]/invalnm", invalnm);
- }
-
- grd_rgst.refresh();
-
- cnt = instance1.selectNodes("/root/send/rgst/termlist/terminfo").length;
- for (var i = 1; i <= cnt; i++) {
- grd_rgst.tooltipText(i, grd_rgst.colRef("invalnm")) = model.getValue("/root/send/rgst/termlist/terminfo[" + i + "]/valnm");
- }
-
- ]]>
- </script>
- </button>
- <button id="btn_cnclinclude" class="btn2_letter4" style="left:1034px; top:320px; width:64px; height:19px; ">
- <caption>포괄해제</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- var cnt = grd_rgst.selectedRows;
- var flag = true;
- for (var i = 0; i < cnt; i++) {
-
- var row = grd_rgst.selectedRow(i);
-
- var inflag = model.getValue("/root/send/rgst/termlist/terminfo[" + row + "]/inflag").substr(0, 1);
-
- if (i == 0 && inflag != "B") {
- flag = false;
- break;
- }
-
- if (i == cnt - 1 && inflag != "E") {
- flag = false;
- break;
- }
-
- if (i > 0 && i < cnt - 1 && inflag != "I") {
- flag = false;
- break;
- }
-
- /*
- var opcode = model.getValue("/root/send/rgst/termlist/terminfo[" + row + "]/opcode");
- if (opcode == "IN" || opcode == "NI") {
- flag = false;
- break;
- }
- */
- }
-
- if (!flag) {
- messageBox("포괄 해제할 항목을 정확히 선택해 주십시오.", "E999");
- return;
- }
-
- for (var i = 0; i < cnt; i++) {
-
- var row = grd_rgst.selectedRow(i);
-
- var inflag = model.getValue("/root/send/rgst/termlist/terminfo[" + row + "]/inflag");
- inflag = inflag.length == 1 ? "" : inflag.substr(1, inflag.length - 1);
- model.setValue("/root/send/rgst/termlist/terminfo[" + row + "]/inflag", inflag);
-
- var aoflag = model.getValue("/root/send/rgst/termlist/terminfo[" + row + "]/aoflag");
- aoflag = aoflag.length == 1 ? "" : aoflag.substr(1, aoflag.length - 1);
- model.setValue("/root/send/rgst/termlist/terminfo[" + row + "]/aoflag", aoflag);
-
- var invalnm = fGetInFlagName(inflag, aoflag) + model.getValue("/root/send/rgst/termlist/terminfo[" + row + "]/valnm");
- model.setValue("/root/send/rgst/termlist/terminfo[" + row + "]/invalnm", invalnm);
- }
-
- grd_rgst.refresh();
-
- cnt = instance1.selectNodes("/root/send/rgst/termlist/terminfo").length;
- for (var i = 1; i <= cnt; i++) {
- grd_rgst.tooltipText(i, grd_rgst.colRef("invalnm")) = model.getValue("/root/send/rgst/termlist/terminfo[" + i + "]/valnm");
- }
-
- ]]>
- </script>
- </button>
- <datagrid id="grd_ctrl" nodeset="/root/main/ctrllist/ctrlinfo" allowselection="false" autoresize="true" backcoloralternate="transparent" caption="예약처^수행부서^수행부서^검사실^검사실^검사코드^검사명^순번^항수^설명^제어^적용시작일^적용종료일" colsep="^" colwidth="60, 0, 120, 0, 120, 0, 200, 40, 40, 370, 40, 80, 80" explorerbar="sort" extendlastcol="scroll" mergecellsfixedrows="bycolrec" rowheader="seq" rowsep="|" style="left:0px; top:90px; width:1195px; height:220px; ">
- <col disabled="true" ref="rsrvplce" type="combo" style="text-align:center; ">
- <choices>
- <item>
- <label>통합예약</label>
- <value>T</value>
- </item>
- <item>
- <label>병동</label>
- <value>I</value>
- </item>
- <item>
- <label>외래</label>
- <value>O</value>
- </item>
- <item>
- <label>전체</label>
- <value>A</value>
- </item>
- </choices>
- </col>
- <col ref="suppdeptcd"/>
- <col ref="suppdeptnm" style="text-align:center; "/>
- <col ref="excuroomcd"/>
- <col ref="excuroomnm" style="text-align:center; "/>
- <col ref="excucd"/>
- <col ref="excunm" style="text-align:center; "/>
- <col ref="ctrlseq" style="text-align:center; "/>
- <col ref="termcnt" style="text-align:center; "/>
- <col ref="ctrldesc"/>
- <col ref="ctrltype" style="text-align:center; "/>
- <col ref="fromdd" format="yyyy-mm-dd" style="text-align:center; "/>
- <col ref="todd" format="yyyy-mm-dd" style="text-align:center; "/>
- <script type="javascript" ev:event="ondblclick">
- <![CDATA[
- if (!grd_ctrl.isCell(event.target)) {
- return;
- }
-
- fSetTermInfo();
-
- fSetRgstStatus(false);
- ]]>
- </script>
- <script type="javascript" ev:event="onmousedown">
- <![CDATA[
- grd_ctrl.focusColor = "#ece1ec";
- ]]>
- </script>
- <script type="javascript" ev:event="onaftersort">
- <![CDATA[
- grd_ctrl.gridToInstance();
- grd_ctrl.resizeCells();
- ]]>
- </script>
- </datagrid>
- <caption id="caption19" class="search_name" style="left:638px; top:33px; width:61px; height:17px; ">제어 :</caption>
- <select1 id="cmb_ctrl" ref="/root/send/srch/itemseq" class="combo_search" appearance="minimal" style="left:703px; top:31px; width:90px; height:19px; ">
- <choices>
- <itemset nodeset="/root/init/srch/ctrllist/ctrlinfo">
- <label ref="itemnm"/>
- <value ref="itemseq"/>
- </itemset>
- </choices>
- </select1>
- <input id="ipt_srch" ref="/root/send/srch/srchstr" class="input_search" style="left:920px; top:31px; width:190px; height:19px; ">
- <script type="javascript" ev:event="onkeypress">
- <![CDATA[
- if(event.keyCode == "13") {
- inputEnterKey("btn_search", "DOMActivate");
- }
- ]]>
- </script>
- </input>
- <select1 id="cmb_srchflag" ref="/root/send/srch/srchflag" appearance="minimal" style="left:826px; top:31px; width:75px; height:19px; ">
- <choices>
- <item>
- <label>설명</label>
- <value>D</value>
- </item>
- <item>
- <label>검사명</label>
- <value>N</value>
- </item>
- <item>
- <label>검사코드</label>
- <value>C</value>
- </item>
- </choices>
- </select1>
- <caption id="caption20" style="left:906px; top:33px; width:10px; height:17px; font-weight:bold; text-align:center; ">:</caption>
- <group id="grp_drctex" visibility="hidden" style="left:210px; top:130px; width:395px; height:170px; background-color:#f0f0f0; border-color:#a0a0a0; border-width:1; border-style:solid; ">
- <textarea id="tar_drctex" ref="/root/temp/iptval/valnm" scroll="autovscroll" maxbyte="4000" style="left:9px; top:9px; width:375px; height:128px; padding:5; ">
- <script type="javascript" ev:event="onmaxlength">
- <![CDATA[
- messageBox("100 글자까지 입력 가능합니다.", "E999");
- ]]>
- </script>
- </textarea>
- <button id="btn_drctexclose" class="btn2_letter2" style="left:342px; top:143px; width:42px; height:19px; ">
- <caption>닫기</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- grp_drctex.visible = false;
- ]]>
- </script>
- </button>
- <button id="btn_drctexipt" class="btn2_letter2" style="left:295px; top:143px; width:42px; height:19px; ">
- <caption>입력</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- btn_drctipt.dispatch("DOMActivate");
- ]]>
- </script>
- </button>
- </group>
- <group id="grp_popup" visibility="hidden" style="left:710px; top:405px; width:395px; height:170px; background-color:#f0f0f0; border-color:#a0a0a0; border-width:1; border-style:solid; ">
- <textarea id="tar_popup" ref="/root/hidden/popup" scroll="autovscroll" maxbyte="4000" style="left:9px; top:9px; width:375px; height:128px; padding:5; "/>
- <button id="btn_popupclose" class="btn2_letter2" style="left:342px; top:143px; width:42px; height:19px; ">
- <caption>닫기</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- grp_popup.visible = false;
- model.setValue("/root/hidden/popup", "");
- tar_popup.refresh();
- ]]>
- </script>
- </button>
- <button id="btn_popupipt" class="btn2_letter2" style="left:295px; top:143px; width:42px; height:19px; ">
- <caption>입력</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- var msg = model.getValue("/root/hidden/popup");
- model.setValue("/root/send/rgst/termlist/terminfo[" + grd_rgst.row + "]/val", msg);
- model.setValue("/root/send/rgst/termlist/terminfo[" + grd_rgst.row + "]/valnm", msg);
-
- var inflag = model.getValue("/root/send/rgst/termlist/terminfo[" + grd_rgst.row + "]/inflag");
- var aoflag = model.getValue("/root/send/rgst/termlist/terminfo[" + grd_rgst.row + "]/aoflag");
-
- model.setValue("/root/send/rgst/termlist/terminfo[" + grd_rgst.row + "]/invalnm", fGetInFlagName(inflag, aoflag) + msg);
-
- grd_rgst.refresh();
-
- grp_popup.visible = false;
- model.setValue("/root/hidden/popup", "");
- tar_popup.refresh();
- ]]>
- </script>
- </button>
- </group>
- </xhtml:body>
- </xhtml:html>
|