/** * ÆÄ ÀÏ ¸í : SMADT10200.js * ¼³ ¸í : º´µ¿ ó¹æÀü/¶óº§ Ãâ·Â, º´µ¿ ¸¶°¨ Javascript * ¼³ °è ÀÚ : °øµÎ°æ * ÀÛ ¼º ÀÚ : °øµÎ°æ * ¼öÁ¤ÀÌ·Â : 2006.6.28 / ¼öÁ¤ÀÛ¼º / °øµÎ°æ */ //Á¶È¸Á¶°Ç¿¡ ¸Â´Â µ¥ÀÌÅͰ¡ ÀÖ´ÂÁö¸¦ chk var chk_drugno = 0; var chk_wardcd = 0; var chk_pid = 0; var chk_prnt_count = 0; var chk_sum_count = 0; var chk_count = 0; var gTimer = null; var gTimer2 = null; var gT1 = null; var sleepTime= 1000; var chk_cnt = 0; var gCurrPrtObj = null; //ÇöÀç Ãâ·Â IViewer /** * ÃʱâÈ­ */ function fInit() { if (model.getValue("/root/hidden/prcpsrch/prcpdd") == "") { // ³¯Â¥ ÃʱâÈ­ model.makeValue("/root/hidden/srchinfo/prcpdd", getCurrentDate()); } //󹿱¸ºÐ ÃʱâÈ­ model.makeValue("/root/hidden/srchinfo/prcpflag", "A"); submit("TRADT10211"); //¾àÁֻ籸ºÐ ÃʱâÈ­ model.makeValue("/root/hidden/srchinfo/drugkind", "T"); //¶óº§ üũ ÃʱâÈ­ model.makeValue("/root/hidden/srchinfo/lblyn", "L"); fChkLBL_YN(); //ó¹æÀü üũ ÃʱâÈ­ model.makeValue("/root/hidden/srchinfo/mpsflag", "P"); //±âŸÁ¶È¸±¸ºÐ ÃʱâÈ­ model.makeValue("/root/hidden/srchinfo/etcflag", "T"); cbx_etcdescflag.disabled = true; //¸¶°¨½Ã instcd Àû¿ëÀ» À§ÇØ instcd ÃʱâÈ­ // model.setValue("/root/hidden/srchinfo/instcd", getUserInfo("posinstcd")); var dutplceinstcd = getUserInfo("dutplceinstcd"); if(dutplceinstcd == ""){ dutplceinstcd = "012"; } model.makeValue("/root/hidden/srchinfo/instcd", dutplceinstcd); //makeReportPreview(0,270,820,700); //º´µ¿ Combo Á¶È¸ model.setValue("/root/send/deptinfo/deptflag", "W"); submit("TRADT10203"); astfAddCombo("/root/hidden/deptlist", "ward", "wardcd,wardnm", "T,Àüü"); //ÀÚµ¿Ãâ·Â±¸ºÐ ÃʱâÈ­ btn_autoprnt_start.disabled = false; btn_autoprnt_end.disabled = true; //model.setValue("/root/hidden/srchinfo/auto_selflag", "1"); //chk_auto_big.disabled = false; //chk_auto_small.disabled = true; //model.setValue("/root/hidden/srchinfo/auto_bigflag", "E|L|G"); //model.setValue("/root/hidden/srchinfo/auto_smallflag", ""); //20100412 Ȳ¼¼¿ø ¼öÁ¤ º´½ÇÄ÷³ submit("TRADT10213"); if(model.getValue("init/roomyn/roomyn/roomyn")=="Y") { grd_patlist.colHidden(5) = false; model.makeValue("/root/hidden/srchinfo/atc3", "Y"); } else { model.makeValue("/root/hidden/srchinfo/atc3", "N"); grd_patlist.colHidden(5) = true; } model.refresh(); /*/ º´½ÇÄ÷³ if(dutplceinstcd == "013") { grd_patlist.colHidden(5) = false; model.makeValue("/root/hidden/srchinfo/atc3", "Y"); } else { model.makeValue("/root/hidden/srchinfo/atc3", "N"); grd_patlist.colHidden(5) = true; } model.refresh(); */ //¸¶°¨½Ã°£±¸ºÐ submit("TRADT10212"); cmb_sumtmflag1.select(0); cmb_sumtmflag2.select(0); cmb_sumtmflag3.select(0); //ó¹æÀü °¨»çÈ­¸é¿¡¼­ ÆË¾÷À¸·Î ¿­¶§ µ¥ÀÌÅÍ Á¶È¸ if(model.getValue("/root/hidden/popupinfo/drugno") != ""){ model.setValue("/root/hidden/srchinfo/prcpdd", model.getValue("/root/hidden/popupinfo/prcpdd")); model.setValue("/root/hidden/srchinfo/fst_drugno", model.getValue("/root/hidden/popupinfo/drugno")); model.setValue("/root/hidden/srchinfo/pid", model.getValue("/root/hidden/popupinfo/pid")); //model.setValue("/root/hidden/srchinfo/ward", model.getValue("/root/hidden/popupinfo/ward")); model.refresh(); fInSumList(); } //¹ÙÄÚµåÇÁ¸°Åͼ³Á¤ ÃʱâÈ­ model.setValue("/root/send/scrnid", getScreenID()); submit("TRLLC90101"); //lzzfMakeBrcdPrntObjHanDo("CommAX"); var comm = model.getValue("/root/main/barcdprntsetup/prntsetupinfo/setupinfo/comm02/comm"); var prntkind = model.getValue("/root/main/barcdprntsetup/prntsetupinfo/setupinfo/prntkind"); if(comm == "2") { model.setValue("/root/main/barcdprntsetup/prntsetupinfo/setupinfo/comm02/comm", "1"); } if(prntkind == "1") { model.setValue("/root/main/barcdprntsetup/prntsetupinfo/setupinfo/prntkind", "5"); } //Ãß°¡¸¶°¨½Ã admission°ú º´µ¿ÀÀ±ÞÀ» ÇÔ²² ¸¶°¨ÇÒÁö ¿©ºÎ Á¶È¸ , ATC¼øÀ¸·Î Á¤·Ä üũ ¿©ºÎ //20100405 À̼±°æ Ãß°¡ : Á¤Á¦ ÀÛÀº¶óº§(¸®½ºÆ®Çü½Ä) Ãâ·Â½Ã ptp ÇÔ²² Ãâ·ÂÇÒÁö ¿©ºÎ submit("TRADT10207"); if(model.getValue("/root/init/sumprcpflagyn/flagyn/orderbyatc") == "Y") { model.setValue("/root/hidden/srchinfo/orderbyatc", "Y"); model.refresh(); } // Ãâ°íºÎ¼­ Á¶È¸, ¼³Á¤ 2009.09.07 pymi submit("TRADT01106"); // 20101019_laboru_°æºÏ´ëº´¿ø_cmc ¼ÂÆÃÀ» °æºÏ´ëº´¿ø¿ëÀ¸·Î º¯°æ /* if((dutplceinstcd == "013") || (dutplceinstcd == "014") || (dutplceinstcd == "017")) { combo1.select(0); } else if(dutplceinstcd == "012") { combo1.select(2); } else { combo1.select(1); }*/ if(dutplceinstcd == "032" || dutplceinstcd == "031") { combo1.select(0); } else { combo1.select(0); } //if(dutplceinstcd == "031") { // checkbox13.visible = false; //} chk_cnt ++; model.setValue("/root/temp/stocdeptcd", model.getValue("/root/hidden/srchinfo/stocdeptcd")); combo1.refresh(); // (e) // 2010.03.22 pymi submit("TRADT01107"); model.setValue("/root/hidden/srchinfo/lbl5", model.getValue("/root/init/lbllists/lbllists/lbl5")); // (e) } /** * ¶óº§ º¯°æ½Ã ó¸® */ function fChkLBL_YN() { var chk = model.getValue("/root/hidden/srchinfo/lblyn"); var sLbl_Drug = "D|DT|DX|DE|DH"; var sLbl_Inj = "I|IO|IX|IE|IH|IS"; // 20120628_ÀϹݼö¾×µµ Ãß°¡(Åð¿øÀÇ °æ¿ì) if(chk != ""){ model.makeValue("/root/hidden/srchinfo/lbl_drug", sLbl_Drug); model.makeValue("/root/hidden/srchinfo/lbl_inj", sLbl_Inj); model.makeValue("/root/hidden/srchinfo/drugall", "Y"); model.makeValue("/root/hidden/srchinfo/injall", "Y"); } else { model.makeValue("/root/hidden/srchinfo/lbl_drug", ""); model.makeValue("/root/hidden/srchinfo/lbl_inj", ""); model.makeValue("/root/hidden/srchinfo/drugall", ""); model.makeValue("/root/hidden/srchinfo/injall", ""); } //¶óº§ Ãâ·Â Çü½Ä ¿É¼Ç submit("TRADT10208"); if(model.getValue("/root/init/lbltype/item2/lbltype") == "Y") { checkbox10.visible = true; checkbox3.visible = true; } else { checkbox10.visible = false; checkbox3.visible = false; } } /** * ¸¶°¨¸®½ºÆ® Á¶È¸ */ function fInSumList() { model.removeNodeset("/root/main/sumlist/sumlist"); model.refresh(); chk_ward.visible = false; if(model.getValue("/root/hidden/srchinfo/prcpflag") == ""){ messageBox("󹿱¸ºÐÀ»", "C001") return; } if(model.getValue("/root/hidden/srchinfo/prcpflag").indexOf("Z") >= 0 && model.getValue("/root/hidden/srchinfo/prcpflag").length > 1){ messageBox("󹿱¸ºÐ 'Á¤±Ô¾à(508ÀÀ±Þº´µ¿)'À» Áߺ¹ ¼±ÅÃÇÒ ¼ö ¾ø½À´Ï´Ù.", "C"); model.setValue("/root/hidden/srchinfo/prcpflag", ""); rdo_prcp.refresh(); rdo_prcp2.refresh(); return; } prcpflag = model.getValue("/root/hidden/srchinfo/prcpflag"); model.setValue("/root/send/suminfo/prcpflag", prcpflag); model.copyNode("/root/send/sumlistinfo", "/root/hidden/srchinfo"); model.makeValue("/root/send/sumlistinfo/version", "new"); //20100301 À̼±°æ ¼öÁ¤ : ÀÚµ¿¶óº§Ãâ·Â½Ã ¶óº§±×·ìº°·Î ¸¶°¨´ë»ó Á¶È¸µÇµµ·Ï if(model.getValue("/root/hidden/srchinfo/autolblyn") == "Y") { var lblstr = model.getValue("/root/hidden/srchinfo/autolblflag"); var lblstr2 = lblstr.setReplaceWord("AD", "D|DX|DH|DP"); lblstr2 = lblstr2.setReplaceWord("AI", "I|IO|IX|IH|IS"); // 20120628_ÀϹݼö¾×µµ Ãß°¡(Åð¿øÀÇ °æ¿ì) model.makeValue("/root/send/sumlistinfo/autolblflag", lblstr2); } // 20130115_½É»ç½ÇÅð¿ø Ã³¹æ Á¶È¸ /* if(prcpflag == "J") { alert("dd"); model.setValue("/root/hidden/srchinfo/prcpflag","L"); model.makeValue("/root/hidden/srchinfo/prcpsimflag","J"); }*/ submit("TRADT10201"); grd_sumlist.isSelected(grd_sumlist.fixedRows) = true; grd_sumlist.row = grd_sumlist.fixedRows; if(grd_sumlist.Rows > 1){ //20100210 À̼±°æ ÁÖ¼® : ¸¶°¨ÀÏÀÚ¸¦ Ã¼Å©ÇØ¼­ Á¶È¸Çϵµ·Ï ÇÔ model.setValue("/root/main/sumlist/sumlist[1]/sel", "Y"); fPrntPatList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·ÂȯÀÚµ¥ÀÌÅÍ Á¶È¸ } else { model.removeNodeset("/root/main/patlist/patlist"); model.refresh(); } } /** * º´µ¿ ¸¶°¨ */ function fHosInSum(chk, auto) { var prcpflag = ""; var prcpdd = model.getValue("/root/hidden/srchinfo/prcpdd"); var instcd = model.getValue("/root/hidden/srchinfo/instcd"); var pid = model.getValue("/root/hidden/srchinfo/pid"); var drugkind = model.getValue("/root/hidden/srchinfo/drugkind"); var onlyantis = model.getValue("/root/hidden/srchinfo/onlyantis"); var prcpflagnm = rdo_prcp.label; var chkret = 0; var fromddflag = ""; var fromdd = ""; var fromtm = ""; var toddflag = ""; var todd = ""; var totm = ""; var sumdt = getCurrentDateTime().replace(" ", ""); prcpflag = model.getValue("/root/hidden/srchinfo/prcpflag"); if(chk == "Y") { if(prcpflag == "R") {//Á¤±Ô¸¶°¨±¸ºÐ fromddflag = model.getValue("/root/hidden/srchinfo/fromddflag1"); fromtm = model.getValue("/root/hidden/srchinfo/fromtm1"); toddflag = model.getValue("/root/hidden/srchinfo/toddflag1"); totm = model.getValue("/root/hidden/srchinfo/totm1"); } else if(prcpflag == "Z") {//Á¤±Ô¾à(508ÀÀ±Þº´µ¿) fromddflag = model.getValue("/root/hidden/srchinfo/fromddflag1"); fromtm = model.getValue("/root/hidden/srchinfo/fromtm1"); toddflag = model.getValue("/root/hidden/srchinfo/toddflag1"); totm = model.getValue("/root/hidden/srchinfo/totm1"); } else if(prcpflag == "A") {//Ãß°¡¸¶°¨±¸ºÐ fromddflag = model.getValue("/root/hidden/srchinfo/fromddflag2"); fromtm = model.getValue("/root/hidden/srchinfo/fromtm2"); toddflag = model.getValue("/root/hidden/srchinfo/toddflag2"); totm = model.getValue("/root/hidden/srchinfo/totm2"); } else if(prcpflag == "K") {// ÀÀ±Þ½Ç¸¶°¨±¸ºÐ fromddflag = model.getValue("/root/hidden/srchinfo/fromddflag3"); fromtm = model.getValue("/root/hidden/srchinfo/fromtm3"); toddflag = model.getValue("/root/hidden/srchinfo/toddflag3"); totm = model.getValue("/root/hidden/srchinfo/totm3"); } if ( prcpflag =="R" || prcpflag =="Z" || prcpflag =="A" || prcpflag == "K"){ if( fromddflag == "" || fromtm == "" || toddflag == "" || totm == "" || fromtm.length != 4 || totm.length != 4) { messageBox("¸¶°¨±¸ºÐÀÌ À߸ø", "E005"); return; } else { if(fromddflag == "0") { fromdd = ((prcpdd.toDate("YYYYMMDD")).getAddDate(-1,"D")).getDateFormat("YYYYMMDD") ; } else { fromdd = prcpdd ; } if(toddflag == "0") { todd = ((prcpdd.toDate("YYYYMMDD")).getAddDate(-1,"D")).getDateFormat("YYYYMMDD") ; } else { todd = prcpdd ; } fromtm = fromtm + "00"; totm = totm + "59"; } } else { fromdd = "" ; todd = "" ; fromtm =""; totm =""; } chkret = 6 ; //messageBox(prcpflagnm + "¸¶°¨À»", "Q004"); } else { if (prcpflag == "Z" && chk == "N" && auto == "auto") { //fromddflag = model.getValue("/root/hidden/srchinfo/fromddflag1"); //fromtm = model.getValue("/root/hidden/srchinfo/fromtm1"); //toddflag = model.getValue("/root/hidden/srchinfo/toddflag1"); //totm = model.getValue("/root/hidden/srchinfo/totm1"); fromdd = ((prcpdd.toDate("YYYYMMDD")).getAddDate(-1,"D")).getDateFormat("YYYYMMDD"); fromtm = '030000' //todd = ((prcpdd.toDate("YYYYMMDD")).getAddDate(1,"D")).getDateFormat("YYYYMMDD"); todd = prcpdd; totm = '235959'; //¸ÖƼµ¥ÀÌ Ã³¹æ Ãâ·Â½Ã ¾÷¹« ¾Ë¾ÆºÁ¾ß ÇÔ } chkret = 6; } if(chkret == 6){ if(model.getValue("/root/hidden/srchinfo/prcpflag") != "C2") { if(chk == "Y") { model.setValue("/root/send/suminfo/fromdd", fromdd); model.setValue("/root/send/suminfo/fromtm", fromtm); model.setValue("/root/send/suminfo/todd", todd); model.setValue("/root/send/suminfo/totm", totm); //model.makeValue("/root/send/suminfo/autoyn", "N"); 20100217 À̼±°æ ÁÖ¼® } else { if (prcpflag == "Z") { model.setValue("/root/send/suminfo/fromdd", fromdd); model.setValue("/root/send/suminfo/fromtm", fromtm); model.setValue("/root/send/suminfo/todd", todd); model.setValue("/root/send/suminfo/totm", totm); } else { model.setValue("/root/send/suminfo/fromdd", ""); model.setValue("/root/send/suminfo/fromtm", ""); model.setValue("/root/send/suminfo/todd", ""); model.setValue("/root/send/suminfo/totm", ""); } } model.setValue("/root/send/suminfo/sumdt", sumdt); model.setValue("/root/send/suminfo/prcpdd", prcpdd); model.setValue("/root/send/suminfo/prcpflag", prcpflag); model.setValue("/root/send/suminfo/instcd", instcd); model.setValue("/root/send/suminfo/pid", pid); model.setValue("/root/send/suminfo/sumdrugkind", drugkind); model.setValue("/root/send/suminfo/onlyantis", onlyantis); model.setValue("/root/send/suminfo/mstocdeptcd", model.getValue("/root/hidden/srchinfo/stocdeptcd")); // 2009.09.11 pymi model.setValue("/root/send/suminfo/ioflag", "I"); model.makeValue("/root/send/suminfo/multiyn", model.getValue("/root/hidden/srchinfo/multiyn")); //multi day ó¹æ Æ÷ÇÔ ¿©ºÎ model.makeValue("/root/send/suminfo/dinjyn", model.getValue("/root/hidden/srchinfo/dinjyn")); // 20121120_Ç×¾ÏÁÖ»ç½Ç Á¦¿Ü ¿©ºÎ var dinjonlyyn = model.getValue("/root/hidden/srchinfo/dinjonlyyn"); // 20121120_Ç×¾ÏÁÖ»ç½Ç¸¸ ¿©ºÎ if(prcpflag == "A" || prcpflag == "R") {//20110102 À̼±°æ ¼öÁ¤ : °æºÏ´ëº´¿ø º´µ¿º°·Î ¸¶°¨È£Ãâ( ¾à¹øÈ£ ¼ø¼­ : º´µ¿, ÆÄ¿ì´õ, µî·Ï¹øÈ£) if(dinjonlyyn == "Y") { model.makeValue("/root/send/suminfo/wardcd", "3120900000"); // 20121121_Ç×¾ÏÁÖ»ç½Ç¸¸ üũ ½Ã Ç×¾ÏÁÖ»ç½Ç¸¸ ¸¶°¨ µÇµµ·Ï ¼öÁ¤ submit("TXADT10201"); } else { for(var i = 2 ; i <= getNodesetCount("/root/hidden/deptlist/ward"); i++) { model.makeValue("/root/send/suminfo/wardcd", model.getValue("/root/hidden/deptlist/ward["+ i + "]/wardcd")); submit("TXADT10201"); } } } else if(prcpflag == "K") { // 20120519_laboru //model.makeValue("/root/send/suminfo/wardcd", model.getValue("/root/hidden/deptlist/ward["+ i + "]/wardcd")); submit("TXADT10201"); } else { submit("TXADT10201"); } //Ãß°¡¸¶°¨½Ã flayn=YÀ̸é admission°ú º´µ¿ÀÀ±Þµµ ¸¶°¨À» ÇÑ´Ù. /*if(chk == "Y" && prcpflag == "A" && model.getValue("/root/init/sumprcpflagyn/flagyn/flagyn") == "Y") { model.setValue("/root/send/suminfo/prcpflag", "M"); for(var i = 0 ; i < 5; i++) { submit("TXADT10201"); } model.setValue("/root/send/suminfo/prcpflag", "W"); for(var i = 0 ; i < 5; i++) { submit("TXADT10201"); } }*/ //20100211 À̼±°æ ¼öÁ¤ : ¸ÖÆ¼Ã¼Å©ÇØ¼­ ¸¶°¨ÇÏ´Â ±â´ÉÀÌ ÀÖÀ¸¹Ç·Î ÁÖ¼®Ã³¸® if (model.getValue("/root/hidden/srchinfo/prcpflag")=="L" || model.getValue("/root/hidden/srchinfo/prcpflag")=="G" ) { model.setValue("/root/send/suminfo/prcpdd", prcpdd); model.setValue("/root/send/suminfo/prcpflag", prcpflag); model.setValue("/root/send/suminfo/instcd", instcd); model.setValue("/root/send/suminfo/pid", pid); model.setValue("/root/send/suminfo/ioflag", "O"); for(var i = 0 ; i < 5; i++) { submit("TXADT10201"); } } if(prcpflag =="J") { //model.makeValue("/root/send/suminfo/wardcd", "4070700000"); // 20130114_½É»ç½Ç Åð¿ø submit("TXADT10201"); } } //20100818 À̼±°æ : Àӻ󿬱¸ ÀϹݾà 80000¹ø´ë·Î ¸¶°¨ model.makeValue("/root/send/srchinfo/srchprcpdd", model.getValue("/root/hidden/srchinfo/prcpdd")); model.makeValue("/root/send/srchinfo/crsumflag", "N"); model.makeValue("/root/send/srchinfo/orgdrugflag", model.getValue("/root/hidden/srchinfo/prcpflag")); model.makeValue("/root/send/srchinfo/sumdt", sumdt); var drugkind = model.getValue("/root/hidden/srchinfo/drugkind"); if(model.getValue("/root/hidden/srchinfo/prcpflag") != "C2") { if(model.getValue("/root/hidden/srchinfo/prcpflag") != "L" && model.getValue("/root/hidden/srchinfo/prcpflag") !="G") { if(drugkind == "T") { //ÁÖ»ç ¸¶°¨ model.makeValue("/root/send/srchinfo/crdrugkind", "M"); submit("TXADC10902"); //¾à ¸¶°¨ model.makeValue("/root/send/srchinfo/crdrugkind", "D"); submit("TXADC10902"); } else if(drugkind == "D") { //¾à ¸¶°¨ model.makeValue("/root/send/srchinfo/crdrugkind", "D"); submit("TXADC10902"); } else if(drugkind == "M") { //ÁÖ»ç ¸¶°¨ model.makeValue("/root/send/srchinfo/crdrugkind", "M"); submit("TXADC10902"); } } else { model.makeValue("/root/send/srchinfo/crdrugkind", ""); submit("TXADC10902"); } } //20100831 À̼±°æ Ãß°¡ : Àӻ󿬱¸ ÀÏ¹Ý¾à ¿Ü·¡ÁÖ»ç ¸¶°¨ ±â´É Ãß°¡ if((auto != "auto" && isSearchString(rdo_prcp2.value, "C2"))|| (auto == "auto" && isSearchString(chk_auto_small.value, "C2")) ) { model.makeValue("/root/send/srchinfo/srchprcpdd", model.getValue( "/root/hidden/srchinfo/prcpdd")); model.makeValue("/root/send/srchinfo/crsumflag", "I"); model.makeValue("/root/send/srchinfo/hosinhosout", "I"); //¿ø³» submit("TXADC10901"); //¿Ü·¡ÀÓ»ó¾à ¸¶°¨ÇÏ´Â °Í°ú µ¿ÀÏ ¼Ò½ºÀÓ (¼öÁ¤½Ã ÁÖÀÇ) } } } /** * ¸¶°¨¸®½ºÆ® ´õºíŬ¸¯½Ã Ãâ·ÂÇÒ È¯ÀÚ¸®½ºÆ® Á¶È¸ */ function fPrntPatList() { model.removeNodeset("/root/main/patlist/patlist"); grd_patlist.rebuildStyle(); // if(model.getValue("/root/main/sumlist/sumlist["+grd_sumlist.row+"]/sumdt") != ""){ //20100210 À̼±°æ ¼öÁ¤ : ¸¶°¨ÀÏÀÚ ¸ÖƼüũ Á¶È¸ °¡´ÉÇϵµ·Ï ÇÔ var strsumdt = ""; for(var i = 1 ; i <= getNodesetCount("/root/main/sumlist/sumlist") ; i++) { if(model.getValue("/root/main/sumlist/sumlist["+i+"]/sel") == "Y") { model.copyNode("/root/send/patlistinfo","/root/main/sumlist/sumlist["+i+"]"); model.makeValue("/root/send/patlistinfo/prcpdd", model.getValue("/root/hidden/srchinfo/prcpdd")); model.makeValue("/root/send/patlistinfo/fst_drugno", model.getValue("/root/hidden/srchinfo/fst_drugno")); model.makeValue("/root/send/patlistinfo/last_drugno", model.getValue("/root/hidden/srchinfo/last_drugno")); model.makeValue("/root/send/patlistinfo/wardcd", model.getValue("/root/hidden/srchinfo/wardcd")); model.makeValue("/root/send/patlistinfo/pid", model.getValue("/root/hidden/srchinfo/pid")); model.makeValue("/root/send/patlistinfo/autoprntflag", model.getValue("/root/hidden/srchinfo/autoprntflag")); model.makeValue("/root/send/patlistinfo/etcdescflag", model.getValue("/root/hidden/srchinfo/etcdescflag")); model.makeValue("/root/send/patlistinfo/prntkind", model.getValue("/root/hidden/srchinfo/prntkind")); model.makeValue("/root/send/patlistinfo/autolblyn", model.getValue("/root/hidden/srchinfo/autolblyn")); model.makeValue("/root/send/patlistinfo/prcpflag", model.getValue("/root/hidden/srchinfo/prcpflag")); model.makeValue("/root/send/patlistinfo/orderbyatc", model.getValue("/root/hidden/srchinfo/orderbyatc")); model.makeValue("/root/send/patlistinfo/instcd", model.getValue("/root/hidden/srchinfo/instcd")); model.makeValue("/root/send/patlistinfo/atc3", model.getValue("/root/hidden/srchinfo/atc3")); model.makeValue("/root/send/patlistinfo/autoyn", model.getValue("/root/hidden/srchinfo/autoyn")); model.makeValue("/root/send/patlistinfo/version", "new"); strsumdt = strsumdt + " " + model.getValue("/root/main/sumlist/sumlist["+i+"]/sumdt"); } } model.makeValue("/root/send/patlistinfo/sumdt", strsumdt); // 20121121_Ç×¾ÏÁÖ»ç½Ç ¿©ºÎ model.makeValue("/root/send/patlistinfo/dinjyn", model.getValue("/root/hidden/srchinfo/dinjyn")); model.makeValue("/root/send/patlistinfo/dinjonlyyn", model.getValue("/root/hidden/srchinfo/dinjonlyyn")); if(strsumdt != "") { submit("TRADT10202"); } if(model.getValue("/root/hidden/srchinfo/fst_drugno") != "" && getNodesetCount("/root/main/patlist/patlist") > 0){ model.setValue("/root/main/patlist/patlist/sel", "Y"); } //sortNodeList("") // } model.refresh(); } /** * ó¹æÀü/¶óº§ Ãâ·Â * autoflag : M(¼öµ¿Ãâ·Â), A(ÀÚµ¿Ãâ·Â) * prntflag : mps(ó¹æÀüÀÚµ¿Ãâ·Â), lbl(¶óº§ÀÚµ¿Ãâ·Â) */ function fPrcpMPSPrint( autoflag, prntflag ) { //Åõ¾à¹øÈ£·Î Ãâ·Â var oRptViewer = ""; var sDrugNo = model.getValue("/root/hidden/srchinfo/fst_drugno"); sleepTime = model.getValue("/root/hidden/sleeptime") * 1000; /*if(sDrugNo != "" && chk_prnt_count == 0){ fAutoPrnt(); return; }*/ chk_prnt_count = 0; //¼öµ¿Ãâ·Â var chk_mpsflag = model.getValue("/root/hidden/srchinfo/mpsflag"); var chk_lblyn = model.getValue("/root/hidden/srchinfo/lblyn"); var chk_patlbl = model.getValue("/root/hidden/srchinfo/namecard"); //var chk_lbl_drug = model.getValue("/root/hidden/srchinfo/lbl_drug"); //var chk_lbl_inj = model.getValue("/root/hidden/srchinfo/lbl_inj"); //ÀÚµ¿Ãâ·Â var chk_autokindflag = model.getValue("/root/hidden/srchinfo/autokind"); var chk_autolblyn = model.getValue("/root/hidden/srchinfo/autolblsize"); //alert(flag + " " + chk_mpsflag); grd_patlist.rebuildStyle(); //if (chk_mpsflag != "" || chk_lblyn != "") { //ó¹æÀü Ãâ·Â µ¥ÀÌÅÍ Á¶È¸ if(autoflag =="M" ) {//¼öµ¿Ãâ·Â var cnt = 0; for(var i = grd_patlist.fixedRows; i < grd_patlist.rows; i++){ if(model.getValue("/root/main/patlist/patlist["+i+"]/sel") == "Y"){ cnt++ ; } } if( cnt == 0){ messageBox("ó¹æÀüÀ» Ãâ·ÂÇÒ È¯ÀÚ¸®½ºÆ®°¡ ¾ø°Å³ª ¼±ÅÃµÈ È¯ÀÚ°¡", "I004"); } } for(var i = grd_patlist.fixedRows; i < grd_patlist.rows; i++){ if(model.getValue("/root/main/patlist/patlist["+i+"]/sel") == "Y"){ model.copyNode("/root/send/prcpinfo", "/root/main/patlist/patlist["+i+"]"); /*if(chk_lbl_drug != "" && chk_lbl_inj != ""){ model.makeValue("/root/send/prcpinfo/lblflag", chk_lbl_drug+"|"+chk_lbl_inj); } else if(chk_lbl_drug != ""){ model.makeValue("/root/send/prcpinfo/lblflag", chk_lbl_drug); } else if(chk_lbl_inj != ""){ model.makeValue("/root/send/prcpinfo/lblflag", chk_lbl_inj); }*/ if(autoflag == "M"){ //model.makeValue("/root/send/prcpinfo/prcpflag", model.getValue("/root/hidden/srchinfo/prcpflag")); //20100315 À̼±°æ ¼öÁ¤ : prcpflagÀÇ ¸ÖƼüũ°¡ °¡´ÉÇϱ⶧¹®¿¡ patlist Á¶È¸µÈ ȯÀÚ °¢°¢ÀÇ drugflag °ªÀ» º¸³»µµ·Ï model.makeValue("/root/send/prcpinfo/prcpflag", model.getValue("/root/send/prcpinfo/drugflag")); model.makeValue("/root/send/prcpinfo/reprintyn", model.getValue("/root/hidden/srchinfo/reprintyn")); } else if(autoflag == "A") { //model.makeValue("/root/send/prcpinfo/prcpflag", model.getValue("/root/hidden/srchinfo/autoprntflag")); //model.makeValue("/root/send/prcpinfo/prcpflag", model.getValue("/root/send/patlistinfo/sumflag")); //20100414 À̼±°æ ¼öÁ¤ : patlist Á¶È¸µÈ ȯÀÚ °¢°¢ÀÇ drugflag °ªÀ» º¸³»µµ·Ï model.makeValue("/root/send/prcpinfo/prcpflag", model.getValue("/root/send/prcpinfo/drugflag")); } model.makeValue("/root/send/prcpinfo/prntflag", model.getValue("/root/hidden/srchinfo/prntflag")); model.makeValue("/root/send/prcpinfo/ioflag", "I"); var drugno = model.getValue("/root/send/prcpinfo/drugno"); var wardcd = model.getValue("/root/send/prcpinfo/wardcd"); var pid = model.getValue("/root/send/prcpinfo/pid"); if(autoflag =="M" ) {//¼öµ¿Ãâ·Â if (chk_mpsflag != "" ){ //ó¹æÀü Ãâ·Â fHosInMPSPrint(); } if(chk_lblyn != "") { //¶óº§¼öµ¿Ãâ·Â fPrcpLBLPrint("M"); } if (chk_patlbl != "") { //³×ÀÓÄ«µå Ãâ·Â oRptViewer += "report_"+i+"|"; fPatLblPrint("report_"+i); } } else if(autoflag == "A"){ //ÀÚµ¿Ãâ·Â if (prntflag == "mps" ){ //ó¹æÀü Ãâ·Â fHosInMPSPrint(); } if(prntflag == "lbl") { //¶óº§ÀÚµ¿Ãâ·Â fPrcpLBLPrint("A"); } } if (model.getValue("/root/hidden/srchinfo/autoyn") !="Y") { //Ãâ·Â»óÅ ǥ½Ã for ( var j = 0 ; j < grd_patlist.cols -1; j++){ grd_patlist.cellStyle("background-color", i, j) = "#cfffcf"; //grd_patlist.cellStyle("font-weight", i, j) = "bold"; } grd_patlist.refresh(); } } //} model.setValue("/root/send/atcinfo/drugdd", model.getValue("/root/hidden/srchinfo/prcpdd")); if ( model.getValue("/root/hidden/srchinfo/prcpflag") =="L" ) { model.setValue("/root/send/atcinfo/drugflag", "L"); } else if ( model.getValue("/root/hidden/srchinfo/prcpflag") =="E" ) { model.setValue("/root/send/atcinfo/drugflag", "E"); } else { model.setValue("/root/send/atcinfo/drugflag", "I"); } if (model.getValue("/root/hidden/srchinfo/autoatcyn") =="Y") { model.setValue("/root/send/atcinfo/instcd", model.getValue("/root/hidden/srchinfo/instcd")); submit("TXADT10202"); //ATC Data Àü¼Û(¹èġȣÃâ) } } //cleaniViewer(oRptViewer); } //¶óº§Ãâ·Â function fPrcpLBLPrint(flag) { var lblitem = null; //¶óº§±¸ºÐ var lblstr = ""; var lblsize = ""; //¶óº§Ãâ·ÂÅ©±â var lblgrupAD = "N"; //Á¤Á¦¶óº§ üũ¿©ºÎ var lblgrupDT = "N"; //PTP¶óº§ üũ¿©ºÎ if(flag == "A") {//ÀÚµ¿Ãâ·Â lblstr = model.getValue("/root/hidden/srchinfo/autolblflag"); lblitem = model.getValue("/root/hidden/srchinfo/autolblflag").split("|"); lblsize = model.getValue("/root/hidden/srchinfo/autolblsize"); if(lblstr.indexOf("AD") >= 0){ lblgrupAD = "Y"; } if(lblstr.indexOf("DT") >= 0){ lblgrupDT = "Y"; } } else if(flag == "M") {//¼öµ¿Ãâ·Â lblstr = model.getValue("/root/hidden/srchinfo/manllblflag"); lblitem = model.getValue("/root/hidden/srchinfo/manllblflag").split("|"); lblsize = model.getValue("/root/hidden/srchinfo/lblsizeflag"); if(lblstr.indexOf("AD") >= 0){ lblgrupAD = "Y"; } if(lblstr.indexOf("DT") >= 0){ lblgrupDT = "Y"; } } // 20101221_laboru_¶óº§ Ãâ·ÂÀº ÆË¾÷À¸·Î ÇÔ. model.makeValue("/root/hidden/srchinfo/flagtmp", flag); model.makeValue("/root/send/prcpinfo/etcdescflag", model.getValue("/root/hidden/srchinfo/etcdescflag")); model.makeValue("/root/send/prcpinfo/lblkind", model.getValue("/root/hidden/srchinfo/lblkind")); model.makeValue("/root/send/prcpinfo/lbltype", model.getValue("/root/init/lbltype/item/lbltype")); model.makeValue("/root/send/prcpinfo/drugkind", model.getValue("/root/hidden/srchinfo/drugkind")); model.makeValue("/root/send/prcpinfo/autoyn", model.getValue("/root/hidden/srchinfo/autoyn")); model.makeValue("/root/send/prcpinfo/prcpliflag", model.getValue("/root/hidden/srchinfo/prcpflag")); // 20120621_Á¦ÇÑÇ×»ýÁ¦ ½ÂÀΠó¹æ ¶óº§ Ãâ·ÂÀ§ÇØ model.makeValue("/root/send/prcpinfo/version", "new"); if(model.getValue("/root/send/suminfo/intiflag") == "N") { model.makeValue("/root/send/prcpinfo/intiflag", "Y"); // 20120417_laboru_ÀÎÆ¼ÆÊ ¿©ºÎ Ãß°¡ } // 20101222_laboru_°æºÏ´ëº´¿ø_°æ´ë º»¿ø ¶óº§(Å«¶óº§ 2) if(lblsize == "L" || lblsize == "L1" ) {//ÀÚµ¿Ãâ·Â¿¡ Å«¶óº§ Ãâ·ÂÀ̸é ȯÀÚº°·Î ÇѲ¨¹ø¿¡ »Ì¾Æ¾ß ¶óº§ÃÑÀå¼ö¿Í ÆäÀÌÁö ¹øÈ£ ÂïÀ½ var lblstr2 = lblstr.setReplaceWord("AD", "D|DX|DH|DP"); lblstr2 = lblstr2.setReplaceWord("AI", "I|IO|IX|IH|IS"); // 20120628_ÀϹݼö¾×µµ Ãß°¡(Åð¿øÀÇ °æ¿ì) model.makeValue("/root/send/prcpinfo/lblflag", lblstr2); model.makeValue("/root/send/prcpinfo/lblsizeflag", "L"); //fInit_lbl(); //fBigLBLPrint(); // 20101221_laboru_¶óº§ Ãâ·ÂÀº ÆË¾÷À¸·Î ÇÔ. modal("SPADT62302", 1, 0, 0, "SPADT62302", "/root", "/root", "left:0px; top:0px; width:0px; height:0px; sysmenu:hidden; min:hidden; max:hidden; caption:hidden;", "false", "x"); } else if(lblsize == "S") { model.makeValue("/root/send/prcpinfo/lblsizeflag", "S"); for (var i = 0; i < lblitem.length; i++) { //20101221_laboru_lblitem À» ÆË¾÷âÀ¸·Î ³Ñ±â±â. model.makeValue("/root/hidden/srchinfo/tmplblitem", lblitem[i]); //Á¤Á¦ if (lblitem[i]=="AD"){ //20100405 À̼±°æ Ãß°¡ : ¶óº§±×·ìÀÇ PTP°¡ üũµÇ¾î ÀÖ°í Á¤Á¦ ÀÛÀº¶óº§(¸®½ºÆ®Çü½Ä) Ãâ·Â½Ã ptp ÇÔ²² Ãâ·ÂÇÏ´Â ¿É¼ÇÀ϶§ PTPÇÔ²² Ãâ·Â if(lblgrupDT == "Y" && model.getValue("/root/init/sumprcpflagyn/flagyn/lbl6yn") == "Y") { model.makeValue("/root/send/prcpinfo/lblflag", "D|DX|DH|DP|DT"); } else { model.makeValue("/root/send/prcpinfo/lblflag", "D|DX|DH|DP"); } //fInit_lbl(); //fSmallLBLPrint(); // 20101221_laboru_¶óº§ Ãâ·ÂÀº ÆË¾÷À¸·Î ÇÔ. modal("SPADT62302", 1, 0, 0, "SPADT62302", "/root", "/root", "left:0px; top:0px; width:0px; height:0px; sysmenu:hidden; min:hidden; max:hidden; caption:hidden;", "false", "x"); } //ÁÖ»ç if (lblitem[i]=="AI"){ model.makeValue("/root/send/prcpinfo/lblflag", "I|IO|IX|IH|IS"); // 20120628_ÀϹݼö¾×µµ Ãß°¡(Åð¿øÀÇ °æ¿ì) //fInit_lbl(); //fSmallLBLPrint(); // 20101221_laboru_¶óº§ Ãâ·ÂÀº ÆË¾÷À¸·Î ÇÔ. modal("SPADT62302", 1, 0, 0, "SPADT62302", "/root", "/root", "left:0px; top:0px; width:0px; height:0px; sysmenu:hidden; min:hidden; max:hidden; caption:hidden;", "false", "x"); } //PTP if (lblitem[i]=="DT"){ model.makeValue("/root/send/prcpinfo/lblflag", "DT"); //20100405 À̼±°æ Ãß°¡ : ¶óº§±×·ìÀÇ Á¤Á¦°¡ üũµÇ¾î ÀÖ°í Á¤Á¦ ÀÛÀº¶óº§(¸®½ºÆ®Çü½Ä) Ãâ·Â½Ã ptp ÇÔ²² Ãâ·ÂÇÏ´Â ¿É¼ÇÀ϶§ Ãâ·Â¾ÈÇÔ if(lblgrupAD == "N" || model.getValue("/root/init/sumprcpflagyn/flagyn/lbl6yn") != "Y") { //fInit_lbl(); //fSmallLBLPrint(); // 20101221_laboru_¶óº§ Ãâ·ÂÀº ÆË¾÷À¸·Î ÇÔ. modal("SPADT62302", 1, 0, 0, "SPADT62302", "/root", "/root", "left:0px; top:0px; width:0px; height:0px; sysmenu:hidden; min:hidden; max:hidden; caption:hidden;", "false", "x"); } } //¿Ü¿ë if (lblitem[i]=="DI"){ model.makeValue("/root/send/prcpinfo/lblflag", "DI"); //fInit_lbl(); //fLiquidLBLPrint(); // 20101221_laboru_¶óº§ Ãâ·ÂÀº ÆË¾÷À¸·Î ÇÔ. modal("SPADT62302", 1, 0, 0, "SPADT62302", "/root", "/root", "left:0px; top:0px; width:0px; height:0px; sysmenu:hidden; min:hidden; max:hidden; caption:hidden;", "false", "x"); } //¼öÁ¦ if (lblitem[i]=="DS"){ model.makeValue("/root/send/prcpinfo/lblflag", "DS"); //fInit_lbl(); //fLiquidLBLPrint(); // 20101221_laboru_¶óº§ Ãâ·ÂÀº ÆË¾÷À¸·Î ÇÔ. modal("SPADT62302", 1, 0, 0, "SPADT62302", "/root", "/root", "left:0px; top:0px; width:0px; height:0px; sysmenu:hidden; min:hidden; max:hidden; caption:hidden;", "false", "x"); } //PACK 20110922_laboru_pack µµ ÀÛÀº ¶óº§·Î Ãâ·Â °¡´ÉÇÏ°Ô ¼öÁ¤ if (lblitem[i]=="DG"){ model.makeValue("/root/send/prcpinfo/lblflag", "DG"); //fInit_lbl(); //fLiquidLBLPrint(); // 20101221_laboru_¶óº§ Ãâ·ÂÀº ÆË¾÷À¸·Î ÇÔ. modal("SPADT62302", 1, 0, 0, "SPADT62302", "/root", "/root", "left:0px; top:0px; width:0px; height:0px; sysmenu:hidden; min:hidden; max:hidden; caption:hidden;", "false", "x"); } //PTP´Üµ¶Ã³¹æ if (lblitem[i]=="PTS"){ model.makeValue("/root/send/prcpinfo/lblflag", "PTS"); //fInit_lbl(); //fSmallLBLPrint(); // 20101221_laboru_¶óº§ Ãâ·ÂÀº ÆË¾÷À¸·Î ÇÔ. modal("SPADT62302", 1, 0, 0, "SPADT62302", "/root", "/root", "left:0px; top:0px; width:0px; height:0px; sysmenu:hidden; min:hidden; max:hidden; caption:hidden;", "false", "x"); } //»êÁ¦¿ë¹ýº° if (lblitem[i]=="DP"){ model.makeValue("/root/send/prcpinfo/lblflag", "DP"); //fInit_lbl(); //fPowderlLBLPrint(); // 20101221_laboru_¶óº§ Ãâ·ÂÀº ÆË¾÷À¸·Î ÇÔ. modal("SPADT62302", 1, 0, 0, "SPADT62302", "/root", "/root", "left:0px; top:0px; width:0px; height:0px; sysmenu:hidden; min:hidden; max:hidden; caption:hidden;", "false", "x"); } //2010-06-29 [º¸°ü¹æ¹ý:³ÃÀåÁÖ»ç] ´Üµ¶Ãâ·Â if (lblitem[i]=="LBL_INJ_I"){ model.makeValue("/root/send/prcpinfo/lblflag", "LBL_INJ_I"); //fInit_lbl(); //fSmallLBLPrint(); // 20101221_laboru_¶óº§ Ãâ·ÂÀº ÆË¾÷À¸·Î ÇÔ. modal("SPADT62302", 1, 0, 0, "SPADT62302", "/root", "/root", "left:0px; top:0px; width:0px; height:0px; sysmenu:hidden; min:hidden; max:hidden; caption:hidden;", "false", "x"); } //2010-06-29 [º¸°ü¹æ¹ý:°íÀ§ÇèÁÖ»ç] ´Üµ¶Ãâ·Â if (lblitem[i]=="LBL_INJ_D"){ model.makeValue("/root/send/prcpinfo/lblflag", "LBL_INJ_D"); //fInit_lbl(); //fSmallLBLPrint(); // 20101221_laboru_¶óº§ Ãâ·ÂÀº ÆË¾÷À¸·Î ÇÔ. modal("SPADT62302", 1, 0, 0, "SPADT62302", "/root", "/root", "left:0px; top:0px; width:0px; height:0px; sysmenu:hidden; min:hidden; max:hidden; caption:hidden;", "false", "x"); } } } } function fStopTimer() { window.clearinterval(gT1); } /** * ó¹æÀü Ãâ·Â */ function fHosInMPSPrint() { model.makeValue("/root/send/prcpinfo/etcdescflag", model.getValue("/root/hidden/srchinfo/etcdescflag")); model.makeValue("/root/send/prcpinfo/autoyn", model.getValue("/root/hidden/srchinfo/autoyn")); model.makeValue("/root/send/prcpinfo/stocdeptcd", model.getValue("/root/hidden/srchinfo/stocdeptcd")); model.makeValue("/root/send/prcpinfo/autolimanti", model.getValue("/root/hidden/srchinfo/prcpflag")); // 2011.02.08 pymi Á¦ÇÑÇ×»ýÁ¦ //fInit_prnt(); modal("SPADT62201", 1, 0, 0, "SPADT62201", "/root/send/prcpinfo", "/root/send/prcpinfo", "left:0px; top:0px; width:0px; height:0px; sysmenu:hidden; min:hidden; max:hidden; caption:hidden;", "false", "x"); } /** * ÀÚµ¿Ãâ·Â ¹öư Ŭ¸¯½Ã ŸÀÌ¸Ó ÀÛµ¿ */ function fClickAutoPrnt(chk) { if (chk == "Y") { //20090824 ¸¶Á¤¹Î ¼öÁ¤. ¿À·ù°¡ ³ª´õ¶óµµ ÆË¾÷ÀÌ ¶ßÁö ¾Ê°í °è¼ÓÇØ¼­ ÁøÇàµÉ ¼ö ÀÖµµ·Ï ¼öÁ¤. setErrorOff(true); model.setValue("/root/hidden/autoend", "N") ; if(model.getValue("/root/hidden/srchinfo/autoprntflag") == ""){ messageBox("ÀÚµ¿Ãâ·ÂÀÇ Ã³¹æ±¸ºÐÀ»", "C001"); return; } if(model.getValue("/root/hidden/srchinfo/autokind") == "" && model.getValue("/root/hidden/srchinfo/autolblsize") == "") { messageBox("ÀÚµ¿Ãâ·ÂÀÇ Ãâ·Â±¸ºÐÀ»", "C001"); return; } // 20101203 wify °æºÏ´ëº´¿ø Å«¶óº§(º»¿ø)Ãß°¡ //if(isSearchString(chk_auto_lblsize.value, "L") || isSearchString(chk_auto_lblsize.value, "S")) { if(isSearchString(chk_auto_lblsize.value, "L") || isSearchString(chk_auto_lblsize.value, "S") || isSearchString(chk_auto_lblsize.value, "L1")) { if(model.getValue("/root/hidden/srchinfo/autolblflag") == ""){ messageBox("ÀÚµ¿Ãâ·ÂÀÇ ¶óº§±¸ºÐÀ»", "C001"); return; } } var sRst = ""; if(gTimer != null) { sRst = messageBox("ÀÚµ¿Ãâ·ÂÀÌ µ¿ÀÛÁßÀÔ´Ï´Ù.\nÀÚµ¿Ãâ·Â±¸ºÐ¼³Á¤´ë·Î ´Ù½Ã", "Q004"); if(sRst == "6"){ window.clearinterval(gTimer); gTimer = null; } else { return; } } if(sRst == ""){ sRst = messageBox("ÀÚµ¿Ãâ·ÂÀ»", "S001"); if(sRst != "6"){ return; } } btn_hist.visible=false; grd_sumlist.visible=false; grd_patlist.visible=false; //20090914 À̼±°æ Ãß°¡ : ÀÚµ¿Ãâ·ÂÁß Ã³¹æ±¸ºÐµî ´Ù¸¥Á¶°Ç º¯°æ ¸øÇÏ°Ô ÇÔ(¿À·ù °¡´É¼º ÀÖÀ½) rdo_prcp.disabled = true; //󹿱¸ºÐ(Á¤±Ô, Ãß°¡) rdo_prcp2.disabled = true; //󹿱¸ºÐ(admission, º´µ¿ÀÀ±Þ, Åð¿ø, ¿Ü¹Ú, ÀÀ±Þ½Ç) checkbox4.disabled = true; //Ç×¾ÏÇÁ·ÎÅäÄÝ󹿏¸ üũ ipt_fst_drugno.disabled = true; //Åõ¾à¹øÈ£ from caption25.disabled = true; //'~' ipt_last_drugno.disabled = true; //Åõ¾à¹øÈ£ to ipt_pid.disabled = true; //µî·Ï¹øÈ£ chk_manl_lblflag.disabled = true; //¶óº§±¸ºÐ btn_prt.disabled = true; //Ãâ·Â¹öư button1.disabled = true; //¸¶°¨¹öư checkbox10.disabled = true; //PTP´Üµ¶Ã³¹æ¶óº§ checkbox3.disabled = true; //ÀÚµ¿Ãâ·ÂÀÇ PTP´Üµ¶Ã³¹æ¶óº§ chk_auto_small.disabled = true; //ÀÚµ¿Ãâ·ÂÀÇ Ã³¹æ±¸ºÐ chk_auto_lblflag.disabled = true; //ÀÚµ¿Ãâ·ÂÀÇ ¶óº§±¸ºÐ chk_auto_big.disabled = true; //ÀÚµ¿Ãâ·ÂÀÇ Ãâ·Â±¸ºÐ chk_auto_lblsize.disabled = true; //ÀÚµ¿Ãâ·ÂÀÇ Ãâ·Â±¸ºÐ checkbox8.disabled = true; //ÀÚµ¿Ãâ·ÂÀÇ ptp¶óº§, ¿Ü¿ë¶óº§ ipt_prcpdd.disabled = true; //Àû¿ëÀÏÀÚ btn_sea.disabled = true; //Á¶È¸¹öư cmb_sumtmflag1.disabled = true; //¸¶°¨½Ã°£´ë±¸ºÐ cmb_fromddflag1.disabled = true; //¸¶°¨ÀÏÀÚfrom ipt_fromtm1.disabled = true; //¸¶°¨½Ã°£from cmb_toddflag1.disabled = true; //¸¶°¨ÀÏÀÚto ipt_totm1.disabled = true; //¸¶°¨½Ã°£to cmb_sumtmflag2.disabled = true; //¸¶°¨½Ã°£´ë±¸ºÐ cmb_fromddflag2.disabled = true; //¸¶°¨ÀÏÀÚfrom ipt_fromtm2.disabled = true; //¸¶°¨½Ã°£from cmb_toddflag2.disabled = true; //¸¶°¨ÀÏÀÚto ipt_totm2.disabled = true; //¸¶°¨½Ã°£to radio1.disabled = true; //¾àÁֻ籸ºÐ radio3.disabled = true; //±âŸÁ¶È¸±¸ºÐ btn_init.disabled = true; //ÃʱâÈ­¹öư button5.disabled = true; //º´µ¿°Ë»öÀ̹ÌÁö chk_mps.disabled = true; //Ãâ·Â±¸ºÐÀÇ Ã³¹æÀüüũ chk_lbl.disabled = true; //Ãâ·Â±¸ºÐÀÇ ¶óº§Ã¼Å© checkbox1.disabled = true; //Ãâ·Â±¸ºÐÀÇ ¾àüũ checkbox2.disabled = true; //Ãâ·Â±¸ºÐÀÇ ÁÖ»çüũ chk_lbl_drug.disabled = true; //Ãâ·Â±¸ºÐÀÇ ¾à¸®½ºÆ®Ã¼Å© chk_lbl_inj.disabled = true; //Ãâ·Â±¸ºÐÀÇ Áֻ縮½ºÆ®Ã¼Å© combo1.disabled = true; //½ÇÃâ°íºÎ¼­ checkbox7.disabled = true; //ATC¼øÀ¸·Î Á¤·Ä btn_prnt.disabled = true; //ÇÁ¸°Åͼ³Á¤ button3.disabled = true; //¸¶°¨½Ã°£°ü¸® input1.disabled = true; //Ãâ·Â°£°Ý checkbox11.disabled = true; //multi-day 󹿯÷ÇÔ //cmb_ward.visible = false; model.setValue("/root/hidden/srchinfo/prcpflag", ""); model.setValue("/root/hidden/srchinfo/fst_drugno", ""); model.setValue("/root/hidden/srchinfo/last_drugno", ""); model.setValue("/root/hidden/srchinfo/wardcd", ""); model.setValue("/root/hidden/srchinfo/wardnm", ""); model.setValue("/root/temp/srchinfo/ward", ""); model.setValue("/root/hidden/srchinfo/pid", ""); model.setValue("/root/hidden/srchinfo/onlyantis",""); model.makeValue("/root/hidden/srchinfo/autoyn", "Y"); model.setValue("/root/send/suminfo/fromdd", ""); model.setValue("/root/send/suminfo/fromtm", ""); model.setValue("/root/send/suminfo/todd", ""); model.setValue("/root/send/suminfo/totm", ""); var autostr = chk_auto_small.label + " " + chk_auto_big.label + " " + chk_auto_lblsize.label ; if(isSearchString(chk_auto_lblsize.value, "L") || isSearchString(chk_auto_lblsize.value, "S") || isSearchString(chk_auto_lblsize.value, "L1")){ autostr = autostr + "(" + chk_auto_lblflag.label + ")"; } autostr = autostr.setReplaceWord("|", ", " ); caption23.text = autostr; model.refresh(); btn_autoprnt_start.disabled = true; btn_autoprnt_end.disabled = false; chk_sum_count = 8; gTimer = window.setInterval("fAutoPrnt()",20000); //ÀçÃâ·Â ºÒ°¡ model.setValue("/root/hidden/srchinfo/reprintyn", ""); checkbox9.disabled = true; group2.visible = "true"; //¼­¹ö¿À·ù°¡ ¹ß»ýÇÏ´õ¶óµµ modeless ÆË¾÷À» ÅëÇØ °è¼ÓÇØ¼­ ÁøÇàÇÒ ¼ö ÀÖµµ·Ï ¼öÁ¤. fErrMsg (); } else { setErrorOn(); window.clearinterval(gTimer); gTimer = null; btn_hist.visible=true; grd_sumlist.visible=true; grd_patlist.visible=true; //20090914 À̼±°æ Ãß°¡ : ÀÚµ¿Ãâ·ÂÁß Ã³¹æ±¸ºÐµî ´Ù¸¥Á¶°Ç º¯°æ ¸øÇÏ°Ô ÇÔ(¿À·ù °¡´É¼º ÀÖÀ½) rdo_prcp.disabled = false; //󹿱¸ºÐ(Á¤±Ô, Ãß°¡) rdo_prcp2.disabled = false; //󹿱¸ºÐ(admission, º´µ¿ÀÀ±Þ, Åð¿ø, ¿Ü¹Ú, ÀÀ±Þ½Ç) checkbox4.disabled = false; //Ç×¾ÏÇÁ·ÎÅäÄÝ󹿏¸ üũ ipt_fst_drugno.disabled = false; //Åõ¾à¹øÈ£ from caption25.disabled = false; //'~' ipt_last_drugno.disabled = false; //Åõ¾à¹øÈ£ to ipt_pid.disabled = false; //µî·Ï¹øÈ£ chk_manl_lblflag.disabled = false; //¶óº§±¸ºÐ btn_prt.disabled = false; //Ãâ·Â¹öư button1.disabled = false; //¸¶°¨¹öư checkbox10.disabled = false; //PTP´Üµ¶Ã³¹æ¶óº§ checkbox3.disabled = false; //ÀÚµ¿Ãâ·ÂÀÇ PTP´Üµ¶Ã³¹æ¶óº§ chk_auto_small.disabled = false; //ÀÚµ¿Ãâ·ÂÀÇ Ã³¹æ±¸ºÐ chk_auto_lblflag.disabled = false; //ÀÚµ¿Ãâ·ÂÀÇ ¶óº§±¸ºÐ chk_auto_big.disabled = false; //ÀÚµ¿Ãâ·ÂÀÇ Ãâ·Â±¸ºÐ chk_auto_lblsize.disabled = false; //ÀÚµ¿Ãâ·ÂÀÇ Ãâ·Â±¸ºÐ checkbox8.disabled = false; //ÀÚµ¿Ãâ·ÂÀÇ ptp¶óº§, ¿Ü¿ë¶óº§ ipt_prcpdd.disabled = false; //Àû¿ëÀÏÀÚ btn_sea.disabled = false; //Á¶È¸¹öư cmb_sumtmflag1.disabled = false; //¸¶°¨½Ã°£´ë±¸ºÐ cmb_fromddflag1.disabled = false; //¸¶°¨ÀÏÀÚfrom ipt_fromtm1.disabled = false; //¸¶°¨½Ã°£from cmb_toddflag1.disabled = false; //¸¶°¨ÀÏÀÚto ipt_totm1.disabled = false; //¸¶°¨½Ã°£to cmb_sumtmflag2.disabled = false; //¸¶°¨½Ã°£´ë±¸ºÐ cmb_fromddflag2.disabled = false; //¸¶°¨ÀÏÀÚfrom ipt_fromtm2.disabled = false; //¸¶°¨½Ã°£from cmb_toddflag2.disabled = false; //¸¶°¨ÀÏÀÚto ipt_totm2.disabled = false; //¸¶°¨½Ã°£to radio1.disabled = false; //¾àÁֻ籸ºÐ radio3.disabled = false; //±âŸÁ¶È¸±¸ºÐ btn_init.disabled = false; //ÃʱâÈ­¹öư button5.disabled = false; //º´µ¿°Ë»öÀ̹ÌÁö chk_mps.disabled = false; //Ãâ·Â±¸ºÐÀÇ Ã³¹æÀüüũ chk_lbl.disabled = false; //Ãâ·Â±¸ºÐÀÇ ¶óº§Ã¼Å© checkbox1.disabled = false; //Ãâ·Â±¸ºÐÀÇ ¾àüũ checkbox2.disabled = false; //Ãâ·Â±¸ºÐÀÇ ÁÖ»çüũ chk_lbl_drug.disabled = false; //Ãâ·Â±¸ºÐÀÇ ¾à¸®½ºÆ®Ã¼Å© chk_lbl_inj.disabled = false; //Ãâ·Â±¸ºÐÀÇ Áֻ縮½ºÆ®Ã¼Å© combo1.disabled = false; //½ÇÃâ°íºÎ¼­ checkbox7.disabled = false; //ATC¼øÀ¸·Î Á¤·Ä btn_prnt.disabled = false; //ÇÁ¸°Åͼ³Á¤ button3.disabled = false; //¸¶°¨½Ã°£°ü¸® input1.disabled = false; //Ãâ·Â°£°Ý checkbox11.disabled = false; //multi-day 󹿯÷ÇÔ //cmb_ward.visible = true; model.setValue("/root/hidden/srchinfo/prcpflag", ""); model.setValue("/root/hidden/srchinfo/fst_drugno", ""); model.setValue("/root/hidden/srchinfo/last_drugno", ""); model.setValue("/root/hidden/srchinfo/wardcd", ""); model.setValue("/root/hidden/srchinfo/wardnm", ""); model.setValue("/root/hidden/srchinfo/drugkind", "T"); model.setValue("/root/temp/srchinfo/ward", ""); model.setValue("/root/hidden/srchinfo/pid", ""); //model.setValue("/root/hidden/srchinfo/autoprntflag", ""); model.makeValue("/root/hidden/srchinfo/autoyn", ""); btn_autoprnt_start.disabled = false; btn_autoprnt_end.disabled = true; model.setValue("/root/hidden/autoend", "Y") ; model.setValue("/root/hidden/srchinfo/prcpflag", "A"); model.refresh(); //ÀçÃâ·Â °¡´É checkbox9.disabled = false; group2.visible = "false"; model.removeNodeset("/root/main/sumlist/sumlist"); model.removeNodeset("/root/main/patlist/patlist"); model.refresh(); } } function fReStart(){ //window.clearinterval(gTimer2); //gTimer = window.setInterval("fAutoPrnt()",11000); } /** * ÀÚµ¿Ãâ·Â */ function fAutoPrnt() { //window.clearinterval(gTimer); if ( model.getValue("/root/hidden/autoend") =="Y" ){ gTimer = null; return; } var orgPrcpflag = model.getValue("/root/hidden/srchinfo/prcpflag"); //if ( chk_count >= 50 ){ //chk_count = 0; //gTimer2 = window.setInterval("fReStart()",5000); //return; //} chk_count++; if ( ( chk_count % 4 )=="0" ){ caption14.text="ÀÚµ¿ Ãâ·ÂÁß[£¯]"; } if ( ( chk_count % 4 )=="1" ){ caption14.text="ÀÚµ¿ Ãâ·ÂÁß[ ¡ª]"; } if ( ( chk_count % 4 )=="2" ){ caption14.text="ÀÚµ¿ Ãâ·ÂÁß[¡¬]"; } if ( ( chk_count % 4 )=="3" ){ caption14.text="ÀÚµ¿ Ãâ·ÂÁß[£ü]"; } caption14.refresh(); if(chk_sum_count >= 4){ if ( model.getValue("/root/hidden/srchinfo/autokind").indexOf("M") > -1 ){ //20090721 À̼±°æ ¼öÁ¤ : ó¹æÀü ÀÚµ¿Ãâ·ÂÀ϶§¸¸ ¸¶°¨Àû¿ë if (model.getValue("/root/hidden/srchinfo/autoendyn") =="Y") { if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("Z") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "Z"); fHosInSum("N", "auto"); //508ÀÀ±Þº´µ¿ Á¤±Ô¾à } if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("M1") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "M"); model.setValue("/root/hidden/srchinfo/drugkind", "D"); fHosInSum("N", "auto"); //Admission¾à¸¶°¨ } if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("M2") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "M"); model.setValue("/root/hidden/srchinfo/drugkind", "M"); fHosInSum("N", "auto"); //AdmissionÁֻ縶°¨ } if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("M1") < 0 && model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("M2") < 0 && model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("M") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "M"); fHosInSum("N", "auto"); //Admission¸¶°¨ } if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("W1") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "W"); model.setValue("/root/hidden/srchinfo/drugkind", "D"); fHosInSum("N", "auto"); //º´µ¿ÀÀ±Þ¾à¸¶°¨ } if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("W2") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "W"); model.setValue("/root/hidden/srchinfo/drugkind", "M"); fHosInSum("N", "auto"); //º´µ¿ÀÀ±ÞÁֻ縶°¨ } else if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("W1") < 0 && model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("W2") < 0 && model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("W") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "W"); fHosInSum("N", "auto"); //º´µ¿ÀÀ±Þ¸¶°¨ } if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("L") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "L"); // ÀÚµ¿À϶§´Â ¿ÜÃâ¿Ü¹ÚÀ¸·Î ó¸®ÇÏ¿© ÀÀ±Þ½Ç Åð¿ø¾à Á¦¿Ü 20091027 À̼±°æ ¼öÁ¤ : ¿ÜÃâ¿Ü¹Ú°ú Åð¿ø¾àÀº µû·Î ó¸® model.setValue("/root/hidden/srchinfo/drugkind", "T"); fHosInSum("N", "auto"); //Åð¿ø¾à¸¶°¨ } if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("G") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "G"); model.setValue("/root/hidden/srchinfo/drugkind", "T"); fHosInSum("N", "auto"); //¿Ü¹Ú¸¶°¨ } if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("E") >=0 ){ //model.setValue("/root/hidden/srchinfo/prcpflag", "Q"); //¸¶¾à¸¸ ¸¶°¨ //fHosInSum("N"); } if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("S") >=0 ){ //model.setValue("/root/hidden/srchinfo/prcpflag", "Q"); //¸¶¾à¸¸ ¸¶°¨ //fHosInSum("N"); } if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("C2") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "C2"); fHosInSum("N", "auto"); //ÀÓ»óÁÖ»ç ¸¶°¨ } } model.setValue("/root/hidden/srchinfo/prcpflag", ""); chk_sum_count = 0; } } chk_sum_count++; //Åð¿ø ÀÚµ¿Ãâ·Â½Ã ¸¶°¨À» G·Î ÇØ¼­ ¿ø·¡ L °ªÀ» º¸³»Áà¾ßÇÔ //model.setValue("/root/hidden/srchinfo/prcpflag", orgPrcpflag); //ÀÌÈÆÀç ¸·À½. ( ¿É¼ÇÀ» ¼±ÅÃÇÑ °ªÀÓ) if ( model.getValue("/root/hidden/srchinfo/autokind").indexOf("M") > -1 ){ model.setValue("/root/hidden/srchinfo/prntkind", "M"); if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("Z") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "Z"); fInSumList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·Âµ¥ÀÌÅÍ Á¶È¸ for(var i = grd_sumlist.fixedRows; i < grd_sumlist.rows; i++){ chk_prnt_count++; grd_sumlist.isSelected(i) = true; grd_sumlist.row = i; model.makeValue("/root/hidden/srchinfo/autolblyn", ""); fPrntPatList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·ÂȯÀÚµ¥ÀÌÅÍ Á¶È¸ fPrcpMPSPrint("A", "mps"); //ó¹æÀüÃâ·Â } } if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("M") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "M"); fInSumList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·Âµ¥ÀÌÅÍ Á¶È¸ for(var i = grd_sumlist.fixedRows; i < grd_sumlist.rows; i++){ chk_prnt_count++; grd_sumlist.isSelected(i) = true; grd_sumlist.row = i; model.makeValue("/root/hidden/srchinfo/autolblyn", ""); fPrntPatList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·ÂȯÀÚµ¥ÀÌÅÍ Á¶È¸ fPrcpMPSPrint("A", "mps"); //ó¹æÀüÃâ·Â } } if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("W") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "W"); if ( model.getValue("/root/send/suminfo/intiflag") != "N" ){ fInSumList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·Âµ¥ÀÌÅÍ Á¶È¸ for(var i = grd_sumlist.fixedRows; i < grd_sumlist.rows; i++){ chk_prnt_count++; grd_sumlist.isSelected(i) = true; grd_sumlist.row = i; model.makeValue("/root/hidden/srchinfo/autolblyn", ""); fPrntPatList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·ÂȯÀÚµ¥ÀÌÅÍ Á¶È¸ fPrcpMPSPrint("A", "mps"); //ó¹æÀüÃâ·Â } } } if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("L") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "L"); // ÀÚµ¿À϶§´Â ¿ÜÃâ¿Ü¹ÚÀ¸·Î ó¸®ÇÏ¿© ÀÀ±Þ½Ç Åð¿ø¾à Á¦¿Ü 20091027 À̼±°æ ¼öÁ¤ : ¿ÜÃâ¿Ü¹Ú°ú Åð¿ø¾àÀº µû·Î ó¸® fInSumList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·Âµ¥ÀÌÅÍ Á¶È¸ for(var i = grd_sumlist.fixedRows; i < grd_sumlist.rows; i++){ chk_prnt_count++; grd_sumlist.isSelected(i) = true; grd_sumlist.row = i; model.makeValue("/root/hidden/srchinfo/autolblyn", ""); fPrntPatList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·ÂȯÀÚµ¥ÀÌÅÍ Á¶È¸ fPrcpMPSPrint("A", "mps"); //ó¹æÀüÃâ·Â } } if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("G") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "G"); fInSumList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·Âµ¥ÀÌÅÍ Á¶È¸ for(var i = grd_sumlist.fixedRows; i < grd_sumlist.rows; i++){ chk_prnt_count++; grd_sumlist.isSelected(i) = true; grd_sumlist.row = i; model.makeValue("/root/hidden/srchinfo/autolblyn", ""); fPrntPatList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·ÂȯÀÚµ¥ÀÌÅÍ Á¶È¸ fPrcpMPSPrint("A", "mps"); //ó¹æÀüÃâ·Â } } if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("E") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "E"); fInSumList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·Âµ¥ÀÌÅÍ Á¶È¸ for(var i = grd_sumlist.fixedRows; i < grd_sumlist.rows; i++){ chk_prnt_count++; grd_sumlist.isSelected(i) = true; grd_sumlist.row = i; model.makeValue("/root/hidden/srchinfo/autolblyn", ""); fPrntPatList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·ÂȯÀÚµ¥ÀÌÅÍ Á¶È¸ fPrcpMPSPrint("A", "mps"); //ó¹æÀüÃâ·Â } } // 2011.02.08 pymi Á¦ÇÑÇ×»ýÁ¦ if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("B") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "B"); fInSumList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·Âµ¥ÀÌÅÍ Á¶È¸ for(var i = grd_sumlist.fixedRows; i < grd_sumlist.rows; i++){ chk_prnt_count++; grd_sumlist.isSelected(i) = true; grd_sumlist.row = i; model.makeValue("/root/hidden/srchinfo/autolblyn", ""); fPrntPatList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·ÂȯÀÚµ¥ÀÌÅÍ Á¶È¸ fPrcpMPSPrint("A", "mps"); //ó¹æÀüÃâ·Â } } // (e) // ÀÓ»ó if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("C2") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "C2"); fInSumList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·Âµ¥ÀÌÅÍ Á¶È¸ for(var i = grd_sumlist.fixedRows; i < grd_sumlist.rows; i++){ chk_prnt_count++; grd_sumlist.isSelected(i) = true; grd_sumlist.row = i; model.makeValue("/root/hidden/srchinfo/autolblyn", ""); fPrntPatList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·ÂȯÀÚµ¥ÀÌÅÍ Á¶È¸ fPrcpMPSPrint("A", "mps"); //ó¹æÀüÃâ·Â } } // 20120316_laboru_¸¶¾à ´Üµ¶ ó¹æÀü Ãâ·Â if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("S") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "S"); fInSumList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·Âµ¥ÀÌÅÍ Á¶È¸ for(var i = grd_sumlist.fixedRows; i < grd_sumlist.rows; i++){ chk_prnt_count++; grd_sumlist.isSelected(i) = true; grd_sumlist.row = i; model.makeValue("/root/hidden/srchinfo/autolblyn", ""); fPrntPatList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·ÂȯÀÚµ¥ÀÌÅÍ Á¶È¸ fPrcpMPSPrint("A", "mps"); //ó¹æÀüÃâ·Â } } // 20120416_laboru_ÀÎÆ¼ÆÊ ó¹æÀü Ãâ·Â if (model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("T") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "T"); model.makeValue("/root/send/sumlistinfo/intiflag", "N"); fInSumList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·Âµ¥ÀÌÅÍ Á¶È¸ for(var i = grd_sumlist.fixedRows; i < grd_sumlist.rows; i++){ chk_prnt_count++; grd_sumlist.isSelected(i) = true; grd_sumlist.row = i; model.makeValue("/root/hidden/srchinfo/autolblyn", ""); fPrntPatList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·ÂȯÀÚµ¥ÀÌÅÍ Á¶È¸ fPrcpMPSPrint("A", "mps"); //ó¹æÀüÃâ·Â } } } //¶óº§ // 20101204 wify °æºÏ´ëº´¿ø Å«¶óº§(º»¿ø) Ãß°¡ //if ( model.getValue("/root/hidden/srchinfo/autolblsize").indexOf("L") > -1 || model.getValue("/root/hidden/srchinfo/autolblsize").indexOf("S") > -1 ){ if ( model.getValue("/root/hidden/srchinfo/autolblsize").indexOf("L") > -1 || model.getValue("/root/hidden/srchinfo/autolblsize").indexOf("S") > -1 || model.getValue("/root/hidden/srchinfo/autolblsize").indexOf("L1") > -1 ){ model.setValue("/root/hidden/srchinfo/prntkind", "L"); if (model.getValue("/root/hidden/srchinfo/autoyn") =="Y") { model.makeValue("/root/hidden/srchinfo/autolblyn", "Y"); } else { model.makeValue("/root/hidden/srchinfo/autolblyn", ""); } if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("Z") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "Z"); fInSumList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·Âµ¥ÀÌÅÍ Á¶È¸ for(var i = grd_sumlist.fixedRows; i < grd_sumlist.rows; i++){ chk_prnt_count++; grd_sumlist.isSelected(i) = true; grd_sumlist.row = i; fPrntPatList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·ÂȯÀÚµ¥ÀÌÅÍ Á¶È¸ fPrcpMPSPrint("A", "lbl"); //¶óº§Ãâ·Â } } if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("M") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "M"); fInSumList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·Âµ¥ÀÌÅÍ Á¶È¸ for(var i = grd_sumlist.fixedRows; i < grd_sumlist.rows; i++){ chk_prnt_count++; grd_sumlist.isSelected(i) = true; grd_sumlist.row = i; fPrntPatList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·ÂȯÀÚµ¥ÀÌÅÍ Á¶È¸ fPrcpMPSPrint("A", "lbl"); //¶óº§Ãâ·Â } } if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("W") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "W"); fInSumList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·Âµ¥ÀÌÅÍ Á¶È¸ for(var i = grd_sumlist.fixedRows; i < grd_sumlist.rows; i++){ chk_prnt_count++; grd_sumlist.isSelected(i) = true; grd_sumlist.row = i; fPrntPatList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·ÂȯÀÚµ¥ÀÌÅÍ Á¶È¸ fPrcpMPSPrint("A", "lbl"); //¶óº§Ãâ·Â } } if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("L") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "L"); fInSumList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·Âµ¥ÀÌÅÍ Á¶È¸ for(var i = grd_sumlist.fixedRows; i < grd_sumlist.rows; i++){ chk_prnt_count++; grd_sumlist.isSelected(i) = true; grd_sumlist.row = i; fPrntPatList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·ÂȯÀÚµ¥ÀÌÅÍ Á¶È¸ fPrcpMPSPrint("A", "lbl"); //¶óº§Ãâ·Â } } if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("G") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "G"); fInSumList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·Âµ¥ÀÌÅÍ Á¶È¸ for(var i = grd_sumlist.fixedRows; i < grd_sumlist.rows; i++){ chk_prnt_count++; grd_sumlist.isSelected(i) = true; grd_sumlist.row = i; fPrntPatList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·ÂȯÀÚµ¥ÀÌÅÍ Á¶È¸ fPrcpMPSPrint("A", "lbl"); //¶óº§Ãâ·Â } } if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("E") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "E"); fInSumList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·Âµ¥ÀÌÅÍ Á¶È¸ for(var i = grd_sumlist.fixedRows; i < grd_sumlist.rows; i++){ chk_prnt_count++; grd_sumlist.isSelected(i) = true; grd_sumlist.row = i; fPrntPatList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·ÂȯÀÚµ¥ÀÌÅÍ Á¶È¸ fPrcpMPSPrint("A", "lbl"); //¶óº§Ãâ·Â } } // 2011.02.09 pymi if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("B") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "B"); fInSumList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·Âµ¥ÀÌÅÍ Á¶È¸ for(var i = grd_sumlist.fixedRows; i < grd_sumlist.rows; i++){ chk_prnt_count++; grd_sumlist.isSelected(i) = true; grd_sumlist.row = i; fPrntPatList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·ÂȯÀÚµ¥ÀÌÅÍ Á¶È¸ fPrcpMPSPrint("A", "lbl"); //¶óº§Ãâ·Â } } //(e) // ÀÓ»ó if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("C2") >=0 ){ model.setValue("/root/hidden/srchinfo/prcpflag", "C2"); fInSumList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·Âµ¥ÀÌÅÍ Á¶È¸ for(var i = grd_sumlist.fixedRows; i < grd_sumlist.rows; i++){ chk_prnt_count++; grd_sumlist.isSelected(i) = true; grd_sumlist.row = i; fPrntPatList(); //¸¶°¨½Ã°£º° ¹ÌÃâ·ÂȯÀÚµ¥ÀÌÅÍ Á¶È¸ fPrcpMPSPrint("A", "lbl"); //¶óº§Ãâ·Â } } } if (model.getValue("/root/hidden/srchinfo/autoatcyn") =="Y") { //ATCÀü¼Û model.setValue("/root/send/atcinfo/drugdd", model.getValue("/root/hidden/srchinfo/prcpdd")); if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("L") > -1 ) { model.setValue("/root/send/atcinfo/drugflag", "L"); model.setValue("/root/send/atcinfo/instcd", model.getValue("/root/hidden/srchinfo/instcd")); submit("TXADT10202"); //ATC Data Àü¼Û(¹èġȣÃâ) } if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("E") > -1 ) { model.setValue("/root/send/atcinfo/drugflag", "E"); model.setValue("/root/send/atcinfo/instcd", model.getValue("/root/hidden/srchinfo/instcd")); submit("TXADT10202"); //ATC Data Àü¼Û(¹èġȣÃâ) } //if ( model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("L") == -1 && model.getValue("/root/hidden/srchinfo/autoprntflag").indexOf("E") == -1 ){ model.setValue("/root/send/atcinfo/drugflag", "I"); model.setValue("/root/send/atcinfo/instcd", model.getValue("/root/hidden/srchinfo/instcd")); submit("TXADT10202"); //ATC Data Àü¼Û(¹èġȣÃâ) //} } //gTimer = window.setInterval("fAutoPrnt()",11000); } function fSleep(numberMillis) { var now = new Date(); var exitTime = now.getTime() + numberMillis; while (true) { now = new Date(); if (now.getTime() > exitTime) return; } } /** * Åõ¾à¹øÈ£ º¯°æ½Ã */ function fChgDrugno(flag) { var bResult = true; if(flag == "first"){ var chk = model.getValue("/root/hidden/srchinfo/fst_drugno"); if(chk == ""){ model.setValue("/root/hidden/srchinfo/last_drugno", ""); model.refresh(); bResult = false; } else { if(isNaN(chk)){ messageBox("Åõ¾à¹øÈ£´Â ¼ýÀÚ·Î","C001"); model.setValue("/root/hidden/srchinfo/fst_drugno", ""); model.refresh(); bResult = false; } if(chk.length > 5){ messageBox("Åõ¾à¹øÈ£´Â 5ÀÚ¸®¹Ì¸¸À¸·Î","C001"); model.setValue("/root/hidden/srchinfo/fst_drugno", ""); model.refresh(); bResult = false; } } } else if(flag == "last"){ var chk_fst = model.getValue("/root/hidden/srchinfo/fst_drugno"); var chk_last = model.getValue("/root/hidden/srchinfo/fst_drugno"); if(chk_fst == ""){ messageBox("ù¹øÂ° Åõ¾à¹øÈ£ºÎÅÍ","C001"); model.setValue("/root/hidden/srchinfo/last_drugno", ""); bResult = false; } else { if(isNaN(chk_fst)){ messageBox("Åõ¾à¹øÈ£´Â ¼ýÀÚ·Î","C001"); model.setValue("/root/hidden/srchinfo/fst_drugno", ""); bResult = false; } if(chk_fst.length > 5 ){ messageBox("Åõ¾à¹øÈ£´Â 5ÀÚ¸®¹Ì¸¸À¸·Î","C001"); model.setValue("/root/hidden/srchinfo/fst_drugno", ""); bResult = false; } if(isNaN(chk_last)){ messageBox("Åõ¾à¹øÈ£´Â ¼ýÀÚ·Î","C001"); model.setValue("/root/hidden/srchinfo/last_drugno", ""); bResult = false; } if(chk_last.length > 5 ){ messageBox("Åõ¾à¹øÈ£´Â 5ÀÚ¸®¹Ì¸¸À¸·Î","C001"); model.setValue("/root/hidden/srchinfo/last_drugno", ""); bResult = false; } } model.refresh(); } return bResult; } function fErrMsg () { var errorMsgPath = "/root/properties/error"; if ( model.getValue ( "/root/properties/error/type" ) == "error" ) { window.load("../../../com/commonweb/xrw/SPZZZ00100_½Ã½ºÅÛ¿¡·¯.xrw","modeless","","width:514px;height:198px;align:center;","/root/properties/error","/root/main"); } } function fPatLblPrint() { submit("TRADT10215"); var commkind = model.getvalue("/root/main/barcdprntsetup/prntsetupinfo/setupinfo/commkind") //ÇÁ¸°ÅÍ Æ÷Æ®¸í, ȤÀº ³×Æ®¿÷ °øÀ¯ ÇÁ¸°ÅÍ ¸í if(commkind == "01") { CommAX1.PrtNm = model.getvalue("/root/main/barcdprntsetup/prntsetupinfo/setupinfo/comm01/setupval"); } var iPoint=0; for(iPoint = 1; iPoint <= getNodesetCount("/root/temp/prntpat/prcpdrug") ; iPoint++){ if(model.getValue("/root/temp/prntpat/prcpdrug["+iPoint+"]/pid") != "" ) { ////////////////////////////////////////////////// // ¶óº§ »ó´Ü³»¿ë // ///////////////////////////////////////////////// //º´µ¿ model.setValue("/root/temp/prntpat/prcpdrug["+iPoint+"]/wardnm" ,model.getValue("/root/temp/prntpat/prcpdrug["+iPoint+"]/wardnm") + " / " + model.getValue("/root/temp/prntpat/prcpdrug["+iPoint+"]/roomcd")); //ȯÀÚ¹øÈ£ model.setValue("/root/temp/prntpat/prcpdrug["+iPoint+"]/pid", "µî·Ï¹øÈ£:" + model.getValue("/root/temp/prntpat/prcpdrug["+iPoint+"]/pid") ); //Áø·á°ú model.setValue("/root/temp/prntpat/prcpdrug["+iPoint+"]/orddeptnm" , model.getValue("/root/temp/prntpat/prcpdrug["+iPoint+"]/orddeptnm") + "/" + model.getValue("/root/temp/prntpat/prcpdrug["+iPoint+"]/medispclidnm") + "/" + model.getValue("/root/temp/prntpat/prcpdrug["+iPoint+"]/atdoctidnm") ); //¶óº§Ãâ·ÂÀÏ var lbldate = getCurrentDate(); lbldate = lbldate.toDate().getDateFormat("YYYY/MM/DD") ; model.makeValue("/root/temp/prntpat/prcpdrug["+iPoint+"]/lbldate" , lbldate); } } makeReportIViewer(0,0,10, 10, arguments[0]); fPrintRex("RFADT10310", "undefined", "undefined", "undefined", "undefined", "undefined", arguments[0]); } function makeReportIViewer(left, top, width, height, iViewerName){ if(left==null || top==null || width==null || height==null){ messageBox("¹Ì¸®º¸±â Å©±âÁ¤º¸°¡", "I004"); }else{ if(iViewerName != null && iViewerName != ""){ if(document.all("ivr_"+iViewerName) == null){ if(document.all("grp_biz") == null){ body.createChild("xforms:iviewer", "id:ivr_"+iViewerName+"; src:../../../com/commonweb/xrw/SPZUR00100_º¸°í¼­.xrw; left:"+left+"px; top:"+top+"px; width:"+width+"px; height:"+height+ "px;"); }else{ grp_biz.createChild("xforms:iviewer", "id:ivr_"+iViewerName+"; src:../../../com/commonweb/xrw/SPZUR00100_º¸°í¼­.xrw; left:"+left+"px; top:"+top+"px; width:"+width+"px; height:"+height+ "px;"); } model.refresh(); } } } } function fPrintRex(rexnm, closeYn, printCount, dataXPath, paramsXPath, infoXPath, parentId){ var posx = ''; var posy = ''; var printnm = ''; if(infoXPath == "" || infoXPath == "undefined" || infoXPath == null) infoXPath = "/root/main/barcdprntsetup/prntsetupinfo"; if(model.getValue(infoXPath + "/setupinfo/rexgbn") != "1") return false; try{ if(model.getXpathValue("count(" + infoXPath + "/setupinfo/pcl/pcllist[barnm='"+rexnm+"']/barnm)") > "0"){ posx = model.getValue(infoXPath + "/setupinfo/pcl/pcllist[barnm='"+rexnm+"']/xpos"); posy = model.getValue(infoXPath + "/setupinfo/pcl/pcllist[barnm='"+rexnm+"']/ypos"); printnm = model.getValue(infoXPath + "/setupinfo/pcl/pcllist[barnm='"+rexnm+"']/prtnm"); }else{ posx = model.getValue(infoXPath + "/setupinfo/blank/left"); posy = model.getValue(infoXPath + "/setupinfo/blank/top"); printnm = model.getValue(infoXPath + "/setupinfo/comm01/setupval"); } if(posx == '') posx = "0"; if(posy == '') posy = "0"; if(closeYn == "true") printnm = ""; exeRexPreview(rexnm, 'XMLSTR', paramsXPath, '', printnm, '', '', '', '', '', '', parentId, '', '', '', printCount, '', 'offsetx=' + posx + ';offsety=' + posy + ';', dataXPath, '', ''); } catch(e){ alert("Ãâ·Â½Ã ¿À·ù°¡ ¹ß»ýÇÏ¿´½À´Ï´Ù\n" + e); return true; } return true; } function exeRexPreview(rid, dataType, paramsXPath, submitId, print, printDialog, fileType, fileName, fileDialog, closeYn, monNo, parentObjId, printPaperBin, userService, showButton, printCount, zoomRate, printOption, dataXPath, mainDataXPath, subDataXPath) { var reportNode = instance1.selectSingleNode(gvReportPath); var syscd = getSystemCd(); syscd = syscd.substr(3,3); //if(syscd == "888" || syscd == "999" || syscd == "") syscd = "001"; if(syscd == "") syscd = "001"; //·¹Æ÷Æ® °ü·Ã ³»¿ë ÃʱâÈ­ if(reportNode != null){ model.removeNodeset(gvReportPath); } model.makeNode(gvReportPath); model.makeNode(gvReportParamsPath); model.makeNode(gvReportPropsPath); model.makeNode(gvReportOptionsPath); paramsXPath = instance1.selectSingleNode(paramsXPath); if(paramsXPath != null){ model.copyNode(gvReportParamsPath, paramsXPath); } model.makeValue(gvReportParamsPath+"/userid", getUserId()); model.makeValue(gvReportParamsPath+"/logoimgurl", getImageURL("error_logo"+getLogoImageKey())); model.makeValue(gvReportParamsPath+"/url", rid); model.makeValue(gvReportPropsPath+"/rex_rptname", rid); model.makeValue(gvReportPropsPath+"/rex_datatype", dataType); model.makeValue(gvReportPropsPath+"/rex_submitid", submitId); model.makeValue(gvReportPropsPath+"/rex_userservice", userService); model.makeValue(gvReportPropsPath+"/rex_data_xpath", dataXPath); model.makeValue(gvReportPropsPath+"/rex_xpath", mainDataXPath); model.makeValue(gvReportPropsPath+"/rex_xpath1", subDataXPath); model.makeValue(gvReportOptionsPath+"/rex_print", print); model.makeValue(gvReportOptionsPath+"/rex_printdialog", printDialog); model.makeValue(gvReportOptionsPath+"/rex_printpaperbin", printPaperBin); model.makeValue(gvReportOptionsPath+"/rex_filetype", fileType); model.makeValue(gvReportOptionsPath+"/rex_filename", fileName); model.makeValue(gvReportOptionsPath+"/rex_filedialog", fileDialog); model.makeValue(gvReportOptionsPath+"/rex_close", closeYn); model.makeValue(gvReportOptionsPath+"/rex_showbutton", showButton); model.makeValue(gvReportOptionsPath+"/rex_printcount", printCount); model.makeValue(gvReportOptionsPath+"/rex_zoomrate", zoomRate); model.makeValue(gvReportOptionsPath+"/rex_printoption", printOption); if(parentObjId == null || parentObjId == ""){ if(document.all("ivr_report") == null){ //popup setParameter("onready","true"); modal("SPZUR00100", monNo); }else{ //iviewer ivr_report.window.javascript.fInitRexpert(); } }else{ var parentObj = document.all("ivr_"+parentObjId); if(parentObj != null){ var childObj = document.all("ivr_"+parentObjId); if(childObj != null){ gCurrPrtObj = "ivr_"+parentObjId; //»èÁ¦ÇÒ viewer¸¦ ÇöÀç Ãâ·Â objº¯¼ö¿¡ ¼³Á¤Çϰí.. ÇÁ¸°Æ® ³¡³­ÈÄ ÇöÀ纯¼öÀÇ Iviewer¸¦ »èÁ¦ childObj.window.javascript.fInitRexpert(); } } } } /** »ý¼ºµÈ IViewer»èÁ¦ **/ function cleanIViewer() { if (arguments[0] == "undefined" || arguments[0] == undefined) { //ÆÄ¶ó¹ÌÅͰ¡ ¾øÀ¸¸é ÇöÀç gCurrPrtObjº¯¼ö·Î IViewer¸¦ »èÁ¦Çϰí var o = document.all("ivr_"+gCurrPrtObj); if (o != null) { body.removeChild("ivr_"+gCurrPrtObj); } } else { //ÆÄ¶ó¹ÌÅͰ¡ Á¸ÀçÇÏ¸é ÆÄ¶ó¹ÌÅÍ ¹è¿­ÀÇ IViewer¸¦ »èÁ¦ÇÔ if (arguments[0].indexOf("|") != -1) return; var arr = arguments[0].split("|"); for (var i in arr) { var o = document.all("ivr_"+arr[i]); if (o != null) { body.removeChild("ivr_"+arr[i]); } } } gCurrPrtObj = null; }