SMZBC00400_업무규칙관리.xfdl 26 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <FDL version="1.5">
  3. <TypeDefinition url="..\..\..\default_typedef.xml"/>
  4. <Form id="SMZBC00400" position="absolute 0 0 1199 805" titletext="업무규칙 관리" oninit="SMZBC00400_oninit" onload="SMZBC00400_onload">
  5. <Layouts>
  6. <Layout>
  7. <Static id="caption7" text="우편번호 앞자리" class="cell_1" position="absolute 0 631 100 654" anchor="left bottom" style="padding:0 0 0 3;"/>
  8. <Static id="caption24" text="업무규칙 ID" class="cell_1" position="absolute 0 631 100 654" anchor="left bottom"/>
  9. <Static id="caption6" text="업무규칙관리" class="tit_1" position="absolute 0 0 189 24"/>
  10. <Shape id="line5" linetype="horizontal" class="line_2" position="absolute 0 653 1195 659" anchor="left right bottom"/>
  11. <Div id="group2" taborder="1" class="div_SA2" position="absolute 0 66 1195 106" anchor="left top right">
  12. <Layouts>
  13. <Layout>
  14. <Shape id="line13" linetype="vertical" position="absolute 1099 9 1105 31" anchor="top right"/>
  15. <Button id="btn_search" taborder="1" text="조회" class="btn1" position="absolute 1122 8 1178 30" anchor="top right" onclick="group2_btn_search_onclick"/>
  16. <Edit id="ipt_search" taborder="2" class="input_search" position="absolute 126 10 276 29"/>
  17. <Combo id="combo1" taborder="3" codecolumn="codecolumn" datacolumn="datacolumn" class="combo_search" position="absolute 16 10 116 29" index="0" value="bizid" text="업무규칙ID">
  18. <Dataset id="innerdataset">
  19. <ColumnInfo>
  20. <Column id="codecolumn"/>
  21. <Column id="datacolumn"/>
  22. </ColumnInfo>
  23. <Rows>
  24. <Row>
  25. <Col id="codecolumn">bizid</Col>
  26. <Col id="datacolumn">업무규칙ID</Col>
  27. </Row>
  28. <Row>
  29. <Col id="codecolumn">biznm</Col>
  30. <Col id="datacolumn">업무규칙명</Col>
  31. </Row>
  32. </Rows>
  33. </Dataset>
  34. </Combo>
  35. </Layout>
  36. </Layouts>
  37. </Div>
  38. <Shape id="line1" linetype="horizontal" class="line_10" position="absolute 0 626 1195 632" anchor="left right bottom"/>
  39. <Static id="caption20" text="업무규칙 목록" class="tit_2" position="absolute 0 120 118 141"/>
  40. <Shape id="line8" class="line_10" position="absolute 0 136 1194 142" anchor="left top right"/>
  41. <Button id="btn_delete" taborder="3" text="삭제" class="btn2" position="absolute 1153 607 1195 626" anchor="right bottom" onclick="btn_delete_onclick"/>
  42. <Button id="btn_update" taborder="4" text="수정" class="btn2" position="absolute 1110 607 1152 626" anchor="right bottom" onclick="btn_update_onclick"/>
  43. <Static id="caption22" text="업무규칙 &#13;&#10;상세설명" class="cell_1" position="absolute 0 657 100 792" anchor="left bottom"/>
  44. <TextArea id="tar_bizdesc" taborder="5" position="absolute 105 658 1195 791" autoselect="true" anchor="left right bottom"/>
  45. <Combo id="cmb_delyn" taborder="6" codecolumn="codecolumn" datacolumn="datacolumn" class="combo_essential" position="absolute 503 633 548 652" anchor="left bottom">
  46. <Dataset id="innerdataset">
  47. <ColumnInfo>
  48. <Column id="codecolumn"/>
  49. <Column id="datacolumn"/>
  50. </ColumnInfo>
  51. <Rows>
  52. <Row>
  53. <Col id="codecolumn">Y</Col>
  54. <Col id="datacolumn">Y</Col>
  55. </Row>
  56. <Row>
  57. <Col id="codecolumn">N</Col>
  58. <Col id="datacolumn">N</Col>
  59. </Row>
  60. </Rows>
  61. </Dataset>
  62. </Combo>
  63. <Button id="btn_add" taborder="7" text="추가" class="btn2" position="absolute 1067 607 1109 626" anchor="right bottom" onclick="btn_add_onclick"/>
  64. <Static id="caption1" text="업무규칙 이름" class="cell_1" position="absolute 195 631 295 654" anchor="left bottom"/>
  65. <Edit id="ipt_biznm" taborder="8" class="input_essential" position="absolute 300 633 393 652" autoselect="true" anchor="left bottom"/>
  66. <Static id="caption3" text="삭제여부" class="cell_1" position="absolute 398 631 498 654" anchor="left bottom"/>
  67. <Edit id="ipt_bizid" taborder="9" class="input_essential" position="absolute 105 633 190 652" autoselect="true" anchor="left bottom"/>
  68. <Shape id="line7" linetype="vertical" class="line_3" position="absolute 0 788 1194 794"/>
  69. <Grid id="grd_bizlist" taborder="10" binddataset="ds_main_bizlist_biz" useinputpanel="false" position="absolute 0 141 1194 598" autoenter="select" cellsizingtype="col" anchor="all" oncelldblclick="grd_bizlist_oncelldblclick">
  70. <Formats>
  71. <Format id="default">
  72. <Columns>
  73. <Column size="20" band="left"/>
  74. <Column size="100"/>
  75. <Column size="150"/>
  76. <Column size="200"/>
  77. <Column size="68"/>
  78. <Column size="100"/>
  79. <Column size="100"/>
  80. <Column size="100"/>
  81. <Column size="100"/>
  82. <Column size="99"/>
  83. <Column size="100"/>
  84. <Column size="150"/>
  85. <Column size="101"/>
  86. <Column size="100"/>
  87. <Column size="150"/>
  88. </Columns>
  89. <Rows>
  90. <Row size="24" band="head"/>
  91. <Row size="24"/>
  92. </Rows>
  93. <Band id="head">
  94. <Cell/>
  95. <Cell col="1" text="업무규칙ID"/>
  96. <Cell col="2" text="업무규칙명"/>
  97. <Cell col="3" text="상세설명"/>
  98. <Cell col="4" text="삭제여부"/>
  99. <Cell col="5" text="권한기관코드"/>
  100. <Cell col="6" text="권한기관명"/>
  101. <Cell col="7" text="권한부서코드"/>
  102. <Cell col="8" text="권한부서명"/>
  103. <Cell col="9" text="최초등록자ID"/>
  104. <Cell col="10" text="최초등록자이름"/>
  105. <Cell col="11" text="최초등록일시"/>
  106. <Cell col="12" text="최종수정자ID"/>
  107. <Cell col="13" text="최종수정자이름"/>
  108. <Cell col="14" text="최종수정일시"/>
  109. </Band>
  110. <Band id="body">
  111. <Cell celltype="head"/>
  112. <Cell col="1" style="align:left middle;padding:2 2 2 2;" text="bind:bizid"/>
  113. <Cell col="2" style="align:left middle;padding:2 2 2 2;" text="bind:biznm"/>
  114. <Cell col="3" style="align:left middle;padding:2 2 2 2;" text="bind:detldesc"/>
  115. <Cell col="4" style="align:left middle;padding:2 2 2 2;" text="bind:delyn"/>
  116. <Cell col="5" style="align:left middle;padding:2 2 2 2;" text="bind:authinstcd"/>
  117. <Cell col="6" style="align:left middle;padding:2 2 2 2;" text="bind:authinstnm"/>
  118. <Cell col="7" style="align:left middle;padding:2 2 2 2;" text="bind:authdeptcd"/>
  119. <Cell col="8" style="align:left middle;padding:2 2 2 2;" text="bind:authdeptnm"/>
  120. <Cell col="9" style="align:left middle;padding:2 2 2 2;" text="bind:fstrgstrid"/>
  121. <Cell col="10" style="align:left middle;padding:2 2 2 2;" text="bind:fstrgstrnm"/>
  122. <Cell col="11" displaytype="date" style="align:left middle;padding:2 2 2 2;" text="bind:fstrgstdt" mask="yyyy-MM-dd HH:mm:ss" calendardisplaynulltype="nulltext"/>
  123. <Cell col="12" style="align:left middle;padding:2 2 2 2;" text="bind:lastupdtrid"/>
  124. <Cell col="13" style="align:left middle;padding:2 2 2 2;" text="bind:lastupdtrnm"/>
  125. <Cell col="14" displaytype="date" style="align:left middle;padding:2 2 2 2;" text="bind:lastupdtdt" mask="yyyy-MM-dd HH:mm:ss" calendardisplaynulltype="nulltext"/>
  126. </Band>
  127. </Format>
  128. </Formats>
  129. </Grid>
  130. <Shape id="line14" class="line_6" position="absolute 0 62 1194 68" anchor="left top right"/>
  131. <Button id="btn_save" taborder="11" text="저장" class="btn4" position="absolute 1067 41 1123 63" anchor="top right" onclick="btn_save_onclick"/>
  132. <Button id="btn_init" taborder="12" text="초기화" class="btn4" position="absolute 1126 41 1194 63" anchor="top right" onclick="btn_init_onclick"/>
  133. <Button id="btn_saveexcel" taborder="13" text="엑셀저장" class="btn7" position="absolute 1114 117 1194 136" anchor="top right" onclick="btn_saveexcel_onclick"/>
  134. <Static id="opt_modellabel" class="tit_2" position="absolute 0 610 342 631" anchor="left bottom"/>
  135. </Layout>
  136. </Layouts>
  137. <Objects>
  138. <Dataset id="ds_main_search" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  139. <ColumnInfo>
  140. <Column id="searchcondition" type="STRING" size="256"/>
  141. <Column id="searchterm" type="STRING" size="256"/>
  142. </ColumnInfo>
  143. <Rows>
  144. <Row>
  145. <Col id="searchcondition">bizid</Col>
  146. <Col id="searchterm"/>
  147. </Row>
  148. </Rows>
  149. </Dataset>
  150. <Dataset id="ds_main_bizlist_biz" firefirstcount="0" firenextcount="0" useclientlayout="true" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  151. <ColumnInfo>
  152. <Column id="bizid" type="STRING" size="256" sumtext="업무ID"/>
  153. <Column id="biznm" type="STRING" size="256" sumtext="업무이름"/>
  154. <Column id="detldesc" type="STRING" size="256" sumtext="업무상세설명"/>
  155. <Column id="delyn" type="STRING" size="256" sumtext="삭제여부"/>
  156. <Column id="authinstcd" type="STRING" size="256" sumtext="권한기관코드"/>
  157. <Column id="authinstnm" type="STRING" size="256" sumtext="권한기관이름"/>
  158. <Column id="authdeptcd" type="STRING" size="256" sumtext="권한부서코드"/>
  159. <Column id="authdeptnm" type="STRING" size="256" sumtext="권한부서이름"/>
  160. <Column id="fstrgstrid" type="STRING" size="256" sumtext="최초등록자ID"/>
  161. <Column id="fstrgstrnm" type="STRING" size="256" sumtext="최초등록자이름"/>
  162. <Column id="fstrgstdt" type="STRING" size="256" sumtext="최초등록일시"/>
  163. <Column id="lastupdtrid" type="STRING" size="256" sumtext="최종수정자ID"/>
  164. <Column id="lastupdtrnm" type="STRING" size="256" sumtext="최종수정자이름"/>
  165. <Column id="lastupdtdt" type="STRING" size="256" sumtext="최종수정일시"/>
  166. </ColumnInfo>
  167. </Dataset>
  168. <Dataset id="ds_send_data" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  169. <Dataset id="ds_main_mode" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  170. <ColumnInfo>
  171. <Column id="modestatus" type="STRING" size="256"/>
  172. <Column id="modelabel" type="STRING" size="256"/>
  173. </ColumnInfo>
  174. <Rows>
  175. <Row>
  176. <Col id="modestatus"/>
  177. <Col id="modelabel"/>
  178. </Row>
  179. </Rows>
  180. </Dataset>
  181. <Dataset id="ds_main_data" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  182. <ColumnInfo>
  183. <Column id="bizid" type="STRING" size="256"/>
  184. <Column id="biznm" type="STRING" size="256"/>
  185. <Column id="fstrgstrid" type="STRING" size="256"/>
  186. <Column id="lastrgstdt" type="STRING" size="256"/>
  187. <Column id="lastrgstrid" type="STRING" size="256"/>
  188. <Column id="delyn" type="STRING" size="256"/>
  189. <Column id="detldesc" type="STRING" size="256"/>
  190. </ColumnInfo>
  191. <Rows>
  192. <Row>
  193. <Col id="bizid"/>
  194. <Col id="biznm"/>
  195. <Col id="fstrgstrid"/>
  196. <Col id="lastrgstdt"/>
  197. <Col id="lastrgstrid"/>
  198. <Col id="delyn"/>
  199. <Col id="detldesc"/>
  200. </Row>
  201. </Rows>
  202. </Dataset>
  203. </Objects>
  204. <Bind>
  205. <BindItem id="item0" compid="opt_modellabel" propid="text" datasetid="ds_main_mode" columnid="modelabel"/>
  206. <BindItem id="item1" compid="tar_bizdesc" propid="value" datasetid="ds_main_data" columnid="detldesc"/>
  207. <BindItem id="item2" compid="cmb_delyn" propid="value" datasetid="ds_main_data" columnid="delyn"/>
  208. <BindItem id="item3" compid="ipt_biznm" propid="value" datasetid="ds_main_data" columnid="biznm"/>
  209. <BindItem id="item4" compid="ipt_bizid" propid="value" datasetid="ds_main_data" columnid="bizid"/>
  210. </Bind>
  211. <Script type="xscript4.0"><![CDATA[/***************************************************************************************
  212. * System Name :
  213. * Job Name :
  214. * Creator :
  215. * Make Date : 2017-09-20
  216. * Description :
  217. *---------------------------------------------------------------------------------------
  218. * Modify Date Modifier Modify Description
  219. *---------------------------------------------------------------------------------------
  220. * 2017-09-20 Live Converter TF->XP
  221. *
  222. *---------------------------------------------------------------------------------------
  223. ****************************************************************************************/
  224. include "com_commonxp::comm_main.xjs";
  225. include "com_basiccodexp::ZBC001.xjs";
  226. function SMZBC00400_oninit(obj:Form, e:InitEventInfo)
  227. {
  228. frmf_initForm(obj);
  229. }
  230. function SMZBC00400_onload(obj:Form, e:LoadEventInfo)
  231. {
  232. grdf_initGrid(grd_bizlist);
  233. grdf_setRowTypeIcon(grd_bizlist, 0);
  234. ds_main_search.setColumn(0, "searchcondition", "bizid");
  235. ds_main_search.setColumn(0, "searchterm", "");
  236. fInitMainData(true);
  237. }
  238. /****************************************************************************************
  239. * Function : onclick
  240. * Description : 조회 버튼 이벤트
  241. ****************************************************************************************/
  242. function group2_btn_search_onclick(obj:Button, e:ClickEventInfo)
  243. {
  244. fGetBizList();
  245. }
  246. /****************************************************************************************
  247. * Function : oncelldblclick
  248. * Description : 그리드 더블클릭 이벤트
  249. ****************************************************************************************/
  250. function grd_bizlist_oncelldblclick(obj:Grid, e:GridClickEventInfo)
  251. {
  252. fGetBiz();
  253. }
  254. /****************************************************************************************
  255. * Function : onclick
  256. * Description : 엑셀저장 버튼 이벤트
  257. ****************************************************************************************/
  258. function btn_saveexcel_onclick(obj:Button, e:ClickEventInfo)
  259. {
  260. grdf_exportExcel(grd_bizlist, "excel", "Sheet1", "true", "", "");
  261. }
  262. /****************************************************************************************
  263. * Function : onclick
  264. * Description : 저장 버튼 이벤트
  265. ****************************************************************************************/
  266. function btn_save_onclick(obj:Button, e:ClickEventInfo)
  267. {
  268. var result;
  269. var mode = ds_main_mode.getColumn(0, "modestatus");
  270. var bizid;
  271. if(mode=="view")
  272. {
  273. sysf_messageBox("조회중인 정보를 저장", 'E001') ;
  274. return;
  275. }
  276. else if(mode=="insert")
  277. {
  278. if(!fValidateMainData()) return false;
  279. bizid = utlf_transNullToEmpty(ds_main_data.getColumn(0, "bizid"));
  280. var biznm = utlf_transNullToEmpty(ds_main_data.getColumn(0, "biznm"));
  281. result = sysf_messageBox("[업무규칙 ID : "+bizid+",업무규칙 이름 : "+biznm+"]을 추가", "S001");
  282. if( result==7 || result == 2 ) return;
  283. ds_send_data.copyData(ds_main_data);
  284. var oParam = {};
  285. oParam.id = "TRZBC00112";
  286. oParam.service = "basiccodeapp.KindCodeAdmin";
  287. oParam.method = "reqInsBizRule";
  288. oParam.inds = "req=ds_send_data";
  289. oParam.async = false;
  290. //oParam.callback = "cf_TRZBC00112";
  291. tranf_submit(oParam);
  292. }
  293. else if(mode=="update")
  294. {
  295. if(!fValidateMainData()) return false;
  296. bizid = utlf_transNullToEmpty(ds_main_data.getColumn(0, "bizid"));
  297. var biznm = utlf_transNullToEmpty(ds_main_data.getColumn(0, "biznm"));
  298. result = sysf_messageBox( "[업무규칙 ID : "+bizid+",업무규칙 이름 : "+biznm+"]을 수정", "S001");
  299. if( result==7 || result == 2 ) return;
  300. ds_send_data.copyData(ds_main_data);
  301. var oParam = {};
  302. oParam.id = "TRZBC00113";
  303. oParam.service = "basiccodeapp.KindCodeAdmin";
  304. oParam.method = "reqSetBizRule";
  305. oParam.inds = "req=ds_send_data";
  306. oParam.async = false;
  307. //oParam.callback = "cf_TRZBC00113";
  308. tranf_submit(oParam);
  309. }
  310. else if(mode=="delete")
  311. {
  312. if(!fValidateMainData()) return false;
  313. bizid = ds_main_data.getColumn(0, "bizid");
  314. var biznm = ds_main_data.getColumn(0, "biznm");
  315. result = sysf_messageBox("[업무규칙 ID : "+bizid+",업무규칙 이름 : "+biznm+"]을 삭제", "S001");
  316. if( result==7 || result == 2 ) return;
  317. ds_send_data.copyData(ds_main_data);
  318. var oParam = {};
  319. oParam.id = "TRZBC00114";
  320. oParam.service = "basiccodeapp.KindCodeAdmin";
  321. oParam.method = "reqDelBizRule";
  322. oParam.inds = "req=ds_send_data";
  323. oParam.async = false;
  324. //oParam.callback = "cf_TRZBC00114";
  325. tranf_submit(oParam);
  326. }
  327. else
  328. {
  329. sysf_messageBox('처리 모드를', 'C002');
  330. return;
  331. }
  332. fGetBizList();
  333. if(mode!="delete")
  334. {
  335. fFindBiz(bizid);
  336. fGetBiz();
  337. }
  338. else
  339. {
  340. fInitMain();
  341. }
  342. }
  343. /****************************************************************************************
  344. * Function : onclick
  345. * Description : 초기화 버튼 이벤트
  346. ****************************************************************************************/
  347. function btn_init_onclick(obj:Button, e:ClickEventInfo)
  348. {
  349. this.reload();
  350. }
  351. /****************************************************************************************
  352. * Function : onclick
  353. * Description : 추가 버튼 이벤트
  354. ****************************************************************************************/
  355. function btn_add_onclick(obj:Button, e:ClickEventInfo)
  356. {
  357. fInitMainData(false);
  358. ds_main_mode.setColumn(0, "insert");
  359. ds_main_mode.setColumn(0, "modelabel", "업무규칙 관리>업무규칙 추가");
  360. ds_main_mode.setColumn(0, "modestatus", "insert");
  361. ds_main_data.setColumn(0, "delyn", "N");
  362. cmb_delyn.enable = false;
  363. }
  364. /****************************************************************************************
  365. * Function : onclick
  366. * Description : 수정 버튼 이벤트
  367. ****************************************************************************************/
  368. function btn_update_onclick(obj:Button, e:ClickEventInfo)
  369. {
  370. var authinstcd = ds_main_bizlist_biz.getColumn(ds_main_bizlist_biz.rowposition, "authinstcd");
  371. var authdeptcd = ds_main_bizlist_biz.getColumn(ds_main_bizlist_biz.rowposition, "authdeptcd");
  372. var authrized = fAuthorize(authinstcd, authdeptcd);
  373. if(authrized)
  374. {
  375. fSettBiz();
  376. }
  377. else
  378. {
  379. var userinfo = fGetUserInfo();
  380. sysf_messageBox(userinfo+" 는 수정할", "E002") ;
  381. }
  382. }
  383. /****************************************************************************************
  384. * Function : onclick
  385. * Description : 삭제 버튼 이벤트
  386. ****************************************************************************************/
  387. function btn_delete_onclick(obj:Button, e:ClickEventInfo)
  388. {
  389. var authinstcd = ds_main_bizlist_biz.getColumn(ds_main_bizlist_biz.rowposition, "authinstcd");
  390. var authdeptcd = ds_main_bizlist_biz.getColumn(ds_main_bizlist_biz.rowposition, "authdeptcd");
  391. var authrized = fAuthorize(authinstcd, authdeptcd);
  392. if(authrized)
  393. {
  394. fDelBiz();
  395. }
  396. else
  397. {
  398. var userinfo = fGetUserInfo();
  399. sysf_messageBox(userinfo+" 는 삭제할", "E002") ;
  400. }
  401. }
  402. /****************************************************************************************
  403. * Function : fInitMainDataControls
  404. * Description : 컴포넌트 활성화/비활성화 설정
  405. ****************************************************************************************/
  406. function fInitMainDataControls(disabled)
  407. {
  408. ipt_bizid.enable = !disabled;
  409. ipt_biznm.enable = !disabled;
  410. tar_bizdesc.enable = !disabled;
  411. cmb_delyn.enable = !disabled;
  412. }
  413. /****************************************************************************************
  414. * Function : fGetBizList
  415. * Description : 조회 함수
  416. ****************************************************************************************/
  417. function fGetBizList()
  418. {
  419. var searchterm = ds_main_search.getColumn(0, "searchterm");
  420. if(utlf_isNull(searchterm))
  421. {
  422. searchterm = "";
  423. }
  424. ds_send_data.copyData(ds_main_search);
  425. ds_send_data.setColumn(0, "searchterm", "%"+searchterm+"%");
  426. var oParam = {};
  427. oParam.id = "TRZBC00115";
  428. oParam.service = "basiccodeapp.KindCodeAdmin";
  429. oParam.method = "reqGetBizRuleList";
  430. oParam.inds = "req=ds_send_data";
  431. oParam.outds = "ds_main_bizlist_biz=biz";
  432. oParam.async = false;
  433. //oParam.callback = "cf_TRZBC00115";
  434. tranf_submit(oParam);
  435. }
  436. /****************************************************************************************
  437. * Function : fGetBiz
  438. * Description : 그리드 더블 클릭 시 호출되는 함수
  439. ****************************************************************************************/
  440. function fGetBiz()
  441. {
  442. var result = fGrid2Main();
  443. if(result)
  444. {
  445. ds_main_mode.setColumn(0, "modelabel", "업무규칙 관리>업무규칙 상세보기");
  446. ds_main_mode.setColumn(0, "modestatus", "view");
  447. fInitMainDataControls(true);
  448. }
  449. else
  450. {
  451. sysf_messageBox('대상 업무규칙을', 'C002');
  452. }
  453. }
  454. /****************************************************************************************
  455. * Function : fGrid2Main
  456. * Description :
  457. ****************************************************************************************/
  458. function fGrid2Main()
  459. {
  460. row = ds_main_bizlist_biz.rowposition;
  461. if(row < 0) return false;
  462. ds_main_data.copyData(ds_main_bizlist_biz);
  463. ds_main_data.clearData();
  464. ds_main_data.copyRow(ds_main_data.addRow(), ds_main_bizlist_biz, row);
  465. return true;
  466. }
  467. /****************************************************************************************
  468. * Function : fValidateMainData
  469. * Description : 저장 시 값 체크
  470. ****************************************************************************************/
  471. function fValidateMainData()
  472. {
  473. var bizid = ds_main_data.getColumn(0, "bizid");
  474. if( utlf_isNull(bizid))
  475. {
  476. sysf_messageBox("업무규칙 ID를" , "C001");
  477. ipt_bizid.setFocus();
  478. return false;
  479. }
  480. if( String(bizid).length != 5 )
  481. {
  482. sysf_messageBox("업무규칙의 길이는 5자리", "E008");
  483. ipt_bizid.setFocus();
  484. return false;
  485. }
  486. var biznm = ds_main_data.getColumn(0, "biznm");
  487. if( utlf_isNull(biznm))
  488. {
  489. sysf_messageBox("업무규칙 이름을", "C001");
  490. ipt_biznm.setFocus();
  491. return false;
  492. }
  493. var delyn = ds_main_data.getColumn(0, "delyn");
  494. if( utlf_isNull(delyn))
  495. {
  496. ds_main_data.setColumn(0, "delyn", "N");
  497. }
  498. var bizdesc = ds_main_data.getColumn(0, "detldesc");
  499. if( utlf_isNull(bizdesc))
  500. {
  501. sysf_messageBox("업무규칙 상세설명을", "C001");
  502. tar_bizdesc.setFocus();
  503. return false;
  504. }
  505. return true;
  506. }
  507. /****************************************************************************************
  508. * Function : fFindBiz
  509. * Description :
  510. ****************************************************************************************/
  511. function fFindBiz(bizid)
  512. {
  513. fFindGridItem(grd_bizlist, 1, bizid);
  514. }
  515. /****************************************************************************************
  516. * Function : fInitMain
  517. * Description :
  518. ****************************************************************************************/
  519. function fInitMain()
  520. {
  521. ds_main_mode.setColumn(0, "modelabel", "");
  522. ds_main_mode.setColumn(0, "modestatus", "");
  523. fInitMainData(true);
  524. }
  525. /****************************************************************************************
  526. * Function : fInitMainData
  527. * Description :
  528. ****************************************************************************************/
  529. function fInitMainData(disabled)
  530. {
  531. ds_main_data.setColumn(0, "bizid", "");
  532. ds_main_data.setColumn(0, "biznm", "");
  533. ds_main_data.setColumn(0, "detldesc", "");
  534. ds_main_data.setColumn(0, "delyn", "");
  535. fInitMainDataControls(disabled);
  536. }
  537. /****************************************************************************************
  538. * Function : fSettBiz
  539. * Description : 수정 이벤트 함수
  540. ****************************************************************************************/
  541. function fSettBiz()
  542. {
  543. var result = fGrid2Main();
  544. if(result)
  545. {
  546. ds_main_mode.setColumn(0, "modelabel", "업무규칙 관리>업무규칙 수정");
  547. ds_main_mode.setColumn(0, "modestatus", "update");
  548. fInitMainDataControls(false);
  549. ipt_bizid.enable = false;
  550. }
  551. else
  552. {
  553. sysf_messageBox('수정할 대상 업무규칙을', 'C002');
  554. }
  555. }
  556. /****************************************************************************************
  557. * Function : fDelBiz
  558. * Description : 삭제 이벤트 함수
  559. ****************************************************************************************/
  560. function fDelBiz()
  561. {
  562. var result = fGrid2Main();
  563. if(result)
  564. {
  565. ds_main_mode.setColumn(0, "modelabel", "업무규칙 관리>업무규칙 삭제");
  566. ds_main_mode.setColumn(0, "modestatus", "delete");
  567. fInitMainDataControls(true);
  568. }
  569. else
  570. {
  571. sysf_messageBox('삭제할 대상 업무규칙을', 'C002');
  572. }
  573. }
  574. ]]></Script>
  575. </Form>
  576. </FDL>