SMMND02200.js 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152
  1. /*
  2. 복막투석 History 관리(SMMND02200.xrw - JScript )
  3. - Version :
  4. 1) : Ver.1.00.01
  5. */
  6. //** 전역변수 **//
  7. /**
  8. * @group :
  9. * @ver : 2007.06.15
  10. * @by : 김진아
  11. * @---------------------------------------------------
  12. * @type : function
  13. * @access : public
  14. * @desc : 화면 초기화
  15. * @param :
  16. * @return :
  17. * @---------------------------------------------------
  18. */
  19. function fDone(){
  20. //**상단정보 초기화**//
  21. delPatientInfos(); //화면상단정보 삭제
  22. setGlobalVariable("paminfo", ""); //원무정보 reset
  23. //**그리드 초기화**//
  24. model.removeNodeset("/root/main/pdmatnpatlist"); // 복막투석 유지환자 리스트
  25. model.removeNodeset("/root/main/pdhistlist"); // 복막투석 History 리스트
  26. // 조회일자 설정
  27. model.makeValue("/root/main/condition/srchtodd", getCurrentDate()); // 현재일자
  28. model.makeValue("/root/main/condition/srchfromdd", getDateCalc(getCurrentDate(), 365)); // 365일 이전 일자
  29. model.refresh();
  30. //**공통코드 가져오기**//
  31. zbcfGetCodeList( new Array ( "M0130" // APD종류
  32. , "M0131" // 복막투석액 회사명
  33. , "M0132" // 복막투석액
  34. )
  35. , new Array ( "/root/init/M0130list" // APD종류
  36. , "/root/init/M0131list" // 복막투석액 회사명
  37. , "/root/init/M0132list" // 복막투석액
  38. )
  39. );
  40. }
  41. /**
  42. * @group :
  43. * @ver : 2007.06.15
  44. * @by : 김진아
  45. * @---------------------------------------------------
  46. * @type : function
  47. * @access : public
  48. * @desc : 복막투석 유지환자 리스트 조회
  49. * @param :
  50. * @return :
  51. * @---------------------------------------------------
  52. */
  53. function fSrchPDMatnPatList(){
  54. model.removenode("/root/send");
  55. model.makeNode("/root/send");
  56. model.makeValue("/root/send/reqdata/pid", model.getValue("/root/main/condition/pid"));
  57. model.makeValue("/root/send/reqdata/dialflag", "P"); // 투석구분 (P:복막)
  58. model.removeNodeset("/root/main/pdmatnpatlist/pdmatnpatinfo"); // 복막투석 유지환자 리스트 초기화
  59. model.removeNodeset("/root/main/pdhistlist/pdhistinfo"); // 복막투석 History 리스트 초기화
  60. model.setValue("/root/main/condition/selpid" ,"");
  61. submit("TRMND02201");
  62. }
  63. /**
  64. * @group :
  65. * @ver : 2007.06.15
  66. * @by : 김진아
  67. * @---------------------------------------------------
  68. * @type : function
  69. * @access : public
  70. * @desc : 선택한 환자정보 설정 (복막투석 유지환자 리스트 더블클릭 시)
  71. * @param :
  72. * @return :
  73. * @---------------------------------------------------
  74. */
  75. function fGetPatInfo(){
  76. var iRow = grd_pdmatnpatinfo.row;
  77. var sSelPid = grd_pdmatnpatinfo.textmatrix(iRow, 1); // 등록번호
  78. model.setValue("/root/main/condition/selpid", sSelPid);
  79. // 조회조건 초기화
  80. model.setValue("/root/main/condition/srchflag", 1); // 조회구분 Default설정 (1:전체)
  81. model.makeValue("/root/main/condition/srchtodd", getCurrentDate()); // 조회일자 (현재일자)
  82. model.makeValue("/root/main/condition/srchfromdd", getDateCalc(getCurrentDate(), 365)); // 조회일자 (365일 이전 일자)
  83. // 유지환자 리스트 셀 색상 초기화 (white)
  84. for(var i=1; i<=grd_pdmatnpatinfo.rows; i++) {
  85. grd_pdmatnpatinfo.cellstyle("background-color", i, 1, i, 4) = "white";
  86. }
  87. // 선택 행 셀 색상 지정 #ffd9ff
  88. grd_pdmatnpatinfo.cellstyle("background-color", iRow, 1, iRow, 4) = "red";
  89. model.refresh();
  90. }
  91. /**
  92. * @group :
  93. * @ver : 2007.06.15
  94. * @by : 김진아
  95. * @---------------------------------------------------
  96. * @type : function
  97. * @access : public
  98. * @desc : 복막투석 Histoty 리스트 조회
  99. * @param :
  100. * @return :
  101. * @---------------------------------------------------
  102. */
  103. function fSrchPDHistList(){
  104. // 조회기간 체크
  105. if(model.getValue("/root/main/condition/srchfromdd") > model.getValue("/root/main/condition/srchtodd")) {
  106. messageBox("예약일자 기간이 올바르지 않습니다.", "E");
  107. var sCurrentDate = getCurrentDate(); // 현재일자
  108. model.setValue("/root/main/condition/srchfromdd", getDateCalc(sCurrentDate, 365));
  109. model.setValue("/root/main/condition/srchtodd" , sCurrentDate);
  110. model.refresh();
  111. }
  112. model.removenode("/root/send");
  113. model.makeNode("/root/send");
  114. model.makeValue("/root/send/reqdata/pid", model.getValue("/root/main/condition/selpid"));
  115. model.makeValue("/root/send/reqdata/srchfromdd", model.getValue("/root/main/condition/srchfromdd"));
  116. model.makeValue("/root/send/reqdata/srchtodd", model.getValue("/root/main/condition/srchtodd"));
  117. model.makeValue("/root/send/reqdata/srchflag", model.getValue("/root/main/condition/srchflag"));
  118. model.removeNodeset("/root/main/pdhistlist/pdhistinfo");
  119. // 유지환자 리스트 셀 색상 초기화 (white)
  120. for(var i=1; i<=grd_pdmatnpatinfo.rows; i++) {
  121. grd_pdmatnpatinfo.cellstyle("background-color", i, 1, i, 4) = "white";
  122. }
  123. submit("TRMND02202");
  124. }
  125. function fUseridPopup(pPath, pNodeID, pNodeNM, pNodeRrgsNo1, pNodeRrgsNo2, pDOC) {
  126. model.removeNodeset("/root/properties/parameters/SendData/SendDatavalue");
  127. modal("SMMNE03700", 1, event.screenX-100, event.screenY-100, "SMMNE03700", pPath+pNodeID, "/root/init/searchitem");
  128. var pParam = model.getValue("/root/properties/parameters/SendData/SendDatavalue");
  129. var pParamValue = pParam.split("|");
  130. model.setValue(pPath+pNodeID, pParamValue[0]);
  131. ipt_pid.refresh();
  132. }