123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509 |
- <?xml version="1.0" encoding="EUC-KR"?>
- <?xml-stylesheet type="text/css" href="../../../com/commonweb/css/common.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>
- <srchrslt>
- <data>
- <check/>
- <h_patflag/>
- <h_prcpdd/>
- <h_cretno/>
- <h_prcpgenrflag/>
- <h_orddd/>
- <replyn/>
- <ward/>
- <room/>
- <h_wardroom/>
- <pid/>
- <hngnm/>
- <sex/>
- <age/>
- <h_diagcd/>
- <diagnm/>
- <orddept/>
- <orddrid/>
- <atdoct/>
- <dietnm/>
- <h_ht/>
- <h_wt/>
- <wlpnt/>
- <bmipnt/>
- <appnt/>
- <gipnt/>
- <stpnt/>
- <atpnt/>
- <dtpnt/>
- <agepnt/>
- <totalpnt/>
- <srchrslt/>
- <bfrslt/>
- <bfrsltdd/>
- <trf/>
- <insrslt/>
- <nutrmngtkind/>
- <execdd/>
- <indd/>
- </data>
- <count>
- <good/>
- <low/>
- <mid/>
- <high/>
- <non/>
- <total/>
- </count>
- </srchrslt>
- <pastsrchrslt>
- <data>
- <check/>
- <signyn/>
- <replyn/>
- <prcpdd/>
- <cretno/>
- <prcpgenrflag/>
- <orddept/>
- <orddrid/>
- <atdoct/>
- <dietnm/>
- <bfrslt/>
- <bfrsltdd/>
- <srchdd/>
- <patflag/>
- <orddd/>
- <indd/>
- <ward/>
- <room/>
- <h_wardroom/>
- <pid/>
- <hngnm/>
- <sex/>
- <age/>
- <diagnm/>
- <wlpnt/>
- <bmipnt/>
- <appnt/>
- <gipnt/>
- <stpnt/>
- <atpnt/>
- <dtpnt/>
- <agepnt/>
- <totalpnt/>
- <srchrslt/>
- <trf/>
- <insrslt/>
- <rem/>
- <h_signno/>
- </data>
- <count>
- <good/>
- <low/>
- <mid/>
- <high/>
- <non/>
- <total/>
- </count>
- </pastsrchrslt>
- <srchstats>
- <data>
- <srchdd/>
- <good1/>
- <low1/>
- <mid1/>
- <high1/>
- <non1/>
- <total1/>
- <good2/>
- <low2/>
- <mid2/>
- <high2/>
- <non2/>
- <total2/>
- </data>
- </srchstats>
- <nutrjudgbase>
- <data>
- <cd/>
- <dngrcd/>
- <min/>
- <max/>
- </data>
- </nutrjudgbase>
- </main>
- <send>
- <searchitem>
- <basedd/>
- <patflag/>
- <orddept/>
- <ward/>
- <dngrflag/>
- <optward/>
- </searchitem>
- <pastsearchitem>
- <fromdd/>
- <todd/>
- <patflag/>
- <ward/>
- <dngrflag/>
- </pastsearchitem>
- <statssearchitem>
- <fromdd/>
- <todd/>
- <patflag/>
- <orddept/>
- <ward/>
- <dngrflag/>
- </statssearchitem>
- <data>
- <list/>
- <pastlist/>
- <signdata/>
- <careplan>
- <listdata/>
- </careplan>
- </data>
- <popup>
- <flag/>
- <flag2/>
- <pid/>
- <hngnm/>
- <reqdd/>
- <reqpsn/>
- <orddrid/>
- <educreqcnts/>
- <h_cretno/>
- <h_orddeptcd/>
- <h_prcpgenrflag/>
- <h_orddd/>
- <h_formrecseq/>
- <execprcpuniqno/>
- <nutrmngtkind/>
- <execdd/>
- <srchdd/>
- </popup>
- </send>
- <temp>
- <count>
- <cnt/>
- </count>
- <patflagyn/>
- <nutrsrchrsltlist>
- <nutrsrchrslt/>
- </nutrsrchrsltlist>
- <singrslt>
- <signno/>
- <histno/>
- </singrslt>
- </temp>
- <init>
- <basecode>
- <dngr>
- <A0058>
- <cdid/>
- <cdnm/>
- </A0058>
- </dngr>
- <orddept>
- <dept>
- <deptcd/>
- <depthngnm/>
- </dept>
- </orddept>
- <ward>
- <dept>
- <deptcd/>
- <depthngnm/>
- </dept>
- </ward>
- <dngrcopy>
- <A0058>
- <cdid/>
- <cdnm/>
- </A0058>
- </dngrcopy>
- </basecode>
- </init>
- </root>
- </instance>
- <submission id="TRZBC00101"/>
- <submission id="TRZSD00109" mediatype="application/x-www-form-urlencoded" method="post" replace="instance"/>
- <submission id="TRANC00102" mediatype="application/x-www-form-urlencoded" method="post" resultref="/root/main/nutrjudgbase"/>
- <submission id="TRANC00103" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/searchitem" resultref="/root/temp"/>
- <submission id="TXANC00151" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/data" resultref="/root/temp"/>
- <submission id="TRANC00157" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/statssearchitem" resultref="/root/main/srchstats"/>
- <script type="javascript" ev:event="xforms-ready">
- <![CDATA[
- finit();
- btn_search1.disabled = !checkAuth("R");
- btn_search2.disabled = !checkAuth("R");
- btn_search3.disabled = !checkAuth("R");
- btn_save.disabled = !checkAuth("X");
- btn_excel1.disabled = !checkAuth("P");
- btn_excel2.disabled = !checkAuth("P");
- btn_excel3.disabled = !checkAuth("P");
- grd_nutrsrch.fixedcellcheckbox(0,1) = true; //영양검색 탭화면 전체선택 체크박스 설정
- grd_pastnutrsrch.fixedcellcheckbox(0,1) = true; //영양검색결과 탭화면 전체선택 체크박스 설정
- ]]>
- </script>
- <script type="javascript">
- <![CDATA[
-
- var sColSep = "▦"; // 열 구분 값
- var sRowSep = "▩"; // 행 구분 값
- var rCSV2 = ""; // 서버로 전송할 서식인증 데이터 변수
- var rCSV3 = ""; // Care Plan 데이터 변수
-
- /*
- * 환자별 서식 데이터 인증후 테이블에 인증번호를 저장
- */
- function fCertSave() {
- rCSV2 = "m▦instcd▦pid▦orddd▦signno▦cretno▦recdd▦rectm▦recsaveflag▦signflag▦signgenrflag▦formcd▦orddeptcd▦orddrid▦histno▦signbfcnts▦signaftcnts▦patflag▦srchdd";
- rCSV3 = "m▦instcd▦careplanseq▦pid▦orddd▦cretno▦workflag▦problem▦careplan▦rgstdd▦rgsttm";
-
- var gridRows = grd_pastnutrsrch.rows; // 검색된 그리드 행의 수
- var gridFixedRows = grd_pastnutrsrch.fixedRows; // 고정된 그리드 행의 수
- var errMessage = "인증 실패 및 Care Plan 전송 실패 데이터 번호: "; // 에러 메시지
- var signErrYn = false; // 서식인증 에러 여부
- var signSucsCnt = 0; // 서식인증 건수
- var sendDataRowCnt = 1; // 전송할 데이터 행의 순번
-
- // 저장 데이터 초기화
- model.removeNodeset("/root/send/data/signdata");
- model.makeNode("/root/send/data/signdata");
-
- var isSelect = true;
- // 데이터 선택 유무 확인
- for(var i = gridFixedRows; i < gridRows; ++i) {
- if(grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("check")) == "true") {
- isSelect = false;
- }
- }
-
- if(isSelect) {
- alert("선택된 데이터가 없습니다.");
- return;
- }
-
- // 서식인증 데이터 생성
- for(var i = gridFixedRows; i < gridRows; ++i) {
- // 서식인증 데이터 초기화
- model.removeNodeset("/root/temp/nutrsrchrsltlist/nutrsrchrslt");
- model.makeNode("/root/temp/nutrsrchrsltlist/nutrsrchrslt");
-
- // 체크 된건중에서 서식인증이 안된 건만 처리
- if(grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("check")) == "true" && grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("signyn")) != "Y") {
- // 비고란에 데이터가 없는 건만 서식인증 데이터 세팅 && 검색결과가 '9' : '판정불가' 가 아닌건만 세팅
- if(grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("rem")) == "" && grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("srchrslt")) != "9") {
-
- // 전자서명 인증 여부
- if(model.getValue("/root/send/pastsearchitem/patflag") == "F") {
- model.makeValue("/root/temp/nutrsrchrsltlist/nutrsrchrslt/inityn" , "(초기)");
- } else {
- model.makeValue("/root/temp/nutrsrchrsltlist/nutrsrchrslt/inityn" , "");
- }
-
- model.makeValue("/root/temp/nutrsrchrsltlist/nutrsrchrslt/pid" , grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("pid")));
- model.makeValue("/root/temp/nutrsrchrsltlist/nutrsrchrslt/hngnm" , grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("hngnm")));
- model.makeValue("/root/temp/nutrsrchrsltlist/nutrsrchrslt/wlpnt" , grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("wlpnt")));
- model.makeValue("/root/temp/nutrsrchrsltlist/nutrsrchrslt/bmipnt" , grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("bmipnt")));
- model.makeValue("/root/temp/nutrsrchrsltlist/nutrsrchrslt/appnt" , grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("appnt")));
- model.makeValue("/root/temp/nutrsrchrsltlist/nutrsrchrslt/gipnt" , grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("gipnt")));
- model.makeValue("/root/temp/nutrsrchrsltlist/nutrsrchrslt/stpnt" , grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("stpnt")));
- model.makeValue("/root/temp/nutrsrchrsltlist/nutrsrchrslt/atpnt" , grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("atpnt")));
- model.makeValue("/root/temp/nutrsrchrsltlist/nutrsrchrslt/dtpnt" , grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("dtpnt")));
- model.makeValue("/root/temp/nutrsrchrsltlist/nutrsrchrslt/agepnt" , grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("agepnt")));
- model.makeValue("/root/temp/nutrsrchrsltlist/nutrsrchrslt/srchrslt", grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("srchrslt")));
-
- // 서식 인증 처리
- if(fExeMakeCertPrcs(sendDataRowCnt, i)) { // 서식인증 성공
- sendENRCAREPLANData(i); // care plan 전송 데이터 생성
- ++sendDataRowCnt; // sendData 데이터 노드 번호
- ++signSucsCnt; // 서식인증 건수
- } else { // 서식인증 실패
- signErrYn = true;
-
- // 에러 메시지 세팅
- if(i != (gridRows - 1)) {
- errMessage += (i-1) + ", ";
- } else {
- errMessage += (i-1);
- }
- } // end of if-else.
-
- }
- }
- } // end of for-loop.
-
- if(signSucsCnt > 0) {
- // Care Plan 데이터 저장
- if(submit("TXANC00357")) {
- // Care Plan 데이터 저장 성공!!
- } else {
- messageBox("서식 인증 저장 안됨!! Care Plan 전송 처리 오류!! 시스템 담당자에게 문의", "I008");
- return;
- }
-
- // 인증내용 저장
- if (submit("TXANC00153")) {
- btn_search2.dispatch("DOMActivate");
- messageBox("서식 인증 및 Care Plan 데이터 저장이", "I002");
- }
- } else if(signErrYn != true){
- messageBox("고지여부 'Y', 검색 결과에 '판정불가', 비고항목에 입력된 메모가 있으면 서식인증 진행", "E001");
- }
-
- // 에러 메시지 출력
- if(signErrYn) {
- messageBox(errMessage, "");
- }
- }
-
- /*
- * Care Plan 관련 ENR 데이터 전송
- */
- function sendENRCAREPLANData(i) {
- // 재검색, 신환 구분
- var patflag = model.getValue("/root/send/pastsearchitem/patflag");
- // 수행시간을 현재 시간으로 세팅
- var curDt = getCurrentDateTime().split(" ");
- // 그리드 헤더값 생성
- var m = "";
- var instcd = "";
- var careplanseq = "";
- var pid = "";
- var orddd = "";
- var cretno = "";
- var workflag = "";
- var problem = "";
- var careplan = "";
- var rgstdd = "";
- var rgsttm = "";
- var problem = "";
- var careplan = "";
-
- /*
- * Care Plan 데이터 구조
- * "m▦instcd▦careplanseq▦pid▦orddd▦cretno▦workflag▦problem▦careplan▦rgstdd▦rgsttm";
- */
- m = "i";
- instcd = getUserInfo("dutplceinstcd");
- careplanseq = "";
- pid = grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("pid"));
- orddd = grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("orddd"));
- cretno = grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("cretno"));
- workflag = "004"; // 004:영양
- if(grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("srchrslt")) == "2") { // 저위험군
- if(patflag == "F") { // 신환
- problem = "영양 검색 시행(저위험군)";
- careplan = "2주 후 영양 재검색";
- } else if(patflag == "I"){ // 재검색
- problem = "영양 검색 시행(저위험군)";
- careplan = "2주 후 영양 재검색";
- } else {
- problem = "";
- careplan = "";
- }
- } else if(grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("srchrslt")) == "3") { // 중위험군
- if(patflag == "F") { // 신환
- problem = "영양 검색 시행(중위험군)";
- careplan = "2주 후 영양 재검색";
- } else if(patflag == "I"){ // 재검색
- problem = "영양 검색 시행(중위험군)";
- careplan = "2주 후 영양 재검색";
- } else {
- problem = "";
- careplan = "";
- }
- } else if(grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("srchrslt")) == "4") { // 고위험군
- if(patflag == "F") { // 신환
- problem = "영양 검색 시행(고위험군)";
- careplan = "영양 상태 평가 및 관리";
- } else if(patflag == "I"){ // 재검색
- problem = "영양 검색 시행(고위험군)";
- careplan = "영양 상태 평가 및 관리";
- } else {
- problem = "";
- careplan = "";
- }
- } else {
- return false;
- }
-
- rgstdd = curDt[0];
- rgsttm = curDt[1];
-
- rCSV3 +=
- sRowSep +
- m + sColSep +
- instcd + sColSep + // 기관코드
- careplanseq + sColSep + // 케이플랜 데이터 시퀀스
- pid + sColSep + // 등록번호
- orddd + sColSep + // 입원/외래 일자
- cretno + sColSep + // 생성번호
- workflag + sColSep + // 작업구분(001:TREATMENT, 002:DISCHARGE, 003:NURSING CARE, 004:NUTRITION MANAGEMENT, 005:ACTIVITY/REHABILITATION, 999:OTHER CARE)
- problem + sColSep + // 문제
- careplan + sColSep + // 해결방안
- rgstdd + sColSep + // 등록일자
- rgsttm; // 등록시간
-
- // Care Plan 관련 전송 데이터 세팅
- model.makeValue("/root/send/data/careplan/listdata", rCSV3);
-
- return true;
- }
-
- /* **********************************
- * ENRSignEngine.js에서 함수를 호출함
- * ***********************************/
- function fMake_SignData(){
- //Sign.XPATH_MAINNODE = "/root/main";
- Sign.addnode("/root/temp/nutrsrchrsltlist"); // 인증경로로 copynode 함
- }
- /* @group : 결과 인증저장 Interface
- * @ver : 2009.12.07
- * @by : SMAER14000_심혈관센터기록관리.xrw 에서 복사해서 씀
- * @-----------------------------------
- * @type : function
- * @access : public
- * @desc : 결과 인증저장을 위한 Interface 데이터 셋팅 및 반영 Function
- */
- function fExeMakeCertPrcs(i, gridRow) {
- if (Sign.signprocess() == true) {
- // signno가 존재하면 기존 결과에 UPDATE가 되며, "0" 이라면 ADD(누적)되도록 데이터가 생성된다.
- var oldsignno = model.getValue("/root/temp/nutrsrchrsltlist/nutrsrchrslt/signno");
- var formcd = "";
- var recsaveflag = "";
-
- if(oldsignno == ""){
- var oldsignno = "0";
- }
-
- // 성인, 소아의 폼코드 구분
- if(grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("age")) >= 18) {
- formcd = "1000007288"; // 각 기록지별 성인서식코드 (심혈관시술시기록지 : (교육) 1000007124, (운영) 1000007288 )
- } else {
- formcd = "1000007289"; // 각 기록지별 소아서식코드 (심혈관시술시기록지 : (교육) 1000007125, (운영) 1000007289 )
- }
-
- // 전자서명 인적정보 변경여부
- if(grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("signyn")) == "Y") {
- recsaveflag = "Y"; // 전자서명 인적정보 변경여부(기록일시 변경되는 경우 : Y, 그외 : N)
- } else {
- recsaveflag = "N"; // 전자서명 인적정보 변경여부(기록일시 변경되는 경우 : Y, 그외 : N)
- }
-
- // "m▦instcd▦pid▦orddd▦signno▦cretno▦recdd▦rectm▦recsaveflag▦signflag▦signgenrflag▦formcd▦orddeptcd▦orddrid▦histno▦signbfcnts▦signaftcnts▦patflag▦srchdd";
- rCSV2 +=
- sRowSep +
- "i" + sColSep +
- getUserInfo("dutplceinstcd") + sColSep + // 기관코드
- grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("pid")) + sColSep + // 등록번호
- grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("orddd")) + sColSep + // 입원, 응급 : 입원일자, 외래 : 진료일자
- grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("h_signno")) + sColSep + // 서명번호
- grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("cretno")) + sColSep + // 생성번호
- getCurrentDate() + sColSep + // 실제기록이 이루어진 기록일자
- getCurrentTime() + sColSep + // 실제기록이 이루어진 기록시간
- recsaveflag + sColSep + // 전자서명 인적정보 변경여부(기록일시 변경되는 경우 : Y, 그외 : N)
- "04" + sColSep + // 서명자료구분(01 : 진료, 02 : 간호, 03:LIS, 04:진료지원, 20: 가정간호, 30:의료협력)
- grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("prcpgenrflag")) + sColSep + // 입원, 외래구분
- formcd + sColSep + // 각 기록지별 소아서식코드 (심혈관시술시기록지 : (운영) 0900006844)
- grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("orddept")) + sColSep + // 진료부서코드
- grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("orddrid")) + sColSep + // 진료의ID
- "0" + sColSep + // 서명이력번호
- Sign.signedInfos[1] + sColSep + // 인증할 데이터 정보(미기록 노드 제거된 정보), 미기록 노드 제거전 원본 노드 정보 : Sign.signedInfos[3]
- Sign.signedInfos[2] + sColSep + // 공인인증 처리 후 인증된 암호화된 데이터를 의미한다. (이것이 인증데이터)
- model.getValue("/root/send/pastsearchitem/patflag") + sColSep + // 환자구분
- grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("srchdd")); // 검색일자
- //alert("1" + Sign.signedInfos[1]);
- //alert("2" + Sign.signedInfos[2]);
-
- // 서버로 전송할 서식인증 데이터 임시 저장
- model.setValue("/root/send/data/signdata", rCSV2);
-
- return true;
- } else {
- return false;
- }
-
- }
-
- /*
- * Bind 에서 wl, bmi, ap, gi, st, at, dt, age 의 합계를 구하는 함수
- */
- function fsumTotalPNT() {
- var patflag = model.getValue("/root/send/pastsearchitem/patflag");
- var fixedRows = grd_pastnutrsrch.fixedRows;
- var gridRows = grd_pastnutrsrch.rows;
- var gridRow = grd_pastnutrsrch.row;
- var totalpnt = 0;
- var srchrslt = 2;
-
- var good = 0;
- var low = 0;
- var mid = 0;
- var high = 0;
- var non = 0;
- var total = 0;
-
- var isTotalPNT = false;
-
- if(grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("wlpnt")).isNumber()) {
- totalpnt += parseInt(grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("wlpnt")));
- isTotalPNT = true;
- }
-
- if(grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("bmipnt")).isNumber()) {
- totalpnt += parseInt(grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("bmipnt")));
- isTotalPNT = true;
- }
-
- if(grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("appnt")).isNumber()) {
- totalpnt += parseInt(grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("appnt")));
- isTotalPNT = true;
- }
-
- if(grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("gipnt")).isNumber()) {
- totalpnt += parseInt(grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("gipnt")));
- isTotalPNT = true;
- }
-
- if(grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("stpnt")).isNumber()) {
- totalpnt += parseInt(grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("stpnt")));
- isTotalPNT = true;
- }
-
- if(grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("atpnt")).isNumber()) {
- totalpnt += parseInt(grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("atpnt")));
- isTotalPNT = true;
- }
-
- if(grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("dtpnt")).isNumber()) {
- totalpnt += parseInt(grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("dtpnt")));
- isTotalPNT = true;
- }
-
- if(grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("agepnt")).isNumber()) {
- totalpnt += parseInt(grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("agepnt")));
- isTotalPNT = true;
- }
-
- // 그리드에 데이터가 존재 할경우만 처리
- if(gridRows > fixedRows) {
- if(0 <= totalpnt && totalpnt <=2) {
- srchrslt = 2; // 저위험도
- } else if(3 <= totalpnt && totalpnt <=5) {
- srchrslt = 3; // 중위험도
- } else if(6 <= totalpnt) {
- srchrslt = 4; // 고위험도
- } else {
- // 에러!!!
- }
-
- if(isTotalPNT) {
- grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("totalpnt")) = totalpnt; // 그리드 항목의 Total
- grd_pastnutrsrch.valueMatrix(gridRow, grd_pastnutrsrch.colRef("srchrslt")) = srchrslt; // 그리드 항목의 검색결과
- }
- for(var i = fixedRows; i < gridRows; ++i) {
- if(grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("srchrslt")).isNumber()) {
- srchrslt = parseInt(grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("srchrslt")));
-
- if(srchrslt == 1) {
- ++good; // 양호
- } else if(srchrslt == 2) {
- ++low; // 저위험도
- } else if(srchrslt == 3) {
- ++mid; // 중위험도
- } else if(srchrslt == 4) {
- ++high; // 고위험도
- } else {
- // 에러!!!
- ++non;
- }
-
- ++total;
- }
- } // end of for.
-
- if(total > 0) {
- model.makeValue("/root/main/pastsrchrslt/count/good", good);
- model.makeValue("/root/main/pastsrchrslt/count/low", low);
- model.makeValue("/root/main/pastsrchrslt/count/mid", mid);
- model.makeValue("/root/main/pastsrchrslt/count/high", high);
- model.makeValue("/root/main/pastsrchrslt/count/non", non);
- model.makeValue("/root/main/pastsrchrslt/count/total", total);
- }
- }
-
- model.refresh();
- }
-
- function finit() {
- // 화면open시 공통코드 setting
- //zbcfGetCodeList( new Array( "A0058", "P0149", "P0160" ), new Array( "/root/init/basecode/dngr", "/root/init/basecode/orddept", "/root/init/basecode/ward" ) );
- zbcfGetCodeList( new Array( "A0058" ), new Array( "/root/init/basecode/dngr" ) );
- model.copyNode("/root/init/basecode/dngrcopy", "/root/init/basecode/dngr");
- model.removenode("/root/init/basecode/dngrcopy/A0058[2]"); // 양호 삭제
- model.removenode("/root/init/basecode/dngrcopy/A0058[5]"); // 판정불가 삭제
- zbcfGetDeptCodeList(getUserInfo("dutplceinstcd"), 'orduseyn', 'D', '/root/init/basecode/orddept');
- astfAddCombo("/root/init/basecode/orddept","dept","deptcd,depthngnm",",");
- //zbcfGetDeptCodeList(getUserInfo("dutplceinstcd"), 'orduseyn', 'W', '/root/init/basecode/ward', 'depthngnm', 'asc', new Date().getDateFormat("YYYYMMDD"), "", 'after');
- zsdfGetWardDeptList(getUserInfo("dutplceinstcd"), '/root/init/basecode/ward', 'depthngnm', 'asc', new Date().getDateFormat("YYYYMMDD"), 'after');
- // model.resetInstanceNode("/root/main/data");
- model.resetInstanceNode("/root/send");
- model.removeNodeset("/root/main/srchrslt");
- model.removeNodeset("/root/main/pastsrchrslt");
- //model.setFocus("ipt_pid");
- model.setValue("/root/send/searchitem/basedd", getCurrentDate());
- model.setValue("/root/send/pastsearchitem/fromdd", getCurrentDate());
- model.setValue("/root/send/pastsearchitem/todd", getCurrentDate());
- model.setValue("/root/send/statssearchitem/fromdd", getCurrentDate());
- model.setValue("/root/send/statssearchitem/todd", getCurrentDate());
- model.setValue("/root/send/searchitem/patflag", "F");
- model.setValue("/root/send/pastsearchitem/patflag", "F");
- model.setValue("/root/send/pastsearchitem/dngrflag", "4");
- model.setValue("/root/send/statssearchitem/patflag", "H");
- chk_ward.attribute("visibility")="hidden";
- btn_pastnutrsrch.dispatch("DOMActivate"); //영양검색결과조회 탭화면 선택
- btn_pastnutrsrch.selected = true;
- submit("TRANC00102"); //영양판정기준표 조회
- }
- ]]>
- </script>
- <submission id="TRANC00151" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/searchitem" resultref="/root/main/srchrslt"/>
- <submission id="TRANC00156" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/pastsearchitem" resultref="/root/main/pastsrchrslt"/>
- <submission id="TXANC00152" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/data" resultref="/root/temp"/>
- <bind id="fsumTotalPNT" ref="/root/main/pastsrchrslt/data/totalpnt" script="fsumTotalPNT();"/>
- <submission id="TXANC00153" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/data" resultref="/root/temp/singrslt"/>
- <submission id="TXANC00357" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/data/careplan" resultref="/root/hidden/msglist"/>
- </model>
- <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/commonweb/js/numericHelper.js"/>
- <script type="javascript" src="../../../com/commonweb/js/stringHelper.js"/>
- <script type="javascript" src="../../../com/commonweb/js/utilHelper.js"/>
- <script type="javascript" src="../../../com/basiccodeweb/js/ZBC001.js"/>
- <script type="javascript" src="../../../com/departmentcodeweb/js/ZSD001.js"/>
- <script type="javascript" src="../../../ast/commonweb/js/AST.js"/>
- <script type="javascript" src="../../../emr/carecomweb/js/ENRSignEngine.js"/>
- </xhtml:head>
- <xhtml:body guideline="1,1194;2,734;" style="margin-left:0; margin-top:0; margin-right:0; margin-bottom:0; ">
- <group id="grp_tle" style="left:0px; top:0px; width:1194px; height:13px; ">
- <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:216px; height:14px; ">영양검색결과</caption>
- </group>
- <group id="grp_biz" scroll="auto" style="left:0px; top:13px; width:1194px; height:744px; ">
- <switch id="swt_nutrsrchrslt" style="left:0px; top:26px; width:1194px; height:718px; ">
- <case id="case1">
- <group id="grp_sea" style="left:5px; top:10px; width:1182px; height:35px; vertical-align:top; ">
- <shape id="roundrect1" class="roundrect_search" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:0px; width:1182px; height:35px; background-color:#fffbf2; "/>
- <button id="btn_search1" class="btn1_letter2" style="left:1106px; top:7px; width:56px; height:22px; ">
- <caption>조회</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- if (chk_ward.attribute("visibility")=="visible") {
- chk_ward.attribute("visibility")="hidden";
- }
-
- grd_nutrsrch.fixedcellischeck(0,1) = false; //영양검색 탭화면 전체선택 체크박스 초기화
-
- submit("TRANC00151");
-
- //신환(F) or 재검색(I) 구분값 setting
- var patflag = model.getValue("/root/send/searchitem/patflag");
-
- for ( i=1; i<grd_nutrsrch.rows-1; i++) {
- var irow = i + 1;
- model.setValue("/root/main/srchrslt/data[" + i + "]/h_patflag", patflag);
- }
- grd_nutrsrch.refresh();
- //조회조건중 병동 컬럼 clear
- model.resetInstanceNode("/root/send/searchitem/ward");
- model.resetInstanceNode("/root/send/searchitem/optward");
- opt_ward.refresh();
- chk_ward.refresh();
- ]]>
- </script>
- </button>
- <line id="line13" class="line_4" style="x1:1092px; y1:7px; x2:1092px; y2:29px; "/>
- <caption id="caption2" class="search_name" style="left:25px; top:9px; width:86px; height:17px; ">기준일자 :</caption>
- <input id="ipt_basedd" ref="/root/send/searchitem/basedd" class="input_s_essential" inputtype="date" style="left:112px; top:8px; width:93px; height:19px; "/>
- <button id="btn_beforedd" class="icon_pre" style="left:210px; top:10px; width:13px; height:15px; ">
- <caption/>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
- var dd = model.getValue("/root/send/searchitem/basedd");
- dd = dd.toDate().getAddDate(-1, "D");
- dd = dd.getDateFormat();
- model.setValue("/root/send/searchitem/basedd", dd);
- model.refresh();
- ]]>
- </script>
- </button>
- <button id="btn_nextdd" class="icon_next" style="left:225px; top:10px; width:13px; height:15px; ">
- <caption/>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
- var dd = model.getValue("/root/send/searchitem/basedd");
- dd = dd.toDate().getAddDate(1, "D");
- dd = dd.getDateFormat();
- model.setValue("/root/send/searchitem/basedd", dd);
- model.refresh();
- ]]>
- </script>
- </button>
- <caption id="caption9" class="search_name" style="left:665px; top:9px; width:73px; height:17px; ">진료과 :</caption>
- <select1 id="cmb_orddept1" ref="/root/send/searchitem/orddept" class="combo_search" appearance="minimal" style="left:740px; top:8px; width:100px; height:19px; ">
- <choices>
- <itemset nodeset="/root/init/basecode/orddept/dept">
- <label ref="depthngnm"/>
- <value ref="deptcd"/>
- </itemset>
- </choices>
- </select1>
- <caption id="caption14" class="search_name" style="left:875px; top:9px; width:60px; height:17px; ">병동 :</caption>
- <output id="opt_ward" ref="/root/send/searchitem/optward" class="output_search" style="left:935px; top:8px; width:140px; height:19px; ">
- <script type="javascript" ev:event="onclick">
- <![CDATA[
- if (chk_ward.attribute("visibility")=="hidden") {
- chk_ward.attribute("visibility")="visible";
- } else if (chk_ward.attribute("visibility")=="visible") {
- chk_ward.attribute("visibility")="hidden";
- }
- ]]>
- </script>
- </output>
- <select1 id="rdo_patflag1" ref="/root/send/searchitem/patflag" appearance="full" cellspacing="6" cols="2" overflow="visible" style="left:325px; top:9px; width:115px; height:20px; border-style:none; ">
- <choices>
- <item>
- <label>재검색</label>
- <value>I</value>
- </item>
- <item>
- <label>신환</label>
- <value>F</value>
- </item>
- </choices>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
- model.resetInstanceNode("/root/send/searchitem/dngrflag");
- cmb_dngrflag1.refresh();
- ]]>
- </script>
- </select1>
- <caption id="caption4" class="search_name" style="left:265px; top:9px; width:73px; height:17px; ">구분 :</caption>
- <caption id="caption1" class="search_name" style="left:470px; top:9px; width:73px; height:17px; ">위험군 :</caption>
- <select1 id="cmb_dngrflag1" ref="/root/send/searchitem/dngrflag" class="combo_search" appearance="minimal" style="left:543px; top:8px; width:82px; height:19px; ">
- <choices>
- <itemset nodeset="/root/init/basecode/dngrcopy/A0058">
- <label ref="cdnm"/>
- <value ref="cdid"/>
- </itemset>
- </choices>
- </select1>
- </group>
- <button id="btn_excel1" class="btn2_letter2" style="left:1146px; top:50px; width:42px; height:19px; ">
- <caption>엑셀</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- var filename = window.fileDialog("save", ",", false, "NutrSrchRslt_list", "xls", "Excel Files(*.xls)|*.xls|All Files (*.*)|*.*");
- if (filename != "") {
- grd_nutrsrch.saveExcel(filename, "grd_nutrsrch", true, false, "", "", "");
- }
- ]]>
- </script>
- </button>
- <button id="btn_nutrjudgbase" class="btn2_letter6" style="left:990px; top:50px; width:86px; height:19px; ">
- <caption>영양판정기준</caption>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
- modal("SPANC00250", 0,520,280, "SPANC00250", "", "");
- ]]>
- </script>
- </button>
- <button id="btn_insbase" class="btn2_letter4" style="left:1079px; top:50px; width:64px; height:19px; ">
- <caption>INS기준</caption>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
- //modal("SPANC00300", 0,100,150, "SPANC00300", "/root/main/nutrjudgbase/data", "/root/main/receivedata");
- window.load("SPANC00300_INS기준표.xrw","modal","code", "left:600px; top:50px; width:550px; height:380px;min:hidden;max:hidden;resize:true;");
- ]]>
- </script>
- </button>
- <line id="line38" class="line_1" style="x1:5px; y1:74px; x2:1188px; y2:74px; "/>
- <datagrid id="grd_nutrsrch" nodeset="/root/main/srchrslt/data" caption="^h_신환구분^h_처방일자^h_생성번호^h_처방상태^h_입원일자^회신여부^병동^병실^h_병동/병실^등록번호^환자명^성별^나이^h_진단코드^진단명^진료과^전문의ID^전문의^식사명^h_키^h_몸무게^WL^BMI^AP^GI^ST^AT^DT^AGE^Total^검색결과^이전결과^이전결과판정일^TRF^INS결과|^h_신환구분^h_처방일자^h_생성번호^h_처방상태^h_입원일자^회신여부^병동^병실^h_병동/병실^등록번호^환자명^성별^나이^h_진단코드^진단명^진료과^전문의ID^전문의^식사명^h_키^h_몸무게^WL^BMI^AP^GI^ST^AT^DT^AGE^Total^검색결과^이전결과^이전결과판정일^(mg/dl)^INS결과" colsep="^" colwidth="20, 10, 10, 10, 10, 10, 55, 100, 50, 10, 58, 70, 33, 33, 10, 190, 80, 10, 60, 160, 10, 10, 32, 34, 33, 39, 36, 31, 36, 43, 46, 62, 62, 66, 53, 57" mergecellsfixedrows="bycolrec" rowheader="seq" rowsep="|" style="left:5px; top:80px; width:1182px; height:600px; ">
- <col checkvalue="Y,N" ref="check" type="checkbox" style="left:479px; top:43px; width:20px; height:23px; "/>
- <col ref="h_patflag" visibility="hidden"/>
- <col ref="h_prcpdd" visibility="hidden"/>
- <col ref="h_cretno" visibility="hidden"/>
- <col ref="h_prcpgenrflag" visibility="hidden"/>
- <col ref="h_orddd" visibility="hidden"/>
- <col ref="replyn"/>
- <col disabled="true" ref="ward" type="combo">
- <choices>
- <itemset nodeset="/root/init/basecode/ward/dept">
- <label ref="depthngnm"/>
- <value ref="deptcd"/>
- </itemset>
- </choices>
- </col>
- <col ref="room"/>
- <col ref="h_wardroom" visibility="hidden"/>
- <col ref="pid"/>
- <col ref="hngnm"/>
- <col ref="sex"/>
- <col ref="age" style="left:358px; top:20px; width:36px; height:20px; "/>
- <col ref="h_diagcd" visibility="hidden"/>
- <col ref="diagnm"/>
- <col disabled="true" ref="orddept" type="combo">
- <choices>
- <itemset nodeset="/root/init/basecode/orddept/dept">
- <label ref="depthngnm"/>
- <value ref="deptcd"/>
- </itemset>
- </choices>
- </col>
- <col ref="orddrid" visibility="hidden"/>
- <col ref="atdoct"/>
- <col ref="dietnm"/>
- <col ref="h_ht" visibility="hidden"/>
- <col ref="h_wt" visibility="hidden"/>
- <col ref="wlpnt" style="text-align:center; "/>
- <col ref="bmipnt" style="text-align:center; "/>
- <col ref="appnt" style="text-align:center; "/>
- <col ref="gipnt" style="text-align:center; "/>
- <col ref="stpnt" style="text-align:center; "/>
- <col ref="atpnt" style="text-align:center; "/>
- <col ref="dtpnt" style="text-align:center; "/>
- <col ref="agepnt" style="text-align:center; "/>
- <col ref="totalpnt" style="text-align:center; "/>
- <col disabled="true" ref="srchrslt" type="combo">
- <choices>
- <itemset nodeset="/root/init/basecode/dngr/A0058">
- <label ref="cdnm"/>
- <value ref="cdid"/>
- </itemset>
- </choices>
- </col>
- <col disabled="true" ref="bfrslt" type="combo">
- <choices>
- <itemset nodeset="/root/init/basecode/dngr/A0058">
- <label ref="cdnm"/>
- <value ref="cdid"/>
- </itemset>
- </choices>
- </col>
- <col ref="bfrsltdd" format="yyyy-mm-dd"/>
- <col ref="trf" style="text-align:right; "/>
- <col ref="insrslt" style="text-align:center; "/>
- <script type="javascript" ev:event="ondblclick">
- <![CDATA[
- // if ( grd_nutrsrch.isCell(event.target) && grd_nutrsrch.row >= grd_nutrsrch.fixedRows ) {
- // // 'R'은 영양검색결과조회 화면임을 뜻하는 구분자임.
- // model.setValue("/root/send/popup/flag", "R");
- // model.setValue("/root/send/popup/flag2", model.getValue("/root/main/srchrslt/data["+(grd_nutrsrch.row-1)+"]/h_patflag"));
- // model.setValue("/root/send/popup/pid", model.getValue("/root/main/srchrslt/data["+(grd_nutrsrch.row-1)+"]/pid"));
- // model.setValue("/root/send/popup/hngnm", model.getValue("/root/main/srchrslt/data["+(grd_nutrsrch.row-1)+"]/hngnm"));
- // model.setValue("/root/send/popup/orddrid", model.getValue("/root/main/srchrslt/data["+(grd_nutrsrch.row-1)+"]/orddrid"));
- // model.setValue("/root/send/popup/reqpsn", model.getValue("/root/main/srchrslt/data["+(grd_nutrsrch.row-1)+"]/atdoct"));
- // //model.setValue("/root/send/popup/execprcpuniqno", model.getValue("/root/main/srchrslt/data["+(grd_nutrsrch.row-1)+"]/h_execprcpuniqno"));
- // model.setValue("/root/send/popup/h_cretno", model.getValue("/root/main/srchrslt/data["+(grd_nutrsrch.row-1)+"]/h_cretno"));
- // model.setValue("/root/send/popup/h_orddeptcd", model.getValue("/root/main/srchrslt/data["+(grd_nutrsrch.row-1)+"]/orddept"));
- // model.setValue("/root/send/popup/h_prcpgenrflag", model.getValue("/root/main/srchrslt/data["+(grd_nutrsrch.row-1)+"]/h_prcpgenrflag"));
- // model.setValue("/root/send/popup/h_orddd", model.getValue("/root/main/srchrslt/data["+(grd_nutrsrch.row-1)+"]/indd"));
- // model.setValue("/root/send/popup/srchdd", getCurrentDate());
- // if ( model.getValue("/root/main/srchrslt/data["+(grd_nutrsrch.row-1)+"]/bfrsltdd") == "" ) {
- // model.setValue("/root/send/popup/srchdd", getCurrentDate());
- // } else {
- // model.setValue("/root/send/popup/srchdd", model.getValue("/root/main/srchrslt/data["+(grd_nutrsrch.row-1)+"]/bfrsltdd"));
- // }
- //
- // open("SMANC00300", "","","", "SMANC00300", "/root/send/popup", "/root/main/receivedata");
- // }
- ]]>
- </script>
- <hint>
- <![CDATA[1. WL( 최근 3개월간 체중감소 ), 2. BMI( 성인:체중/키*키*0.0001, 소아:체중/소아기준표체중*100 ), 3. AP( 식욕상태 ),
- 4. GI( 소화기계 장애 ), 5. ST( 배변장애 ), 6. AT( 활동정도 ), 7. DT( 식사처방 ), 8. AGE( 나이 ),
- TOTAL( WL + BMI + AP + GI + ST + AT + DT + ATE 의 합계 )]]>
- </hint>
- </datagrid>
- <line id="line4" class="line_2" style="x1:5px; y1:685px; x2:1187px; y2:685px; "/>
- <output id="opt_srchrslt1" ref="/root/main/srchrslt/count/good" class="output_fix" style="left:119px; top:689px; width:126px; height:19px; text-align:center; "/>
- <output id="opt_srchrslt2" ref="/root/main/srchrslt/count/low" class="output_fix" style="left:310px; top:689px; width:125px; height:19px; text-align:center; "/>
- <output id="opt_srchrslt3" ref="/root/main/srchrslt/count/mid" class="output_fix" style="left:502px; top:689px; width:125px; height:19px; text-align:center; "/>
- <caption id="caption7" class="cell_1" style="left:5px; top:687px; width:61px; height:23px; vertical-align:middle; ">검색결과</caption>
- <caption id="caption8" class="cell_1" style="left:247px; top:687px; width:60px; height:23px; vertical-align:middle; ">저위험도</caption>
- <caption id="caption10" class="cell_1" style="left:68px; top:687px; width:48px; height:23px; text-align:center; vertical-align:middle; ">양호</caption>
- <caption id="caption11" class="cell_1" style="left:438px; top:687px; width:61px; height:23px; vertical-align:middle; ">중위험도</caption>
- <caption id="caption12" class="cell_1" style="left:630px; top:687px; width:61px; height:23px; vertical-align:middle; ">고위험도</caption>
- <output id="opt_srchrslt4" ref="/root/main/srchrslt/count/high" class="output_fix" style="left:693px; top:689px; width:120px; height:19px; text-align:center; "/>
- <output id="opt_srchrsltsum1" ref="/root/main/srchrslt/count/total" class="output_fix" style="left:1062px; top:689px; width:125px; height:19px; text-align:center; "/>
- <caption id="caption3" class="cell_1" style="left:1000px; top:687px; width:61px; height:23px; text-align:center; vertical-align:middle; ">계</caption>
- <line id="line5" class="line_3" style="x1:5px; y1:710px; x2:1187px; y2:710px; "/>
- <caption id="caption5" class="cell_1" style="left:815px; top:687px; width:61px; height:23px; vertical-align:middle; ">판정불가</caption>
- <output id="opt_srchrslt5" ref="/root/main/srchrslt/count/non" class="output_fix" style="left:878px; top:689px; width:120px; height:19px; text-align:center; "/>
- </case>
- <case id="case2" selected="true">
- <group id="group1" style="left:5px; top:10px; width:1182px; height:35px; vertical-align:top; ">
- <shape id="roundrect2" class="roundrect_search" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:0px; width:1182px; height:35px; background-color:#fffbf2; "/>
- <button id="btn_search2" class="btn1_letter2" style="left:1106px; top:7px; width:56px; height:22px; ">
- <caption>조회</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- var patflag = model.getValue("/root/send/pastsearchitem/patflag"); // 전체, 재검색, 신환 구분
- var fromdd = model.getValue("/root/send/pastsearchitem/fromdd");
- var todd = model.getValue("/root/send/pastsearchitem/todd");
- if ( getDateInterval(fromdd, todd) < 0 ) {
- messageBox("검색 시작일은 종료일보다 클 수", "I004");
- return;
- } else {
- var gridRows = grd_pastnutrsrch.rows;
- var fixedRows = grd_pastnutrsrch.fixedRows;
-
- for(var i = fixedRows; i < gridRows; ++i) {
- grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("wlpnt")) = "";
- grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("bmipnt")) = "";
- grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("appnt")) = "";
- grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("gipnt")) = "";
- grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("stpnt")) = "";
- grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("atpnt")) = "";
- grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("dtpnt")) = "";
- grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("agepnt")) = "";
- grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("totalpnt")) = "";
- }
-
- grd_pastnutrsrch.fixedcellischeck(0,1) = false; //영양검색결과 탭화면 전체선택 체크박스 초기화
-
- submit("TRANC00156");
- }
-
- var fixedRows = grd_pastnutrsrch.fixedRows;
- var gridRows = grd_pastnutrsrch.rows;
- var srchrslt = 2;
- var good = 0;
- var low = 0;
- var mid = 0;
- var high = 0;
- var non = 0;
- var total = 0;
-
- for(var i = fixedRows; i < gridRows; ++i) {
- if(grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("srchrslt")).isNumber()) {
- srchrslt = parseInt(grd_pastnutrsrch.valueMatrix(i, grd_pastnutrsrch.colRef("srchrslt")));
-
- if(srchrslt == 1) {
- ++good; // 양호
- } else if(srchrslt == 2) {
- ++low; // 저위험도
- } else if(srchrslt == 3) {
- ++mid; // 중위험도
- } else if(srchrslt == 4) {
- ++high; // 고위험도
- } else {
- // 에러!!!
- ++non;
- }
-
- ++total;
- }
- } // end of for.
-
- if(total > 0) {
- model.makeValue("/root/main/pastsrchrslt/count/good", good);
- model.makeValue("/root/main/pastsrchrslt/count/low", low);
- model.makeValue("/root/main/pastsrchrslt/count/mid", mid);
- model.makeValue("/root/main/pastsrchrslt/count/high", high);
- model.makeValue("/root/main/pastsrchrslt/count/non", non);
- model.makeValue("/root/main/pastsrchrslt/count/total", total);
- }
-
- // 재검색 여부를 확인 - 재검색 일경우 wl, bmi, ... age 항목이 수정되어야 됨.
- if(patflag == "I") {
- model.makeValue("/root/temp/patflagyn", "Y");
- } else {
- model.makeValue("/root/temp/patflagyn", "N");
- }
-
- model.refresh();
- ]]>
- </script>
- </button>
- <line id="line1" class="line_4" style="x1:1092px; y1:7px; x2:1092px; y2:29px; "/>
- <caption id="caption13" class="search_name" style="left:30px; top:9px; width:86px; height:17px; ">검색일자 :</caption>
- <input id="ipt_fromdd" ref="/root/send/pastsearchitem/fromdd" class="input_s_essential" inputtype="date" style="left:117px; top:8px; width:93px; height:19px; "/>
- <caption id="caption16" class="search_name" style="left:860px; top:9px; width:60px; height:17px; ">병동 :</caption>
- <select1 id="cmb_ward2" ref="/root/send/pastsearchitem/ward" class="combo_s_essential" appearance="minimal" style="left:920px; top:8px; width:150px; height:19px; ">
- <choices>
- <itemset nodeset="/root/init/basecode/ward/dept">
- <label ref="depthngnm"/>
- <value ref="deptcd"/>
- </itemset>
- </choices>
- </select1>
- <select1 id="rdo_patflag2" ref="/root/send/pastsearchitem/patflag" appearance="full" cellspacing="6" cols="3" overflow="visible" style="left:435px; top:9px; width:160px; height:20px; border-style:none; ">
- <choices>
- <item>
- <label>재검색</label>
- <value>I</value>
- </item>
- <item>
- <label>신환</label>
- <value>F</value>
- </item>
- </choices>
- </select1>
- <caption id="caption17" class="search_name" style="left:375px; top:9px; width:73px; height:17px; ">구분 :</caption>
- <caption id="caption18" class="search_no_b" style="left:215px; top:10px; width:12px; height:17px; ">~</caption>
- <input id="ipt_todd" ref="/root/send/pastsearchitem/todd" class="input_s_essential" inputtype="date" style="left:230px; top:8px; width:93px; height:19px; "/>
- <caption id="caption19" class="search_name" style="left:645px; top:9px; width:73px; height:17px; ">위험군 :</caption>
- <select1 id="cmb_dngrflag2" ref="/root/send/pastsearchitem/dngrflag" class="combo_search" appearance="minimal" style="left:718px; top:8px; width:82px; height:19px; ">
- <choices>
- <itemset nodeset="/root/init/basecode/dngrcopy/A0058">
- <label ref="cdnm"/>
- <value ref="cdid"/>
- </itemset>
- </choices>
- </select1>
- </group>
- <button id="btn_excel2" class="btn2_letter2" style="left:1146px; top:50px; width:42px; height:19px; ">
- <caption>엑셀</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- var filename = window.fileDialog("save", ",", false, "PastNutrSrchRslt_list", "xls", "Excel Files(*.xls)|*.xls|All Files (*.*)|*.*");
- if (filename != "") {
- grd_pastnutrsrch.saveExcel(filename, "grd_pastnutrsrch", true, false, "", "", "");
- }
- ]]>
- </script>
- </button>
- <line id="line2" class="line_1" style="x1:5px; y1:74px; x2:1188px; y2:74px; "/>
- <datagrid id="grd_pastnutrsrch" nodeset="/root/main/pastsrchrslt/data" caption="고지^고지여부^회신여부^검색일자^신환구분^입원일자^병동^병실^등록번호^환자명^성별^나이^진단명^진료과^전문의^식사명^WL^BMI^AP^GI^ST^AT^DT^AGE^Total^검색결과^이전결과^이전결과판정일^TRF^INS결과^비고^서명번호^입원, 외래구분^생성번호^전문의ID|고지^고지여부^회신여부^검색일자^신환구분^입원일자^병동^병실^등록번호^환자명^성별^나이^진단명^진료과^전문의^식사명^WL^BMI^AP^GI^ST^AT^DT^AGE^Total^검색결과^이전결과^이전결과판정일^(mg/dl)^INS결과^비고^서명번호^입원, 외래구분^생성번호^전문의ID" colsep="^" colwidth="46, 58, 55, 70, 55, 70, 100, 50, 75, 70, 32, 32, 190, 90, 70, 170, 29, 30, 28, 30, 31, 28, 30, 46, 47, 60, 60, 68, 55, 60, 120, 100, 100, 100, 100" mergecellsfixedrows="bycolrec" rowheader="seq" rowsep="|" style="left:5px; top:80px; width:1182px; height:600px; ">
- <col ref="check" type="checkbox"/>
- <col ref="signyn" style="text-align:center; "/>
- <col ref="replyn"/>
- <col ref="srchdd" format="yyyy-mm-dd"/>
- <col disabled="true" ref="patflag" type="combo">
- <choices>
- <item>
- <label>재검색</label>
- <value>I</value>
- </item>
- <item>
- <label>신환</label>
- <value>F</value>
- </item>
- </choices>
- </col>
- <col ref="orddd" format="yyyy-mm-dd"/>
- <col disabled="true" ref="ward" type="combo">
- <choices>
- <itemset nodeset="/root/init/basecode/ward/dept">
- <label ref="depthngnm"/>
- <value ref="deptcd"/>
- </itemset>
- </choices>
- </col>
- <col ref="room"/>
- <col ref="pid"/>
- <col ref="hngnm"/>
- <col ref="sex"/>
- <col ref="age" style="left:358px; top:20px; width:36px; height:20px; "/>
- <col ref="diagnm"/>
- <col disabled="true" ref="orddept" type="combo">
- <choices>
- <itemset nodeset="/root/init/basecode/orddept/dept">
- <label ref="depthngnm"/>
- <value ref="deptcd"/>
- </itemset>
- </choices>
- </col>
- <col ref="atdoct"/>
- <col ref="dietnm"/>
- <col disabled="true" ref="wlpnt" type="input" style="text-align:center; "/>
- <col disabled="true" ref="bmipnt" type="input" style="text-align:center; "/>
- <col disabled="true" ref="appnt" type="input" style="text-align:center; "/>
- <col disabled="true" ref="gipnt" type="input" style="text-align:center; "/>
- <col disabled="true" ref="stpnt" type="input" style="text-align:center; "/>
- <col disabled="true" ref="atpnt" type="input" style="text-align:center; "/>
- <col disabled="true" ref="dtpnt" type="input" style="text-align:center; "/>
- <col disabled="true" ref="agepnt" type="input" style="text-align:center; "/>
- <col disabled="true" ref="totalpnt" type="output" style="text-align:center; "/>
- <col disabled="true" ref="srchrslt" type="combo">
- <choices>
- <itemset nodeset="/root/init/basecode/dngr/A0058">
- <label ref="cdnm"/>
- <value ref="cdid"/>
- </itemset>
- </choices>
- </col>
- <col disabled="true" ref="bfrslt" type="combo">
- <choices>
- <itemset nodeset="/root/init/basecode/dngr/A0058">
- <label ref="cdnm"/>
- <value ref="cdid"/>
- </itemset>
- </choices>
- </col>
- <col ref="bfrsltdd" format="yyyy-mm-dd"/>
- <col ref="trf" style="text-align:right; "/>
- <col ref="insrslt" style="text-align:center; "/>
- <col ref="rem" type="input"/>
- <col ref="h_signno" visibility="hidden"/>
- <col ref="prcpgenrflag" visibility="hidden"/>
- <col ref="cretno" visibility="hidden"/>
- <col ref="orddrid" visibility="hidden"/>
- <script type="javascript" ev:event="ondblclick">
- <![CDATA[
- if ( grd_pastnutrsrch.isCell(event.target) && grd_pastnutrsrch.row >= grd_pastnutrsrch.fixedRows ) {
- // 'R'은 영양검색결과조회 화면임을 뜻하는 구분자임.
- model.setValue("/root/send/popup/flag", "R");
- model.setValue("/root/send/popup/flag2", model.getValue("/root/main/pastsrchrslt/data["+(grd_pastnutrsrch.row-1)+"]/patflag"));
- model.setValue("/root/send/popup/pid", model.getValue("/root/main/pastsrchrslt/data["+(grd_pastnutrsrch.row-1)+"]/pid"));
- model.setValue("/root/send/popup/hngnm", model.getValue("/root/main/pastsrchrslt/data["+(grd_pastnutrsrch.row-1)+"]/hngnm"));
- model.setValue("/root/send/popup/orddrid", model.getValue("/root/main/pastsrchrslt/data["+(grd_pastnutrsrch.row-1)+"]/orddrid"));
- model.setValue("/root/send/popup/reqpsn", model.getValue("/root/main/pastsrchrslt/data["+(grd_pastnutrsrch.row-1)+"]/atdoct"));
- model.setValue("/root/send/popup/h_cretno", model.getValue("/root/main/pastsrchrslt/data["+(grd_pastnutrsrch.row-1)+"]/cretno"));
- model.setValue("/root/send/popup/h_orddeptcd", model.getValue("/root/main/pastsrchrslt/data["+(grd_pastnutrsrch.row-1)+"]/orddept"));
- model.setValue("/root/send/popup/h_prcpgenrflag", model.getValue("/root/main/pastsrchrslt/data["+(grd_pastnutrsrch.row-1)+"]/prcpgenrflag"));
- model.setValue("/root/send/popup/h_orddd", model.getValue("/root/main/pastsrchrslt/data["+(grd_pastnutrsrch.row-1)+"]/orddd"));
- model.setValue("/root/send/popup/srchdd", model.getValue("/root/main/pastsrchrslt/data["+(grd_pastnutrsrch.row-1)+"]/srchdd"));
- open("SMANC00350", "","","", "SMANC00350", "/root/send/popup", "/root/main/receivedata");
- }
- ]]>
- </script>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
- var patflag = model.getValue("/root/send/pastsearchitem/patflag"); // 신환, 재검색 구분
- var patflagyn = model.getValue("/root/temp/patflagyn"); // 신환, 재검색 선택 여부( 'Y' 재검색, 'N' 신환 )
- var fixedRows = grd_pastnutrsrch.fixedRows;
- var gridRows = grd_pastnutrsrch.rows;
- var totalpnt = 0;
-
- if(patflag == "I" && patflagyn == "Y") {
- for(var i = fixedRows; i < gridRows; ++i) {
- grd_pastnutrsrch.cellAttribute("disabled", i, grd_pastnutrsrch.colRef("wlpnt")) = "false";
- grd_pastnutrsrch.cellAttribute("disabled", i, grd_pastnutrsrch.colRef("bmipnt")) = "false";
- grd_pastnutrsrch.cellAttribute("disabled", i, grd_pastnutrsrch.colRef("appnt")) = "false";
- grd_pastnutrsrch.cellAttribute("disabled", i, grd_pastnutrsrch.colRef("gipnt")) = "false";
- grd_pastnutrsrch.cellAttribute("disabled", i, grd_pastnutrsrch.colRef("stpnt")) = "false";
- grd_pastnutrsrch.cellAttribute("disabled", i, grd_pastnutrsrch.colRef("atpnt")) = "false";
- grd_pastnutrsrch.cellAttribute("disabled", i, grd_pastnutrsrch.colRef("dtpnt")) = "false";
- grd_pastnutrsrch.cellAttribute("disabled", i, grd_pastnutrsrch.colRef("agepnt")) = "false";
- }
- } else {
- for(var i = fixedRows; i < gridRows; ++i) {
- grd_pastnutrsrch.cellAttribute("disabled", i, grd_pastnutrsrch.colRef("wlpnt")) = "true";
- grd_pastnutrsrch.cellAttribute("disabled", i, grd_pastnutrsrch.colRef("bmipnt")) = "true";
- grd_pastnutrsrch.cellAttribute("disabled", i, grd_pastnutrsrch.colRef("appnt")) = "true";
- grd_pastnutrsrch.cellAttribute("disabled", i, grd_pastnutrsrch.colRef("gipnt")) = "true";
- grd_pastnutrsrch.cellAttribute("disabled", i, grd_pastnutrsrch.colRef("stpnt")) = "true";
- grd_pastnutrsrch.cellAttribute("disabled", i, grd_pastnutrsrch.colRef("atpnt")) = "true";
- grd_pastnutrsrch.cellAttribute("disabled", i, grd_pastnutrsrch.colRef("dtpnt")) = "true";
- grd_pastnutrsrch.cellAttribute("disabled", i, grd_pastnutrsrch.colRef("agepnt")) = "true";
- grd_pastnutrsrch.cellAttribute("disabled", i, grd_pastnutrsrch.colRef("totalpnt")) = "true";
- }
- }
-
- grd_pastnutrsrch.editCell();
- grd_pastnutrsrch.refresh();
- ]]>
- </script>
- <hint>
- <![CDATA[1. WL( 최근 3개월간 체중감소 ), 2. BMI( 성인:체중/키*키*0.0001, 소아:체중/소아기준표체중*100 ), 3. AP( 식욕상태 ),
- 4. GI( 소화기계 장애 ), 5. ST( 배변장애 ), 6. AT( 활동정도 ), 7. DT( 식사처방 ), 8. AGE( 나이 ),
- TOTAL( WL + BMI + AP + GI + ST + AT + DT + ATE 의 합계 )]]>
- </hint>
- </datagrid>
- <line id="line3" class="line_2" style="x1:5px; y1:685px; x2:1187px; y2:685px; "/>
- <output id="opt_srchrslt6" ref="/root/main/pastsrchrslt/count/good" class="output_fix" style="left:118px; top:689px; width:125px; height:19px; text-align:center; "/>
- <output id="opt_srchrslt7" ref="/root/main/pastsrchrslt/count/low" class="output_fix" style="left:308px; top:689px; width:125px; height:19px; text-align:center; "/>
- <output id="opt_srchrslt8" ref="/root/main/pastsrchrslt/count/mid" class="output_fix" style="left:499px; top:689px; width:125px; height:19px; text-align:center; "/>
- <caption id="caption20" class="cell_1" style="left:5px; top:687px; width:61px; height:23px; vertical-align:middle; ">검색결과</caption>
- <caption id="caption21" class="cell_1" style="left:246px; top:687px; width:60px; height:23px; vertical-align:middle; ">저위험도</caption>
- <caption id="caption22" class="cell_1" style="left:68px; top:687px; width:48px; height:23px; text-align:center; vertical-align:middle; ">양호</caption>
- <caption id="caption23" class="cell_1" style="left:436px; top:687px; width:61px; height:23px; vertical-align:middle; ">중위험도</caption>
- <caption id="caption24" class="cell_1" style="left:627px; top:687px; width:61px; height:23px; vertical-align:middle; ">고위험도</caption>
- <output id="opt_srchrslt9" ref="/root/main/pastsrchrslt/count/high" class="output_fix" style="left:690px; top:689px; width:125px; height:19px; text-align:center; "/>
- <output id="opt_srchrsltsum2" ref="/root/main/pastsrchrslt/count/total" class="output_fix" style="left:1070px; top:689px; width:117px; height:19px; text-align:center; "/>
- <caption id="caption25" class="cell_1" style="left:1008px; top:687px; width:61px; height:23px; text-align:center; vertical-align:middle; ">계</caption>
- <line id="line6" class="line_3" style="x1:5px; y1:710px; x2:1187px; y2:710px; "/>
- <output id="opt_srchrslt10" ref="/root/main/pastsrchrslt/count/non" class="output_fix" style="left:880px; top:689px; width:125px; height:19px; text-align:center; "/>
- <caption id="caption15" class="cell_1" style="left:817px; top:687px; width:61px; height:23px; vertical-align:middle; ">판정불가</caption>
- </case>
- <case id="case3">
- <group id="group2" style="left:5px; top:10px; width:1182px; height:35px; vertical-align:top; ">
- <shape id="roundrect3" class="roundrect_search" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:0px; width:1182px; height:35px; background-color:#fffbf2; "/>
- <button id="btn_search3" class="btn1_letter2" style="left:1106px; top:7px; width:56px; height:22px; ">
- <caption>조회</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- var fromdd = model.getValue("/root/send/statssearchitem/fromdd");
- var todd = model.getValue("/root/send/statssearchitem/todd");
- //var ward = model.getValue("/root/send/searchitem/ward");
- if ( getDateInterval(fromdd, todd) < 0 ) {
- messageBox("검색 시작일은 종료일보다 클 수", "I004");
- return;
- } else {
- if (submit("TRANC00157")) {
- //조회후 그리드 하단에 합계 구하기
- //grd_nutrsrchstats.subtotal("clear", -1, 4, "", "", "", "");
- grd_nutrsrchstats.subtotalPosition = "below";
- for (var i = 2; i <= 13; i ++){
- grd_nutrsrchstats.subtotal("sum", -1, i, "#,###", "", 1, "합 계 ");
- }
- grd_nutrsrchstats.refresh();
- }
- }
- ]]>
- </script>
- </button>
- <line id="line7" class="line_4" style="x1:1092px; y1:7px; x2:1092px; y2:29px; "/>
- <caption id="caption26" class="search_name" style="left:10px; top:9px; width:86px; height:17px; ">검색일자 :</caption>
- <input id="ipt_fromdd3" ref="/root/send/statssearchitem/fromdd" class="input_s_essential" inputtype="date" style="left:97px; top:8px; width:93px; height:19px; "/>
- <caption id="caption27" class="search_name" style="left:720px; top:9px; width:73px; height:17px; ">진료과 :</caption>
- <select1 id="cmb_orddept3" ref="/root/send/statssearchitem/orddept" class="combo_search" appearance="minimal" style="left:795px; top:8px; width:95px; height:19px; ">
- <choices>
- <itemset nodeset="/root/init/basecode/orddept/dept">
- <label ref="depthngnm"/>
- <value ref="deptcd"/>
- </itemset>
- </choices>
- </select1>
- <caption id="caption28" class="search_name" style="left:910px; top:9px; width:60px; height:17px; ">병동 :</caption>
- <select1 id="cmb_ward3" ref="/root/send/statssearchitem/ward" class="combo_s_essential" appearance="minimal" style="left:970px; top:8px; width:105px; height:19px; ">
- <choices>
- <itemset nodeset="/root/init/basecode/ward/dept">
- <label ref="depthngnm"/>
- <value ref="deptcd"/>
- </itemset>
- </choices>
- </select1>
- <select1 id="rdo_patflag3" ref="/root/send/statssearchitem/patflag" appearance="full" cellspacing="4" cols="3" overflow="visible" style="left:380px; top:9px; width:160px; height:20px; border-style:none; ">
- <choices>
- <item>
- <label>전체</label>
- <value>H</value>
- </item>
- <item>
- <label>재검색</label>
- <value>I</value>
- </item>
- <item>
- <label>신환</label>
- <value>F</value>
- </item>
- </choices>
- </select1>
- <caption id="caption29" class="search_name" style="left:320px; top:9px; width:73px; height:17px; ">구분 :</caption>
- <caption id="caption30" class="search_no_b" style="left:195px; top:10px; width:12px; height:17px; ">~</caption>
- <input id="ipt_todd3" ref="/root/send/statssearchitem/todd" class="input_s_essential" inputtype="date" style="left:210px; top:8px; width:93px; height:19px; "/>
- <caption id="caption31" class="search_name" style="left:550px; top:9px; width:73px; height:17px; ">위험군 :</caption>
- <select1 id="cmb_dngrflag3" ref="/root/send/statssearchitem/dngrflag" class="combo_search" appearance="minimal" style="left:623px; top:8px; width:75px; height:19px; ">
- <choices>
- <itemset nodeset="/root/init/basecode/dngr/A0058">
- <label ref="cdnm"/>
- <value ref="cdid"/>
- </itemset>
- </choices>
- </select1>
- </group>
- <button id="btn_excel3" class="btn2_letter2" style="left:1146px; top:50px; width:42px; height:19px; ">
- <caption>엑셀</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- var filename = window.fileDialog("save", ",", false, "NutrSrchRsltStats_list", "xls", "Excel Files(*.xls)|*.xls|All Files (*.*)|*.*");
- if (filename != "") {
- grd_nutrsrchstats.saveExcel(filename, "grd_nutrsrchstats", true, false, "", "", "");
- }
- ]]>
- </script>
- </button>
- <line id="line8" class="line_1" style="x1:5px; y1:74px; x2:1188px; y2:74px; "/>
- <datagrid id="grd_nutrsrchstats" nodeset="/root/main/srchstats/data" caption="검색일자^신환^신환^신환^신환^신환^신환^재검색^재검색^재검색^재검색^재검색^재검색|검색일자^양호^저위험도^중위헙도^고위험도^판정불가^합계^양호^저위험도^중위험도^고위험도^판정불가^합계" colsep="^" colwidth="100, 65, 65, 67, 72, 70, 88, 65, 65, 76, 71, 72, 77" dataheight="25" mergecellsfixedrows="bycolrec" rowheader="seq" rowsep="|" style="left:5px; top:80px; width:1182px; height:629px; text-align:center; ">
- <col ref="srchdd" format="yyyy-mm-dd" style="left:20px; top:43px; width:100px; height:23px; "/>
- <col ref="good1"/>
- <col ref="low1"/>
- <col ref="mid1"/>
- <col ref="high1"/>
- <col ref="non1"/>
- <col ref="total1"/>
- <col ref="good2"/>
- <col ref="low2"/>
- <col ref="mid2"/>
- <col ref="high2"/>
- <col ref="non2"/>
- <col ref="total2"/>
- </datagrid>
- </case>
- </switch>
- <button id="btn_nutrsrch" class="btn_sw" group="tab" selected="true" style="left:0px; top:5px; width:89px; height:22px; ">
- <caption>영양검색</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- model.toggle("case1");
- //btn_save.visible = true;
- btn_save.disabled = false;
- btn_signsave.disabled = true;
- btn_signsave.visible = false;
- ]]>
- </script>
- </button>
- <button id="btn_pastnutrsrch" class="btn_sw" group="tab" selected="false" style="left:88px; top:5px; width:125px; height:22px; ">
- <caption>영양검색결과조회</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- if (chk_ward.attribute("visibility")=="visible") {
- chk_ward.attribute("visibility")="hidden";
- }
- model.toggle("case2");
- btn_save.disabled = false;
- btn_signsave.disabled = false;
- btn_signsave.visible = true;
- ]]>
- </script>
- </button>
- <button id="btn_nutrsrchstats" class="btn_sw" group="tab" selected="false" style="left:212px; top:5px; width:95px; height:22px; ">
- <caption>영양검색통계</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- if (chk_ward.attribute("visibility")=="visible") {
- chk_ward.attribute("visibility")="hidden";
- }
- model.toggle("case3");
- btn_save.disabled = true;
- btn_signsave.disabled = true;
- btn_signsave.visible = false;
- ]]>
- </script>
- </button>
- </group>
- <group id="grp_btn" style="left:0px; top:757px; width:1194px; height:27px; ">
- <button id="btn_prnt" class="btn6_letter2" visibility="hidden" style="left:0px; top:5px; width:56px; height:22px; ">
- <caption>출력</caption>
- </button>
- <button id="btn_signsave" class="btn4_letter4" style="left:986px; top:5px; width:80px; height:22px; ">
- <caption>인증저장</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- if ( btn_pastnutrsrch.selected ) {
- var patflag = model.getValue("/root/send/pastsearchitem/patflag"); // 신환, 재검색 구분
- var patflagyn = model.getValue("/root/temp/patflagyn"); // 신환, 재검색 선택 여부( 'Y' 재검색, 'N' 신환 )
-
- if(messageBox("인증 데이터를", "Q002") == "6") {
- // 신환, 재검색 유무 확인후 저장
- if(patflag == "F" && patflagyn == "N") {
- fCertSave(); // 인증저장 호출
- } else {
- if ( getGridUpdateData(grd_pastnutrsrch) == "" ) {
- messageBox("입력 또는 수정한 데이터가", "I004");
- } else {
- model.setValue("/root/send/data/pastlist", grd_pastnutrsrch.getUpdateData());
-
- if (submit("TXANC00152")) {
- fCertSave(); // 인증저장 호출
- }
- } // end of if-else.
- }
- }
-
- }
- ]]>
- </script>
- </button>
- <button id="btn_reset" class="btn4_letter3" style="left:1067px; top:5px; width:68px; height:22px; ">
- <caption>초기화</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- finit();
- ]]>
- </script>
- </button>
- <button id="btn_save" class="btn4_letter2" style="left:1136px; top:5px; width:56px; height:22px; ">
- <caption>저장</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- //영양검색 탭화면 일때
- if ( btn_nutrsrch.selected ) {
- //하루에 기준일자를 달리하여 2회이상 재검색할 경우 데이터 중복을 피하기 위해 입원일자를 기준일의 7일전 날짜로 셋팅후 저장한다.
- if ( model.getValue("/root/send/searchitem/patflag") == "I" ) {
- var basedd = model.getValue("/root/send/searchitem/basedd");
- basedd = basedd.toDate().getAddDate(-7, "D");
- basedd = basedd.getDateFormat();
- for ( i=1; i<grd_nutrsrch.rows-1; i++) {
- model.setValue("/root/main/srchrslt/data[" + i + "]/h_orddd", basedd);
- }
- }
-
- //저장할 데이터를 한건이라도 check했는지 체크
- var nodeList = instance1.selectNodes("/root/main/srchrslt/data[check='Y']");
- var rCSV = getNodeListCSV(nodeList);
- if ( rCSV == null ) {
- messageBox("저장할 데이터를", "C002");
- return;
- }
-
- if ( messageBox("체크한 데이터를", "Q002") == 6 ) {
- if (btn_nutrsrch.selected) {
- //하루에 기준일자별로 재검색,신환 각 한번씩만 저장 가능
- //오늘날짜에 기준일자에 해당하는 재검색 or 신환 데이터 존재여부를 체크해서 없으면 저장한다.
- submit("TRANC00103");
- var count = model.getValue("/root/temp/count/cnt");
- if ( count > 0 ) {
- var basedd = ipt_basedd.value;
- var patflag = rdo_patflag1.label;
- messageBox(basedd.substr(0,4)+"-"+basedd.substr(4,2)+"-"+basedd.substr(6,2)+" " + patflag + " 데이터를 이미 저장했습니다. 두번 저장", "E001");
- return;
- } else {
- model.setValue("/root/send/data/list", rCSV);
- if (submit("TXANC00151")) {
- btn_search1.dispatch("DOMActivate");
- model.resetInstanceNode("/root/send/data/list");
- }
- }
- }
- } else { return; }
- }
- //과거영양검색조회 탭화면 일때
- else if ( btn_pastnutrsrch.selected ) {
- if ( getGridUpdateData(grd_pastnutrsrch) == "" ) {
- messageBox("입력 또는 수정한 데이터가", "I004");
- } else {
- if ( messageBox("", "Q002") == 6 ) {
- model.setValue("/root/send/data/pastlist", grd_pastnutrsrch.getUpdateData());
- if (submit("TXANC00152")) {
- btn_search2.dispatch("DOMActivate");
- }
- } else { return; }
- }
- }
- ]]>
- </script>
- </button>
- <line id="line32" class="line_6" style="x1:0px; y1:0px; x2:1194px; y2:0px; "/>
- </group>
- <select id="chk_ward" ref="/root/send/searchitem/ward" class="checkbox_search" overflow="visible" appearance="full" style="left:940px; top:78px; width:140px; height:15px; background-color:#e5eae9; ">
- <choices>
- <itemset nodeset="/root/init/basecode/ward/dept">
- <label ref="depthngnm"/>
- <value ref="deptcd"/>
- </itemset>
- </choices>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
- model.setValue("/root/send/searchitem/optward", chk_ward.label);
- opt_ward.refresh();
- ]]>
- </script>
- </select>
- </xhtml:body>
- </xhtml:html>
|