SPMMB02300_검체임상소견.xfdl 33 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <FDL version="1.5">
  3. <TypeDefinition url="..\..\..\default_typedef.xml"/>
  4. <Form id="SPMMB02300" position="absolute 0 0 789 491" titletext="검체임상소견" onload="SPMMB02300_onload" oninit="SPMMB02300_oninit">
  5. <Layouts>
  6. <Layout>
  7. <Tab position="absolute 0 0 784 488" id="switch1" style="buttonpadding:4 10 4 10;">
  8. <Tabpages>
  9. <Tabpage text=" 검체 " id="case1">
  10. <Layouts>
  11. <Layout>
  12. <Button position="absolute 480 1 522 20" id="button37" class="btn5" text="복사" onclick="switch1_case1_button37_onclick"/>
  13. <Button position="absolute 740 1 782 20" id="button2" class="btn5" text="저장" onclick="switch1_case1_button2_onclick"/>
  14. <Grid position="absolute 528 22 784 460" id="grd_uselpcmspcm" binddataset="ds_main_lpcmspcmlist" autofittype="col" selecttype="multirow" onrbuttondown="switch1_case1_grd_uselpcmspcm_onrbuttondown">
  15. <Formats>
  16. <Format id="default">
  17. <Columns>
  18. <Column size="35"/>
  19. <Column size="199"/>
  20. </Columns>
  21. <Rows>
  22. <Row size="24" band="head"/>
  23. <Row size="24"/>
  24. </Rows>
  25. <Band id="head">
  26. <Cell/>
  27. <Cell col="1" text="자주쓰는 병리검체"/>
  28. </Band>
  29. <Band id="body">
  30. <Cell displaytype="combo" edittype="combo" text="bind:status" combodataset="ds_cmb_uselpcmspcm_status" combocodecol="value" combodatacol="label"/>
  31. <Cell col="1" displaytype="normal" edittype="none" style="align:left;padding:0 0 0 5;" text="bind:spcnm"/>
  32. </Band>
  33. </Format>
  34. </Formats>
  35. </Grid>
  36. <Grid position="absolute 271 22 527 460" id="grd_lpcmspcm" binddataset="ds_lpcmspcmlist" autofittype="col" oncelldblclick="switch1_case1_grd_lpcmspcm_oncelldblclick">
  37. <Formats>
  38. <Format id="default">
  39. <Columns>
  40. <Column size="20"/>
  41. <Column size="175"/>
  42. </Columns>
  43. <Rows>
  44. <Row size="24" band="head"/>
  45. <Row size="24"/>
  46. </Rows>
  47. <Band id="head">
  48. <Cell/>
  49. <Cell col="1" text="병리검체"/>
  50. </Band>
  51. <Band id="body">
  52. <Cell displaytype="checkbox" edittype="checkbox" text="bind:status" expr="expr:(status==&quot;I&quot; || status==&quot;1&quot;)?1:0"/>
  53. <Cell col="1" displaytype="normal" edittype="none" style="align:left;padding:0 0 0 5;" text="bind:spcnm"/>
  54. </Band>
  55. </Format>
  56. </Formats>
  57. </Grid>
  58. <Grid position="absolute 0 22 270 460" id="datagrid1" binddataset="ds_prcpclscdlist" autofittype="col" onlbuttonup="switch1_case1_datagrid1_onlbuttonup">
  59. <Formats>
  60. <Format id="default">
  61. <Columns>
  62. <Column size="250"/>
  63. </Columns>
  64. <Rows>
  65. <Row size="24" band="head"/>
  66. <Row size="24"/>
  67. </Rows>
  68. <Band id="head">
  69. <Cell text="검체분류"/>
  70. </Band>
  71. <Band id="body">
  72. <Cell style="align:left;padding:0 0 0 5;" text="bind:prcpclsnm"/>
  73. </Band>
  74. </Format>
  75. </Formats>
  76. </Grid>
  77. <Radio position="absolute 594 2 734 21" id="radio1" columncount="2" codecolumn="codecolumn" datacolumn="datacolumn" onitemchanged="switch1_case1_radio1_onitemchanged">
  78. <Dataset id="innerdataset">
  79. <ColumnInfo>
  80. <Column id="codecolumn"/>
  81. <Column id="datacolumn"/>
  82. </ColumnInfo>
  83. <Rows>
  84. <Row>
  85. <Col id="codecolumn">all</Col>
  86. <Col id="datacolumn">전체조회</Col>
  87. </Row>
  88. <Row>
  89. <Col id="codecolumn">cls</Col>
  90. <Col id="datacolumn">분류조회</Col>
  91. </Row>
  92. </Rows>
  93. </Dataset>
  94. </Radio>
  95. </Layout>
  96. </Layouts>
  97. </Tabpage>
  98. <Tabpage text="임상소견" id="case2">
  99. <Layouts>
  100. <Layout>
  101. <Button position="absolute 693 0 735 19" id="button4" class="btn5" text="추가" onclick="switch1_case2_button4_onclick"/>
  102. <Button position="absolute 739 0 781 19" id="button6" class="btn5" text="저장" onclick="switch1_case2_button6_onclick"/>
  103. <Grid position="absolute 0 21 784 461" id="grd_clinccmtlist" binddataset="ds_clinccmtlist" autofittype="col" selecttype="multirow" onrbuttondown="switch1_case2_grd_clinccmtlist_onrbuttondown">
  104. <Formats>
  105. <Format id="default">
  106. <Columns>
  107. <Column size="35"/>
  108. <Column size="711"/>
  109. </Columns>
  110. <Rows>
  111. <Row size="24" band="head"/>
  112. <Row size="24"/>
  113. </Rows>
  114. <Band id="head">
  115. <Cell/>
  116. <Cell col="1" text="자주쓰는 병리임상소견"/>
  117. </Band>
  118. <Band id="body">
  119. <Cell displaytype="combo" edittype="combo" text="bind:status" combodataset="ds_cmb_uselpcmspcm_status" combocodecol="value" combodatacol="label"/>
  120. <Cell col="1" displaytype="text" edittype="text" text="bind:etccnts"/>
  121. </Band>
  122. </Format>
  123. </Formats>
  124. </Grid>
  125. </Layout>
  126. </Layouts>
  127. </Tabpage>
  128. </Tabpages>
  129. </Tab>
  130. <Static text="진료과:" position="absolute 151 1 206 21" id="caption1"/>
  131. <Combo position="absolute 196 1 381 20" id="cmb_ordept" innerdataset="@ds_init_orddept" datacolumn="depthngnm" codecolumn="deptcd" onitemchanged="cmb_ordept_onitemchanged"/>
  132. </Layout>
  133. </Layouts>
  134. <Objects>
  135. <Dataset id="ds_main_lpcmspcmlist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" reversesubsum="false">
  136. <ColumnInfo>
  137. <Column id="status" type="STRING" size="256"/>
  138. <Column id="spccd" type="STRING" size="256"/>
  139. <Column id="spcnm" type="STRING" size="256"/>
  140. <Column id="orddeptcd" type="STRING" size="256"/>
  141. <Column id="spckind" type="STRING" size="256"/>
  142. <Column id="spckindno" type="STRING" size="256"/>
  143. </ColumnInfo>
  144. </Dataset>
  145. <Dataset id="ds_lpcmspcmlist" firefirstcount="0" firenextcount="0" useclientlayout="true" updatecontrol="true" enableevent="true" loadkeymode="keep" reversesubsum="false" oncolumnchanged="ds_lpcmspcmlist_oncolumnchanged">
  146. <ColumnInfo>
  147. <Column id="status" type="STRING" size="256"/>
  148. <Column id="spccd" type="STRING" size="256"/>
  149. <Column id="spcnm" type="STRING" size="256"/>
  150. <Column id="orddeptcd" type="STRING" size="256"/>
  151. <Column id="spckind" type="STRING" size="256"/>
  152. <Column id="spckindno" type="STRING" size="256"/>
  153. </ColumnInfo>
  154. </Dataset>
  155. <Dataset id="ds_prcpclscdlist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" reversesubsum="false">
  156. <ColumnInfo>
  157. <Column id="instcd" type="STRING" size="256" sumtext="기관코,"/>
  158. <Column id="prcpclscd1" type="STRING" size="256" sumtext="검체분류1"/>
  159. <Column id="prcpclscd2" type="STRING" size="256" sumtext="검체분류2"/>
  160. <Column id="prcpclscd3" type="STRING" size="256" sumtext="검체분류3"/>
  161. <Column id="prcpclsnm" type="STRING" size="256" sumtext="검체분류명"/>
  162. <Column id="calcscorcd" type="STRING" size="256" sumtext="수가코드"/>
  163. </ColumnInfo>
  164. </Dataset>
  165. <Dataset id="ds_clinccmtlist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" reversesubsum="false" oncolumnchanged="ds_clinccmtlist_oncolumnchanged">
  166. <ColumnInfo>
  167. <Column id="status" type="STRING" size="256"/>
  168. <Column id="cdkind" type="STRING" size="256"/>
  169. <Column id="cdno" type="STRING" size="256"/>
  170. <Column id="etccnts" type="STRING" size="256"/>
  171. <Column id="orddeptcd" type="STRING" size="256"/>
  172. </ColumnInfo>
  173. </Dataset>
  174. <Dataset id="ds_init_orddept" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" reversesubsum="false">
  175. <ColumnInfo>
  176. <Column id="depthngnm" type="STRING"/>
  177. <Column id="deptcd" type="STRING"/>
  178. </ColumnInfo>
  179. </Dataset>
  180. <Dataset id="ds_init" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  181. <ColumnInfo>
  182. <Column id="orddeptcd" type="STRING" size="256"/>
  183. </ColumnInfo>
  184. <Rows>
  185. <Row/>
  186. </Rows>
  187. </Dataset>
  188. <Dataset id="ds_send" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  189. <ColumnInfo>
  190. <Column id="cond1" type="STRING" size="256"/>
  191. <Column id="cond2" type="STRING" size="256"/>
  192. <Column id="cond3" type="STRING" size="256"/>
  193. <Column id="cond4" type="STRING" size="256"/>
  194. </ColumnInfo>
  195. <Rows>
  196. <Row>
  197. <Col id="cond4">cls</Col>
  198. </Row>
  199. </Rows>
  200. </Dataset>
  201. <Dataset id="ds_main_totlpcmspcmlist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  202. <ColumnInfo>
  203. <Column id="status" type="STRING" size="256" sumtext="상태"/>
  204. <Column id="spccd" type="STRING" size="256" sumtext="검체코드"/>
  205. <Column id="spcnm" type="STRING" size="256" sumtext="검체명"/>
  206. <Column id="orddeptcd" type="STRING" size="256" sumtext="진료과코드"/>
  207. <Column id="spckind" type="STRING" size="256" sumtext="검체종류"/>
  208. <Column id="spckindno" type="STRING" size="256" sumtext="검체종류번호"/>
  209. </ColumnInfo>
  210. </Dataset>
  211. <Dataset id="ds_cmb_uselpcmspcm_status" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  212. <ColumnInfo>
  213. <Column id="label" type="STRING" size="256"/>
  214. <Column id="value" type="STRING" size="256"/>
  215. </ColumnInfo>
  216. <Rows>
  217. <Row>
  218. <Col id="label">-</Col>
  219. <Col id="value">-</Col>
  220. </Row>
  221. <Row>
  222. <Col id="label">신규</Col>
  223. <Col id="value">I</Col>
  224. </Row>
  225. <Row>
  226. <Col id="label">수정</Col>
  227. <Col id="value">U</Col>
  228. </Row>
  229. <Row>
  230. <Col id="label">삭제</Col>
  231. <Col id="value">D</Col>
  232. </Row>
  233. </Rows>
  234. </Dataset>
  235. <Dataset id="ds_reset_clinccmtlist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  236. <ColumnInfo>
  237. <Column id="status" type="STRING" size="256"/>
  238. <Column id="cdkind" type="STRING" size="256"/>
  239. <Column id="cdno" type="STRING" size="256"/>
  240. <Column id="etccnts" type="STRING" size="256"/>
  241. <Column id="orddeptcd" type="STRING" size="256"/>
  242. </ColumnInfo>
  243. <Rows>
  244. <Row>
  245. <Col id="status">I</Col>
  246. </Row>
  247. </Rows>
  248. </Dataset>
  249. </Objects>
  250. <Bind>
  251. <BindItem id="item0" compid="cmb_ordept" propid="value" datasetid="ds_init" columnid="orddeptcd"/>
  252. <BindItem id="item1" compid="switch1.case1.radio1" propid="value" datasetid="ds_send" columnid="cond4"/>
  253. </Bind>
  254. <Script type="xscript4.0"><![CDATA[/***************************************************************************************
  255. * System Name :
  256. * Job Name :
  257. * Creator :
  258. * Make Date : 2014-08-29
  259. * Description :
  260. *---------------------------------------------------------------------------------------
  261. * Modify Date Modifier Modify Description
  262. *---------------------------------------------------------------------------------------
  263. * 2014-08-29 Live Converter TF->XP
  264. *
  265. *---------------------------------------------------------------------------------------
  266. ****************************************************************************************/
  267. //=======================================================================================
  268. // Lib Include
  269. //---------------------------------------------------------------------------------------
  270. include "com_commonxp::comm_main.xjs"
  271. include "emr_prcpmngtxp::MMOCommon.xjs"
  272. include "emr_medirecxp::MMRCommon.xjs"
  273. var arErrorCode = new HashArray();
  274. //=======================================================================================
  275. // Event
  276. //---------------------------------------------------------------------------------------
  277. function SPMMB02300_oninit(obj:Form, e:InitEventInfo)
  278. {
  279. frmf_initForm(obj); // 폼 초기화
  280. }
  281. /****************************************************************************************
  282. * Components : Form
  283. * Components ID : SPMMB02300
  284. * Event : onload
  285. * Argument : 01.obj : Object Event has occurred
  286. * : 02.e : Event Object
  287. * Description : 화면 로드시 초기화 함수 실행
  288. ****************************************************************************************/
  289. function SPMMB02300_onload(obj:Form, e:LoadEventInfo)
  290. {
  291. grdf_initGrid(switch1.case1.grd_lpcmspcm);
  292. // 팝업메뉴 생성
  293. frmf_createPopupMenu("del_grd_uselpcmspcm"
  294. ,"fDeleteRow"
  295. ,[{id: "D", level: "0", title: "삭제"}]
  296. );
  297. frmf_createPopupMenu("del_grd_clinccmtlist"
  298. ,"fSpcDeleteRow"
  299. ,[{id: "D", level: "0", title: "삭제"}]
  300. );
  301. switch1.tabindex = 0;
  302. lf_mmbfGetDeptCodeComboList(ds_init_orddept, "A");
  303. ds_init.setColumn(0,"orddeptcd",sysf_getUserInfo("dutplcecd"));
  304. var oParam = {};
  305. oParam.id = "TRMMB02304";
  306. oParam.service = "prcpbaseapp.OrdPrcpMngt";
  307. oParam.method = "reqGetLpcmspcmCls";
  308. oParam.inds = "req=ds_send";
  309. oParam.outds = "ds_prcpclscdlist=prcpclscdlist";
  310. oParam.async = false;
  311. oParam.callback = "cf_TRMMB02304";
  312. tranf_submit(oParam);
  313. var calcscorcd = ds_prcpclscdlist.getColumn(0,"calcscorcd");
  314. if (!utlf_isNull(cmb_ordept.text)) {
  315. cmb_ordept.enable = false;
  316. ds_send.setColumn(0,"cond1",ds_init.getColumn(0,"orddeptcd"));
  317. ds_send.setColumn(0,"cond2","1");
  318. ds_send.setColumn(0,"cond3",calcscorcd);
  319. var oParam = {};
  320. oParam.id = "TRMMB02302";
  321. oParam.service = "prcpbaseapp.OrdPrcpMngt";
  322. oParam.method = "reqGetUseLpcmspcm";
  323. oParam.inds = "req=ds_send";
  324. oParam.outds = "ds_main_lpcmspcmlist=lpcmspcmlist ds_main_totlpcmspcmlist=totlpcmspcmlist";
  325. oParam.async = false;
  326. oParam.callback = "";
  327. tranf_submit(oParam);
  328. var oParam = {};
  329. oParam.id = "TRMMB02211";
  330. oParam.service = "prcpbaseapp.OrdPrcpMngt";
  331. oParam.method = "reqGetClincCmtList";
  332. oParam.inds = "req=ds_send";
  333. oParam.outds = "ds_clinccmtlist=clinccmtlist";
  334. oParam.async = false;
  335. oParam.callback = "";
  336. tranf_submit(oParam);
  337. fColorSetting();
  338. } else {
  339. cmb_ordept.enable = true;
  340. ds_main_lpcmspcmlist.clear();
  341. ds_clinccmtlist.clear();
  342. }
  343. }
  344. /****************************************************************************************
  345. * Components : Grid
  346. * Components ID : switch1.case1.datagrid1
  347. * Event : onlbuttonup
  348. * Argument : 01.obj : Object Event has occurred
  349. * : 02.e : Event Object
  350. * Description : 검체 분류 선택시 병리검체 조회
  351. ****************************************************************************************/
  352. function switch1_case1_datagrid1_onlbuttonup(obj:Grid, e:GridMouseEventInfo)
  353. {
  354. if(e.row > -1){
  355. var calcscorcd = ds_prcpclscdlist.getColumn(e.row,"calcscorcd");
  356. ds_send.setColumn(0,"cond1",calcscorcd);
  357. var oParam = {};
  358. oParam.id = "TRMMB02301";
  359. oParam.service = "prcpbaseapp.OrdPrcpMngt";
  360. oParam.method = "reqGetLpcmspcm";
  361. oParam.inds = "req=ds_send";
  362. oParam.outds = "ds_lpcmspcmlist=lpcmspcmlist";
  363. oParam.async = false;
  364. oParam.callback = "";
  365. tranf_submit(oParam);
  366. if (!utlf_isNull(cmb_ordept.text)) {
  367. ds_send.setColumn(0,"cond1",ds_init.getColumn(0,"orddeptcd"));
  368. ds_send.setColumn(0,"cond2","1");
  369. ds_send.setColumn(0,"cond3",calcscorcd);
  370. var oParam = {};
  371. oParam.id = "TRMMB02302";
  372. oParam.service = "prcpbaseapp.OrdPrcpMngt";
  373. oParam.method = "reqGetUseLpcmspcm";
  374. oParam.inds = "req=ds_send";
  375. oParam.outds = "ds_main_lpcmspcmlist=lpcmspcmlist ds_main_totlpcmspcmlist=totlpcmspcmlist";
  376. oParam.async = false;
  377. oParam.callback = "";
  378. tranf_submit(oParam);
  379. }
  380. fColorSetting();
  381. }
  382. }
  383. /****************************************************************************************
  384. * Components : Grid
  385. * Components ID : switch1.case1.grd_lpcmspcm
  386. * Event : oncelldblclick
  387. * Argument : 01.obj : Object Event has occurred
  388. * : 02.e : Event Object
  389. * Description : 병리검체 더블클릭시 자주쓰는 병리검체에 추가
  390. ****************************************************************************************/
  391. function switch1_case1_grd_lpcmspcm_oncelldblclick(obj:Grid, e:GridClickEventInfo)
  392. {
  393. if(e.row > -1){
  394. var spcnm = ds_lpcmspcmlist.getColumn(e.row,"spcnm");
  395. var spccd = ds_lpcmspcmlist.getColumn(e.row,"spccd");
  396. var totchkspccd = ds_main_totlpcmspcmlist.getColumn(ds_main_totlpcmspcmlist.findRow("spccd",spccd),"spccd");
  397. var chckspccd = ds_main_lpcmspcmlist.getColumn(ds_main_lpcmspcmlist.findRow("spccd",spccd),"spccd");
  398. var totchkspcnm = ds_main_totlpcmspcmlist.getColumn(ds_main_totlpcmspcmlist.findRow("spcnm",spcnm),"spcnm");
  399. var chckspcnm = ds_main_lpcmspcmlist.getColumn(ds_main_lpcmspcmlist.findRow("spcnm",spcnm),"spcnm");
  400. if(utlf_isNull(totchkspccd) && utlf_isNull(chckspccd)){
  401. ds_lpcmspcmlist.setColumn(e.row,"status","I");
  402. ds_lpcmspcmlist.setColumn(e.row,"orddeptcd",ds_init.getColumn(0,"orddeptcd"));
  403. // model.duplicate ( "/root/main/lpcmspcm", "/root/lpcmspcmsrch/lpcmspcmlist[" + grd_lpcmspcm.row + "]" , "*[1]");
  404. ds_main_lpcmspcmlist.copyRow(ds_main_lpcmspcmlist.insertRow(0),ds_lpcmspcmlist,e.row);
  405. } else {
  406. sysf_messageBox ("[" + spcnm + "]는 이미 있는 검체명", "E008" );
  407. }
  408. }
  409. }
  410. /****************************************************************************************
  411. * Components : Dataset
  412. * Components ID : ds_lpcmspcmlist
  413. * Event : oncolumnchanged
  414. * Argument : 01.obj : Object Event has occurred
  415. * : 02.e : Event Object
  416. * Description : 병리검체 체크박스 체크
  417. ****************************************************************************************/
  418. function ds_lpcmspcmlist_oncolumnchanged(obj:Dataset, e:DSColChangeEventInfo)
  419. {
  420. if(e.columnid=="status") {
  421. obj.setColumn(e.row,e.columnid,(e.newvalue=="I"||e.newvalue==1)?"I":"N");
  422. }
  423. }
  424. /****************************************************************************************
  425. * Components : Button
  426. * Components ID : switch1.case1.button37
  427. * Event : onclick
  428. * Argument : 01.obj : Object Event has occurred
  429. * : 02.e : Event Object
  430. * Description : 복사버튼 클릭시 선택된 병리검체 자주쓰는 병리검체에 일괄 복사
  431. ****************************************************************************************/
  432. function switch1_case1_button37_onclick(obj:Button, e:ClickEventInfo)
  433. {
  434. var spccd = "";
  435. for(var i = 0 ; i < ds_lpcmspcmlist.rowcount ; i++ ) {
  436. if(ds_lpcmspcmlist.getColumn(i,"status") == "I" ) {
  437. spccd = ds_lpcmspcmlist.getColumn(i,"spccd");
  438. if(utlf_isNull(ds_main_lpcmspcmlist.getColumn(ds_main_lpcmspcmlist.findRow("spccd",spccd),"spccd"))) {
  439. ds_lpcmspcmlist.setColumn(i,"orddeptcd",ds_init.getColumn(0,"orddeptcd"));
  440. // var pDestNode = model.instances(0).selectSingleNode("/root/main/lpcmspcm");
  441. // var pSrchNode = model.instances(0).selectSingleNode("/root/lpcmspcmsrch/lpcmspcmlist[" + i + "]");
  442. // pDestNode.appendChild(pSrchNode.cloneNode(true));
  443. ds_main_lpcmspcmlist.copyRow(ds_main_lpcmspcmlist.addRow(),ds_lpcmspcmlist,i);
  444. } else {
  445. sysf_messageBox(ds_lpcmspcmlist.getColumn(ds_lpcmspcmlist.findRow("spccd",spccd),"spcnm") + "는 이미 있는 검체명 입니다", "E" );
  446. }
  447. }
  448. }
  449. }
  450. /****************************************************************************************
  451. * Components : Radio
  452. * Components ID : switch1.case1.radio1
  453. * Event : onitemchanged
  454. * Argument : 01.obj : Object Event has occurred
  455. * : 02.e : Event Object
  456. * Description : 전체조회 분류조회 라디오 버튼 선택
  457. ****************************************************************************************/
  458. function switch1_case1_radio1_onitemchanged(obj:Radio, e:ItemChangeEventInfo)
  459. {
  460. if(!utlf_isNull(cmb_ordept.text)) {
  461. var calcscorcd = ds_prcpclscdlist.getColumn(ds_prcpclscdlist.rowposition,"calcscorcd");
  462. ds_send.setColumn(0,"cond1",ds_init.getColumn(0,"orddeptcd"));
  463. ds_send.setColumn(0,"cond2","1");
  464. ds_send.setColumn(0,"cond3",calcscorcd);
  465. var oParam = {};
  466. oParam.id = "TRMMB02302";
  467. oParam.service = "prcpbaseapp.OrdPrcpMngt";
  468. oParam.method = "reqGetUseLpcmspcm";
  469. oParam.inds = "req=ds_send";
  470. oParam.outds = "ds_main_lpcmspcmlist=lpcmspcmlist ds_main_totlpcmspcmlist=totlpcmspcmlist";
  471. oParam.async = false;
  472. oParam.callback = "";
  473. tranf_submit(oParam);
  474. }
  475. }
  476. /****************************************************************************************
  477. * Components : Grid
  478. * Components ID : switch1.case1.grd_uselpcmspcm
  479. * Event : onrbuttondown
  480. * Argument : 01.obj : Object Event has occurred
  481. * : 02.e : Event Object
  482. * Description : 자주쓰는 병리검체 우클릭시
  483. ****************************************************************************************/
  484. function switch1_case1_grd_uselpcmspcm_onrbuttondown(obj:Grid, e:GridMouseEventInfo)
  485. {
  486. if(e.row > -1) {
  487. //ds_main_lpcmspcmlist.rowposition = e.row;
  488. //fMouseRghtBtnPopup();
  489. del_grd_uselpcmspcm.trackPopup(e.screenX,e.screenY);
  490. }
  491. }
  492. /****************************************************************************************
  493. * Components : Button
  494. * Components ID : switch1.case1.button2
  495. * Event : onclick
  496. * Argument : 01.obj : Object Event has occurred
  497. * : 02.e : Event Object
  498. * Description : 저장버튼 클릭
  499. ****************************************************************************************/
  500. function switch1_case1_button2_onclick(obj:Button, e:ClickEventInfo)
  501. {
  502. // var saveClincCmt = model.instances(0).selectNodes( "/root/main/lpcmspcm/lpcmspcmlist" );
  503. // model.setValue ( "/root/send/cond1", getNodeListCSV(saveClincCmt));
  504. dsf_createDs("ds_send_lpcmspcmlist");
  505. ds_send_lpcmspcmlist.copyData(ds_main_lpcmspcmlist);
  506. var oParam = {};
  507. oParam.id = "TXMMB02301";
  508. oParam.service = "prcpbaseapp.OrdPrcpMngt";
  509. oParam.method = "reqExeSaveUseLpcmspcm";
  510. oParam.inds = "lpcmspcmlist=ds_send_lpcmspcmlist";
  511. oParam.outds = "ds_main_lpcmspcmlist=lpcmspcmlist";
  512. oParam.async = false;
  513. oParam.callback = "";
  514. tranf_submit(oParam);
  515. if (!utlf_isNull(cmb_ordept.text)) {
  516. var calcscorcd = ds_prcpclscdlist.getColumn(ds_prcpclscdlist.rowposition,"calcscorcd");
  517. ds_send.setColumn(0,"cond1",ds_init.getColumn(0,"orddeptcd"));
  518. ds_send.setColumn(0,"cond2","1");
  519. ds_send.setColumn(0,"cond3",calcscorcd);
  520. var oParam = {};
  521. oParam.id = "TRMMB02302";
  522. oParam.service = "prcpbaseapp.OrdPrcpMngt";
  523. oParam.method = "reqGetUseLpcmspcm";
  524. oParam.inds = "req=ds_send";
  525. oParam.outds = "ds_main_lpcmspcmlist=lpcmspcmlist ds_main_totlpcmspcmlist=totlpcmspcmlist";
  526. oParam.async = false;
  527. oParam.callback = "";
  528. tranf_submit(oParam);
  529. }
  530. dsf_deleteDs("ds_send_lpcmspcmlist");
  531. fColorSetting();
  532. }
  533. /****************************************************************************************
  534. * Components : Combo
  535. * Components ID : cmb_ordept
  536. * Event : onitemchanged
  537. * Argument : 01.obj : Object Event has occurred
  538. * : 02.e : Event Object
  539. * Description :
  540. ****************************************************************************************/
  541. function cmb_ordept_onitemchanged(obj:Combo, e:ItemChangeEventInfo)
  542. {
  543. if (!utlf_isNull(cmb_ordept.text)) {
  544. ds_send.setColumn(0,"cond1",ds_init.getColumn(0,"orddeptcd"));
  545. ds_send.setColumn(0,"cond2","1");
  546. var oParam = {};
  547. oParam.id = "TRMMB02302";
  548. oParam.service = "prcpbaseapp.OrdPrcpMngt";
  549. oParam.method = "reqGetUseLpcmspcm";
  550. oParam.inds = "req=ds_send";
  551. oParam.outds = "ds_main_lpcmspcmlist=lpcmspcmlist ds_main_totlpcmspcmlist=totlpcmspcmlist";
  552. oParam.async = false;
  553. oParam.callback = "";
  554. tranf_submit(oParam);
  555. var oParam = {};
  556. oParam.id = "TRMMB02211";
  557. oParam.service = "prcpbaseapp.OrdPrcpMngt";
  558. oParam.method = "reqGetClincCmtList";
  559. oParam.inds = "req=ds_send";
  560. oParam.outds = "ds_clinccmtlist=clinccmtlist";
  561. oParam.async = false;
  562. oParam.callback = "";
  563. tranf_submit(oParam);
  564. fColorSetting();
  565. } else {
  566. ds_main_lpcmspcmlist.clear();
  567. ds_clinccmtlist.clear();
  568. }
  569. }
  570. /****************************************************************************************
  571. * Components : Button
  572. * Components ID : switch1.case2.button4
  573. * Event : onclick
  574. * Argument : 01.obj : Object Event has occurred
  575. * : 02.e : Event Object
  576. * Description : 추가버튼 클릭
  577. ****************************************************************************************/
  578. function switch1_case2_button4_onclick(obj:Button, e:ClickEventInfo)
  579. {
  580. ds_reset_clinccmtlist.setColumn(0,"cdkind","1");
  581. ds_reset_clinccmtlist.setColumn(0,"orddeptcd",ds_init.getColumn(0,"orddeptcd"));
  582. // appendChildPrcp ( "/root/reset/clinccmtlist", "/root/clinccmt", "main" );
  583. ds_clinccmtlist.copyRow(ds_clinccmtlist.addRow(),ds_reset_clinccmtlist,0);
  584. }
  585. /****************************************************************************************
  586. * Components : Button
  587. * Components ID : switch1.case2.button6
  588. * Event : onclick
  589. * Argument : 01.obj : Object Event has occurred
  590. * : 02.e : Event Object
  591. * Description : 저장버튼 클릭
  592. ****************************************************************************************/
  593. function switch1_case2_button6_onclick(obj:Button, e:ClickEventInfo)
  594. {
  595. // var saveClincCmt = model.instances(0).selectNodes( "/root/clinccmt/clinccmtlist" );
  596. // model.setValue ( "/root/send/cond1", getNodeListCSV(saveClincCmt));
  597. dsf_createDs("ds_send_clinccmtlist");
  598. ds_send_clinccmtlist.copyData(ds_clinccmtlist);
  599. var oParam = {};
  600. oParam.id = "TXMMB02211";
  601. oParam.service = "prcpbaseapp.OrdPrcpMngt";
  602. oParam.method = "reqExeSaveClincCmt";
  603. oParam.inds = "clinccmtlist=ds_send_clinccmtlist";
  604. oParam.outds = "ds_clinccmtlist=clinccmtlist";
  605. oParam.async = false;
  606. oParam.callback = "";
  607. tranf_submit(oParam);
  608. dsf_deleteDs("ds_send_clinccmtlist");
  609. }
  610. /****************************************************************************************
  611. * Components : Dataset
  612. * Components ID : ds_clinccmtlist
  613. * Event : oncolumnchanged
  614. * Argument : 01.obj : Object Event has occurred
  615. * : 02.e : Event Object
  616. * Description : 임상소견 내용 변경시
  617. ****************************************************************************************/
  618. function ds_clinccmtlist_oncolumnchanged(obj:Dataset, e:DSColChangeEventInfo)
  619. {
  620. var status = ds_clinccmtlist.getColumn(ds_clinccmtlist.rowposition,"status");
  621. if (status=="-" ) {
  622. ds_clinccmtlist.setColumn(ds_clinccmtlist.rowposition,"status","U");
  623. }
  624. }
  625. /****************************************************************************************
  626. * Components : Grid
  627. * Components ID : switch1.case2.grd_clinccmtlist
  628. * Event : onrbuttondown
  629. * Argument : 01.obj : Object Event has occurred
  630. * : 02.e : Event Object
  631. * Description : 자주쓰는 병리임상소견 우클릭시
  632. ****************************************************************************************/
  633. function switch1_case2_grd_clinccmtlist_onrbuttondown(obj:Grid, e:GridMouseEventInfo)
  634. {
  635. if(e.row > -1) {
  636. del_grd_clinccmtlist.trackPopup(e.screenX,e.screenY);
  637. }
  638. }
  639. //=======================================================================================
  640. // Function
  641. //---------------------------------------------------------------------------------------
  642. /****************************************************************************************
  643. * Function : cf_TRMMB02304
  644. * Description : TRMMB02304 콜백함수
  645. * Argument :
  646. * :
  647. * return type :
  648. * Creator :
  649. ****************************************************************************************/
  650. function cf_TRMMB02304(sSvcId, nErrorCode, sErrorMsg) {
  651. if(nErrorCode < 0) return;
  652. else {
  653. var calcscorcd = ds_prcpclscdlist.getColumn(0,"calcscorcd");
  654. if (!utlf_isNull(calcscorcd)) {
  655. ds_prcpclscdlist.rowposition = 0;
  656. ds_send.setColumn(0,"cond1",calcscorcd);
  657. var oParam = {};
  658. oParam.id = "TRMMB02301";
  659. oParam.service = "prcpbaseapp.OrdPrcpMngt";
  660. oParam.method = "reqGetLpcmspcm";
  661. oParam.inds = "req=ds_send";
  662. oParam.outds = "ds_lpcmspcmlist=lpcmspcmlist";
  663. oParam.async = false;
  664. oParam.callback = "";
  665. tranf_submit(oParam);
  666. }
  667. }
  668. }
  669. /****************************************************************************************
  670. * Function : fColorSetting
  671. * Description : 그리드 폰트 세팅
  672. * Argument :
  673. * :
  674. * return type :
  675. * Creator :
  676. ****************************************************************************************/
  677. function fColorSetting () {
  678. for(var i = 0; i <= ds_lpcmspcmlist.rowcount ; i++ ) {
  679. var spccd = ds_lpcmspcmlist.getColumn(i,"spccd");
  680. if(ds_main_totlpcmspcmlist.findRow("spccd",spccd) >= 0) {
  681. dsf_makeValue(ds_lpcmspcmlist,"chkbold","string","Y",i);
  682. }
  683. }
  684. var sExpr1 ="font:EXPR(getColumn(currow,'chkbold')=='Y'?&quot;Dotum,9,bold&quot;:&quot;Dotum,9&quot;)"
  685. +";align:&quot;left&quot;";
  686. switch1.case1.grd_lpcmspcm.setCellProperty("body", 1, "style", sExpr1);
  687. }
  688. /****************************************************************************************
  689. * Function : fDeleteRow
  690. * Description : 자주쓰는 병리검체 삭제
  691. * Argument :
  692. * :
  693. * return type :
  694. * Creator :
  695. ****************************************************************************************/
  696. function fDeleteRow () {
  697. var selectedRows = grdf_getSelectedRows(switch1.case1.grd_uselpcmspcm);
  698. for(var i= selectedRows.length-1; i > -1; i--){
  699. var status = ds_main_lpcmspcmlist.getColumn(selectedRows[i],"status");
  700. if (status=="-" || status=="U" ) {
  701. ds_main_lpcmspcmlist.setColumn(selectedRows[i],"status","D");
  702. } else if ( status =="I" ){
  703. ds_main_lpcmspcmlist.deleteRow(selectedRows[i]);
  704. } else if (status=="D" ) {
  705. ds_main_lpcmspcmlist.setColumn(selectedRows[i],"status","-");
  706. }
  707. }
  708. }
  709. /****************************************************************************************
  710. * Function : fSpcDeleteRow
  711. * Description : 자주쓰는 병리임상소견 삭제
  712. * Argument :
  713. * :
  714. * return type :
  715. * Creator :
  716. ****************************************************************************************/
  717. function fSpcDeleteRow () {
  718. var selectedRows = grdf_getSelectedRows(switch1.case2.grd_clinccmtlist);
  719. for (var i= selectedRows.length-1; i > -1; i--){
  720. var status = ds_clinccmtlist.getColumn(selectedRows[i],"status");
  721. if (status=="-" || status=="U" ) {
  722. ds_clinccmtlist.setColumn(selectedRows[i],"status","D");
  723. } else if ( status =="I" ){
  724. ds_clinccmtlist.deleteRow(selectedRows[i]);
  725. } else if (status=="D" ) {
  726. ds_clinccmtlist.setColumn(selectedRows[i],"status","-");
  727. }
  728. }
  729. }
  730. ]]></Script>
  731. </Form>
  732. </FDL>