SMMRE00300_참조값등록.xfdl 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <FDL version="1.5">
  3. <TypeDefinition url="..\..\..\default_typedef.xml"/>
  4. <Form id="SMMRE00300" position="absolute 0 0 580 800" titletext="참조값 등록" onload="SMMRE00300_onload">
  5. <Layouts>
  6. <Layout>
  7. <Shape position="absolute 0 84 580 90" linetype="horizontal" id="line1" class="line_1"/>
  8. <Static text="참조값" position="absolute 0 68 66 84" align="align:center middle;" id="caption2" class="tit_2"/>
  9. <Grid position="absolute 0 88 580 800" id="grd_reflist" binddataset="ds_grd_reflist" onenteredit="ds_edit_onclick" autoenter="select">
  10. <Formats>
  11. <Format id="default">
  12. <Columns>
  13. <Column size="20"/>
  14. <Column size="60"/>
  15. <Column size="60"/>
  16. <Column size="323"/>
  17. <Column size="60"/>
  18. <Column size="40"/>
  19. <Column size="0"/>
  20. <Column size="0"/>
  21. </Columns>
  22. <Rows>
  23. <Row size="24" band="head"/>
  24. <Row size="24"/>
  25. </Rows>
  26. <Band id="head">
  27. <Cell/>
  28. <Cell col="1" text="참조"/>
  29. <Cell col="2" text="구분코드"/>
  30. <Cell col="3" text="구분명"/>
  31. <Cell col="4" text="순번"/>
  32. <Cell col="5" text="사용"/>
  33. <Cell col="6"/>
  34. <Cell col="7"/>
  35. </Band>
  36. <Band id="body">
  37. <Cell celltype="head" text="expr:currow + 1"/>
  38. <Cell col="1" displaytype="text" edittype="text" text="bind:gubun"/>
  39. <Cell col="2" displaytype="text" edittype="text" text="bind:code"/>
  40. <Cell col="3" displaytype="text" edittype="text" text="bind:codename" wordwrap="char"/>
  41. <Cell col="4" displaytype="text" edittype="text" text="bind:seq"/>
  42. <Cell col="5" displaytype="checkbox" edittype="checkbox" text="bind:useyn"/>
  43. <Cell col="6" text="bind:instcd"/>
  44. <Cell col="7" text="bind:status"/>
  45. </Band>
  46. </Format>
  47. </Formats>
  48. </Grid>
  49. <Static text="참조값 등록" position="absolute 0 0 173 25" id="caption6" class="tit_1"/>
  50. <Button position="absolute 537 67 579 86" id="btn_save" class="btn5" taborder="11" text="저장" onclick="btn_save_onclick"/>
  51. <Button position="absolute 449 67 491 86" id="btn_insert" class="btn2_letter2" taborder="9" text="추가" onclick="btn_insert_onclick"/>
  52. <Button position="absolute 493 67 535 86" id="btn_del" class="btn2_letter2" taborder="10" text="삭제" onclick="btn_del_onclick"/>
  53. <Div id="Div00" taborder="12" position="absolute 0 24 580 63" class="div_SA">
  54. <Layouts>
  55. <Layout>
  56. <Button id="btn_req" taborder="0" text="조회" onclick="btn_req_onclick" class="btn1" position="absolute 512 9 568 31"/>
  57. <CheckBox id="onlyuseyn" taborder="1" value="N" truevalue="Y" falsevalue="N" onclick="onlyuseyn_onclick" position="absolute 125 9 142 31"/>
  58. <Static id="caption14" text="사용하는 것만" class="search_name" position="absolute 19 14 114 29"/>
  59. </Layout>
  60. </Layouts>
  61. </Div>
  62. </Layout>
  63. </Layouts>
  64. <Objects>
  65. <Dataset id="ds_grd_reflist" firefirstcount="0" firenextcount="0" useclientlayout="true" updatecontrol="true" enableevent="true" loadkeymode="keep" reversesubsum="false">
  66. <ColumnInfo>
  67. <Column id="gubun" type="STRING"/>
  68. <Column id="code" type="STRING"/>
  69. <Column id="codename" type="STRING"/>
  70. <Column id="seq" type="STRING"/>
  71. <Column id="useyn" type="STRING"/>
  72. <Column id="instcd" type="STRING" size="256"/>
  73. <Column id="status" type="STRING" size="256"/>
  74. </ColumnInfo>
  75. </Dataset>
  76. <Dataset id="ds_modlist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  77. <ColumnInfo>
  78. <Column id="gubun" type="STRING" size="256"/>
  79. <Column id="code" type="STRING" size="256"/>
  80. <Column id="codename" type="STRING" size="256"/>
  81. <Column id="seq" type="STRING" size="256"/>
  82. <Column id="useyn" type="STRING" size="256"/>
  83. <Column id="instcd" type="STRING" size="256"/>
  84. <Column id="status" type="STRING" size="256"/>
  85. </ColumnInfo>
  86. <Rows>
  87. <Row/>
  88. </Rows>
  89. </Dataset>
  90. <Dataset id="ds_dellist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  91. <ColumnInfo>
  92. <Column id="gubun" type="STRING" size="256"/>
  93. <Column id="code" type="STRING" size="256"/>
  94. <Column id="codename" type="STRING" size="256"/>
  95. <Column id="seq" type="STRING" size="256"/>
  96. <Column id="useyn" type="STRING" size="256"/>
  97. <Column id="instcd" type="STRING" size="256"/>
  98. <Column id="status" type="STRING" size="256"/>
  99. </ColumnInfo>
  100. </Dataset>
  101. <Dataset id="ds_reqcond" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  102. <ColumnInfo>
  103. <Column id="onlyuseyn" type="STRING" size="256"/>
  104. </ColumnInfo>
  105. <Rows>
  106. <Row>
  107. <Col id="onlyuseyn">N</Col>
  108. </Row>
  109. </Rows>
  110. </Dataset>
  111. </Objects>
  112. <Bind>
  113. <BindItem id="item0" compid="Div00.onlyuseyn" propid="value" datasetid="ds_reqcond" columnid="onlyuseyn"/>
  114. </Bind>
  115. <Script type="xscript4.0"><![CDATA[/***************************************************************************************
  116. * System Name :
  117. * Job Name : SMMRE00300_참조값등록_knuh.xfdl
  118. * Creator :
  119. * Make Date : 2014-10-14
  120. * Description : 참조값등록
  121. *---------------------------------------------------------------------------------------
  122. * Modify Date Modifier Modify Description
  123. *---------------------------------------------------------------------------------------
  124. * 2014-09-17 Live Converter TF->XP
  125. *
  126. *---------------------------------------------------------------------------------------
  127. ****************************************************************************************/
  128. //=======================================================================================
  129. // Lib Include
  130. //---------------------------------------------------------------------------------------
  131. include "com_commonxp::comm_main.xjs"
  132. //=======================================================================================
  133. // Global Form Variable
  134. //---------------------------------------------------------------------------------------
  135. //=======================================================================================
  136. // Function
  137. //---------------------------------------------------------------------------------------
  138. //=======================================================================================
  139. // Transaction Callback
  140. //---------------------------------------------------------------------------------------
  141. /****************************************************************************************
  142. * Argument : 01.sKey : 코드아이디
  143. * : 02.sValue : 코드명
  144. * Description : 술식어 참조리스트를 조회한다.
  145. ****************************************************************************************/
  146. function btn_req_onclick(obj:Button, e:ClickEventInfo) //조회
  147. {
  148. var oParam = {};
  149. oParam.id = "TRMRE00301";
  150. oParam.service = "dentirecapp.DentiWord";
  151. oParam.method = "reqGetRefList";
  152. oParam.inds = "reqcond=" + "ds_reqcond";
  153. oParam.outds = "ds_grd_reflist=reflist";
  154. oParam.async = true;
  155. tranf_submit(oParam);
  156. }
  157. /****************************************************************************************
  158. * Argument : 01.sKey : 코드아이디
  159. * : 02.sValue : 코드명
  160. * Description : 술식어 참조리스트를 저장한다.
  161. ****************************************************************************************/
  162. function btn_save_onclick(obj:Button, e:ClickEventInfo)//저장
  163. {
  164. ds_modlist.copyData(ds_grd_reflist);
  165. var oParam = {};
  166. oParam.id = "TXMRE00301";
  167. oParam.service = "dentirecapp.DentiWord";
  168. oParam.method = "reqExeSaveGetRefList";
  169. oParam.inds = "modlist=ds_modlist"+" dellist=ds_dellist"+" reqcond=ds_reqcond";
  170. oParam.outds = "ds_grd_reflist=reflist";
  171. oParam.async = false;
  172. oParam.callback = "cf_TXMRE00301";
  173. tranf_submit(oParam);
  174. }
  175. /****************************************************************************************
  176. * Argument : 01.sKey : 코드아이디
  177. * : 02.sValue : 코드명
  178. * Description : 저장실패시 에러메세지 띄워준다.
  179. ****************************************************************************************/
  180. function cf_TXMRE00301(sSvcId, nErrorCode, sErrorMsg) {
  181. if(nErrorCode < 0) {
  182. sysf_messageBox("저장을 실패하였습니다.", "E999");
  183. return;
  184. }
  185. Div00.btn_req.onclick.fireEvent(Div00.btn_req, new ClickEventInfo);
  186. }
  187. /****************************************************************************************
  188. * Argument : 01.sKey : 코드아이디
  189. * : 02.sValue : 코드명
  190. * Description : 술식어 참조리스트에 수정시 기능
  191. ****************************************************************************************/
  192. function ds_edit_onclick(obj:Button, e:ClickEventInfo){
  193. var currow = ds_grd_reflist.rowposition;
  194. ds_grd_reflist.setColumn(currow,"status", "u");
  195. }
  196. //=======================================================================================
  197. // Event
  198. //---------------------------------------------------------------------------------------
  199. /****************************************************************************************
  200. * Components : Form
  201. * Components ID : SMMRE00300
  202. * Event : onload
  203. * Argument : 01.obj : Object Event has occurred
  204. * : 02.e : Event Object
  205. * Description : 최초 OnLoad Event
  206. ****************************************************************************************/
  207. function SMMRE00300_onload(obj:Form, e:LoadEventInfo)
  208. {
  209. frmf_initForm(obj);
  210. var e = new ClickEventInfo;
  211. frmf_inputEnterKey("Div00.btn_req", "onclick", e);
  212. }
  213. /****************************************************************************************
  214. * Components : Button
  215. * Components ID : SMMRE00300
  216. * Event : onload
  217. * Argument : 01.obj : Object Event has occurred
  218. * : 02.e : Event Object
  219. * Description : 참조값 리스트에 한 줄 추가 EVENT
  220. ****************************************************************************************/
  221. function btn_insert_onclick(obj:Button, e:ClickEventInfo)
  222. {
  223. ds_grd_reflist.addRow();
  224. var currow = ds_grd_reflist.rowposition;
  225. ds_grd_reflist.setColumn(currow,"status", "i");
  226. ds_grd_reflist.setColumn(currow,"useyn", "Y");
  227. }
  228. /****************************************************************************************
  229. * Components : Button
  230. * Components ID : SMMRE00300
  231. * Event : onload
  232. * Argument : 01.obj : Object Event has occurred
  233. * : 02.e : Event Object
  234. * Description : 참조값 리스트에 한 줄 삭제 EVENT
  235. ****************************************************************************************/
  236. function btn_del_onclick(obj:Button, e:ClickEventInfo)
  237. {
  238. ds_modlist.clearData();
  239. ds_dellist.clearData();
  240. var nRow = ds_dellist.addRow();
  241. var currow = ds_grd_reflist.rowposition;
  242. ds_dellist.copyRow(nRow, ds_grd_reflist, currow);
  243. //sysf_trace(ds_dellist.saveXML());
  244. var oParam = {};
  245. oParam.id = "TXMRE00301";
  246. oParam.service = "dentirecapp.DentiWord";
  247. oParam.method = "reqExeSaveGetRefList";
  248. oParam.inds = "modlist=ds_modlist"+" dellist=ds_dellist"+" reqcond=ds_reqcond";
  249. oParam.outds = "ds_grd_reflist=reflist";
  250. oParam.async = false;
  251. oParam.callback = "cf_TXMRE00301";
  252. tranf_submit(oParam);
  253. }]]></Script>
  254. </Form>
  255. </FDL>