SMLBP00100_혈액재고조회.xfdl 26 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <FDL version="1.5">
  3. <TypeDefinition url="..\..\..\default_typedef.xml"/>
  4. <Form id="SMLBP00100" position="absolute 0 0 1259 805" titletext="혈액재고조회" onload="SMLBP00100_onload">
  5. <Layouts>
  6. <Layout>
  7. <Static id="caption6" text="혈액재고조회" class="tit_1" position="absolute 0 0 114 25"/>
  8. <Button id="btn_excel" taborder="6" text="엑셀" onlbuttonup="btn_excel_onlbuttonup" class="btn7" position="absolute 1201 101 1253 121" anchor="top right"/>
  9. <Button id="button2" taborder="7" text="인수인계용엑셀" onlbuttonup="button2_onlbuttonup" class="btn7" position="absolute 1084 101 1197 121" anchor="top right"/>
  10. <Static id="caption1" text="현재고" class="tit_2" position="absolute 0 78 65 94" style="align:left middle;"/>
  11. <Grid id="grd_bloodstocklist" taborder="15" useinputpanel="false" position="absolute 0 124 1255 554" style="align:center middle;" onclick="datagrid1_onclick" anchor="left top right" binddataset="ds_grid_grd_bloodstocklist" selecttype="cell" oncellclick="grd_bloodstocklist_oncellclick" autofittype="col" cellsizingtype="col">
  12. <Formats>
  13. <Format id="default">
  14. <Columns>
  15. <Column size="30"/>
  16. <Column size="150"/>
  17. <Column size="90"/>
  18. <Column size="90"/>
  19. <Column size="90"/>
  20. <Column size="90"/>
  21. <Column size="90"/>
  22. <Column size="90"/>
  23. <Column size="90"/>
  24. <Column size="90"/>
  25. <Column size="100"/>
  26. <Column size="0"/>
  27. <Column size="0"/>
  28. <Column size="0"/>
  29. <Column size="0"/>
  30. <Column size="0"/>
  31. <Column size="0"/>
  32. <Column size="0"/>
  33. <Column size="0"/>
  34. <Column size="0"/>
  35. <Column size="122"/>
  36. </Columns>
  37. <Rows>
  38. <Row size="30" band="head"/>
  39. <Row size="23"/>
  40. </Rows>
  41. <Band id="head">
  42. <Cell style="font:dotum,9,bold;"/>
  43. <Cell col="1" style="font:dotum,9,bold;" text="혈액명"/>
  44. <Cell col="2" style="font:dotum,9,bold;" text="A+"/>
  45. <Cell col="3" style="font:dotum,9,bold;" text="B+"/>
  46. <Cell col="4" style="font:dotum,9,bold;" text="O+"/>
  47. <Cell col="5" style="font:dotum,9,bold;" text="AB+"/>
  48. <Cell col="6" style="font:dotum,9,bold;" text="A-"/>
  49. <Cell col="7" style="font:dotum,9,bold;" text="B-"/>
  50. <Cell col="8" style="font:dotum,9,bold;" text="O-"/>
  51. <Cell col="9" style="font:dotum,9,bold;" text="AB-"/>
  52. <Cell col="10" style="font:dotum,9,bold;" text="현재고량"/>
  53. <Cell col="11" style="font:dotum,9,bold;" text="barcd"/>
  54. <Cell col="12" style="font:dotum,9,bold;" text="A+"/>
  55. <Cell col="13" style="font:dotum,9,bold;" text="B+"/>
  56. <Cell col="14" style="font:dotum,9,bold;" text="O+"/>
  57. <Cell col="15" style="font:dotum,9,bold;" text="AB+"/>
  58. <Cell col="16" style="font:dotum,9,bold;" text="A-"/>
  59. <Cell col="17" style="font:dotum,9,bold;" text="B-"/>
  60. <Cell col="18" style="font:dotum,9,bold;" text="O-"/>
  61. <Cell col="19" style="font:dotum,9,bold;" text="AB-"/>
  62. <Cell col="20" style="font:dotum,9,bold;" text="현재고량&#10;(가출고,준비중포함)"/>
  63. </Band>
  64. <Band id="body">
  65. <Cell celltype="head" style="font:dotum,9,bold;" expr="expr:currow+1"/>
  66. <Cell col="1" displaytype="text" style="align:left middle;font:dotum,9,bold;" text="bind:blodcomnm" wordwrap="char"/>
  67. <Cell col="2" displaytype="number" style="background:EXPR(toNumber(apyn)&gt;0?'#f7a08b':'transparent');background2:EXPR(toNumber(apyn)&gt;0?'#f7a08b':'transparent');font:dotum,9,bold;" text="bind:ap"/>
  68. <Cell col="3" displaytype="number" style="background:EXPR(toNumber(bpyn)&gt;0?'#f7a08b':'transparent');background2:EXPR(toNumber(bpyn)&gt;0?'#f7a08b':'transparent');font:dotum,9,bold;" text="bind:bp"/>
  69. <Cell col="4" displaytype="number" style="background:EXPR(toNumber(opyn)&gt;0?'#f7a08b':'transparent');background2:EXPR(toNumber(opyn)&gt;0?'#f7a08b':'transparent');font:dotum,9,bold;" text="bind:op"/>
  70. <Cell col="5" displaytype="number" style="background:EXPR(toNumber(abpyn)&gt;0?'#f7a08b':'transparent');background2:EXPR(toNumber(abpyn)&gt;0?'#f7a08b':'transparent');font:dotum,9,bold;" text="bind:abp"/>
  71. <Cell col="6" displaytype="number" style="background:EXPR(toNumber(amyn)&gt;0?'#f7a08b':'transparent');background2:EXPR(toNumber(amyn)&gt;0?'#f7a08b':'transparent');font:dotum,9,bold;" text="bind:am"/>
  72. <Cell col="7" displaytype="number" style="background:EXPR(toNumber(bmyn)&gt;0?'#f7a08b':'transparent');background2:EXPR(toNumber(bmyn)&gt;0?'#f7a08b':'transparent');font:dotum,9,bold;" text="bind:bm"/>
  73. <Cell col="8" displaytype="number" style="background:EXPR(toNumber(omyn)&gt;0?'#f7a08b':'transparent');background2:EXPR(toNumber(omyn)&gt;0?'#f7a08b':'transparent');font:dotum,9,bold;" text="bind:om"/>
  74. <Cell col="9" displaytype="number" style="background:EXPR(toNumber(abmyn)&gt;0?'#f7a08b':'transparent');background2:EXPR(toNumber(abmyn)&gt;0?'#f7a08b':'transparent');font:dotum,9,bold;" text="bind:abm"/>
  75. <Cell col="10" displaytype="number" style="font:dotum,9,bold;" text="bind:hap"/>
  76. <Cell col="11" style="font:dotum,9,bold;"/>
  77. <Cell col="12" style="font:dotum,9,bold;"/>
  78. <Cell col="13" style="font:dotum,9,bold;"/>
  79. <Cell col="14" style="font:dotum,9,bold;"/>
  80. <Cell col="15" style="font:dotum,9,bold;"/>
  81. <Cell col="16" style="font:dotum,9,bold;"/>
  82. <Cell col="17" style="font:dotum,9,bold;"/>
  83. <Cell col="18" style="font:dotum,9,bold;"/>
  84. <Cell col="19" style="font:dotum,9,bold;"/>
  85. <Cell col="20" style="align:right middle;font:dotum,9,bold;" text="bind:totalcnt"/>
  86. </Band>
  87. </Format>
  88. </Formats>
  89. </Grid>
  90. <Static id="caption4" text="현재고 상세내역" class="tit_2" position="absolute 0 562 121 581"/>
  91. <Grid id="grd_blooddetaillist" taborder="17" useinputpanel="false" position="absolute 0 582 1255 803" anchor="left top right" binddataset="ds_grid_grd_blooddetaillist" autofittype="col">
  92. <Formats>
  93. <Format id="default">
  94. <Columns>
  95. <Column size="30"/>
  96. <Column size="136"/>
  97. <Column size="190"/>
  98. <Column size="100"/>
  99. <Column size="120"/>
  100. <Column size="120"/>
  101. <Column size="120"/>
  102. <Column size="120"/>
  103. <Column size="100"/>
  104. <Column size="0"/>
  105. </Columns>
  106. <Rows>
  107. <Row size="22" band="head"/>
  108. <Row size="22"/>
  109. </Rows>
  110. <Band id="head">
  111. <Cell style="font:dotum,9,bold;" text="No."/>
  112. <Cell col="1" style="font:dotum,9,bold;" text="혈액번호"/>
  113. <Cell col="2" style="font:dotum,9,bold;" text="성분"/>
  114. <Cell col="3" style="font:dotum,9,bold;" text="혈액형/RH"/>
  115. <Cell col="4" style="font:dotum,9,bold;" text="헌혈일시"/>
  116. <Cell col="5" style="font:dotum,9,bold;" text="유효일시"/>
  117. <Cell col="6" style="font:dotum,9,bold;" text="입고일시"/>
  118. <Cell col="7" style="font:dotum,9,bold;" text="입고자"/>
  119. <Cell col="8" style="font:dotum,9,bold;" text="Donor"/>
  120. <Cell col="9" text="vdtyn"/>
  121. </Band>
  122. <Band id="body">
  123. <Cell celltype="head" style="font:dotum,9,bold;" expr="expr:currow+1"/>
  124. <Cell col="1" displaytype="text" edittype="text" style="align:center middle;background:EXPR(vdtyn=='Y'?'#f7a08b':'transparent');background2:EXPR(vdtyn=='Y'?'#f7a08b':'transparent');font:dotum,9,bold;" text="bind:blodno"/>
  125. <Cell col="2" style="background:EXPR(vdtyn=='Y'?'#f7a08b':'transparent');background2:EXPR(vdtyn=='Y'?'#f7a08b':'transparent');font:dotum,9,bold;" text="bind:blodcomnm"/>
  126. <Cell col="3" style="align:center middle;background:EXPR(vdtyn=='Y'?'#f7a08b':'transparent');background2:EXPR(vdtyn=='Y'?'#f7a08b':'transparent');font:dotum,9,bold;" text="bind:aborh"/>
  127. <Cell col="4" style="align:center middle;background:EXPR(vdtyn=='Y'?'#f7a08b':'transparent');background2:EXPR(vdtyn=='Y'?'#f7a08b':'transparent');font:dotum,9,bold;" text="bind:dondt" mask="expr:dondt==null?'':'####-##-## ##:##'"/>
  128. <Cell col="5" style="align:center middle;background:EXPR(vdtyn=='Y'?'#f7a08b':'transparent');background2:EXPR(vdtyn=='Y'?'#f7a08b':'transparent');font:dotum,9,bold;" text="bind:validt" mask="expr:validt==null?'':'####-##-## ##:##'"/>
  129. <Cell col="6" style="align:center middle;background:EXPR(vdtyn=='Y'?'#f7a08b':'transparent');background2:EXPR(vdtyn=='Y'?'#f7a08b':'transparent');font:dotum,9,bold;" text="bind:windt" mask="expr:windt==null?'':'####-##-## ##:##'"/>
  130. <Cell col="7" style="align:center middle;background:EXPR(vdtyn=='Y'?'#f7a08b':'transparent');background2:EXPR(vdtyn=='Y'?'#f7a08b':'transparent');font:dotum,9,bold;" text="bind:winnm"/>
  131. <Cell col="8" style="align:center middle;background:EXPR(vdtyn=='Y'?'#f7a08b':'transparent');background2:EXPR(vdtyn=='Y'?'#f7a08b':'transparent');font:dotum,9,bold;" text="bind:dnornm"/>
  132. <Cell col="9"/>
  133. </Band>
  134. </Format>
  135. </Formats>
  136. </Grid>
  137. <Button id="btn_detlexcel" taborder="18" text="엑셀" onlbuttonup="btn_detlexcel_onlbuttonup" class="btn7" position="absolute 1197 559 1252 579" anchor="top right"/>
  138. <Div id="Div00" anchor="left top right" taborder="19" text="Div00" position="absolute 0 25 1256 67" class="div_SA">
  139. <Layouts>
  140. <Layout>
  141. <Button id="btn_search" taborder="6" text="조회" class="btn1" position="absolute 1188 10 1244 30" anchor="top right" onclick="Div00_btn_search_onclick"/>
  142. <Static id="caption2" text="입고일시" onclick="Div00_caption2_onclick" class="search_name" position="absolute 8 10 82 30"/>
  143. <Calendar id="ipt_startdd" taborder="7" dateformat="yyyy-MM-dd" class="input_s_essential" position="absolute 82 10 182 30"/>
  144. <Static id="caption11" text="~" position="absolute 185 11 197 28"/>
  145. <Calendar id="ipt_enddd" taborder="8" dateformat="yyyy-MM-dd" class="input_s_essential" position="absolute 198 10 298 30"/>
  146. </Layout>
  147. </Layouts>
  148. </Div>
  149. <Static id="caption5" text="혈액보관온도" class="cell_1" position="absolute 1 97 96 121" anchor="default"/>
  150. <Edit id="input2" taborder="20" class="input_default" position="absolute 99 99 231 119" anchor="default"/>
  151. <Static id="caption7" text="인계자" class="cell_1" position="absolute 234 97 299 121" anchor="default"/>
  152. <Edit id="input3" taborder="21" class="input_default" position="absolute 302 99 382 119" anchor="default"/>
  153. <Edit id="input5" taborder="22" class="input_default" position="absolute 385 99 465 119" anchor="default"/>
  154. <Edit id="input6" taborder="23" class="input_default" position="absolute 468 99 548 119" anchor="default"/>
  155. <Static id="caption8" text="인수자" class="cell_1" position="absolute 551 97 616 121" anchor="default"/>
  156. <Edit id="input4" taborder="24" class="input_default" position="absolute 619 99 699 119" anchor="default"/>
  157. <Edit id="input7" taborder="25" class="input_default" position="absolute 702 99 782 119" anchor="default"/>
  158. <Edit id="input8" taborder="26" class="input_default" position="absolute 785 99 865 119" anchor="default"/>
  159. <Grid id="grd_bloodacpttran" taborder="27" useinputpanel="false" position="absolute 396 407 824 528" anchor="left top right" style="align:center middle;" onclick="datagrid1_onclick" binddataset="ds_grid_grd_bloodacpttran" visible="false">
  160. <Formats>
  161. <Format id="default">
  162. <Columns>
  163. <Column size="30"/>
  164. <Column size="150"/>
  165. <Column size="90"/>
  166. <Column size="90"/>
  167. <Column size="90"/>
  168. <Column size="90"/>
  169. <Column size="90"/>
  170. <Column size="90"/>
  171. <Column size="90"/>
  172. <Column size="90"/>
  173. <Column size="100"/>
  174. <Column size="0"/>
  175. <Column size="0"/>
  176. <Column size="0"/>
  177. <Column size="0"/>
  178. <Column size="0"/>
  179. <Column size="0"/>
  180. <Column size="0"/>
  181. <Column size="0"/>
  182. <Column size="0"/>
  183. </Columns>
  184. <Rows>
  185. <Row size="22" band="head"/>
  186. <Row size="22"/>
  187. </Rows>
  188. <Band id="head">
  189. <Cell text="No."/>
  190. <Cell col="1" text="혈액명"/>
  191. <Cell col="2" text="A+"/>
  192. <Cell col="3" text="B+"/>
  193. <Cell col="4" text="O+"/>
  194. <Cell col="5" text="AB+"/>
  195. <Cell col="6" text="A-"/>
  196. <Cell col="7" text="B-"/>
  197. <Cell col="8" text="O-"/>
  198. <Cell col="9" text="AB-"/>
  199. <Cell col="10" text="현재고량"/>
  200. <Cell col="11" text="barcd"/>
  201. <Cell col="12" text="A+"/>
  202. <Cell col="13" text="B+"/>
  203. <Cell col="14" text="O+"/>
  204. <Cell col="15" text="AB+"/>
  205. <Cell col="16" text="A-"/>
  206. <Cell col="17" text="B-"/>
  207. <Cell col="18" text="O-"/>
  208. <Cell col="19" text="AB-"/>
  209. </Band>
  210. <Band id="body">
  211. <Cell expr="expr:currow+1"/>
  212. <Cell col="1" text="bind:blodcomnm"/>
  213. <Cell col="2" text="bind:ap"/>
  214. <Cell col="3" text="bind:bp"/>
  215. <Cell col="4" text="bind:op"/>
  216. <Cell col="5" text="bind:abp"/>
  217. <Cell col="6" text="bind:am"/>
  218. <Cell col="7" text="bind:bm"/>
  219. <Cell col="8" text="bind:om"/>
  220. <Cell col="9" text="bind:abm"/>
  221. <Cell col="10" text="bind:hap"/>
  222. <Cell col="11"/>
  223. <Cell col="12"/>
  224. <Cell col="13"/>
  225. <Cell col="14"/>
  226. <Cell col="15"/>
  227. <Cell col="16"/>
  228. <Cell col="17"/>
  229. <Cell col="18"/>
  230. <Cell col="19"/>
  231. <Cell col="20"/>
  232. <Cell col="21"/>
  233. </Band>
  234. </Format>
  235. </Formats>
  236. </Grid>
  237. <Button id="btn_print" taborder="28" text="출력" class="btn4" position="absolute 1127 1 1183 21" anchor="top right" onclick="btn_print_onclick"/>
  238. <Button id="button5" taborder="29" text="초기화" onclick="button5_onclick" class="btn4" position="absolute 1186 1 1255 21" anchor="top right"/>
  239. </Layout>
  240. </Layouts>
  241. <Objects>
  242. <Dataset id="ds_grid_grd_bloodstocklist" firefirstcount="0" firenextcount="0" useclientlayout="true" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  243. <ColumnInfo>
  244. <column id="blodcomnm" type="STRING" size="256"/>
  245. <column id="ap" type="STRING" size="256"/>
  246. <column id="am" type="STRING" size="256"/>
  247. <column id="bp" type="STRING" size="256"/>
  248. <column id="bm" type="STRING" size="256"/>
  249. <column id="op" type="STRING" size="256"/>
  250. <column id="om" type="STRING" size="256"/>
  251. <column id="abp" type="STRING" size="256"/>
  252. <column id="abm" type="STRING" size="256"/>
  253. <column id="hap" type="STRING" size="256"/>
  254. <column id="blodbarcd" type="STRING" size="256"/>
  255. <column id="apyn" type="STRING" size="256"/>
  256. <column id="amyn" type="STRING" size="256"/>
  257. <column id="bpyn" type="STRING" size="256"/>
  258. <column id="bmyn" type="STRING" size="256"/>
  259. <column id="opyn" type="STRING" size="256"/>
  260. <column id="omyn" type="STRING" size="256"/>
  261. <column id="abpyn" type="STRING" size="256"/>
  262. <column id="abmyn" type="STRING" size="256"/>
  263. <Column id="totalcnt" type="STRING" size="256"/>
  264. </ColumnInfo>
  265. </Dataset>
  266. <Dataset id="ds_grid_grd_blooddetaillist" firefirstcount="0" firenextcount="0" useclientlayout="true" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  267. <ColumnInfo>
  268. <column id="blodno" type="STRING" size="256"/>
  269. <column id="blodcomnm" type="STRING" size="256"/>
  270. <column id="aborh" type="STRING" size="256"/>
  271. <column id="dondt" type="STRING" size="256"/>
  272. <column id="validt" type="STRING" size="256"/>
  273. <column id="windt" type="STRING" size="256"/>
  274. <column id="winnm" type="STRING" size="256"/>
  275. <column id="vdtyn" type="STRING" size="256"/>
  276. <column id="dnornm" type="STRING" size="256"/>
  277. </ColumnInfo>
  278. </Dataset>
  279. <Dataset id="ds_grid_grd_bloodacpttran" firefirstcount="0" firenextcount="0" useclientlayout="true" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  280. <ColumnInfo>
  281. <column id="blodcomnm" type="STRING" size="256"/>
  282. <column id="ap" type="STRING" size="256"/>
  283. <column id="am" type="STRING" size="256"/>
  284. <column id="bp" type="STRING" size="256"/>
  285. <column id="bm" type="STRING" size="256"/>
  286. <column id="op" type="STRING" size="256"/>
  287. <column id="om" type="STRING" size="256"/>
  288. <column id="abp" type="STRING" size="256"/>
  289. <column id="abm" type="STRING" size="256"/>
  290. <column id="hap" type="STRING" size="256"/>
  291. <column id="blodbarcd" type="STRING" size="256"/>
  292. <column id="apyn" type="STRING" size="256"/>
  293. <column id="amyn" type="STRING" size="256"/>
  294. <column id="bpyn" type="STRING" size="256"/>
  295. <column id="bmyn" type="STRING" size="256"/>
  296. <column id="opyn" type="STRING" size="256"/>
  297. <column id="omyn" type="STRING" size="256"/>
  298. <column id="abpyn" type="STRING" size="256"/>
  299. <column id="abmyn" type="STRING" size="256"/>
  300. </ColumnInfo>
  301. </Dataset>
  302. </Objects>
  303. <Script type="xscript4.0"><![CDATA[/***************************************************************************************
  304. * System Name :
  305. * Job Name :
  306. * Creator :
  307. * Make Date : 2015-05-01
  308. * Description :
  309. *---------------------------------------------------------------------------------------
  310. * Modify Date Modifier Modify Description
  311. *---------------------------------------------------------------------------------------
  312. * 2015-05-01 Live Converter TF->XP
  313. *
  314. *---------------------------------------------------------------------------------------
  315. ****************************************************************************************/
  316. include "com_commonxp::comm_main.xjs";
  317. include "lis_commonxp::LLZ001.xjs";
  318. function SMLBP00100_onload(obj:Form, e:LoadEventInfo)
  319. {
  320. //폼 초기화 함수
  321. frmf_initForm(obj);
  322. lf_setInit();
  323. }
  324. function lf_setInit()
  325. {
  326. var toDay = utlf_getCurrentDate().toDate().getAddDate(-6, "M").getDateFormat("YYYYMMDD");
  327. trace("toDay = " + toDay);
  328. Div00.ipt_startdd.value = toDay;
  329. Div00.ipt_enddd.value = utlf_getCurrentDate();
  330. ds_grid_grd_blooddetaillist.clearData();
  331. ds_grid_grd_bloodstocklist.clearData();
  332. grd_bloodstocklist.setFormatColProperty(grd_bloodstocklist.getBindCellIndex("Body","totalcnt"),"size",0);
  333. //그리드정렬
  334. grdf_setGridSort(grd_blooddetaillist);
  335. lf_bloodRef();
  336. }
  337. function lf_bloodRef() {
  338. var startdd = Div00.ipt_startdd.value;
  339. var enddd = Div00.ipt_enddd.value;
  340. var sInDsName = dsf_createDsRow("ds_temp_search"
  341. , [{col: "startdd", val:startdd }
  342. , {col: "enddd", val:enddd }
  343. ]);
  344. var oParam = {};
  345. oParam.id = "TRLBP00101";
  346. oParam.service = "refprintmngtapp.BloodBankRefPrintMngt";
  347. oParam.method = "reqGetBloodStockRef";
  348. oParam.inds = "cond="+sInDsName;
  349. oParam.outds = "ds_grid_grd_bloodstocklist=bloodstocklist";
  350. oParam.async = false;
  351. oParam.callback = "cbf_SMLBP00100";
  352. tranf_submit(oParam);
  353. }
  354. function lf_bloodDetail(row, col) {
  355. var blodbarcd = ds_grid_grd_bloodstocklist.getColumn(row, "blodbarcd");
  356. var aborh = grd_bloodstocklist.getCellProperty("Head", col, "text");
  357. var sInDsName = dsf_createDsRow("ds_temp_search"
  358. , [{col: "blodbarcd", val:blodbarcd }
  359. , {col: "aborh", val:aborh }
  360. ]);
  361. var oParam = {};
  362. oParam.id = "TRLBP00102";
  363. oParam.service = "refprintmngtapp.BloodBankRefPrintMngt";
  364. oParam.method = "reqGetBloodStockDetailRef";
  365. oParam.inds = "cond="+sInDsName;
  366. oParam.outds = "ds_grid_grd_blooddetaillist=blooddetaillist";
  367. oParam.async = false;
  368. oParam.callback = "cbf_SMLBP00100";
  369. tranf_submit(oParam);
  370. }
  371. // 출력
  372. function lf_exePrint() {
  373. var objDOM = rptf_createDOM(); // DOM 객체 설정
  374. rptf_makeNodeToDOM(objDOM, "/root/hidden/report");
  375. rptf_setValueToDOM(objDOM, "/root/hidden/report/fromdd", Div00.ipt_startdd.value);
  376. rptf_setValueToDOM(objDOM, "/root/hidden/report/todd", Div00.ipt_enddd.value);
  377. rptf_setNodeListToDOM(objDOM, "/root/hidden/report/bloodstocklist", ds_grid_grd_bloodstocklist); // 데이터셋 1
  378. var objParam = new Object();
  379. objParam.xml_data_XML1 = objDOM.documentElement.source; // 최상의노드 XML 스트링 추출
  380. var option = "open=1;save=1;directprint=0;print=1;zoom=0";
  381. rptf_exeReportPreview30(["RPLBP00300"],[objParam], option);
  382. }
  383. // 엑셀 저장
  384. function lf_exeExcel(pGridId,pGridNm) {
  385. grdf_exportExcel(pGridId, lf_lisGetTitle(this) + "_" + pGridNm, "sheet1", false);
  386. }
  387. // 혈액인수인계용 엑셀저장
  388. function lf_bloodAcptTranExcel() {
  389. var toDate = utlf_getYear()+"년 "+utlf_getMonth()+"월 "+utlf_getDate()+"일 ";
  390. var toTime = utlf_getCurrentTime();
  391. toDate = toDate + toTime.substr(0,2)+"시 "+toTime.substr(2,2)+" 분";
  392. var strTmpr = input2.value; // 온도
  393. var strTran01 = input3.value; // 인계자1
  394. var strTran02 = input5.value; // 인계자2
  395. var strTran03 = input6.value; // 인계자3
  396. var strAcpt01 = input4.value; // 인수자1
  397. var strAcpt02 = input7.value; // 인수자2
  398. var strAcpt03 = input8.value; // 인수자3
  399. var rowNum;
  400. var savename = "혈액인수인계_" + toDate.toString();
  401. var filename = "";
  402. if(utlf_isNull(strTmpr)){
  403. sysf_messageBox("혈액보관온도를 입력해주세요.", "I");
  404. return;
  405. }
  406. if(utlf_isNull(strTran01) && utlf_isNull(strTran02) && utlf_isNull(strTran03)){
  407. sysf_messageBox("인계자를 입력해주세요.", "I");
  408. return;
  409. }
  410. if(utlf_isNull(strAcpt01) && utlf_isNull(strAcpt02) && utlf_isNull(strAcpt03)){
  411. sysf_messageBox("인수자를 입력해주세요.", "I");
  412. return;
  413. }
  414. // 재고조회 그리드를 인수인계용 그리드로 copy
  415. ds_grid_grd_bloodacpttran.copyData(ds_grid_grd_bloodstocklist, false);
  416. var addRw = ds_grid_grd_bloodacpttran.addRow();
  417. ds_grid_grd_bloodacpttran.setColumn(addRw, "blodcomnm", "혈액보관온도");
  418. ds_grid_grd_bloodacpttran.setColumn(addRw, "ap", strTmpr);
  419. addRw = ds_grid_grd_bloodacpttran.addRow();
  420. ds_grid_grd_bloodacpttran.setColumn(addRw, "blodcomnm", "인계자");
  421. ds_grid_grd_bloodacpttran.setColumn(addRw, "ap", strTran01);
  422. ds_grid_grd_bloodacpttran.setColumn(addRw, "bp", strTran02);
  423. ds_grid_grd_bloodacpttran.setColumn(addRw, "op", strTran03);
  424. addRw = ds_grid_grd_bloodacpttran.addRow();
  425. ds_grid_grd_bloodacpttran.setColumn(addRw, "blodcomnm", "인수자");
  426. ds_grid_grd_bloodacpttran.setColumn(addRw, "ap", strAcpt01);
  427. ds_grid_grd_bloodacpttran.setColumn(addRw, "bp", strAcpt02);
  428. ds_grid_grd_bloodacpttran.setColumn(addRw, "op", strAcpt03);
  429. grdf_exportExcel(grd_bloodacpttran, lf_lisGetTitle(this) + "_" + savename, "sheet1", false);
  430. }
  431. // callback 함수
  432. function cbf_SMLBP00100(strSvcID, nErrorCode, strErrorMag) {
  433. if(nErrorCode != 0) {
  434. sysf_messageBox("ID: "+ strSvcID + " Error: " + strErrorMag, "E009", "");
  435. }else{
  436. switch(strSvcID) {
  437. case "TRLZZ00101":
  438. group1.cmb_mdlcd.index = 0;
  439. break;
  440. case "TRLBP00101":
  441. break;
  442. case "TRLBP00102":
  443. break;
  444. default:
  445. break;
  446. }
  447. }
  448. }
  449. function Div00_btn_search_onclick(obj:Button, e:MouseEventInfo)
  450. {
  451. lf_bloodRef();
  452. }
  453. function grd_bloodstocklist_oncellclick(obj:Grid, e:GridClickEventInfo)
  454. {
  455. if(e.row >=0 && e.col<10 && e.col>1) {
  456. lf_bloodDetail(e.row, e.col);
  457. }
  458. }
  459. function btn_excel_onlbuttonup(obj:Button, e:MouseEventInfo)
  460. {
  461. lf_exeExcel(grd_bloodstocklist,"현재고");
  462. }
  463. function btn_detlexcel_onlbuttonup(obj:Button, e:MouseEventInfo)
  464. {
  465. if(ds_grid_grd_blooddetaillist.rowcount>0){
  466. lf_exeExcel(grd_blooddetaillist,"현재고상세내역");
  467. }
  468. }
  469. function button2_onlbuttonup(obj:Button, e:MouseEventInfo)
  470. {
  471. lf_bloodAcptTranExcel();
  472. }
  473. function button5_onclick(obj:Button, e:ClickEventInfo)
  474. {
  475. lf_setInit();
  476. }
  477. function btn_print_onclick(obj:Button, e:ClickEventInfo)
  478. {
  479. lf_exePrint();
  480. }]]></Script>
  481. </Form>
  482. </FDL>