1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768 |
- <?xml version="1.0" encoding="EUC-KR"?>
- <?xml-stylesheet href="../../../com/commonweb/css/common.css" type="text/css" ?>
- <xhtml:html xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.w3.org/2002/01/xforms" xmlns:ev="http://www.w3.org/2001/xml-events">
- <xhtml:head>
- <xhtml:title>알코올센터 메인</xhtml:title>
- <model id="model1">
- <instance id="instance1">
- <root xmlns="">
- <main>
- <cond>
- <orddd/>
- <to_orddd/>
- <indschacptstat>1</indschacptstat>
- <mngtstat>1</mngtstat>
- <pid/>
- <patnm/>
- <sexage/>
- <orddeptnm/>
- <wardcd/>
- <prestimportid/>
- <userid/>
- <usernm/>
- <section/>
- </cond>
- <paminfo/>
- <patinfo>
- <patinfolist/>
- </patinfo>
- </main>
- <main_nm>
- <wardpatinfo>
- <wardpatlist>
- <spcffactyn/>
- <indschstat/>
- <pid/>
- <patnm/>
- <sexage/>
- <findd/>
- <hd/>
- <endschedd/>
- <dschdd/>
- <endflag/>
- <cnstcnt/>
- <replcnt/>
- <orddeptnm/>
- <medispclnm/>
- <insukind/>
- <endflagnm/>
- <outstatyn/>
- <indd/>
- <cretno/>
- <seqno/>
- <instcd/>
- </wardpatlist>
- </wardpatinfo>
- <popupmenu>
- <inwardpat>
- <item>
- <name>입실저장</name>
- <func>fSaveInRm</func>
- </item>
- </inwardpat>
- <outwardpat>
- <item>
- <name>종료상태저장</name>
- <func>fSaveOutRm</func>
- </item>
- </outwardpat>
- </popupmenu>
- </main_nm>
- <main_cnst>
- <cnstpatinfo>
- <cnstpatlist>
- <spcffactyn/>
- <pid/>
- <patnm/>
- <sexage/>
- <rgstdd/>
- <lastcnstdd/>
- <mngtflag/>
- <mngtenddd/>
- <insukind/>
- </cnstpatlist>
- <patcntinfo>
- <patcnt/>
- </patcntinfo>
- </cnstpatinfo>
- <patmngtinfo>
- <patmngtdetlinfo>
- <pid/>
- <patnm/>
- <sexage/>
- <rgstno/>
- <hometel/>
- <mpphontel/>
- <addr/>
- <rgstdd/>
- <mngtflag/>
- <mngtenddd/>
- <mngtrem/>
- <status/>
- <existyn/>
- <rgstflag/>
- </patmngtdetlinfo>
- <cnstddlist>
- <cnstdd/>
- <pid/>
- <rgstdd/>
- <recdd/>
- <rectm/>
- </cnstddlist>
- </patmngtinfo>
- <cnstinfo>
- <cnstdetlinfo>
- <cnstdd/>
- <cnstrid/>
- <cnstpath/>
- <relign/>
- <cnstkind/>
- <cnsttype/>
- <cnstcntsflag/>
- <cnstrem/>
- <visitrid/>
- <visitplce/>
- <visitrem/>
- <recdd/>
- <rectm/>
- <recrid/>
- <localcnst/>
- <areacnstfact/>
- </cnstdetlinfo>
- <cnstflagdetlinfo>
- <recdd/>
- <rectm/>
- <cnstclsflag/>
- <cnstseqno/>
- <cnstclscntscd/>
- </cnstflagdetlinfo>
- </cnstinfo>
- <popupmenu>
- <!--
- <patmngt>
- <item>
- <name>대상자삭제</name>
- <func>fDelPatMngtInfo</func>
- </item>
- </patmngt>
- -->
- <patcnst>
- <item>
- <name>기록삭제</name>
- <func>fDelPatCnstInfo</func>
- </item>
- </patcnst>
- </popupmenu>
- </main_cnst>
- <send>
- </send>
- <init>
- <userinfo>
- <userlist>
- <userid/>
- <usernm/>
- </userlist>
- </userinfo>
- <mlist/>
- <patmngtdetlinfo>
- <pid/>
- <patnm/>
- <sexage/>
- <rgstno/>
- <hometel/>
- <mpphontel/>
- <addr/>
- <rgstdd/>
- <mngtflag/>
- <mngtenddd/>
- <mngtrem/>
- <status/>
- <existyn/>
- <rgstflag/>
- </patmngtdetlinfo>
- </init>
- <hidden>
- </hidden>
- <code>
- </code>
- <source/>
- <temp/>
- </root>
- </instance>
- <script type="javascript" ev:event="xforms-ready">
- <![CDATA[
- fInitialize();
- ]]>
- </script>
- <script type="javascript">
- <![CDATA[
- /*** 20090519_SMY ***/
- function fInitialize() {
- model.setValue("/root/main/cond/prestimportid", getScreenMenuParameter());
- model.setValue("/root/main/cond/section", "ATC"); //order manage에서 정렬조건 파라미터로 사용
-
- //공통코드조회
- zbcfGetCodeList( new Array ( "M0536" //종료구분
- ,"M0537" //상담경위
- ,"M0538" //종교
- ,"M0539" //상담종류
- ,"M0540" //상담형태
- ,"M0541" //상담내용
- ,"M0542" //방문장소
- ,"M0549"
- )
- , new Array ( "/root/init/mlist" //종료구분
- ,"/root/init/mlist" //상담경위
- ,"/root/init/mlist" //종교
- ,"/root/init/mlist" //상담종류
- ,"/root/init/mlist" //상담형태
- ,"/root/init/mlist" //상담내용
- ,"/root/init/mlist" //방문장소
- ,"/root/init/mlist" //지역사회의뢰
- )
- );
-
- addComboItem("combo2", "없음", "", "above");//종교 없음 추가
-
- //종료구분 기본값 항목추가
- addComboInstance("/root/init/mlist", "cdid^cdnm", "-^", "M0536");
-
- //알코올의존치료센터 소속 사용자정보조회
- model.removeNodeset("/root/send");
- //model.makeValue("/root/send/wardcd", '2032100000'); //2032100000 : 알코올의존치료센터, 4050411000 : 알코올의존치료팀
- model.makeValue("/root/send/wardcd", getUserInfo("dutplcecd"));
- submit("TRMNC00101");
-
- model.removeNodeset("/root/main_nm/wardpatinfo/wardpatlist");
- model.removeNodeset("/root/main_cnst/cnstpatinfo/cnstpatlist");
- model.removeNodeset("/root/main_cnst/patmngtinfo/cnstddlist");
- //오늘 날짜로 초기화 하는 부분.(진료일자를 default로 오늘 날짜로 선택함)
- if(model.getValue("/root/main/cond/prestimportid") == "cm"){
- model.setValue("/root/main/cond/orddd", getCurrentDate().toDate().getAddDate(-1,"M").getDateFormat());
- model.setValue("/root/main/cond/to_orddd", getCurrentDate());
- }else{
- model.setValue("/root/main/cond/orddd", getCurrentDate());
- }
- //model.setValue("/root/main/cond/wardcd", '2032100000'); //2032100000 : 알코올의존치료센터, 4050411000 : 알코올의존치료팀
- model.setValue("/root/main/cond/wardcd", getUserInfo("dutplcecd")); //알코올의존치료센터부서코드
- model.setValue("/root/main/cond/indschacptstat", "1");
-
- fInqurySelectedPrgm();
- }
-
-
- function fInqurySelectedPrgm() {
- //일반상담 정보 초기화
- model.resetInstanceNode("/root/main_cnst/patmngtinfo/patmngtdetlinfo");
- model.removeNodeset("/root/main_cnst/patmngtinfo/cnstddlist");
- model.resetInstanceNode("/root/main_cnst/cnstinfo/cnstdetlinfo");
-
- switch(model.getValue("/root/main/cond/prestimportid")) {
- case "cm" :
- btn_cm.selected = true;
- sha_state.visible = false;
- cap_state.visible = false;
- cap_color.visible = false;
- cap_uncnfm.visible = false;
- //조회조건
- cap_from.visible = true;
- ipt_to_orddd.visible = true;
- cap_condstat.attribute("text") = "상태 : ";
- rdo_indschacptstat.visible = false;
- rdo_mngtstat.visible = true;
- rdo_mngtstat.attribute("left") = "110px";
- rdo_mngtstat.attribute("top") = "40px";
-
- model.toggle("case_cm");
- fGetCnstPatList();
- break;
- case "om" :
- cap_from.visible = false;
- ipt_to_orddd.visible = false;
- btn_om.selected = true;
- sha_state.visible = false;
- cap_state.visible = false;
- cap_uncnfm.visible = true;
- cap_color.visible = true;
- cap_color.attribute("left") = "15px";
- cap_uncnfm.attribute("left") = "35px";
- //조회조건
- cap_condstat.attribute("text") = "재원상태 : ";
- rdo_indschacptstat.visible = true;
- rdo_mngtstat.visible = false;
-
- model.toggle("case_om");
- fGetOMPatList();
- break;
- case "prn" :
- cap_from.visible = false;
- ipt_to_orddd.visible = false;
- btn_om.selected = true;
- sha_state.visible = false;
- cap_state.visible = false;
- cap_color.visible = false;
- cap_uncnfm.visible = false;
- //조회조건
- cap_condstat.attribute("text") = "재원상태 : ";
- rdo_indschacptstat.visible = true;
- rdo_mngtstat.visible = false;
-
- model.toggle("case_om");
- fSetPrnMode();
- fGetOMPatList();
- break;
- default :
- cap_from.visible = false;
- ipt_to_orddd.visible = false;
- btn_nm.selected = true;
- sha_state.visible = true;
- cap_state.visible = true;
- cap_color.visible = false;
- cap_uncnfm.visible = false;
- grd_wardpatlist.visible = true;
- //조회조건
- cap_condstat.attribute("text") = "재원상태 : ";
- rdo_indschacptstat.visible = true;
- rdo_mngtstat.visible = false;
-
- model.toggle("case_nm");
- fGetWardPatList();
- break;
- }
- }
-
- //상단환자정보세팅하기
- function fSetPatInfo(Flag) {
-
- var condparam = "";
- if(Flag == "I"){
- // 상단 세팅을 위한 파라미터(입원)
- condparam = Flag + "▦" + model.getValue("/root/main_nm/wardpatinfo/wardpatlist["+grd_wardpatlist.row+"]/pid")
- + "▦" + model.getValue("/root/main_nm/wardpatinfo/wardpatlist["+grd_wardpatlist.row+"]/indd")
- + "▦" + model.getValue("/root/main_nm/wardpatinfo/wardpatlist["+grd_wardpatlist.row+"]/cretno")
- + "▦" + model.getValue("/root/main_nm/wardpatinfo/wardpatlist["+grd_wardpatlist.row+"]/instcd")
- + "▦" + model.getValue("/root/main/cond/orddd");
- }else{
- // 상단 세팅을 위한 파라미터(외래)
- condparam = Flag + "▦" + model.getValue("/root/main_cnst/cnstpatinfo/cnstpatlist["+grd_cnstpatlist.row+"]/pid")
- + "▦" + model.getValue("/root/main_cnst/cnstpatinfo/cnstpatlist["+grd_cnstpatlist.row+"]/orddd")
- + "▦" + model.getValue("/root/main_cnst/cnstpatinfo/cnstpatlist["+grd_cnstpatlist.row+"]/cretno")
- + "▦" + model.getValue("/root/main_cnst/cnstpatinfo/cnstpatlist["+grd_cnstpatlist.row+"]/instcd")
- + "▦" + ""
- + "▦" + model.getValue("/root/main_cnst/cnstpatinfo/cnstpatlist["+grd_cnstpatlist.row+"]/orgorddd")
- }
- setParameter("condparam", condparam);
-
- //상단 세팅 화면 사이즈 작게 띄움
- modal("SPMMO08900", 1, "", "", "", "", "", "left:0; right:0; width:0; height:0; sysmenu:hidden; caption:hidden; min:hidden, max:hidden;");
- }
-
- //알코올센터 메인 조회
- function fGetWardPatList() {
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/wardcd", model.getValue("/root/main/cond/wardcd"));
- model.makeValue("/root/send/orddd", model.getValue("/root/main/cond/orddd"));
- model.makeValue("/root/send/indschacptstat", model.getValue("/root/main/cond/indschacptstat"));
- model.makeValue("/root/send/pid", model.getValue("/root/main/cond/pid"));
-
- if(submit("TRMNC00102")){
- for( var i=1; i <grd_wardpatlist.rows; i++ ) {
- var cnstcnt = model.getValue("/root/main_nm/wardpatinfo/wardpatlist[" + i + "]/cnstcnt");
- var replcnt = model.getValue("/root/main_nm/wardpatinfo/wardpatlist[" + i + "]/replcnt");
-
- if (cnstcnt == "0") {
- model.setValue("/root/main_nm/wardpatinfo/wardpatlist[" + i + "]/cnstcnt", "");
- }
- if (replcnt == "0") {
- model.setValue("/root/main_nm/wardpatinfo/wardpatlist[" + i + "]/replcnt", "");
- }
- }
-
- //종료상태 저장시에만 종료구분 콤보 활성화
- if (model.getValue("/root/main/cond/indschacptstat") == "3" || model.getValue("/root/main/cond/indschacptstat") == "4"){ //종료상태저장
- grd_wardpatlist.colDisabled(grd_wardpatlist.colRef("endflag")) = false;
- }else{
- grd_wardpatlist.colDisabled(grd_wardpatlist.colRef("endflag")) = true;
- }
- }
- grd_wardpatlist.refresh();
- }
-
- //입실저장
- function fSaveInRm(){
- if(model.getValue("/root/main/cond/orddd") != getCurrentDate()) {
- messageBox("당일 입원환자에 대해서만 입실저장이", "I006");
- return;
- }
- if(model.getValue("/root/main_nm/wardpatinfo/wardpatlist[" + grd_wardpatlist.row + "]/indschstat") != ""){
- messageBox("이미 입실저장된 환자입니다.", "I");
- return;
- }
-
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/pid", model.getValue("/root/main_nm/wardpatinfo/wardpatlist[" + grd_wardpatlist.row + "]/pid"));
- model.makeValue("/root/send/indd", model.getValue("/root/main_nm/wardpatinfo/wardpatlist[" + grd_wardpatlist.row + "]/indd"));
- model.makeValue("/root/send/cretno", model.getValue("/root/main_nm/wardpatinfo/wardpatlist[" + grd_wardpatlist.row + "]/cretno"));
- model.makeValue("/root/send/instcd", model.getValue("/root/main_nm/wardpatinfo/wardpatlist[" + grd_wardpatlist.row + "]/instcd"));
- model.makeValue("/root/send/curdd", getCurrentDate());
- model.makeValue("/root/send/curtm", getCurrentTime().substr(0,4));
- model.makeValue("/root/send/status", "U");
- model.makeValue("/root/send/ordflag", "01");
-
- if(submit("TXMNC00103")){ //wardcare입실저장쿼리 사용
- var sMessage = "";
- sMessage = model.getValue("/root/main_nm/wardpatinfo/wardpatlist[" + grd_wardpatlist.row + "]/pid") + " "
- + model.getValue("/root/main_nm/wardpatinfo/wardpatlist[" + grd_wardpatlist.row + "]/patnm") + " "
- + model.getValue("/root/main_nm/wardpatinfo/wardpatlist[" + grd_wardpatlist.row + "]/sexage") + " "
- + "입실등록되었습니다." ;
-
- messageBox(sMessage, "I");
-
- fInqurySelectedPrgm();
-
- }
- }
-
- //종료상태저장
- function fSaveOutRm(){
- if (model.getValue("/root/main_nm/wardpatinfo/wardpatlist[" + grd_wardpatlist.row + "]/endflag") == ""){
- messageBox("종료상태가 선택되지 않았습니다.", "I");
- return;
- }
-
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/pid", model.getValue("/root/main_nm/wardpatinfo/wardpatlist[" + grd_wardpatlist.row + "]/pid"));
- model.makeValue("/root/send/indd", model.getValue("/root/main_nm/wardpatinfo/wardpatlist[" + grd_wardpatlist.row + "]/indd"));
- model.makeValue("/root/send/cretno", model.getValue("/root/main_nm/wardpatinfo/wardpatlist[" + grd_wardpatlist.row + "]/cretno"));
- model.makeValue("/root/send/instcd", model.getValue("/root/main_nm/wardpatinfo/wardpatlist[" + grd_wardpatlist.row + "]/instcd"));
- model.makeValue("/root/send/endflag", model.getValue("/root/main_nm/wardpatinfo/wardpatlist[" + grd_wardpatlist.row + "]/endflag"));
-
- var status = "";
- if(model.getValue("/root/main_nm/wardpatinfo/wardpatlist[" + grd_wardpatlist.row + "]/outstatyn") == "Y"){
- status = "U";
- }else {
- status = "I";
- }
- model.makeValue("/root/send/status", status);
-
- if(submit("TXMNC00104")){
- var sMessage = "";
- sMessage = model.getValue("/root/main_nm/wardpatinfo/wardpatlist[" + grd_wardpatlist.row + "]/pid") + " "
- + model.getValue("/root/main_nm/wardpatinfo/wardpatlist[" + grd_wardpatlist.row + "]/patnm") + " "
- + model.getValue("/root/main_nm/wardpatinfo/wardpatlist[" + grd_wardpatlist.row + "]/sexage") + " "
- + "종료상태가 저장되었습니다." ;
-
- messageBox(sMessage, "I");
-
- fInqurySelectedPrgm();
-
- }
- }
-
- //상담기록 환자리스트 조회
- function fGetCnstPatList(){
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/orddd", model.getValue("/root/main/cond/orddd"));
- model.makeValue("/root/send/to_orddd", model.getValue("/root/main/cond/to_orddd"));
- model.makeValue("/root/send/mngtstat", model.getValue("/root/main/cond/mngtstat"));
- model.makeValue("/root/send/pid", model.getValue("/root/main/cond/pid"));
- submit("TRMNC00103");
- }
-
- //상담환자상세내역, 상담일자 리스트 조회
- function fGetPatMngtInfo(){
- model.removeNodeset("/root/send");
- if(model.getValue("/root/main_cnst/cnstpatinfo/cnstpatlist[" + grd_cnstpatlist.row + "]/pid") =='기명상담'){
- model.makeValue("/root/send/pid", model.getValue("/root/main_cnst/cnstpatinfo/cnstpatlist[" + grd_cnstpatlist.row + "]/patnm"));
- } else{
- model.makeValue("/root/send/pid", model.getValue("/root/main_cnst/cnstpatinfo/cnstpatlist[" + grd_cnstpatlist.row + "]/pid"));
- }
-
- model.makeValue("/root/send/rgstdd", model.getValue("/root/main_cnst/cnstpatinfo/cnstpatlist[" + grd_cnstpatlist.row + "]/rgstdd"));
- submit("TRMNC00104");
- }
-
- //상담일자별 상담정보조회
- function fGetPatCnstInfo(){
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/pid", model.getValue("/root/main_cnst/patmngtinfo/cnstddlist[" + grd_cnstddlist.row + "]/pid"));
- model.makeValue("/root/send/rgstdd", model.getValue("/root/main_cnst/patmngtinfo/cnstddlist[" + grd_cnstddlist.row + "]/rgstdd"));
- model.makeValue("/root/send/recdd", model.getValue("/root/main_cnst/patmngtinfo/cnstddlist[" + grd_cnstddlist.row + "]/recdd"));
- model.makeValue("/root/send/rectm", model.getValue("/root/main_cnst/patmngtinfo/cnstddlist[" + grd_cnstddlist.row + "]/rectm"));
- if(submit("TRMNC00105", false)){
-
- var cnstclsflag = "";
- var cnstclscntscd = "";
- var cnstpath = "";
- var cnstkind = "";
- var cnsttype = "";
- var cnstcntsflag = "";
- var visitplce = "";
- var areacnst ="";
- var areacnstfact= "";
-
- for(i = 1; i <= getNodesetCount("/root/main_cnst/cnstinfo/cnstflagdetlinfo"); i++) {
- cnstclsflag = model.getValue("/root/main_cnst/cnstinfo/cnstflagdetlinfo[" + i + "]/cnstclsflag");
- cnstclscntscd = model.getValue("/root/main_cnst/cnstinfo/cnstflagdetlinfo[" + i + "]/cnstclscntscd");
-
-
- //상담경위
- if(cnstclsflag == "A"){
- if(cnstpath == ""){
- cnstpath = cnstclscntscd;
- }else{
- cnstpath += "▦" + cnstclscntscd;
- }
- //상담종류
- }else if(cnstclsflag == "B"){
- if(cnstkind == ""){
- cnstkind = cnstclscntscd;
- }else{
- cnstkind += "▦" + cnstclscntscd;
- }
- //상담형태
- }else if(cnstclsflag == "C"){
- if(cnsttype == ""){
- cnsttype = cnstclscntscd;
- }else{
- cnsttype += "▦" + cnstclscntscd;
- }
- //상담내용
- }else if(cnstclsflag == "D"){
- if(cnstcntsflag == ""){
- cnstcntsflag = cnstclscntscd;
- }else{
- cnstcntsflag += "▦" + cnstclscntscd;
- }
- //방문장소
- }else if (cnstclsflag == "E"){
- if(visitplce == ""){
- visitplce = cnstclscntscd;
- }else{
- visitplce += "▦" + cnstclscntscd;
- }
- } else {
- //지역사회의뢰
- if(areacnst == ""){
- areacnst = cnstclscntscd;
- }else{
- areacnst += "▦" + cnstclscntscd;
- }
- areacnstfact = model.getValue("/root/main_cnst/cnstinfo/cnstflagdetlinfo[" + i + "]/areacnstfact");
- }
- }
- model.setValue("/root/main_cnst/cnstinfo/cnstdetlinfo/cnstpath", cnstpath);
- model.setValue("/root/main_cnst/cnstinfo/cnstdetlinfo/cnstkind", cnstkind);
- model.setValue("/root/main_cnst/cnstinfo/cnstdetlinfo/cnsttype", cnsttype);
- model.setValue("/root/main_cnst/cnstinfo/cnstdetlinfo/cnstcntsflag", cnstcntsflag);
- model.setValue("/root/main_cnst/cnstinfo/cnstdetlinfo/visitplce", visitplce);
- model.setValue("/root/main_cnst/cnstinfo/cnstdetlinfo/localcnst", areacnst);
- model.setValue("/root/main_cnst/cnstinfo/cnstdetlinfo/areacnstfact", areacnstfact);
- chk_local.dispatch("xforms-value-changed");
- model.refresh();
- }
- }
-
- //상담대상환자정보 저장, 수정
- function fSetPatMngtInfo(){
- var pid = model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/pid");
- var rgstdd = model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstdd");
- var rgstflag = model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstflag");
- var patcnt = model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/patcnt");//이용자
- var rgstplce = "";
- if (rgstflag == "A") {
- rgstplce = "익명상담";
- } else if (rgstflag == "I"){
- rgstplce = "인터넷상담";
- }
- /*
- for (i = 0; i < grd_cnstpatlist.rows; i++ ) {
- var cnstpid = model.getValue("/root/main_cnst/cnstpatinfo/cnstpatlist[" + i + "]/pid");
- var cnstrgstdd = model.getValue("/root/main_cnst/cnstpatinfo/cnstpatlist[" + i + "]/rgstdd");
- if (pid == cnstpid && rgstdd == cnstrgstdd) {
- messageBox(rgstdd + "일 " + rgstplce + "은 이미 등록되어 있습니다.\n 상담관리 리스트에서 선택하십시오", "I")
- return;
- }
- }
- */
- if(model.getValue("/root/main_cnst/cnstpatinfo/cnstpatlist/mngtflag") == "2" && model.getValue("/root/main_cnst/cnstpatinfo/cnstpatlist/mngtenddd") == ""){
- messageBox("관리종료일을 입력해주십시오.", "I");
- return;
- }
-
- model.removeNodeset("/root/send");
- model.makeNode("/root/send");
- model.makeValue("/root/send/status", model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/status"));
- if(model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstflag") == "G") { //기명상담일때
- model.makeValue("/root/send/pid", model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/patnm"));
- } else {
- model.makeValue("/root/send/pid", model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/pid"));
- }
- model.makeValue("/root/send/rgstdd", model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstdd"));
- model.makeValue("/root/send/mngtflag", model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtflag"));
- model.makeValue("/root/send/rgstflag", model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstflag"));
- model.makeValue("/root/send/patcnt", patcnt);//이용자
- if(model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtenddd") == ""){
- model.makeValue("/root/send/mngtenddd", '99991231');
- }else{
- model.makeValue("/root/send/mngtenddd", model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtenddd"));
- }
- model.makeValue("/root/send/mngtrem", model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtrem"));
-
- var status = "";
- if(model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/existyn") == "Y"){
- status = "U";
- }else {
- status = "I";
- }
- model.makeValue("/root/send/status", status);
-
- if(submit("TXMNC00101")){
- fInqurySelectedPrgm(); //일반상담리스트 조회
- }
- }
- /*
- //상담대상환자정보 삭제
- function fDelPatMngtInfo(){
- model.removeNodeset("/root/send");
- model.makeNode("/root/send");
- model.makeValue("/root/send/status", "D");
- model.makeValue("/root/send/pid", model.getValue("/root/main_cnst/cnstpatinfo/cnstpatlist[" + grd_cnstpatlist.row + "]/pid"));
- model.makeValue("/root/send/rgstdd", model.getValue("/root/main_cnst/cnstpatinfo/cnstpatlist[" + grd_cnstpatlist.row + "]/rgstdd"));
-
- if(submit("TXMNC00101")){
- model.resetInstanceNode("/root/main_cnst/patmngtinfo/patmngtdetlinfo");
- fInqurySelectedPrgm(); //일반상담리스트 조회
- }
- }
- */
- //상담기록정보 저장, 수정
- function fSetPatCnstInfo(){
- var pid = model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/pid")
- var existyn = model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/existyn")
- if (isNull(pid) || existyn != 'Y') {
- messageBox("환자관리에 등록된 환자가 아닙니다.", "I");
- return;
- }
- model.removeNodeset("/root/send");
- model.makeNode("/root/send");
- //저장상태
- var status = "";
- var recdd = "";
- var rectm = "";
- var recrid = "";
- if(model.getValue("/root/main_cnst/cnstinfo/cnstdetlinfo/recdd") == ""){
- status = "I";
- recdd = getCurrentDate();
- rectm = getCurrentTime().substr(0,6);
- recrid = getUserId();
-
- }else{
- status = "U";
- recdd = model.getValue("/root/main_cnst/cnstinfo/cnstdetlinfo/recdd");
- rectm = model.getValue("/root/main_cnst/cnstinfo/cnstdetlinfo/rectm");
- recrid = getUserId();
- }
- model.makeValue("/root/send/recdd", recdd);
- model.makeValue("/root/send/rectm", rectm);
- model.makeValue("/root/send/recrid", recrid);
- model.makeValue("/root/send/status", status);
- model.makeValue("/root/send/pid", model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/pid"));
- model.makeValue("/root/send/rgstdd", model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstdd"));
- model.makeValue("/root/send/cnstdd", model.getValue("/root/main_cnst/cnstinfo/cnstdetlinfo/cnstdd"));
- model.makeValue("/root/send/cnstrid", model.getValue("/root/main_cnst/cnstinfo/cnstdetlinfo/cnstrid"));
- model.makeValue("/root/send/relign", model.getValue("/root/main_cnst/cnstinfo/cnstdetlinfo/relign"));
- model.makeValue("/root/send/cnstrem", model.getValue("/root/main_cnst/cnstinfo/cnstdetlinfo/cnstrem"));
- model.makeValue("/root/send/visitrid", model.getValue("/root/main_cnst/cnstinfo/cnstdetlinfo/visitrid"));
- model.makeValue("/root/send/visitrem", model.getValue("/root/main_cnst/cnstinfo/cnstdetlinfo/visitrem"));
-
- //model.makeValue("/root/send/cnstpath", model.getValue("/root/main_cnst/cnstinfo/cnstdetlinfo/cnstpath"));
- //model.makeValue("/root/send/cnstkind", model.getValue("/root/main_cnst/cnstinfo/cnstdetlinfo/cnstkind"));
- //model.makeValue("/root/send/cnsttype", model.getValue("/root/main_cnst/cnstinfo/cnstdetlinfo/cnsttype"));
- //model.makeValue("/root/send/cnstcntsflag", model.getValue("/root/main_cnst/cnstinfo/cnstdetlinfo/cnstcntsflag"));
- //model.makeValue("/root/send/visitplce", model.getValue("/root/main_cnst/cnstinfo/cnstdetlinfo/visitplce"));
-
- //상담경위, 상담종류, 상담형태, 상담내용, 방문장소 다중선택 로직 변경_20090618
- var CnstClsHeader = "pid▦rgstdd▦recdd▦rectm▦cnstclsflag▦cnstseqno▦areacnstfact▦cnstclscntscd▩";
- var CnstClsData = "";
-
- //상담경위
- var cnstpathVal = chk_cnstpath.value;
- var cnstpathArrVal = cnstpathVal.split("▦");
-
- for(var i = 1; i <= chk_cnstpath.length; i++) {
- if(cnstpathArrVal[i-1] > "00"){
- CnstClsData += model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/pid") +"▦"
- + model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstdd") +"▦"
- + recdd +"▦"
- + rectm +"▦"
- + "A" +"▦"
- + "" +"▦"
- + "" +"▦"
- + cnstpathArrVal[i-1] +"▩";
- }
- }
-
- //상담종류
- var cnstkindVal = chk_cnstkind.value;
- var cnstkindArrVal = cnstkindVal.split("▦");
-
- for(var i = 1; i <= chk_cnstkind.length; i++) {
- if(cnstkindArrVal[i-1] > "00"){
- CnstClsData += model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/pid") +"▦"
- + model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstdd") +"▦"
- + recdd +"▦"
- + rectm +"▦"
- + "B" +"▦"
- + "" +"▦"
- + "" +"▦"
- + cnstkindArrVal[i-1] +"▩";
- }
- }
-
- //상담형태
- var cnsttypeVal = chk_cnsttype.value;
- var cnsttypeArrVal = cnsttypeVal.split("▦");
-
- for(var i = 1; i <= chk_cnsttype.length; i++) {
- if(cnsttypeArrVal[i-1] > "00"){
- CnstClsData += model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/pid") +"▦"
- + model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstdd") +"▦"
- + recdd +"▦"
- + rectm +"▦"
- + "C" +"▦"
- + "" +"▦"
- + "" +"▦"
- + cnsttypeArrVal[i-1] +"▩";
- }
- }
-
- //상담내용
- var cnstcntsflagVal = chk_cnstcntsflag.value;
- var cnstcntsflagArrVal = cnstcntsflagVal.split("▦");
-
- for(var i = 1; i <= chk_cnstcntsflag.length; i++) {
- if(cnstcntsflagArrVal[i-1] > "00"){
- CnstClsData += model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/pid") +"▦"
- + model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstdd") +"▦"
- + recdd +"▦"
- + rectm +"▦"
- + "D" +"▦"
- + "" +"▦"
- + "" +"▦"
- + cnstcntsflagArrVal[i-1] +"▩";
- }
- }
-
- //방문장소
- var visitplceVal = chk_visitplce.value;
- var visitplceArrVal = visitplceVal.split("▦");
-
- for(var i = 1; i <= chk_visitplce.length; i++) {
- if(visitplceArrVal[i-1] > "00"){
- CnstClsData += model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/pid") +"▦"
- + model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstdd") +"▦"
- + recdd +"▦"
- + rectm +"▦"
- + "E" +"▦"
- + "" +"▦"
- + "" +"▦"
- + visitplceArrVal[i-1] +"▩";
- }
- }
-
- //지역사회 의뢰
- var areaCnstVal = chk_local.value;
- var areCnstArrVal = areaCnstVal.split("▦");
-
- for(var i = 1; i <= chk_local.length; i++) {
- if(areCnstArrVal[i-1] > "00"){
- CnstClsData += model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/pid") +"▦"
- + model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstdd") +"▦"
- + recdd +"▦"
- + rectm +"▦"
- + "F" +"▦"
- + "" +"▦"
- + model.getValue("/root/main_cnst/cnstinfo/cnstdetlinfo/areacnstfact") +"▦"
- + areCnstArrVal[i-1] +"▩";
- }
- }
-
- model.makeValue("/root/send/cnstflag", CnstClsHeader+CnstClsData);
-
- if(submit("TXMNC00102")){
- fInqurySelectedPrgm(); //일반상담리스트 조회
- }
- }
-
- //상담기록정보 삭제
- function fDelPatCnstInfo(){
- var rtn = messageBox("상담기록을", "Q001");
- if (rtn == "6"){
- model.removeNodeset("/root/send");
- model.makeNode("/root/send");
- model.makeValue("/root/send/pid", model.getValue("/root/main_cnst/patmngtinfo/cnstddlist[" + grd_cnstddlist.row + "]/pid"));
- model.makeValue("/root/send/rgstdd", model.getValue("/root/main_cnst/patmngtinfo/cnstddlist[" + grd_cnstddlist.row + "]/rgstdd"));
- model.makeValue("/root/send/recdd", model.getValue("/root/main_cnst/patmngtinfo/cnstddlist[" + grd_cnstddlist.row + "]/recdd"));
- model.makeValue("/root/send/rectm", model.getValue("/root/main_cnst/patmngtinfo/cnstddlist[" + grd_cnstddlist.row + "]/rectm"));
- model.makeValue("/root/send/status", "D");
-
- if(submit("TXMNC00102")){
- fInqurySelectedPrgm(); //일반상담리스트 조회
- }
- }
- }
-
- function fShowPopupMenu(gridID, menuPath)
- {
- var gridObj = document.controls.item(gridID);
-
- if(event.button == 3) {
- if(gridObj.isCell(event.target) && gridObj.mouseRow >= gridObj.fixedrows){
- window.setPopupMenu(true, menuPath, "name", "func", false);
- }else{
- window.setPopupMenu(false);
- }
- }
- }
- ]]>
- </script>
- <script type="javascript" src="../../../emr/carecomweb/js/CareCom.js"/>
- <script type="javascript" src="../../../com/commonweb/js/common.js"/>
- <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
- <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
- <script type="javascript" src="../../../com/departmentcodeweb/js/ZSD001.js"/>
- <script type="javascript" src="../../../pam/pamcomnweb/js/PAM.js"/>
- <script type="javascript" src="../../../com/basiccodeweb/js/ZBC001.js"/>
- <script type="javascript" src="../../../emr/prcpmngtweb/js/MMO001.js"/>
- <submission id="TRMNC00101" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/init/userinfo"/>
- <submission id="TRMNC00102" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main_nm/wardpatinfo"/>
- <submission id="TRMNC00103" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main_cnst/cnstpatinfo"/>
- <submission id="TRMNC00104" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main_cnst/patmngtinfo"/>
- <submission id="TRMNC00105" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main_cnst/cnstinfo"/>
- <submission id="TXMNC00101" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/temp"/>
- <submission id="TXMNC00102" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send"/>
- <submission id="TXMNC00103" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send"/>
- <submission id="TXMNC00104" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send"/>
- <submission id="TRMNW00001" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/code/codelist"/>
- <submission id="TRZBC00101" mediatype="application/x-www-form-urlencoded" method="post"/>
- <submission id="TXMNC00105" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send"/>
- </model>
- </xhtml:head>
- <xhtml:body guideline="1,1195;1,1193;2,124;" style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
- <group id="group1" style="left:0px; top:0px; width:1195px; height:13px; ">
- <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:189px; height:14px; ">알코올센터 메인</caption>
- </group>
- <group id="group3" scroll="auto" style="left:0px; top:13px; width:1195px; height:742px; ">
- <button id="btn_nm" class="btn_sw" group="tab" style="left:0px; top:84px; width:115px; height:22px; ">
- <caption>알코올센터 Main</caption>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
- group5.visible = false;
- model.setValue("/root/main/cond/prestimportid", "nm");
- model.setValue("/root/main/cond/orddd", getCurrentDate());
- //조회조건 등록번호 초기화
- model.resetInstanceNode("/root/main/cond/pid");
- fInqurySelectedPrgm();
- ]]>
- </script>
- <toggle case="case_nm" ev:event="onclick"/>
- </button>
- <button id="btn_om" class="btn_sw" group="tab" style="left:115px; top:84px; width:122px; height:22px; ">
- <caption>Order Manage</caption>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
- group5.visible = false;
- if(model.getValue("/root/main/cond/prestimportid") == "cm"){
- model.setValue("/root/main/cond/orddd", getCurrentDate());
-
- }
- //조회조건 등록번호 초기화
- model.resetInstanceNode("/root/main/cond/pid");
- model.setValue("/root/main/cond/prestimportid", "om");
- fInqurySelectedPrgm();
- ]]>
- </script>
- <toggle case="case_om" ev:event="onclick"/>
- </button>
- <button id="btn_cm" class="btn_sw" group="tab" style="left:237px; top:84px; width:122px; height:22px; ">
- <caption>상담관리</caption>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
- group5.visible = true;
- delPatientInfos(); //화면상단정보 삭제
- setGlobalVariable("paminfo", ""); //원무정보 reset
-
- model.setValue("/root/main/cond/prestimportid", "cm");
- model.setValue("/root/main/cond/orddd", getCurrentDate().toDate().getAddDate(-1,"M").getDateFormat());
- model.setValue("/root/main/cond/to_orddd", getCurrentDate());
- model.setValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstdd", getCurrentDate()); //등록일
- //조회조건 등록번호 초기화
- model.resetInstanceNode("/root/main/cond/pid");
-
- fInqurySelectedPrgm();
- ]]>
- </script>
- <toggle case="case_cm" ev:event="onclick"/>
- </button>
- <switch id="swt_main" style="left:0px; top:105px; width:1195px; height:636px; border-color:#c7a3cf; border-style:solid; ">
- <case id="case_nm" selected="true" style="left:0px; top:0px; width:1195px; height:709px; ">
- <datagrid id="grd_wardpatlist" nodeset="/root/main_nm/wardpatinfo/wardpatlist" class="datagrid2" allowbigselection="false" allowselection="false" caption="특이^재원
상태^등록번호^환자명^S/A^입원일^교육
일수^종료예정일^퇴원일^종료구분^의
뢰^회
신^진료과^주치의^자격^종료구분명^endflagnm" colsep="^" colwidth="37, 33, 100, 75, 44, 100, 41, 100, 100, 75, 30, 30, 164, 75, 120, 0" ellipsis="true" explorerbar="sort" frozencols="12" mergecellsfixedrows="bycolrec" multitotal="false" rowheader="seq" rowheight="32" rowsep="|" tooltip="true" style="left:5px; top:8px; width:1183px; height:622px; ">
- <col ref="spcffactyn" style="text-align:center; "/>
- <col ref="indschstat" style="text-align:center; border-left-width:0; "/>
- <col ref="pid" style="text-align:center; "/>
- <col ref="patnm" style="text-align:center; "/>
- <col ref="sexage" style="text-align:center; "/>
- <col ref="findd" style="text-align:center; "/>
- <col ref="hd" style="text-align:center; "/>
- <col ref="endschedd" style="text-align:center; "/>
- <col ref="dschdd" style="text-align:center; "/>
- <col class="gridcombo" ref="endflag" type="combo" style="text-align:center; ">
- <choices>
- <itemset nodeset="/root/init/mlist/M0536">
- <label ref="cdnm"/>
- <value ref="cdid"/>
- </itemset>
- </choices>
- </col>
- <col ref="cnstcnt" style="text-align:center; "/>
- <col ref="replcnt" style="text-align:center; "/>
- <col ref="orddeptnm" style="text-align:center; "/>
- <col ref="medispclnm" style="text-align:center; "/>
- <col ref="insukind" style="text-align:center; "/>
- <col ref="endflagnm"/>
- <script type="javascript" ev:event="ondblclick">
- <![CDATA[
- if( isDataCell()) {
- //특이사항이 있을 경우 상단환자세팅을 하고 특이 정보를 띄움
- if (grd_wardpatlist.col == grd_wardpatlist.colRef("spcffactyn") && grd_wardpatlist.valueMatrix(grd_wardpatlist.row, grd_wardpatlist.colRef("spcffactyn")) == "★") {
- fSetPatInfo("I");
-
- model.makeNode("/root/source/srchcond");
- model.makeNode("/root/source/pid");
- model.setValue("/root/source/srchcond", 1);
- model.setValue("/root/source/pid", model.getValue("/root/main_nm/wardpatinfo/wardpatlist["+grd_wardpatlist.row+"]/pid"));
- modal("SMPMC01300", "1", "", "", "SMPMC01300", "/root/source", "/root/source");
- //이외는 상단환자세팅
- } else {
- fSetPatInfo("I");
- }
- }
- ]]>
- </script>
- <script type="javascript" ev:event="onmousedown">
- <![CDATA[
- if(model.getValue("/root/main/cond/indschacptstat") == "2"){ //입실저장
- fShowPopupMenu("grd_wardpatlist","/root/main_nm/popupmenu/inwardpat/item");
-
- }else if (model.getValue("/root/main/cond/indschacptstat") == "3" || model.getValue("/root/main/cond/indschacptstat") == "4"){ //종료상태저장
- fShowPopupMenu("grd_wardpatlist","/root/main_nm/popupmenu/outwardpat/item");
- }
- ]]>
- </script>
- <script type="javascript" ev:event="DOMFocusOut">
- <![CDATA[
- window.setPopupMenu(false);
- ]]>
- </script>
- <script type="javascript" ev:event="onaftersort">
- <![CDATA[
- grd_wardpatlist.gridToInstance();
- ]]>
- </script>
- </datagrid>
- <line id="line1" class="line_1" style="x1:5px; y1:3px; x2:1188px; y2:3px; "/>
- </case>
- <case id="case_om">
- <import id="import3" src="SMMNW00300_Order Manage.xrw" style="left:0px; top:0px; width:1190px; height:634px; "/>
- </case>
- <case id="case_cm">
- <datagrid id="grd_cnstpatlist" nodeset="/root/main_cnst/cnstpatinfo/cnstpatlist" class="datagrid2" allowbigselection="false" allowselection="false" caption="특이^등록번호^환자명^S/A^등록일^최종상담일^관리구분^관리종료일^자격^rgstflag^nrsetting^indd^cretno^seqno^instcd^atdoctid^rgstno" colsep="^" colwidth="48, 84, 95, 55, 84, 84, 75, 84, 95, 0" ellipsis="true" explorerbar="sort" frozencols="12" mergecellsfixedrows="bycolrec" multitotal="false" rowheader="seq" rowheight="32" rowsep="|" tooltip="true" style="left:5px; top:8px; width:657px; height:618px; ">
- <col ref="spcffactyn" style="text-align:center; "/>
- <col ref="pid" style="text-align:center; "/>
- <col ref="patnm" style="text-align:center; "/>
- <col ref="sexage" style="text-align:center; "/>
- <col ref="rgstdd" format="yyyy/mm/dd" style="text-align:center; "/>
- <col ref="lastcnstdd" format="yyyy/mm/dd" style="text-align:center; "/>
- <col ref="mngtflag" style="text-align:center; "/>
- <col ref="mngtenddd" format="yyyy/mm/dd" style="text-align:center; "/>
- <col ref="insukind" visibility="hidden" style="text-align:center; "/>
- <col ref="rgstflag" visibility="hidden"/>
- <script type="javascript" ev:event="ondblclick">
- <![CDATA[
- if( isDataCell() ) {
- model.resetInstanceNode("/root/main_cnst/cnstinfo/cnstdetlinfo");
-
- model.setValue("/root/main_cnst/cnstinfo/cnstdetlinfo/cnstdd", getCurrentDate()); //상담일자 셋팅
- model.setValue("/root/main_cnst/cnstinfo/cnstdetlinfo/cnstrid", getUserId());
- model.setValue("/root/main_cnst/cnstinfo/cnstdetlinfo/visitrid", getUserId());
-
- fGetPatMngtInfo();
-
- //관리구분에 따른 종료일 disable
- if(model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtflag") == "2"){
- ipt_mngtenddd.disabled = false;
- }else{
- ipt_mngtenddd.disabled = true;
- }
- ipt_mngtenddd.refresh();
- }
- var rgstflag = model.getValue("/root/main_cnst/cnstpatinfo/cnstpatlist[" + grd_cnstpatlist.row + "]/rgstflag");
- if (rgstflag != "H") {
- if (rgstflag == "A") {
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/patnm", "익명상담");
- opt_valitrgtpid.disabled = true;
- } else if (rgstflag == "I") {
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/patnm", "인터넷상담");
- opt_valitrgtpid.disabled = true;
- } else if (rgstflag == "G") {
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/patnm", model.getValue("/root/main_cnst/cnstpatinfo/cnstpatlist[" + grd_cnstpatlist.row + "]/patnm"));
- opt_valitrgtpid.disabled = false;
- }
- //group4.disabled = true;
- combo5.disabled = true;
- ipt_mngtenddd.disabled = true;
- textarea2.disabled = true;
- rdo_rgstflag.disabled = true;
-
- } else {
- group4.disabled = false;
- rdo_rgstflag.disabled = false;
- opt_valitrgtpid.disabled = true;
- }
-
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstflag", rgstflag);
- model.refresh();
- ]]>
- </script>
- <script type="javascript" ev:event="onmousedown">
- <![CDATA[
- fShowPopupMenu("grd_cnstpatlist","/root/main_cnst/popupmenu/patmngt/item");
- ]]>
- </script>
- <script type="javascript" ev:event="DOMFocusOut">
- <![CDATA[
- window.setPopupMenu(false);
- ]]>
- </script>
- <script type="javascript" ev:event="onaftersort">
- <![CDATA[
- grd_cnstpatlist.gridToInstance();
- ]]>
- </script>
- </datagrid>
- <line id="line2" class="line_1" style="x1:5px; y1:3px; x2:662px; y2:3px; "/>
- <button id="btn_bdinfo" class="btn5_letter2" style="left:1149px; top:2px; width:42px; height:19px; ">
- <caption>저장</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- fSetPatMngtInfo();
- ]]>
- </script>
- </button>
- <button id="button2" class="btn2_letter2" style="left:1108px; top:2px; width:42px; height:19px; ">
- <caption>채번</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- model.resetInstanceNode("/root/source");
- model.makeValue("/root/source/srchcond", '1');
- model.makeValue("/root/source/pid", model.getValue("/root/main/ptbs/ptbs_pid"));
- modal("SMPMC01400", "1", "100", "100" ,"SMPMC01400","","");
-
- var newPID = getParameter("SMPMC01400_PID");
-
- //상담환자상세내역, 상담일자 리스트 조회
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/srchflag", "Y");
- model.makeValue("/root/send/pid", newPID);
- model.makeValue("/root/send/rgstdd", getCurrentDate());
-
- if(submit("TRMNC00104")){
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstdd", getCurrentDate());
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtflag", "1");
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtenddd", "");
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtrem", "");
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/status", "I");
-
- for(i = 1; i <= getNodesetCount("/root/main_cnst/cnstpatinfo/cnstpatlist/pid"); i++) {
- if(model.getValue("/root/main_cnst/cnstpatinfo/cnstpatlist[" + i + "]/pid") == newPID){
- grd_cnstpatlist.row = i;
- grd_cnstpatlist.topRow = i;
- }
- }
- }
- model.refresh();
- ]]>
- </script>
- </button>
- <button id="btn_receipt" class="btn2_letter2" visibility="hidden" style="left:1026px; top:2px; width:42px; height:19px; ">
- <caption>접수</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- modal("SMPMO00100", "1", "", "", "SMPMO00100", "", "");
- ]]>
- </script>
- </button>
- <line id="line128" class="line_1" style="x1:672px; y1:22px; x2:1186px; y2:22px; "/>
- <caption id="caption2" class="tit_2" style="left:665px; top:7px; width:74px; height:13px; ">환자관리</caption>
- <select1 id="rdo_rgstflag" ref="/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstflag" appearance="full" cellspacing="0" cols="4" overflow="visible" style="left:767px; top:4px; width:293px; height:20px; border-style:none; ">
- <choices>
- <item>
- <label>병원상담자</label>
- <value>H</value>
- </item>
- <item>
- <label>인터넷상담</label>
- <value>I</value>
- </item>
- <item>
- <label>익명상담</label>
- <value>A</value>
- </item>
- <item>
- <label>기명상담</label>
- <value>G</value>
- </item>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- var rgstflag = model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstflag");
- if (rgstflag == "H") {
- group4.disabled = false;
- opt_valitrgtpid.disabled = true;
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/pid", "");
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/patnm", "");
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstdd", getCurrentDate());
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtflag", "1");
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtenddd", "99991231");
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtrem", "");
- } else {
- if (rgstflag == "I") {
- opt_valitrgtpid.disabled = true;
- combo5.disabled = true;
- ipt_mngtenddd.disabled = true;
- textarea2.disabled = true;
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/pid", "Internet");
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/patnm", "인터넷상담");
- } else if(rgstflag == "A") {
- opt_valitrgtpid.disabled = true;
- combo5.disabled = true;
- ipt_mngtenddd.disabled = true;
- textarea2.disabled = true;
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/pid", "Anon");
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/patnm", "익명상담");
- } else if(rgstflag == "G") {
- opt_valitrgtpid.disabled = false;
- combo5.disabled = true;
- ipt_mngtenddd.disabled = true;
- textarea2.disabled = true;
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/pid", "Gnon");
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/patnm", model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/patnm"));
- model.refresh();
- }
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstdd", getCurrentDate());
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtflag", "2");
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtenddd", getCurrentDate());
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtrem", "");
- }
- model.refresh();
- ]]>
- </script>
- </select1>
- <line id="line8" class="line_2" style="x1:755px; y1:228px; x2:1184px; y2:228px; "/>
- <line id="line9" class="line_2" style="x1:755px; y1:255px; x2:1184px; y2:255px; "/>
- <line id="line10" class="line_2" style="x1:756px; y1:282px; x2:1185px; y2:282px; "/>
- <line id="line11" class="line_2" style="x1:756px; y1:309px; x2:1185px; y2:309px; "/>
- <input id="ipt_areacnst" ref="/root/main_cnst/cnstinfo/cnstdetlinfo/areacnstfact" disabled="true" style="left:950px; top:467px; width:235px; height:19px; "/>
- <line id="line12" class="line_2" style="x1:755px; y1:463px; x2:1184px; y2:463px; "/>
- <button id="button5" class="btn5_letter2" style="left:1144px; top:177px; width:42px; height:19px; ">
- <caption>저장</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- fSetPatCnstInfo();
- ]]>
- </script>
- </button>
- <caption id="caption10" class="cell_1" style="left:755px; top:257px; width:88px; height:24px; vertical-align:middle; ">종교</caption>
- <caption id="caption21" class="cell_1" style="left:755px; top:519px; width:88px; height:24px; vertical-align:middle; ">방문장소</caption>
- <line id="line14" class="line_2" style="x1:755px; y1:490px; x2:1184px; y2:490px; "/>
- <caption id="caption22" class="cell_1" style="left:755px; top:547px; width:88px; height:81px; vertical-align:middle; ">비고</caption>
- <select1 id="combo1" ref="/root/main_cnst/cnstinfo/cnstdetlinfo/cnstrid" class="combo_default" appearance="minimal" style="left:1046px; top:205px; width:120px; height:19px; ">
- <choices>
- <itemset nodeset="/root/init/userinfo/userlist">
- <label ref="usernm"/>
- <value ref="userid"/>
- </itemset>
- </choices>
- </select1>
- <caption id="caption11" class="cell_1" style="left:755px; top:203px; width:88px; height:24px; vertical-align:middle; ">상담일</caption>
- <select id="chk_visitplce" ref="/root/main_cnst/cnstinfo/cnstdetlinfo/visitplce" overflow="visible" appearance="full" cellspacing="10" cols="3" sep="▦" style="left:845px; top:522px; width:245px; height:18px; border-style:none; ">
- <choices>
- <itemset nodeset="/root/init/mlist/M0542">
- <label ref="cdnm"/>
- <value ref="cdid"/>
- </itemset>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
-
- ]]>
- </script>
- </select>
- <select1 id="combo2" ref="/root/main_cnst/cnstinfo/cnstdetlinfo/relign" class="combo_default" appearance="minimal" style="left:845px; top:258px; width:120px; height:19px; ">
- <choices>
- <itemset nodeset="/root/init/mlist/M0538">
- <label ref="cdnm"/>
- <value ref="cdid"/>
- </itemset>
- </choices>
- </select1>
- <caption id="caption23" class="cell_1" style="left:755px; top:492px; width:88px; height:24px; vertical-align:middle; ">방문자</caption>
- <line id="line15" class="line_2" style="x1:755px; y1:387px; x2:1184px; y2:387px; "/>
- <select1 id="combo3" ref="/root/main_cnst/cnstinfo/cnstdetlinfo/visitrid" class="combo_default" appearance="minimal" style="left:845px; top:494px; width:120px; height:19px; ">
- <choices>
- <itemset nodeset="/root/init/userinfo/userlist">
- <label ref="usernm"/>
- <value ref="userid"/>
- </itemset>
- </choices>
- </select1>
- <line id="line16" class="line_2" style="x1:755px; y1:544px; x2:1184px; y2:544px; "/>
- <select id="chk_cnstkind" ref="/root/main_cnst/cnstinfo/cnstdetlinfo/cnstkind" overflow="visible" appearance="full" cellspacing="10" cols="3" sep="▦" style="left:845px; top:287px; width:165px; height:18px; border-style:none; ">
- <choices>
- <itemset nodeset="/root/init/mlist/M0539">
- <label ref="cdnm"/>
- <value ref="cdid"/>
- </itemset>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
-
- ]]>
- </script>
- </select>
- <caption id="caption13" class="cell_1" style="left:755px; top:311px; width:88px; height:24px; vertical-align:middle; ">상담형태</caption>
- <caption id="caption14" class="cell_1" style="left:967px; top:202px; width:77px; height:24px; vertical-align:middle; ">상담자</caption>
- <caption id="caption15" class="cell_1" style="left:755px; top:465px; width:88px; height:24px; vertical-align:middle; ">지역사회 의뢰</caption>
- <select id="chk_cnstpath" ref="/root/main_cnst/cnstinfo/cnstdetlinfo/cnstpath" overflow="visible" appearance="full" cellspacing="10" cols="3" sep="▦" style="left:845px; top:233px; width:160px; height:18px; border-style:none; ">
- <choices>
- <itemset nodeset="/root/init/mlist/M0537">
- <label ref="cdnm"/>
- <value ref="cdid"/>
- </itemset>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
-
- ]]>
- </script>
- </select>
- <line id="line29" class="line_1" style="x1:672px; y1:198px; x2:752px; y2:198px; "/>
- <datagrid id="grd_cnstddlist" nodeset="/root/main_cnst/patmngtinfo/cnstddlist" class="datagrid2" allowselection="false" caption="상담일^처방적용일" colsep="^" colwidth="82" extendlastcol="scroll" mergecellsfixedrows="bycolrec" rowsep="|" style="left:672px; top:203px; width:80px; height:426px; ">
- <col ref="cnstdd" format="yyyy/mm/dd" style="text-align:center; "/>
- <script type="javascript" ev:event="ondblclick">
- <![CDATA[
- if( isDataCell()) {
- fGetPatCnstInfo();
- }
- ]]>
- </script>
- <script type="javascript" ev:event="onmousedown">
- <![CDATA[
- fShowPopupMenu("grd_cnstddlist","/root/main_cnst/popupmenu/patcnst/item");
- ]]>
- </script>
- <script type="javascript" ev:event="DOMFocusOut">
- <![CDATA[
- window.setPopupMenu(false);
- ]]>
- </script>
- </datagrid>
- <line id="line18" class="line_2" style="x1:755px; y1:517px; x2:1184px; y2:517px; "/>
- <line id="line19" class="line_1" style="x1:755px; y1:198px; x2:1186px; y2:198px; "/>
- <caption id="caption16" class="cell_1" style="left:755px; top:338px; width:88px; height:48px; vertical-align:middle; ">상담내용</caption>
- <input id="input17" ref="/root/main_cnst/cnstinfo/cnstdetlinfo/cnstdd" class="input" inputtype="date" style="left:845px; top:205px; width:120px; height:19px; "/>
- <select id="chk_cnstcntsflag" ref="/root/main_cnst/cnstinfo/cnstdetlinfo/cnstcntsflag" overflow="visible" appearance="full" cellspacing="10" cols="3" sep="▦" vcellspacing="7" style="left:845px; top:339px; width:255px; height:43px; border-style:none; ">
- <choices>
- <itemset nodeset="/root/init/mlist/M0541">
- <label ref="cdnm"/>
- <value ref="cdid"/>
- </itemset>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
-
- ]]>
- </script>
- </select>
- <caption id="caption8" class="cell_1" style="left:755px; top:284px; width:88px; height:24px; vertical-align:middle; ">상담종류</caption>
- <caption id="caption9" class="cell_1" style="left:755px; top:230px; width:88px; height:24px; vertical-align:middle; ">상담경위</caption>
- <caption id="caption176" class="tit_2" style="left:673px; top:182px; width:89px; height:13px; ">기록정보</caption>
- <textarea id="textarea3" ref="/root/main_cnst/cnstinfo/cnstdetlinfo/visitrem" class="input" scroll="autovscroll" maxlength="500" style="left:845px; top:547px; width:340px; height:81px; "/>
- <textarea id="tar_trgteconspec" ref="/root/main_cnst/cnstinfo/cnstdetlinfo/cnstrem" class="input" scroll="autovscroll" maxlength="500" style="left:845px; top:389px; width:340px; height:73px; "/>
- <select id="chk_cnsttype" ref="/root/main_cnst/cnstinfo/cnstdetlinfo/cnsttype" overflow="visible" appearance="full" cellspacing="10" cols="3" sep="▦" style="left:845px; top:313px; width:170px; height:18px; border-style:none; ">
- <choices>
- <itemset nodeset="/root/init/mlist/M0540">
- <label ref="cdnm"/>
- <value ref="cdid"/>
- </itemset>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
-
- ]]>
- </script>
- </select>
- <caption id="caption19" class="cell_1" style="left:755px; top:389px; width:88px; height:73px; vertical-align:middle; ">Remark</caption>
- <line id="line7" class="line_2" style="x1:756px; y1:336px; x2:1185px; y2:336px; "/>
- <line id="line17" class="line_3" style="x1:672px; y1:630px; x2:1187px; y2:630px; "/>
- <group id="group4" style="left:672px; top:28px; width:515px; height:145px; ">
- <output id="output4" ref="/root/main_cnst/patmngtinfo/patmngtdetlinfo/sexage" class="output_fix" appearance="output" style="left:408px; top:0px; width:106px; height:19px; text-align:center; "/>
- <button id="button1" class="icon_search" disabled="false" style="left:160px; top:1px; width:16px; height:16px; ">
- <caption/>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- modal("../../../pam/commonweb/xrw/SPPMC02500", "1","150", "150", "SPPMC02500", "/root/source", "/root/main/cond");
-
- //상담환자상세내역, 상담일자 리스트 조회
- model.removeNodeset("/root/send");
- model.makeValue("/root/send/srchflag", "Y");
-
- model.makeValue("/root/send/pid", model.getValue("/root/main/patinfo/patinfolist/pid"));
- model.makeValue("/root/send/rgstdd", getCurrentDate());
-
- if(submit("TRMNC00104")){
- if(model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/existyn") != "Y"){ //상담환자대상자로 등록되지 않은 경우
- //환자번호 copy
- var popupendflag = model.getValue("/root/main/popupendflag");
- if (popupendflag == "ok"){
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/pid", model.getValue("/root/main/patinfo/patinfolist/pid"));
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/patnm", model.getValue("/root/main/patinfo/patinfolist/hngnm"));
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/sexage", model.getValue("/root/main/patinfo/patinfolist/sex") + "/" + model.getValue("/root/main/patinfo/patinfolist/age"));
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstno", model.getValue("/root/main/patinfo/patinfolist/rrgstno1") + "-" + model.getValue("/root/main/patinfo/patinfolist/rrgstno2"));
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/hometel", model.getValue("/root/main/patinfo/patinfolist/hometel"));
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/mpphontel", model.getValue("/root/main/patinfo/patinfolist/mpphontel"));
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/addr", model.getValue("/root/main/patinfo/patinfolist/addr") + " " + model.getValue("/root/main/patinfo/patinfolist/detladdr"));
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstdd", getCurrentDate());
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtflag", "1");
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtenddd", "");
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtrem", "");
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/status", "I");
- } else {
- model.makeNode("/root/main_cnst/patmngtinfo/patmngtdetlinfo");
- model.copyNode("/root/main_cnst/patmngtinfo/patmngtdetlinfo", "/root/init/patmngtdetlinfo");
- }
- }else{
- var pid = model.getValue("/root/main/patinfo/patinfolist/pid");
-
- for(i = 1; i <= getNodesetCount("/root/main_cnst/cnstpatinfo/cnstpatlist/pid"); i++) {
- if(model.getValue("/root/main_cnst/cnstpatinfo/cnstpatlist[" + i + "]/pid") == pid){
- grd_cnstpatlist.row = i;
- grd_cnstpatlist.topRow = i;
- }
- }
- }
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstflag", "H");
- model.refresh();
- }
- // model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstflag", "H");
- setGlobalVariable("paminfo", ""); //원무정보 reset
- ]]>
- </script>
- </button>
- <caption id="caption1" class="cell_1" style="left:0px; top:23px; width:65px; height:21px; vertical-align:middle; ">주민번호</caption>
- <line id="line13" class="line_3" style="x1:0px; y1:140px; x2:514px; y2:140px; "/>
- <caption id="caption180" class="cell_1" style="left:0px; top:0px; width:65px; height:21px; vertical-align:middle; ">등록번호</caption>
- <caption id="caption3" class="cell_1" style="left:351px; top:71px; width:55px; height:21px; vertical-align:middle; ">종료일</caption>
- <caption id="caption4" class="cell_1" style="left:177px; top:23px; width:70px; height:21px; vertical-align:middle; ">집전화번호</caption>
- <caption id="caption24" class="cell_1" style="left:351px; top:0px; width:55px; height:21px; vertical-align:middle; ">S/A</caption>
- <caption id="caption5" class="cell_1" style="left:351px; top:23px; width:55px; height:21px; vertical-align:middle; ">휴대전화</caption>
- <input id="opt_valitrgtpid" ref="/root/main_cnst/patmngtinfo/patmngtdetlinfo/patnm" disabled="true" style="left:249px; top:0px; width:100px; height:19px; text-align:center; "/>
- <caption id="caption173" class="cell_1" style="left:0px; top:95px; width:65px; height:43px; vertical-align:middle; ">비고</caption>
- <input id="input1" ref="/root/main_cnst/patmngtinfo/patmngtdetlinfo/mpphontel" class="output_fix" style="left:408px; top:24px; width:106px; height:19px; text-align:center; "/>
- <select1 id="combo5" ref="/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtflag" class="combo_default" appearance="minimal" style="left:249px; top:72px; width:100px; height:19px; ">
- <choices>
- <item>
- <label>관리중</label>
- <value>1</value>
- </item>
- <item>
- <label>관리종료</label>
- <value>2</value>
- </item>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- if(model.getValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtflag") == "2"){
- ipt_mngtenddd.disabled = false;
- model.setValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtenddd", getCurrentDate());
- }else{
- ipt_mngtenddd.disabled = true;
- model.setValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtenddd", "");
- }
- ipt_mngtenddd.refresh();
- ]]>
- </script>
- </select1>
- <line id="line3" class="line_2" style="x1:0px; y1:21px; x2:514px; y2:21px; "/>
- <caption id="caption7" class="cell_1" style="left:0px; top:47px; width:65px; height:21px; vertical-align:middle; ">주소</caption>
- <input id="input2" ref="/root/main_cnst/patmngtinfo/patmngtdetlinfo/hometel" class="output_fix" style="left:249px; top:24px; width:100px; height:19px; text-align:center; "/>
- <caption id="caption175" class="cell_1" style="left:177px; top:0px; width:70px; height:21px; vertical-align:middle; ">환자명</caption>
- <output id="opt_trgtpid" ref="/root/main_cnst/patmngtinfo/patmngtdetlinfo/pid" class="output_fix" appearance="output" style="left:66px; top:0px; width:87px; height:19px; text-align:center; "/>
- <line id="line4" class="line_2" style="x1:0px; y1:45px; x2:514px; y2:45px; "/>
- <input id="input3" ref="/root/main_cnst/patmngtinfo/patmngtdetlinfo/addr" class="output_fix" style="left:66px; top:48px; width:448px; height:19px; text-align:left; "/>
- <caption id="caption17" class="cell_1" style="left:177px; top:70px; width:70px; height:21px; vertical-align:middle; ">관리구분</caption>
- <textarea id="textarea2" ref="/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtrem" class="input" scroll="autovscroll" maxlength="500" style="left:66px; top:95px; width:448px; height:43px; "/>
- <caption id="caption18" class="cell_1" style="left:0px; top:71px; width:65px; height:21px; vertical-align:middle; ">등록일</caption>
- <line id="line5" class="line_2" style="x1:0px; y1:69px; x2:514px; y2:69px; "/>
- <output id="output2" ref="/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstno" class="output_fix" appearance="output" style="left:66px; top:24px; width:109px; height:19px; text-align:center; "/>
- <line id="line6" class="line_2" style="x1:0px; y1:93px; x2:514px; y2:93px; "/>
- <input id="ipt_mngtenddd" ref="/root/main_cnst/patmngtinfo/patmngtdetlinfo/mngtenddd" class="input" disabled="true" inputtype="date" style="left:408px; top:72px; width:106px; height:19px; "/>
- <output id="output3" ref="/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstdd" class="output_fix" format="yyyy/mm/dd" appearance="output" style="left:66px; top:72px; width:109px; height:19px; text-align:center; "/>
- </group>
- <button id="button3" class="btn2_letter2" style="left:1067px; top:2px; width:42px; height:19px; ">
- <caption>신규</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- model.resetInstanceNode("/root/main_cnst/patmngtinfo/patmngtdetlinfo");
- rdo_rgstflag.disabled = false;
- model.makeValue("/root/main_cnst/patmngtinfo/patmngtdetlinfo/rgstflag", "");
- model.setValue("/root/main_cnst/cnstinfo/cnstdetlinfo/cnstcntsflag", getCurrentDate());
- model.refresh();
- ]]>
- </script>
- </button>
- <select1 id="chk_local" ref="/root/main_cnst/cnstinfo/cnstdetlinfo/localcnst" visibility="hidden" appearance="full" cellspacing="10" cols="2" overflow="visible" style="left:970px; top:495px; width:100px; height:19px; border-style:none; ">
- <choices>
- <itemset nodeset="/root/init/mlist/M0549">
- <label ref="cdnm"/>
- <value ref="cdid"/>
- </itemset>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- var localcnst = model.getValue("/root/main_cnst/cnstinfo/cnstdetlinfo/localcnst");
- if (!isNull(localcnst)) {
- ipt_areacnst.disabled = false;
- }else{
- ipt_areacnst.disabled = true;
- }
- ]]>
- </script>
- </select1>
- <select id="checkbox1" ref="/root/main_cnst/cnstinfo/cnstdetlinfo/localcnst" overflow="visible" appearance="full" cols="2" style="left:849px; top:468px; width:100px; height:20px; border-style:none; ">
- <choices>
- <itemset nodeset="/root/init/mlist/M0549">
- <label ref="cdnm"/>
- <value ref="cdid"/>
- </itemset>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- var localcnst = model.getValue("/root/main_cnst/cnstinfo/cnstdetlinfo/localcnst");
- if (!isNull(localcnst)) {
- ipt_areacnst.disabled = false;
- }else{
- ipt_areacnst.disabled = true;
- model.setValue("/root/main_cnst/cnstinfo/cnstdetlinfo/areacnstfact","");
- }
- model.refresh();
- ]]>
- </script>
- </select>
- </case>
- </switch>
- <group id="group2" style="left:1px; top:10px; width:1194px; height:65px; vertical-align:top; ">
- <shape id="roundrect1" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:0px; width:1194px; height:65px; background-color:#fffbf2; border-color:#ffd799; "/>
- <button id="btn_ref" class="btn1_letter2" style="left:986px; top:23px; width:56px; height:22px; ">
- <caption>조회</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- fInqurySelectedPrgm();
- ]]>
- </script>
- </button>
- <caption id="caption12" class="search_name" style="left:15px; top:11px; width:90px; height:17px; ">업무일자 :</caption>
- <input id="ipt_orddd" ref="/root/main/cond/orddd" class="input_s_essential" inputtype="date" style="left:110px; top:10px; width:105px; height:19px; ">
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- fInqurySelectedPrgm();
- ]]>
- </script>
- </input>
- <select1 id="rdo_indschacptstat" ref="/root/main/cond/indschacptstat" class="radio_search" appearance="full" cellspacing="5" cols="4" overflow="visible" style="left:110px; top:40px; width:217px; height:18px; border-style:none; ">
- <choices>
- <item>
- <label>재원</label>
- <value>1</value>
- </item>
- <item>
- <label>입원</label>
- <value>2</value>
- </item>
- <item>
- <label>퇴원진행</label>
- <value>3</value>
- </item>
- <item>
- <label>퇴원</label>
- <value>4</value>
- </item>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- if(model.getValue("/root/main/cond/indschacptstat") == "3" || model.getValue("/root/main/cond/indschacptstat") =="4") {
- button6.visible = true;
- } else{
- button6.visible = false;
- }
- fInqurySelectedPrgm();
- ]]>
- </script>
- </select1>
- <caption id="caption54" class="search_name" style="left:435px; top:40px; width:93px; height:17px; ">등록번호 :</caption>
- <input id="input5" ref="/root/main/cond/pid" class="input_search" maxlength="10" style="left:527px; top:39px; width:90px; height:19px; ">
- <script type="javascript" ev:event="onkeypress">
- <![CDATA[
- if(event.keycode == "13"){
- model.setFocus("btn_ref");
- delPatientInfos(); //화면상단정보 삭제
- setGlobalVariable("paminfo", ""); //원무정보 reset
- fInqurySelectedPrgm();
-
- //model.setValue("/root/main/cond/patnm", model.getValue("/root/main_nm/wardpatinfo/wardpatlist[pid = '" + model.getValue("/root/main/cond/pid") + "']/patnm"));
- //model.setValue("/root/main/cond/sexage", model.getValue("/root/main_nm/wardpatinfo/wardpatlist[pid = '" + model.getValue("/root/main/cond/pid") + "']/sexage"));
- //model.setValue("/root/main/cond/orddeptnm", model.getValue("/root/main_nm/wardpatinfo/wardpatlist[pid = '" + model.getValue("/root/main/cond/pid") + "']/orddeptnm"));
- //model.refresh();
- }
- ]]>
- </script>
- </input>
- <line id="line25" class="line_4" style="x1:966px; y1:15px; x2:966px; y2:52px; border-color:#ffe4bb; border-left-style:solid; "/>
- <button id="button4" class="icon_search" disabled="false" style="left:624px; top:41px; width:16px; height:16px; ">
- <caption/>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- modal("../../../pam/commonweb/xrw/SPPMC02500", "1","150", "150", "SPPMC02500", "/root/source", "/root/main/cond");
-
- //환자번호 copy
- var popupendflag = model.getValue("/root/main/popupendflag");
- if (popupendflag == "ok"){
- model.setValue("/root/main/cond/pid", model.getValue("/root/main/patinfo/patinfolist/pid"));
- //model.setValue("/root/main/cond/patnm", model.getValue("/root/main/patinfo/patinfolist/hngnm"));
- //model.setValue("/root/main/cond/sexage", model.getValue("/root/main/patinfo/patinfolist/sex") + "/" + model.getValue("/root/main/patinfo/patinfolist/age"));
- //model.setValue("/root/main/cond/orddeptnm", model.getValue("/root/main/patinfo/patinfolist/hngnm"));
- model.refresh();
- }
-
- delPatientInfos(); //화면상단정보 삭제
- setGlobalVariable("paminfo", ""); //원무정보 reset
-
- fInqurySelectedPrgm();
-
- ]]>
- </script>
- </button>
- <button id="btn_excel" class="btn1_letter2" style="left:1049px; top:23px; width:56px; height:22px; ">
- <caption>엑셀</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- var fileName = window.fileDialog("save", ",", false, "excel", "xls", "Excel Files(*.xls)|*.xls|All Files (*.*)|*.*");
- if (fileName != "") {
- var selectindex = swt_main.selectedIndex;
- switch(selectindex) {
- case 0: // nm
- grd_wardpatlist.saveExcel(fileName, "SheetName", true, true, "", "", true);
- break;
- case 1: // om
- grd_omprcplist.saveExcel(fileName, "SheetName", true, true, "", "", true);
- break;
- case 2: // cm
- grd_cnstpatlist.saveExcel(fileName, "SheetName", true, true, "", "", true);
- break;
- default :
- messageBox("엑셀로 저장할 수 있는 리스트가 선택되지", "E007");
- }
- }
- ]]>
- </script>
- </button>
- <button id="btn_print" class="btn1_letter2" style="left:1112px; top:23px; width:56px; height:22px; ">
- <caption>출력</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- model.removeNodeset("/root/send");
- model.makeNode("/root/send");
- var flag = swt_main.selectedIndex; //nm:0, om:1, cm:2
- if (flag == 0) { // nm
- //send 재구성
- model.makeNode("/root/send/ipatgroup");
- model.makeNode("/root/send/ipatgroup/ipat");
- model.makeValue("/root/send/ipatgroup/ipat/wardnm", getUserInfo("dutplcenm"));
- model.makeValue("/root/send/ipatgroup/ipat/total", grd_wardpatlist.rows-1);
- model.makeValue("/root/send/ipatgroup/ipat/orddd", model.getValue("/root/main/cond/orddd"));
-
- var indschacptstat = model.getValue("/root/main/cond/indschacptstat");
- switch(indschacptstat){
- case "1":
- model.makeValue("/root/send/ipatgroup/ipat/indschacptstat", "재원");
- break;
- case "2":
- model.makeValue("/root/send/ipatgroup/ipat/indschacptstat", "입원");
- break;
- case "3":
- model.makeValue("/root/send/ipatgroup/ipat/indschacptstat", "퇴원진행");
- break;
- case "4":
- model.makeValue("/root/send/ipatgroup/ipat/indschacptstat", "퇴원");
- break;
- }
- /*
- for( var i=1; i <grd_wardpatlist.rows; i++ ) {
- var endflag = model.getValue("/root/main_nm/wardpatinfo/wardpatlist[" + i + "]/endflag");
- var endflagnm = "";
- if(endflag == "1"){
- endflagnm = "수료";
- }else if(endflag == "2"){
- endflagnm = "자퇴";
- }else if(endflag == "3"){
- endflagnm = "중퇴";
- }else if(endflag == "4"){
- endflagnm = "재수료";
- }else{
- endflagnm = "";
- }
- model.makeValue("/root/main_nm/wardpatinfo/wardpatlist[" + i + "]/endflagnm", endflagnm);
- }
- */
- //list
- model.makeNode("/root/send/ipatgroup/ipatlistinfo/ipatlist");
- model.copyNode("/root/send/ipatgroup/ipatlistinfo", "/root/main_nm/wardpatinfo");
- exeReportPreview("RPMNC00100", "XMLSTR");
-
- } else if (flag == 1) { // om
- if (model.getValue("/root/main_om/ominfo/prcpinfo/prcplist/flag") != "") {
- model.makeNode("/root/send/ompatgroup");
- model.makeNode("/root/send/ompatgroup/ompat");
- model.copyNode("/root/send/ompatgroup/ompat", "/root/main_om/ominfo/ompatinfo/ompatlist[pid = '" + model.getValue("/root/main_om/cond/pid") + "']");
-
- model.makeNode("/root/send/ompatgroup/cnfmprcpdd");
- var cnfm_color = grd_prcpappddlist.allStyle("all", "background-color");
- var uncnfm_color = grd_uncnfmprcpddlist.allStyle("all", "background-color");
- var prcpheader = "";
- var prcpdd = grd_omprcplist.labelMatrix((grd_omprcplist.rows-1), 24);
-
- if (cnfm_color != "#ffffff") {
- prcpheader = "처방적용일 : ";
-
- } else if (uncnfm_color != "#ffffff") {
- prcpheader = "미확인처방일 : ";
- }
- prcpdd = prcpheader.concat(prcpdd);
- model.makeValue("/root/send/ompatgroup/cnfmprcpdd/cnfmprcpdd", prcpdd);
- model.makeNode("/root/send/ompatgroup/prcplistinfo");
- model.copyNode("/root/send/ompatgroup/prcplistinfo", "/root/main_om/ominfo/prcpinfo");
-
- exeReportPreview("RPMNW00300", "XMLSTR");
-
- } else {
- messageBox("처방을 조회 후 출력하십시오", "I");
- }
- } else { // cm
- model.makeNode("/root/send/cnstpatgroup");
- model.makeNode("/root/send/cnstpatgroup/cnstpat");
- model.makeValue("/root/send/cnstpatgroup/cnstpat/total", grd_cnstpatlist.rows-1);
- model.makeValue("/root/send/cnstpatgroup/cnstpat/orddd", model.getValue("/root/main/cond/orddd"));
- model.makeValue("/root/send/cnstpatgroup/cnstpat/to_orddd", model.getValue("/root/main/cond/to_orddd"));
-
- //list
- model.makeNode("/root/send/cnstpatgroup/cnstpatlistinfo/cnstpatlist");
- model.copyNode("/root/send/cnstpatgroup/cnstpatlistinfo", "/root/main_cnst/cnstpatinfo");
- exeReportPreview("RPMNC00101", "XMLSTR");
- }
- ]]>
- </script>
- </button>
- <caption id="cap_condstat" class="search_name" style="left:15px; top:40px; width:90px; height:17px; ">재원상태 :</caption>
- <select1 id="rdo_mngtstat" ref="/root/main/cond/mngtstat" class="radio_search" visibility="hidden" appearance="full" cellspacing="5" cols="3" overflow="visible" style="left:355px; top:15px; width:202px; height:18px; border-style:none; ">
- <choices>
- <item>
- <label>관리중</label>
- <value>1</value>
- </item>
- <item>
- <label>관리종료</label>
- <value>2</value>
- </item>
- <item>
- <label>당일등록</label>
- <value>3</value>
- </item>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- fInqurySelectedPrgm();
- ]]>
- </script>
- </select1>
- <output id="opt_sa" ref="/root/main/cond/sexage" class="output_search" visibility="hidden" style="left:737px; top:39px; width:50px; height:19px; "/>
- <output id="opt_patnm" ref="/root/main/cond/patnm" class="output_search" visibility="hidden" style="left:644px; top:39px; width:90px; height:19px; "/>
- <input id="ipt_to_orddd" ref="/root/main/cond/to_orddd" class="input_s_essential" visibility="hidden" inputtype="date" style="left:235px; top:10px; width:105px; height:19px; ">
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- fInqurySelectedPrgm();
- ]]>
- </script>
- </input>
- <caption id="cap_from" visibility="hidden" style="left:219px; top:10px; width:15px; height:19px; ">~</caption>
- <output id="opt_orddeptnm" ref="/root/main/cond/orddeptnm" class="output_search" visibility="hidden" style="left:790px; top:39px; width:100px; height:19px; "/>
- </group>
- <button id="button6" class="btn5_letter2" visibility="hidden" style="left:1117px; top:84px; width:42px; height:19px; ">
- <caption>저장</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- fSaveOutRm();
- ]]>
- </script>
- </button>
- </group>
- <group id="grp_btn" scroll="auto" style="left:0px; top:757px; width:1195px; height:27px; ">
- <shape id="sha_state" visibility="hidden" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:7px; top:3px; width:593px; height:20px; background-color:#fffbf2; border-color:#7cbbdd; "/>
- <caption id="cap_state" visibility="hidden" style="left:12px; top:4px; width:588px; height:20px; ">상태 ⓐ:입원 ⓞ:외출/외박 ⓓ:퇴원예고 ⓒ:간호사퇴원정리완료 ⓘ:심사중 ⓕ:심사완료 (+):전실옴 (-):전실감</caption>
- <caption id="cap_color" class="color_6" visibility="hidden" style="left:820px; top:5px; width:15px; height:15px; background-color:#ffcccc; "/>
- <caption id="cap_uncnfm" visibility="hidden" style="left:840px; top:4px; width:38px; height:20px; ">미확인</caption>
- <group id="group5" visibility="hidden" style="left:1024px; top:2px; width:165px; height:21px; ">
- <caption id="caption26" class="cell_1" style="left:0px; top:1px; width:55px; height:20px; ">이용자 :</caption>
- <button id="button8" class="btn5_letter2" style="left:121px; top:0px; width:42px; height:19px; ">
- <caption>저장</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
-
- model.removeNodeset("/root/send");
- model.makeNode("/root/send");
- model.makeValue("/root/send/status", "I");
- model.makeValue("/root/send/pid", "-");
- model.makeValue("/root/send/rgstflag", "P");
-
- model.makeValue("/root/send/rgstdd", model.getValue("/root/main/cond/to_orddd"));
- model.makeValue("/root/send/patcnt", model.getValue("/root/main_cnst/cnstpatinfo/patcntinfo/patcnt"));
- model.makeValue("/root/send/patcntyn", "Y"); //이용자수저장
- if(submit("TXMNC00101")){
- fInqurySelectedPrgm(); //일반상담리스트 조회
- }
- model.makeValue("/root/send/patcntyn", "N");
- ]]>
- </script>
- </button>
- <caption id="caption27" class="cell_1" style="left:95px; top:1px; width:20px; height:20px; ">명</caption>
- <input id="input6" ref="/root/main_cnst/cnstpatinfo/patcntinfo/patcnt" maxlength="4" format="9999" style="left:55px; top:1px; width:40px; height:19px; "/>
- </group>
- </group>
- </xhtml:body>
- </xhtml:html>
|