SPMNG00404_린넨공휴일업무관리.xrw 7.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188
  1. <?xml version="1.0" encoding="EUC-KR"?>
  2. <?xml-stylesheet href="../../../com/commonweb/css/common.css" type="text/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>린넨청구부서코드 HELP</xhtml:title>
  6. <model id="model1">
  7. <instance id="instance1">
  8. <root xmlns="">
  9. <main>
  10. <week>
  11. <week/>
  12. </week>
  13. <cond>
  14. <workdd/>
  15. </cond>
  16. </main>
  17. <target/>
  18. <init>
  19. </init>
  20. <send>
  21. </send>
  22. </root>
  23. </instance>
  24. <script type="javascript" ev:event="xforms-ready">
  25. <![CDATA[
  26. ipt_workdd.value = getCurrentDate();
  27. model.refresh();
  28. fSetDate();
  29. fSearch();
  30. ]]>
  31. </script>
  32. <script type="javascript">
  33. <![CDATA[
  34. function fSearch(){
  35. model.removeNodeset("/root/send/reqdata");
  36. model.makeValue("/root/send/reqdata/year" , model.getValue("/root/main/cond/year"));
  37. model.makeValue("/root/send/reqdata/month" , model.getValue("/root/main/cond/month"));
  38. model.makeValue("/root/send/reqdata/perfdeptcd", model.getValue("/root/main/cond/perfdeptcd"));
  39. var rtnval = submit("TRMNG00410");
  40. if(rtnval == true){
  41. fMakeCalendar();
  42. }
  43. grd_calendar.dataheight = 58;
  44. }
  45. function fMakeCalendar(){
  46. model.removeNodeset("/root/main/week/week");
  47. model.refresh();
  48. grd_calendar.addRow(false, true);
  49. var row = 0;
  50. var col = 0;
  51. var patsum = 0;
  52. var totcnt = getNodeSetCnt("/root/main/lnschecal/lnschecal");
  53. for(var i = 1; i <= totcnt ; i++){
  54. row = model.getValue("/root/main/lnschecal/lnschecal[" + i + "]/week");
  55. col = model.getValue("/root/main/lnschecal/lnschecal[" + i + "]/day") - 1;
  56. dutflag = model.getValue("/root/main/lnschecal/lnschecal[" + i + "]/dutflag");
  57. cdnm = model.getValue("/root/main/lnschecal/lnschecal[" + i + "]/cdnm");
  58. if(dutflag == 4){ //토
  59. grd_calendar.cellstyle("color", row, col) = "#0000FF";
  60. }else if(dutflag == 8){ //일
  61. grd_calendar.cellstyle("color", row, col) = "#FF0000";
  62. }else{ //휴일
  63. grd_calendar.cellstyle("color", row, col) = "#000000";
  64. }
  65. grd_calendar.valueMatrix(row, col) = i + "\n" + cdnm ;
  66. if(col == 6){
  67. grd_calendar.addRow(false, true);
  68. }
  69. }
  70. grd_calendar.rebuild();
  71. }
  72. function fSetDate() {
  73. var workdd = ipt_workdd.value;
  74. var year = workdd.substr(0, 4);
  75. var month = workdd.substr(4, 2);
  76. model.makeValue("/root/main/cond/year", year);
  77. model.makeValue("/root/main/cond/month", month);
  78. }
  79. ]]>
  80. </script>
  81. <submission id="TRMNG00410" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/reqdata" resultref="/root/main/lnschecal"/>
  82. <submission id="TXMNG00406" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/savedata" resultref="/root/temp"/>
  83. </model>
  84. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  85. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  86. <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
  87. <script type="javascript" src="../../../mis/miscommonweb/js/MIS.js"/>
  88. <script type="javascript" src="../../../emr/prcpmngtweb/js/MMO001.js"/>
  89. </xhtml:head>
  90. <xhtml:body pagewidth="560" pageheight="520" guideline="1,624;2,561;" style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
  91. <group id="group3" scroll="auto" style="left:0px; top:0px; width:535px; height:465px; ">
  92. <group id="group2" style="left:0px; top:0px; width:532px; height:30px; ">
  93. <shape id="roundrect1" class="roundrect_search" appearance="roundrect" style="left:0px; top:0px; width:529px; height:29px; "/>
  94. <button id="btn_search" class="btn1_letter2" style="left:459px; top:4px; width:56px; height:22px; ">
  95. <caption>조회</caption>
  96. <script type="javascript" ev:event="DOMActivate">
  97. <![CDATA[
  98. fSearch();
  99. ]]>
  100. </script>
  101. </button>
  102. <line id="line13" class="line_4" style="x1:450px; y1:0px; x2:450px; y2:29px; border-color:#ffe4bb; border-left-style:solid; "/>
  103. <caption id="caption2" class="search_name" style="left:10px; top:6px; width:86px; height:17px; ">조회조건:</caption>
  104. <input id="ipt_workdd" ref="/root/main/cond/workdd" class="input_default" inputtype="date" maxlength="6" style="left:100px; top:5px; width:105px; height:15px; ">
  105. <script type="javascript" ev:event="xforms-value-changed">
  106. <![CDATA[
  107. fSetDate();
  108. ]]>
  109. </script>
  110. </input>
  111. </group>
  112. <caption id="caption1" class="tit_2" style="left:5px; top:50px; width:95px; height:14px; ">월별 현황</caption>
  113. <line id="line1" class="line_1" style="x1:0px; y1:70px; x2:529px; y2:70px; "/>
  114. <datagrid id="grd_calendar" nodeset="/root/main/week/week" allowbigselection="false" allowselection="true" allowuserresize="false" caption="일^월^화^수^목^금^토" colsep="^" colwidth="75, 75, 75, 75, 75, 75, 75" dataheight="50" defaultrows="7" extendlastcol="scroll" mergecellsfixedrows="bycolrec" rowheight="30" rowsep="|" selectionmode="free" style="left:0px; top:75px; width:529px; height:378px; font-size:13pt; ">
  115. <col ref="sun"/>
  116. <col ref="mon"/>
  117. <col ref="tue"/>
  118. <col ref="wed"/>
  119. <col ref="thu"/>
  120. <col ref="fri"/>
  121. <col ref="sat"/>
  122. <script type="javascript" ev:event="onclick">
  123. <![CDATA[
  124. ]]>
  125. </script>
  126. </datagrid>
  127. </group>
  128. <group id="group1" scroll="auto" style="left:0px; top:465px; width:529px; height:30px; ">
  129. <button id="btn_sav" class="btn4_letter2" style="left:346px; top:2px; width:56px; height:22px; ">
  130. <caption>지정</caption>
  131. <script type="javascript" ev:event="DOMActivate">
  132. <![CDATA[
  133. var week = grd_calendar.row;
  134. var day = grd_calendar.col + 1;
  135. if(grd_calendar.cellStyle("color", grd_calendar.row, grd_calendar.col) == "#ff0000" ) {
  136. basedd = model.getValue("/root/main/lnschecal/lnschecal[week = '" + week + "' and day = '" + day + "']/basedd");
  137. model.makeValue("/root/send/savedata/basedd", basedd);
  138. model.makeValue("/root/send/savedata/saveflag", "I");
  139. if (submit("TXMNG00406")) {
  140. alert("업무일로 지정되었습니다.");
  141. }
  142. } else {
  143. alert("지정일이 공휴일인지 확인하십시오. 공휴일만 지정할 수 있습니다.");
  144. }
  145. fSearch();
  146. ]]>
  147. </script>
  148. </button>
  149. <button id="btn_del" class="btn4_letter2" style="left:406px; top:2px; width:56px; height:22px; ">
  150. <caption>취소</caption>
  151. <script type="javascript" ev:event="DOMActivate">
  152. <![CDATA[
  153. var week = grd_calendar.row;
  154. var day = grd_calendar.col + 1;
  155. if( grd_calendar.cellStyle("color", grd_calendar.row, grd_calendar.col) == "#ff0000" ) {
  156. basedd = model.getValue("/root/main/lnschecal/lnschecal[week = '" + week + "' and day = '" + day + "']/basedd");
  157. model.makeValue("/root/send/savedata/basedd", basedd);
  158. model.makeValue("/root/send/savedata/saveflag", "D");
  159. if (submit("TXMNG00406")) {
  160. alert("공휴일로 지정되었습니다.");
  161. }
  162. }else {
  163. alert("지정일이 공휴일인지 확인하십시오. 공휴일만 지정할 수 있습니다.");
  164. }
  165. fSearch();
  166. ]]>
  167. </script>
  168. </button>
  169. <button id="btn_cancel" class="btn4_letter2" style="left:465px; top:2px; width:56px; height:22px; ">
  170. <caption>닫기</caption>
  171. <script type="javascript" ev:event="DOMActivate">
  172. <![CDATA[
  173. window.close();
  174. ]]>
  175. </script>
  176. </button>
  177. </group>
  178. </xhtml:body>
  179. </xhtml:html>