SPAAA03100_직책처리.xrw 8.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232
  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>직책처리</xhtml:title>
  6. <model id="model1">
  7. <instance id="instance1">
  8. <root xmlns="">
  9. <send>
  10. <savedata/>
  11. </send>
  12. <main>
  13. <jobsource>
  14. <voluntrid/>
  15. <holijobrespflag/>
  16. <fromdd/>
  17. <todd/>
  18. <holicd/>
  19. <jobrespcd/>
  20. <holijobrem/>
  21. <status/>
  22. </jobsource>
  23. <returnsts>
  24. <statusinfo>
  25. <restatus/>
  26. <voluntrid/>
  27. <actstatflag/>
  28. <restatusdd/>
  29. </statusinfo>
  30. </returnsts>
  31. </main>
  32. <init>
  33. <comcd/>
  34. </init>
  35. <hidden>
  36. <init>
  37. <comcd/>
  38. </init>
  39. </hidden>
  40. </root>
  41. </instance>
  42. <script type="javascript" ev:event="xforms-ready">
  43. <![CDATA[
  44. fInit();
  45. ]]>
  46. </script>
  47. <submission id="TRZBC00101" mediatype="application/x-www-form-urlencoded" method="post"/>
  48. <submission id="TRZBC00102" mediatype="application/x-www-form-urlencoded" method="post"/>
  49. <submission id="TRZBC00105" mediatype="application/x-www-form-urlencoded" method="post" replace="instance"/>
  50. <submission id="TXAAA02701" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/savedata" resultref="/root/main/returnsts"/>
  51. </model>
  52. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  53. <script type="javascript" src="../../../com/commonweb/js/utilHelper.js"/>
  54. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  55. <script type="javascript" src="../../../com/commonweb/js/stringHelper.js"/>
  56. <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
  57. <script type="javascript" src="../../../com/basiccodeweb/js/ZBC001.js"/>
  58. </xhtml:head>
  59. <script type="javascript">
  60. <![CDATA[
  61. // 초기값
  62. function fInit()
  63. {
  64. /*if (checkOpener()) {
  65. var benfdd = opener.javascript.getParameter("benfdd");
  66. var posteam1 = opener.javascript.getParameter("posteam1");
  67. var posteam2 = opener.javascript.getParameter("posteam2");
  68. } else {
  69. messageBox("상위화면이 변경되어 데이터를 전달할 수 ", "I004");
  70. }
  71. // 공통코드 셋팅
  72. zbcfGetCodeList(new Array("A0359", "A0360", "A0364"), new Array( "/root/init/posteam1", "/root/init/posteam2", "/root/init/benfcd") , true);
  73. //화면 오픈시 간병인명에 이름 셋팅
  74. //alert(sinursnm);
  75. model.setValue("/root/main/benfinfo/benfdd",benfdd);
  76. model.setValue("/root/main/benfinfo/posteam1",posteam1);
  77. model.setValue("/root/main/benfinfo/posteam2",posteam2);
  78. model.refresh(); */
  79. //zbcfGetCodeList( new Array("A0512"), new Array("/root/hidden/init/comcd") ); // 관계코드 설정
  80. // 공통코드 셋팅
  81. zbcfGetCodeList(new Array("A0504"), new Array( "/root/hidden/init/comcd") , true);
  82. model.refresh();
  83. }
  84. //확인
  85. function fSendParam()
  86. {
  87. var fromdd=model.getValue("/root/main/jobsource/fromdd"); //직책임명일
  88. var todd=model.getValue("/root/main/jobsource/todd"); //직책해지일
  89. if(model.getValue("/root/main/jobsource/fromdd")=="")
  90. {
  91. //저장시 직책임명일이 비어있으면
  92. messageBox("직책임명일은","I003");
  93. return;
  94. }
  95. if(model.getValue("/root/main/jobsource/todd")=='')
  96. { //저장시 직책해지일이 비어있으면
  97. messageBox("직책해지일은","I003");
  98. return;
  99. }
  100. if(model.getValue("/root/main/jobsource/jobrespcd")=='')
  101. { //저장시 직책구분이 비어있으면
  102. messageBox("직책구분은","I003");
  103. return;
  104. }
  105. if(todd<fromdd)
  106. { // 직책임명일이 직책해지일보다 빠른 날짜로 선택시
  107. messageBox("직책해지일이 직책임명일보다 작을 수","I004");
  108. return;
  109. }
  110. model.removeNodeset("/root/send/savedata");
  111. model.makeNode("/root/send/savedata");
  112. model.copyNode("/root/send/savedata","/root/main/jobsource");
  113. if(submit("TXAAA02701")==true)
  114. {
  115. if(model.getValue("/root/main/returnsts/statusinfo/restatus")=="J") // 휴가 구간이 겹칠 때
  116. {
  117. messageBox("직책 구간이","E006");
  118. return;
  119. }
  120. if(model.getValue("/root/main/returnsts/statusinfo/restatus")=="D") // 활동기간 정보가 존재 하지 않을 때
  121. {
  122. messageBox("활동기간 정보가","I004");
  123. return;
  124. }
  125. else
  126. {
  127. messageBox("직책 등록 처리가","I002");
  128. opener.model.makeValue("/root/jobsource/status","u");
  129. opener.model.makeValue("/root/jobsource/reflag","c"); // 처리되었다는 의미 플래그 C저장
  130. opener.model.refresh();
  131. window.close();
  132. }
  133. }
  134. }
  135. function fDelJob()
  136. {
  137. var btn=messageBox("직책내역을","Q001");
  138. if(btn=='6')
  139. {
  140. if(model.getValue("/root/main/jobsource/status")=="i") // 등록을 위해 팝업창을 열었을 경우에는 삭제할 수 없다.
  141. {
  142. messageBox("삭제할 직책 처리 내역이","I004");
  143. return;
  144. }
  145. model.makeValue("/root/main/jobsource/status","d");
  146. model.removeNodeset("/root/send/savedata");
  147. model.makeNode("/root/send/savedata");
  148. model.copyNode("/root/send/savedata","/root/main/jobsource");
  149. if(submit("TXAAA02701")==true)
  150. {
  151. messageBox("직책 등록 삭제가","I002");
  152. opener.model.removeNodeset("/root/main/jobsource"); // 갖고 있는 값 초기화
  153. opener.model.makeValue("/root/jobsource/reflag","c"); // 처리되었다는 의미 플래그 C저장
  154. opener.model.refresh();
  155. window.close();
  156. }
  157. }
  158. else if(btn=='7')
  159. {
  160. return;
  161. }
  162. }
  163. ]]>
  164. </script>
  165. <xhtml:body pagewidth="465" pageheight="132" guideline="1,500;" style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
  166. <group id="grp_btn" scroll="auto" style="left:0px; top:105px; width:449px; height:27px; ">
  167. <line id="line32" class="line_6" style="x1:0px; y1:0px; x2:448px; y2:0px; "/>
  168. <button id="btn_cancel" class="btn4_letter2" style="left:330px; top:5px; width:56px; height:22px; ">
  169. <caption>삭제</caption>
  170. <script type="javascript" ev:event="DOMActivate">
  171. <![CDATA[
  172. //opener.javascript.setParameter("flag", "N");
  173. fDelJob();
  174. ]]>
  175. </script>
  176. </button>
  177. <button id="button1" class="btn4_letter2" style="left:390px; top:5px; width:56px; height:22px; ">
  178. <caption>취소</caption>
  179. <script type="javascript" ev:event="DOMActivate">
  180. <![CDATA[
  181. //opener.javascript.setParameter("flag", "N");
  182. //opener.model.makeValue("/root/jobsource/status","r"); //취소 상태값인 r 저장
  183. //opener.model.removeNodeset("/root/main/jobsource"); // 갖고 있는 값 초기화
  184. model.close();
  185. ]]>
  186. </script>
  187. </button>
  188. <button id="button2" class="btn4_letter2" style="left:269px; top:4px; width:56px; height:22px; ">
  189. <caption>저장</caption>
  190. <script type="javascript" ev:event="DOMActivate">
  191. <![CDATA[
  192. fSendParam();
  193. ]]>
  194. </script>
  195. </button>
  196. </group>
  197. <group id="group1" scroll="auto" style="left:0px; top:0px; width:449px; height:105px; ">
  198. <line id="line8" class="line_2" style="x1:0px; y1:22px; x2:448px; y2:22px; "/>
  199. <line id="line1" class="line_2" style="x1:0px; y1:46px; x2:448px; y2:46px; "/>
  200. <caption id="caption5" class="cell_1" style="left:0px; top:0px; width:85px; height:23px; vertical-align:middle; ">직책임명일</caption>
  201. <caption id="caption6" class="cell_1" style="left:0px; top:24px; width:85px; height:23px; vertical-align:middle; ">직책구분</caption>
  202. <caption id="caption7" class="cell_1" style="left:0px; top:48px; width:85px; height:53px; vertical-align:middle; ">비고</caption>
  203. <caption id="caption8" class="cell_1" style="left:220px; top:0px; width:85px; height:23px; vertical-align:middle; ">직책해지일</caption>
  204. <input id="ipt_benfdd" ref="/root/main/jobsource/fromdd" class="input_default" disabled="false" inputtype="date" style="left:88px; top:2px; width:130; height:19px; "/>
  205. <select1 id="cmb_benfcd" ref="/root/main/jobsource/jobrespcd" class="combo_default" appearance="minimal" style="left:88px; top:25px; width:130; height:19px; ">
  206. <choices>
  207. <itemset nodeset="/root/hidden/init/comcd/A0504">
  208. <label ref="cdnm"/>
  209. <value ref="cdid"/>
  210. </itemset>
  211. </choices>
  212. </select1>
  213. <textarea id="tar_rem" ref="/root/main/jobsource/holijobrem" maxlength="33" style="left:88px; top:48px; width:360px; height:53px; "/>
  214. <input id="input1" ref="/root/main/jobsource/todd" class="input_default" disabled="false" inputtype="date" style="left:308px; top:2px; width:130px; height:19px; "/>
  215. </group>
  216. </xhtml:body>
  217. </xhtml:html>