SPMNG00401_세탁물청구부서코드HELP.xfdl 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <FDL version="1.5">
  3. <TypeDefinition url="..\..\..\default_typedef.xml"/>
  4. <Form id="SPMNG00401" position="absolute 0 0 590 550" titletext="세탁물청구부서코드 HELP" oninit="SPMNG00401_oninit" onload="SPMNG00401_onload">
  5. <Layouts>
  6. <Layout>
  7. <Div position="absolute 0 0 582 520" id="group3" scrollbars="autoboth">
  8. <Layouts>
  9. <Layout>
  10. <Div position="absolute 0 0 580 30" id="group2" anchor="default">
  11. <Layouts>
  12. <Layout>
  13. <Shape position="absolute 0 0 580 29" id="roundrect1" class="roundrect_search" type="roundrectangle" anchor="default"/>
  14. <Button position="absolute 519 4 575 26" id="btn_search" class="btn1" text="조회" onclick="group3_group2_btn_search_onclick" anchor="default"/>
  15. <Shape position="absolute 512 0 518 29" linetype="vertical" id="line13" class="line_4" anchor="default"/>
  16. <Static text="조회조건:" position="absolute 10 6 96 23" id="caption2" class="search_name" anchor="default"/>
  17. <Combo position="absolute 100 5 200 24" id="cmb_dept" innerdataset="@ds_main_csrdeptlist" datacolumn="deptnm" codecolumn="deptcd" onitemchanged="group3_group2_cmb_dept_onitemchanged" anchor="default"/>
  18. </Layout>
  19. </Layouts>
  20. </Div>
  21. <Static text="하위부서 리스트" position="absolute 0 45 117 61" id="caption1" class="tit_2" anchor="default"/>
  22. <Shape position="absolute 0 61 580 67" linetype="horizontal" id="line1" class="line_10" anchor="default"/>
  23. <Grid position="absolute 0 65 582 520" id="grd_deptlist" binddataset="ds_main_deptcodelist" onexpanddown="group3_grd_deptlist_onexpanddown" anchor="default" cellsizingtype="both" extendsizetype="row">
  24. <Formats>
  25. <Format id="default">
  26. <Columns>
  27. <Column size="25" band="left"/>
  28. <Column size="144"/>
  29. <Column size="230"/>
  30. <Column size="100"/>
  31. <Column size="0"/>
  32. <Column size="0"/>
  33. <Column size="0"/>
  34. <Column size="0"/>
  35. </Columns>
  36. <Rows>
  37. <Row size="24" band="head"/>
  38. <Row size="24"/>
  39. </Rows>
  40. <Band id="head">
  41. <Cell/>
  42. <Cell col="1" text="부서코드"/>
  43. <Cell col="2" text="부서명"/>
  44. <Cell col="3" text="부서구분"/>
  45. <Cell col="4"/>
  46. <Cell col="5"/>
  47. <Cell col="6"/>
  48. <Cell col="7"/>
  49. </Band>
  50. <Band id="body">
  51. <Cell celltype="head"/>
  52. <Cell col="1" displaytype="text" edittype="expand" class="input_essential" text="bind:deptcd" expandshow="show"/>
  53. <Cell col="2" text="bind:deptnm"/>
  54. <Cell col="3" displaytype="combo" edittype="combo" style="align:center middle;" class="input_essential" text="bind:csrreqdeptcd" combodataset="ds_main_csrreqdeptlist" combocodecol="csrreqdeptcd" combodatacol="csrreqdeptnm"/>
  55. <Cell col="4" text="bind:supdeptcd"/>
  56. <Cell col="5" text="bind:supdeptnm"/>
  57. <Cell col="6" text="bind:userid"/>
  58. <Cell col="7" text="bind:useyn"/>
  59. </Band>
  60. </Format>
  61. </Formats>
  62. </Grid>
  63. <Button position="absolute 530 40 570 60" id="btn_save" class="btn5" text="저장" onclick="group3_btn_save_onclick" anchor="default"/>
  64. <Button position="absolute 415 40 468 60" id="button1" class="btn2" text="행추가" onclick="group3_button1_onclick" anchor="default"/>
  65. <Button position="absolute 470 40 523 60" id="btn_del" class="btn2" text="행삭제" onclick="group3_btn_del_onclick" anchor="default"/>
  66. </Layout>
  67. </Layouts>
  68. </Div>
  69. <Div position="absolute 0 521 580 548" id="group1" scrollbars="autoboth">
  70. <Layouts>
  71. <Layout>
  72. <Button position="absolute 461 2 517 24" id="btn_confirm" class="btn4" text="확인" onclick="group1_btn_confirm_onclick"/>
  73. <Button position="absolute 520 2 576 24" id="btn_cancel" class="btn4" text="취소" onclick="group1_btn_cancel_onclick"/>
  74. </Layout>
  75. </Layouts>
  76. </Div>
  77. </Layout>
  78. </Layouts>
  79. <Objects>
  80. <Dataset id="ds_main_deptcodelist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  81. <ColumnInfo>
  82. <Column id="deptcd" type="STRING" size="256"/>
  83. <Column id="deptnm" type="STRING" size="256"/>
  84. <Column id="csrreqdeptcd" type="STRING" size="256"/>
  85. <Column id="supdeptnm" type="STRING" size="256"/>
  86. <Column id="userid" type="STRING" size="256"/>
  87. <Column id="useyn" type="STRING" size="256"/>
  88. </ColumnInfo>
  89. <Rows>
  90. <Row>
  91. <Col id="deptcd"/>
  92. <Col id="deptnm"/>
  93. <Col id="csrreqdeptcd"/>
  94. <Col id="supdeptnm"/>
  95. <Col id="userid"/>
  96. <Col id="useyn"/>
  97. </Row>
  98. </Rows>
  99. </Dataset>
  100. <Dataset id="ds_main_cond" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  101. <ColumnInfo>
  102. <Column id="deptcd" type="STRING" size="256"/>
  103. </ColumnInfo>
  104. <Rows>
  105. <Row/>
  106. </Rows>
  107. </Dataset>
  108. <Dataset id="ds_main_csrdeptlist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  109. <Dataset id="ds_target" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  110. <Dataset id="ds_init_refcond" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  111. <ColumnInfo>
  112. <Column id="label" type="STRING" size="256"/>
  113. <Column id="value" type="STRING" size="256"/>
  114. </ColumnInfo>
  115. <Rows>
  116. <Row>
  117. <Col id="label">부서코드</Col>
  118. <Col id="value">deptcd</Col>
  119. </Row>
  120. <Row>
  121. <Col id="label">부서명</Col>
  122. <Col id="value">deptnm</Col>
  123. </Row>
  124. </Rows>
  125. </Dataset>
  126. <Dataset id="ds_send_deptref" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  127. <ColumnInfo>
  128. <Column id="refcond" type="STRING" size="256"/>
  129. <Column id="deptnm" type="STRING" size="256"/>
  130. <Column id="deptcd" type="STRING" size="256"/>
  131. <Column id="instcd" type="STRING" size="256"/>
  132. </ColumnInfo>
  133. <Rows>
  134. <Row>
  135. <Col id="refcond"/>
  136. <Col id="deptnm"/>
  137. <Col id="deptcd"/>
  138. <Col id="instcd"/>
  139. </Row>
  140. </Rows>
  141. </Dataset>
  142. <Dataset id="ds_send_comcdref" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  143. <ColumnInfo>
  144. <Column id="cdgrupid" type="STRING" size="256"/>
  145. <Column id="cdid" type="STRING" size="256"/>
  146. <Column id="cdnm" type="STRING" size="256"/>
  147. </ColumnInfo>
  148. <Rows>
  149. <Row>
  150. <Col id="cdgrupid"/>
  151. <Col id="cdid"/>
  152. <Col id="cdnm"/>
  153. </Row>
  154. </Rows>
  155. </Dataset>
  156. <Dataset id="ds_send_reqdata" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  157. <ColumnInfo>
  158. <Column id="deptcd" type="STRING" size="256"/>
  159. </ColumnInfo>
  160. <Rows>
  161. <Row/>
  162. </Rows>
  163. </Dataset>
  164. <Dataset id="ds_main_csrreqdeptlist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  165. <Dataset id="ds_send" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  166. <Dataset id="ds_copynode" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  167. <Dataset id="ds_send_reqdata1_reqdeptinfo" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  168. <Dataset id="ds_send_reqdata2_csrreqdept" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  169. </Objects>
  170. <Bind>
  171. <BindItem id="item0" compid="group3.group2.cmb_dept" propid="value" datasetid="ds_main_cond" columnid="deptcd"/>
  172. </Bind>
  173. <Script type="xscript4.0"><![CDATA[/***************************************************************************************
  174. * System Name :
  175. * Job Name :
  176. * Creator :
  177. * Make Date : 2015-11-13
  178. * Description :
  179. *---------------------------------------------------------------------------------------
  180. * Modify Date Modifier Modify Description
  181. *---------------------------------------------------------------------------------------
  182. * 2015-11-13 Live Converter TF->XP
  183. *
  184. *---------------------------------------------------------------------------------------
  185. ****************************************************************************************/
  186. include "com_commonxp::comm_main.xjs";
  187. include "mis_miscommonxp::RSZ001.xjs";
  188. include "mis_miscommonxp::MIS.xjs";
  189. function SPMNG00401_oninit(obj:Form, e:InitEventInfo)
  190. {
  191. frmf_initForm(obj);
  192. }
  193. function SPMNG00401_onload(obj:Form, e:LoadEventInfo)
  194. {
  195. grdf_setRowTypeIcon(group3.grd_deptlist,0);
  196. var oParam = {};
  197. oParam.id = "TRMNG00402";
  198. oParam.service = "csrapp.CsrMngt";
  199. oParam.method = "getCsrDeptList";
  200. oParam.inds = "req=ds_send_reqdata";
  201. oParam.outds = "ds_main_csrdeptlist=csrdeptlist";
  202. oParam.async = false;
  203. tranf_submit(oParam);
  204. dsf_makeValue(ds_send,"useyn", "string", "Y");
  205. var oParam = {};
  206. oParam.id = "TRMNG00401";
  207. oParam.service = "csrapp.CsrMngt";
  208. oParam.method = "reqGetDeptFlagList";
  209. oParam.inds = "req=ds_send";
  210. oParam.outds = "ds_main_csrreqdeptlist=csrreqdeptlist";
  211. oParam.async = false;
  212. tranf_submit(oParam);
  213. }
  214. function group3_group2_btn_search_onclick(obj:Button, e:ClickEventInfo)
  215. {
  216. var chk = group3.group2.cmb_dept.value;
  217. if ( utlf_isNull(chk) ) {
  218. alert("상위부서를 선택하세요");
  219. return;
  220. }
  221. ds_send_reqdata.setColumn(0, "deptcd", ds_main_cond.getColumn(0, "deptcd"));
  222. var oParam = {};
  223. oParam.id = "TRMNG00404";
  224. oParam.service = "csrapp.CsrDryMngt";
  225. oParam.method = "reqGetClnDeptList";
  226. oParam.inds = "req=ds_send_reqdata";
  227. oParam.outds = "ds_main_deptcodelist=deptcodelist";
  228. oParam.async = false;
  229. tranf_submit(oParam);
  230. }
  231. function group3_group2_cmb_dept_onitemchanged(obj:Combo, e:ItemChangeEventInfo)
  232. {
  233. frmf_inputEnterKey("group3.group2.btn_search", "onclick", new ClickEventInfo);
  234. }
  235. function group3_grd_deptlist_onexpanddown(obj:Grid, e:GridMouseEventInfo)
  236. {
  237. var chk = group3.group2.cmb_dept.value;
  238. if ( utlf_isNull(chk) ) {
  239. alert("상위부서를 선택하세요");
  240. return;
  241. }
  242. sysf_setModelProperty("flag","req");
  243. if (e.col == group3.grd_deptlist.getBindCellIndex("body","deptcd")) {//부서코드 버튼을 눌렀을 때
  244. ds_copynode.clearData();
  245. rszfOpenPopUpListByWndName(group3.grd_deptlist,"","deptcd,deptnm","SPMNG00400","","", "Y");
  246. var CSV = frmf_getParameter("SPMNG00400_");
  247. dsf_setCSVToDs("ds_copynode", CSV);
  248. fSettingGoodList("ds_copynode");
  249. }
  250. }
  251. function group3_btn_save_onclick(obj:Button, e:ClickEventInfo)
  252. {
  253. for (i=0; i< ds_main_deptcodelist.rowcount; i++ ) {
  254. var csrreqdeptcd = group3.grd_deptlist.getCellValue(i, group3.grd_deptlist.getBindCellIndex("body","csrreqdeptcd"));
  255. if ( utlf_isNull(csrreqdeptcd) ) {
  256. if ( ds_main_deptcodelist.getRowType(i) != "2" ) {
  257. alert("부서구분을 입력하세요");
  258. return;
  259. }
  260. }
  261. }
  262. var update = grdf_getGridUpdateData(group3.grd_deptlist);
  263. grdf_setStatusColumn(update, "status");
  264. if (update.rowcount < 1)
  265. {
  266. sysf_messageBox("변경된 데이터가","I004");
  267. return;
  268. }
  269. dsf_createDs("ds_send_reqdata1_reqdeptinfo");
  270. ds_send_reqdata1_reqdeptinfo.copyData(update, true);
  271. dsf_createDs("ds_send_reqdata2_csrreqdept");
  272. ds_send_reqdata2_csrreqdept.copyData(update, true);
  273. var oParam = {};
  274. oParam.id = "TXMNG00403";
  275. oParam.service = "csrapp.CsrDryMngt";
  276. oParam.method = "reqExeSaveClnDept";
  277. oParam.inds = "req=ds_send_reqdata1_reqdeptinfo";
  278. oParam.outds = "";
  279. oParam.async = false;
  280. tranf_submit(oParam);
  281. var oParam = {};
  282. oParam.id = "TXMNG00402";
  283. oParam.service = "csrapp.CsrMngt";
  284. oParam.method = "reqExeSaveCsrDept";
  285. oParam.inds = "req=ds_send_reqdata2_csrreqdept";
  286. oParam.outds = "";
  287. oParam.async = false;
  288. tranf_submit(oParam);
  289. frmf_inputEnterKey("group3.group2.btn_search", "onclick", new ClickEventInfo);
  290. }
  291. function group3_button1_onclick(obj:Button, e:ClickEventInfo)
  292. {
  293. ds_main_deptcodelist.addRow();
  294. ds_main_deptcodelist.setColumn(ds_main_deptcodelist.rowposition , "useyn", "Y");
  295. }
  296. function group3_btn_del_onclick(obj:Button, e:ClickEventInfo)
  297. {
  298. if(ds_main_deptcodelist.rowcount == 0) {
  299. sysf_messageBox("삭제할 행이 존재하지 않습니다.");
  300. return;
  301. }
  302. if(ds_main_deptcodelist.rowposition < 0) {
  303. sysf_messageBox("삭제할 행을 선택하십시오.", "E");
  304. return;
  305. }
  306. ds_main_deptcodelist.updatecontrol =false;
  307. ds_main_deptcodelist.setRowType(i, "D");
  308. ds_main_deptcodelist.updatecontrol =true;
  309. }
  310. function group1_btn_confirm_onclick(obj:Button, e:ClickEventInfo)
  311. {
  312. if(ds_main_deptcodelist.rowcount == 0)
  313. {
  314. sysf_messageBox("적용할 내역이","I004");
  315. this.close();
  316. return;
  317. }
  318. //var iParam = model.getValue(grd_deptlist.nodeset);
  319. ds_main_deptcodelist.filter("chkyn=='Y'");
  320. var rCVS = dsf_getDsCSV(ds_main_deptcodelist);
  321. ds_main_deptcodelist.filter("");
  322. if ( frmf_checkOpener() ) {
  323. opener.frmf_setParameter("SPMNG00400_", rCVS);
  324. } else {
  325. var rtn = sysf_messageBox("상위화면을 찾을 수", "E001");
  326. }
  327. this.close();
  328. }
  329. function group1_btn_cancel_onclick(obj:Button, e:ClickEventInfo)
  330. {
  331. misfPopUpListCancel();
  332. }
  333. function fSettingGoodList(pnode)
  334. {
  335. var codynode = ds_copynode.rowcount;
  336. var addRow = ds_main_deptcodelist.rowcount - 1;
  337. for (var j = 0; j < codynode; j++)
  338. {
  339. if(addRow > ds_main_deptcodelist.rowcount - 1)
  340. {
  341. misfGridIUD(group3.grd_deptlist,"A");
  342. addRow = ds_main_deptcodelist.rowcount - 1;
  343. }
  344. ds_main_deptcodelist.updatecontrol = false;
  345. ds_main_deptcodelist.enableevent = false;
  346. ds_main_csrdeptlist.setColumn(addRow, "deptcd" , ds_copynode.getColumn(j, "deptcd"));
  347. ds_main_csrdeptlist.setColumn(addRow, "deptnm" , ds_copynode.getColumn(j, "depthngnm"));
  348. ds_main_csrdeptlist.setColumn(addRow, "supdeptcd" , group3.group2.cmb_dept.value);
  349. ds_main_csrdeptlist.setColumn(addRow, "supdeptnm" , group3.group2.cmb_dept.text);
  350. ds_main_csrdeptlist.setColumn(addRow, "userid" , sysf_getUserInfo("userid"));
  351. ds_main_csrdeptlist.setColumn(addRow, "useyn" , "Y");
  352. //grp_biz.grd_reqcollcdeptlist.showEditor(false);
  353. ds_main_deptcodelist.enableevent = true;
  354. ds_main_deptcodelist.updatecontrol = true;
  355. addRow = addRow + 1;
  356. }
  357. }]]></Script>
  358. </Form>
  359. </FDL>