SMRNB00600_신규직원연동.xfdl 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <FDL version="1.5">
  3. <TypeDefinition url="..\..\..\default_typedef.xml"/>
  4. <Form id="SMRNB00600" inheritanceid="" position="absolute 0 0 1024 665" titletext="신규직원연동" onload="SMRNB00600_onload" ontimer="SMRNB00600_ontimer">
  5. <Layouts>
  6. <Layout>
  7. <Static id="caption6" text="직원식권 연동" class="tit_1" position="absolute 0 0 120 25"/>
  8. <Static id="cap_time" position="absolute 758 1 1023 24" style="background:darkseagreen;padding:0 0 0 4;align:center middle;font:Dotum,10,bold;" anchor="top right"/>
  9. <Button id="btn_init" taborder="27" text="초기화" class="btn4" position="absolute 841 26 905 48" anchor="top right" onclick="btn_init_onclick"/>
  10. <Button id="btn_save" taborder="29" text="저장" class="btn4" position="absolute 908 26 964 48" anchor="top right" onclick="btn_save_onclick"/>
  11. <Button id="btn_close" taborder="30" text="종료" class="btn4" position="absolute 967 26 1023 48" anchor="top right" onclick="btn_close_onclick"/>
  12. <Static id="cap_messege_title" position="absolute 72 638 229 661" anchor="left bottom" style="background:lightblue;padding:0 0 0 4;"/>
  13. <Static id="cap_messege" position="absolute 231 638 948 661" anchor="left bottom" style="background:lightblue;padding:0 0 0 4;font:Dotum,9,bold;"/>
  14. <Shape id="line7" class="line_6" position="absolute 0 47 1023 53" anchor="left top right"/>
  15. <Grid id="grd_foodmasterlist" taborder="31" useinputpanel="false" position="absolute 0 120 1023 633" binddataset="ds_main_newempllist" autofittype="col" selecttype="cell" autoenter="select" anchor="all">
  16. <Formats>
  17. <Format id="default">
  18. <Columns>
  19. <Column size="25" band="left"/>
  20. <Column size="25" band="left"/>
  21. <Column size="80"/>
  22. <Column size="80"/>
  23. <Column size="159"/>
  24. <Column size="120"/>
  25. <Column size="100"/>
  26. <Column size="120"/>
  27. <Column size="80"/>
  28. </Columns>
  29. <Rows>
  30. <Row size="24" band="head"/>
  31. <Row size="24"/>
  32. <Row size="24" band="summ"/>
  33. </Rows>
  34. <Band id="head">
  35. <Cell/>
  36. <Cell col="1"/>
  37. <Cell col="2" displaytype="normal" text="직원번호"/>
  38. <Cell col="3" text="성명"/>
  39. <Cell col="4" text="소속"/>
  40. <Cell col="5" text="발령일"/>
  41. <Cell col="6" text="직급"/>
  42. <Cell col="7" text="등록일자"/>
  43. <Cell col="8" text="사용유무"/>
  44. </Band>
  45. <Band id="body">
  46. <Cell celltype="head"/>
  47. <Cell col="1" celltype="head" text="expr:currow+1"/>
  48. <Cell col="2" displaytype="text" edittype="text" text="bind:id" editautoselect="true"/>
  49. <Cell col="3" displaytype="text" edittype="text" text="bind:name" editautoselect="true"/>
  50. <Cell col="4" displaytype="text" edittype="text" text="bind:departname" editautoselect="true"/>
  51. <Cell col="5" displaytype="date" text="bind:hiredate" mask="yyyy-MM-dd HH:mm:ss"/>
  52. <Cell col="6" text="bind:grade"/>
  53. <Cell col="7" displaytype="date" text="bind:resumpdate" mask="yyyy-MM-dd HH:mm:ss"/>
  54. <Cell col="8" text="bind:use_flag"/>
  55. </Band>
  56. <Band id="summary">
  57. <Cell/>
  58. <Cell col="1"/>
  59. <Cell col="2" style="font:Dotum,9,bold;" text="총건수"/>
  60. <Cell col="3" displaytype="number" style="font:Dotum,9,bold;" text="expr:rowcount"/>
  61. <Cell col="4"/>
  62. <Cell col="5"/>
  63. <Cell col="6"/>
  64. <Cell col="7"/>
  65. <Cell col="8"/>
  66. </Band>
  67. </Format>
  68. </Formats>
  69. </Grid>
  70. <Static id="caption1" text="직원리스트" class="tit_2" position="absolute 0 99 157 115"/>
  71. <Shape id="line1" class="line_10" position="absolute 0 115 1023 121" anchor="left top right"/>
  72. <Button id="btn_importExcel" taborder="33" text="Excel 자료가져오기" class="btn7" position="absolute 694 26 838 48" anchor="top right" onclick="btn_importExcel_onclick" visible="false"/>
  73. <Div id="grp_search" taborder="34" class="div_SA2" position="absolute 0 51 1023 91" anchor="left top right">
  74. <Layouts>
  75. <Layout>
  76. <Static id="cap_ibgodd" text="조회일자" class="search_name" position="absolute 10 12 84 29" anchor="default"/>
  77. <Button id="btn_search" taborder="4" text="조회" onclick="grp_search_btn_search_onclick" class="btn1" position="absolute 953 9 1009 31" style="align:center;" anchor="top right"/>
  78. <Shape id="line7" linetype="vertical" class="line_4" position="absolute 938 7 941 34" anchor="top right"/>
  79. <Calendar id="ipt_fromdd" taborder="5" autoselect="true" class="input_essential" position="absolute 91 9 209 30" onchanged="grp_search_ipt_ibgodd_onchanged" anchor="default"/>
  80. <Calendar id="ipt_todd" taborder="6" autoselect="true" onchanged="grp_search_ipt_ibgodd_onchanged" class="input_essential" position="absolute 227 9 345 30"/>
  81. <Static id="Static00" text="~" position="absolute 214 10 234 30"/>
  82. </Layout>
  83. </Layouts>
  84. </Div>
  85. </Layout>
  86. </Layouts>
  87. <Bind>
  88. <BindItem id="item19" compid="cap_messege" propid="text" datasetid="ds_messege" columnid="cmt"/>
  89. <BindItem id="item15" compid="grp_search.ipt_fromdd" propid="value" datasetid="ds_send" columnid="fromdd"/>
  90. <BindItem id="item0" compid="grp_search.ipt_todd" propid="value" datasetid="ds_send" columnid="todd"/>
  91. </Bind>
  92. <Objects>
  93. <Dataset id="ds_send" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  94. <ColumnInfo>
  95. <Column id="instcd" type="STRING" size="256"/>
  96. <Column id="userid" type="STRING" size="256"/>
  97. <Column id="fromdd" type="STRING" size="256"/>
  98. <Column id="todd" type="STRING" size="256"/>
  99. </ColumnInfo>
  100. <Rows>
  101. <Row>
  102. <Col id="instcd"/>
  103. <Col id="userid"/>
  104. <Col id="fromdd"/>
  105. <Col id="todd"/>
  106. </Row>
  107. </Rows>
  108. </Dataset>
  109. <Dataset id="ds_main_newempllist" firefirstcount="0" firenextcount="0" useclientlayout="true" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  110. <ColumnInfo>
  111. <Column id="id" type="STRING" size="256"/>
  112. <Column id="name" type="STRING" size="256"/>
  113. <Column id="departname" type="STRING" size="256"/>
  114. <Column id="hiredate" type="DATE" size="256"/>
  115. <Column id="grade" type="STRING" size="256"/>
  116. <Column id="resumpdate" type="DATE" size="256"/>
  117. <Column id="use_flag" type="STRING" size="256"/>
  118. <Column id="departcode" type="STRING" size="256"/>
  119. <Column id="position1" type="STRING" size="256"/>
  120. <Column id="registrationno" type="STRING" size="256"/>
  121. <Column id="jikkind" type="STRING" size="256"/>
  122. <Column id="restdate" type="DATE" size="256"/>
  123. <Column id="retiredate" type="DATE" size="256"/>
  124. <Column id="kubun" type="STRING" size="256"/>
  125. <Column id="payfood" type="STRING" size="256"/>
  126. <Column id="expandfood" type="STRING" size="256"/>
  127. <Column id="flag1" type="STRING" size="256"/>
  128. <Column id="flag2" type="STRING" size="256"/>
  129. <Column id="remain" type="STRING" size="256"/>
  130. </ColumnInfo>
  131. </Dataset>
  132. </Objects>
  133. <Script type="xscript4.0"><![CDATA[/***************************************************************************************
  134. * System Name :
  135. * Job Name :
  136. * Creator :
  137. * Make Date : 2017-12-04
  138. * Description :
  139. *---------------------------------------------------------------------------------------
  140. * Modify Date Modifier Modify Description
  141. *---------------------------------------------------------------------------------------
  142. * 2017-06-19 Live Converter TF->XP
  143. *
  144. *---------------------------------------------------------------------------------------
  145. ****************************************************************************************/
  146. //=======================================================================================
  147. // Lib Include
  148. //---------------------------------------------------------------------------------------
  149. include "com_commonxp::comm_main.xjs";
  150. include "mis_miscommonxp::MIS.xjs";
  151. //=======================================================================================
  152. // Global Form Variable
  153. //---------------------------------------------------------------------------------------
  154. var arErrorCode = new HashArray();
  155. //=======================================================================================
  156. // Function
  157. //---------------------------------------------------------------------------------------
  158. /****************************************************************************************
  159. * Argument : N/A
  160. * Description : 초기화
  161. ****************************************************************************************/
  162. function lf_init() {
  163. var sInstcd = sysf_getUserInfo("dutplceinstcd");
  164. ds_send.setColumn(0, "instcd", sInstcd);
  165. ds_send.setColumn(0, "fromdd", utlf_getCurrentDate());
  166. ds_send.setColumn(0, "todd", utlf_getCurrentDate());
  167. ds_main_newempllist.clearData();
  168. cap_messege_title.style.background = "lightblue";
  169. cap_messege.text = "";
  170. }
  171. /****************************************************************************************
  172. * Argument : N/A
  173. * Description : 시간설정
  174. ****************************************************************************************/
  175. function lf_setTime() {
  176. var cTime = utlf_getCurrentDateTime();
  177. cap_time.text = cTime.substr(0,4)+"/"+cTime.substr(4,2)+"/"+cTime.substr(6,2)+" "+cTime.substr(9,2)+":"+cTime.substr(11,2)+":"+cTime.substr(13,2);
  178. }
  179. /****************************************************************************************
  180. * Argument : N/A
  181. * Description : 조회함수
  182. ****************************************************************************************/
  183. function lf_userAuth() {
  184. if(sysf_getUserInfo("userid").substr(0,4).toUpperCase() == "EVER") {
  185. //btn_save.enable = false;
  186. btn_importExcel.enable = false;
  187. }
  188. }
  189. //=======================================================================================
  190. // Event
  191. //---------------------------------------------------------------------------------------
  192. /****************************************************************************************
  193. * Components : Form
  194. * Description : 화면 처음 초기화시 폼초기화
  195. ****************************************************************************************/
  196. function SMRNB00600_onload(obj:Form, e:LoadEventInfo)
  197. {
  198. frmf_initForm(obj);
  199. lf_init();
  200. grdf_setGridSort(grd_foodmasterlist);
  201. grdf_setRowTypeIcon(grd_foodmasterlist, 0);
  202. lf_userAuth();
  203. lf_setTime();
  204. this.setTimer(0, 1000);
  205. }
  206. /****************************************************************************************
  207. * Components : Form
  208. * Description : 화면 타이머 설정 시계표시
  209. ****************************************************************************************/
  210. function SMRNB00600_ontimer(obj:Form, e:TimerEventInfo)
  211. {
  212. if(e.timerid == 0) {
  213. lf_setTime();
  214. }
  215. }
  216. /****************************************************************************************
  217. * Components : Button
  218. * Description : 종료
  219. ****************************************************************************************/
  220. function btn_close_onclick(obj:Button, e:ClickEventInfo)
  221. {
  222. this.close();
  223. }
  224. /****************************************************************************************
  225. * Components : Button
  226. * Description : 신규인사조회
  227. ****************************************************************************************/
  228. function grp_search_btn_search_onclick(obj:Button, e:ClickEventInfo)
  229. {
  230. var oParam = {};
  231. oParam.id = "TRRNB00016";
  232. oParam.service = "sicksuapp.SicksuMngt";
  233. oParam.method = "reqGetNewEmplList";
  234. oParam.inds = "req=ds_send";
  235. oParam.outds = "ds_main_newempllist=newempllist";
  236. oParam.async = false;
  237. oParam.callback = "cf_TRRNB00016";
  238. tranf_submit(oParam);
  239. if(arErrorCode.pop("TRRNB00016") > -1) {
  240. for(var i = 0 ; i < ds_main_newempllist.rowcount ; i++) {
  241. grdf_setStatus(grd_foodmasterlist, "I", [i]);
  242. }
  243. cap_messege_title.style.background = "lightblue";
  244. cap_messege.text = "";
  245. }
  246. }
  247. function cf_TRRNB00016(sSvcId, nErrorCode, sErrorMsg) {
  248. arErrorCode.push(sSvcId, nErrorCode);
  249. }
  250. /****************************************************************************************
  251. * Components : Button
  252. * Description : 초기화
  253. ****************************************************************************************/
  254. function btn_init_onclick(obj:Button, e:ClickEventInfo)
  255. {
  256. lf_init();
  257. }
  258. /****************************************************************************************
  259. * Components : Button
  260. * Description : 엑셀입력
  261. ****************************************************************************************/
  262. function btn_importExcel_onclick(obj:Button, e:ClickEventInfo)
  263. {
  264. grdf_ImportExcel("ds_main_newempllist", 2, grd_foodmasterlist, 0);
  265. }
  266. /****************************************************************************************
  267. * Components : Button
  268. * Description : 저장
  269. ****************************************************************************************/
  270. function btn_save_onclick(obj:Button, e:ClickEventInfo)
  271. {
  272. if(ds_main_newempllist.rowcount < 1) return;
  273. dsf_setFixVal(ds_main_newempllist, "instcd:"+ds_send.getColumn(0,"instcd"));
  274. var oParam = {};
  275. oParam.id = "TXRNB00005";
  276. oParam.service = "sicksuapp.SicksuMngt";
  277. oParam.method = "reqSetFoodMasetList";
  278. oParam.inds = "req=ds_main_newempllist";
  279. oParam.outds = "";
  280. oParam.async = false;
  281. oParam.callback = "cf_TXRNB00005";
  282. tranf_submit(oParam);
  283. if(arErrorCode.pop("TXRNB00005") > -1) {
  284. cap_messege_title.style.background = "lightblue";
  285. cap_messege.text = "일괄저장이 완료되었습니다!";
  286. } else {
  287. cap_messege_title.style.background = "red";
  288. cap_messege.text = "데이터 저장에 실패하였습니다!";
  289. }
  290. }
  291. function cf_TXRNB00005(sSvcId, nErrorCode, sErrorMsg) {
  292. arErrorCode.push(sSvcId, nErrorCode);
  293. }
  294. ]]></Script>
  295. </Form>
  296. </FDL>