SMRPA07000_직급별경조사공제금액등록.xrw 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273
  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. <main>
  10. <congradeduamtlist>
  11. <baseym/>
  12. <dutplceinst/>
  13. <jobposcd/>
  14. <deduamt/>
  15. <cmt/>
  16. <jobposnm/>
  17. </congradeduamtlist>
  18. </main>
  19. <send>
  20. <search>
  21. <dutplceinst/>
  22. <baseym/>
  23. <baseamtsaveym/>
  24. </search>
  25. <savelist>
  26. <congradeduamtlist/>
  27. </savelist>
  28. </send>
  29. <init>
  30. <combo1>
  31. <label>교수</label>
  32. <value>1782</value>
  33. <label>부교수</label>
  34. <value>1784</value>
  35. <label>조교수</label>
  36. <value>1786</value>
  37. <label>전임강사</label>
  38. <value>1788</value>
  39. <label>조교</label>
  40. <value>1790</value>
  41. </combo1>
  42. </init>
  43. <temp/>
  44. <dataynlist>
  45. <baseamtsaveyn/>
  46. </dataynlist>
  47. </root>
  48. </instance>
  49. <script type="javascript" ev:event="xforms-ready">
  50. <![CDATA[
  51. misfGridInit(grd_congradeduamtlist);
  52. misfMsterDetailSet(grd_congradeduamtlist,null,"TRRPA07001","Y");
  53. btn_save.disabled = !(checkAuth("X"));
  54. // 공통코드 바인딩 silver
  55. misfComboComCdList('Z0007', cmb_dutplceinst);
  56. // misfComboCopyItemSet(cmb_dutplceinst, "", grd_congradeduamtlist, "dutplceinst");
  57. var dutplceinst = '103';
  58. if (getUserInfo("dutplceinstcd") == "017") {
  59. dutplceinst = '017';
  60. }
  61. cmb_dutplceinst.value=dutplceinst;
  62. var curDate = getCurrentDate().toDate();
  63. model.setValue("/root/send/search/baseym", curDate.getDateFormat('YYYYMM'));
  64. btn_search.dispatch("DOMActivate");
  65. ]]>
  66. </script>
  67. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  68. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  69. <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
  70. <script type="javascript" src="../../../mis/miscommonweb/js/MIS.js"/>
  71. <script type="javascript">
  72. <![CDATA[
  73. // 화면 open시와 초기화 버튼 클릭시 화면 초기화 기능을 수행한다.
  74. function fInitialize() {
  75. grd_congradeduamtlist.refresh();
  76. model.removeNodeset("/root/main/congradeduamtlist");
  77. model.refresh();
  78. }
  79. function fsaveCheckValue(){
  80. var iInsCnt = 0;
  81. var iDupCnt = 0;
  82. var bDel = false;
  83. var icolidx=grd_congradeduamtlist.colRef("baseym");
  84. var icolidx1=grd_congradeduamtlist.colRef("dutplceinst");
  85. var icolidx2=grd_congradeduamtlist.colRef("jobposcd");
  86. for(var i=0; i<grd_congradeduamtlist.rows; i++)
  87. {
  88. if(grd_congradeduamtlist.rowStatus(i) == 1 || grd_congradeduamtlist.rowStatus(i) == 3)
  89. {
  90. iInsCnt = i;
  91. break;
  92. }
  93. }
  94. for(var i=iInsCnt; i<grd_congradeduamtlist.rows; i++)
  95. {
  96. for(var j=1; j<i; j++)
  97. {
  98. if(grd_congradeduamtlist.valueMatrix(i, icolidx) == grd_congradeduamtlist.valueMatrix(j, icolidx) && grd_congradeduamtlist.valueMatrix(i, icolidx1) == grd_congradeduamtlist.valueMatrix(j, icolidx1) && grd_congradeduamtlist.valueMatrix(i, icolidx2) == grd_congradeduamtlist.valueMatrix(j, icolidx2))
  99. {
  100. if(grd_congradeduamtlist.rowStatus(i) == 1 || grd_congradeduamtlist.rowStatus(i) == 3)
  101. { var ret= messageBox("중복된 행을 삭제", "Q001");
  102. if (ret != 6) { // not OK
  103. bDel = false;
  104. return false;
  105. }else{
  106. grd_congradeduamtlist.deleteItem(i);
  107. iDupCnt++;
  108. bDel = true;
  109. }
  110. }
  111. }
  112. }
  113. if(bDel)
  114. {
  115. bDel = false;
  116. i--;
  117. }
  118. }
  119. if(iDupCnt > 0)
  120. {
  121. messageBox("[ " + iDupCnt + " ]" + " 건의 중복된 행이 삭제", "I001");
  122. }
  123. return true;
  124. }
  125. ]]>
  126. </script>
  127. <submission id="TRRPA07001" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/search" resultref="/root/main/congradeduamtlist"/>
  128. <submission id="TXRPA07001" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/savelist" resultref="/root/temp"/>
  129. <submission id="TRRPA07102" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/search" resultref="/root/dataynlist"/>
  130. </model>
  131. </xhtml:head>
  132. <xhtml:body style="margin-left:8; margin-right:8; ">
  133. <group id="group1" style="left:0px; top:0px; width:1195px; height:13px; ">
  134. <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:800px; height:14px; ">직급별 경조사 공제금액관리</caption>
  135. </group>
  136. <group id="group2" scroll="auto" style="left:0px; top:38px; width:1195px; height:744px; ">
  137. <shape id="roundrect1" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:10px; width:1195px; height:35px; "/>
  138. <caption id="cap_dutplceinst" class="search_name" style="left:215px; top:19px; width:90px; height:17px; ">기 관 :</caption>
  139. <button id="btn_search" class="btn1_letter2" style="left:1125px; top:16px; width:56px; height:22px; ">
  140. <caption>조회</caption>
  141. <script type="javascript" ev:event="DOMActivate">
  142. <![CDATA[
  143. if(!isRequiredControls("ipt_baseym"))return;
  144. submit("TRRPA07001");
  145. ]]>
  146. </script>
  147. </button>
  148. <line id="line13" class="line_4" style="x1:1110px; y1:16px; x2:1110px; y2:38px; "/>
  149. <line id="line207" class="line_1" style="x1:0; y1:69; x2:1195; y2:69px; "/>
  150. <datagrid id="grd_congradeduamtlist" nodeset="/root/main/congradeduamtlist" caption="기준년월^근무기관^직위코드^직위명^공제액^비고" colsep="^" colwidth="126, 195, 106, 136, 184, 362, 100" dataheight="25" extendlastcol="scroll" mergecellsfixedrows="bycolrec" rowheader="update" rowheight="25" rowsep="|" style="left:0px; top:74px; width:1195px; height:670px; ">
  151. <col ref="baseym" format="yyyy-mm" _key="true" style="text-align:center; "/>
  152. <col ref="dutplceinstnm" style="text-align:center; "/>
  153. <col ref="jobposcd" type="inputbutton" _key="true"/>
  154. <col ref="jobposnm" _key="true"/>
  155. <col ref="deduamt" type="input" format="#,###" _key="true" style="text-align:right; padding-right:10; "/>
  156. <col imemode="hangul" ref="cmt" type="input" style="text-align:left; "/>
  157. <col ref="dutplceinst" visibility="hidden"/>
  158. <script type="javascript" ev:event="onbuttonclick">
  159. <![CDATA[
  160. if (grd_congradeduamtlist.col == 3 ) {
  161. var recv_list = "jobposcd,jobposnm";
  162. misfOpenPopUpList("03", grd_congradeduamtlist,"R0062", recv_list) ;
  163. model.refresh();
  164. }
  165. ]]>
  166. </script>
  167. </datagrid>
  168. <select1 id="cmb_dutplceinst" ref="/root/send/search/dutplceinst" class="combo_s_essential" disabled="true" appearance="minimal" style="left:304px; top:18px; width:190px; height:19px; ">
  169. <choices>
  170. <itemset>
  171. <label/>
  172. <value/>
  173. </itemset>
  174. </choices>
  175. </select1>
  176. <button id="btn_grddel" class="btn2_letter3" style="left:1142px; top:48px; width:53px; height:19px; ">
  177. <caption>행삭제</caption>
  178. <script type="javascript" ev:event="DOMActivate">
  179. <![CDATA[
  180. misfGridIUD(grd_congradeduamtlist,"D");
  181. model.refresh();
  182. ]]>
  183. </script>
  184. </button>
  185. <button id="btn_grdadd" class="btn2_letter3" style="left:1086px; top:48px; width:53px; height:19px; ">
  186. <caption>행추가</caption>
  187. <script type="javascript" ev:event="DOMActivate">
  188. <![CDATA[
  189. misfGridIUD(grd_congradeduamtlist, "A");
  190. var cur_row=grd_congradeduamtlist.row;
  191. grd_congradeduamtlist.valueMatrix(cur_row, grd_congradeduamtlist.colRef("dutplceinst")) =cmb_dutplceinst.value;
  192. grd_congradeduamtlist.valueMatrix(cur_row, grd_congradeduamtlist.colRef("dutplceinstnm")) =cmb_dutplceinst.label;
  193. grd_congradeduamtlist.valueMatrix(cur_row, grd_congradeduamtlist.colRef("baseym")) =ipt_baseym.value;
  194. ]]>
  195. </script>
  196. </button>
  197. <caption id="caption9" class="tit_2" style="left:3px; top:54px; width:183px; height:13px; ">직급별 경조사 공제금액관리</caption>
  198. <input id="ipt_baseym" ref="/root/send/search/baseym" class="input_s_essential" inputtype="date" format="yyyy-mm" style="left:100px; top:18px; width:100px; height:19px; ">
  199. <script type="javascript" ev:event="xforms-value-changed">
  200. <![CDATA[
  201. btn_search.dispatch("DOMActivate");
  202. ]]>
  203. </script>
  204. </input>
  205. <caption id="cap_baseym" class="search_name" style="left:15px; top:19px; width:91px; height:17px; ">기준년월 :</caption>
  206. <input id="input1" ref="/root/send/search/baseamtsaveym" visibility="hidden" style="left:615px; top:20px; width:125px; height:15px; "/>
  207. </group>
  208. <group id="grp_btn" scroll="auto" style="left:0px; top:12px; width:1195px; height:27px; ">
  209. <line id="line11" class="line_6" style="x1:0; y1:25; x2:1195; y2:25; "/>
  210. <button id="btn_save" class="btn4_letter2" style="left:1139px; top:3px; width:56px; height:22px; ">
  211. <caption>저장</caption>
  212. <script type="javascript" ev:event="DOMActivate">
  213. <![CDATA[
  214. var updtdata = getGridUpdateData(grd_congradeduamtlist);
  215. if (updtdata == "" ) {
  216. messageBox("변경된 데이터가","I004");
  217. return;
  218. }
  219. var retMes = messageBox("저장 하시겠습니까?", "Q999");
  220. if ( retMes != 6) {
  221. return;
  222. }
  223. if(!checkKeyColumn("grd_congradeduamtlist"))return;
  224. if(!fsaveCheckValue())return;
  225. for(i=grd_congradeduamtlist.fixedRows; i < grd_congradeduamtlist.rows;i++){
  226. if(updtdata !=""){
  227. var baseamtsaveym=grd_congradeduamtlist.valueMatrix(i,grd_congradeduamtlist.colRef("baseym"));
  228. model.setValue("/root/send/search/baseamtsaveym",baseamtsaveym);
  229. submit("TRRPA07102");
  230. }
  231. }
  232. var baseamtsaveyn=model.getValue("/root/dataynlist/baseamtsaveyn");
  233. if(baseamtsaveyn=='Y'){
  234. messageBox("공제 생성이 완료되어 저장","E001");
  235. return;
  236. }
  237. misfSave("TXRPA07001");
  238. ]]>
  239. </script>
  240. </button>
  241. <button id="btn_clear" class="btn4_letter3" style="left:1069px; top:3px; width:68px; height:22px; ">
  242. <caption>초기화</caption>
  243. <script type="javascript" ev:event="DOMActivate">
  244. <![CDATA[
  245. var updtdata = getGridUpdateData(grd_congradeduamtlist);
  246. if (updtdata != "" ) {
  247. var ret = messageBox("그리드에 작업 중인 내용이 있습니다. 초기화 작업을","Q003");
  248. if (ret != 6) { // not OK
  249. return;
  250. }
  251. }
  252. fInitialize();
  253. ]]>
  254. </script>
  255. </button>
  256. </group>
  257. </xhtml:body>
  258. </xhtml:html>