12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417 |
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 화면을 초기화 한다
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fInitalize(){
- grd_termlist.colHidden(1) = true;
- model.setValue("/root/hidden/condition/selctedmode", "D");
- var currentTime = getCurrentTime();
- var instcd = getUserInfo("dutplceinstcd");
- // Edited by NJ 2007-07-21 getDate() -> getCurrentDate()
- //model.setValue("/root/init/today", getDate());
- model.setValue("/root/init/today", getCurrentDate());
- model.setValue("/root/init/curruntTime", currentTime.substr(0,4));
- model.setValue("/root/init/userinfo/userid", getUserId());
- model.setValue("/root/init/userinfo/usernm", getUserName());
- model.setValue("/root/init/userinfo/instcd", instcd);
-
- //2009-05-06 오전 9:55:28 강지훈 수정 : 선택할수있는 기관을 공통코드로 관리한다.
- zbcfGetCodeList( new Array("M0534"), new Array("/root/init/M0534list") ); //화면하단의 사용되는 기관 CheckBox instance 초기화
- copyNodeset("/root/init/M0534selcmb", "/root/init/M0534list", "replace");//중앙의료원일때 보이는 기관선택 Combo Instance 초기화
- copyNodeset("/root/init/M0534allcmb", "/root/init/M0534list", "replace");//기관별이력조회의 Combo Instance 초기화
- addComboInstance("/root/init/M0534selcmb", "cdid^cdnm", "001^전체", "M0534");
- addComboInstance("/root/init/M0534allcmb", "cdid^cdnm", "-^전체", "M0534");
-
-
- //2009-03-12 오전 10:59:38 강지훈 수정 : 접속 기관별 보여지는 항목이 다르다.
- //maininstyn : 중앙관리자여부, selInstcd : 선택기관코드
- if(instcd == "001"){ //중앙의료원에서 접속할경우
- model.setValue("/root/hidden/condition/maininstyn", "Y");
- cap_selInst.visible = true;
- cmb_selInst.visible = true;
- cmb_selInst.value = "001";
- cap_selInst.refresh();
- btn_saverow.disabled = true;
- }
- else{
- model.setValue("/root/hidden/condition/maininstyn", "N");
- model.setValue("/root/hidden/condition/selInstcd", instcd);
- }
- // 공통코드를 조회한다.
- zbcfGetCodeList( new Array("A0129"), new Array("/root/init/A0129list") );
- zbcfGetCodeList( new Array("M0382"), new Array("/root/init/M0382list") );
-
-
- model.makeValue("/root/send/mode", model.getValue("/root/hidden/condition/indxviewmode"));
- model.makeValue("/root/send/indxflag", model.getValue("/root/hidden/condition/indxflag"));
- model.makeValue("/root/send/indxuseflag", model.getValue("/root/hidden/condition/indxuseflag"));
- model.makeValue("/root/send/selInst", model.getValue("/root/hidden/condition/selInst"));
- submit("TRMRT00201");
- model.refresh();
- }
- /**
- * @group :
- * @ver : 2007.03.20
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 입력창 세팅 Enable / Disable
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fDisabled(flag) {
- var maininstyn = model.getValue("/root/hidden/condition/maininstyn");
-
- if(flag == "ETN" || flag == "ETM") {
- cmb_icd10cd.disabled = "false";
- if(flag=="ETM"){
- ipt_diagattrcd.disabled = "true";
- btn_diagattrcd.attribute("visibility") = "hidden";
- ipt_termcd.disabled = "true";
- ipt_snmdcnptid.disabled = "false";
- ipt_termtodd.disabled = "true";
- cap_appinst.disabled = "true";
- chk_appinst.disabled = "true";
- if(maininstyn == "Y"){
- rdo_essntermflag.disabled = "false";
- }
- } else {
- ipt_diagattrcd.disabled = "true";
- btn_diagattrcd.attribute("visibility") = "hidden";
- ipt_termcd.disabled = "true";
- ipt_snmdcnptid.disabled = "false";
- ipt_termtodd.disabled = "false";
-
- if(maininstyn == "Y"){
- cap_appinst.disabled = "false";
- chk_appinst.disabled = "false";
- rdo_essntermflag.disabled = "false";
- }
- }
-
- ipt_termfromdd.disabled = "false";
- btn_snmdcnptid.disabled = "false";
- //btn_snmddescid.disabled = "false";
- btn_medireccd.disabled = "false";
- ipt_engnm.disabled = "false";
- ipt_hngnm.disabled = "false";
- cmb_reprflag.disabled = "false";
- cmb_diagattrverflag.disabled = "false";
- cmb_lglydisflag.disabled = "false";
- rdo_chrncsickyn.disabled = "false";
- rdo_estmexptyn.disabled = "false";
- rdo_serdiagclsyn.disabled = "false";
- rdo_cncryn.disabled = "false";
- rdo_manwomflag.disabled = "false";
- cmb_ageflag.disabled = "false";
- btn_termsave.disabled = "false";
- } else if(flag == "TN" || flag == "TM") {
- ipt_diagattrcd.disabled = "true";
- btn_diagattrcd.attribute("visibility") = "hidden";
- ipt_termcd.disabled = "true";
- ipt_snmdcnptid.disabled = "false"; // 동의어 입력시에도 등록가능하게.
- //btn_snmdcnptid.attribute("visibility") = "hidden";
- btn_snmdcnptid.attribute("visibility") = "visible";
- btn_medireccd.disabled = "true";
- ipt_engnm.disabled = "false";
- ipt_hngnm.disabled = "false";
- cmb_reprflag.disabled = "true";
- cmb_diagattrverflag.disabled = "true";
- cmb_lglydisflag.disabled = "true";
- rdo_chrncsickyn.disabled = "true";
- rdo_estmexptyn.disabled = "true";
- rdo_serdiagclsyn.disabled = "true";
- rdo_cncryn.disabled = "true";
- rdo_manwomflag.disabled = "true";
- ipt_termfromdd.disabled = "false";
- ipt_termtodd.disabled = "false";
- cmb_ageflag.disabled = "true";
- chk_appinst.disabled = "true";
- rdo_essntermflag.disabled = "true";
- } else if(flag == "AS") {
- cmb_icd10cd.disabled = "true";
- ipt_diagattrcd.disabled = "true";
- btn_diagattrcd.attribute("visibility") = "hidden";
- ipt_termcd.disabled = "true";
- ipt_snmdcnptid.disabled = "true";
- ipt_snmdcnptnm.disabled = "true";
- btn_snmdcnptid.disabled = "true";
- //btn_snmddescid.disabled = "true";
- btn_medireccd.disabled = "true";
- ipt_engnm.disabled = "true";
- ipt_hngnm.disabled = "true";
- cmb_reprflag.disabled = "true";
- cmb_diagattrverflag.disabled = "true";
- cmb_lglydisflag.disabled = "true";
- rdo_chrncsickyn.disabled = "true";
- rdo_estmexptyn.disabled = "true";
- rdo_serdiagclsyn.disabled = "true";
- rdo_cncryn.disabled = "true";
- rdo_manwomflag.disabled = "true";
- ipt_termfromdd.disabled = "true";
- ipt_termtodd.disabled = "true";
- cmb_ageflag.disabled = "true";
- chk_appinst.disabled = "true";
- rdo_essntermflag.disabled = "true";
- }
- }
- /**
- * @group :
- * @ver : 2007.03.20
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 진단/MORPHOLOGY 노드세팅
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fCntlReset( flag ) {
- if(flag == "diag"){
- if(model.getValue("/root/hidden/condition/status")=="ETN"){
- model.resetInstanceNode("/root/main/peprterminfo/info/snmdcnptid");
- model.resetInstanceNode("/root/main/peprterminfo/info/snmdcnptnm");
- model.resetInstanceNode("/root/main/peprterminfo/info/lglydisflag");
- }
- model.resetInstanceNode("/root/main/peprterminfo/info/serdiagclsyn");
- model.resetInstanceNode("/root/main/peprterminfo/info/chrncsickyn");
- model.resetInstanceNode("/root/main/peprterminfo/info/estmexptyn");
- model.resetInstanceNode("/root/main/peprterminfo/info/termengnm");
- model.resetInstanceNode("/root/main/peprterminfo/info/termhngnm");
- model.resetInstanceNode("/root/main/peprterminfo/info/reprflag");
- model.resetInstanceNode("/root/main/peprterminfo/info/ageflag");
- } else if(flag == "kcd4m"){
- model.resetInstanceNode("/root/main/kcd4minfo/info");
- }
- }
- /**
- * @group :
- * @ver : 2007.03.20
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : ICD10코드 추가 및 삭제
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fAddRow(flag) {
- var iRow = 0;
- var currentTime = getCurrentTime();
- if(flag == "I") {
- grd_icd10.addItem();
- iRow = grd_icd10.row - grd_icd10.fixedRows + 1;
- model.setValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/state", "I");
- model.setValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/icd10todd", "99991231");
-
- // Edited by 나종천 ICD10 신규 추가 2008-06-16
- model.setValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/lastupdtdt", model.getValue("/root/init/today") + currentTime.substr(0,6));
- model.setValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/fstrgstdt", model.getValue("/root/init/today") + currentTime.substr(0,6));
- model.setValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/fstrgstrid", model.getValue("/root/init/userinfo/userid"));
- model.setValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/lastupdtrid", model.getValue("/root/init/userinfo/userid"));
- model.setValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/icd10fromdd", model.getValue("/root/init/today"));
- } else if(flag == "D") {
- grd_diagcd.addItem();
- iRow = grd_diagcd.row - grd_diagcd.fixedRows + 1;
- model.setValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/state", "I" );
- model.setValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/termtodd", "99991231");
- }
- }
- /**
- * @group :
- * @ver : 2007.04.09
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 과진단추가시 진단 용어 조회
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fSrchDiagInfo(){
- var sCondPath = "/root/hidden/condition/deptset";
- var sSrchedDiagCdInfoPath = "/root/main/srcheddiagcdlist/srcheddiagcdinfo";
- var srchnm = model.getValue(sCondPath+"/srchnm");
- srchnm = srchnm.replace(/^ *| *$/g, "");
-
- model.removenode("/root/send");
- if(srchnm == ""){
- messageBox("조회 할 내용을","C001");
- return;
- }
- model.removenodeset(sSrchedDiagCdInfoPath);
- grd_srcheddiaginfo.rebuild();
- model.makeValue("/root/send/srchflag", model.getValue(sCondPath+"/srchflag")); //
- model.makeValue("/root/send/srchnm", srchnm); // ??????
- model.makeValue("/root/send/termflag", model.getValue("/root/hidden/condition/indxflag")); // ????????
- submit("TRMRT00211");
- }
- /**
- * @group :
- * @ver : 2007.04.10
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 과진단에 진단 추가
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fSendDeptDiag(){
- var sCondPath = "/root/hidden/condition/deptset";
- var sIndxListPath = "/root/main/indxlist/item";
- var sSrchedDiagCdListPath = "/root/main/srcheddiagcdlist/srcheddiagcdinfo";
- var sDeptDiagCdListPath = "/root/main/deptdiagcdlist/deptdiagcdinfo";
- var sDeptCd = model.getValue(sCondPath+"/selecteddeptcd");
- var sIndxCd = model.getValue("/root/hidden/condition/selectedIndx");
- var sIndxNm = model.getValue("/root/main/indxlist/item[indxcd='"+sIndxCd+"']/indxhngnm");
- var sSrchedDiagRowCnt = grd_srcheddiaginfo.rows - grd_srcheddiaginfo.fixedrows;
- var iDeptDiagRow = 0;
- var sTermcd = "";
- if(sDeptCd == ""){
- messageBox("부서코드를 먼저", "C002");
- return;
- }
-
- if(sIndxCd == ""){
- messageBox("색인코드를 먼저", "C002");
- return;
- }
- //debugger;
- for(var iSrchedDiagRow = 1; iSrchedDiagRow <= sSrchedDiagRowCnt; iSrchedDiagRow++){
- if(model.getValue(sSrchedDiagCdListPath+"["+iSrchedDiagRow+"]/check") == "true"){
- sTermcd = model.getValue(sSrchedDiagCdListPath+"["+iSrchedDiagRow+"]/termcd");
- if(model.getValue(sDeptDiagCdListPath+"[termcd = '"+sTermcd+"' and deptindxcd = '"+sIndxCd+"']/termcd") != "") continue;
- grd_deptdiag.addItem();
- iDeptDiagRow = grd_deptdiag.rows - grd_deptdiag.fixedrows;
- model.setValue(sDeptDiagCdListPath+"["+iDeptDiagRow+"]/status","I");
- model.setValue(sDeptDiagCdListPath+"["+iDeptDiagRow+"]/deptcd",sDeptCd);
- model.setValue(sDeptDiagCdListPath+"["+iDeptDiagRow+"]/deptnm",model.getValue(sCondPath+"/selecteddeptnm"));
- model.setValue(sDeptDiagCdListPath+"["+iDeptDiagRow+"]/termcd",sTermcd);
- model.setValue(sDeptDiagCdListPath+"["+iDeptDiagRow+"]/deptindxcd",sIndxCd);
- model.setValue(sDeptDiagCdListPath+"["+iDeptDiagRow+"]/deptindxnm",sIndxNm);
- model.setValue(sDeptDiagCdListPath+"["+iDeptDiagRow+"]/termengnm",model.getValue(sSrchedDiagCdListPath+"["+iSrchedDiagRow+"]/termengnm"));
- model.setValue(sDeptDiagCdListPath+"["+iDeptDiagRow+"]/termhngnm",model.getValue(sSrchedDiagCdListPath+"["+iSrchedDiagRow+"]/termhngnm"));
- model.setValue(sDeptDiagCdListPath+"["+iDeptDiagRow+"]/deptindxflag",model.getValue("/root/hidden/condition/indxflag"));
- }
- }
- grd_deptdiag.rebuild();
-
- }
- /**
- * @group :
- * @ver : 2007.04.11
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 과진단 저장
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fSaveDeptDiagInfo(){
- var xCondPath = "/root/hidden/condition";
- var sSelIndxCd = model.getValue(xCondPath+"/selectedIndx");
- model.removenode("/root/send");
- model.makeValue("/root/send/indxcd", sSelIndxCd);
- model.makeValue("/root/send/indxflag", model.getValue("/root/hidden/condition/indxflag"));
- model.makeValue("/root/send/deptcd", model.getValue(xCondPath+"/deptset/selecteddeptcd"));
- model.makeValue("/root/send/deptdiagcdlist", grd_deptdiag.getUpdateDataAll("i"));
-
- if(submit("TXMRT00203")) fSrchDeptDiagInfo();
- }
- /**
- * @group :
- * @ver : 2007.04.11
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 선택부서 과진단 조회
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fSrchDeptDiagInfo(){
- var xCondPath = "/root/hidden/condition";
- var sIndxCd = model.getValue(xCondPath+"/selectedIndx");
- var sDeptCd = model.getValue(xCondPath+"/deptset/selecteddeptcd");
- if(sDeptCd == ""){
- messageBox("부서코드를 먼저", "C002");
- return;
- }
-
- if(sIndxCd == ""){
- messageBox("색인코드를 먼저", "C002");
- return;
- }
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/indxcd", sIndxCd);
- model.makeValue("/root/send/indxflag", model.getValue(xCondPath+"/indxflag"));
- model.makeValue("/root/send/deptcd", sDeptCd);
- model.makeValue("/root/send/pagesize",pagesize);
- model.makeValue("/root/send/offset","0");
- model.removenodeset("/root/main/deptdiagcdlist/deptdiagcdinfo");
- pinfo = 1;
- submit("TRMRT00212");
- }
- /**
- * @group :
- * @ver : 2007.04.11
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 부서 선택 팝업 호출
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fCallDeptInfo(){
- var xCondPath = "/root/hidden/condition";
- model.removenodeset("/root/main/indxlist/item");
- model.removenodeset("/root/main/deptdiagcdlist/deptdiagcdinfo");
- trv_dgindx.rebuild();
- grd_deptdiag.rebuild();
- zbcfOpenInstDeptCodeList("deptnm", model.getValue(xCondPath+"/deptset/selecteddeptnm"), xCondPath+"/deptset/selecteddeptcd", xCondPath+"/deptset/selecteddeptnm", "ordduseryn", "");
-
- if(model.getValue(xCondPath+"/deptset/selecteddeptcd") != ""){
- model.removenode("/root/send");
- model.makeValue("/root/send/indxflag", model.getValue("/root/hidden/condition/indxflag"));
- model.makeValue("/root/send/deptcd", model.getValue("/root/hidden/condition/deptset/selecteddeptcd"));
- if(submit("TRMRT00210")){
- model.removenodeset("/root/main/deptdiagcdlist/deptdiagcdinfo");
- model.setValue(xCondPath+"/selectedIndx","");
- grd_deptdiag.rebuild();
- }
- }else{
- model.refresh();
- }
- }
- /**
- * @group :
- * @ver : 2007.04.12
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 전체진단조회 팝업 호출
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fCallExtnDiagInfo(){
- setParameter("indxflag", model.getValue("/root/hidden/condition/indxflag"));
- modal("SPMRT01000", 1,10,10);
- }
- /**
- * @group :
- * @ver : 2007.04.12
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : KCD4M 용어 컨트롤 세팅
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- function fCtrlSet(flag){
- if(flag == "N"){
- ipt_morphlgccd.disabled = "false";
- ipt_kcd4mseqno.disabled = "false";
- ipt_kcdsnmdcnptid.disabled = "false";
- ipt_kcd4mengnm.disabled = "false";
- ipt_kcd4mhngnm.disabled = "false";
- ipt_kcd4mfromdate.disabled = "false";
- ipt_kcd4mtodate.disabled = "false";
- cmb_version.disabled = "false";
- } else if(flag == "M") {
- ipt_kcd4mengnm.disabled = "false";
- ipt_kcd4mhngnm.disabled = "false";
- ipt_kcdsnmdcnptid.disabled = "false";
- ipt_kcd4mfromdate.disabled = "false";
- ipt_kcd4mtodate.disabled = "false";
- cmb_version.disabled = "false";
- }else {
- ipt_morphlgccd.disabled = "true";
- ipt_kcd4mengnm.disabled = "true";
- ipt_kcd4mhngnm.disabled = "true";
- ipt_kcd4mfromdate.disabled = "true";
- ipt_kcd4mtodate.disabled = "true";
- ipt_kcd4mseqno.disabled = "true";
- ipt_kcdsnmdcnptid.disabled = "true";
- cmb_version.disabled = "true";
- }
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : ICD10코드 리스트를 조회
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fSelICD10List(){
- var sSelectedMode = model.getValue("/root/hidden/condition/selctedmode");
- btn_addrow.attribute("visibility") = "visible";
- btn_delrow.attribute("visibility") = "visible";
- btn_saverow.attribute("visibility") = "visible";
- btn_modify.attribute("visibility") = "visible";
- cap_selInst.visible = false;
- cmb_selInst.visible = false;
-
- if(sSelectedMode == "K" || sSelectedMode == "P") {
- model.setValue("/root/hidden/condition/indxflag", "0");
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/mode",model.getValue("/root/hidden/condition/indxviewmode"));
- model.makeValue("/root/send/indxflag",model.getValue("/root/hidden/condition/indxflag"));
-
- submit("TRMRT00201");
- model.refresh();
- }
- model.setValue("/root/hidden/condition/selctedmode", "I");
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 진단코드 리스트를 조회
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- function fSelDiagList(){
- var sSelectedMode = model.getValue("/root/hidden/condition/selctedmode");
- btn_addrow.attribute("visibility") = "hidden";
- btn_delrow.attribute("visibility") = "hidden";
- btn_saverow.attribute("visibility") = "visible";
- btn_modify.attribute("visibility") = "hidden";
- //2009-03-19 오후 2:26:46 강지훈 수정 : 기관별 용어를 조회한다.
- if(getUserInfo("dutplceinstcd") == "001"){
- cap_selInst.visible = true;
- cmb_selInst.visible = true;
- }
-
-
-
- if(sSelectedMode == "K" || sSelectedMode == "P") {
- model.setValue("/root/hidden/condition/indxflag", "0");
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/mode",model.getValue("/root/hidden/condition/indxviewmode"));
- model.makeValue("/root/send/indxflag",model.getValue("/root/hidden/condition/indxflag"));
- model.makeValue("/root/send/indxuseflag",model.getValue("/root/hidden/condition/indxuseflag"));
- submit("TRMRT00201");
- model.refresh();
- }
- model.setValue("/root/hidden/condition/selctedmode", "D");
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : Morphology코드 리스트를 조회
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- function fSelMorphoList(){
- btn_addrow.attribute("visibility") = "hidden";
- btn_delrow.attribute("visibility") = "hidden";
- btn_saverow.attribute("visibility") = "hidden";
- btn_modify.attribute("visibility") = "hidden";
- cap_selInst.visible = false;
- cmb_selInst.visible = false;
-
- model.setValue("/root/hidden/condition/selctedmode", "K");
- model.setValue("/root/hidden/condition/indxflag", "4");
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/mode",model.getValue("/root/hidden/condition/indxviewmode"));
- model.makeValue("/root/send/indxflag",model.getValue("/root/hidden/condition/indxflag"));
- submit("TRMRT00201");
- model.refresh();
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 동의어 리스트에서 선택
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fGetSynom(){
- var iRow = grd_termlist.row;
- var indx = model.getValue("/root/hidden/condition/selectedIndx");
- var icd10 = model.getValue("/root/hidden/condition/selectedicd10");
- var path = model.getValue("/root/hidden/condition/selectedIndxPath");
- var term = model.getValue("/root/main/sametermlist/info[" + iRow + "]/termcd");
- model.setValue("/root/hidden/condition/selectedtermcd", term);
- opt_Hdicd10cd.visible = "true";
- cmb_icd10cd.visible = "false";
- btn_delete2.disabled = "false";
- fDisabled("AS");
- if( !isNull(iRow) ) {
- model.setValue("/root/hidden/condition/status", "STM");
-
- model.setValue("/root/main/peprterminfo/info/icd10cd", term.split(".")[0]); // ICD10
- model.setValue("/root/main/peprterminfo/info/diagattrcd", term.split(".")[1]); // 확장코드
- model.setValue("/root/main/peprterminfo/info/termcd", term.split(".")[2]); // 대표어(동의어)코드
- model.setValue("/root/main/peprterminfo/info/snmdcnptid", model.getValue("/root/main/sametermlist/info[" + iRow + "]/snmdcnptid")); // 스노메드-cnpt id
- model.setValue("/root/main/peprterminfo/info/snmdcnptnm", model.getValue("/root/main/sametermlist/info[" + iRow + "]/snmdcnptnm")); // 스노메드-cncpt 명
- model.setValue("/root/main/peprterminfo/info/umlscd", model.getValue("/root/main/sametermlist/info[" + iRow + "]/umlscd")); // UMLS 코드
- model.setValue("/root/main/peprterminfo/info/termengnm", model.getValue("/root/main/sametermlist/info[" + iRow + "]/termengnm")); // 영문
- model.setValue("/root/main/peprterminfo/info/termhngnm", model.getValue("/root/main/sametermlist/info[" + iRow + "]/termhngnm")); // 한글
- model.setValue("/root/main/peprterminfo/info/reprflag", model.getValue("/root/main/sametermlist/info[" + iRow + "]/reprflag")); // 대표어구분
- model.setValue("/root/main/peprterminfo/info/termflag", model.getValue("/root/main/sametermlist/info[" + iRow + "]/termflag")); // 용어구분
- model.setValue("/root/main/peprterminfo/info/fstrgstrid", model.getValue("/root/main/sametermlist/info[" + iRow + "]/lastupdtrnm")); // 최종등록자
- //저장시 필요한 키값
- model.setValue("/root/main/peprterminfo/info/attrfromdd", model.getValue("/root/main/sametermlist/info[" + iRow + "]/attrfromdd"));
- model.setValue("/root/main/peprterminfo/info/attrtodd", model.getValue("/root/main/sametermlist/info[" + iRow + "]/attrtodd"));
- model.setValue("/root/main/peprterminfo/info/icdfromdd", model.getValue("/root/main/sametermlist/info[" + iRow + "]/icdfromdd"));
- model.setValue("/root/main/peprterminfo/info/alttermcd", model.getValue("/root/main/sametermlist/info[" + iRow + "]/alttermcd"));
- model.setValue("/root/main/peprterminfo/info/essntermflag", model.getValue("/root/main/sametermlist/info[" + iRow + "]/essntermflag"));
- model.setValue("/root/main/peprterminfo/info/appinstcd", model.getValue("/root/main/sametermlist/info[" + iRow + "]/appinstcd")); //적용기관
-
- var fstrgstdt = model.getValue("/root/main/sametermlist/info[" + iRow + "]/fstrgstdt");
- var termfromdd = model.getValue("/root/main/sametermlist/info[" + iRow + "]/termfromdd");
- var termtodd = model.getValue("/root/main/sametermlist/info[" + iRow + "]/termtodd");
- model.setValue("/root/main/peprterminfo/info/fstrgstdt", fstrgstdt); // 등록일
- model.setValue("/root/main/peprterminfo/info/fstrgstdate", fstrgstdt.substr(0,8));
- model.setValue("/root/main/peprterminfo/info/fstrgsttime", fstrgstdt.substr(8,4));
- model.setValue("/root/main/peprterminfo/info/termfromdd", termfromdd); // 시작일
- model.setValue("/root/main/peprterminfo/info/termtodd", termtodd); // 종료일
-
-
-
-
- model.refresh();
- }
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 동의어 등록
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- function fSetInj(){
- //동의어 신규
- var jRow = grd_diagcd.row;
- var term1 = model.getValue("/root/main/diagcdinfo/diagcd[" + jRow + "]/termcd"); //그리드에서 선택한 term
- var diagattr = model.getValue("/root/main/diagcdinfo/diagcd[" + jRow + "]/diagattrcd"); //그리드에서 선택한 term
- var icd10cd = model.getValue("/root/main/diagcdinfo/diagcd[" + jRow + "]/icd10cd"); //그리드에서 선택한 term
- var indx = model.getValue("/root/hidden/condition/selectedIndx"); //트리에서 선택한 index
- var fromdd = ((getCurrentDate()).toDate()).getAddDate(1);
-
- if(term1 == "" || term1 == null){
- var rtn = messageBox("진단 용어를 ", "C002");
- return;
- }
- fDisabled("TN");
- opt_Hdicd10cd.visible = "true";
- cmb_icd10cd.visible = "false";
- btn_delete2.disabled = "true";
- fCntlReset("diag");
- model.setValue("/root/hidden/condition/status", "TN"); //term만 new
- model.removeNodeset("/root/send");
- model.removeNodeset("/root/main/temp");
- model.makeValue("/root/send/reqdata/icd10cd", icd10cd);
- model.makeValue("/root/send/reqdata/diagattrcd", diagattr);
- model.makeNode("/root/main/temp/info");
- submit("TRMRT00208");
- model.setValue("/root/main/peprterminfo/info/icd10cd", model.getValue("/root/main/temp/info/icd10cd"));
- model.setValue("/root/main/peprterminfo/info/diagattrcd", model.getValue("/root/main/temp/info/diagattrcd").split(".")[1]);
- model.setValue("/root/main/peprterminfo/info/termcd", model.getValue("/root/main/temp/info/termcd"));
- // Edited by 2007-08-16 대표어 'R' 그 외 값은 ''로 처리
- // model.setValue("/root/main/peprterminfo/info/reprflag", "S");
- model.setValue("/root/main/peprterminfo/info/reprflag", "");
- model.setValue("/root/main/peprterminfo/info/diagattrmedireccd", model.getValue("/root/main/diagcdinfo/diagcd[" + jRow + "]/diagattrmedireccd"));
- var path = model.getValue("/root/hidden/condition/selectedIndxPath").split(".");
- model.setValue("/root/main/peprterminfo/info/diagattrdrindxcd", path[path.length-2]);
- model.setValue("/root/main/peprterminfo/info/termflag", "0");
- model.setValue("/root/main/peprterminfo/info/fstrgstrid", model.getValue("/root/init/userinfo/userid"));
- model.setValue("/root/main/peprterminfo/info/termengnm", model.getValue("/root/main/diagcdinfo/diagcd[" + jRow + "]/termengnm"));
- model.setValue("/root/main/peprterminfo/info/termhngnm", model.getValue("/root/main/diagcdinfo/diagcd[" + jRow + "]/termhngnm"));
- model.makeValue("/root/main/peprterminfo/info/oldattrfromdd", model.getValue("/root/main/diagcdinfo/diagcd[" + jRow + "]/attrfromdd"));
- //신규 등록 모드는 디폴트를 설정
- model.setValue("/root/main/peprterminfo/info/fstrgstdate", model.getValue("/root/init/today"));
- model.setValue("/root/main/peprterminfo/info/fstrgsttime", model.getValue("/root/init/curruntTime"));
- model.setValue("/root/main/peprterminfo/info/fstrgstdt", model.getValue("/root/main/peprterminfo/info/fstrgstdate")+model.getValue("/root/main/peprterminfo/info/fstrgsttime")+"00");
- model.setValue("/root/main/peprterminfo/info/termfromdd", fromdd.getDateFormat());
- model.setValue("/root/main/peprterminfo/info/termtodd", "99991231");
- model.setValue("/root/main/peprterminfo/info/fstrgstrid", model.getValue("/root/init/userinfo/usernm"));
- model.refresh();
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 신규 용어 등록
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- function fSetNewTerm(){
- var sIndx = model.getValue("/root/hidden/condition/selectedIndx");
- var fromdd = ((getCurrentDate()).toDate()).getAddDate(1);
- var maininstyn = model.getValue("/root/hidden/condition/maininstyn");
-
- if(sIndx == "" || sIndx == null){
- var rtn = messageBox("색인을 ", "C002");
- return;
- }
-
- model.setValue("/root/main/peprterminfo/info/appinstcd", "");
- model.setValue("/root/main/peprterminfo/info/essntermflag", "N");
- model.removeNodeset("/root/main/sametermlist/info"); // 신규버튼 클릭시 동의어 그리드 초기화
- model.setValue("/root/hidden/condition/status", "ETN");
- opt_Hdicd10cd.visible = "false";
- cmb_icd10cd.visible = "true";
- btn_delete2.disabled = "true";
- fCntlReset("diag");
- fDisabled("ETN");
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/indxcd",sIndx);
- model.makeValue("/root/send/indxflag",model.getValue("/root/hidden/condition/indxflag"));
-
- //선택한 인덱스에 해당하는 ICD10코드를 가지고 온다..
- submit("TRMRT00206");
- cmb_icd10cd.refresh();
- cmb_reprflag.select(0);
- // Edited by NJ 2007-07-21 getDate() -> getCurrentDate()
- //model.setValue("/root/main/peprterminfo/info/attrfromdd", getDate() );
- model.setValue("/root/main/peprterminfo/info/termfromdd", fromdd.getDateFormat());
- model.setValue("/root/main/peprterminfo/info/termtodd", "99991231");
- model.setValue("/root/main/peprterminfo/info/attrfromdd", model.getValue("/root/main/peprterminfo/info/termfromdd"));
- model.setValue("/root/main/peprterminfo/info/attrtodd", model.getValue("/root/main/peprterminfo/info/termtodd"));
- model.setValue("/root/main/peprterminfo/info/fstrgstdate", getCurrentDate());
- model.setValue("/root/main/peprterminfo/info/fstrgsttime", getCurrentTime());
- model.setValue("/root/main/peprterminfo/info/fstrgstrid", getUserName());
- model.refresh();
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 용어 수정
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- function fSetTermUpdt(){
- var selTermcd = model.getValue("/root/hidden/condition/selectedtermcd");
- var fromdd = ((getCurrentDate()).toDate()).getAddDate(1);
- if(selTermcd == "" || selTermcd == null){
- var rtn = messageBox("icd10 코드를 ", "C002");
- return;
- }
- // Edited by NJ 2007-07-21 getDate() -> getCurrentDate()
- //var today = getDate();
- var today = getCurrentDate();
-
- //alert(today);
- //alert(model.getValue("/root/main/peprterminfo/info/termfromdd"));
- if(model.getValue("/root/main/peprterminfo/info/termfromdd") >= today){
- var rtn = messageBox("당일 등록한 용어는 수정 ", "E001");
- return;
- }
- fDisabled("ETM");
- model.setValue("/root/hidden/condition/status", "ETM");
- btn_delete2.disabled = "true";
- model.makeValue("/root/main/peprterminfo/info/oldtermfromdd", model.getValue("/root/main/peprterminfo/info/termfromdd"));
- model.makeValue("/root/main/peprterminfo/info/oldattrfromdd", model.getValue("/root/main/peprterminfo/info/attrfromdd"));
- model.setValue("/root/main/peprterminfo/info/termfromdd", fromdd.getDateFormat());
- model.setValue("/root/main/peprterminfo/info/termtodd", "99991231");
- model.setValue("/root/main/peprterminfo/info/attrfromdd", model.getValue("/root/main/peprterminfo/info/termfromdd"));
- model.setValue("/root/main/peprterminfo/info/attrtodd", model.getValue("/root/main/peprterminfo/info/termtodd"));
- model.setValue("/root/main/peprterminfo/info/fstrgstdate", getCurrentDate());
- model.setValue("/root/main/peprterminfo/info/fstrgsttime", getCurrentTime());
- model.setValue("/root/main/peprterminfo/info/fstrgstrid", getUserName());
- model.refresh();
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 진단용어 저장
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fSaveDiag(){
- var insICD10cd = model.getValue("/root/main/peprterminfo/info/icd10cd");
- var insdiagattrcd = model.getValue("/root/main/peprterminfo/info/diagattrcd");
- var insTermcd = model.getValue("/root/main/peprterminfo/info/termcd");
- var fullTermCode = insICD10cd + "." + insdiagattrcd + "." + insTermcd;
- var rowCnt = grd_diagcd.row;
- var orgReprFlag = model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/reprflag"); //상단 그리드의 원래 대표어구분
- var chngReprFlag = model.getValue("/root/main/peprterminfo/info/reprflag"); //저장시, 변경된 대표어구분
- model.removeNodeset("/root/send");
- model.makeNode("/root/send/reqdata");
- model.copyNode("/root/send/reqdata", "/root/main/peprterminfo/info");
- model.setValue("/root/send/reqdata/icd10cd", insICD10cd);
- model.setValue("/root/send/reqdata/diagattrcd", insICD10cd + "." + insdiagattrcd);
- model.setValue("/root/send/reqdata/termcd", fullTermCode);
- model.setValue("/root/send/reqdata/fstrgstdt", model.getValue("/root/main/peprterminfo/info/fstrgstdate") + model.getValue("/root/main/peprterminfo/info/fstrgsttime")+"00"); //용어등록일
- model.setValue("/root/send/reqdata/termflag", "0"); //용어구분
- model.makeValue("/root/send/reqdata/indxcd", model.getValue("/root/hidden/condition/selectedIndx"));
- model.makeValue("/root/send/reqdata/status", model.getValue("/root/hidden/condition/status")); //TN:용어만 등록, ETN:용어,속성함께등록,TM:용어만수정, EM:속성만수정,
-
- model.makeValue("/root/send/reqdata/maininstyn", model.getValue("/root/hidden/condition/maininstyn"));
- model.makeValue("/root/send/reqdata/selInstcd", model.getValue("/root/hidden/condition/selInstcd"));
-
-
- //ETM:용어,속성함께수정, 용어수정+대표어교환, ETM:속성수정+대표어교환, ETFM:용어,속성수정+대표어교환, FM:대표어만 교환
- if(model.getValue("/root/hidden/condition/status") == "ETN" || model.getValue("/root/hidden/condition/status") == "TN") {
- //2009-03-28 오후 1:49:29 강지훈 수정 : 기관에서 등록할때는 적용기관이 필수이다.
- var mainInstYn = model.getValue("/root/hidden/condition/maininstyn");
- var appInstcd = model.getValue("/root/main/peprterminfo/info/appinstcd");
- if(mainInstYn == "Y" && appInstcd == ""){
- var rtn = messageBox("선택된 적용기관이 없으므로 저장 ", "E001");
- return;
- }
- if(submit("TXMRT00201")){
- fCntlReset("diag");
- model.resetInstanceNode("/root/main/peprterminfo/info");
- model.removeNodeset("/root/main/sametermlist");
- model.refresh();
- }
- } else if(model.getValue("/root/hidden/condition/status") == "STM") {
- //왼쪽 그리드에서 정보를 선택했을 때
- var sRowCnt = grd_termlist.row;
- var orgReprFlag2 = orgReprFlag2;
- if(fullTermCode == model.getValue("/root/main/sametermlist/info[" + sRowCnt + "]/termcd")) {
- if(model.getValue("/root/main/sametermlist/info[" + sRowCnt + "]/termengnm") != model.getValue("/root/main/peprterminfo/info/termengnm") ||
- model.getValue("/root/main/sametermlist/info[" + sRowCnt + "]/termhngnm") != model.getValue("/root/main/peprterminfo/info/termhngnm") ||
- model.getValue("/root/main/sametermlist/info[" + sRowCnt + "]/termflag") != model.getValue("/root/main/peprterminfo/info/termflag")) {
- if(orgReprFlag2 != chngReprFlag ){
- if(orgReprFlag2 != "R" ) {
- //동의어나 유사어를 대표어로 수정하는 경우 (대표어구분코드를 맞교환)
- if( chngReprFlag != "R" )
- model.setValue("/root/send/reqdata/status", "TM");
- else {
- model.setValue("/root/send/reqdata/orgreprflag", orgReprFlag2); //대표어구분을 교환하기 위해 원래 값을 다시 세팅한다.
- model.setValue("/root/send/reqdata/status", "TFM");
- }
- if(submit("TXMRT00201")){
- fCntlReset("diag");
- model.removeNodeset("/root/main/sametermlist");
- model.resetInstanceNode("/root/main/peprterminfo/info");
- model.refresh();
- }
- } else {
- var rtn = messageBox("대표어를 동의어나 유사어로 수정 ", "E001");
- return;
- //동의어를 대표어로 바꾸는 것만 허용
- }
- } else {
- model.setValue("/root/send/reqdata/status", "TM");
- if(submit("TXMRT00201")){
- fCntlReset("diag");
- model.removeNodeset("/root/main/sametermlist");
- model.resetInstanceNode("/root/main/peprterminfo/info");
- model.refresh();
- }
- }
- } else {
- var rtn = messageBox("변경된 내용이 없으므로 저장 ", "E001");
- return;
- }
- } else {
- var rtn = messageBox("신규입력 버튼을 ", "C002");
- return;
- }
- } else {
- if(fullTermCode == model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/termcd")) {
- // 용어명칭이 바뀐 경우
- if(model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/termengnm") != model.getValue("/root/main/peprterminfo/info/termengnm") ||
- model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/termhngnm") != model.getValue("/root/main/peprterminfo/info/termhngnm") ||
- model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/termflag") != model.getValue("/root/main/peprterminfo/info/termflag") ||
- model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/essntermflag") != model.getValue("/root/main/peprterminfo/info/essntermflag")) {
-
- if(model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/lglydisflag") != model.getValue("/root/main/peprterminfo/info/lglydisflag") ||
- model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/chrncsickyn") != model.getValue("/root/main/peprterminfo/info/chrncsickyn") ||
- model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/estmexptyn") != model.getValue("/root/main/peprterminfo/info/estmexptyn") ||
- model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/serdiagclsyn") != model.getValue("/root/main/peprterminfo/info/serdiagclsyn") ||
- model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/manwomflag") != model.getValue("/root/main/peprterminfo/info/manwomflag") ||
- model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/cncryn") != model.getValue("/root/main/peprterminfo/info/cncryn") ||
- //model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/diagattrdrindxcd") != model.getValue("/root/main/peprterminfo/info/diagattrdrindxcd") ||
- model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/diagattrmedireccd") != model.getValue("/root/main/peprterminfo/info/diagattrmedireccd") ||
- model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/diagattrverflag") != model.getValue("/root/main/peprterminfo/info/diagattrverflag") ||
- //model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/snmdcnptid") != model.getValue("/root/main/peprterminfo/info/snmdcnptid") ||
- //model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/snmdcnptnm") != model.getValue("/root/main/peprterminfo/info/snmdcnptnm") ||
- model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/ageflag") != model.getValue("/root/main/peprterminfo/info/ageflag")) {
-
- if(orgReprFlag != chngReprFlag ){
- if(orgReprFlag != "R" ) {
- //동의어나 유사어를 대표어로 수정하는 경우 (대표어구분코드를 맞교환)
- if( chngReprFlag != "R" )
- model.setValue("/root/send/reqdata/status", "ETM"); // 유사어 구분이 없기 때문에 이 로직은 타지 않는다.
- else {
- model.makeValue("/root/send/reqdata/orgreprflag", orgReprFlag); //대표어구분을 교환하기 위해 원래 값을 다시 세팅한다.
- model.setValue("/root/send/reqdata/status", "ETFM");
- }
- if(submit("TXMRT00201")){
- fCntlReset("diag");
- model.removeNodeset("/root/main/sametermlist");
- model.resetInstanceNode("/root/main/peprterminfo/info");
- model.refresh();
- }
- } else {
- var rtn = messageBox("대표어를 동의어나 유사어로 수정 ", "E001");
- return;
- //동의어를 대표어로 바꾸는 것만 허용
- }
- } else {
- model.setValue("/root/send/reqdata/status", "ETM");
- if(submit("TXMRT00201")){
- fCntlReset("diag");
- model.removeNodeset("/root/main/sametermlist");
- model.resetInstanceNode("/root/main/peprterminfo/info");
- model.refresh();
- }
- }
- } else {
- //용어테이블만 수정되었을 경우
- if(orgReprFlag != chngReprFlag ){
- if(orgReprFlag != "R" ) {
- //동의어나 유사어를 대표어로 수정하는 경우 (대표어구분코드를 맞교환)
- if( chngReprFlag != "R" )
- model.setValue("/root/send/reqdata/status", "TM"); // 동의어 유사어 구분이 없기 때문에 이 로직은 타지 않는다
- else {
- model.makeValue("/root/send/reqdata/orgreprflag", orgReprFlag); //대표어구분을 교환하기 위해 원래 값을 다시 세팅한다.
- model.setValue("/root/send/reqdata/status", "TFM");
- }
- if(submit("TXMRT00201")){
- fCntlReset("diag");
- model.removeNodeset("/root/main/sametermlist");
- model.resetInstanceNode("/root/main/peprterminfo/info");
- model.refresh();
- }
- } else {
- var rtn = messageBox("대표어를 동의어나 유사어로 수정 ", "E001");
- return;
- //동의어를 대표어로 바꾸는 것만 허용
- }
- } else {
- model.setValue("/root/send/reqdata/status", "TM");
- if(submit("TXMRT00201")){
- fCntlReset("diag");
- model.removeNodeset("/root/main/sametermlist");
- model.resetInstanceNode("/root/main/peprterminfo/info");
- model.refresh();
- }
- }
- }
- // 용어 명칭 외의 것이 바뀐 경우
- } else {
- //속성만 수정
- if(model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/lglydisflag") != model.getValue("/root/main/peprterminfo/info/lglydisflag") ||
- model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/chrncsickyn") != model.getValue("/root/main/peprterminfo/info/chrncsickyn") ||
- model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/estmexptyn") != model.getValue("/root/main/peprterminfo/info/estmexptyn") ||
- model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/serdiagclsyn") != model.getValue("/root/main/peprterminfo/info/serdiagclsyn") ||
- model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/manwomflag") != model.getValue("/root/main/peprterminfo/info/manwomflag") ||
- model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/cncryn") != model.getValue("/root/main/peprterminfo/info/cncryn") ||
- //model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/diagattrdrindxcd") != model.getValue("/root/main/peprterminfo/info/diagattrdrindxcd") ||
- model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/diagattrmedireccd") != model.getValue("/root/main/peprterminfo/info/diagattrmedireccd") ||
- model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/diagattrverflag") != model.getValue("/root/main/peprterminfo/info/diagattrverflag") ||
- //model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/snmdcnptid") != model.getValue("/root/main/peprterminfo/info/snmdcnptid") ||
- //model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/snmdcnptnm") != model.getValue("/root/main/peprterminfo/info/snmdcnptnm") ||
- model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/ageflag") != model.getValue("/root/main/peprterminfo/info/ageflag")) {
-
- if(orgReprFlag != chngReprFlag ){
- if(orgReprFlag != "R" ) {
- //동의어나 유사어를 대표어로 수정하는 경우 (대표어구분코드를 맞교환)
- if( chngReprFlag != "R" )
- model.setValue("/root/send/reqdata/status", "ETM"); // 동의어 유사어 구분이 없기 때문에 이 로직은 타지 않는다
- else {
- //2009 02 16 강지훈 수정 : 오류수정
- //model.setValue("/root/send/reqdata/orgreprflag", orgReprFlag); //대표어구분을 교환하기 위해 원래 값을 다시 세팅한다.
- model.makeValue("/root/send/reqdata/orgreprflag", orgReprFlag); //대표어구분을 교환하기 위해 원래 값을 다시 세팅한다.
- model.setValue("/root/send/reqdata/status", "EFM");
- }
- if(submit("TXMRT00201")){
- fCntlReset("diag");
- model.removeNodeset("/root/main/sametermlist");
- model.resetInstanceNode("/root/main/peprterminfo/info");
- model.refresh();
- }
- } else {
- var rtn = messageBox("대표어를 동의어나 유사어로 수정 ", "E001");
- return;
- //동의어를 대표어로 바꾸는 것만 허용
- }
- } else {
- model.setValue("/root/send/reqdata/status", "EM");
- if(submit("TXMRT00201")){
- fCntlReset("diag");
- model.removeNodeset("/root/main/sametermlist");
- model.resetInstanceNode("/root/main/peprterminfo/info");
- model.refresh();
- }
- }
- } else {
- //순수 용어 테이블만 수정되었을 경우(기존에는 대표어, 동의어)
- //alert(orgReprFlag + "||" + chngReprFlag);
-
- if(orgReprFlag != chngReprFlag ){
- if(orgReprFlag != "R" ) {
- //동의어나 유사어를 대표어로 수정하는 경우 (대표어구분코드를 맞교환)
- if( chngReprFlag != "R" )
- model.setValue("/root/send/reqdata/status", "TM");
- else {
- if (model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/snmdcnptid") != model.getValue("/root/main/peprterminfo/info/snmdcnptid"))
- {
- model.setValue("/root/send/reqdata/status", "TM");
- }
- else {
-
- //2009 02 16 강지훈 수정 : 오류수정
- //model.setValue("/root/send/reqdata/orgreprflag", orgReprFlag); //대표어구분을 교환하기 위해 원래 값을 다시 세팅한다.
- model.makeValue("/root/send/reqdata/orgreprflag", orgReprFlag); //대표어구분을 교환하기 위해 원래 값을 다시 세팅한다.
- model.setValue("/root/send/reqdata/status", "FM");
- }
- }
- if(submit("TXMRT00201")){
- fCntlReset("diag");
- model.removeNodeset("/root/main/sametermlist");
- model.resetInstanceNode("/root/main/peprterminfo/info");
- model.refresh();
- }
- } else {
- var rtn = messageBox("대표어를 동의어나 유사어로 수정 ", "E001");
- return;
- //동의어를 대표어로 바꾸는 것만 허용
- }
- // 대표어구분이 바뀌지 않고 snomed만 바뀐 경우
- } else {
- if (model.getValue("/root/main/diagcdinfo/diagcd[" + rowCnt + "]/snmdcnptid") != model.getValue("/root/main/peprterminfo/info/snmdcnptid"))
- {
- model.setValue("/root/send/reqdata/status", "TM");
- if(submit("TXMRT00201")){
- fCntlReset("diag");
- model.removeNodeset("/root/main/sametermlist");
- model.resetInstanceNode("/root/main/peprterminfo/info");
- model.refresh();
- }
- }
- else
- {
- var rtn = messageBox("수정된 사항이 없으므로 수정 ", "E001");
- return;
- }
-
-
- }
- }
- }
- } else {
- var rtn = messageBox("용어를 입력하시려면 입력 버튼을 ", "C002");
- }
- }
- fDisabled("AS");
- btn_delete2.disabled = "false";
- model.setValue("/root/hidden/condition/status", "");
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 진단용어 사용종료
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- function fEndDiagTerm(){
- var selTermcd = model.getValue("/root/hidden/condition/selectedtermcd");
- var insicd10cd = model.getValue("/root/main/peprterminfo/info/icd10cd");
- var diagattrcd = model.getValue("/root/main/peprterminfo/info/diagattrcd");
- var insTermcd = model.getValue("/root/main/peprterminfo/info/termcd");
- var sRow = grd_termlist.rows - grd_termlist.fixedRows;
- if(insTermcd == "" || insTermcd == null){
- var rtn = messageBox("삭제할 진단용어를 ", "C002");
- return;
- }
- //대표어일지라도 동의어/유사어가 없다면 삭제 가능함.
- if(model.getValue("/root/main/peprterminfo/info/reprflag") == "R" && sRow >= 1) {
- model.makeValue("/root/send/reqdata/termcd", insicd10cd + "." + diagattrcd + "." + insTermcd);
- model.makeValue("/root/send/reqdata/diagattrcd", insicd10cd + "." + diagattrcd);
- model.makeValue("/root/send/reqdata/termflag", model.getValue("/root/hidden/condition/indxflag"));
- if(submit("TRMRT00215")){
- var sametermyn = model.getValue("/root/hidden/exists/sametermyn");
- if(sametermyn == "Y"){
- var rtn = messageBox("대표어는 삭제 ", "E001");
- return;
- }
- } else {
- return;
- }
- }
- var rtn = messageBox("선택한 진단용어를", "Q001");
- if( rtn == "6") { //진단코드를 삭제하시겠습니까?
- var altmsg = messageBox("대체코드를", "Q014");
- if(altmsg == "6"){
- btn_altterm.disabled = "false";
- var ref1 = "/root/main/peprterminfo/info/alttermcd";
- var altflag = fCallTermSrch(ref1);
- btn_altterm.disabled = "true";
- if(!altflag){
- return;
- }
- }
- model.setValue("/root/hidden/condition/status", "TD");
- model.removeNodeset("/root/send/reqdata");
- model.makeValue("/root/send/reqdata/indxcd", model.getValue("/root/hidden/condition/selectedIndx"));
- model.makeValue("/root/send/reqdata/icd10cd", insicd10cd);
- model.makeValue("/root/send/reqdata/diagattrcd", insicd10cd + "." + diagattrcd);
- model.makeValue("/root/send/reqdata/termcd", insicd10cd + "." + diagattrcd + "." + insTermcd);
- model.makeValue("/root/send/reqdata/status", model.getValue("/root/hidden/condition/status")); //N:등록, M:수정, D:삭제
- model.makeValue("/root/send/reqdata/termflag", "0"); //용어구분
- model.makeValue("/root/send/reqdata/termfromdd", model.getValue("/root/main/peprterminfo/info/termfromdd"));
- model.makeValue("/root/send/reqdata/oldtermfromdd", model.getValue("/root/main/peprterminfo/info/termfromdd"));
- model.makeValue("/root/send/reqdata/attrfromdd", model.getValue("/root/main/peprterminfo/info/attrfromdd"));
- model.makeValue("/root/send/reqdata/oldattrfromdd", model.getValue("/root/main/peprterminfo/info/attrfromdd"));
- model.makeValue("/root/send/reqdata/alttermcd", model.getValue("/root/main/peprterminfo/info/alttermcd"));
- submit("TXMRT00201");
- grd_diagcd.refresh();
- } else if( rtn == "7") {
- return;
- }
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 동의어 리스트 조회
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fGetSynomList(){
- grd_termlist.colHidden(1) = true;
- grd_termlist.colHidden(3) = false;
- var iRow = grd_diagcd.row;
- opt_Hdicd10cd.visible = "true";
- cmb_icd10cd.visible = "false";
-
- cap_allinsthist.visible = "false";
- cmb_allinsthist.visible = "false";
-
- btn_delete2.disabled = "true";
- btn_sameterm.disabled = "false";
- btn_modify1.disabled = "false";
- btn_rollback.disabled = "false";
- btn_termsave.disabled = "false";
-
- //2009-04-28 오후 3:21:38 강지훈 수정 : 중앙이 아닌 기관일경우 확장,용어코드가 000.00인것은 수정불가처리
- var term = model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/termcd");
- var diagattrcd = model.getValue("/root/main/peprterminfo/info/diagattrcd");
- var termcd = model.getValue("/root/main/peprterminfo/info/termcd");
- var maininstyn = model.getValue("/root/hidden/condition/maininstyn");
-
- if(maininstyn == "N" && diagattrcd == "000" && termcd == "00"){
- btn_modify1.disabled = true;
- }
- else{
- btn_modify1.disabled = false;
- }
-
- model.setValue("/root/hidden/condition/sametermmode", "U");
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/diagattrcd", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/diagattrcd"));
- model.makeValue("/root/send/sametermmode", model.getValue("/root/hidden/condition/sametermmode"));
- model.makeValue("/root/send/selInstcd", model.getValue("/root/hidden/condition/selInstcd"));
-
- submit("TRMRT00205");
- model.refresh();
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 용어 이력 리스트 조회
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- function fGetDiagTermHistList(){
- grd_termlist.colHidden(1) = true;
- grd_termlist.colHidden(3) = true;
-
- var iRow = grd_diagcd.row;
- opt_Hdicd10cd.visible = "true";
- cmb_icd10cd.visible = "false";
- cap_allinsthist.visible = "false";
- cmb_allinsthist.visible = "false";
-
- btn_delete2.disabled = "true";
- btn_sameterm.disabled = "false";
-
-
- //2009-04-28 오후 3:21:38 강지훈 수정 : 중앙이 아닌 기관일경우 확장,용어코드가 000.00인것은 수정불가처리
- var term = model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/termcd");
- var diagattrcd = model.getValue("/root/main/peprterminfo/info/diagattrcd");
- var termcd = model.getValue("/root/main/peprterminfo/info/termcd");
- var maininstyn = model.getValue("/root/hidden/condition/maininstyn");
-
- if(maininstyn == "N" && diagattrcd == "000" && termcd == "00"){
- btn_modify1.disabled = true;
- }
- else{
- btn_modify1.disabled = false;
- }
-
- btn_rollback.disabled = "false";
- btn_termsave.disabled = "false";
- model.setValue("/root/hidden/condition/sametermmode", "N");
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/diagattrcd", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/diagattrcd"));
- model.makeValue("/root/send/sametermmode", model.getValue("/root/hidden/condition/sametermmode"));
- model.makeValue("/root/send/selInstcd", model.getValue("/root/hidden/condition/selInstcd"));
- submit("TRMRT00205");
- model.refresh();
- }
- /**
- * @group :
- * @ver : 2009-02-23 오후 10:30:15
- * @by : 강지훈
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 기관별 용어 이력 리스트 조회
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fGetDiagInstTermHistList(){
- grd_termlist.colHidden(1) = false;
- grd_termlist.colHidden(3) = true;
- var iRow = grd_diagcd.row;
-
-
- opt_Hdicd10cd.visible = "true";
- cmb_icd10cd.visible = "false";
- cap_allinsthist.visible = "true";
- cmb_allinsthist.visible = "true";
-
- btn_delete2.disabled = "true";
- btn_sameterm.disabled = "true";
- btn_modify1.disabled = "true";
- btn_rollback.disabled = "true";
- btn_termsave.disabled = "true";
-
-
- model.setValue("/root/hidden/condition/sametermmode", "H");
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/diagattrcd", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/diagattrcd"));
- model.makeValue("/root/send/sametermmode", model.getValue("/root/hidden/condition/sametermmode"));
- model.makeValue("/root/send/allinsthist", model.getValue("/root/hidden/condition/allinsthist"));
- //alert(model.getValue("/root/hidden/condition/allinsthist"));
- submit("TRMRT00205");
- model.refresh();
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 용어 조회
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- function fSrchDiagTerm(){
- if(model.getValue("/root/hidden/condition/srchnm") == "" || model.getValue("/root/hidden/condition/srchnm") == null){
- var rtn = messageBox("검색어를 ", "C001");
- return;
- } else {
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/srchflag", model.getValue("/root/hidden/condition/srchflag"));
- model.makeValue("/root/send/srchnm", model.getValue("/root/hidden/condition/srchnm"));
- model.makeValue("/root/send/srchfromdd", model.getValue("/root/hidden/condition/srchfromdd"));
- model.makeValue("/root/send/srchtodd", model.getValue("/root/hidden/condition/srchtodd"));
- model.makeValue("/root/send/endflag", model.getValue("/root/hidden/condition/endflag"));
- model.makeValue("/root/send/maininstyn", model.getValue("/root/hidden/condition/maininstyn"));
- model.makeValue("/root/send/selInstcd", model.getValue("/root/hidden/condition/selInstcd"));
-
- var srchnm = model.getValue("/root/hidden/condition/srchnm");
- srchnm = srchnm.replace(/^ *| *$/g, "");
- if(model.getValue("/root/send/srchflag") == "C" || model.getValue("/root/send/srchflag") == "E") {
- srchnm = srchnm.toUpperCase();
- model.setValue("/root/send/srchnm", srchnm);
- }
-
- if(model.getValue("/root/hidden/condition/selctedmode") == "I" ) {
- model.removeNodeset("/root/main/diagcdinfo/icd10cd");
- submit("TRMRT00203");
- } else if (model.getValue("/root/hidden/condition/selctedmode") == "D" ) {
- model.removeNodeset("/root/main/diagcdinfo/diagcd");
- submit("TRMRT00204");
- } else if (model.getValue("/root/hidden/condition/selctedmode") == "K" ) {
- model.removeNodeset("/root/main/diagcdinfo/kcd4m");
- submit("TRMRT00209");
- } else if(model.getValue("/root/hidden/condition/selctedmode") == "P" ) {
- if(model.getValue("/root/hidden/condition/deptset/selecteddeptcd") == ""){
- messageBox("과를", "C002");
- return;
- }
- model.removeNodeset("/root/send");
- model.removeNodeset("/root/main/deptdiagcdlist/deptdiagcdinfo");
- model.makeValue("/root/send/indxflag", model.getValue("/root/hidden/condition/indxflag"));
- model.makeValue("/root/send/indxcd", "null");
- model.makeValue("/root/send/deptcd", model.getValue("/root/hidden/condition/deptset/selecteddeptcd"));
- model.makeValue("/root/send/srchflag", model.getValue("/root/hidden/condition/srchflag"));
- model.makeValue("/root/send/srchnm", model.getValue("/root/hidden/condition/srchnm"));
- model.makeValue("/root/send/pagesize",pagesize);
- model.makeValue("/root/send/offset","0");
- model.removenodeset("/root/main/deptdiagcdlist/deptdiagcdinfo");
- pinfo = 1;
- submit("TRMRT00212");
- }
- model.refresh();
- }
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : KCD4M 용어 사용종료
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- function fEndKCD4M(){
- model.setValue("/root/hidden/condition/status", "MD");
- model.removeNodeset("/root/send");
- model.removeNodeset("/root/main/diagcdinfo");
- model.makeValue("/root/send/morphlgccd", model.getValue("/root/main/kcd4minfo/info/morphlgccd"));
- model.makeValue("/root/send/kcd4mseqno", model.getValue("/root/main/kcd4minfo/info/kcd4mseqno"));
- model.makeValue("/root/send/indxcd", model.getValue("/root/main/kcd4minfo/info/indxcd"));
- model.makeValue("/root/send/kcd4mengnm", model.getValue("/root/main/kcd4minfo/info/kcd4mengnm"));
- model.makeValue("/root/send/kcd4mhngnm", model.getValue("/root/main/kcd4minfo/info/kcd4mhngnm"));
- model.setValue("/root/main/kcd4minfo/info/kcd4mfromdate", model.getValue("/root/init/today"));
- model.setValue("/root/main/kcd4minfo/info/kcd4mfromtime", model.getValue("/root/init/curruntTime"));
- model.setValue("/root/main/kcd4minfo/info/kcd4mtodate", getCurrentDate());
- model.setValue("/root/main/kcd4minfo/info/kcd4mtotime", "2359");
- //model.setValue("/root/main/kcd4minfo/info/fstrgstdt", "");
- //Edited by 나종천 2008-06-23 사용종료의 시작일자 수정
- model.makeValue("/root/send/oldkcd4mfromdd", model.getValue("/root/main/kcd4minfo/info/kcd4mfromdd"));
- model.makeValue("/root/send/kcd4mfromdd", model.getValue("/root/main/kcd4minfo/info/kcd4mfromdate"));
- model.makeValue("/root/send/kcd4mtodd", model.getValue("/root/main/kcd4minfo/info/kcd4mtodate"));
- model.makeValue("/root/send/status", model.getValue("/root/hidden/condition/status"));
- submit("TXMRT00202");
- fCntlReset("kcd4m");
- grd_kcd4minfo.rebuild();
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : KCD4M 용어 저장
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- function fSaveKCD4M(){
- var selectedIndx = model.getValue("/root/hidden/condition/indxflag");
- if(selectedIndx == "" || selectedIndx == null){
- var rtn = messageBox("색인 코드를 ", "C002");
- return;
- }
- var rowcnt = model.getValue("/root/hidden/condition/rowcnt");
- if(model.getValue("/root/hidden/condition/status") == "MN"){
- model.removeNodeset("/root/send");
- model.removeNodeset("/root/main/diagcdinfo");
- model.makeValue("/root/send/morphlgccd", model.getValue("/root/main/kcd4minfo/info/morphlgccd"));
- model.makeValue("/root/send/indxcd", model.getValue("/root/main/kcd4minfo/info/indxcd"));
- model.makeValue("/root/send/kcd4mengnm", model.getValue("/root/main/kcd4minfo/info/kcd4mengnm"));
- model.makeValue("/root/send/kcd4mhngnm", model.getValue("/root/main/kcd4minfo/info/kcd4mhngnm"));
- model.makeValue("/root/send/kcd4mseqno", model.getValue("/root/main/kcd4minfo/info/kcd4mseqno"));
- model.makeValue("/root/send/snmdcnptid", model.getValue("/root/main/kcd4minfo/info/snmdcnptid"));
- model.makeValue("/root/send/kcd4mfromdd", model.getValue("/root/main/kcd4minfo/info/kcd4mfromdd"));
- model.makeValue("/root/send/kcd4mtodd", model.getValue("/root/main/kcd4minfo/info/kcd4mtodd"));
- model.makeValue("/root/send/oldkcd4mfromdd", model.getValue("/root/main/kcd4minfo/info/oldkcd4mfromdd"));
- model.makeValue("/root/send/snmdcnptid", model.getValue("/root/main/kcd4minfo/info/snmdcnptid"));
- model.makeValue("/root/send/version", model.getValue("/root/main/kcd4minfo/info/version"));
- model.makeValue("/root/send/status", model.getValue("/root/hidden/condition/status"));
- if(submit("TXMRT00202")){
- model.resetInstanceNode("/root/main/kcd4minfo/info");
- fCntlReset("kcd4m");
- grd_kcd4minfo.rebuild();
- }
- return;
- }
- if(model.getValue("/root/main/kcd4minfo/info/morphlgccd") == model.getValue("/root/main/diagcdinfo/kcd4m[" + rowcnt + "]/morphlgccd") &&
- model.getValue("/root/main/kcd4minfo/info/kcd4mengnm") == model.getValue("/root/main/diagcdinfo/kcd4m[" + rowcnt + "]/kcd4mengnm") &&
- model.getValue("/root/main/kcd4minfo/info/kcd4mhngnm") == model.getValue("/root/main/diagcdinfo/kcd4m[" + rowcnt + "]/kcd4mhngnm") &&
- model.getValue("/root/main/kcd4minfo/info/snmdcnptid") == model.getValue("/root/main/diagcdinfo/kcd4m[" + rowcnt + "]/snmdcnptid") &&
- model.getValue("/root/main/kcd4minfo/info/indxcd") == model.getValue("/root/main/diagcdinfo/kcd4m[" + rowcnt + "]/indxcd") &&
- model.getValue("/root/main/kcd4minfo/info/version") == model.getValue("/root/main/diagcdinfo/kcd4m[" + rowcnt + "]/version")){
- var rtn = messageBox("수정되지 ", "E007");
- return;
- } else{
- model.removeNodeset("/root/send");
- model.removeNodeset("/root/main/diagcdinfo");
- model.makeValue("/root/send/morphlgccd", model.getValue("/root/main/kcd4minfo/info/morphlgccd"));
- model.makeValue("/root/send/indxcd", model.getValue("/root/main/kcd4minfo/info/indxcd"));
- model.makeValue("/root/send/kcd4mengnm", model.getValue("/root/main/kcd4minfo/info/kcd4mengnm"));
- model.makeValue("/root/send/kcd4mhngnm", model.getValue("/root/main/kcd4minfo/info/kcd4mhngnm"));
- model.makeValue("/root/send/kcd4mseqno", model.getValue("/root/main/kcd4minfo/info/kcd4mseqno"));
- model.makeValue("/root/send/snmdcnptid", model.getValue("/root/main/kcd4minfo/info/snmdcnptid"));
-
- //model.setValue("/root/main/kcd4minfo/info/kcd4mfromdate", model.getValue("/root/init/today"));
- //model.setValue("/root/main/kcd4minfo/info/kcd4mfromtime", model.getValue("/root/init/curruntTime"));
- //model.setValue("/root/main/kcd4minfo/info/kcd4mtodate", "99991231");
- //model.setValue("/root/main/kcd4minfo/info/kcd4mtotime", "2359");
- //model.setValue("/root/main/kcd4minfo/info/fstrgstdt", "");
- model.makeValue("/root/send/kcd4mfromdd", model.getValue("/root/main/kcd4minfo/info/kcd4mfromdd"));
- model.makeValue("/root/send/kcd4mtodd", model.getValue("/root/main/kcd4minfo/info/kcd4mtodd"));
- model.makeValue("/root/send/oldkcd4mfromdd", model.getValue("/root/main/kcd4minfo/info/oldkcd4mfromdd"));
- model.makeValue("/root/send/version", model.getValue("/root/main/kcd4minfo/info/version"));
- model.makeValue("/root/send/status", model.getValue("/root/hidden/condition/status"));
- if(submit("TXMRT00202")){
- model.resetInstanceNode("/root/main/kcd4minfo/info");
- fCntlReset("kcd4m");
- grd_kcd4minfo.rebuild();
- }
- }
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : KCD4M 용어 수정
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- function fSetKCD4MUpdt(){
- var fromdd = ((getCurrentDate()).toDate()).getAddDate(1);
- iRow = grd_kcd4minfo.row - grd_kcd4minfo.fixedRows + 1;
- model.setValue("/root/hidden/condition/status", "MM");
- fCtrlSet("M");
- model.setValue("/root/main/kcd4minfo/info/indxcd", model.getValue("/root/main/diagcdinfo/kcd4m[" + iRow + "]/indxcd"));
- model.setValue("/root/main/kcd4minfo/info/kcd4mfromdate", fromdd.getDateFormat());
- model.setValue("/root/main/kcd4minfo/info/kcd4mfromtime", model.getValue("/root/init/curruntTime"));
- model.setValue("/root/main/kcd4minfo/info/kcd4mtodate", "99991231");
- model.setValue("/root/main/kcd4minfo/info/kcd4mtotime", "2359");
- model.setValue("/root/main/kcd4minfo/info/kcd4mfromdd", model.getValue("/root/main/kcd4minfo/info/kcd4mfromdate"));
- model.setValue("/root/main/kcd4minfo/info/kcd4mtodd", model.getValue("/root/main/kcd4minfo/info/kcd4mtodate"));
- model.setValue("/root/main/kcd4minfo/info/fstrgstdt", model.getValue("/root/main/kcd4minfo/info/kcd4mfromdate")+model.getValue("/root/main/kcd4minfo/info/kcd4mfromtime")+"00");
- model.setValue("/root/main/kcd4minfo/info/fstrgstrid", getUserName());
- model.refresh();
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : KCD4M 용어 신규 등록
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- function fSetNewKCD4M(){
- var sIndx = model.getValue("/root/hidden/condition/selectedIndx");
- var fromdd = ((getCurrentDate()).toDate()).getAddDate(1);
- if(trv_dgindx.focusIndex < 0){
- var rtn = messageBox("색인을 ", "C002");
- return;
- }
- model.setValue("/root/hidden/condition/status", "MN");
- fCntlReset("kcd4m");
- fCtrlSet("N");
- model.setValue("/root/main/kcd4minfo/info/indxcd", model.getValue("/root/hidden/condition/selectedIndx"));
- model.setValue("/root/main/peprterminfo/info/fstrgstdate", model.getValue("/root/init/today"));
- model.setValue("/root/main/peprterminfo/info/fstrgsttime", model.getValue("/root/init/curruntTime"));
- model.setValue("/root/main/kcd4minfo/info/kcd4mfromdate", fromdd.getDateFormat());
- model.setValue("/root/main/kcd4minfo/info/kcd4mfromtime", model.getValue("/root/init/curruntTime"));
- model.setValue("/root/main/kcd4minfo/info/kcd4mtodate", "99991231");
- model.setValue("/root/main/kcd4minfo/info/kcd4mtotime", "2359");
- model.setValue("/root/main/kcd4minfo/info/kcd4mfromdd", model.getValue("/root/main/kcd4minfo/info/kcd4mfromdate"));
- model.setValue("/root/main/kcd4minfo/info/kcd4mtodd", model.getValue("/root/main/kcd4minfo/info/kcd4mtodate"));
- model.setValue("/root/main/kcd4minfo/info/fstrgstdate", model.getValue("/root/main/kcd4minfo/info/kcd4mfromdate"));
- model.setValue("/root/main/kcd4minfo/info/fstrgsttime", model.getValue("/root/main/kcd4minfo/info/kcd4mfromtime"));
- model.setValue("/root/main/kcd4minfo/info/fstrgstdt", model.getValue("/root/main/kcd4minfo/info/kcd4mfromdate")+model.getValue("/root/main/kcd4minfo/info/kcd4mfromtime")+"00");
- model.setValue("/root/main/kcd4minfo/info/fstrgstrid", getUserId());
- model.refresh();
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : KCD4M 용어 이력 선택
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- function fGetKCD4MHistList(){
- var iRow = grd_kcd4mhist.row;
- model.setValue("/root/hidden/condition/rowcnt", iRow);
- var kcd4mfromdd = model.getValue("/root/main/kcd4mhist/list[" + iRow + "]/kcd4mfromdd");
- var kcd4mtodd = model.getValue("/root/main/kcd4mhist/list[" + iRow + "]/kcd4mtodd");
- var lastupdtdt = model.getValue("/root/main/kcd4mhist/list[" + iRow + "]/lastupdtdt");
- fCtrlSet();
- model.setValue("/root/main/kcd4minfo/info/morphlgccd", model.getValue("/root/main/kcd4mhist/list[" + iRow + "]/morphlgccd")); // 스노메드-dscrpt
- model.setValue("/root/main/kcd4minfo/info/kcd4mengnm", model.getValue("/root/main/kcd4mhist/list[" + iRow + "]/kcd4mengnm")); // 스노메드-cncpt
- model.setValue("/root/main/kcd4minfo/info/kcd4mhngnm", model.getValue("/root/main/kcd4mhist/list[" + iRow + "]/kcd4mhngnm")); // 영문
- model.setValue("/root/main/kcd4minfo/info/indxcd", model.getValue("/root/main/kcd4mhist/list[" + iRow + "]/indxcd")); // 한글
-
- model.setValue("/root/main/kcd4minfo/info/kcd4mfromdd", kcd4mfromdd);
- model.setValue("/root/main/kcd4minfo/info/kcd4mfromdate", kcd4mfromdd.substr(0,8));
- model.setValue("/root/main/kcd4minfo/info/kcd4mfromtime", kcd4mfromdd.substr(8,4));
- model.setValue("/root/main/kcd4minfo/info/kcd4mtodd", kcd4mtodd);
- model.setValue("/root/main/kcd4minfo/info/kcd4mtodate", kcd4mtodd.substr(0,8));
- model.setValue("/root/main/kcd4minfo/info/kcd4mtotime", kcd4mtodd.substr(8,4));
- model.setValue("/root/main/kcd4minfo/info/fstrgstdate", lastupdtdt.substr(0,8));
- model.setValue("/root/main/kcd4minfo/info/fstrgsttime", lastupdtdt.substr(8,4));
- model.setValue("/root/main/kcd4minfo/info/fstrgstrid", model.getValue("/root/main/kcd4mhist/list["+iRow+"]/lastupdtrnm"));
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : Tree 선택
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fSelTreeIndx(){
- var sSelectedMode = model.getValue("/root/hidden/condition/selctedmode");
- var iIndx = trv_dgindx.focusIndex + 1;
- var selIndxCd = model.getValue("/root/main/indxlist/item[" + iIndx + "]/indxcd");
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/indxcd", selIndxCd);
- model.makeValue("/root/send/indxuseflag", model.getValue("/root/hidden/condition/indxuseflag"));
- model.makeValue("/root/send/indxflag", model.getValue("/root/hidden/condition/indxflag"));
- model.makeValue("/root/send/maininstyn", model.getValue("/root/hidden/condition/maininstyn"));
- model.makeValue("/root/send/selInstcd", model.getValue("/root/hidden/condition/selInstcd"));
- switch(sSelectedMode){
- case 'P' : // 과진단 코드
- model.makeValue("/root/send/deptcd", model.getValue("/root/hidden/condition/deptset/selecteddeptcd"));
- model.makeValue("/root/send/pagesize",pagesize);
- model.makeValue("/root/send/offset", "0");
- model.removenodeset("/root/main/deptdiagcdlist/deptdiagcdinfo");
- pinfo = 1;
- submit("TRMRT00212");
- break;
- default :
- model.setValue("/root/hidden/condition/selectedIndx", model.getValue("/root/main/indxlist/item[" + iIndx + "]/indxcd"));
- model.setValue("/root/hidden/condition/selectedIndxDepth", model.getValue("/root/main/indxlist/item[" + iIndx + "]/depth"));
- model.setValue("/root/hidden/condition/selectedIndxPath", model.getValue("/root/main/indxlist/item[" + iIndx + "]/pathcd")); //경로
- submit("TRMRT00202"); //인덱스 트리를 가지고 온다
- grd_icd10.rebuild();
- grd_diagcd.rebuild();
- grd_kcd4minfo.rebuild();
- if(sSelectedMode == "K"){
- fCtrlSet();
- } else if(sSelectedMode == "D"){
- fDisabled("AS");
- }
- }
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 색인추가
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- function fAddIndx(){
- var selectedmode = model.getValue("/root/hidden/condition/selctedmode");
- if(selectedmode != "P"){
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/paramindx","");
- model.setValue("/root/send/paramindx", model.getValue("/root/hidden/condition/indxflag"));
- modal("SMMRT00100", 1,10, 10, "SMMRT00100", "/root/send", "/root/hidden/condition/getdata");
- var child = "SPMRT01200";
- if(child != null){
- var getVal = getParameter("setVal");
- // 색인추가후 재조회가 안됨... Edited by 나종천 20080928
- //if(getVal == "I" || getVal == "U" || getVal == "D") {
- if(getVal == "0" || getVal == "4") {
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/indxflag",model.getValue("/root/hidden/condition/indxflag"));
- model.makeValue("/root/send/mode",model.getValue("/root/hidden/condition/indxviewmode"));
- submit("TRMRT00201");
- trv_dgindx.rebuild();
- }
- }
- }else {
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/indxflag","0");
- model.makeValue("/root/send/deptcd", model.getValue("/root/hidden/condition/deptset/selecteddeptcd"));
- model.makeValue("/root/send/deptnm", model.getValue("/root/hidden/condition/deptset/selecteddeptnm"));
- modal("SMMRT01300",1,10,10,"SMMRT01300","/root/send","/root/hidden/condition/getdata");
- if(getParameter("saveyn") == "Y" && model.getValue("/root/hidden/condition/deptset/selecteddeptcd") != ""){
- model.removenode("/root/send");
- model.makeValue("/root/send/indxflag", model.getValue("/root/hidden/condition/indxflag"));
- model.makeValue("/root/send/deptcd", model.getValue("/root/hidden/condition/deptset/selecteddeptcd"));
- if(submit("TRMRT00210")){
- model.removenodeset("/root/main/deptdiagcdlist/deptdiagcdinfo");
- model.setValue("/root/hidden/condition/selectedIndx","");
- grd_deptdiag.rebuild();
- trv_dgindx.rebuild();
- }
- }
- }
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 색인 언어 변경
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- function fChngLangIndx(){
- var selectedmode = model.getValue("/root/hidden/condition/selctedmode");
- if(selectedmode != "P"){
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/indxflag",model.getValue("/root/hidden/condition/indxflag"));
- model.makeValue("/root/send/mode",model.getValue("/root/hidden/condition/indxviewmode"));
- model.makeValue("/root/send/indxuseflag",model.getValue("/root/hidden/condition/indxuseflag"));
- submit("TRMRT00201");
- }
- trv_dgindx.rebuild();
- model.refresh();
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 색인 코드 조회
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- function fSrchIndxCd(){
- if(model.getValue("/root/hidden/condition/srchindxcd") == "" || model.getValue("/root/hidden/condition/srchindxcd") == null){
- var rtn = messageBox("검색할 색인코드를 ", "C001");
- return;
- } else {
- model.setValue("/root/hidden/condition/selectedIndx", model.getValue("/root/hidden/condition/srchindxcd"));
- trv_dgindx.expandDepth = "3";
- model.refresh();
- }
- trv_dgindx.vscroll.attribute("pos") = ( parseInt(trv_dgindx.attribute("itemheight")) + 1 ) * trv_dgindx.selectedIndex;
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 과진단 선택
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- function fSelDeptDiag(){
- btn_addrow.attribute("visibility") = "hidden";
- btn_delrow.attribute("visibility") = "hidden";
- btn_saverow.attribute("visibility") = "hidden";
- btn_modify.attribute("visibility") = "hidden";
- cap_selInst.visible = false;
- cmb_selInst.visible = false;
- cap_allinsthist.visible = false;
- cmb_allinsthist.visible = false;
-
- pinfo = 1;
-
- model.setValue("/root/hidden/condition/deptset/srchflag","H");
- model.setValue("/root/hidden/condition/deptset/srchnm","");
- model.setValue("/root/hidden/condition/deptset/selecteddeptcd","");
- model.setValue("/root/hidden/condition/deptset/selecteddeptnm","");
- model.setValue("/root/hidden/condition/selctedmode", "P");
- model.setValue("/root/hidden/condition/indxflag", "0"); // 진단 : 0, 수술 : 9
- model.removenodeset("/root/main/indxlist/item");
- model.removenodeset("/root/main/srcheddiagcdlist/srcheddiagcdinfo");
- model.removenodeset("/root/main/deptdiagcdlist/deptdiagcdinfo");
- model.refresh();
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 진단 용어 선택
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- function fSelDiagTerm(){
- var iRow = grd_diagcd.row;
- if(grd_diagcd.isCell(event.target) && grd_diagcd.mouserow >= grd_diagcd.fixedrows) {
- opt_Hdicd10cd.visible = "true";
- cmb_icd10cd.visible = "false";
- var sameTermMode = model.getValue("/root/hidden/condition/sametermmode");
-
- //2009-03-20 오전 9:12:31 강지훈 수정 : 기관별 사용 이력조회에서는 신규입력외의 Operation 금지
- if(sameTermMode != "H"){
- btn_delete2.disabled = "false";
- }
- fDisabled("AS");
- if( !isNull(iRow) ) {
- model.setValue("/root/hidden/condition/status", "");
- var diagAttr = model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/diagattrcd");
- var term = model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/termcd");
- var icd10cd = term.split(".")[0];
- var diagattrcd = term.split(".")[1];
- var termcd = term.split(".")[2];
-
-
- model.setValue("/root/hidden/condition/selectedtermcd" , term);
- model.setValue("/root/main/peprterminfo/info/icd10cd" , icd10cd); //ICD10
- model.setValue("/root/main/peprterminfo/info/diagattrcd" , diagattrcd); // 확장코드
- model.setValue("/root/main/peprterminfo/info/termcd" , termcd); // 대표어(동의어)코드
- model.setValue("/root/main/peprterminfo/info/snmdcnptid", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/snmdcnptid")); // 스노메드-cnpt id
- model.setValue("/root/main/peprterminfo/info/snmdcnptnm", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/snmdcnptnm")); // 스노메드-cncpt 명
- model.setValue("/root/main/peprterminfo/info/snmddescid", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/snmddescid")); // 스노메드-dscrpt
- model.setValue("/root/main/peprterminfo/info/umlscd", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/umlscd")); // UMLS코드
- model.setValue("/root/main/peprterminfo/info/termengnm", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/termengnm")); // 영문
- model.setValue("/root/main/peprterminfo/info/termhngnm", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/termhngnm")); // 한글
- model.setValue("/root/main/peprterminfo/info/reprflag", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/reprflag")); // 대표어구분
- model.setValue("/root/main/peprterminfo/info/termflag", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/termflag")); // 용어구분
- model.setValue("/root/main/peprterminfo/info/lglydisflag", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/lglydisflag")); // 법정전염병
- model.setValue("/root/main/peprterminfo/info/chrncsickyn", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/chrncsickyn")); // 만성질환
- model.setValue("/root/main/peprterminfo/info/estmexptyn", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/estmexptyn")); // 산정특례
- model.setValue("/root/main/peprterminfo/info/serdiagclsyn", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/serdiagclsyn")); // 중증도분류
- model.setValue("/root/main/peprterminfo/info/ageflag", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/ageflag")); // 연령별 구분
- model.setValue("/root/main/peprterminfo/info/manwomflag", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/manwomflag")); // 남여구분
- model.setValue("/root/main/peprterminfo/info/cncryn", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/cncryn")); // 남여구분
- model.setValue("/root/main/peprterminfo/info/diagattrdrindxcd", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/diagattrdrindxcd")); // 의사색인
- model.setValue("/root/main/peprterminfo/info/diagattrmedireccd", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/diagattrmedireccd")); // 의무기록색인
- model.setValue("/root/main/peprterminfo/info/diagattrverflag", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/diagattrverflag")); // 버전
- model.setValue("/root/main/peprterminfo/info/fstrgstrid", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/lastupdtrnm")); // 최종등록자
- model.setValue("/root/main/peprterminfo/info/attrfromdd", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/attrfromdd"));
- model.setValue("/root/main/peprterminfo/info/attrtodd", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/attrtodd"));
- model.setValue("/root/main/peprterminfo/info/icdfromdd", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/icdfromdd"));
- model.setValue("/root/main/peprterminfo/info/alttermcd", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/alttermcd"));
- model.setValue("/root/main/peprterminfo/info/essntermflag", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/essntermflag"));
- var fstrgstdt = model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/fstrgstdt");
- var termfromdd = model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/termfromdd");
- var termtodd = model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/termtodd");
-
- model.setValue("/root/main/peprterminfo/info/fstrgstdt", fstrgstdt); // 등록일
- model.setValue("/root/main/peprterminfo/info/fstrgstdate", fstrgstdt.substr(0,8));
- model.setValue("/root/main/peprterminfo/info/fstrgsttime", fstrgstdt.substr(8,4));
- model.setValue("/root/main/peprterminfo/info/termfromdd",termfromdd);
- model.setValue("/root/main/peprterminfo/info/termtodd", termtodd);
-
- //2009-04-28 오후 3:21:38 강지훈 수정 : 중앙이 아닌 기관일경우 확장,용어코드가 000.00인것은 수정불가처리, 기관별사용이력조회일때도 불가
- var maininstyn = model.getValue("/root/hidden/condition/maininstyn");
- if(sameTermMode != "H"){
- if(maininstyn == "N" && diagattrcd == "000" && termcd == "00"){
- btn_modify1.disabled = true;
- }
- else{
- btn_modify1.disabled = false;
- }
- }
- else{
- btn_modify1.disabled = true;
- }
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/diagattrcd", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/diagattrcd"));
- model.makeValue("/root/send/sametermmode", model.getValue("/root/hidden/condition/sametermmode"));
- model.makeValue("/root/send/allinsthist", model.getValue("/root/hidden/condition/allinsthist"));
- model.makeValue("/root/send/termcd", term);
- model.makeValue("/root/send/termflag", model.getValue("/root/main/diagcdinfo/diagcd[" + iRow + "]/termflag"));
- model.makeValue("/root/send/maininstyn", model.getValue("/root/hidden/condition/maininstyn"));
- model.makeValue("/root/send/selInstcd", model.getValue("/root/hidden/condition/selInstcd"));
-
- submit("TRMRT00205");
- model.setValue("/root/main/peprterminfo/info/appinstcd", model.getValue("/root/main/sametermlist/appinstcd/appinstcd"));
-
- model.refresh();
- }
- }
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : KCD4M 용어 선택
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- function fSelKCD4M(){
- var iRow = grd_kcd4minfo.row;
- model.setValue("/root/hidden/condition/rowcnt", iRow);
- var kcd4mfromdd = model.getValue("/root/main/diagcdinfo/kcd4m[" + iRow + "]/kcd4mfromdd");
- var kcd4mtodd = model.getValue("/root/main/diagcdinfo/kcd4m[" + iRow + "]/kcd4mtodd");
- var lastupdtdt = model.getValue("/root/main/diagcdinfo/kcd4m[" + iRow + "]/lastupdtdt");
- fCtrlSet();
- model.setValue("/root/main/kcd4minfo/info/morphlgccd", model.getValue("/root/main/diagcdinfo/kcd4m[" + iRow + "]/morphlgccd"));
- model.setValue("/root/main/kcd4minfo/info/kcd4mengnm", model.getValue("/root/main/diagcdinfo/kcd4m[" + iRow + "]/kcd4mengnm"));
- model.setValue("/root/main/kcd4minfo/info/kcd4mhngnm", model.getValue("/root/main/diagcdinfo/kcd4m[" + iRow + "]/kcd4mhngnm"));
- model.setValue("/root/main/kcd4minfo/info/indxcd", model.getValue("/root/main/diagcdinfo/kcd4m[" + iRow + "]/indxcd"));
- model.setValue("/root/main/kcd4minfo/info/kcd4mseqno", model.getValue("/root/main/diagcdinfo/kcd4m[" + iRow + "]/kcd4mseqno"));
- model.setValue("/root/main/kcd4minfo/info/snmdcnptid", model.getValue("/root/main/diagcdinfo/kcd4m[" + iRow + "]/snmdcnptid"));
- model.setValue("/root/main/kcd4minfo/info/snmdcnptnm", model.getValue("/root/main/diagcdinfo/kcd4m[" + iRow + "]/snmdcnptnm"));
- model.setValue("/root/main/kcd4minfo/info/version", model.getValue("/root/main/diagcdinfo/kcd4m[" + iRow + "]/version"));
- model.setValue("/root/main/kcd4minfo/info/kcd4mfromdd", kcd4mfromdd);
- model.setValue("/root/main/kcd4minfo/info/oldkcd4mfromdd", kcd4mfromdd);
- model.setValue("/root/main/kcd4minfo/info/kcd4mfromdate", kcd4mfromdd.substr(0,8));
- model.setValue("/root/main/kcd4minfo/info/kcd4mfromtime", kcd4mfromdd.substr(8,4));
- model.setValue("/root/main/kcd4minfo/info/kcd4mtodd", kcd4mtodd);
- model.setValue("/root/main/kcd4minfo/info/kcd4mtodate", kcd4mtodd.substr(0,8));
- model.setValue("/root/main/kcd4minfo/info/kcd4mtotime", kcd4mtodd.substr(8,4));
- model.setValue("/root/main/kcd4minfo/info/fstrgstdate", lastupdtdt.substr(0,8));
- model.setValue("/root/main/kcd4minfo/info/fstrgsttime", lastupdtdt.substr(8,4));
- model.setValue("/root/main/kcd4minfo/info/fstrgstrid", model.getValue("/root/main/diagcdinfo/kcd4m["+iRow+"]/lastupdtrnm"));
- model.setValue("/root/hidden/condition/sametermmode", "N");
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/morphlgccd", model.getValue("/root/main/diagcdinfo/kcd4m[" + iRow + "]/morphlgccd"));
- model.makeValue("/root/send/sametermmode", model.getValue("/root/hidden/condition/sametermmode"));
- submit("TRMRT00213");
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 과진단추가 리스트 선택
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- function fSelAddDiagList(){
- if(grd_srcheddiaginfo.row == 0){
- var sRowCnt = grd_srcheddiaginfo.rows- grd_srcheddiaginfo.fixedRows;
- var sCheck = model.getValue("/root/main/srcheddiagcdlist/srcheddiagcdinfo[1]/check");
- if(sCheck == "true"){
- for(var iRow=1; iRow <= sRowCnt; iRow++){
- model.setValue("/root/main/srcheddiagcdlist/srcheddiagcdinfo["+iRow+"]/check","false");
- }
- }else{
- for(var iRow=1; iRow <= sRowCnt; iRow++){
- model.setValue("/root/main/srcheddiagcdlist/srcheddiagcdinfo["+iRow+"]/check","true");
- }
- }
- grd_srcheddiaginfo.rebuild();
- }
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 과진단 용어 삭제
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- function fDelDeptDiagTerm(){
- var iRow = grd_deptdiag.row;
- if(iRow < 1){
- return;
- }
- if(model.getValue("/root/main/deptdiagcdlist/deptdiagcdinfo["+iRow+"]/status") == "I"){
- grd_deptdiag.deleteItem(iRow);
- }else{
- model.setValue("/root/main/deptdiagcdlist/deptdiagcdinfo["+iRow+"]/status","D");
- }
- grd_deptdiag.rebuild();
- }
- /**
- * @group :
- * @ver : 2008.03.19
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 진단 용어 신규 등록시 확장코드 생성
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fGetNewExtCd(){
- //ICD10코드 선택 시, 새로운 확장, 용어코드 및 ICD시작일자 함께 조회
- var iCd = cmb_icd10cd.focusIndex + 1;
- var selCd = model.getValue("/root/main/icd10cdlist/info[" + iCd + "]/icd10cd");
- var path = model.getValue("/root/hidden/condition/selectedIndxPath");
- model.setValue("/root/hidden/condition/selectedicd10", selCd);
- model.setValue("/root/main/peprterminfo/info/icd10cd", selCd);
-
- model.removeNodeset("/root/send");
- model.removeNodeset("/root/main/temp");
- model.makeValue("/root/send/icd10cd", selCd);
- model.makeNode("/root/main/temp/icd10info");
- submit("TRMRT00207");
-
- model.setValue("/root/main/peprterminfo/info/icd10cd", model.getValue("/root/main/temp/icd10info/icd10cd"));
- model.setValue("/root/main/peprterminfo/info/diagattrcd", model.getValue("/root/main/temp/icd10info/diagattrcd"));
- model.setValue("/root/main/peprterminfo/info/termcd", model.getValue("/root/main/temp/icd10info/termcd"));
- if(model.getValue("/root/main/temp/icd10info/diagattrmedireccd") == ""){
- model.setValue("/root/main/peprterminfo/info/diagattrmedireccd", model.getValue("/root/hidden/condition/selectedIndx"));
- } else {
- model.setValue("/root/main/peprterminfo/info/diagattrmedireccd", model.getValue("/root/main/temp/icd10info/diagattrmedireccd"));
- }
- model.setValue("/root/main/peprterminfo/info/diagattrmedireccd", model.getValue("/root/main/temp/icd10info/diagattrmedireccd"));
- var path = model.getValue("/root/hidden/condition/selectedIndxPath").split(".");
- model.setValue("/root/main/peprterminfo/info/diagattrdrindxcd", path[path.length-2]);
- model.setValue("/root/main/peprterminfo/info/icdfromdd", model.getValue("/root/main/temp/icd10info/icdfromdd"));
- model.setValue("/root/main/peprterminfo/info/reprflag", "R"); //신규모드일때에는 디폴트 R
- // Edited by NJ 2007-07-21 getDate() -> getCurrentDate()
- //model.setValue("/root/main/peprterminfo/info/attrfromdd", getDate());
- /* model.setValue("/root/main/peprterminfo/info/attrfromdd", getCurrentDate());
- model.setValue("/root/main/peprterminfo/info/attrtodd", "99991231");
-
- model.setValue("/root/main/peprterminfo/info/fstrgstdate", model.getValue("/root/init/today"));
- model.setValue("/root/main/peprterminfo/info/fstrgsttime", model.getValue("/root/init/curruntTime"));
- model.setValue("/root/main/peprterminfo/info/fstrgstdt", model.getValue("/root/main/peprterminfo/info/fstrgstdate") + model.getValue("/root/main/peprterminfo/info/fstrgsttime") + "00");
- model.setValue("/root/main/peprterminfo/info/termfromdd", model.getValue("/root/init/today"));
- model.setValue("/root/main/peprterminfo/info/termtodd", "99991231");
- model.setValue("/root/main/peprterminfo/info/fstrgstrid", model.getValue("/root/init/userinfo/usernm"));
- */
- model.refresh();
- }
- /**
- * @group :
- * @ver : 2008.06.18
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : ICD10코드 저장 후 ICD10 재조회
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fICD10Save(){
- model.removeNodeset("/root/send");
-
-
- var RowCnt = grd_icd10.rows;
- model.makeValue("/root/send/reqdata","");
- var cnt = 1;
- for ( i=1; i<=RowCnt; i++) {
- if(model.getValue("/root/main/diagcdinfo/icd10cd[" + i + "]/state") == "I" || model.getValue("/root/main/diagcdinfo/icd10cd[" + i + "]/state") == "U" || model.getValue("/root/main/diagcdinfo/icd10cd[" + i + "]/state") == "D") {
- /* model.makeValue("/root/send/reqdata[" + cnt + "]/state","");
- model.makeValue("/root/send/reqdata[" + cnt + "]/icd10cd","");
- model.makeValue("/root/send/reqdata[" + cnt + "]/icd10drindxcd","");
- model.makeValue("/root/send/reqdata[" + cnt + "]/icd10medireccd","");
- model.makeValue("/root/send/reqdata[" + cnt + "]/icd10engnm","");
- model.makeValue("/root/send/reqdata[" + cnt + "]/icd10hngnm","");
- model.makeValue("/root/send/reqdata[" + cnt + "]/icd10seqno","");
- model.makeValue("/root/send/reqdata[" + cnt + "]/icd10fromdd", "");
- model.makeValue("/root/send/reqdata[" + cnt + "]/icd10todd",""); */
- model.makeValue("/root/send/reqdata[" + cnt + "]/state", model.getValue("/root/main/diagcdinfo/icd10cd[" + i + "]/state"));
- model.makeValue("/root/send/reqdata[" + cnt + "]/icd10cd", model.getValue("/root/main/diagcdinfo/icd10cd[" + i + "]/icd10cd"));
- model.makeValue("/root/send/reqdata[" + cnt + "]/icd10drindxcd", model.getValue("/root/main/diagcdinfo/icd10cd[" + i + "]/icd10drindxcd"));
- model.makeValue("/root/send/reqdata[" + cnt + "]/icd10medireccd", model.getValue("/root/main/diagcdinfo/icd10cd[" + i + "]/icd10medireccd"));
- model.makeValue("/root/send/reqdata[" + cnt + "]/icd10engnm", model.getValue("/root/main/diagcdinfo/icd10cd[" + i + "]/icd10engnm"));
- model.makeValue("/root/send/reqdata[" + cnt + "]/icd10hngnm", model.getValue("/root/main/diagcdinfo/icd10cd[" + i + "]/icd10hngnm"));
- model.makeValue("/root/send/reqdata[" + cnt + "]/icd10seqno", model.getValue("/root/main/diagcdinfo/icd10cd[" + i + "]/icd10seqno"));
- model.makeValue("/root/send/reqdata[" + cnt + "]/icd10fromdd", model.getValue("/root/main/diagcdinfo/icd10cd[" + i + "]/icd10fromdd"));
- model.makeValue("/root/send/reqdata[" + cnt + "]/icd10todd", model.getValue("/root/main/diagcdinfo/icd10cd[" + i + "]/icd10todd"));
- model.makeValue("/root/send/reqdata[" + cnt + "]/fstrgstrid", model.getValue("/root/main/diagcdinfo/icd10cd[" + i + "]/fstrgstrid"));
- model.makeValue("/root/send/reqdata[" + cnt + "]/lastupdtrid", model.getValue("/root/main/diagcdinfo/icd10cd[" + i + "]/lastupdtrid"));
- model.makeValue("/root/send/reqdata[" + cnt + "]/oldfromdd", model.getValue("/root/main/diagcdinfo/icd10cd[" + i + "]/oldfromdd"));
- model.makeValue("/root/send/reqdata[" + cnt + "]/oldtodd", model.getValue("/root/main/diagcdinfo/icd10cd[" + i + "]/oldtodd"));
- cnt++;
- }
- }
- model.makeValue("/root/send/reqdata/indxcd", model.getValue("/root/hidden/condition/selectedIndx"));
- model.makeValue("/root/send/reqdata/indxflag", model.getValue("/root/hidden/condition/indxflag"));
- submit("TXMRT00204");
- grd_icd10.rebuild();
- model.refresh();
- }
- /**
- * @group :
- * @ver : 2008.06.18
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : ICD10코드 삭제
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fDelRow(flag) {
- var iRow = grd_icd10.row - grd_icd10.fixedRows + 1;
- var currentTime = getCurrentTime();
- if(model.getValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/icd10cd") == ""){
- return;
- }
- if(flag == "I") {
- iRow = grd_icd10.row - grd_icd10.fixedRows + 1;
- model.setValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/state", "D");
- model.setValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/icd10todd", model.getValue("/root/init/today"));
- model.setValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/lastupdtdt", model.getValue("/root/init/today") + currentTime.substr(0,6));
- model.setValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/lastupdtrid", model.getValue("/root/init/userinfo/userid"));
- }
- model.refresh();
- }
- /**
- * @group :
- * @ver : 2008.11.24
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : ICD10코드 수정
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fEditRow(flag){
- var iRow = grd_icd10.row - grd_icd10.fixedRows + 1;
- var currentTime = getCurrentTime();
- if(model.getValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/icd10cd") == ""){
- return;
- }
- if(flag == "I") {
- model.setValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/state", "U");
-
- model.makeValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/oldfromdd", model.getValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/icd10fromdd"));
- model.makeValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/oldtodd", model.getValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/icd10todd"));
- model.setValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/icd10fromdd", model.getValue("/root/init/today"));
- model.setValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/icd10todd", "99991231");
- model.setValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/fstrgstdt", model.getValue("/root/init/today") + currentTime.substr(0,6));
- model.setValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/fstrgstrid", model.getValue("/root/init/userinfo/userid"));
- model.setValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/lastupdtdt", model.getValue("/root/init/today") + currentTime.substr(0,6));
- model.setValue("/root/main/diagcdinfo/icd10cd[" + iRow + "]/lastupdtrid", model.getValue("/root/init/userinfo/userid"));
- }
- model.refresh();
- }
- /**
- * @group :
- * @ver : 2008.11.29
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 사용종료 용어 되살리기
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fRollbackTerm(){
- var icd10cd = model.getValue("/root/main/peprterminfo/info/icd10cd");
- var attrcd = model.getValue("/root/main/peprterminfo/info/diagattrcd");
- var termcd = model.getValue("/root/main/peprterminfo/info/termcd");
- var fullTermcd = icd10cd + "." + attrcd + "." + termcd;
- model.removeNodeset("/root/send");
- model.makeNode("/root/send/reqdata");
- model.copyNode("/root/send/reqdata", "/root/main/peprterminfo/info");
- model.setValue("/root/send/reqdata/icd10cd", icd10cd);
- model.setValue("/root/send/reqdata/diagattrcd", icd10cd + "." + attrcd);
- model.setValue("/root/send/reqdata/termcd", fullTermcd);
- model.setValue("/root/send/reqdata/termflag", "0");
- model.setValue("/root/send/reqdata/termfromdd", model.getValue("/root/init/today"));
- model.setValue("/root/send/reqdata/termtodd", "99991231");
- model.makeValue("/root/send/reqdata/indxcd", model.getValue("/root/hidden/condition/selectedIndx"));
- model.makeValue("/root/send/reqdata/maininstyn", model.getValue("/root/hidden/condition/maininstyn"));
- if(termcd == "00"){
- model.makeValue("/root/send/reqdata/status", "ETN");
- model.makeValue("/root/send/reqdata/attrfromdd", model.getValue("/root/init/today"));
- model.makeValue("/root/send/reqdata/attrtodd", "99991231");
- } else {
- model.makeValue("/root/send/reqdata/status", "TN");
- }
- submit("TXMRT00201");
- }
- /**
- * @group :
- * @ver : 2008.12.11
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 오른쪽 마우스 팝업 호출
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fCallPopup(flag){
- if(flag == "grd_diagcd"){
- if(isDataCell()){
- setPopupMenu(flag, false, "/root/init/func/mouserght", "label", "value");
- }
- } else if(flag == "trv_dgindx"){
- if(trv_dgindx.value == ""){
- return;
- }
- setPopupMenu(flag, false, "/root/init/func/trvmouserght", "label", "value");
- } else if(flag == "grd_kcd4minfo"){
- if(isDataCell()){
- setPopupMenu(flag, false, "/root/init/func/mouserght", "label", "value");
- }
- } else {
- initPopupMenu();
- }
- }
- /**
- * @group :
- * @ver : 2008.12.11
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 색인 변경 처리
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fModifyIndx(){
- var selTab = model.getValue("/root/hidden/condition/selctedmode");
- model.removenode("/root/hidden/reqdata");
- if(selTab == "D"){
- selectedRows = grd_diagcd.selectedRows;
- for(var cnt = 0; cnt <= selectedRows -1; cnt++){
- copyNodeset("/root/hidden/reqdata/diagindxlist", "/root/main/diagcdinfo/diagcd[" + grd_diagcd.selectedrow(cnt) + "]", "append");
- }
- } else if(selTab == "K"){
- selectedRows = grd_kcd4minfo.selectedRows;
- for(var cnt = 0; cnt <= selectedRows -1; cnt++){
- copyNodeset("/root/hidden/reqdata/kcd4mindxlist", "/root/main/diagcdinfo/kcd4m[" + grd_kcd4minfo.selectedrow(cnt) + "]", "append");
- }
- }
- }
- /**
- * @group :
- * @ver : 2008.12.11
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 색인 변경 처리
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fPasteIndx(){
- var selTab = model.getValue("/root/hidden/condition/selctedmode");
- var iIndx = trv_dgindx.focusIndex + 1;
- var selIndxCd = model.getValue("/root/main/indxlist/item[" + iIndx + "]/indxcd");
- var selIndxDrdiflag = model.getValue("/root/main/indxlist/item[" + iIndx + "]/indxdrdiflag");
- var msg = messageBox("색인을", "Q012");
- if(msg == "7"){
- return;
- }
- switch(selTab){
- case "D":
- copyNodeset("/root/send/reqdata/diagindxlist", "/root/hidden/reqdata/diagindxlist");
- model.makeValue("/root/send/reqdata/chnginfo/chngindxcd", selIndxCd);
- model.makeValue("/root/send/reqdata/chnginfo/indxdrdiflag", selIndxDrdiflag);
- model.makeValue("/root/send/reqdata/chnginfo/indxflag", selTab);
- if(msg == "6"){
- if(submit("TXMRT00205")){
- messageBox("색인 변경이","I001");
- grd_diagcd.refresh();
- } else {
- messageBox("색인 변경을","E009");
- }
- }
- model.removeNodeset("/root/send/reqdata");
- model.removeNodeset("/root/hidden/reqdata");
- break;
- case "K":
- copyNodeset("/root/send/reqdata/kcd4mindxlist", "/root/hidden/reqdata/kcd4mindxlist");
- model.makeValue("/root/send/reqdata/chnginfo/chngindxcd", selIndxCd);
- model.makeValue("/root/send/reqdata/chnginfo/indxdrdiflag", selIndxDrdiflag);
- model.makeValue("/root/send/reqdata/chnginfo/indxflag", selTab);
- if(msg == "6"){
- if(submit("TXMRT00205")){
- messageBox("색인 변경이","I001");
- grd_diagcd.refresh();
- } else {
- messageBox("색인 변경을","E009");
- }
- }
- model.removeNodeset("/root/send/reqdata");
- model.removeNodeset("/root/hidden/reqdata");
- break;
- }
- }
- /**
- * @group :
- * @ver : 2008.12.11
- * @by : 나종천
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 대체코드 검색
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fCallTermSrch(ref1){
- var alttermcd = model.getValue("/root/main/peprterminfo/info/alttermcd");
- var curr_date = model.getValue("/root/init/today");
- model.removeNodeset("/root/temp/terminfo/altterminfo");
- setParameter("SPMRT01500_param_nodepath", "/root/temp/terminfo/altterminfo");
- setParameter("SPMRT01500_SEARCHDATA", alttermcd);
- setParameter("SPMRT01500_FLAG", "1");
- setParameter("stndd", curr_date);
- // 2009-08-03 nj 추가
- setParameter("maininstyn", "Y");
- modal("SPMRT01500");
- if(getParameter("SPMRT01500_FLAG") == ""){
- return;
- }
- if(getNodesetCnt(model,"/root/temp/terminfo/altterminfo")>0){
- model.setValue(ref1, model.getValue("/root/temp/terminfo/altterminfo/selectdiaglist/diagcd"));
- ipt_alttermcd.refresh();
- return true;
- } else {
- return false;
- }
- }
- /**
- * @group :
- * @ver : 2009.02.09
- * @by : 강지훈
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 기관별 용어 사용여부 설정
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fTermUseSave(){
- model.removeNodeset("/root/send");
- var RowCnt = grd_icd10.rows;
- model.makeValue("/root/send/termuse",getGridUpdateData(grd_diagcd));
- submit("TXMRT00206");
-
- model.refresh();
- }
- /**
- * @group :
- * @ver : 2009.07.16
- * @by : 이은영
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 스크롤 페이지단위 조회
- * @param :
- * @return :
- * @---------------------------------------------------
- */
-
- var pinfo = 1;
- var pagesize = 10000;
- function fSubmitOnScroll() {
-
- if(grd_deptdiag.vscroll.attribute("max") == grd_deptdiag.vscroll.attribute("pos")) { // end of scroll
-
- if ( (grd_deptdiag.rows-grd_deptdiag.fixedRows) < eval(pinfo*pagesize))return;
- model.makeValue("/root/send/pagesize",pagesize);
- model.makeValue("/root/send/offset", grd_deptdiag.rows-grd_deptdiag.fixedRows); // grid의 header row는 제외
- submit("TRMRT00212");
- pinfo += 1;
-
- grd_deptdiag.dispatch("onmouseup"); // 스크롤바 처리를 위한 이벤트 발생
- }
- }
|