SMZUM01500_직종별바로가기.xfdl 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <FDL version="1.5">
  3. <TypeDefinition url="..\..\..\default_typedef.xml"/>
  4. <Form id="workform" position="absolute 0 0 1256 805" titletext="직종별 바로가기 등록">
  5. <Layouts>
  6. <Layout>
  7. <Static id="caption6" text="직종별 바로가기" class="tit_1" position="absolute 0 0 177 25"/>
  8. <Div id="grp_sea" anchor="left top right" taborder="1" style="align:center top;" class="div_SA" position="absolute 0 25 1256 67">
  9. <Layouts>
  10. <Layout>
  11. <Static id="caption3" text="직종코드" class="search_name" position="absolute 8 10 82 30"/>
  12. <Button id="btn_sea" taborder="14" text="조회" onlbuttonup="&quot;btn_sea_onlbuttonup&quot;" class="btn1" position="absolute 1188 10 1244 30" anchor="top right"/>
  13. <Static id="caption4" text="화면코드" class="search_name" position="absolute 221 10 295 30"/>
  14. <Combo id="cmb_jobkindcd" taborder="15" class="combo_search" position="absolute 82 10 197 30"/>
  15. <Edit id="input3" taborder="16" class="input_search" position="absolute 295 10 395 30" imemode="alpha"/>
  16. </Layout>
  17. </Layouts>
  18. </Div>
  19. <Static id="caption1" text="직종별 바로가기" class="tit_2" position="absolute 0 77 129 97"/>
  20. <Button id="btn_addrow" taborder="2" text="행추가" onlbuttonup="btn_addrow_onlbuttonup" class="btn2" position="absolute 1153 74 1209 94" anchor="top right"/>
  21. <Button id="btn_delete" taborder="3" text="삭제" onlbuttonup="btn_delete_onlbuttonup" class="btn2" position="absolute 1212 74 1256 94" anchor="top right"/>
  22. <Grid id="grd_jobkindlist" taborder="4" useinputpanel="false" position="absolute 0 97 1011 782" anchor="all">
  23. <Formats>
  24. <Format id="default">
  25. <Columns>
  26. <Column size="100"/>
  27. <Column size="130"/>
  28. <Column size="90"/>
  29. <Column size="40"/>
  30. <Column size="60"/>
  31. <Column size="40"/>
  32. <Column size="100"/>
  33. <Column size="75"/>
  34. <Column size="100"/>
  35. </Columns>
  36. <Rows>
  37. <Row size="22" band="head"/>
  38. <Row size="20"/>
  39. </Rows>
  40. <Band id="head">
  41. <Cell text="직종코드"/>
  42. <Cell col="1" text="바로가기명"/>
  43. <Cell col="2" text="화면ID"/>
  44. <Cell col="3" text="순서"/>
  45. <Cell col="4" text="표시형태"/>
  46. <Cell col="5"/>
  47. <Cell col="6" text="파라미터"/>
  48. <Cell col="7" text="iconcd"/>
  49. <Cell col="8"/>
  50. </Band>
  51. <Band id="body">
  52. <Cell/>
  53. <Cell col="1"/>
  54. <Cell col="2"/>
  55. <Cell col="3"/>
  56. <Cell col="4" class="text_center"/>
  57. <Cell col="5" style="align:center middle;"/>
  58. <Cell col="6"/>
  59. <Cell col="7"/>
  60. <Cell col="8"/>
  61. <Cell col="9"/>
  62. <Cell col="10"/>
  63. <Cell col="11"/>
  64. <Cell col="12"/>
  65. </Band>
  66. </Format>
  67. </Formats>
  68. </Grid>
  69. <Button id="btn_save" taborder="5" text="저장" onlbuttonup="btn_save_onlbuttonup" class="btn4" position="absolute 1200 785 1256 805" anchor="right bottom"/>
  70. <Grid id="grd_iconlist" taborder="6" useinputpanel="false" visible="true" position="absolute 1021 97 1256 782" anchor="top right bottom">
  71. <Formats>
  72. <Format id="default">
  73. <Columns>
  74. <Column size="40"/>
  75. <Column size="45"/>
  76. <Column size="50"/>
  77. <Column size="100"/>
  78. </Columns>
  79. <Rows>
  80. <Row size="22" band="head"/>
  81. <Row size="20"/>
  82. </Rows>
  83. <Band id="head">
  84. <Cell text="선택"/>
  85. <Cell col="1" text="아이콘"/>
  86. <Cell col="2" text="iconcd"/>
  87. <Cell col="3" text="iconurl"/>
  88. </Band>
  89. <Band id="body">
  90. <Cell/>
  91. <Cell col="1"/>
  92. <Cell col="2"/>
  93. <Cell col="3"/>
  94. <Cell col="4"/>
  95. </Band>
  96. </Format>
  97. </Formats>
  98. </Grid>
  99. </Layout>
  100. </Layouts>
  101. <Script type="xscript4.0"><![CDATA[/***************************************************************************************
  102. * System Name : HIT
  103. * Job Name :
  104. * File Name : SMZUM01500_직종별바로가기.xfdl
  105. * Creator :
  106. * Make Date : 2014-03-04
  107. *
  108. * Description :
  109. *---------------------------------------------------------------------------------------
  110. * Modify Date Modifier Modify Description
  111. *---------------------------------------------------------------------------------------
  112. * 2014-03-04 HIT Converting Program(TF->XP)
  113. *
  114. *---------------------------------------------------------------------------------------
  115. ****************************************************************************************/
  116. //=======================================================================================
  117. // Lib Include
  118. //---------------------------------------------------------------------------------------
  119. include "com_commonxp::common.xjs";
  120. include "com_commonxp::tfHelper.xjs";
  121. include "com_commonxp::stringHelper.xjs";
  122. include "com_basiccodexp::ZBC001.xjs";
  123. //=======================================================================================
  124. // Function
  125. //---------------------------------------------------------------------------------------
  126. //=======================================================================================
  127. // Event
  128. //---------------------------------------------------------------------------------------
  129. /****************************************************************************************
  130. * Components :
  131. * Components ID : model1
  132. * Event :
  133. * Argument : 01.obj : Object Event has occurred
  134. * : 02.e : Event Object
  135. * Description : Not Convert : xforms-model-construct-done
  136. ****************************************************************************************//* TF 이벤트 : xforms-model-construct-done
  137. function model1_(obj:Form, e:)
  138. {
  139. zbcfGetCodeList( new Array("R3004", "Z0014"), new Array("/root/init/R3004list", "/root/init/Z0014list") );
  140. addComboItem( "cmb_jobkindcd" , "전체", "");
  141. model.removeNodeset("/root/main/jobkindlist/rows");
  142. submit("TRZUM01502");
  143. }*/
  144. /****************************************************************************************
  145. * Components :
  146. * Components ID : model1
  147. * Event : oninit
  148. * Argument : 01.obj : Object Event has occurred
  149. * : 02.e : Event Object
  150. * Description :
  151. ****************************************************************************************/
  152. function model1_oninit(obj:Form, e:InitEventInfo)
  153. {
  154. fCheckAuth();
  155. fSetGridBackImage(grd_iconlist, 1);
  156. grd_jobkindlist.dataHeight = 30;
  157. }
  158. /****************************************************************************************
  159. * Components :
  160. * Components ID : btn_search
  161. * Event : onlbuttonup
  162. * Argument : 01.obj : Object Event has occurred
  163. * : 02.e : Event Object
  164. * Description :
  165. ****************************************************************************************/
  166. function btn_search_onlbuttonup(obj:Button, e:MouseEventInfo)
  167. {
  168. submit("TRZUM01501");
  169. fSetGridBackImage(grd_jobkindlist, 6);
  170. }
  171. /****************************************************************************************
  172. * Components :
  173. * Components ID : grd_jobkindlist
  174. * Event :
  175. * Argument : 01.obj : Object Event has occurred
  176. * : 02.e : Event Object
  177. * Description : Not Convert : xforms-select
  178. ****************************************************************************************//* TF 이벤트 : xforms-select
  179. function grd_jobkindlist_(obj:Grid, e:)
  180. {
  181. if(grd_jobkindlist.col == 1){ // 직종선택
  182. grd_jobkindlist.col = 2;
  183. grd_jobkindlist.dispatch("onentercell");
  184. // 불필요한 코드 삭제 - 김기호
  185. //grd_jobkindlist.editCell();
  186. }else if(grd_jobkindlist.col == 5){ // 아이콘선택
  187. //표시형태 선택시 처리
  188. var icontype = model.getValue("/root/main/jobkindlist/rows["+grd_jobkindlist.row+"]/icontype");
  189. if(icontype == "I"){
  190. grd_iconlist.visible = true;
  191. model.setFocus("grd_iconlist");
  192. }else{
  193. grd_iconlist.visible = false;
  194. grd_jobkindlist.col = 6;
  195. grd_jobkindlist.dispatch("onentercell");
  196. // 불필요한 코드 삭제 - 김기호
  197. //grd_jobkindlist.editCell();
  198. }
  199. }
  200. }*/
  201. /****************************************************************************************
  202. * Components :
  203. * Components ID : grd_jobkindlist
  204. * Event :
  205. * Argument : 01.obj : Object Event has occurred
  206. * : 02.e : Event Object
  207. * Description : Not Convert : onendedit
  208. ****************************************************************************************//* TF 이벤트 : onendedit
  209. function grd_jobkindlist_(obj:Grid, e:)
  210. {
  211. //iconText 입력시
  212. if( grd_jobkindlist.col == 6 ){
  213. var row = grd_jobkindlist.row;
  214. var iconText = model.getValue("/root/main/jobkindlist/rows[" + row + "]/icontext");
  215. if (iconText.getByteLength() > 8) {
  216. messageBox("한글 4글자, 영문 8글자를 초과", "E001");
  217. grd_jobkindlist.editCell();
  218. return;
  219. }
  220. model.setValue("/root/main/jobkindlist/rows["+row+"]/iconcd", "IDZUM10000");
  221. grd_jobkindlist.cellStyle("background-image", row, 6) = "../../../com/hismainweb/images/IDZUM10000.gif";
  222. grd_jobkindlist.cellStyle("background-position", row, 6) = "center";
  223. }
  224. // 김기호 - 버그삭제
  225. //grd_jobkindlist.col = grd_jobkindlist.col + 1;
  226. //grd_jobkindlist.dispatch("onentercell");
  227. //grd_jobkindlist.editCell();
  228. }*/
  229. /****************************************************************************************
  230. * Components :
  231. * Components ID : grd_jobkindlist
  232. * Event :
  233. * Argument : 01.obj : Object Event has occurred
  234. * : 02.e : Event Object
  235. * Description : Not Convert : onentercell
  236. ****************************************************************************************//* TF 이벤트 : onentercell
  237. function grd_jobkindlist_(obj:Grid, e:)
  238. {
  239. //화면아이디 입력
  240. if( grd_jobkindlist.col == 3 ){
  241. modal("SPZSA20500");
  242. var row = grd_jobkindlist.row;
  243. model.setValue("/root/main/jobkindlist/rows["+row+"]/scrncd", getParameter("SPZSA20500_").split("|")[0]);
  244. grd_jobkindlist.addStatus(row, "update");
  245. model.refresh();
  246. }
  247. }*/
  248. /****************************************************************************************
  249. * Components :
  250. * Components ID : grd_jobkindlist
  251. * Event :
  252. * Argument : 01.obj : Object Event has occurred
  253. * : 02.e : Event Object
  254. * Description : Not Convert : onkeypress
  255. ****************************************************************************************//* TF 이벤트 : onkeypress
  256. function grd_jobkindlist_(obj:Grid, e:)
  257. {
  258. // enter 를 통해서 입력을 마쳤을 경우만 화면ID 선택창 오픈 - 김기호
  259. if (grd_jobkindlist.col == 2 && event.keyCode == 13) {
  260. grd_jobkindlist.col = grd_jobkindlist.col + 1;
  261. grd_jobkindlist.dispatch("onentercell");
  262. }
  263. }*/
  264. /****************************************************************************************
  265. * Components :
  266. * Components ID : btn_addrow
  267. * Event : onlbuttonup
  268. * Argument : 01.obj : Object Event has occurred
  269. * : 02.e : Event Object
  270. * Description :
  271. ****************************************************************************************/
  272. function btn_addrow_onlbuttonup(obj:Button, e:MouseEventInfo)
  273. {
  274. grd_jobkindlist.addRow();
  275. grd_jobkindlist.isReadOnly(grd_jobkindlist.row, 1) = false;
  276. grd_jobkindlist.col = 1;
  277. grd_jobkindlist.dispatch("onentercell");
  278. }
  279. /****************************************************************************************
  280. * Components :
  281. * Components ID : grd_iconlist
  282. * Event :
  283. * Argument : 01.obj : Object Event has occurred
  284. * : 02.e : Event Object
  285. * Description : Not Convert : xforms-select
  286. ****************************************************************************************//* TF 이벤트 : xforms-select
  287. function grd_iconlist_(obj:Grid, e:)
  288. {
  289. if( grd_iconlist.col == 0){
  290. var row = grd_jobkindlist.row;
  291. var iconcd = model.getValue("/root/init/iconlist/rows[" +grd_iconlist.row+"]/iconcd");
  292. var iconurl = model.getValue("/root/init/iconlist/rows[" +grd_iconlist.row+"]/iconurl");
  293. model.setValue("/root/main/jobkindlist/rows["+row+"]/icontext", "");
  294. model.setValue("/root/main/jobkindlist/rows["+row+"]/iconcd", iconcd);
  295. grd_jobkindlist.cellStyle("background-image", row, 6) = "../../../"+ iconurl;
  296. grd_jobkindlist.cellStyle("background-position", row, 6) = "center";
  297. model.refresh();
  298. }
  299. }*/
  300. /****************************************************************************************
  301. * Components :
  302. * Components ID : btn_delete
  303. * Event : onlbuttonup
  304. * Argument : 01.obj : Object Event has occurred
  305. * : 02.e : Event Object
  306. * Description :
  307. ****************************************************************************************/
  308. function btn_delete_onlbuttonup(obj:Button, e:MouseEventInfo)
  309. {
  310. var row = grd_jobkindlist.row;
  311. grd_jobkindlist.deleteRow(row);
  312. }
  313. /****************************************************************************************
  314. * Components :
  315. * Components ID : btn_save
  316. * Event : onlbuttonup
  317. * Argument : 01.obj : Object Event has occurred
  318. * : 02.e : Event Object
  319. * Description :
  320. ****************************************************************************************/
  321. function btn_save_onlbuttonup(obj:Button, e:MouseEventInfo)
  322. {
  323. var updtdata = getGridUpdateData(grd_jobkindlist);
  324. if (updtdata == "") {
  325. messageBox("변경된 데이터가","I004");
  326. return;
  327. }
  328. var jobKindCd = "";
  329. var itemNm = "";
  330. var scrnCd = "";
  331. var seq = "";
  332. var iconType = "";
  333. var iconText = "";
  334. var menuParam = "";
  335. var iconCd = "";
  336. for( i = grd_jobkindlist.fixedRows; i < grd_jobkindlist.rows ; i++ ) {
  337. var status = grd_jobkindlist.rowStatus(i);
  338. if(status != 0){
  339. jobKindCd = grd_jobkindlist.valueMatrix(i,1);
  340. itemNm = grd_jobkindlist.valueMatrix(i,2);
  341. scrnCd = grd_jobkindlist.valueMatrix(i,3);
  342. seq = grd_jobkindlist.valueMatrix(i,4);
  343. iconType = grd_jobkindlist.valueMatrix(i,5);
  344. iconText = grd_jobkindlist.valueMatrix(i,6);
  345. menuParam = grd_jobkindlist.valueMatrix(i,7);
  346. iconCd = grd_jobkindlist.valueMatrix(i,8);
  347. if(jobKindCd == ""){
  348. messageBox("직종코드를","C002");
  349. grd_jobkindlist.row = i;
  350. grd_jobkindlist.col = 1;
  351. grd_jobkindlist.dispatch("onentercell");
  352. return;
  353. }
  354. if(itemNm == ""){
  355. messageBox("바로가기명을","C001");
  356. grd_jobkindlist.row = i;
  357. grd_jobkindlist.col = 2;
  358. grd_jobkindlist.dispatch("onentercell");
  359. return;
  360. }
  361. if(scrnCd == ""){
  362. messageBox("연결할 화면을","C002");
  363. grd_jobkindlist.row = i;
  364. grd_jobkindlist.col = 3;
  365. grd_jobkindlist.dispatch("onentercell");
  366. return;
  367. }
  368. if(seq == ""){
  369. messageBox("표시순서를","C001");
  370. grd_jobkindlist.row = i;
  371. grd_jobkindlist.col = 4;
  372. grd_jobkindlist.dispatch("onentercell");
  373. return;
  374. }
  375. if(iconType == ""){
  376. messageBox("표시형태를","C002");
  377. grd_jobkindlist.row = i;
  378. grd_jobkindlist.col = 5;
  379. grd_jobkindlist.dispatch("onentercell");
  380. return;
  381. }
  382. if(iconType == "T" && iconText == "" ){
  383. messageBox("표시할 텍스트를","C001");
  384. grd_jobkindlist.row = i;
  385. grd_jobkindlist.col = 6;
  386. grd_jobkindlist.dispatch("onentercell");
  387. grd_jobkindlist.editCell();
  388. return;
  389. }
  390. if(iconType == "I" && (iconCd == "" || iconCd == "IDZUM10000")){
  391. messageBox("표시할 아이콘을","C002");
  392. grd_jobkindlist.row = i;
  393. grd_iconlist.visible = true;
  394. model.setFocus("grd_iconlist");
  395. return;
  396. }
  397. if(menuParam != ""){
  398. if((isSearchString(menuParam, "<")
  399. || isSearchString(menuParam, ">")
  400. || isSearchString(menuParam, "&")
  401. || isSearchString(menuParam, "'")
  402. || isSearchString(menuParam, '"') )
  403. || (menuParam.split("|").length >1 )){
  404. messageBox("파라미터로 사용", "E001", "(<, >, &, "+ "'"+", "+'"'+",|)");
  405. return;
  406. }
  407. }
  408. }
  409. //insert시
  410. if(status == 1){
  411. model.setValue("/root/main/jobkindlist/rows["+i+"]/oldscrncd", scrncd);
  412. }
  413. }
  414. // alert("grid update data = " + grd_shortcutlist.getUpdateData());
  415. model.setValue("/root/send/jobkindlist", updtdata);
  416. if ( submit("TXZUM01501") ) {
  417. grd_jobkindlist.clearStatus(); // submit() 성공하면 그리드의 i,u,d 상태 제거
  418. }
  419. }
  420. ]]></Script>
  421. </Form>
  422. </FDL>