12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237 |
- /*
-
- (SMMNR01000_수혈간호기록.xrw - JScript )
- - Version :
- 1) : Ver.1.00.01
- */
- var xTopAttributePath = "/root/main/topattribute";
- var xRecgrupListPath = "/root/main/recgrup/recgruplist";
- var xHIsgrupListPath = "/root/main/histgrup/histgruplist";
- var xRecHIstPntListPath = "/root/main/rechistpntgrup/rechistpntlist";
- var xClsListPath = "/root/main/detlgrup/detlgruplist"
- var xHIsgrupListBKPath = "/root/temp/histgrup/histgruplist";
- var xlrgListPath = "/root/main/lrggrup/lrggruplist"
- var xCondPath = "/root/main/cond";
- var xClsListBKPath = "/root/temp/main/detlgrup/detlgruplist";
- var xPopWndClsListBKPath = "/root/temp/main/cond/execpopwnddetlgrup/execpopwnddetlgruplist";
- var xExecDetlListPath = "/root/main/cond/execdetlgrup/execdetlgruplist";
- var xPopWndExecDetlListPath = "/root/main/cond/execpopwnddetlgrup/execpopwnddetlgruplist";
- var xDelDeliveExecPrcpListPath = "/root/main/cond/delivedetlgrup/delivedetlgruplist";
- var xBlodReturnReqGrupListPath = "/root/main/cond/blodreturnreqgrup/blodreturnreqgruplist";
- var xBlodExecRecGrupListPath = "/root/main/cond/blodexecrecgrup/blodexecrecgruplist";
- var xVitalSignPath = "/root/main/cond/vitalsigngrup/vitalsigngruplist";
- var xBlodNoRecPath = "/root/main/cond/blodnoexecrecgrup/blodnoexecrecgruplist";
- var ioparam = "" ;// 화면에서 넘어오는 파라메터 (절대 지우면 안됨)
- /**
- * @group :
- * @ver : 2007.07.16
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 수혈 수행 내역에서 더블클릭 했을때, vital sign 리스트
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fVitalSignList(){
- var iRow = datagrid3.row ;
- // alert(model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnscarerecseq"));
- model.removenode("/root/send");
- model.makeValue("/root/send/tnscarerecseq",model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnscarerecseq"));
- model.makeValue("/root/send/ioparam", ioparam);
- if(submit("TRMNR01025")){
- }
- }
- /**
- * @group :
- * @ver : 2007.09.27
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 바이탈싸인 행삭제
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fDelRow(){
- var iRow = datagrid4.row ;
- // alert(iRow);
- if(parseInt(iRow) < 4){
- messageBox("Vital Sign 기본정보는 삭제 ","E001");
- return;
- } else {
- datagrid4.deleteRow(iRow);
- }
-
- }
- /**
- * @group :
- * @ver : 2007.09.27
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 줄추가 버튼
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fAddSameLevlItemButton(){
- var iRows = datagrid4.rows;
- var iRow = datagrid4.row;
-
- if(iRows > 2) {
- // alert('2');
- datagrid4.insertRow(datagrid4.rows-datagrid4.fixedrows, "below");
- // var sRowCnt = grd_detlgrup.rows-grd_detlgrup.fixedrows;
- //
- // /* grupcd 현재 화면의 최대값 가져오기 시작 */
- //
- // var retVal = "" ;
- //
- // for(var i=2; i<= sRowCnt; i++){
- //// alert(model.getValue(xClsListPath+"["+i+"]/grupcd"));
- // if(model.getValue(xClsListPath+"["+i+"]/grupcd") ) {
- // saveyn = 1 ;
- // }
- //
- // retVal = Math.max(retVal,model.getValue(xClsListPath+"["+i+"]/grupcd"));
- //
- //// alert("retVal : " + retVal);
- //
- // }
- //
- // retVal = retVal + 1 ;
- //
- // retVal = String(retVal) ;
- //
- // retVal = fLpad(retVal,8,0);// grupcd 8자리 나머지는 0 으로 매꿈
- //
- // /* grupcd 현재 화면의 최대값 가져오기 끝 */
- //
- //// alert("retVal 22 : " + retVal);
- //
- // model.setValue(xClsListPath+"["+(grd_detlgrup.row-1)+"]/grupcd",retVal);
- //
- //// grd_detlgrup.merge();
- }
- // model.setValue(xClsListPath+"["+(grd_detlgrup.row-1)+"]/stat","I");
- //// model.setValue(xClsListPath+"["+(grd_detlgrup.row-1)+"]/grupcd","00000001");
- // model.setValue(xClsListPath+"["+(grd_detlgrup.row-1)+"]/genrdd",getCurrentDate());
- // model.setValue(xClsListPath+"["+(grd_detlgrup.row-1)+"]/genrtm",getCurrentDateTime().substring(9,13));
- // model.setValue(xClsListPath+"["+(grd_detlgrup.row-1)+"]/flag","등록");
- // model.setValue(xClsListPath+"["+(grd_detlgrup.row-1)+"]/recdd",getCurrentDate());
- // model.setValue(xClsListPath+"["+(grd_detlgrup.row-1)+"]/rectm",getCurrentDateTime().substring(9,13));
-
- }
- /**
- * @group :
- * @ver : 2007.05.09
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 참여자 정보 팝업 조회
- * @param : originalNode
- * @param : copyNode
- * @return : true/false
- * @---------------------------------------------------
- */
- function fClickUserBtn(userflag, seq, deptcd2, flag){
- // alert(deptcd2);
- var deptcd = "";
- var jobkindcd = "";
- var deptcd = "";
- if(userflag == "doctor"){
- deptcd = deptcd2;
- jobkindcd = "";
- }else if(userflag == "nurse"){
- deptcd = deptcd2;
- jobkindcd = "";
- }else{}
- setParameter("SPMNN02100_deptcd", deptcd);
- setParameter("SPMNN02100_jobkindcd", jobkindcd);
-
- modal("SPMNR02100");
-
- var userid = getParameter("SPMNN02100_userid");
- var usernm = getParameter("SPMNN02100_usernm");
- var posinstnm = getParameter("SPMNN02100_posinstnm");
- var posinstcd = getParameter("SPMNN02100_posinstcd");
- var posdeptnm = getParameter("SPMNN02100_posdeptnm");
- var posdeptcd = getParameter("SPMNN02100_posdeptcd");
- if(flag == "str"){
- model.setValue(output10.attribute("ref"), userid);// 저장할 데이터 생성
- model.setValue(output11.attribute("ref"), usernm);// 저장할 데이터 생성
- model.setValue(output12.attribute("ref"), userid+","+usernm+","+posinstnm+","+posinstcd+","+posdeptnm+","+posdeptcd);// 저장할 데이터 생성
- } else if(flag == "end"){
- model.setValue(output8.attribute("ref"), userid);// 저장할 데이터 생성
- model.setValue(output9.attribute("ref"), usernm);// 저장할 데이터 생성
- model.setValue(output13.attribute("ref"), userid+","+usernm+","+posinstnm+","+posinstcd+","+posdeptnm+","+posdeptcd);// 저장할 데이터 생성
- }
- model.refresh();
- // if(userid != ""){
- // model.setValue(xPartrtnEntrPath + "/entrid" + seq, userid);
- // model.setValue(xPartrtnEntrPath + "/entrnm" + seq, usernm);
- // model.setValue(xPartrtnEntrPath + "/status", "U");
- // model.refresh();
- // }
-
- setParameter("SPMNN02100_userid", "");
- setParameter("SPMNN02100_usernm", "");
- }
- /**
- * @group :
- * @ver : 2007.07.09
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 미수행기록 목록에서 선택항목 체크(더블클릭)
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fParam(getparam) {
- // alert("ioflag : "+opener.window.javascript.getParameter("ioflag"));
- // alert("pid : "+opener.window.javascript.getParameter("pid"));
- //
- // alert("getparam : "+getparam);
- // alert("session pid : "+getPatientInfo("pid"));
- var openernull = "" // 파마리터 null check
- var popvalue = "" ;
- var pidvalue = "" ;
- /* 메뉴 || 파라미터로 들어올때 체크 시작 */
- if( window.opener == null &&
- ( getparam == "IPRC1" || getparam == "IPRC2" || getparam == "OPRC1" || getparam == "OPRC2" ||
- getparam == "IPRC" || getparam == "OPRC") ) {//병동메인/주사에서 들어오지 않을때...
- openernull = 'Y';
- if(getparam == "OPRC1"){
- button1.selected = true;
- model.toggle("case1");
- getparam = "OPRC" ;
- ioparam = getparam ;
-
- if(getPatientInfo("pid") != null && getPatientInfo("pid") != "" ) {//상단정보가 있을때
- model.setValue(input3.attribute("ref"), getPatientInfo("pid") );//등록번호 화면에 셋팅
- model.setValue(input12.attribute("ref"), getPatientInfo("pid") );//등록번호 화면에 셋팅
- button3.dispatch("DOMActivate");
- }
- } else if(getparam == "OPRC2"){
- button2.selected = true;
- model.toggle("case2");
- getparam = "OPRC" ;
- ioparam = getparam ;
-
-
- if(getPatientInfo("pid") != null && getPatientInfo("pid") != "" ) {//상단정보가 있을때
- model.setValue(input3.attribute("ref"), getPatientInfo("pid") );//등록번호 화면에 셋팅
- model.setValue(input12.attribute("ref"), getPatientInfo("pid") );//등록번호 화면에 셋팅
- button16.dispatch("DOMActivate");
- }
- } else if(getparam == "IPRC1"){
- button1.selected = true;
- model.toggle("case1");
- getparam = "IPRC" ;
- ioparam = getparam ;
-
-
- if(getPatientInfo("pid") != null && getPatientInfo("pid") != "" ) {//상단정보가 있을때
- model.setValue(input3.attribute("ref"), getPatientInfo("pid") );//등록번호 화면에 셋팅
- model.setValue(input12.attribute("ref"), getPatientInfo("pid") );//등록번호 화면에 셋팅
- button3.dispatch("DOMActivate");
- }
- } else if(getparam == "IPRC2"){
- button2.selected = true;
- model.toggle("case2");
- getparam = "IPRC" ;
- ioparam = getparam ;
- if(getPatientInfo("pid") != null && getPatientInfo("pid") != "" ) {//상단정보가 있을때
- model.setValue(input3.attribute("ref"), getPatientInfo("pid") );//등록번호 화면에 셋팅
- model.setValue(input12.attribute("ref"), getPatientInfo("pid") );//등록번호 화면에 셋팅
- button16.dispatch("DOMActivate");
- }
- }
- // button1.selected = true;
- // model.toggle("case1");
- // getparam = "IPRC";
- } else if( window.opener != null && ( opener.window.javascript.getParameter("ioflag") == "IPRC1" ||
- opener.window.javascript.getParameter("ioflag") == "IPRC2" ||
- opener.window.javascript.getParameter("ioflag") == "OPRC1" ||
- opener.window.javascript.getParameter("ioflag") == "OPRC2" )
- ) {//병동메인/주사실메인에서 들어올때...
- popvalue = opener.window.javascript.getParameter("ioflag")
- pidvalue = opener.window.javascript.getParameter("pid")
- if( popvalue != null && popvalue != "" && pidvalue != null && pidvalue != "") {//플래그별 화면 case 선택
- if(popvalue == "OPRC1"){
- button1.selected = true;
- model.toggle("case1");
- getparam = "OPRC" ;
- ioparam = getparam ;
-
- model.setValue(input3.attribute("ref"), opener.window.javascript.getParameter("pid") );
- model.setValue(input12.attribute("ref"), opener.window.javascript.getParameter("pid") );
- button3.dispatch("DOMActivate");
- } else if(popvalue == "OPRC2"){
- button2.selected = true;
- model.toggle("case2");
- getparam = "OPRC" ;
- ioparam = getparam ;
-
- model.setValue(input3.attribute("ref"), opener.window.javascript.getParameter("pid") );
- model.setValue(input12.attribute("ref"), opener.window.javascript.getParameter("pid") );
- button16.dispatch("DOMActivate");
-
- } else if(popvalue == "IPRC1"){
- button1.selected = true;
- model.toggle("case1");
- getparam = "IPRC" ;
- ioparam = getparam ;
-
-
- model.setValue(input3.attribute("ref"), opener.window.javascript.getParameter("pid") );
- model.setValue(input12.attribute("ref"), opener.window.javascript.getParameter("pid") );
- button3.dispatch("DOMActivate");
-
- } else if(popvalue == "IPRC2"){
- button2.selected = true;
- model.toggle("case2");
- getparam = "IPRC" ;
- ioparam = getparam ;
-
- model.setValue(input3.attribute("ref"), opener.window.javascript.getParameter("pid") );
- model.setValue(input12.attribute("ref"), opener.window.javascript.getParameter("pid") );
- button16.dispatch("DOMActivate");
-
- }
- }
- } else if(
- ( getparam == "IPRC1" || getparam == "IPRC2" || getparam == "OPRC1" || getparam == "OPRC2" || getparam == "IPRC" || getparam == "OPRC")
- ) {// 메뉴에서 들어올때
- if(getparam == "OPRC1"){
- button1.selected = true;
- model.toggle("case1");
- getparam = "OPRC" ;
- ioparam = getparam ;
-
- if(getPatientInfo("pid") != null && getPatientInfo("pid") != "" ) {//상단정보가 있을때
- model.setValue(input3.attribute("ref"), getPatientInfo("pid") );//등록번호 화면에 셋팅
- model.setValue(input12.attribute("ref"), getPatientInfo("pid") );//등록번호 화면에 셋팅
- button3.dispatch("DOMActivate");
- }
- } else if(getparam == "OPRC2"){
- button2.selected = true;
- model.toggle("case2");
- getparam = "OPRC" ;
- ioparam = getparam ;
-
-
- if(getPatientInfo("pid") != null && getPatientInfo("pid") != "" ) {//상단정보가 있을때
- model.setValue(input3.attribute("ref"), getPatientInfo("pid") );//등록번호 화면에 셋팅
- model.setValue(input12.attribute("ref"), getPatientInfo("pid") );//등록번호 화면에 셋팅
- button16.dispatch("DOMActivate");
- }
-
- } else if(getparam == "IPRC1"){
- button1.selected = true;
- model.toggle("case1");
- getparam = "IPRC" ;
- ioparam = getparam ;
-
-
- if(getPatientInfo("pid") != null && getPatientInfo("pid") != "" ) {//상단정보가 있을때
- model.setValue(input3.attribute("ref"), getPatientInfo("pid") );//등록번호 화면에 셋팅
- model.setValue(input12.attribute("ref"), getPatientInfo("pid") );//등록번호 화면에 셋팅
- button3.dispatch("DOMActivate");
- }
-
- } else if(getparam == "IPRC2"){
- button2.selected = true;
- model.toggle("case2");
- getparam = "IPRC" ;
- ioparam = getparam ;
- if(getPatientInfo("pid") != null && getPatientInfo("pid") != "" ) {//상단정보가 있을때
- model.setValue(input3.attribute("ref"), getPatientInfo("pid") );//등록번호 화면에 셋팅
- model.setValue(input12.attribute("ref"), getPatientInfo("pid") );//등록번호 화면에 셋팅
- button16.dispatch("DOMActivate");
- }
-
- }
- } else if(getparam == "" || getparam == null ) {// 화면파라미터 없을때
- button1.selected = true;
- model.toggle("case1");
- getparam = "IPRC";
- } else {
- openernull = 'Y';
- getparam = "" ;
- }
- /* 메뉴 && 파라미터가 아닌 로컬이나 다른 값으로 들어올때 기본 셋팅값으로 시작 */
- if(getparam == "" && openernull == "Y"){
- // 화면파라미터/팝업파라미터 모두 없을때
- button1.selected = true;
- model.toggle("case1");
- getparam = "IPRC" ;
- }
- /* 메뉴 && 파라미터가 아닌 로컬이나 다른 값으로 들어올때 기본 셋팅값으로 끝 */
- /* 메뉴 || 파라미터가 외래일때 병동/병실/환자 리스트 disabled 시작 */
- if(getparam == "OPRC"){ // 외래일때, 병동/병실/환자 리스트 disabled
- combo5.disabled = true ;
- combo1.disabled = true ;
- combo6.disabled = true ;
- combo7.disabled = true ;
- combo2.disabled = true ;
- combo8.disabled = true ;
- }
- /* 메뉴 || 파라미터가 외래일때 병동/병실/환자 리스트 disabled 끝 */
- ioparam = getparam ;
- return getparam ;
- }
- /**
- * @group :
- * @ver : 2007.07.09
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 혈액요청취소 선택했을때...
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fBlodReqCancelDoc(){
- var sRowCnt = datagrid7.rows-datagrid7.fixedrows;
-
- var cnt = 0 ;
- model.removeNode ("/root/send/report");
- for(var i=1; i<= sRowCnt; i++){ // 선택한 값이 불출신청 상태인지 체크
- // alert(datagrid7.labelmatrix(i, 1));
- if( datagrid7.labelmatrix(i, 1) == "true" ) {
- cnt = cnt + 1;
- // if( datagrid7.labelmatrix(i, 2) != "혈액준비") {
- if( datagrid7.labelmatrix(i, 2) != "불출요청") {
-
- messageBox("불출요청 상태 이외에는 혈액요청취소를 ","E001");
- return;
-
- }
- if( datagrid7.labelmatrix(i, 8).length < 5 ) {
-
- messageBox("혈액번호가 ","I004");
- return;
-
- }
- model.makeValue("/root/send/report/delivedetlgrup/delivedetlgruplist["+cnt+"]","");
- model.copyNode( "/root/send/report/delivedetlgrup/delivedetlgruplist["+cnt+"]", "/root/main/cond/delivedetlgrup/delivedetlgruplist["+i+"]" );
- // alert(instance1.selectSingleNode("/root/send/report/delivedetlgrup/delivedetlgruplist"+"["+cnt+"]").xml);
- }
- }
- if(cnt < 1){
- messageBox("선택 정보가 ","I004");
- return;
- };
- if(messageBox("혈액요청 취소를 ","Q004") != 6) return;// 저장하시겠습니까?
- model.makeValue("/root/send/report/patientnm",model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/patientnm") );
- model.makeValue("/root/send/report/pid",model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/pid") );
- model.makeValue("/root/send/report/sexage",model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/sexage") );
- model.makeValue("/root/send/report/btypee",model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/btype") );
-
- model.makeValue("/root/send/detlgrup",datagrid7.getupdatedataAll("i"));
-
- if(submit("TXMNR01034")){
- fGettDeliveDetlList();// 불출신청 내역 재조회
- }
-
- }
- /**
- * @group :
- * @ver : 2007.07.09
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 미수행기록 목록에서 선택항목 체크(더블클릭)
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fGridSel() {
- var sRowCnt2 = datagrid2.rows-datagrid2.fixedrows;
- var iRow = datagrid2.Row ;
- if( datagrid2.labelmatrix(iRow, 1) == "FALSE" || datagrid2.labelmatrix(iRow, 1) == "false" ){
- datagrid2.textmatrix(iRow, 1) = "true" ;
- } else if( datagrid2.labelmatrix(iRow, 1) == "true" ) {
- datagrid2.textmatrix(iRow, 1) = "FALSE" ;
- }
- }
- /**
- * @group :
- * @ver : 2007.07.09
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 수행기록 내역 상세정보 (더블클릭)
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fBlodExecRecDetlinfo() {
- var sRowCnt = datagrid3.rows-datagrid3.fixedrows;
- var iRow = datagrid3.row ;
- model.setValue(output5.attribute("ref"), model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/blodno"));
- model.setValue(output6.attribute("ref"), model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/prcpnm"));
- model.setValue(output7.attribute("ref"), model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/abo") + model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/rh") );
- model.setValue(input4.attribute("ref"), model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnsstrddtm").substring(0,8));
- model.setValue(input5.attribute("ref"), model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnsstrddtm").substring(8,14));
- model.setValue(input6.attribute("ref"), model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnsendddtm").substring(0,8));
- model.setValue(input7.attribute("ref"), model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnsendddtm").substring(8,14));
- model.setValue(output10.attribute("ref"), model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnsstrnursedeptnm"));
- model.setValue(output11.attribute("ref"), model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnsstrnursenm"));
- model.setValue(output8.attribute("ref"), model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnsendnursedeptnm"));
- model.setValue(output9.attribute("ref"), model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnsendnursenm"));
- model.setValue(combo3.attribute("ref"), model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnssideeffect"));
- model.setValue(input1.attribute("ref"), model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/prcpdelivefact"));
- model.setValue(radio1.attribute("ref"), model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/discontinuyn"));
- model.setValue(combo4.attribute("ref"), model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/discontinu"));
- model.setValue(input8.attribute("ref"), model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/drugqty"));
- model.setValue(textarea1.attribute("ref"), model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnsrec"));
- /*
- model.makeValue("/root/send/tnsstrnurseid", sp[0] );
- model.makeValue("/root/send/tnsstrnursenm", sp[1] );
- model.makeValue("/root/send/tnsstrnursedeptcd", sp[5] );
- model.makeValue("/root/send/tnsstrnursedeptnm", sp[4] );
- */
- model.setValue(output12.attribute("ref"),
- model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnsstrnurseid")+","+
- model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnsstrnursenm")+","+","+","+
- model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnsstrnursedeptnm")+","+
- model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnsstrnursedeptcd")
- );
- // alert(output12.value);
- model.setValue(output13.attribute("ref"),
- model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnsendnurseid")+","+
- model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnsendnursenm")+","+","+","+
- model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnsendnursedeptnm")+","+
- model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnsendnursedeptcd")
- );
- // alert(output13.value);
- // model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnsendnurseid")+","+
- // model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnsendnursenm")+","+
- // model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnsendnursedeptcd")+","+
- // model.getValue(xBlodExecRecGrupListPath+"["+iRow+"]/tnsendnursenm")
- model.refresh();
- var sRowCnt2 = datagrid2.rows-datagrid2.fixedrows;
-
- for(var i=1; i<= sRowCnt2; i++){ // 선택한 값이 불출신청 상태인지 체크
- datagrid2.textmatrix(i, 1) = "FALSE" ;
- }
- }
- /**
- * @group :
- * @ver : 2007.07.16
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 수혈 수행 내역 리스트
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fGetBlodExecRecList(blodpidflag){
- var sRowCnt = datagrid5.rows-datagrid5.fixedrows;
- if( model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/pid") == "" && model.getValue("/root/main/cond/blodno") == "" ){
-
- messageBox("혈액번호/등록번호를 ","C001");
- model.setfocus("input13");
- return;
-
- }
- model.refresh();
- model.makeValue("/root/send/blodpidflag",blodpidflag);
- model.makeValue("/root/send/blodno", input13.value );
- model.makeValue("/root/send/prcpddfrom", input9.value );
- model.makeValue("/root/send/prcpddto", input10.value );
- model.makeValue("/root/send/wardcd", combo5.value );
- model.makeValue("/root/send/roomcd", combo1.value );
- model.makeValue("/root/send/hngnm", combo6.value );
- model.makeValue("/root/send/pid", input12.value );
- model.makeValue("/root/send/ioparam", ioparam);
- if(submit("TRMNR01024")){
- }
- }
- /**
- * @group :
- * @ver : 2007.05.09
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 수혈간호기록 기록저장 버튼
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fTnsRecSave(){
- /* 수혈중단이 Y 일때 수혈폐기로 상태 변경 시작 */
- if( radio1.value == 'Y') {
- // alert(output5.value.length);
- var blodnodupSource = new Array();
- if(output5.value.length > 10){
- // alert('1');
- blodnodupSource = output5.value.split(",") ;
- } else {
- // alert('2' + output5.value);
- blodnodupSource[0] = output5.value ;
- }
- // alert('3' + blodnodupSource[0]);
- for(var i=0; i<= blodnodupSource.length -1 ; i++){
- // alert('4 : ' + blodnodupSource[i]);
- for(var n=1; n<= datagrid1.rows-1 ; n++){
- // alert('5 : ' + model.getValue(xBlodReturnReqGrupListPath+"["+n+"]/blodno"));
- if( blodnodupSource[i] == model.getValue(xBlodReturnReqGrupListPath+"["+n+"]/blodno") ) {//혈액번호와 같으면 그리드에 셋팅
- // alert('666');
- // model.setValue(xBlodReturnReqGrupListPath+"["+n+"]/stat") = 'true' ;
- // model.setValue(xBlodReturnReqGrupListPath+"["+n+"]/reqflag") = '3' ;
- // model.setValue(xBlodReturnReqGrupListPath+"["+n+"]/returnabandondate") = getCurrentDate() ;
- // model.setValue(xBlodReturnReqGrupListPath+"["+n+"]/etcprcpresncd") = combo4.value ;
- datagrid1.valuematrix(n,1) = 'true' ;
- datagrid1.valuematrix(n,10) = '3' ;
- datagrid1.valuematrix(n,11) = getCurrentDate() ;
- datagrid1.valuematrix(n,12) = combo4.value ;
- }
- // alert(datagrid1.labelmatrix(n, 1));
- // alert(datagrid1.labelmatrix(n, 10));
- // alert(datagrid1.labelmatrix(n, 11));
- // alert(datagrid1.labelmatrix(n, 12));
- }
- for(var x=1; x<= datagrid2.rows-1 ; x++){
- if( blodnodupSource[i] == model.getValue(xBlodNoRecPath+"["+x+"]/blodno") ) {//혈액번호와 같으면 그리드에 셋팅
- datagrid2.valuematrix(n,1) = 'true' ;
- }
- }
- }
- var cnt = 0 ;
- for(var i=1; i<= datagrid1.rows ; i++){//체크된 그리드 값 체크
- if( datagrid1.labelmatrix(i, 1) == "true" ) {
- cnt = cnt + 1;
- // ****************************** 반납사유 필수 로직 추가 ***************************************
- //alert(model.getValue(xBlodReturnReqGrupListPath+"["+i+"]/etcprcpresncd"));
- if(model.getValue(xBlodReturnReqGrupListPath+"["+i+"]/reqflag") == "-" || model.getValue(xBlodReturnReqGrupListPath+"["+i+"]/reqflag") == ""){//반납/폐기를 체크
- messageBox("반납/폐기를 ","C002");
- return;
- }
- if(model.getValue(xBlodReturnReqGrupListPath+"["+i+"]/returnabandondate") == "-" || model.getValue(xBlodReturnReqGrupListPath+"["+i+"]/returnabandondate") == ""){//반납/폐기일 체크
- messageBox("반납/폐기일을 ","C002");
- return;
- }
- if(model.getValue(xBlodReturnReqGrupListPath+"["+i+"]/etcprcpresncd") == "-" || model.getValue(xBlodReturnReqGrupListPath+"["+i+"]/etcprcpresncd") == ""){//반납사유 체크
- messageBox("반납/폐기 사유를 ","C002");
- return;
- }
- }
- }
- if(cnt < 1){
- messageBox("선택 정보가 ","I004");
- return;
- };
- model.removenode("/root/send");
- model.makeValue("/root/send/detlgrup2",datagrid1.getupdatedataAll("i"));
- model.makeValue("/root/send/discontinuyn2", "Y" );
- } else {
- var blodnodupSource2 = new Array();
- if(output5.value.length > 10){
- // alert('1');
- blodnodupSource2 = output5.value.split(",") ;
- } else {
- // alert('2' + output5.value);
- blodnodupSource2[0] = output5.value ;
- }
- // alert('3' + blodnodupSource[0]);
- for(var i=0; i<= blodnodupSource2.length -1 ; i++){
- for(var x=1; x<= datagrid2.rows-1 ; x++){
- if( blodnodupSource2[i] == model.getValue(xBlodNoRecPath+"["+x+"]/blodno") ) {//혈액번호와 같으면 그리드에 셋팅
- datagrid2.valuematrix(x,1) = 'true' ;
- }
- }
- }
- }
- /* 수혈중단이 Y 일때 수혈폐기로 상태 변경 끝 */
- // return ;
- if(model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/blodno") == ""){
- messageBox("혈액번호를 ","C002");
- return;
- }
- if(model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/prcpnm") == ""){
- messageBox("혈액명을 ","C002");
- return;
- }
- if(model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/abo") == ""){
- messageBox("혈액형을 ","C002");
- return;
- }
- if(model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/tnsstrdd") == "" || model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/tnsstrtm") == "" ) {
- messageBox("수혈시작시간을 ","C001");
- return;
- }
- if(model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/tnsenddd") == "" || model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/tnsendtm") == "" ) {
- messageBox("수혈종료시간을 ","C001");
- return;
- }
- if(model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/tnsstrnursdeptnm") == "" || model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/tnsstrnursnm") == "" || model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/tnsstrnursall") == "") {
- messageBox("수혈시작 간호사를 ","C002");
- return;
- }
- if(model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/tnsendnursdeptnm") == "" || model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/tnsendnursnm") == "" || model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/tnsendnursall") == "") {
- messageBox("수혈종료 간호사를 ","C002");
- return;
- }
- if(model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/tnsrec") == "" ) {
- messageBox("수혈기록을 ","C001");
- return;
- }
- model.makeValue("/root/send/pid",model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/pid") ) ;
- model.makeValue("/root/send/blodno",model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/blodno") ) ;
- model.makeValue("/root/send/tnsstrddtm",model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/tnsstrdd") + model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/tnsstrtm") );
- model.makeValue("/root/send/tnsendddtm",model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/tnsenddd") + model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/tnsendtm") );
-
- model.makeValue("/root/send/tnsstrnursall",model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/tnsstrnursall") );
- model.makeValue("/root/send/tnsendnursall",model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/tnsendnursall") );
- model.makeValue("/root/send/sideeffectcomcodelist",model.getValue("/root/main/cond/tnsnursereccdgrup/sideeffectcomcodelist") );
- // model.makeValue("/root/send/prcpdelivefact",model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/prcpdelivefact") );
- model.makeValue("/root/send/discontinuyn",model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/discontinuyn") );
- model.makeValue("/root/send/discontinucomcodelist",model.getValue("/root/main/cond/tnsnursereccdgrup/discontinucomcodelist") );
- model.makeValue("/root/send/drugqty",model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/drugqty") );
- model.makeValue("/root/send/tnsrec",model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/tnsrec") );
- var sp = model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/tnsstrnursall").split(",");
- //alert(sp);
- model.makeValue("/root/send/tnsstrnurseid", sp[0] );
- model.makeValue("/root/send/tnsstrnursenm", sp[1] );
- model.makeValue("/root/send/tnsstrnursedeptcd", sp[5] );
- model.makeValue("/root/send/tnsstrnursedeptnm", sp[4] );
- var sp2 = model.getValue("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist/tnsendnursall").split(",");
- //alert(sp2);
- model.makeValue("/root/send/tnsendnurseid", sp2[0] );
- model.makeValue("/root/send/tnsendnursenm", sp2[1] );
- model.makeValue("/root/send/tnsendnursedeptcd", sp2[5] );
- model.makeValue("/root/send/tnsendnursedeptnm", sp2[4] );
- model.makeValue("/root/send/ioparam", ioparam);
- var check = "" ;
- var sRowCnt = datagrid3.rows-datagrid3.fixedrows;
-
- for(var i=1; i<= sRowCnt; i++){ // 선택한 값이 불출신청 상태인지 체크
- // alert(datagrid3.labelmatrix(i, 3));
- //
- // alert(output5.value);
- if( datagrid3.labelmatrix(i, 3) == output5.value ) {
- check = "Y" ;
- }
- }
- /* 저장 / 업데이트 구분 체크 끝 */
- if( check != "Y" ){// 신규 저장
- model.makeValue("/root/send/instcd", "" );
- model.makeValue("/root/send/execprcpuniqno", "" );
- //alert("신규 저장");
- model.makeValue("/root/send/detlgrup",datagrid2.getupdatedataAll("i"));
- model.makeValue("/root/send/vitalgrup",datagrid4.getupdatedataAll("i"));
- if(messageBox("","Q002") != 6) return;// 저장하시겠습니까?
- if(submit("TXMNR01031")){
- model.copyNode("/root/hidden/main","/root/main");
- var pidblodflag = '';
- if(input12.value != ""){
- pidblodflag = 'pid';
- } else if (input13.value !="") {
- pidblodflag = 'blod';
- }
- fBlodDeliveList(pidblodflag);// 혈액불출내역 리스트
- fGetBlodNoExecRecList(pidblodflag); //수혈 미수행 내역 리스트
- fGetBlodExecRecList(pidblodflag); //수혈 수행 내역 리스트
- }
- } else if( check == "Y") {// 업데이트
- model.makeValue("/root/send/prcpdd", "" );
- model.makeValue("/root/send/prcpno", "" );
- model.makeValue("/root/send/prcphistno", "" );
- model.makeValue("/root/send/instcd", "" );
- model.makeValue("/root/send/execprcpuniqno", "" );
- //alert("업데이트");
- if(messageBox("","Q002") != 6) return;// 저장하시겠습니까?
- model.makeValue("/root/send/detlgrup",datagrid3.getupdatedataAll("i"));
- if(submit("TXMNR01032")){
- model.copyNode("/root/hidden/main","/root/main");
- var pidblodflag = '';
- if(input12.value != ""){
- pidblodflag = 'pid';
- } else if (input13.value !="") {
- pidblodflag = 'blod';
- }
- fBlodDeliveList(pidblodflag);// 혈액불출내역 리스트
- fGetBlodNoExecRecList(pidblodflag); //수혈 미수행 내역 리스트
- fGetBlodExecRecList(pidblodflag); //수혈 수행 내역 리스트
- }
- }
- }
- /**
- * @group :
- * @ver : 2007.05.09
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 미수행기록목록에서 선택한 혈액정보 기록버튼
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fExecRec(){
- var sRowCnt = datagrid2.rows-datagrid2.fixedrows;
- var cnt = 0 ;
- model.removenode("/root/send");
- model.makeValue("/root/send/detlgrup",datagrid2.getupdatedataAll("i"));
-
- var blodno = "" ;
- var prcpnm = "" ;
- var aborh = "" ;
- var prcpdelivefact = "" ;
- var duplreccheck = false ;
-
- /* 미수행기록 목록 선택 되어 있는지 체크 시작 */
- for(var i=1; i<= sRowCnt; i++){
- // alert(datagrid2.labelmatrix(i, 1));
- if( datagrid2.labelmatrix(i, 1) == "true" ) {
- blodno += datagrid2.labelmatrix(i, 2) + "," ;
- prcpnm += datagrid2.labelmatrix(i, 3) + "," ;
- aborh += datagrid2.labelmatrix(i, 4)+datagrid2.labelmatrix(i, 5) + "," ;
- prcpdelivefact += datagrid2.labelmatrix(i, 10) + "," ;
- cnt = cnt + 1;
- }
- }
- if(cnt < 1){
- messageBox("선택 정보가 ","I004");
- return;
- };
- /* 미수행기록 목록 선택 되어 있는지 체크 끝 */
- var blodnodupSource = blodno.substr(0,blodno.length-1).split(",");
- // alert(blodnodupSource);
- /* 미수행내역 기록버튼시 중복 체크 시작 */
- for(var i=0; i<= blodnodupSource.length; i++){
- // alert(datagrid2.labelmatrix(i, 1));
- for(var n=0; n<= datagrid3.rows; n++){
- if( blodnodupSource[i] == model.getValue(xBlodExecRecGrupListPath+"["+n+"]/blodno") ) {
- duplreccheck = true ;
- }
- }
- }
- /* 미수행내역 기록버튼시 중복 체크 끝 */
- // alert(blodno.substr(0,blodno.length-1));
- // if( duplreccheck ){// 중복기록 체크
- // messageBox("수행기록된 혈액을 중복으로 기록할수 ","I004");
- // return;
- // };
- // fClearChildNode("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist");
- // fClearChildNode("/root/main/cond/tnsnursereccdgrup/sideeffectcomcodelist");
- // fClearChildNode("/root/main/cond/tnsnursereccdgrup/discontinucomcodelist");
-
- // model.refresh();
- model.setValue(output5.attribute("ref"), blodno.substr(0,blodno.length-1) );
- model.setValue(output6.attribute("ref"), prcpnm.substr(0,prcpnm.length-1) );
- model.setValue(output7.attribute("ref"), aborh.substr(0,aborh.length-1) );
- model.setValue(radio1.attribute("ref"), "N" );
- model.setValue(input1.attribute("ref"), prcpdelivefact.substr(0,prcpdelivefact.length-1) );//전달사항
- model.setValue(input4.attribute("ref"), getCurrentDate() );
- model.setValue(input5.attribute("ref"), getCurrentTime() );
- model.setValue(output10.attribute("ref"), getUserId() );
- model.setValue(output11.attribute("ref"), getUserInfo("dutplcenm") );
- model.setValue(output12.attribute("ref"), getUserInfo("userid")+","+getUserInfo("usernm")+","+getUserInfo("dutplceinstnm")+","+getUserInfo("dutplceinstcd")+","+getUserInfo("dutplcenm")+","+getUserInfo("dutplcecd"));// 저장할 데이터 생성
- model.setValue(output8.attribute("ref"), getUserId() );
- model.setValue(output9.attribute("ref"), getUserInfo("dutplcenm") );
- model.setValue(output13.attribute("ref"), getUserInfo("userid")+","+getUserInfo("usernm")+","+getUserInfo("dutplceinstnm")+","+getUserInfo("dutplceinstcd")+","+getUserInfo("dutplcenm")+","+getUserInfo("dutplcecd"));// 저장할 데이터 생성
- /* 미수행내역 리스트에서 기록버튼 누를때 vital sign 측정시작 측정일시/시간 15분후 일시 시간 셋팅 시작 */
- datagrid4.valuematrix(1,1) = getCurrentDate() ;
- datagrid4.valuematrix(1,2) = getCurrentTime() ;
- /* 미수행내역 리스트에서 기록버튼 누를때 vital sign 측정시작 측정일시/시간 15분후 일시 시간 셋팅 끝 */
- model.refresh();
- // var sp1 = getUserInfos();
- // var sp2 = sp1.split("|")
- // alert(sp2[0]);
- // alert(sp2[1]);
- // alert(sp2[7]);
- // alert(sp2[6]);
- // alert(sp2[9]);
- // alert(sp2[8]);
- // output10.value = sp[4];
- // output11.value = sp[1];
- // output12.value = sp2;
- if(submit("TRMNR01023")){
- model.copyNode("/root/hidden/main","/root/main");
- }
- }
- /**
- * @group :
- * @ver : 2007.07.09
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 혈액요청서 선택했을때...
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fBlodReqDoc(){
- var sRowCnt = datagrid7.rows-datagrid7.fixedrows;
-
- var cnt = 0 ;
- model.removeNode ("/root/send/report");
- for(var i=1; i<= sRowCnt; i++){ // 선택한 값이 불출신청 상태인지 체크
- // alert(datagrid7.labelmatrix(i, 35));
- //
- // return ;
- if( datagrid7.labelmatrix(i, 1) == "true" ) {
- // alert(datagrid7.labelmatrix(i, 35));
- // return ;
- cnt = cnt + 1;
- // if( datagrid7.labelmatrix(i, 2) != "검사완료" ) { // 코드 변경후 바꾸기
- // if( datagrid7.labelmatrix(i, 35) != "520") {// 520 혈액준비 (공통코드)
- //
- //// messageBox("검사완료 상태 이외에는 혈액요청서를 출력 ","E001");// 코드 변경후 바꾸기
- //
- //// if(datagrid7.labelmatrix(i, 35) == "525"){
- //// messageBox("혈액요청서를 이미 출력한 상태입니다. 혈액요청서를 출력 ","E001");
- //// return;
- //// } else
- //
- //// if(datagrid7.labelmatrix(i, 35) != "520" && datagrid7.labelmatrix(i, 35) != "525"){
- //// messageBox("준비완료 상태 이외에는 혈액요청서를 출력 ","E001");
- //// return;
- //// }
- //
- // }
- if(datagrid7.labelmatrix(i, 36) != "520" && datagrid7.labelmatrix(i, 36) != "525"){
- messageBox("준비완료 상태 이외에는 혈액요청서를 출력 ","E001");
- return;
- }
- if( datagrid7.labelmatrix(i, 8).length < 5 ) {
-
- messageBox("혈액번호가 ","I004");
- return;
-
- }
- model.makeValue("/root/send/report/delivedetlgrup/delivedetlgruplist["+cnt+"]","");
- model.copyNode( "/root/send/report/delivedetlgrup/delivedetlgruplist["+cnt+"]", "/root/main/cond/delivedetlgrup/delivedetlgruplist["+i+"]" );
- // alert(instance1.selectSingleNode("/root/send/report/delivedetlgrup/delivedetlgruplist"+"["+cnt+"]").xml);
- }
- }
- if(cnt < 1){
- messageBox("선택 정보가 ","I004");
- return;
- };
- if(messageBox("혈액요청 출력을 ","Q004") != 6) return;
- model.makeValue("/root/send/report/patientnm",model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/patientnm") );
- model.makeValue("/root/send/report/pid",model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/pid") );
- model.makeValue("/root/send/report/sexage",model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/sexage") );
- model.makeValue("/root/send/report/btypee",model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/btype") ); model.makeValue("/root/send/report/wardnm",combo7.value );
- model.makeValue("/root/send/report/roomcd",combo2.value );
- model.makeValue("/root/send/ioparam", ioparam);
-
- // exeReportPreview("RFMNR01000", "XMLSTR");
- /*
- exeReportPreview(레포트명, 연계방법, 매개변수필드 XPath, SubmitID, 출력여부, 인쇄 창 보임 여부, 저장타입, 파일명, 파일 저장 창 보임여부, 미리보기창닫기여부, 모니터 번호, 데이터 소스, 데이터 XPath , 메인리포트 반복XPath, 서브리포트1 반복Xpath)
- */
- exeReportPreview("RFMNR01000", "XMLSTR", "", "", "true", "", "", "", "", "");
-
- model.makeValue("/root/send/detlgrup",datagrid7.getupdatedataAll("i"));
- if(submit("TXMNR01033")){
- fGettDeliveDetlList();// 불출신청 내역 재조회
- }
-
- }
- /**
- * @group :
- * @ver : 2007.07.09
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 혈액불출 내역 선택 삭제 (신청취소)
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fDelDeliveExecPrcp(){
- alert();
- var sRowCnt = datagrid7.rows-datagrid7.fixedrows;
- var cnt = 0 ;
- for(var i=1; i<= sRowCnt; i++){ // 선택한 값이 불출신청 상태인지 체크
- // alert(datagrid7.labelmatrix(i, 1));
- if( datagrid7.labelmatrix(i, 1) == "true" ) {
- cnt = cnt + 1;
- // if( datagrid7.labelmatrix(i, 2) != "500" ) {
- //
- // messageBox("불출신청 이외의 상태에서는 삭제할 수 ","I004");
- // return;
- //
- // }
- alert(model.getValue(xDelDeliveExecPrcpListPath+"["+i+"]/prcppreptfflag");
- if( datagrid7.labelmatrix(i, 36) != "000") {// 500 불출요청 (공통코드)
-
- messageBox("혈액은행에 접수된 상태에서는 신청취소 할 수 ","I004");
- return;
-
- } else if( datagrid7.labelmatrix(i, 36) == "의사") {// 의사 처방 삭제 불가능
-
- messageBox("의사처방은 신청취소 할 수 ","I004");
- return;
-
- }
- }
- }
- if(cnt < 1){
- messageBox("선택 정보가 ","I004");
- return;
- };
- // alert("개발 중입니다.");
- // return ;
- model.removenode("/root/send");
- model.refresh();
- // model.makeValue("/root/send/blodpidflag",blodpidflag);
- model.makeValue("/root/send/blodno", input13.value );
- model.makeValue("/root/send/prcpddfrom", input9.value );
- model.makeValue("/root/send/prcpddto", input10.value );
- model.makeValue("/root/send/wardcd", combo5.value );
- model.makeValue("/root/send/roomcd", combo1.value );
- model.makeValue("/root/send/hngnm", combo6.value );
- model.makeValue("/root/send/pid", input12.value );
- model.makeValue("/root/send/ioparam", ioparam);
- /* 양천덕시 로직 시작 */
- if(messageBox ( "신청취소를 ", "Q004" ) == "6"){
- model.makeValue("/root/send/detlgrup",datagrid7.getupdatedataAll("i"));
-
- if(submit("TXMNR01035") == true ){
- fGetExecDetlList();// 수행처방내역리스트
- fGettDeliveDetlList();// 불출신청 내역 리스트
- }
- }
- /* 양천덕시 로직 끝 */
- }
- /**
- * @group :
- * @ver : 2007.07.16
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 수혈 미수행 내역 리스트
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fGetBlodNoExecRecList(blodpidflag){
- var sRowCnt = datagrid5.rows-datagrid5.fixedrows;
- if( model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/pid") == "" && model.getValue("/root/main/cond/blodno") == "" ){
-
- messageBox("혈액번호/등록번호를 ","C001");
- model.setfocus("input13");
- return;
-
- }
- /* 수혈간호기록 내용 초기화 */
- // fClearChildNode("/root/main/cond/tnsnurserecgrup/tnsnurserecgruplist");
- // fClearChildNode("/root/main/cond/tnsnursereccdgrup/sideeffectcomcodelist");
- // fClearChildNode("/root/main/cond/tnsnursereccdgrup/discontinucomcodelist");
- //
- // model.refresh();
- model.makeValue("/root/send/blodpidflag",blodpidflag);
- model.makeValue("/root/send/blodno", input13.value );
- model.makeValue("/root/send/prcpddfrom", input9.value );
- model.makeValue("/root/send/prcpddto", input10.value );
- model.makeValue("/root/send/wardcd", combo5.value );
- model.makeValue("/root/send/roomcd", combo1.value );
- model.makeValue("/root/send/hngnm", combo6.value );
- model.makeValue("/root/send/pid", input12.value );
- model.makeValue("/root/send/ioparam", ioparam);
- if(submit("TRMNR01021")){
- }
- }
- /**
- * @group :
- * @ver : 2007.05.09
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 혈액불출내역의 혈액반납의뢰 저장
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fBlodReturnSave(){
- var sRowCnt = datagrid1.rows-datagrid1.fixedrows;
- var cnt = 0 ;
- model.removenode("/root/send");
- model.makeValue("/root/send/detlgrup",datagrid1.getupdatedataAll("i"));
-
- var saveyn = 0 ;
- for(var i=1; i<= sRowCnt; i++){
- //alert(datagrid1.labelmatrix(i, 1));
- if( datagrid1.labelmatrix(i, 1) == "true" ) {
- cnt = cnt + 1;
- // ****************************** 반납사유 필수 로직 추가 ***************************************
- //alert(model.getValue(xBlodReturnReqGrupListPath+"["+i+"]/etcprcpresncd"));
- if(model.getValue(xBlodReturnReqGrupListPath+"["+i+"]/reqflag") == "-" || model.getValue(xBlodReturnReqGrupListPath+"["+i+"]/reqflag") == ""){//반납/폐기를 체크
- messageBox("반납/폐기를 ","C002");
- return;
- }
- if(model.getValue(xBlodReturnReqGrupListPath+"["+i+"]/returnabandondate") == "-" || model.getValue(xBlodReturnReqGrupListPath+"["+i+"]/returnabandondate") == ""){//반납/폐기일 체크
- messageBox("반납/폐기일을 ","C002");
- return;
- }
- if(model.getValue(xBlodReturnReqGrupListPath+"["+i+"]/etcprcpresncd") == "-" || model.getValue(xBlodReturnReqGrupListPath+"["+i+"]/etcprcpresncd") == ""){//반납사유 체크
- messageBox("반납/폐기 사유를 ","C002");
- return;
- }
- }
- }
- if(cnt < 1){
- messageBox("선택 정보가 ","I004");
- return;
- };
- model.makeValue("/root/send/ioparam", ioparam);
- if(submit("TXMNR01030")){
- model.copyNode("/root/hidden/main","/root/main");
- }
- /* 반납/폐기 이후 정보 조회 실행 */
- var pidblodflag = '';
- if(input12.value != ""){
- pidblodflag = 'pid';
- } else if (input13.value !="") {
- pidblodflag = 'blod';
- }
- fBlodDeliveList(pidblodflag); //혈액불출 리스트 조회버튼
- fGetBlodNoExecRecList(pidblodflag); //수혈 미수행 내역 리스트
- }
- /**
- * @group :
- * @ver : 2007.07.16
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 혈액불출 내역 조회 리스트
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fBlodDeliveList(blodpidflag){
- var sRowCnt = datagrid5.rows-datagrid5.fixedrows;
- if( model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/pid") == "" && model.getValue("/root/main/cond/blodno") == "" ){
-
- messageBox("혈액번호/등록번호를 ","C001");
- model.setfocus("input13");
- return;
-
- }
- model.removenode("/root/send");
- model.refresh();
- model.makeValue("/root/send/blodpidflag",blodpidflag);
- model.makeValue("/root/send/blodno", input13.value );
- model.makeValue("/root/send/prcpddfrom", input9.value );
- model.makeValue("/root/send/prcpddto", input10.value );
- model.makeValue("/root/send/wardcd", combo5.value );
- model.makeValue("/root/send/roomcd", combo1.value );
- model.makeValue("/root/send/hngnm", combo6.value );
- model.makeValue("/root/send/pid", input12.value );
- model.makeValue("/root/send/ioparam", ioparam);
- if(submit("TRMNR01020")){
- for(var i = 1 ; i < datagrid1.rows; i++ ){
- if( model.getValue("/root/main/cond/blodreturnreqgrup/blodreturnreqgruplist["+ i +"]/prcphistcd") == 'E' ) {
- datagrid1.isReadOnly(i, datagrid1.colRef("reqflag")) = true;
- datagrid1.isReadOnly(i, datagrid1.colRef("returnabandondate")) = true;
- datagrid1.isReadOnly(i, datagrid1.colRef("etcprcpresncd")) = true;
- datagrid1.isReadOnly(i, datagrid1.colRef("stat")) = true;
- datagrid1.rowstyle(i, "data", "background-color") = "#fff000";
- }
- }
- }
- model.setfocus("input13");
- }
- /**
- * @group :
- * @ver : 2007.06.18
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 불출신청 내역 조회 리스트
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fGettDeliveDetlList(){
- if( model.getValue("/root/main/cond/wardcdgrup/wardcdgruplist") == "" ){
-
- // messageBox("병동을 ","C002");
- // model.setfocus("combo7");
- // return;
-
- }
- model.removenode("/root/send");
-
- model.makeValue("/root/send/prcpddfrom", input2.value);
- model.makeValue("/root/send/prcpddto", input11.value);
- model.makeValue("/root/send/wardcd", combo7.value);
- model.makeValue("/root/send/roomcd", combo2.value);
- model.makeValue("/root/send/hngnm", combo8.value);
- model.makeValue("/root/send/pid", input3.value);
- model.makeValue("/root/send/ioparam", ioparam);
- if(submit("TRMNR01009")){
- }
- }
- /**
- * @group :
- * @ver : 2007.04.02
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 수행처방 선택시 체크사항
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fSelchange(){
- var iRow = datagrid5.row ;
- // alert(parseInt(model.getValue(xExecDetlListPath+"["+iRow+"]/prcpqty")));
- //
- // alert(parseInt(model.getValue(xExecDetlListPath+"["+iRow+"]/appno")));
- if( parseInt(model.getValue(xExecDetlListPath+"["+iRow+"]/prcpqty")) <= parseInt(model.getValue(xExecDetlListPath+"["+iRow+"]/appno")) ) {
- model.setValue(xExecDetlListPath+"["+iRow+"]/sel", "false" ) ;
- messageBox("신청수량이 처방수량보다 클 수 ","I004");
- return;
- }
- if( model.getValue(xExecDetlListPath+"["+iRow+"]/prcpstatcd") == "D/C") {
- model.setValue(xExecDetlListPath+"["+iRow+"]/sel", "false" ) ;
- messageBox("D/C 상태에서는 신청할 수 ","I004");
- return;
- } else if( model.getValue(xExecDetlListPath+"["+iRow+"]/prcpstatcd") == "의사") {
- model.setValue(xExecDetlListPath+"["+iRow+"]/sel", "false" ) ;
- messageBox("의사 상태에서는 신청할 수 ","I004");
- return;
- } else if( model.getValue(xExecDetlListPath+"["+iRow+"]/prcpstatcd") == "완료") {
- model.setValue(xExecDetlListPath+"["+iRow+"]/sel", "false" ) ;
- messageBox("완료 상태에서는 신청할 수 ","I004");
- return;
- } else if( model.getValue(xExecDetlListPath+"["+iRow+"]/prcpstatcd") != "처방") {
- model.setValue(xExecDetlListPath+"["+iRow+"]/sel", "false" ) ;
- messageBox("처방 상태 이외에는 신청할 수 ","I004");
- return;
- }
-
- }
- /**
- * @group :
- * @ver : 2007.04.02
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 그리드의 값이 변경되었을때, 상태값을 변경한다.
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fChangedGridCol(){
- var sDetlGrupRow = datagrid5.row;
- var sDetlGrupBKRow=0;
- var num = model.getValue(xPopWndExecDetlListPath+"["+sDetlGrupRow+"]/num");
- for(var i=1; i<= getNodesetCount(xPopWndClsListBKPath); i++){
- if(model.getValue(xPopWndClsListBKPath+"["+i+"]/num") == num){
- sDetlGrupBKRow = i;
- break;
- }
- }
- if(event.keyCode == "32") {
- messageBox("신청수량에 스페이스를 넣을 수 ","I004");
- model.setValue(xPopWndExecDetlListPath+"["+sDetlGrupRow+"]/stat","-");
- model.setValue(xPopWndExecDetlListPath+"["+sDetlGrupRow+"]/appno","");
- datagrid5.refresh();
- return;
- }
- var irr = datagrid5.textmatrix(sDetlGrupRow,6) ;
- if(model.getValue(xPopWndExecDetlListPath+"["+sDetlGrupRow+"]/appno") == "0" || model.getValue(xPopWndExecDetlListPath+"["+sDetlGrupRow+"]/appno") == ""){
- model.setValue(xPopWndExecDetlListPath+"["+sDetlGrupRow+"]/stat","-");
- datagrid5.rebuild();
- //return;
- }
- // alert(instance1.selectSingleNode(xPopWndExecDetlListPath+"["+sDetlGrupRow+"]").xml);
- //
- // alert(instance1.selectSingleNode(xPopWndClsListBKPath+"["+sDetlGrupBKRow+"]").xml);
- if(instance1.selectSingleNode(xPopWndExecDetlListPath+"["+sDetlGrupRow+"]").xml != instance1.selectSingleNode(xPopWndClsListBKPath+"["+sDetlGrupBKRow+"]").xml){
- model.setValue(xPopWndExecDetlListPath+"["+sDetlGrupRow+"]/stat","I");
- datagrid5.rebuild();
- }
- }
- /**
- * @group :
- * @ver : 2007.05.09
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 혈액불출관리 init
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fPopWndSave(){
- var sRowCnt = datagrid5.rows-datagrid5.fixedrows;
- model.removenode("/root/send");
- model.makeValue("/root/send/detlgrup",datagrid5.getupdatedataAll("i"));
-
- var saveyn = 0 ;
- for(var i=1; i<= sRowCnt; i++){
- if(model.getValue(xPopWndExecDetlListPath+"["+i+"]/stat") != "-") {
- saveyn = 1 ;
- }
- if(model.getValue(xPopWndExecDetlListPath+"["+i+"]/stat") != "-" && model.getValue(xPopWndExecDetlListPath+"["+i+"]/appno") == ""){
- messageBox("신청수량은 ","I003");
- return;
- }
- // if( !isNumber(model.getValue(xPopWndExecDetlListPath+"["+i+"]/appno")) ) {
- //
- // messageBox("숫자형을 ","C001");
- // return;
- //
- // }
- if( parseInt(model.getValue(xPopWndExecDetlListPath+"["+i+"]/appno")) < 1 || parseInt(model.getValue(xPopWndExecDetlListPath+"["+i+"]/appno")) == " " ) {
- messageBox("신청수량은 1건 이하로 입력할 수 ","E001");
- return;
- }
-
- if( parseInt(model.getValue(xPopWndExecDetlListPath+"["+i+"]/delivepossno")) < parseInt(model.getValue(xPopWndExecDetlListPath+"["+i+"]/appno")) ) {
- messageBox("신청수량은 불출수량보다 크게 입력 ","E001");
- return;
- }
- // alert( model.getValue(xPopWndExecDetlListPath+"["+i+"]/prcphopedd") );
- // alert( model.getValue(xPopWndExecDetlListPath+"["+i+"]/prcphopetm") );
- if(model.getValue(xPopWndExecDetlListPath+"["+i+"]/prcphopedd") == "" || model.getValue(xPopWndExecDetlListPath+"["+i+"]/prcphopetm") == ""){
- messageBox("예약일자/예약시간은 ","I003");
- return;
- }
-
- }
- if(saveyn <= 0 ){
- messageBox("수정사항이 없어 저장 ","E001");
- return;
- }
-
- //alert("result : " + saveyn);
- // if(saveyn <= 0 ){
- // messageBox("수정사항이 없어 저장 ","E001");
- // return;
- // }
- //alert(model.getValue("/root/main/cond/clsflag"));
- //alert(model.getValue("/root/main/cond/recflag"));
-
-
- //if(messageBox("","Q002") != 6) return;
- //alert(model.getValue("/root/main/cond/todd"));
- // model.makeValue("/root/send/lrggrupcd", model.getValue(xCondPath+"/lrggrupcd"));
- // model.makeValue("/root/send/clsflag", model.getValue("/root/main/cond/clsflag"));
- // model.makeValue("/root/send/recflag", model.getValue("/root/main/cond/recflag"))
- // model.makeValue("/root/send/todd2", model.getValue("/root/main/cond/todd"))
- //alert(model.getValue("/root/send/todd2"));
- if(submit("TXMNR01008")){
- model.copyNode("/root/hidden/main","/root/main");
- }
- // grd_detlgrup.row = 1;
- window.close();
- }
- /**
- * @group :
- * @ver : 2007.05.09
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 혈액불출관리 init
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fPopWndInit(){
- model.makeValue("/root/send/prcpddfrom", opener.window.javascript.getParameter("prcpddfrom") );
- model.makeValue("/root/send/prcpddto", opener.window.javascript.getParameter("prcpddto") );
- model.makeValue("/root/send/wardcd", opener.window.javascript.getParameter("wardcd") );
- model.makeValue("/root/send/roomcd", opener.window.javascript.getParameter("roomcd") );
- model.makeValue("/root/send/pid", opener.window.javascript.getParameter("pid") );
- model.makeValue("/root/send/queryprcpdd", opener.window.javascript.getParameter("queryprcpdd") );
- model.makeValue("/root/send/queryprcpno", opener.window.javascript.getParameter("queryprcpno") );
- model.makeValue("/root/send/queryprcphistno", opener.window.javascript.getParameter("queryprcphistno") );
- //alert(prcpddfrom); alert(prcpddto); alert(wardcd); alert(roomcd); alert(pid);
-
- if(submit("TRMNR01007")){
- model.copyNode("/root/temp/main","/root/main");
- for(var i = 1 ; i < datagrid5.rows ; i++) {
- model.setValue(xPopWndExecDetlListPath+"["+i+"]/prcphopedd",getCurrentDate());
- model.setValue(xPopWndExecDetlListPath+"["+i+"]/prcphopetm",getCurrentTime());
-
- }
- }
- }
- /**
- * @group :
- * @ver : 2007.06.18
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 혈액불출신청 팝업
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fPopWnd(){
- var iRows = datagrid5.rows;
- var queryprcpdd = "" ;
- var queryprcpno = "" ;
- var queryprcphistno = "" ;
- var checkcnt = 0 ;
- for(var i = 1 ; i < datagrid5.rows; i++ ) {// 전체를 돌면서 그룹에 값이 체크되어 있는것 초기화
- if( model.getValue(xExecDetlListPath+"["+ i +"]/sel") == "true" ) {
- // alert("111");
- queryprcpdd = queryprcpdd + "'" + model.getValue(xExecDetlListPath+"["+ i +"]/prcpdd2") + "'," ;
- queryprcpno = queryprcpno + "" + model.getValue(xExecDetlListPath+"["+ i +"]/prcpno") + "," ;
- // alert(model.getValue(xExecDetlListPath+"["+ i +"]/prcphistno"));
- queryprcphistno = queryprcphistno + "" + model.getValue(xExecDetlListPath+"["+ i +"]/prcphistno") + "," ;
- checkcnt++ ;
- } else {
- // alert("222");
-
- }
-
- }
- if( checkcnt <= 0 ) {
-
- messageBox("수혈처방내역을 ","C002");
- return 0 ;
-
- }
- queryprcpdd = queryprcpdd.replace(/-/g,"")
- // alert(queryprcpdd.replace(/-/g,""));
- // alert(queryprcpdd.substr(0,queryprcpdd.length-1));
- // alert(queryprcpno.substr(0,queryprcpno.length-1));
- // alert(queryprcphistno.substr(0,queryprcphistno.length-1));
- queryprcpdd = queryprcpdd.substr(0,queryprcpdd.length-1) ;
- queryprcpno = queryprcpno.substr(0,queryprcpno.length-1) ;
- queryprcphistno = queryprcphistno.substr(0,queryprcphistno.length-1) ;
- // for(var i = 0 ; i < data.length; i++ ) {
- //
- // queryprcpno = queryprcpno + data[i] ;
- //
- // }
- setParameter("prcpddfrom", input2.value);
- setParameter("prcpddto", input11.value);
- setParameter("wardcd", combo7.value);
- setParameter("roomcd", combo2.value);
- setParameter("pid", input3.value);
- setParameter("queryprcpdd", queryprcpdd);
- setParameter("queryprcpno", queryprcpno);
- setParameter("queryprcphistno", queryprcphistno);
- var left = event.screenX-1000;
- var top = event.screenY+50;
- modal("SMMNR01001",1,left,top);
- }
- /**
- * @group :
- * @ver : 2007.06.18
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 수행처방내역 조회 리스트
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fGetExecDetlList(){
- if( model.getValue("/root/main/cond/wardcdgrup/wardcdgruplist") == "" ){
-
- // messageBox("병동을 ","C002");
- // model.setfocus("combo7");
- // return;
-
- }
- model.removenode("/root/send");
- model.makeValue("/root/send/prcpddfrom", input2.value);
- model.makeValue("/root/send/prcpddto", input11.value);
- model.makeValue("/root/send/wardcd", combo7.value);
- model.makeValue("/root/send/roomcd", combo2.value);
- model.makeValue("/root/send/hngnm", combo8.value);
- model.makeValue("/root/send/pid", input3.value);
- model.makeValue("/root/send/ioparam", ioparam);
- if(submit("TRMNR01006")){
- }
- }
- /**
- * @group :
- * @ver : 2007.06.18
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 환자 상세정보 조회 combo
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fGetPatientInfoRec(arg){
- // alert(ioparameter);
- model.removenode("/root/send");
-
- model.makeValue("/root/send/wardcd", combo5.value);
- model.makeValue("/root/send/roomcd", combo1.value);
- if( input12.value != "" ){
- model.makeValue("/root/send/pid", input12.value);
- } else if( model.makeValue("/root/send/pid", combo6.value) != "" ){
- model.makeValue("/root/send/pid", combo6.value);
- }
- if(submit("TRMNR01005")){
- if( arg == "pid" && ioparam == "IPRC" ){
- // fGetWardList();
- if("" == model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/pidsearchlistInfo/wardcd") ) {
- return ;
- }
- model.setValue(combo5.attribute("ref"), model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/pidsearchlistInfo/wardcd") );
- fGetRoomList();
- if( "" == model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/pidsearchlistInfo/roomcd") ) {
- return ;
- }
- model.setValue(combo1.attribute("ref"), model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/pidsearchlistInfo/roomcd") );
- fGetPatientList();
- if("" == model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/pidsearchlistInfo/pid") ) {
- return ;
- }
- model.setValue(combo6.attribute("ref"), model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/pidsearchlistInfo/pid") );
- }
- // model.refresh();
- }
- model.setfocus("button16");
- }
- /**
- * @group :
- * @ver : 2007.06.18
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 환자 상세정보 조회 combo
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fGetPatientInfo(arg){
- // alert(ioparameter);
- model.removenode("/root/send");
-
- model.makeValue("/root/send/wardcd", combo7.value);
- model.makeValue("/root/send/roomcd", combo2.value);
- if( input3.value != "" ){
- model.makeValue("/root/send/pid", input3.value);
- } else if( model.makeValue("/root/send/pid", combo8.value) != "" ){
- model.makeValue("/root/send/pid", combo8.value);
- }
- if(submit("TRMNR01005")){
- if( arg == "pid" && ioparam == "IPRC" ){
- // fGetWardList();
- if("" == model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/pidsearchlistInfo/wardcd") ) {
- return ;
- }
- model.setValue(combo7.attribute("ref"), model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/pidsearchlistInfo/wardcd") );
- fGetRoomList();
- if( "" == model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/pidsearchlistInfo/roomcd") ) {
- return ;
- }
- model.setValue(combo2.attribute("ref"), model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/pidsearchlistInfo/roomcd") );
- fGetPatientList();
- if("" == model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/pidsearchlistInfo/pid") ) {
- return ;
- }
- model.setValue(combo8.attribute("ref"), model.getValue("/root/main/cond/patientgrupInfo/patientgruplistInfo/pidsearchlistInfo/pid") );
- }
- // model.refresh();
- }
- model.setfocus("button3");
- }
- /**
- * @group :
- * @ver : 2007.06.18
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 환자 정보 조회 combo
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fGetPatientList(){
- model.removenode("/root/send");
-
- model.makeValue("/root/send/wardcd", combo7.value);
- model.makeValue("/root/send/roomcd", combo2.value);
- if(submit("TRMNR01004")){
- }
- model.setfocus("combo8");
- }
- /**
- * @group :
- * @ver : 2007.06.18
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 병실 조회 combo
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fGetRoomList(){
- model.removenode("/root/send");
-
- model.makeValue("/root/send/wardcd", combo7.value);
- //alert(combo7.value);
- if(submit("TRMNR01003")){
- }
- model.setfocus("combo2");
- }
- /**
- * @group :
- * @ver : 2007.06.18
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 병동 조회
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fGetWardList(){
- model.removenode("/root/send");
-
- model.makeValue("/root/send/wardcd", model.getValue("/root/temp/cond/wardcdgrup/wardcdgruplist/wardcd"));
- if(submit("TRMNR01002")){
- }
- // model.setfocus("combo7");
- }
- /**
- * @group :
- * @ver : 2007.05.09
- * @by : 정찬성
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 혈액불출관리 init
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fInit( getparam){
- // alert('11: ' + getparam);
- //
- // ioparam = getparam ;
- fGetWardList();// 병동코드 리스트
- }
|