SMMRD01900_지표관리.xrw 7.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177
  1. <?xml version="1.0" encoding="EUC-KR"?>
  2. <?xml-stylesheet type="text/css" href="../../../com/commonweb/css/common.css" ?>
  3. <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">
  4. <xhtml:head>
  5. <xhtml:title>지표관리(Master관리)</xhtml:title>
  6. <model id="model1">
  7. <instance id="instance1">
  8. <root xmlns="">
  9. <main>
  10. <indxlist>
  11. <rows>
  12. <kpicd/>
  13. <instcd/>
  14. <indxid/>
  15. <dispseq/>
  16. <itemnm/>
  17. <indxfromdd/>
  18. <indxtodd/>
  19. <indxappflag/>
  20. <rem/>
  21. </rows>
  22. </indxlist>
  23. </main>
  24. <temp>
  25. </temp>
  26. <hidden>
  27. </hidden>
  28. <send>
  29. <indxlist/>
  30. </send>
  31. </root>
  32. </instance>
  33. <script type="javascript" ev:event="xforms-ready">
  34. <![CDATA[
  35. model.removeNodeset("/root/main/indxlist/rows");
  36. submit("TRMRD01900");
  37. model.refresh();
  38. ]]>
  39. </script>
  40. <submission id="TXMRD01900" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/indxlist" resultref="/root/main/indxlist"/>
  41. <submission id="TRMRD01900" mediatype="application/x-www-form-urlencoded" method="post" resultref="/root/main/indxlist"/>
  42. </model>
  43. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  44. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  45. <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
  46. <script type="javascript" src="../../../emr/dschanalyweb/js/SMMRD01700.js"/>
  47. </xhtml:head>
  48. <xhtml:body pagewidth="630" pageheight="320" style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
  49. <caption id="caption1" class="tit_2" style="left:7px; top:19px; width:153px; height:14px; ">지표관리(Master관리)</caption>
  50. <line id="line1" class="line_1" style="x1:2px; y1:34px; x2:612px; y2:34px; "/>
  51. <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:147px; height:14px; ">지표관리</caption>
  52. <line id="line4" class="line_3" style="x1:2px; y1:292px; x2:612px; y2:292px; "/>
  53. <button id="btn_save" class="btn4_letter2" visibility="visible" style="left:555px; top:295px; width:56px; height:22px; ">
  54. <caption>저장</caption>
  55. <script type="javascript" ev:event="DOMActivate">
  56. <![CDATA[
  57. var dispSeqSameRow = grd_indxlist.findRow("", 1, grd_indxlist.colRef("dispseq"));
  58. var itemNmSameRow = grd_indxlist.findRow("", 1, grd_indxlist.colRef("itemnm"));
  59. if(itemNmSameRow > 0){
  60. messageBox("항목명은","I003");
  61. return;
  62. }
  63. model.setValue("/root/send/indxlist", getGridUpdateData(grd_indxlist));
  64. //alert(model.getValue("/root/send/indxlist"))
  65. model.removeNodeset("/root/main/indxlist/rows");
  66. submit("TXMRD01900");
  67. ]]>
  68. </script>
  69. </button>
  70. <button id="button1" class="btn2_letter3" style="left:515px; top:13px; width:53px; height:19px; ">
  71. <caption>행추가</caption>
  72. <script type="javascript" ev:event="DOMActivate">
  73. <![CDATA[
  74. grd_indxlist.addRow();
  75. var curRow = grd_indxlist.row;
  76. model.setValue("/root/main/indxlist/rows["+ curRow +"]/indxfromdd", getCurrentDate());
  77. model.setValue("/root/main/indxlist/rows["+ curRow +"]/indxtodd", "99991231");
  78. model.setValue("/root/main/indxlist/rows["+ curRow +"]/indxappflag", "Y");
  79. ]]>
  80. </script>
  81. </button>
  82. <button id="button2" class="btn2_letter2" style="left:570px; top:13px; width:42px; height:19px; ">
  83. <caption>삭제</caption>
  84. <script type="javascript" ev:event="DOMActivate">
  85. <![CDATA[
  86. var msg = messageBox("선택한 행을 ","Q001");
  87. if(msg == "6"){
  88. deleteSelectedRows(grd_indxlist, true);
  89. }
  90. ]]>
  91. </script>
  92. </button>
  93. <datagrid id="grd_indxlist" nodeset="/root/main/indxlist/rows" caption="KPICD^기관코드^INDXID^순번^항목명^적용시작일^적용종료일^적용여부^비고" colsep="^" colwidth="0, 0, 0, 0, 162, 100, 100, 56, 149" defaultrows="0" mergecellsfixedrows="bycolrec" rowheader="update" rowsep="|" style="left:2px; top:41px; width:610px; height:249px; ">
  94. <col ref="kpicd" visibility="hidden"/>
  95. <col ref="instcd" visibility="hidden"/>
  96. <col ref="indxid" visibility="hidden"/>
  97. <col ref="dispseq" type="input" format="999"/>
  98. <col ref="itemnm" type="input"/>
  99. <col ref="indxfromdd" type="inputdate"/>
  100. <col ref="indxtodd" type="inputdate"/>
  101. <col checkvalue="Y,N" ref="indxappflag" type="checkbox"/>
  102. <col ref="rem" type="input"/>
  103. <script type="javascript" ev:event="xforms-value-changed">
  104. <![CDATA[
  105. var curRow = grd_indxlist.row;
  106. var itemnm = model.getValue("/root/main/indxlist/rows["+curRow+"]/itemnm");
  107. var dispseq = model.getValue("/root/main/indxlist/rows["+curRow+"]/dispseq");
  108. var indxfromdd = model.getValue("/root/main/indxlist/rows["+curRow+"]/indxfromdd");
  109. var indxtodd = model.getValue("/root/main/indxlist/rows["+curRow+"]/indxtodd");
  110. // if(grd_indxlist.col == grd_indxlist.colRef("dispseq")){
  111. // if(dispseq == ""){
  112. // messageBox("순번은","I003");
  113. // }
  114. // else{
  115. // var bfSameRow = grd_indxlist.findRow(dispseq, 1, grd_indxlist.colRef("dispseq"));
  116. // var aftSameRow = grd_indxlist.findRow(dispseq, curRow +1, grd_indxlist.colRef("dispseq"));
  117. // if(bfSameRow != curRow && bfSameRow > 0){
  118. // var msg = messageBox("동일한 순번이 있습니다. ","Q003");
  119. // if(msg != "6"){
  120. // model.setValue("/root/main/indxlist/rows["+curRow+"]/dispseq", "");
  121. // }
  122. // }
  123. // if(aftSameRow != curRow && aftSameRow > 0){
  124. // var msg = messageBox("동일한 순번이 있습니다. ","Q003");
  125. // if(msg != "6"){
  126. // model.setValue("/root/main/indxlist/rows["+curRow+"]/dispseq", "");
  127. // }
  128. // }
  129. // }
  130. // grd_indxlist.col =grd_indxlist.colRef("dispseq");
  131. // }
  132. if(grd_indxlist.col == grd_indxlist.colRef("itemnm")){
  133. if(itemnm == ""){
  134. messageBox("항목명은","I003");
  135. }
  136. else{
  137. var bfSameRow = grd_indxlist.findRow(itemnm, 1, grd_indxlist.colRef("itemnm"));
  138. var aftSameRow = grd_indxlist.findRow(itemnm, curRow +1, grd_indxlist.colRef("itemnm"));
  139. if(bfSameRow != curRow && bfSameRow > 0){
  140. var msg = messageBox("동일한 항목명이 있습니다. ","Q003");
  141. if(msg != "6"){
  142. model.setValue("/root/main/indxlist/rows["+curRow+"]/itemnm", "");
  143. }
  144. }
  145. if(aftSameRow != curRow && aftSameRow > 0){
  146. var msg = messageBox("동일한 항목명이 있습니다. ","Q003");
  147. if(msg != "6"){
  148. model.setValue("/root/main/indxlist/rows["+curRow+"]/itemnm", "");
  149. }
  150. }
  151. }
  152. grd_indxlist.col =grd_indxlist.colRef("itemnm");
  153. }
  154. if(grd_indxlist.col == grd_indxlist.colRef("indxfromdd") && indxfromdd == ""){
  155. messageBox("적용시작일은","I003");
  156. grd_indxlist.col = grd_indxlist.colRef("indxfromdd");
  157. }
  158. if(grd_indxlist.col == grd_indxlist.colRef("indxtodd") && indxtodd == ""){
  159. messageBox("적용종료일은","I003");
  160. grd_indxlist.col = grd_indxlist.colRef("indxtodd");
  161. }
  162. ]]>
  163. </script>
  164. </datagrid>
  165. </xhtml:body>
  166. </xhtml:html>