xSMRPS01500_외부교육부서및인사팀승인.xrw 29 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663
  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>SMRPS01500_외부교육부서및인사팀승인</xhtml:title>
  6. <model id="model1">
  7. <instance id="instance1">
  8. <root xmlns="">
  9. <main>
  10. <rpsmedap/>
  11. </main>
  12. <send>
  13. <init>
  14. <inoutflag/>
  15. <appyy/>
  16. <dutinstcd/>
  17. <dutunitcd/>
  18. <dutunitnm/>
  19. <educfromdd/>
  20. <eductodd/>
  21. <emplno/>
  22. <emplnm/>
  23. </init>
  24. <save/>
  25. </send>
  26. <init>
  27. <item>
  28. <value/>
  29. <label>전체</label>
  30. </item>
  31. <item>
  32. <value>I</value>
  33. <label>국내</label>
  34. </item>
  35. <item>
  36. <value>O</value>
  37. <label>국외</label>
  38. </item>
  39. <item1>
  40. <value>N</value>
  41. <label>미처리</label>
  42. </item1>
  43. <item1>
  44. <value>Y</value>
  45. <label>승인</label>
  46. </item1>
  47. <item1>
  48. <value>R</value>
  49. <label>반려</label>
  50. </item1>
  51. </init>
  52. <temp>
  53. </temp>
  54. </root>
  55. </instance>
  56. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  57. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  58. <script type="javascript" src="../../../com/commonweb/js/stringHelper.js"/>
  59. <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
  60. <script type="javascript" src="../../../mis/miscommonweb/js/MIS.js"/>
  61. <script type="javascript" src="../../../mis/educationmngtweb/js/RPS001.js"/>
  62. <script type="javascript" src="../../../mis/humtrafactmngtweb/js/RPB001.js"/>
  63. <script type="javascript" ev:event="xforms-ready">
  64. <![CDATA[
  65. fInit();
  66. ]]>
  67. </script>
  68. <script type="javascript">
  69. <![CDATA[
  70. function fInit()
  71. {
  72. model.setValue("/root/send/init/appyy", getCurrentDate().substr(0, 4));
  73. model.removenode("/root/main/rpsmedap");
  74. misfComboComCdListMulti("Z0007", "cmb_dutinstcd", null, "Y");
  75. // 기관, 부서, 사원번호에 user session에 있는 내용을 세팅한다.
  76. model.setValue("/root/send/init/dutunitcd", getUserInfo("dutplcecd"));
  77. model.setValue("/root/send/init/dutunitnm", getUserInfo("dutplcenm"));
  78. model.setValue("/root/send/init/dutinstcd", getUserInfo("dutplceinstcd"));
  79. grd_rpsmedap.fixedcellcheckbox(1,13)=true; // 그리드에 있는 전체선택 체크박스
  80. grd_insa.fixedcellcheckbox(1,13)=true; // 그리드에 있는 전체선택 체크박스
  81. grd_insa.fixedcellcheckbox(1,16)=true;
  82. var userdeptcd = getUserInfo("dutplcecd");
  83. if( userdeptcd == '4020500000' || userdeptcd == '4020500300' ) {
  84. grd_insa.visible = true;
  85. grd_rpsmedap.visible = false;
  86. }
  87. else {
  88. grd_insa.visible = false;
  89. grd_rpsmedap.visible = true;
  90. }
  91. fCheck() ;
  92. model.refresh();
  93. }
  94. function fCheck() {
  95. var userinstcd = getUserInfo("dutplceinstcd");
  96. var userdeptcd = getUserInfo("dutplcecd");
  97. if( userinstcd == '001' || (userinstcd == '012' && ( userdeptcd == '4020500000' || userdeptcd == '4020503000' )))
  98. cmb_dutinstcd.disabled = false;
  99. else
  100. cmb_dutinstcd.disabled = true;
  101. if( userdeptcd == '4020500000' || userdeptcd == '4020503000' ) {
  102. ipt_dutunitcd.disabled = false;
  103. ipt_dutunitnm.disabled = false;
  104. ipt_emplno.disabled = false;
  105. ipt_emplnm.disabled = false;
  106. grd_insa.colDisabled(grd_insa.colRef("deptaprvyn") ) = false;
  107. grd_insa.colDisabled(grd_insa.colRef("lastchk") ) = false;
  108. grd_insa.colDisabled(grd_insa.colRef("lastaprvyn") ) = false;
  109. grd_insa.colDisabled(grd_insa.colRef("lastreturn") ) = false;
  110. grd_insa.colDisabled(grd_insa.colRef("offctouramtpayyn") ) = false;
  111. }
  112. else {
  113. grd_rpsmedap.colDisabled(grd_rpsmedap.colRef("lastchk") ) = true;
  114. grd_rpsmedap.colDisabled(grd_rpsmedap.colRef("lastaprvyn") ) = true;
  115. grd_rpsmedap.colDisabled(grd_rpsmedap.colRef("lastreturn") ) = true;
  116. grd_rpsmedap.colDisabled(grd_rpsmedap.colRef("offctouramtpayyn") ) = true;
  117. grd_rpsmedap.colDisabled(grd_rpsmedap.colRef("deptaprvyn") ) = false;
  118. }
  119. model.refresh();
  120. }
  121. function fSave()
  122. {
  123. model.makeNode("/root/send/save");
  124. var userdeptcd = getUserInfo("dutplcecd");
  125. if( userdeptcd == '4020500000' || userdeptcd == '4020503000' ) {
  126. model.setValue("/root/send/save", grd_insa.getUpdateData());
  127. }
  128. else {
  129. model.setValue("/root/send/save", grd_rpsmedap.getUpdateData());
  130. }
  131. if( submit("TXRPS01501") )
  132. messageBox("","I001");
  133. }
  134. function fCheckYN( row, col ) {
  135. if( grd_insa.colRef("deptchk") == col && grd_insa.valueMatrix(row,grd_insa.colRef("deptchk")) == "Y" ) {
  136. grd_insa.valueMatrix(row,grd_insa.colRef("flagd")) = "D";
  137. }
  138. else if( grd_insa.colRef("deptaprvyn") == col ) {
  139. grd_insa.valueMatrix(row,grd_insa.colRef("flagd")) = "D";
  140. }
  141. else if( grd_insa.colRef("deptreturn") == col ) {
  142. grd_insa.valueMatrix(row,grd_insa.colRef("flagd")) = "D";
  143. }
  144. else if( grd_insa.colRef("lastchk") == col && grd_insa.valueMatrix(row,grd_insa.colRef("lastchk")) == "Y" ) {
  145. grd_insa.valueMatrix(row,grd_insa.colRef("flagl")) = "L";
  146. }
  147. else if( grd_insa.colRef("lastaprvyn") == col ) {
  148. grd_insa.valueMatrix(row,grd_insa.colRef("flagl")) = "L";
  149. }
  150. else if( grd_insa.colRef("lastreturn") == col ) {
  151. grd_insa.valueMatrix(row,grd_insa.colRef("flagl")) = "L";
  152. }
  153. else {
  154. ;
  155. }
  156. }
  157. function fCheckDeptYN( row, col ) {
  158. if( grd_rpsmedap.colRef("deptchk") == col && grd_rpsmedap.valueMatrix(row,grd_rpsmedap.colRef("deptchk")) == 'Y' ) {
  159. grd_rpsmedap.valueMatrix(row,grd_rpsmedap.colRef("flagd")) = "D";
  160. }
  161. else if( grd_rpsmedap.colRef("deptchk") == col ){
  162. }
  163. else if( grd_rpsmedap.colRef("deptaprvyn") == col ) {
  164. grd_rpsmedap.valueMatrix(row,grd_rpsmedap.colRef("flagd")) = "D";
  165. }
  166. else if( grd_rpsmedap.colRef("deptreturn") == col ) {
  167. grd_rpsmedap.valueMatrix(row,grd_rpsmedap.colRef("flagd")) = "D";
  168. }
  169. else if( grd_rpsmedap.colRef("lastchk") == col && grd_rpsmedap.valueMatrix(row,grd_rpsmedap.colRef("lastchk")) == 'Y' ) {
  170. grd_rpsmedap.valueMatrix(row,grd_rpsmedap.colRef("flagl")) = "L";
  171. }
  172. else if( grd_rpsmedap.colRef("lastchk") == col ) {
  173. }
  174. else if( grd_rpsmedap.colRef("lastaprvyn") == col ) {
  175. grd_rpsmedap.valueMatrix(row,grd_rpsmedap.colRef("flagl")) = "L";
  176. }
  177. else if( grd_rpsmedap.colRef("lastreturn") == col ) {
  178. grd_rpsmedap.valueMatrix(row,grd_rpsmedap.colRef("flagl")) = "L";
  179. }
  180. }
  181. ]]>
  182. </script>
  183. <submission id="TRRPS01501" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/init" resultref="/root/main/rpsmedap"/>
  184. <submission id="TXRPS01501" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/save" resultref="/root/temp"/>
  185. </model>
  186. </xhtml:head>
  187. <xhtml:body style="margin-left:8; margin-right:8; ">
  188. <group id="group1" style="left:0px; top:0px; width:1195px; height:13px; ">
  189. <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:800px; height:14px; ">외부교육 부서 및 인사팀 승인</caption>
  190. </group>
  191. <group id="group2" scroll="auto" style="left:0px; top:38px; width:1195px; height:744px; ">
  192. <shape id="roundrect1" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:2px; width:1195px; height:62px; background-color:#fffbf2; border-color:#ffd799; "/>
  193. <line id="line8" class="line_1" style="x1:0px; y1:87px; x2:1195px; y2:87px; "/>
  194. <caption id="caption29" class="tit_2" style="left:5px; top:73px; width:169px; height:13px; ">외부교육부서승인</caption>
  195. <datagrid id="grd_rpsmedap" nodeset="/root/main/rpsmedap" autoresize="true" caption="년도^근무기관^근무부서^사번^성명^주체기관^교육명^교육기간^교육기간^총교육시간^교육장소^과정교육비^부서장^부서장^반려사유^인사팀^인사팀^반려사유^출장비&#xA;지급여부^순번^flagd^flagl|년도^근무기관^근무부서^사번^성명^주체기관^교육명^From^To^총교육시간^교육장소^과정교육비^^승인여부^반려사유^^확인여부^반려사유^출장비&#xA;지급여부^순번^flagd^flagl" colsep="^" colwidth="60, 72, 60, 65, 60, 100, 180, 95, 95, 73, 80, 80, 30, 60, 150, 30, 60, 150, 60, 60, 50, 50" dataheight="25" mergecellsfixedrows="bycolrec" rowheader="update" rowsep="|" style="left:0px; top:91px; width:1195px; height:614px; ">
  196. <col class="input_s_essential" ref="appyy" style="text-align:center; "/>
  197. <col class="input_s_essential" disabled="true" ref="dutinstcd" type="combo">
  198. <choices>
  199. <itemset>
  200. <label/>
  201. <value/>
  202. </itemset>
  203. </choices>
  204. </col>
  205. <col class="input_s_essential" ref="dutdeptnm"/>
  206. <col class="input_s_essential" ref="emplno" style="text-align:center; "/>
  207. <col class="input_s_essential" ref="emplnm" style="text-align:center; "/>
  208. <col class="combo_s_essential" disabled="true" ref="instcd" type="combo">
  209. <choices>
  210. <itemset>
  211. <label/>
  212. <value/>
  213. </itemset>
  214. </choices>
  215. </col>
  216. <col class="input_s_essential" ref="educnm"/>
  217. <col class="input_s_essential" disabled="true" ref="educfromdd" type="inputdate"/>
  218. <col class="input_s_essential" disabled="true" ref="eductodd" type="inputdate"/>
  219. <col ref="eductm" style="text-align:right; "/>
  220. <col class="input_s_essential" ref="educplce"/>
  221. <col ref="educamt" format="#,###"/>
  222. <col checkvalue="Y,N" ref="deptchk" type="checkbox"/>
  223. <col ref="deptaprvyn" type="combo">
  224. <choices>
  225. <itemset nodeset="/root/init/item1">
  226. <label ref="label"/>
  227. <value ref="value"/>
  228. </itemset>
  229. </choices>
  230. </col>
  231. <col ref="deptreturn" type="input"/>
  232. <col checkvalue="Y,N" ref="lastchk" type="checkbox"/>
  233. <col ref="lastaprvyn" type="combo">
  234. <choices>
  235. <itemset nodeset="/root/init/item1">
  236. <label ref="label"/>
  237. <value ref="value"/>
  238. </itemset>
  239. </choices>
  240. </col>
  241. <col ref="lastreturn" type="input"/>
  242. <col checkvalue="Y,N" ref="offctouramtpayyn" type="checkbox"/>
  243. <col ref="seq" visibility="hidden"/>
  244. <col ref="flagd" visibility="hidden"/>
  245. <col ref="flagl" visibility="hidden"/>
  246. <script type="javascript" ev:event="onmouseup">
  247. <![CDATA[
  248. // 인사팀일때 부서장승인여부가 N이면 인사팀 확인과 출장비지급여부를 체크할수 없어야 한다.
  249. var userdeptcd = getUserInfo("dutplcecd");
  250. if( userdeptcd == '4020500000' || userdeptcd == '4020503000' ) {
  251. if( grd_rpsmedap.valueMatrix(grd_rpsmedap.row, grd_rpsmedap.colRef("deptaprvyn")) == 'N' ) {
  252. messageBox("아직 확인하실수","I004");
  253. grd_rpsmedap.removeStatus(grd_rpsmedap.row,"update");
  254. grd_rpsmedap.valueMatrix(grd_rpsmedap.row, grd_rpsmedap.colRef("offctouramtpayyn")) = "false";
  255. grd_rpsmedap.valueMatrix(grd_rpsmedap.row, grd_rpsmedap.colRef("lastaprvyn")) = "false";
  256. }
  257. }
  258. ]]>
  259. </script>
  260. <script type="javascript" ev:event="xforms-value-changed">
  261. <![CDATA[
  262. // 셀의 데이터가 변경되었을때 발생하는 이벤트..변경된 데이터가 부서장승인인지, 인사팀 승인인지 구분하기 위해서 필요..
  263. var row = grd_rpsmedap.row;
  264. var col = grd_rpsmedap.col;
  265. fCheckDeptYN(row,col);
  266. ]]>
  267. </script>
  268. </datagrid>
  269. <button id="btn_search" class="btn1_letter2" style="left:1125px; top:22px; width:56px; height:22px; ">
  270. <caption>조회</caption>
  271. <script type="javascript" ev:event="DOMActivate">
  272. <![CDATA[
  273. model.removeNodeset("/root/main/rpsmedap");
  274. grd_rpsmedap.refresh();
  275. grd_insa.refresh();
  276. misfComboComCdListMulti("Z0007,Z0007,Z0007,Z0007,Z0007", "cmb_dutinstcd,grd_rpsmedap.dutinstcd,grd_rpsmedap.instcd,grd_insa.dutinstcd,grd_insa.instcd", null, "Y");
  277. fCheck() ;
  278. submit("TRRPS01501");
  279. ]]>
  280. </script>
  281. </button>
  282. <line id="line13" class="line_4" style="x1:1110px; y1:8px; x2:1110px; y2:58px; "/>
  283. <caption id="caption1" class="search_name" style="left:40px; top:36px; width:86px; height:17px; ">근무기관 :</caption>
  284. <input id="ipt_appyy" ref="/root/send/init/appyy" class="input_s_essential" inputtype="date" format="yyyy" style="left:125px; top:11px; width:70px; height:19px; text-align:center; "/>
  285. <caption id="caption10" class="search_name" style="left:40px; top:10px; width:100px; height:17px; ">년 도 :</caption>
  286. <caption id="caption2" class="search_name" style="left:385px; top:36px; width:101px; height:17px; ">근 무 부 서 :</caption>
  287. <select1 id="cmb_dutinstcd" ref="/root/send/init/dutinstcd" class="combo_s_essential" disabled="true" appearance="minimal" style="left:125px; top:36px; width:180px; height:19px; ">
  288. <choices>
  289. <itemset>
  290. <label/>
  291. <value/>
  292. </itemset>
  293. </choices>
  294. </select1>
  295. <caption id="caption4" class="search_name" style="left:770px; top:36px; width:89px; height:17px; ">사원번호 :</caption>
  296. <caption id="caption7" class="search_name" style="left:770px; top:11px; width:91px; height:17px; ">교육년월 :</caption>
  297. <caption id="caption75" class="search_name" style="left:385px; top:9px; width:99px; height:17px; ">국내외구분 :</caption>
  298. <select1 id="rdo_inoutflag" ref="/root/send/init/inoutflag" appearance="full" cellspacing="20" cols="3" overflow="visible" style="left:485px; top:9px; width:190px; height:20px; border-style:none; ">
  299. <choices>
  300. <itemset nodeset="/root/init/item">
  301. <label ref="label"/>
  302. <value ref="value"/>
  303. </itemset>
  304. </choices>
  305. </select1>
  306. <input id="ipt_emplnm" ref="/root/send/init/emplnm" class="input_search" navindex="3" style="left:970px; top:36px; width:95px; height:19px; text-align:center; ">
  307. <script type="javascript" ev:event="xforms-value-changed">
  308. <![CDATA[
  309. misfValidationCheck("02", "", "emplno,emplnm", ipt_emplno.value, "instcd");
  310. model.refresh();
  311. ]]>
  312. </script>
  313. <script type="javascript" ev:event="onkeypress">
  314. <![CDATA[
  315. if(event.keyCode == 13) {
  316. ipt_emplnm.value = ipt_emplnm.currentText;
  317. misfValidationCheck("02", "", "emplno,emplnm", ipt_emplno.value, "instcd");
  318. model.refresh();
  319. }
  320. ]]>
  321. </script>
  322. </input>
  323. <input id="ipt_dutunitnm" ref="/root/send/init/dutunitnm" class="input_search" disabled="true" navindex="7" style="left:582px; top:36px; width:118px; height:19px; text-align:center; ">
  324. <script type="javascript" ev:event="xforms-value-changed">
  325. <![CDATA[
  326. misfValidationCheck("02", "", "dutunitcd,dutunitnm", cmb_dutinstcd.value, "instcd");
  327. model.refresh();
  328. ]]>
  329. </script>
  330. <script type="javascript" ev:event="onkeypress">
  331. <![CDATA[
  332. if(event.keyCode == 13)
  333. {
  334. ipt_dutunitcd.value = ipt_dutunitcd.currentText;
  335. misfValidationCheck("02", "", "dutunitcd,dutunitnm", cmb_dutinstcd.value, "instcd");
  336. model.refresh();
  337. }
  338. ]]>
  339. </script>
  340. </input>
  341. <input id="ipt_emplno" ref="/root/send/init/emplno" class="input_search" navindex="2" maxlength="10" style="left:855px; top:36px; width:95px; height:19px; text-align:center; ">
  342. <script type="javascript" ev:event="xforms-value-changed">
  343. <![CDATA[
  344. misfValidationCheck("02", "", "emplno,emplnm", ipt_emplno.value, "instcd");
  345. model.refresh();
  346. ]]>
  347. </script>
  348. <script type="javascript" ev:event="onkeypress">
  349. <![CDATA[
  350. if(event.keyCode == 13)
  351. {
  352. ipt_dutunitcd.value = ipt_dutunitcd.currentText;
  353. misfValidationCheck("02", "", "emplno,emplnm", ipt_emplno.value, "instcd");
  354. model.refresh();
  355. }
  356. ]]>
  357. </script>
  358. </input>
  359. <input id="ipt_dutunitcd" ref="/root/send/init/dutunitcd" class="input_search" disabled="true" style="left:485px; top:36px; width:75px; height:19px; text-align:center; ">
  360. <script type="javascript" ev:event="xforms-value-changed">
  361. <![CDATA[
  362. misfValidationCheck("02", "", "dutunitcd,dutunitnm", cmb_dutinstcd.value, "instcd");
  363. model.refresh();
  364. ]]>
  365. </script>
  366. <script type="javascript" ev:event="onkeypress">
  367. <![CDATA[
  368. if(event.keyCode == 13)
  369. {
  370. ipt_dutunitcd.value = ipt_dutunitcd.currentText;
  371. misfValidationCheck("02", "", "dutunitcd,dutunitnm", cmb_dutinstcd.value, "instcd");
  372. model.refresh();
  373. }
  374. ]]>
  375. </script>
  376. </input>
  377. <button id="btn_empl" class="icon_search" style="left:952px; top:36px; width:16px; height:16px; ">
  378. <caption/>
  379. <script type="javascript" ev:event="DOMActivate">
  380. <![CDATA[
  381. var recv_list = "emplno,emplnm";
  382. rpbfOpenPopUpList("SPRPB00101", ipt_emplno, recv_list,"","N","Y");
  383. model.refresh();
  384. ]]>
  385. </script>
  386. </button>
  387. <button id="btn_unit" class="icon_search" disabled="false" style="left:563px; top:36px; width:16px; height:16px; ">
  388. <caption/>
  389. <script type="javascript" ev:event="DOMActivate">
  390. <![CDATA[
  391. misfOpenPopUpList("02", ipt_dutunitnm, "", "dutunitcd,dutunitnm", cmb_dutinstcd.value, "instcd");
  392. model.refresh();
  393. ]]>
  394. </script>
  395. </button>
  396. <input id="ipt_educfromdd" ref="/root/send/init/educfromdd" class="input_search" inputtype="date" style="left:855px; top:11px; width:95px; height:19px; "/>
  397. <input id="ipt_eductodd" ref="/root/send/init/eductodd" class="input_search" inputtype="date" style="left:970px; top:11px; width:95px; height:19px; "/>
  398. <caption id="caption100" style="left:955px; top:11px; width:20px; height:20px; ">~</caption>
  399. <datagrid id="grd_insa" nodeset="/root/main/rpsmedap" visibility="hidden" autoresize="true" caption="년도^근무기관^근무부서^사번^성명^주체기관^교육명^교육기간^교육기간^총교육시간^교육장소^과정교육비^부서장^부서장^반려사유^인사팀^인사팀^반려사유^출장비&#xA;지급여부^등록비^교통비^현지&#xA;교통비^숙박비^식비^일비^계^순번^flagD^flagL|년도^근무기관^근무부서^사번^성명^주체기관^교육명^From^To^총교육시간^교육장소^과정교육비^^승인여부^반려사유^^확인여부^반려사유^출장비&#xA;지급여부^등록비^교통비^현지&#xA;교통비^숙박비^식비^일비^계^순번^flagD^flagL" colsep="^" colwidth="60, 72, 60, 65, 60, 100, 180, 95, 95, 73, 80, 80, 30, 60, 150, 30, 60, 150, 60, 60, 60, 60, 60, 60, 60, 70, 60, 50, 50" dataheight="25" mergecellsfixedrows="bycolrec" rowheader="update" rowsep="|" style="left:0px; top:91px; width:1195px; height:615px; ">
  400. <col class="input_s_essential" ref="appyy" style="text-align:center; "/>
  401. <col class="input_s_essential" disabled="true" ref="dutinstcd" type="combo">
  402. <choices>
  403. <itemset>
  404. <label/>
  405. <value/>
  406. </itemset>
  407. </choices>
  408. </col>
  409. <col class="input_s_essential" ref="dutdeptnm"/>
  410. <col class="input_s_essential" ref="emplno" style="text-align:center; "/>
  411. <col class="input_s_essential" ref="emplnm" style="text-align:center; "/>
  412. <col class="combo_s_essential" disabled="true" ref="instcd" type="combo">
  413. <choices>
  414. <itemset>
  415. <label/>
  416. <value/>
  417. </itemset>
  418. </choices>
  419. </col>
  420. <col class="input_s_essential" ref="educnm" type="input"/>
  421. <col class="input_s_essential" disabled="true" ref="educfromdd" type="inputdate"/>
  422. <col class="input_s_essential" disabled="true" ref="eductodd" type="inputdate"/>
  423. <col ref="eductm" style="text-align:right; "/>
  424. <col class="input_s_essential" ref="educplce"/>
  425. <col ref="educamt" format="#,###"/>
  426. <col checkvalue="Y,N" ref="deptchk" type="checkbox"/>
  427. <col ref="deptaprvyn" type="combo">
  428. <choices>
  429. <itemset nodeset="/root/init/item1">
  430. <label ref="label"/>
  431. <value ref="value"/>
  432. </itemset>
  433. </choices>
  434. </col>
  435. <col ref="deptreturn" type="input"/>
  436. <col checkvalue="Y,N" ref="lastchk" type="checkbox"/>
  437. <col ref="lastaprvyn" type="combo">
  438. <choices>
  439. <itemset nodeset="/root/init/item1">
  440. <label ref="label"/>
  441. <value ref="value"/>
  442. </itemset>
  443. </choices>
  444. </col>
  445. <col ref="lastreturn" type="input"/>
  446. <col checkvalue="Y,N" ref="offctouramtpayyn" type="checkbox"/>
  447. <col ref="item1" type="input" format="#,###" maxlength="7" style="text-align:right; "/>
  448. <col ref="item2" type="input" format="#,###" maxlength="7" style="text-align:right; "/>
  449. <col ref="item3" type="input" format="#,###" maxlength="7" style="text-align:right; "/>
  450. <col ref="item4" type="input" format="#,###" maxlength="7" style="text-align:right; "/>
  451. <col ref="item5" type="input" format="#,###" maxlength="7" style="text-align:right; "/>
  452. <col ref="item6" type="input" format="#,###" maxlength="7" style="text-align:right; "/>
  453. <col ref="itemtotal" format="#,###" maxlength="7" style="text-align:right; "/>
  454. <col ref="seq" visibility="hidden"/>
  455. <col ref="flagd" visibility="hidden"/>
  456. <col ref="flagl" visibility="hidden"/>
  457. <script type="javascript" ev:event="onmouseup">
  458. <![CDATA[
  459. // 인사팀일때 부서장승인여부가 N이면 인사팀 확인과 출장비지급여부를 체크할수 없어야 한다.
  460. var userdeptcd = getUserInfo("dutplcecd");
  461. if( userdeptcd == '4020500000' || userdeptcd == '4020503000' ) {
  462. if( grd_rpsmedap.valueMatrix(grd_rpsmedap.row, grd_rpsmedap.colRef("deptaprvyn")) == 'N' ) {
  463. messageBox("아직 확인하실수","I004");
  464. grd_rpsmedap.removeStatus(grd_rpsmedap.row,"update");
  465. grd_rpsmedap.valueMatrix(grd_rpsmedap.row, grd_rpsmedap.colRef("offctouramtpayyn")) = "false";
  466. grd_rpsmedap.valueMatrix(grd_rpsmedap.row, grd_rpsmedap.colRef("lastaprvyn")) = "false";
  467. }
  468. }
  469. ]]>
  470. </script>
  471. <script type="javascript" ev:event="xforms-value-changed">
  472. <![CDATA[
  473. var total = 0;
  474. // 셀의 데이터가 변경되었을때 발생하는 이벤트..변경된 데이터가 부서장승인인지, 인사팀 승인인지 구분하기 위해서 필요..
  475. var row = grd_insa.row;
  476. var col = grd_insa.col;
  477. var userdeptcd = getUserInfo("dutplcecd");
  478. if( userdeptcd == '4020500000' || userdeptcd == '4020503000' ) {
  479. if( col == grd_insa.colRef("item1") || col == grd_insa.colRef("item2") || col == grd_insa.colRef("item3") ||
  480. col == grd_insa.colRef("item4") || col == grd_insa.colRef("item5") || col == grd_insa.colRef("item6") ||
  481. col == grd_insa.colRef("offctouramtpayyn") ) {
  482. if(grd_insa.valueMatrix(grd_insa.row,grd_insa.colRef("item1")) != "" )
  483. total = parseInt(grd_insa.valueMatrix(grd_insa.row,grd_insa.colRef("item1"))) + parseInt(total);
  484. if(grd_insa.valueMatrix(grd_insa.row,grd_insa.colRef("item2")) != "" )
  485. total = parseInt(grd_insa.valueMatrix(grd_insa.row,grd_insa.colRef("item2"))) + parseInt(total);
  486. if(grd_insa.valueMatrix(grd_insa.row,grd_insa.colRef("item3")) != "" )
  487. total = parseInt(grd_insa.valueMatrix(grd_insa.row,grd_insa.colRef("item3"))) + parseInt(total);
  488. if(grd_insa.valueMatrix(grd_insa.row,grd_insa.colRef("item4")) != "" )
  489. total = parseInt(grd_insa.valueMatrix(grd_insa.row,grd_insa.colRef("item4"))) + parseInt(total);
  490. if(grd_insa.valueMatrix(grd_insa.row,grd_insa.colRef("item5")) != "" )
  491. total = parseInt(grd_insa.valueMatrix(grd_insa.row,grd_insa.colRef("item5"))) + parseInt(total);
  492. if(grd_insa.valueMatrix(grd_insa.row,grd_insa.colRef("item6")) != "" )
  493. total = parseInt(grd_insa.valueMatrix(grd_insa.row,grd_insa.colRef("item6"))) + parseInt(total);
  494. grd_insa.valueMatrix(grd_insa.row,grd_insa.colRef("itemtotal")) = total;
  495. grd_insa.valueMatrix(grd_insa.row,grd_insa.colRef("flagl")) = "L";
  496. }
  497. }
  498. fCheckYN(row,col);
  499. ]]>
  500. </script>
  501. </datagrid>
  502. <button id="button1" class="btn5_letter2" style="left:1108px; top:67px; width:42px; height:19px; ">
  503. <caption>승인</caption>
  504. <script type="javascript" ev:event="DOMActivate">
  505. <![CDATA[
  506. if( messageBox("승인 하시겠습니까?","Q999") == '6' ) {
  507. var userdeptcd = getUserInfo("dutplcecd");
  508. if( userdeptcd == '4020500000' || userdeptcd == '4020503000' ) {
  509. for(var i = grd_insa.fixedRows; i < grd_insa.rows; i++){
  510. if(grd_insa.valueMatrix(i,grd_insa.colRef("deptchk")) == "Y") {
  511. grd_insa.addStatus(i, "update");
  512. grd_insa.valueMatrix(i,grd_insa.colRef("flagd")) = "D";
  513. grd_insa.valueMatrix(i,grd_insa.colRef("deptaprvyn")) = "Y";
  514. }
  515. else ;
  516. if(grd_insa.valueMatrix(i,grd_insa.colRef("lastchk")) == "Y") {
  517. grd_insa.addStatus(i, "update");
  518. grd_insa.valueMatrix(i,grd_insa.colRef("flagl")) = "L";
  519. grd_insa.valueMatrix(i,grd_insa.colRef("lastaprvyn")) = "Y";
  520. }
  521. else ;
  522. }
  523. }
  524. else {
  525. for(var i = grd_rpsmedap.fixedRows; i < grd_rpsmedap.rows; i++){
  526. if(grd_rpsmedap.valueMatrix(i,grd_rpsmedap.colRef("deptchk")) == "Y") {
  527. grd_rpsmedap.addStatus(i, "update");
  528. grd_rpsmedap.valueMatrix(i,grd_rpsmedap.colRef("flagd")) = "D";
  529. grd_rpsmedap.valueMatrix(i,grd_rpsmedap.colRef("deptaprvyn")) = "Y";
  530. }
  531. else ;
  532. if(grd_rpsmedap.valueMatrix(i,grd_rpsmedap.colRef("lastchk")) == "Y") {
  533. grd_rpsmedap.addStatus(i, "update");
  534. grd_rpsmedap.valueMatrix(i,grd_rpsmedap.colRef("flagl")) = "L";
  535. grd_rpsmedap.valueMatrix(i,grd_rpsmedap.colRef("lastaprvyn")) = "Y";
  536. }
  537. else ;
  538. }
  539. }
  540. }
  541. ]]>
  542. </script>
  543. </button>
  544. <button id="button2" class="btn5_letter2" style="left:1151px; top:67px; width:42px; height:19px; ">
  545. <caption>반려</caption>
  546. <script type="javascript" ev:event="DOMActivate">
  547. <![CDATA[
  548. if( messageBox("반려 하시겠습니까?","Q999") == '6' ) {
  549. var userdeptcd = getUserInfo("dutplcecd");
  550. if( userdeptcd == '4020500000' || userdeptcd == '4020503000' ) {
  551. for(var i = grd_insa.fixedRows; i < grd_insa.rows; i++){
  552. if(grd_insa.valueMatrix(i,grd_insa.colRef("deptchk")) == "Y") {
  553. grd_insa.addStatus(i, "update");
  554. grd_insa.valueMatrix(i,grd_insa.colRef("flagd")) = "D";
  555. grd_insa.valueMatrix(i,grd_insa.colRef("deptaprvyn")) = "R";
  556. }
  557. else if(grd_insa.valueMatrix(i,grd_insa.colRef("lastchk")) == "Y") {
  558. grd_insa.addStatus(i, "update");
  559. grd_insa.valueMatrix(i,grd_insa.colRef("flagl")) = "L";
  560. grd_insa.valueMatrix(i,grd_insa.colRef("lastaprvyn")) = "R";
  561. }
  562. else ;
  563. }
  564. }
  565. else {
  566. for(var i = grd_rpsmedap.fixedRows; i < grd_rpsmedap.rows; i++){
  567. if(grd_rpsmedap.valueMatrix(i,grd_rpsmedap.colRef("deptchk")) == "Y") {
  568. grd_rpsmedap.addStatus(i, "update");
  569. grd_rpsmedap.valueMatrix(i,grd_rpsmedap.colRef("flagd")) = "D";
  570. grd_rpsmedap.valueMatrix(i,grd_rpsmedap.colRef("deptaprvyn")) = "R";
  571. }
  572. else if(grd_rpsmedap.valueMatrix(i,grd_rpsmedap.colRef("lastchk")) == "Y") {
  573. grd_rpsmedap.addStatus(i, "update");
  574. grd_rpsmedap.valueMatrix(i,grd_rpsmedap.colRef("flagl")) = "L";
  575. grd_rpsmedap.valueMatrix(i,grd_rpsmedap.colRef("lastaprvyn")) = "R";
  576. }
  577. else ;
  578. }
  579. }
  580. }
  581. ]]>
  582. </script>
  583. </button>
  584. <button id="button3" class="btn2_letter4" style="left:1031px; top:67px; width:64px; height:19px; ">
  585. <caption>엑셀저장</caption>
  586. <script type="javascript" ev:event="DOMActivate">
  587. <![CDATA[
  588. var fileName = window.fileDialog("save", ",", false, "excel", "xls", "Excel Files(*.xls)|*.xls|All Files (*.*)|*.*");
  589. var userdeptcd = getUserInfo("dutplcecd");
  590. if( userdeptcd == '4020500000' || userdeptcd == '4020503000' ) {
  591. grd_insa.saveExcel(fileName,"sheetname:sheet1;colhiddenextend:false;rowhiddenextend:false;col_2:label;col_6:label;col_14:label;col_17:label;");
  592. }
  593. else {
  594. grd_rpsmedap.saveExcel(fileName,"sheetname:sheet1;colhiddenextend:false;rowhiddenextend:false;col_2:label;col_6:label;col_14:label;col_17:label;");
  595. }
  596. ]]>
  597. </script>
  598. </button>
  599. </group>
  600. <group id="grp_btn" scroll="auto" style="left:0px; top:12px; width:1195px; height:27px; ">
  601. <button id="btn_save" class="btn4_letter2" style="left:1139px; top:3px; width:56px; height:22px; ">
  602. <caption>저장</caption>
  603. <script type="javascript" ev:event="DOMActivate">
  604. <![CDATA[
  605. fSave();
  606. // submit("TRRPS01501");
  607. // 체크된 내용 모두 지우고 flagD와 flagL도 모두 삭제
  608. for(var i = grd_insa.fixedRows; i < grd_insa.rows; i++) { // grd_insa와 grd_rpsmedap의 data row수는 같으므로 같은 i를 사용한다.
  609. grd_insa.valueMatrix(i, grd_insa.colRef("deptchk")) = "N";
  610. grd_insa.valueMatrix(i, grd_insa.colRef("lastchk")) = "N";
  611. grd_insa.valueMatrix(i, grd_insa.colRef("flagd")) = "";
  612. grd_insa.valueMatrix(i, grd_insa.colRef("flagl")) = "";
  613. grd_insa.fixedcellischeck(1,13) = false; // 전체 체크박스를 초기화
  614. grd_insa.fixedcellischeck(1,16) = false; // 전체 체크박스를 초기화
  615. grd_rpsmedap.valueMatrix(i, grd_rpsmedap.colRef("deptchk")) = "N";
  616. grd_rpsmedap.valueMatrix(i, grd_rpsmedap.colRef("lastchk")) = "N";
  617. grd_rpsmedap.valueMatrix(i, grd_rpsmedap.colRef("flagd")) = "";
  618. grd_rpsmedap.valueMatrix(i, grd_rpsmedap.colRef("flagl")) = "";
  619. grd_rpsmedap.fixedcellischeck(1,13) = false; // 전체 체크박스를 초기화
  620. }
  621. grd_insa.clearStatus();
  622. grd_rpsmedap.clearStatus();
  623. model.refresh();
  624. ]]>
  625. </script>
  626. </button>
  627. </group>
  628. </xhtml:body>
  629. </xhtml:html>