SMRPD31500_전문의평가대상자별평가자지정.xfdl 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <FDL version="1.5">
  3. <TypeDefinition url="..\..\..\default_typedef.xml"/>
  4. <Form id="SMRPD31500" position="absolute 0 0 1200 780" titletext="전문의 평가 - 연도별 평가자 지정" oninit="SMRPD31500_oninit" onload="SMRPD31500_onload">
  5. <Layouts>
  6. <Layout>
  7. <Div id="grp_sea" taborder="1" class="div_SA" position="absolute 0 50 1194 85">
  8. <Layouts>
  9. <Layout/>
  10. </Layouts>
  11. </Div>
  12. <Static text="전문의 평가 - 연도별 평가자 지정" position="absolute 0 0 235 24" id="caption1" class="tit_1"/>
  13. <Div position="absolute 0 13 1195 45" id="grp_button" scrollbars="autoboth">
  14. <Layouts>
  15. <Layout>
  16. <Shape position="absolute 0 25 1195 31" linetype="horizontal" id="line2" class="line_6" anchor="default"/>
  17. <Button position="absolute 1139 4 1195 26" id="btn_save" class="btn4" text="저장" anchor="default" onclick="grp_button_btn_save_onclick"/>
  18. </Layout>
  19. </Layouts>
  20. </Div>
  21. <Div position="absolute 0 40 1195 765" id="grp_main">
  22. <Layouts>
  23. <Layout>
  24. <Grid position="absolute 0 83 1195 700" id="datagrid1" binddataset="ds_main_codeinfo_codelist" autoenter="select" onexpandup="grp_main_datagrid1_onexpandup" selecttype="row">
  25. <Formats>
  26. <Format id="default">
  27. <Columns>
  28. <Column size="20" band="left"/>
  29. <Column size="66"/>
  30. <Column size="68"/>
  31. <Column size="150"/>
  32. <Column size="130"/>
  33. <Column size="66"/>
  34. <Column size="68"/>
  35. <Column size="150"/>
  36. <Column size="130"/>
  37. <Column size="0"/>
  38. <Column size="0"/>
  39. </Columns>
  40. <Rows>
  41. <Row size="24" band="head"/>
  42. <Row size="24" band="head"/>
  43. <Row size="24"/>
  44. </Rows>
  45. <Band id="head">
  46. <Cell rowspan="2" taborder="undefined"/>
  47. <Cell col="1" colspan="4" text="대상자" taborder="undefined"/>
  48. <Cell col="5" colspan="4" text="평가자" taborder="undefined"/>
  49. <Cell col="9" text="instcd"/>
  50. <Cell col="10" text="year"/>
  51. <Cell row="1" col="1" text="사번" taborder="undefined"/>
  52. <Cell row="1" col="2" text="성명"/>
  53. <Cell row="1" col="3" text="부서명"/>
  54. <Cell row="1" col="4" text="직종"/>
  55. <Cell row="1" col="5" text="사번"/>
  56. <Cell row="1" col="6" text="성명"/>
  57. <Cell row="1" col="7" text="부서명"/>
  58. <Cell row="1" col="8" text="직종"/>
  59. <Cell row="1" col="9" text="instcd"/>
  60. <Cell row="1" col="10" text="year"/>
  61. </Band>
  62. <Band id="body">
  63. <Cell celltype="head"/>
  64. <Cell col="1" displaytype="text" edittype="expr:getRowType(currow) == 2 ? 'text' : 'none'" style="align:center;" text="bind:emplno" expandshow="show" enable="false"/>
  65. <Cell col="2" style="align:left;" text="bind:emplnm"/>
  66. <Cell col="3" style="align:left;" text="bind:deptnm"/>
  67. <Cell col="4" style="align:left;" text="bind:jobkindnm"/>
  68. <Cell col="5" displaytype="text" edittype="text" style="align:center;" text="bind:evalemplno" editautoselect="true" expandshow="show"/>
  69. <Cell col="6" style="align:left;" text="bind:evalemplnm"/>
  70. <Cell col="7" style="align:left;" text="bind:evaldeptnm"/>
  71. <Cell col="8" style="align:left;" text="bind:evaljobkindnm"/>
  72. <Cell col="9" text="bind:instcd"/>
  73. <Cell col="10" text="bind:year"/>
  74. </Band>
  75. </Format>
  76. </Formats>
  77. </Grid>
  78. <Button position="absolute 1030 57 1083 76" id="btn_grddel" class="btn2" text="행삭제" onclick="grp_main_btn_grddel_onclick"/>
  79. <Static text="※ 대상자 자동 생성시 해당 연도의 기등록 자료는 모두 삭제됨에 유의하십시요." position="absolute 0 702 503 722" id="caption3" style="color:#ff0000ff;"/>
  80. <Static text="평가자 지정" position="absolute 2 62 120 76" id="caption4" class="tit_2"/>
  81. <Button position="absolute 974 57 1027 76" id="btn_grdadd" class="btn2" text="행추가" onclick="grp_main_btn_grdadd_onclick"/>
  82. <Shape position="absolute 0 78 1195 84" linetype="horizontal" id="line7" class="line_10"/>
  83. <Combo position="absolute 120 19 262 38" id="cmb_instcd" class="combo_s_default" enable="false" onitemchanged="grp_main_cmb_instcd_onitemchanged"/>
  84. <Static text="기관코드" position="absolute 49 20 118 37" id="caption2" class="search_name"/>
  85. <Static text="연도" position="absolute 290 20 333 37" id="caption5" class="search_name"/>
  86. <Shape position="absolute 412 17 418 39" linetype="vertical" id="line3"/>
  87. <MaskEdit position="absolute 335 19 385 38" align="align:center middle;" id="ipt_year" taborder="3" mask="####" autoselect="true" type="string" maskchar=" " autoskip="true" trimtype="both"/>
  88. <Button position="absolute 430 17 486 39" id="btn_search" class="btn1" text="조회" onclick="grp_main_btn_search_onclick"/>
  89. <Button position="absolute 1086 57 1194 76" id="btn_download" class="btn2" taborder="6" text="엑셀 Download" onclick="grp_main_btn_download_onclick"/>
  90. <Button position="absolute 890 57 971 76" id="btn_psn" class="btn2" text="대상자생성" onclick="grp_main_btn_psn_onclick"/>
  91. </Layout>
  92. </Layouts>
  93. </Div>
  94. </Layout>
  95. </Layouts>
  96. <Objects>
  97. <Dataset id="ds_send" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  98. <ColumnInfo>
  99. <Column id="instcd" type="STRING" size="256" sumtext="기관코드"/>
  100. </ColumnInfo>
  101. <Rows>
  102. <Row/>
  103. </Rows>
  104. </Dataset>
  105. <Dataset id="ds_init_prvg" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  106. <ColumnInfo>
  107. <Column id="cnt" type="STRING" size="256" sumtext="권한유무(있으면 1, 없으면 0)"/>
  108. </ColumnInfo>
  109. </Dataset>
  110. <Dataset id="ds_send_reqdata" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false" oncolumnchanged="ds_send_reqdata_oncolumnchanged">
  111. <ColumnInfo>
  112. <Column id="instcd" type="STRING" size="256" sumtext="기관코드"/>
  113. <Column id="year" type="STRING" size="256" sumtext="연도"/>
  114. </ColumnInfo>
  115. <Rows>
  116. <Row/>
  117. </Rows>
  118. </Dataset>
  119. <Dataset id="ds_main_codeinfo_codelist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false" oncolumnchanged="ds_main_codeinfo_codelist_oncolumnchanged">
  120. <ColumnInfo>
  121. <Column id="emplno" type="STRING" size="256" sumtext="사번"/>
  122. <Column id="emplnm" type="STRING" size="256" sumtext="성명"/>
  123. <Column id="jobkindnm" type="STRING" size="256" sumtext="직종명"/>
  124. <Column id="deptnm" type="STRING" size="256" sumtext="부서명"/>
  125. <Column id="evalemplno" type="STRING" size="256" sumtext="평가자사번"/>
  126. <Column id="evalemplnm" type="STRING" size="256" sumtext="평가자성명"/>
  127. <Column id="evaljobkindnm" type="STRING" size="256" sumtext="평가자직종명"/>
  128. <Column id="evaldeptnm" type="STRING" size="256" sumtext="평가자부서명"/>
  129. <Column id="instcd" type="STRING" size="256" sumtext="기관코드"/>
  130. <Column id="year" type="STRING" size="256" sumtext="연도"/>
  131. <Column id="colIUD" type="STRING" size="256"/>
  132. </ColumnInfo>
  133. </Dataset>
  134. <Dataset id="ds_senddata_execdata_codelist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  135. <ColumnInfo>
  136. <Column id="status" type="STRING" size="256" sumtext="처리구분"/>
  137. <Column id="emplno" type="STRING" size="256" sumtext="사번"/>
  138. <Column id="evalemplno" type="STRING" size="256" sumtext="평가자사번"/>
  139. <Column id="instcd" type="STRING" size="256" sumtext="기관코드"/>
  140. <Column id="year" type="STRING" size="256" sumtext="연도"/>
  141. </ColumnInfo>
  142. </Dataset>
  143. <Dataset id="ds_hidden_item" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  144. <ColumnInfo>
  145. <Column id="count" type="STRING" size="256" sumtext="실행건수"/>
  146. </ColumnInfo>
  147. </Dataset>
  148. </Objects>
  149. <Bind>
  150. <BindItem id="item0" compid="grp_main.cmb_instcd" propid="value" datasetid="ds_send_reqdata" columnid="instcd"/>
  151. <BindItem id="item1" compid="grp_main.ipt_year" propid="value" datasetid="ds_send_reqdata" columnid="year"/>
  152. </Bind>
  153. <Script type="xscript4.0"><![CDATA[/***************************************************************************************
  154. * System Name : 경대 의료정보시스템
  155. * Job Name : mis_dligclaznsmngtxp -> SMRPD31500
  156. * Creator : pjb
  157. * Make Date : 2017-12-22
  158. * Description :
  159. *---------------------------------------------------------------------------------------
  160. * Modify Date Modifier Modify Description
  161. *---------------------------------------------------------------------------------------
  162. * 2017-12-22 pjb TF->XP
  163. *
  164. *---------------------------------------------------------------------------------------
  165. ****************************************************************************************/
  166. //=======================================================================================
  167. // Lib Include
  168. //---------------------------------------------------------------------------------------
  169. include "com_commonxp::comm_main.xjs";
  170. include "mis_miscommonxp::MIS.xjs";
  171. include "mis_humtrafactmngtxp::RPB001.xjs";
  172. //=======================================================================================
  173. // Global Form Variable
  174. //---------------------------------------------------------------------------------------
  175. var arErrorCode = new HashArray();
  176. //=======================================================================================
  177. // Function
  178. //---------------------------------------------------------------------------------------
  179. function readfunc(){ // 해당 조건에 대한 사용자 권한내역을 조회한다.
  180. if (utlf_transNullToEmpty(grp_main.ipt_year.value).length != 4){
  181. sysf_messageBox("연도를 확인하십시요. ", "E999", "");
  182. grp_main.ipt_year.setFocus();
  183. return;
  184. }
  185. misfGridInit(grp_main.datagrid1);
  186. var oParam = {};
  187. oParam.id = "TRRPD31501";
  188. oParam.service = "dligclaznsmngtapp.DutScheMngt";
  189. oParam.method = "reqGetSpcEvalPsnList";
  190. oParam.inds = "req=ds_send_reqdata";
  191. oParam.outds = "ds_main_codeinfo_codelist=codelist";
  192. oParam.async = false;
  193. //oParam.callback = "cf_TRRPD31501";
  194. tranf_submit(oParam);
  195. ds_main_codeinfo_codelist.addColumn("colIUD", "string");
  196. }
  197. function datacheck(){
  198. var scdid1 = "";
  199. var scdid2 = "";
  200. // for (var i = 1; i < datagrid1.rows; i ++){
  201. /*
  202. if (model.getValue("/root/main/codeinfo/codelist[" + i + "]/cdid") == ""){
  203. messageBox("코드는 필수 입력 항목입니다.", "E999", "");
  204. return false;
  205. }
  206. if (model.getValue("/root/main/codeinfo/codelist[" + i + "]/cdnm") == ""){
  207. messageBox("명칭은 필수 입력 항목입니다.", "E999", "");
  208. return false;
  209. }
  210. */
  211. /*
  212. scdid1 = model.getValue("/root/main/codeinfo/codelist[" + i + "]/cdid");
  213. var k = i + 1;
  214. for (var j = k; j < datagrid1.rows; j++){
  215. scdid2 = model.getValue("/root/main/codeinfo/codelist[" + j + "]/cdid");
  216. if (i != j){
  217. if (scdid1 == scdid2){
  218. messageBox(j + "번째 행에서 중복된 코드가 존재합니다", "E999", "");
  219. return false;
  220. }
  221. }
  222. }
  223. */
  224. // }
  225. return true;
  226. }
  227. function ExecData(){
  228. grdf_setStatusColumn(ds_main_codeinfo_codelist, "status");
  229. var update = grdf_getGridUpdateData(grp_main.datagrid1);
  230. ds_senddata_execdata_codelist.assign(update);
  231. var oParam = {};
  232. oParam.id = "TXRPD31501";
  233. oParam.service = "dligclaznsmngtapp.DutScheMngt";
  234. oParam.method = "reqExeSaveSpcEvalPsnList";
  235. oParam.inds = "codelist=ds_senddata_execdata_codelist:A";
  236. oParam.outds = "ds_hidden_item=item";
  237. oParam.async = false;
  238. oParam.callback = "cf_TXRPD31501";
  239. tranf_submit(oParam);
  240. if (arErrorCode.pop("TXRPD31501") > -1){
  241. readfunc();
  242. }
  243. }
  244. function cf_TXRPD31501(sSvcId, nErrorCode, sErrorMsg) {
  245. arErrorCode.push(sSvcId, nErrorCode);
  246. }
  247. //=======================================================================================
  248. // Event
  249. //---------------------------------------------------------------------------------------
  250. /****************************************************************************************
  251. * Components : Form
  252. * Components ID : SMRPD31500
  253. * Event : oninit
  254. * Argument : 01.obj : Object Event has occurred
  255. * : 02.e : Event Object
  256. * Description : 화면 처음 초기화시
  257. ****************************************************************************************/
  258. function SMRPD31500_oninit(obj:Form, e:InitEventInfo)
  259. {
  260. frmf_initForm(obj); //폼 초기화
  261. }
  262. /****************************************************************************************
  263. * Components : Form
  264. * Components ID : SMRPD31500
  265. * Event : onload
  266. * Argument : 01.obj : Object Event has occurred
  267. * : 02.e : Event Object
  268. * Description : 화면 로딩 완료시
  269. ****************************************************************************************/
  270. function SMRPD31500_onload(obj:Form, e:LoadEventInfo)
  271. {
  272. grdf_setRowTypeIcon(grp_main.datagrid1, 0);
  273. grdf_setGridSort(grp_main.datagrid1);
  274. //전문의평가 관리권한 확인용 : 관리권한이 있는 자만 사용 가능
  275. var oParam = {};
  276. oParam.id = "TRRPD31102";
  277. oParam.service = "dligclaznsmngtapp.DutScheMngt";
  278. oParam.method = "reqGetSpcEvalMngtPrvg";
  279. oParam.inds = "req=ds_send";
  280. oParam.outds = "ds_init_prvg=codelist";
  281. oParam.async = false;
  282. oParam.callback = "cf_TRRPD31102";
  283. tranf_submit(oParam);
  284. if (arErrorCode.pop("TRRPD31102") > -1) {
  285. if(ds_init_prvg.getColumn(0, "cnt") != "1") {
  286. sysf_messageBox("프로그램 사용권한이 없습니다. 관리자에게 문의바랍니다.", "E999", "");
  287. return;
  288. }
  289. }
  290. misfComboInstCdListMulti("grp_main.cmb_instcd", utlf_getCurrentDate(),"","N");
  291. //model.setValue(cmb_instcd.attribute("ref"), getUserInfo("dutplceinstcd"));
  292. //model.refresh();
  293. grp_main.cmb_instcd.value = sysf_getUserInfo("dutplceinstcd");
  294. ds_send_reqdata.enableevent = false;
  295. ds_send_reqdata.updatecontrol = false;
  296. grp_main.ipt_year.value = utlf_getCurrentDate().substr(0,4) - 1;
  297. ds_send_reqdata.updatecontrol = true;
  298. ds_send_reqdata.enableevent = true;
  299. grp_main.btn_search.click();
  300. }
  301. function cf_TRRPD31102(sSvcId, nErrorCode, sErrorMsg) {
  302. arErrorCode.push(sSvcId, nErrorCode);
  303. }
  304. /****************************************************************************************
  305. * Components : Combo
  306. * Components ID : grp_main_cmb_instcd
  307. * Event : onitemchanged
  308. * Argument : 01.obj : Object Event has occurred
  309. * : 02.e : Event Object
  310. * Description : 기관코드 콤보 항목 변경시
  311. ****************************************************************************************/
  312. function grp_main_cmb_instcd_onitemchanged(obj:Combo, e:ItemChangeEventInfo)
  313. {
  314. misfGridInit(grp_main.datagrid1);
  315. }
  316. /****************************************************************************************
  317. * Components : Dataset
  318. * Components ID : ds_send_reqdata
  319. * Event : oncolumnchanged
  320. * Argument : 01.obj : Object Event has occurred
  321. * : 02.e : Event Object
  322. * Description : ds_send_reqdata 데이터셋 값 변경시
  323. ****************************************************************************************/
  324. function ds_send_reqdata_oncolumnchanged(obj:Dataset, e:DSColChangeEventInfo)
  325. {
  326. switch( e.columnid ) {
  327. case "year" :
  328. grp_main.btn_search.click();
  329. break;
  330. default :
  331. break;
  332. }
  333. }
  334. /****************************************************************************************
  335. * Components : Button
  336. * Components ID : grp_main_btn_search
  337. * Event : onclick
  338. * Argument : 01.obj : Object Event has occurred
  339. * : 02.e : Event Object
  340. * Description : 조회버튼 클릭시
  341. ****************************************************************************************/
  342. function grp_main_btn_search_onclick(obj:Button, e:ClickEventInfo)
  343. {
  344. readfunc();
  345. }
  346. /****************************************************************************************
  347. * Components : Dataset
  348. * Components ID : ds_main_codeinfo_codelist
  349. * Event : oncolumnchanged
  350. * Argument : 01.obj : Object Event has occurred
  351. * : 02.e : Event Object
  352. * Description : Dataset 값 변경시
  353. ****************************************************************************************/
  354. function ds_main_codeinfo_codelist_oncolumnchanged(obj:Dataset, e:DSColChangeEventInfo)
  355. {
  356. switch(e.columnid) {
  357. case "emplno" :
  358. var recv_list = "emplno,emplnm";
  359. misfValidationCheck("01-1", "", recv_list);
  360. break;
  361. case "evalemplno" :
  362. var recv_list = "evalemplno,evalemplnm";
  363. misfValidationCheck("01-1", "", recv_list);
  364. break;
  365. default :
  366. break;
  367. }
  368. ds_main_codeinfo_codelist.setColumn(e.row, "colIUD", "u");
  369. }
  370. /****************************************************************************************
  371. * Components : Grid
  372. * Components ID : grp_main_datagrid1
  373. * Event : onexpandup
  374. * Argument : 01.obj : Object Event has occurred
  375. * : 02.e : Event Object
  376. * Description : 그리드의 버튼 expandup시
  377. ****************************************************************************************/
  378. function grp_main_datagrid1_onexpandup(obj:Grid, e:GridMouseEventInfo)
  379. {
  380. var sColNM = grp_main.datagrid1.getCellProperty("Body", e.cell, "text").replace("bind:", "");
  381. if (sColNM == "emplno" ) { //계산기준코드
  382. var recv_list = "emplno,emplnm";
  383. rpbfOpenPopUpList("SPRPB00101", grp_main.datagrid1, recv_list, "", "N");
  384. }
  385. else if (sColNM == "evalemplno" ) { //계산기준코드
  386. //잠시 backup
  387. ds_main_codeinfo_codelist.enableevent = false;
  388. ds_main_codeinfo_codelist.updatecontrol = false;
  389. var vEmplno = ds_main_codeinfo_codelist.getColumn(ds_main_codeinfo_codelist.rowposition, "emplno");
  390. var vEmplnm = ds_main_codeinfo_codelist.getColumn(ds_main_codeinfo_codelist.rowposition, "emplnm");
  391. ds_main_codeinfo_codelist.setColumn(ds_main_codeinfo_codelist.rowposition, "emplno", "");
  392. ds_main_codeinfo_codelist.setColumn(ds_main_codeinfo_codelist.rowposition, "emplnm", "");
  393. ds_main_codeinfo_codelist.updatecontrol = true;
  394. ds_main_codeinfo_codelist.enableevent = true;
  395. var recv_list = "emplno,emplnm";
  396. rpbfOpenPopUpList("SPRPB00101", grp_main.datagrid1, recv_list, "", "N");
  397. ds_main_codeinfo_codelist.enableevent = false;
  398. //Popup 에서 값을 선택했을 경우에만 vEvalemplno, vEvalemplnm 에 값을 가져온다.
  399. if( !utlf_isNull(ds_main_codeinfo_codelist.getColumn(ds_main_codeinfo_codelist.rowposition, "emplno")) ) {
  400. ds_main_codeinfo_codelist.setColumn(ds_main_codeinfo_codelist.rowposition, "evalemplno",
  401. ds_main_codeinfo_codelist.getColumn(ds_main_codeinfo_codelist.rowposition, "emplno") );
  402. }
  403. if( !utlf_isNull(ds_main_codeinfo_codelist.getColumn(ds_main_codeinfo_codelist.rowposition, "emplnm")) ) {
  404. ds_main_codeinfo_codelist.setColumn(ds_main_codeinfo_codelist.rowposition, "evalemplnm",
  405. ds_main_codeinfo_codelist.getColumn(ds_main_codeinfo_codelist.rowposition, "emplnm") );
  406. }
  407. ds_main_codeinfo_codelist.enableevent = true;
  408. ds_main_codeinfo_codelist.enableevent = false;
  409. ds_main_codeinfo_codelist.updatecontrol = false;
  410. ds_main_codeinfo_codelist.setColumn(ds_main_codeinfo_codelist.rowposition, "emplno", vEmplno);
  411. ds_main_codeinfo_codelist.setColumn(ds_main_codeinfo_codelist.rowposition, "emplnm", vEmplnm);
  412. ds_main_codeinfo_codelist.updatecontrol = true;
  413. ds_main_codeinfo_codelist.enableevent = true;
  414. }
  415. }
  416. /****************************************************************************************
  417. * Components : Button
  418. * Components ID : grp_main_btn_grdadd
  419. * Event : onclick
  420. * Argument : 01.obj : Object Event has occurred
  421. * : 02.e : Event Object
  422. * Description : 행추가 버튼 클릭시
  423. ****************************************************************************************/
  424. function grp_main_btn_grdadd_onclick(obj:Button, e:ClickEventInfo)
  425. {
  426. if (utlf_transNullToEmpty(grp_main.ipt_year.value).length != 4){
  427. sysf_messageBox("연도를 확인하십시요. ", "E999", "");
  428. grp_main.ipt_year.setFocus();
  429. return;
  430. }
  431. ds_main_codeinfo_codelist.addRow();
  432. var irow = ds_main_codeinfo_codelist.rowposition;
  433. ds_main_codeinfo_codelist.setColumn(irow, "instcd", grp_main.cmb_instcd.value);
  434. ds_main_codeinfo_codelist.setColumn(irow, "year", grp_main.ipt_year.value);
  435. ds_main_codeinfo_codelist.rowposition = irow;
  436. grp_main.datagrid1.setCellPos( grp_main.datagrid1.getBindCellIndex("body", "emplno") );
  437. grp_main.datagrid1.setFocus();
  438. grp_main.datagrid1.showEditor(true);
  439. }
  440. /****************************************************************************************
  441. * Components : Button
  442. * Components ID : grp_main_btn_grddel
  443. * Event : onclick
  444. * Argument : 01.obj : Object Event has occurred
  445. * : 02.e : Event Object
  446. * Description : 행삭제 버튼 클릭시
  447. ****************************************************************************************/
  448. function grp_main_btn_grddel_onclick(obj:Button, e:ClickEventInfo)
  449. {
  450. var status = ds_main_codeinfo_codelist.getRowType(ds_main_codeinfo_codelist.rowposition);
  451. ds_main_codeinfo_codelist.enableevent = false;
  452. ds_main_codeinfo_codelist.updatecontrol = false;
  453. if(status == 1) {
  454. ds_main_codeinfo_codelist.setRowType(ds_main_codeinfo_codelist.rowposition, 8);
  455. }else if(status == 2) {
  456. ds_main_codeinfo_codelist.deleteRow(ds_main_codeinfo_codelist.rowposition);
  457. }else if(status == 4) {
  458. ds_main_codeinfo_codelist.setColumn(ds_main_codeinfo_codelist.rowposition, "colIUD", "u");
  459. ds_main_codeinfo_codelist.setRowType(ds_main_codeinfo_codelist.rowposition, 8);
  460. }else if(status == 8) {
  461. if(ds_main_codeinfo_codelist.getColumn(ds_main_codeinfo_codelist.rowposition, "colIUD") == "u") {
  462. ds_main_codeinfo_codelist.setRowType(ds_main_codeinfo_codelist.rowposition, 4);
  463. }else {
  464. ds_main_codeinfo_codelist.setRowType(ds_main_codeinfo_codelist.rowposition, 1);
  465. }
  466. }
  467. ds_main_codeinfo_codelist.updatecontrol = true;
  468. ds_main_codeinfo_codelist.enableevent = true;
  469. }
  470. /****************************************************************************************
  471. * Components : Button
  472. * Components ID : grp_main_btn_download
  473. * Event : onclick
  474. * Argument : 01.obj : Object Event has occurred
  475. * : 02.e : Event Object
  476. * Description : 엑셀 다운 버튼 클릭시
  477. ****************************************************************************************/
  478. function grp_main_btn_download_onclick(obj:Button, e:ClickEventInfo)
  479. {
  480. //조회된 자료가 없으면 먼저 조회하라고 message
  481. if(ds_main_codeinfo_codelist.rowcount < 1) {
  482. sysf_messageBox("조회된 결과가 존재하지 않습니다. \n\n먼저 조회 후 Download 하십시요. ", "E999", "");
  483. return;
  484. }
  485. //misfSaveExcel(datagrid1, "평가항목");
  486. grdf_exportExcel(grp_main.datagrid1, "excel", "savetype", false, "", "user", false);
  487. }
  488. function grp_button_btn_save_onclick(obj:Button, e:ClickEventInfo)
  489. {
  490. if (datacheck() == false){
  491. return;
  492. }
  493. ExecData();
  494. }
  495. function grp_main_btn_psn_onclick(obj:Button, e:ClickEventInfo)
  496. {
  497. if (utlf_transNullToEmpty(grp_main.ipt_year.value).length != 4){
  498. sysf_messageBox("연도를 확인하십시요. ", "E999", "");
  499. grp_main.ipt_year.setFocus();
  500. return;
  501. }
  502. if( sysf_messageBox("대상자 생성 작업시 해당 연도에 등록된 기존 자료는 \n모두 삭제됩니다. \n\n대상자 생성 작업을 시작하시겠습니다? " , "Q99" ) == 6 ){
  503. var oParam = {};
  504. oParam.id = "TXRPD31502";
  505. oParam.service = "dligclaznsmngtapp.DutScheMngt";
  506. oParam.method = "reqExeSaveSpcEvalPsnCreate";
  507. oParam.inds = "req=ds_send_reqdata";
  508. oParam.outds = "ds_hidden_item=item";
  509. oParam.async = false;
  510. oParam.callback = "cf_TXRPD31502";
  511. tranf_submit(oParam);
  512. if (arErrorCode.pop("TXRPD31502") > -1){
  513. readfunc();
  514. }
  515. }
  516. }
  517. function cf_TXRPD31502(sSvcId, nErrorCode, sErrorMsg) {
  518. arErrorCode.push(sSvcId, nErrorCode);
  519. }]]></Script>
  520. </Form>
  521. </FDL>