SPLBT90400_외래수혈처방조회.xfdl 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <FDL version="1.5">
  3. <TypeDefinition url="..\..\..\default_typedef.xml"/>
  4. <Form id="SPLBT90400" position="absolute 0 0 998 743" titletext="외래수혈처방조회" scrollbars="none" onload="SPLBT90400_onload" ontimer="SPLBT90400_ontimer" onclose="SPLBT90400_onclose">
  5. <Layouts>
  6. <Layout>
  7. <Div id="grp_tle" position="absolute 1036 -19 2016 -6" anchor="default" positiontype="position">
  8. <Layouts>
  9. <Layout/>
  10. </Layouts>
  11. </Div>
  12. <Div id="grp_sea" taborder="2" style="align:center top;" position="absolute 0 25 996 67" anchor="left top right" class="div_SA">
  13. <Layouts>
  14. <Layout>
  15. <Shape id="line13" linetype="vertical" class="line_4" position="absolute 893 7 893 29" anchor="default"/>
  16. <Static id="caption2" text="예약일시" class="search_name" position="absolute 8 10 82 30" anchor="default"/>
  17. <Button id="btn_ref" taborder="1" text="조회" class="btn1" position="absolute 928 10 984 30" anchor="top right" onclick="grp_sea_btn_ref_onclick"/>
  18. <Static id="caption1" text="등록번호" class="search_name" position="absolute 322 10 396 30" anchor="default"/>
  19. <Edit id="ipt_pid" taborder="4" position="absolute 396 10 496 30" anchor="default" onkeydown="grp_sea_ipt_pid_onkeydown" maxlength="9" inputtype="digit"/>
  20. <Edit id="ipt_autom" taborder="5" class="input_search" position="absolute 618 10 642 30" anchor="default" value="1" maxlength="2" inputtype="digit"/>
  21. <Static id="caption8" text="분" class="search_no_b" position="absolute 645 10 660 30" anchor="default"/>
  22. <Button id="btn_autoNF" taborder="6" text="자동조회 On" class="btn5" position="absolute 523 10 615 30" anchor="default" onclick="grp_sea_btn_autoNF_onclick"/>
  23. <cp_periodCal id="cp_periodCal" titletext="Period Calendar" taborder="7" text="cp_periodCal00" scrollbars="none" position="absolute 82 10 298 30" style="background:transparent; " class="input_essential" anchor="default"/>
  24. </Layout>
  25. </Layouts>
  26. </Div>
  27. <Static id="caption32" text="외래환자 수혈처방 조회" class="tit_2" position="absolute 0 79 167 99"/>
  28. <Grid id="grd_dnorinfo" class="datagrid3" taborder="3" useinputpanel="false" position="absolute 0 99 996 739" style="align:center middle;" anchor="default" autofittype="col" binddataset="ds_grid_outprcplist" cellsizingtype="col" oncellclick="grd_dnorinfo_oncellclick">
  29. <Formats>
  30. <Format id="default">
  31. <Columns>
  32. <Column size="21"/>
  33. <Column size="55"/>
  34. <Column size="79"/>
  35. <Column size="77"/>
  36. <Column size="40"/>
  37. <Column size="66"/>
  38. <Column size="68"/>
  39. <Column size="55"/>
  40. <Column size="90"/>
  41. <Column size="34"/>
  42. <Column size="57"/>
  43. <Column size="54"/>
  44. <Column size="54"/>
  45. <Column size="30"/>
  46. <Column size="30"/>
  47. <Column size="131"/>
  48. <Column size="166"/>
  49. </Columns>
  50. <Rows>
  51. <Row size="45" band="head"/>
  52. <Row size="24"/>
  53. </Rows>
  54. <Band id="head">
  55. <Cell/>
  56. <Cell col="1" text="상태"/>
  57. <Cell col="2" text="처방일자"/>
  58. <Cell col="3" colspan="2" text="예약일시"/>
  59. <Cell col="5" text="등록번호"/>
  60. <Cell col="6" text="환자명"/>
  61. <Cell col="7" text="진료과"/>
  62. <Cell col="8" text="처방명"/>
  63. <Cell col="9" text="수량"/>
  64. <Cell col="10" text="Btype"/>
  65. <Cell col="11" text="최근수혈&#10;혈액형"/>
  66. <Cell col="12" text="보관&#10;검체"/>
  67. <Cell col="13" text="혈액&#10;은행&#10;확인"/>
  68. <Cell col="14" text="외래&#10;확인"/>
  69. <Cell col="15" text="확인일시"/>
  70. <Cell col="16" text="보관검체정보"/>
  71. </Band>
  72. <Band id="body">
  73. <Cell celltype="head" expr="expr:currow+1"/>
  74. <Cell col="1" style="align:center middle;" text="bind:prcpstat"/>
  75. <Cell col="2" style="align:center middle;" text="bind:prcpdd" mask="####-##-##"/>
  76. <Cell col="3" style="align:center middle;" text="bind:prcphopedd" mask="####-##-##"/>
  77. <Cell col="4" text="bind:prcphopetm" mask="##:##"/>
  78. <Cell col="5" text="bind:pid"/>
  79. <Cell col="6" text="bind:hngnm"/>
  80. <Cell col="7" text="bind:deptnm"/>
  81. <Cell col="8" style="align:left middle;" text="bind:blodcomabbrnm"/>
  82. <Cell col="9" text="bind:reqqty"/>
  83. <Cell col="10" text="bind:btype"/>
  84. <Cell col="11" text="bind:bfaborh"/>
  85. <Cell col="12" text="bind:keepno"/>
  86. <Cell col="13" text="bind:bankcnfmyn"/>
  87. <Cell col="14" displaytype="checkbox" edittype="expr:(stat2 == '000') || (stat2 == '0') || (stat2 == &quot;230&quot;) ? 'none' : 'checkbox'" style="controlbackground:EXPR((stat2 == '000') || (stat2 == '0') || (stat2 == &quot;230&quot;) ? 'gray' : 'none');" text="bind:outcnfmyn"/>
  88. <Cell col="15" displaytype="date" edittype="date" text="bind:rsrvcnfmdt" expr="expr:outcnfmyn =='Y' ? rsrvcnfmdt : ''" mask="yyyy-MM-dd hh:mm" calendardisplaynulltype="nulltext"/>
  89. <Cell col="16" text="bind:bcnoinfo"/>
  90. </Band>
  91. </Format>
  92. </Formats>
  93. </Grid>
  94. <Static id="caption6" text="외래환자 수혈처방 조회" class="tit_1" position="absolute 0 0 179 25"/>
  95. </Layout>
  96. </Layouts>
  97. <Objects>
  98. <Dataset id="ds_init_lb0000" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" reversesubsum="false">
  99. <ColumnInfo>
  100. <Column id="cd" type="STRING"/>
  101. <Column id="nm" type="STRING"/>
  102. </ColumnInfo>
  103. </Dataset>
  104. <Dataset id="ds_grid_outprcplist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false" oncolumnchanged="ds_grid_outprcplist_oncolumnchanged">
  105. <ColumnInfo>
  106. <Column id="prcpstat" type="STRING" size="256"/>
  107. <Column id="prcpdd" type="STRING" size="256"/>
  108. <Column id="prcphopedd" type="STRING" size="256"/>
  109. <Column id="prcphopetm" type="STRING" size="256"/>
  110. <Column id="pid" type="STRING" size="256"/>
  111. <Column id="hngnm" type="STRING" size="256"/>
  112. <Column id="deptnm" type="STRING" size="256"/>
  113. <Column id="blodcomabbrnm" type="STRING" size="256"/>
  114. <Column id="reqqty" type="STRING" size="256"/>
  115. <Column id="keepno" type="STRING" size="256"/>
  116. <Column id="voltrans" type="STRING" size="256"/>
  117. <Column id="tnsreqacptno" type="STRING" size="256"/>
  118. <Column id="prcpcd" type="STRING" size="256"/>
  119. <Column id="stat2" type="STRING" size="256"/>
  120. <Column id="bankcnfmyn" type="STRING" size="256"/>
  121. <Column id="outcnfmyn" type="STRING" size="256"/>
  122. <Column id="rsrvcnfmdt" type="STRING" size="256"/>
  123. <Column id="btype" type="STRING" size="256"/>
  124. <Column id="bfaborh" type="STRING" size="256"/>
  125. <Column id="bcnoinfo" type="STRING" size="256"/>
  126. </ColumnInfo>
  127. </Dataset>
  128. </Objects>
  129. <Script type="xscript4.0"><![CDATA[/***************************************************************************************
  130. * System Name :
  131. * Job Name :
  132. * Creator :
  133. * Make Date : 2015-05-01
  134. * Description :
  135. *---------------------------------------------------------------------------------------
  136. * Modify Date Modifier Modify Description
  137. *---------------------------------------------------------------------------------------
  138. * 2015-05-01 Live Converter TF->XP
  139. *
  140. *---------------------------------------------------------------------------------------
  141. ****************************************************************************************/
  142. include "com_commonxp::comm_main.xjs";
  143. include "lis_commonxp::LLZ001.xjs";
  144. function SPLBT90400_onload(obj:Form, e:LoadEventInfo)
  145. {
  146. frmf_initForm(obj);
  147. lf_SetInit();
  148. }
  149. //초기화
  150. function lf_SetInit(){
  151. grp_sea.ipt_pid.setFocus();
  152. lf_getDbDeptcd("0000|","cbf_TRLZZ00101");
  153. lf_Timer();
  154. var aData = new Array();
  155. aData[0] = utlf_getCurrentDate().toDate("YYYYMMDD").getAddDate(-1, "D").getDateFormat("YYYYMMDD");
  156. aData[1] = utlf_getCurrentDate();
  157. grp_sea.cp_periodCal.setData(aData);
  158. grp_sea.ipt_pid.value = "";
  159. lf_GetOutPrcpList();
  160. }
  161. var iCnt = 1;
  162. function lf_Timer(){
  163. iCnt++;
  164. if(iCnt%2 == 0){
  165. var m = grp_sea.ipt_autom.value;
  166. this.setTimer(0, Number(m)*60000);
  167. grp_sea.btn_autoNF.text = "자동접수 Off";
  168. grp_sea.ipt_autom.enable = true;
  169. }else{
  170. grp_sea.btn_autoNF.text = "자동접수 On";
  171. grp_sea.ipt_autom.enable = false;
  172. this.killTimer(0);
  173. }
  174. }
  175. //조회
  176. function lf_GetOutPrcpList(){
  177. var aData = new Array();
  178. aData = grp_sea.cp_periodCal.getData();
  179. var sInDsName = dsf_createDsRow("ds_temp_search"
  180. , [{col: "fromdd" , val: aData[0]}
  181. , {col: "todd" , val: aData[1]}
  182. , {col: "pid" , val: grp_sea.ipt_pid.value}]);
  183. var oParam = {};
  184. oParam.id = "TRLBT90401";
  185. oParam.service = "transfusionmngtapp.PseuDeliveryRgst";
  186. oParam.method = "reqGetOutBlodPrcpList";
  187. oParam.inds = "cond="+sInDsName;
  188. oParam.outds = "ds_grid_outprcplist=getOutBlodPrcpList";
  189. oParam.async = false;
  190. oParam.callback = "cbf_TRLBT90401";
  191. tranf_submit(oParam);
  192. }
  193. function lf_KeyEvent(objName, keyCode){
  194. if(keyCode == "13"){
  195. if(objName == "ipt_pid"){
  196. frmf_setInputNodeCurPid(grp_sea.ipt_pid);
  197. grp_sea.ipt_pid.value = String(grp_sea.ipt_pid.value).getTrim();
  198. lf_GetOutPrcpList();
  199. }
  200. }
  201. }
  202. //혈액은행 확인, 외래확인 체크
  203. function lf_SetRsrvCNFM(){
  204. var oParam = {};
  205. oParam.id = "TXLBT90401";
  206. oParam.service = "transfusionmngtapp.PseuDeliveryRgst";
  207. oParam.method = "reqExeOutRsrvCnfm";
  208. oParam.inds = "data=ds_grid_outprcplist:U";
  209. oParam.async = false;
  210. oParam.callback = "cbf_TXLBT90401";
  211. tranf_submit(oParam);
  212. }
  213. //콜백_LIS공통코드조회
  214. function cbf_TRLZZ00101(strSvcID, nErrorCode, strErrorMag){
  215. if(nErrorCode != 0){
  216. sysf_messageBox("ID: " + strSvcID + " Error: " + strErrorMag, "E009", "");
  217. }else{
  218. }
  219. }
  220. //콜백_조회
  221. function cbf_TRLBT90401(strSvcID, nErrorCode, strErrorMag){
  222. if(nErrorCode != 0){
  223. sysf_messageBox("ID: " + strSvcID + " Error: " + strErrorMag, "E009", "");
  224. }else{
  225. createColumn(ds_grid_outprcplist, "edittype");
  226. ds_grid_outprcplist.updatecontrol = false;
  227. for(var i=0; i<ds_grid_outprcplist.rowcount; i++){
  228. if(ds_grid_outprcplist.getColumn(i, "stat2") == "000" ||
  229. ds_grid_outprcplist.getColumn(i, "stat2") == "0" ||
  230. ds_grid_outprcplist.getColumn(i, "stat2") == "230"){
  231. ds_grid_outprcplist.setColumn(i, "edittype", "none");
  232. }else{
  233. ds_grid_outprcplist.setColumn(i, "edittype", "checkbox");
  234. }
  235. if(ds_grid_outprcplist.getColumn(i, "outcnfmyn") == "N"){
  236. ds_grid_outprcplist.setColumn(i, "outcnfmyn", 0);
  237. }
  238. ds_grid_outprcplist.setRowType(i, Dataset.ROWTYPE_NORMAL);
  239. }
  240. ds_grid_outprcplist.updatecontrol = true;
  241. }
  242. }
  243. function cbf_TXLBT90401(strSvcID, nErrorCode, strErrorMag){
  244. if(nErrorCode != 0){
  245. sysf_messageBox("ID: " + strSvcID + " Error: " + strErrorMag, "E009", "");
  246. }else{
  247. lf_GetOutPrcpList();
  248. }
  249. }
  250. function createColumn(objDs, strColID){
  251. var isExist = false;
  252. if(!isExistCol(objDs, strColID)){
  253. objDs.addColumn(strColID,"string");
  254. }
  255. }
  256. function isExistCol(objDs, strColID){
  257. var isExist = false;
  258. var colID = "";
  259. for(var i=0; i<objDs.getColCount(); i++){
  260. colID = objDs.getColID(i);
  261. if(colID == strColID){
  262. isExist = true;
  263. }
  264. }
  265. return isExist;
  266. }
  267. function SPLBT90400_ontimer(obj:Form, e:TimerEventInfo)
  268. {
  269. lf_GetOutPrcpList();
  270. }
  271. function SPLBT90400_onclose(obj:Form, e:CloseEventInfo)
  272. {
  273. this.killTimer(0);
  274. }
  275. function grp_sea_ipt_pid_onkeydown(obj:Edit, e:KeyEventInfo)
  276. {
  277. lf_KeyEvent(obj.name, e.keycode);
  278. }
  279. function grp_sea_btn_ref_onclick(obj:Button, e:ClickEventInfo)
  280. {
  281. lf_GetOutPrcpList();
  282. }
  283. function grp_sea_btn_autoNF_onclick(obj:Button, e:ClickEventInfo)
  284. {
  285. lf_Timer();
  286. }
  287. function btn_exit_onclick(obj:Button, e:ClickEventInfo)
  288. {
  289. this.close();
  290. }
  291. function grd_dnorinfo_oncellclick(obj:Grid, e:GridClickEventInfo)
  292. {
  293. if(e.col == "14") { //outcnfmyn")
  294. var nVal = obj.getCellValue(e.row,14);
  295. var nYn = "";
  296. if (nVal == "1") {
  297. nYn = "Y";
  298. }else {
  299. nYn = "N";
  300. }
  301. obj.updatecontrol = false;
  302. ds_grid_outprcplist.setColumn(e.row, "outcnfmyn", nYn);
  303. ds_grid_outprcplist.setRowType(e.row,"4");
  304. obj.updatecontrol = true;
  305. lf_SetRsrvCNFM();
  306. }
  307. }
  308. // function ds_grid_outprcplist_oncolumnchanged(obj:Dataset, e:DSColChangeEventInfo)
  309. // {
  310. // if(obj.getColID(e.col) == "outcnfmyn"){
  311. // obj.updatecontrol = false;
  312. // if(obj.getColumn(e.row, obj.getColID(e.col)) == 1){
  313. // obj.setRowType(e.row, Dataset.ROWTYPE_INSERT);
  314. // obj.setColumn(e.row, "outcnfmyn", "Y");
  315. // }
  316. // obj.updatecontrol = true;
  317. //
  318. // lf_SetRsrvCNFM();
  319. // }
  320. // }]]></Script>
  321. </Form>
  322. </FDL>