123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210 |
- /*
-
- ER Daily Census (SMMNE01300.xfm - JScript )
- - Version :
- 1) : Ver.1.00.01
- */
- var MemoUseYn = "";
- /**
- * @group :
- * @ver : 2007.07.12
- * @by : 양천덕
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 초기 화면 설정(기초 정보 설정)
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fInit(){
-
- // 간호하드코딩 테이블 조회_20090415(ByJA)
- var pCode = "'131'"; // 조회할 CdGrupID 코드정보
- var pDate = getCurrentDate(); //조회기준일자
- fGetNursHardCdInfo(pCode, pDate);
-
- MemoUseYn = model.getValue("/root/code/codeinfo/codelist[cdgrupid ="+"131"+"]/cdid");
-
- if(MemoUseYn == "Y"){
- btn_memo.visible = true;
- }
-
- model.removeNodeset("/root/main/erdailycensuslist/ercensuspatcnt");
- model.removeNodeset("/root/main/erdayiycesussection/ercensusinsucnt");
- model.removeNodeset("/root/main/erdayiycesussection/ercensuspatlinfo");
- var setDate = getDateCalc(getCurrentDate() , 1);
- model.setValue("/root/main/cond/fromdate", setDate);
- model.setValue("/root/main/cond/todate", getDateAddc(setDate, 1));
- model.setValue("/root/main/cond/srcflag", "D");
- model.setValue("/root/main/cond/chngdateyn","Y");
-
- fSearch();
- }
-
- /**
- * @group :
- * @ver : 2007.07.12
- * @by : 양천덕
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 조회일자별 보험, 내원/퇴원/keep 조회, 환자
- * 리스트 조회
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fSearch(){
-
- var sSrchHeader = "fromdate▦todate▦srcflag▦chngdateyn▦memoflag▩";
-
- if(model.getValue("/root/main/cond/chngdateyn") == "Y"){
-
- var sSrchData = model.getValue("/root/main/cond/fromdate" )+"▦"
- + model.getValue("/root/main/cond/todate" )+"▦"
- + model.getValue("/root/main/cond/srcflag" )+"▦"
- + model.getValue("/root/main/cond/chngdateyn" )+"▦"
- + "▩";
-
- model.removenode("/root/send");
- //model.removeNodeset("/root/main/erdailycensuslist/ercensuspatcnt");
- model.makeValue("/root/send/cond", sSrchHeader + sSrchData);
-
- submit("TRMNE01301", false);
- model.setValue("/root/main/cond/chngdateyn","N");
- }
-
-
- //grd_ercensuspatcnt.mergeByFree(1, 4, 3, 4);
- //grd_ercensuspatcnt.mergeByFree(1, 5, 3, 5);
-
- var sSrchData = "";
- var sSrchData = model.getValue("/root/main/cond/fromdate" )+"▦"
- + model.getValue("/root/main/cond/todate" )+"▦"
- + model.getValue("/root/main/cond/srcflag" )+"▦"
- + model.getValue("/root/main/cond/chngdateyn")+"▦"
- + "▩";
-
- model.removenode("/root/send");
- // model.removeNodeset("/root/main/erdayiycesussection/ercensusinsucnt");
- // model.removeNodeset("/root/main/erdayiycesussection/ercensuspatlinfo");
- model.makeValue("/root/send/cond", sSrchHeader + sSrchData);
-
- submit("TRMNE01302");
-
- //응급실 memo 사용 여부에 화면 처리
- if(MemoUseYn == "Y"){
- grd_patlist.colHidden(grd_patlist.colRef("intype")) = false;
- grd_patlist.colHidden(grd_patlist.colRef("pos")) = false;
- grd_patlist.colHidden(grd_patlist.colRef("smntdesc")) = false;
- grd_patlist.colHidden(grd_patlist.colRef("skilfact")) = false;
- grd_patlist.colHidden(grd_patlist.colRef("deptuser")) = false;
- grd_patlist.colHidden(grd_patlist.colRef("memo")) = true;
- }
-
- grd_patlist.rebuildStyle();
- grd_patlist.resizeCells();
- for(var i = 1 ; i <= grd_patlist.rows ; i ++){
- if(grd_patlist.valueMatrix( i , grd_patlist.colRef("chostimetype")) == "Y"){
- grd_patlist.rowstyle(i, "data", "background-color") = "#999999";
- }
- }
-
- model.refresh();
- }
- /**
- * @group :
- * @ver : 2007.07.12
- * @by : 양천덕
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : 메모 등록 환자 조회
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fSearchPatMemo(){
- var sSrchHeader = "fromdate▦todate▦srcflag▦chngdateyn▦memoflag▩";
-
- if(model.getValue("/root/main/cond/chngdateyn") == "Y"){
-
- var sSrchData = model.getValue("/root/main/cond/fromdate" )+"▦"
- + model.getValue("/root/main/cond/todate" )+"▦"
- + model.getValue("/root/main/cond/srcflag" )+"▦"
- + model.getValue("/root/main/cond/chngdateyn" )+"▦"
- + "▩";
-
- model.removenode("/root/send");
- //model.removeNodeset("/root/main/erdailycensuslist/ercensuspatcnt");
- model.makeValue("/root/send/cond", sSrchHeader + sSrchData);
-
- submit("TRMNE01301", false);
- model.setValue("/root/main/cond/chngdateyn","N");
- }
-
-
- //grd_ercensuspatcnt.mergeByFree(1, 4, 3, 4);
- //grd_ercensuspatcnt.mergeByFree(1, 5, 3, 5);
-
- var sSrchData = "";
- var sSrchData = model.getValue("/root/main/cond/fromdate" )+"▦"
- + model.getValue("/root/main/cond/todate" )+"▦"
- + model.getValue("/root/main/cond/srcflag" )+"▦"
- + model.getValue("/root/main/cond/chngdateyn")+"▦"
- + "Y" + "▩";
-
- model.removenode("/root/send");
- // model.removeNodeset("/root/main/erdayiycesussection/ercensusinsucnt");
- // model.removeNodeset("/root/main/erdayiycesussection/ercensuspatlinfo");
- model.makeValue("/root/send/cond", sSrchHeader + sSrchData);
-
- submit("TRMNE01302");
-
- //응급실 memo 사용 여부에 화면 처리
- if(MemoUseYn == "Y"){
- grd_patlist.colHidden(grd_patlist.colRef("intype")) = true;
- grd_patlist.colHidden(grd_patlist.colRef("pos")) = true;
- grd_patlist.colHidden(grd_patlist.colRef("smntdesc")) = true;
- grd_patlist.colHidden(grd_patlist.colRef("skilfact")) = true;
- grd_patlist.colHidden(grd_patlist.colRef("deptuser")) = true;
- grd_patlist.colHidden(grd_patlist.colRef("memo")) = false;
- }
-
- grd_patlist.rebuildStyle();
- grd_patlist.resizeCells();
- for(var i = 1 ; i <= grd_patlist.rows ; i ++){
- if(grd_patlist.valueMatrix( i , 11) == "Y"){
- grd_patlist.rowstyle(i, "data", "background-color") = "#999999";
- }
- }
-
- model.refresh();
- }
- /**
- * @group :
- * @ver : 2010.01.07
- * @by :
- * @---------------------------------------------------
- * @type : function
- * @access : public
- * @desc : grd_dschpatlist 엑셀저장
- * @param :
- * @return :
- * @---------------------------------------------------
- */
- function fSaveExcel(){
- var excelname = "EMC Daily census_("+model.getValue("/root/main/cond/fromdate")+"_"+model.getValue("/root/main/cond/srcflag")+")";
- var fileName = window.fileDialog("save", ",", false, excelname, "xls", "All Files (*.*)|*.*|Excel Files(*.xls)|*.xls");
- if (fileName != ""){
- grd_patlist.saveExcel(fileName, "SheetName", true, true, "", "", false);
- }
- }
|