SPMNP03000.js 4.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123
  1. /*---------------------------------------------------------------------
  2. 미불출, 응급불출 (SPMNP03100.xfm SPMNP03200.xfm - JScript )
  3. - Version :
  4. 1) : Ver.1.00.01
  5. : Create By 김 진 명
  6. : 2009.03.25
  7. ----------------------------------------------------------------------*/
  8. /* --------------------------------------------------*/
  9. /* type : function */
  10. /* access : public */
  11. /* desc : 초기화 */
  12. /* param : */
  13. /* return : */
  14. /* --------------------------------------------------*/
  15. function fInit(pFlag) {
  16. model.setValue("/root/main/cond/openflag", opener.javascript.getParameter("openflag"));
  17. model.removenode("/root/send");
  18. if( pFlag == "E" ) {
  19. model.removenode("/root/main/reqerlist");
  20. grd_erlist.explorerbar = "sort";
  21. grd_erlist.fixedcellcheckbox(0,3) = true;
  22. }else {
  23. model.removenode("/root/main/undelivelist");
  24. grd_undelivelist.explorerbar = "sort";
  25. grd_undelivelist.fixedcellcheckbox(0,3) = true;
  26. }
  27. model.setValue("/root/main/cond/fromdd", getCurrentDate().substr(0, 8));
  28. submit("TRMNP03004", false);
  29. addComboItem("cmb_rosette", "전 체", "", "above" );
  30. model.removenode("/root/send");
  31. model.makeNode("/root/send");
  32. model.makeValue("/root/send/opcnfmdd" ,model.getValue("/root/main/cond/fromdd") );
  33. model.makeValue("/root/send/rosette" ,model.getValue("/root/main/cond/oprosette"));
  34. submit("TRMNP03002", false); // 수술실코드 가져오기
  35. addComboItem("cmb_oproomlist","전체","","above");
  36. model.refresh();
  37. }
  38. /*--------------------------------------------------*/
  39. /*type : function */
  40. /*access : public */
  41. /*desc : 응급 요청 리스트 조회 */
  42. /*param : */
  43. /*return : */
  44. /*--------------------------------------------------*/
  45. function fSearch() {
  46. model.removenode("/root/send");
  47. model.makeNode("/root/send/reqdata");
  48. model.copyNode("/root/send/reqdata", "/root/main/cond");
  49. submit("TRMNP03005");
  50. }
  51. /*--------------------------------------------------*/
  52. /*type : function */
  53. /*access : public */
  54. /*desc : 미불출 리스트 조회 */
  55. /*param : */
  56. /*return : */
  57. /*--------------------------------------------------*/
  58. function fUnDeliveSearch() {
  59. model.removenode("/root/send");
  60. model.makeNode("/root/send/reqdata");
  61. model.copyNode("/root/send/reqdata", "/root/main/cond");
  62. submit("TRMNP03006");
  63. }
  64. /*--------------------------------------------------*/
  65. /*type : function */
  66. /*access : public */
  67. /*desc : 미불출, 응급청구 불출 */
  68. /*param : S:미불출, E:응급청구 */
  69. /*return : */
  70. /*--------------------------------------------------*/
  71. function fDeliveCnfm(pFlag) {
  72. var chkflag, goodcd, allsizespecid, oprsrvno, iRows, nodePath, oproomcd, undeliveresn, deliveqty;
  73. var cnt = 0;
  74. var delivelist = "m▦goodcd▦allsizespecid▦oproomcd▦oprsrvno▦undeliveresn▦deliveqty";
  75. if( pFlag == "S" ) {
  76. iRows = grd_undelivelist.rows;
  77. nodePath = "/root/main/undelivelist";
  78. }else {
  79. iRows = grd_erlist.rows;
  80. nodePath = "/root/main/reqerlist";
  81. }
  82. for(var i = 1; i <= iRows; i++ ) {
  83. chkflag = model.getValue(nodePath + "[" + i + "]/chkflag");
  84. goodcd = model.getValue(nodePath + "[" + i + "]/goodcd");
  85. allsizespecid = model.getValue(nodePath + "[" + i + "]/allsizespecid");
  86. oprsrvno = model.getValue(nodePath + "[" + i + "]/oprsrvno");
  87. oproomcd = model.getValue(nodePath + "[" + i + "]/oproomcd");
  88. undeliveresn = model.getValue(nodePath + "[" + i + "]/undeliveresn");
  89. deliveqty = model.getValue(nodePath + "[" + i + "]/deliveqty");
  90. if( chkflag == "true" ) {
  91. delivelist = delivelist + "▩" + "U" + "▦" + goodcd + "▦" + allsizespecid + "▦" + oproomcd + "▦" + oprsrvno + "▦" + undeliveresn + "▦" + deliveqty;
  92. cnt++
  93. }
  94. }
  95. if( cnt > 0 ) {
  96. model.removenode("/root/send");
  97. model.makeNode("/root/send/reqdata");
  98. model.copyNode("/root/send/reqdata", "/root/main/cond");
  99. model.makeValue("/root/send/savedata", delivelist);
  100. //submit("TXMNP03006");
  101. }else {
  102. messageBox("선택하신게 없습니다.!", "E000");
  103. }
  104. }