SPAHR00700_코드조회(건진구분).xfdl 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <FDL version="1.5">
  3. <TypeDefinition url="..\..\..\default_typedef.xml"/>
  4. <Form id="SPAHR00700" position="absolute 0 0 520 578" titletext="코드조회" onload="SPAHR00700_onload">
  5. <Layouts>
  6. <Layout>
  7. <Div position="absolute 0 0 518 550" id="group3" scrollbars="autoboth">
  8. <Layouts>
  9. <Layout>
  10. <Div position="absolute 0 0 518 40" align="align:center top;" id="group2" class="div_SA2">
  11. <Layouts>
  12. <Layout>
  13. <Static text="검색명 :" position="absolute 15 12 77 29" id="caption2" class="search_name" anchor="default"/>
  14. <Shape position="absolute 426 9 432 31" linetype="vertical" id="line13" anchor="default"/>
  15. <Edit position="absolute 85 11 401 30" id="ipt_excucd" class="input_search" anchor="default" onkeyup="group3_group2_ipt_excucd_onkeyup"/>
  16. <Button position="absolute 445 9 501 31" id="btn_sea" class="btn1" text="조회" anchor="default" onclick="group3_group2_btn_sea_onclick"/>
  17. </Layout>
  18. </Layouts>
  19. </Div>
  20. <Static text="코드조회" position="absolute 0 48 103 65" id="caption1" class="tit_2"/>
  21. <Shape position="absolute 0 64 518 70" id="line1" class="line_10"/>
  22. <Grid position="absolute 0 69 518 550" id="grd_excucd" binddataset="ds_main_excucdlist_item" cellclickbound="cell">
  23. <Formats>
  24. <Format id="default">
  25. <Columns>
  26. <Column size="58"/>
  27. <Column size="124"/>
  28. <Column size="316"/>
  29. </Columns>
  30. <Rows>
  31. <Row size="24" band="head"/>
  32. <Row size="24"/>
  33. </Rows>
  34. <Band id="head">
  35. <Cell text="선택"/>
  36. <Cell col="1" text="코드"/>
  37. <Cell col="2" text="코드명칭"/>
  38. </Band>
  39. <Band id="body">
  40. <Cell displaytype="checkbox" edittype="checkbox" text="bind:check" expr="expr:(check==&quot;Y&quot;||check==1)?1:0"/>
  41. <Cell col="1" style="align:left middle;padding:0 0 0 3;" text="bind:excucd"/>
  42. <Cell col="2" style="align:left middle;padding:0 0 0 3;" text="bind:excucdnm"/>
  43. </Band>
  44. </Format>
  45. </Formats>
  46. </Grid>
  47. </Layout>
  48. </Layouts>
  49. </Div>
  50. <Div position="absolute 0 549 518 576" id="group1" scrollbars="autoboth">
  51. <Layouts>
  52. <Layout>
  53. <Button position="absolute 401 5 457 27" id="btn_cfm" class="btn4" text="확인" anchor="default" onclick="group1_btn_cfm_onclick"/>
  54. <Button position="absolute 460 5 516 27" id="btn_cls" class="btn4" text="닫기" anchor="default" onclick="group1_btn_cls_onclick"/>
  55. <Button position="absolute 342 5 398 27" id="button1" class="btn4" visible="false" text="취소" anchor="default" onclick="group1_button1_onclick"/>
  56. </Layout>
  57. </Layouts>
  58. </Div>
  59. </Layout>
  60. </Layouts>
  61. <Objects>
  62. <Dataset id="ds_main_excucdlist_item" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="keep" oncolumnchanged="ds_main_excucdlist_item_oncolumnchanged">
  63. <ColumnInfo>
  64. <Column id="check" type="STRING" size="256"/>
  65. <Column id="excucd" type="STRING" size="256"/>
  66. <Column id="excucdnm" type="STRING" size="256"/>
  67. </ColumnInfo>
  68. <Rows>
  69. <Row>
  70. <Col id="check"/>
  71. <Col id="excucd"/>
  72. <Col id="excucdnm"/>
  73. </Row>
  74. </Rows>
  75. </Dataset>
  76. <Dataset id="ds_send" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="keep">
  77. <ColumnInfo>
  78. <Column id="srchexcucd" type="STRING" size="256"/>
  79. <Column id="tmplcdflag" type="STRING" size="256"/>
  80. </ColumnInfo>
  81. <Rows>
  82. <Row>
  83. <Col id="srchexcucd"/>
  84. </Row>
  85. </Rows>
  86. </Dataset>
  87. <Dataset id="ds_send_globalinstance" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="keep">
  88. <ColumnInfo>
  89. <Column id="instance1" type="STRING" size="256"/>
  90. </ColumnInfo>
  91. <Rows>
  92. <Row>
  93. <Col id="instance1"/>
  94. </Row>
  95. </Rows>
  96. </Dataset>
  97. <Dataset id="ds_hidden" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="keep">
  98. <ColumnInfo>
  99. <Column id="hidden" type="STRING" size="256"/>
  100. </ColumnInfo>
  101. <Rows>
  102. <Row>
  103. <Col id="hidden"/>
  104. </Row>
  105. </Rows>
  106. </Dataset>
  107. <Dataset id="ds_init" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="keep">
  108. <ColumnInfo>
  109. <Column id="degnitemlevlcd" type="STRING" size="256"/>
  110. </ColumnInfo>
  111. </Dataset>
  112. </Objects>
  113. <Bind>
  114. <BindItem id="item0" compid="group3.group2.ipt_excucd" propid="value" datasetid="ds_send" columnid="srchexcucd"/>
  115. </Bind>
  116. <Script type="xscript4.0"><![CDATA[/***************************************************************************************
  117. * System Name :
  118. * Job Name :
  119. * Creator :
  120. * Make Date : 2017-12-04
  121. * Description :
  122. *---------------------------------------------------------------------------------------
  123. * Modify Date Modifier Modify Description
  124. *---------------------------------------------------------------------------------------
  125. * 2017-06-19 Live Converter TF->XP
  126. *
  127. *---------------------------------------------------------------------------------------
  128. ****************************************************************************************/
  129. //=======================================================================================
  130. // Lib Include
  131. //---------------------------------------------------------------------------------------
  132. include "com_commonxp::comm_main.xjs";
  133. include "ast_examcurexp::AEZ0001.xjs";
  134. //=======================================================================================
  135. // Global Form Variable
  136. //---------------------------------------------------------------------------------------
  137. var arErrorCode = new HashArray();
  138. //=======================================================================================
  139. // Function
  140. //---------------------------------------------------------------------------------------
  141. /*-**************************************************************************************
  142. * Argument : N/A
  143. * Description : 조회
  144. ****************************************************************************************/
  145. function call_TRAHR00701() {
  146. var oParam = {};
  147. oParam.id = "TRAHR00701";
  148. oParam.service = "healexamrsltjudgapp.TestProgrs";
  149. oParam.method = "reqGetHealGubnList";
  150. oParam.inds = "req=ds_send";
  151. oParam.outds = "ds_main_excucdlist_item=item";
  152. oParam.async = false;
  153. oParam.callback = "cf_TRAHR00701";
  154. tranf_submit(oParam);
  155. }
  156. function cf_TRAHR00701(sSvcId, nErrorCode, sErrorMsg) {
  157. arErrorCode.push(sSvcId, nErrorCode);
  158. ds_main_excucdlist_item.updatecontrol = false;
  159. dsf_setFixVal(ds_main_excucdlist_item, "check:N");
  160. ds_main_excucdlist_item.updatecontrol = true;
  161. }
  162. //=======================================================================================
  163. // Event
  164. //---------------------------------------------------------------------------------------
  165. /****************************************************************************************
  166. * Components : Form
  167. * Description : 화면 처음 초기화시 폼초기화
  168. ****************************************************************************************/
  169. function SPAHR00700_onload(obj:Form, e:LoadEventInfo) {
  170. frmf_initForm(obj);
  171. //grdf_initGrid(grd_XXX);
  172. grdf_setGridSort(group3.grd_excucd);
  173. //grdf_setRowTypeIcon(grd_XXX, 0_컬럼위치값);
  174. lf_aezfSetSuppDeptcd(); //AEZ0001.xjs
  175. ds_send_globalinstance.setColumn(0, "instance1", frmf_getParameter("AST_DEPTCD"));
  176. try{
  177. ds_init.copyData(arg_ds_init);
  178. }catch(e){}
  179. call_TRAHR00701();
  180. if(arErrorCode.pop("TRAHR00701") > -1) {
  181. var vFlag = utlf_transNullToEmpty(ds_init.getColumn(0, "degnitemlevlcd")).split("^");
  182. if(vFlag.length > 0) {
  183. for(var i=0; i < ds_main_excucdlist_item.rowcount; i++) {
  184. var vExcucd = ds_main_excucdlist_item.getColumn( i , "excucd");
  185. for(var j=0; j < vFlag.length; j++) {
  186. if(vExcucd == vFlag[j]) {
  187. ds_main_excucdlist_item.setColumn( i , "check", "Y");
  188. }
  189. }
  190. }
  191. }
  192. }
  193. }
  194. /****************************************************************************************
  195. * Components : Edit
  196. * Description : 검색명 입력 후 조회
  197. ****************************************************************************************/
  198. function group3_group2_ipt_excucd_onkeyup(obj:Edit, e:KeyEventInfo) {
  199. if(e.keycode == 13) {
  200. obj.updateToDataset();
  201. group3.group2.btn_sea.click();
  202. }
  203. }
  204. /****************************************************************************************
  205. * Components : Button
  206. * Description : 조회
  207. ****************************************************************************************/
  208. function group3_group2_btn_sea_onclick(obj:Button, e:ClickEventInfo) {
  209. call_TRAHR00701();
  210. ds_send.setColumn( 0, "srchexcucd", "");
  211. group3.group2.ipt_excucd.setFocus();
  212. }
  213. /****************************************************************************************
  214. * Components : Button
  215. * Description : 확인
  216. ****************************************************************************************/
  217. function group1_btn_cfm_onclick(obj:Button, e:ClickEventInfo) {
  218. if ( ds_main_excucdlist_item.rowposition < 0 ) return;
  219. var openerid = opener.frmf_getScreenID();
  220. var check = "";
  221. var loopcnt = 0;
  222. var loop = ds_main_excucdlist_item.rowcount;
  223. var str_temp = "";
  224. var str_temp2 = "";
  225. var str_check = "";
  226. for( var i = 0 ; i < loop ; i++ ) {
  227. check = ds_main_excucdlist_item.getColumn(i, "check");
  228. if ( check == "Y" ) {
  229. str_temp += ds_main_excucdlist_item.getColumn(i, "excucd");
  230. str_temp2 += ds_main_excucdlist_item.getColumn(i, "excucdnm");
  231. str_temp = str_temp + "^"
  232. str_temp2 = str_temp2 + "^"
  233. }
  234. loopcnt++;
  235. }
  236. if ( loopcnt == 0 ) {
  237. sysf_messageBox("코드를 선택해 주십시오.","I999");
  238. return "0";
  239. }
  240. switch (openerid) {
  241. case "SMAHB00100" : // 검사코드관리
  242. var checkrow = opener.ds_main_testcdlst_item1.rowposition;
  243. opener.ds_main_testcdlst_item1.setColumn( checkrow , "degnitemlevlcd", str_temp);
  244. break;
  245. case "SMAHA03010" : // 검사코드관리
  246. var checkrow = opener.ds_main_testcdlst_item1.rowposition;
  247. opener.ds_main_testcdlst_item1.setColumn( checkrow , "degnitemlevlcd", str_temp);
  248. break;
  249. }
  250. this.close();
  251. }
  252. /****************************************************************************************
  253. * Components : Button
  254. * Description : 취소
  255. ****************************************************************************************/
  256. function group1_button1_onclick(obj:Button, e:ClickEventInfo) {
  257. this.close();
  258. }
  259. /****************************************************************************************
  260. * Components : Dataset
  261. * Description : 체크박스 설정
  262. ****************************************************************************************/
  263. function ds_main_excucdlist_item_oncolumnchanged(obj:Dataset, e:DSColChangeEventInfo)
  264. {
  265. if(e.columnid=="check") {
  266. obj.setColumn(e.row,e.columnid,(e.newvalue=="Y"||e.newvalue==1)?"Y":"N");
  267. }
  268. }
  269. /****************************************************************************************
  270. * Components : Button
  271. * Description : 닫기
  272. ****************************************************************************************/
  273. function group1_btn_cls_onclick(obj:Button, e:ClickEventInfo)
  274. {
  275. this.close();
  276. }
  277. ]]></Script>
  278. </Form>
  279. </FDL>