SMADT30600_마약향정불출전용.xfdl 77 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <FDL version="1.5">
  3. <TypeDefinition url="..\..\..\default_typedef.xml"/>
  4. <Form id="SMADT30600" position="absolute 0 0 1209 860" titletext="마약/향정약 처방관리" oninit="SMADT30600_oninit" onload="SMADT30600_onload">
  5. <Layouts>
  6. <Layout>
  7. <Div position="absolute 8 31 1203 775" id="group3" scrollbars="autoboth" onkeyup="group3_onkeyup">
  8. <Layouts>
  9. <Layout>
  10. <Div position="absolute 0 0 1195 260" id="group2" anchor="default" class="div_SA">
  11. <Layouts>
  12. <Layout>
  13. <Edit position="absolute 245 120 860 195" id="input9" class="font_ab" anchor="default" onkeyup="group3_group2_input9_onkeyup" style="font:Dotum,40,bold;"/>
  14. <Static text="바코드 :" position="absolute 10 120 245 195" id="caption7" class="font_ab" anchor="default" style="font:Dotum,30,bold;"/>
  15. <Static text="담당자 :" position="absolute 10 35 245 110" id="caption8" class="font_ab" anchor="default" style="font:Dotum,30,bold;"/>
  16. <Edit readonly="true" position="absolute 595 34 596 109" id="output1" class="font_ab" anchor="default"/>
  17. <Edit position="absolute 245 34 585 109" id="input1" class="font_ab" anchor="default" onkeyup="group3_group2_input1_onkeyup" onkillfocus="group3_group2_input1_onkillfocus" style="font:Dotum,40,bold;"/>
  18. <Button position="absolute 1085 80 1165 102" id="button1" class="btn4" visible="false" text="불출확인" anchor="default" onclick="group3_group2_button1_onclick"/>
  19. <Button position="absolute 1085 135 1165 157" id="button2" class="btn4" text="불출취소" anchor="default" onclick="group3_group2_button2_onclick"/>
  20. <Shape position="absolute 1052 5 1058 245" linetype="vertical" id="line13" class="line_4" anchor="default"/>
  21. <Static text="사용자ID를 입력하십시오." position="absolute 240 200 860 240" id="caption1" anchor="default" style="color:red;font:Dotum,12,bold;"/>
  22. <Static id="Static00" position="absolute 615 34 951 110" style="font:Dotum,40,bold;"/>
  23. </Layout>
  24. </Layouts>
  25. </Div>
  26. </Layout>
  27. </Layouts>
  28. </Div>
  29. <Static id="caption19" text="마약/향정약 처방관리" class="tit_1" position="absolute 8 6 188 31"/>
  30. <Grid id="grd_outnarc" class="datagrid2" taborder="1" binddataset="ds_main_narclist" useinputpanel="false" position="absolute 8 310 1203 750" visible="false" oncelldblclick="grd_outnarc_oncelldblclick" onkeydown="grd_outnarc_onkeydown">
  31. <Formats>
  32. <Format id="default">
  33. <Columns>
  34. <Column size="25"/>
  35. <Column size="27"/>
  36. <Column size="65"/>
  37. <Column size="70"/>
  38. <Column size="70"/>
  39. <Column size="53"/>
  40. <Column size="50"/>
  41. <Column size="70"/>
  42. <Column size="80"/>
  43. <Column size="65"/>
  44. <Column size="61"/>
  45. <Column size="90"/>
  46. <Column size="150"/>
  47. <Column size="40"/>
  48. <Column size="35"/>
  49. <Column size="40"/>
  50. <Column size="35"/>
  51. <Column size="40"/>
  52. <Column size="35"/>
  53. <Column size="30"/>
  54. <Column size="30"/>
  55. <Column size="40"/>
  56. <Column size="35"/>
  57. <Column size="55"/>
  58. <Column size="35"/>
  59. <Column size="40"/>
  60. <Column size="35"/>
  61. <Column size="6"/>
  62. <Column size="70"/>
  63. <Column size="0"/>
  64. <Column size="0"/>
  65. <Column size="6"/>
  66. <Column size="70"/>
  67. <Column size="7"/>
  68. <Column size="70"/>
  69. <Column size="10"/>
  70. <Column size="70"/>
  71. <Column size="10"/>
  72. <Column size="70"/>
  73. <Column size="100"/>
  74. <Column size="6"/>
  75. <Column size="85"/>
  76. <Column size="7"/>
  77. <Column size="85"/>
  78. <Column size="0"/>
  79. <Column size="0"/>
  80. <Column size="0"/>
  81. <Column size="0"/>
  82. <Column size="0"/>
  83. <Column size="0"/>
  84. <Column size="0"/>
  85. <Column size="0"/>
  86. <Column size="0"/>
  87. <Column size="0"/>
  88. <Column size="0"/>
  89. <Column size="0"/>
  90. </Columns>
  91. <Rows>
  92. <Row size="24" band="head"/>
  93. <Row size="24"/>
  94. </Rows>
  95. <Band id="head">
  96. <Cell/>
  97. <Cell col="1"/>
  98. <Cell col="2" text="불출상태"/>
  99. <Cell col="3" text="반환상태"/>
  100. <Cell col="4" text="반납상태"/>
  101. <Cell col="5" text="약품&#10;구분"/>
  102. <Cell col="6" text="투약번호"/>
  103. <Cell col="7" text="수행부서"/>
  104. <Cell col="8" text="처방일자"/>
  105. <Cell col="9" text="환자번호"/>
  106. <Cell col="10" text="환자명"/>
  107. <Cell col="11" text="약품코드"/>
  108. <Cell col="12" text="약품명"/>
  109. <Cell col="13" colspan="2" text="총량" taborder="undefined"/>
  110. <Cell col="15" colspan="2" text="일수량" taborder="undefined"/>
  111. <Cell col="17" colspan="2" text="일용량" taborder="undefined"/>
  112. <Cell col="19" text="횟수"/>
  113. <Cell col="20" text="일수"/>
  114. <Cell col="21" colspan="2" text="잔량" taborder="undefined"/>
  115. <Cell col="23" colspan="2" text="반환횟수" taborder="undefined"/>
  116. <Cell col="25" colspan="2" text="반환용량" taborder="undefined"/>
  117. <Cell col="27" text="조제일시"/>
  118. <Cell col="28" text="조제약사"/>
  119. <Cell col="29" text="투약일시"/>
  120. <Cell col="30" text="투약약사"/>
  121. <Cell col="31" text="수령일시"/>
  122. <Cell col="32" text="수령&#10;담당자"/>
  123. <Cell col="33" text="부서확인&#10;일시"/>
  124. <Cell col="34" text="부서확인&#10;간호사"/>
  125. <Cell col="35" text="반환신청일시"/>
  126. <Cell col="36" text="반환신청&#10;간호사"/>
  127. <Cell col="37" text="반환확인일시"/>
  128. <Cell col="38" text="반환확인&#10;약사"/>
  129. <Cell col="39" text="반환사유"/>
  130. <Cell col="40" text="반납신청&#10;일시"/>
  131. <Cell col="41" text="잔량반납신청&#10;간호사"/>
  132. <Cell col="42" text="반납확인&#10;일시"/>
  133. <Cell col="43" text="잔량반납확인&#10;약사"/>
  134. <Cell col="44" text="prcpno"/>
  135. <Cell col="45" text="prcphistno"/>
  136. <Cell col="46" text="drugdd"/>
  137. <Cell col="47" text="drugno"/>
  138. <Cell col="48" text="ioflag"/>
  139. <Cell col="49" text="instcd"/>
  140. <Cell col="50" text="narcflag"/>
  141. <Cell col="51" text="prntflag"/>
  142. <Cell col="52" text="orddd"/>
  143. <Cell col="53" text="orddeptcd"/>
  144. <Cell col="54" text="prcpgenrflag"/>
  145. <Cell col="55" text="drugkind"/>
  146. </Band>
  147. <Band id="body">
  148. <Cell celltype="head" text="expr:currow + 1"/>
  149. <Cell col="1" displaytype="checkbox" edittype="checkbox" text="bind:sel"/>
  150. <Cell col="2" displaytype="combo" edittype="combo" text="bind:narcstat"/>
  151. <Cell col="3" displaytype="combo" edittype="combo" text="bind:cnclstat"/>
  152. <Cell col="4" displaytype="combo" edittype="combo" text="bind:rtnstat"/>
  153. <Cell col="5" text="bind:drugkindnm"/>
  154. <Cell col="6" text="bind:drugno"/>
  155. <Cell col="7" text="bind:issdeptcdnm"/>
  156. <Cell col="8" text="bind:prcpdd" mask="yyyy/mm/dd"/>
  157. <Cell col="9" text="bind:pid"/>
  158. <Cell col="10" text="bind:patnm"/>
  159. <Cell col="11" text="bind:prcpcd"/>
  160. <Cell col="12" text="bind:drugnm"/>
  161. <Cell col="13" text="bind:totdrugqty"/>
  162. <Cell col="14" text="bind:prcpqtyunit"/>
  163. <Cell col="15" text="bind:dayprcpqty"/>
  164. <Cell col="16" text="bind:prcpqtyunit"/>
  165. <Cell col="17" text="bind:prcpvol"/>
  166. <Cell col="18" text="bind:prcpvolunit"/>
  167. <Cell col="19" text="bind:prcptims"/>
  168. <Cell col="20" text="bind:prcpdayno"/>
  169. <Cell col="21" text="bind:spreqty"/>
  170. <Cell col="22" text="bind:prcpvolunit"/>
  171. <Cell col="23" displaytype="text" edittype="text" class="gridinput" text="bind:rtnqty"/>
  172. <Cell col="24" text="bind:rtnunit"/>
  173. <Cell col="25" text="bind:returnqty"/>
  174. <Cell col="26" text="bind:prcpvolunit"/>
  175. <Cell col="27" text="bind:prcpdt" mask="yyyy/mm/dd hh:nn"/>
  176. <Cell col="28" text="bind:prcpidnm"/>
  177. <Cell col="29" text="bind:drugdt" mask="yyyy/mm/dd hh:nn"/>
  178. <Cell col="30" text="bind:drugidnm"/>
  179. <Cell col="31" text="bind:delivedt" mask="yyyy/mm/dd hh:nn"/>
  180. <Cell col="32" text="bind:deliveidnm"/>
  181. <Cell col="33" text="bind:acptdt" mask="yyyy/mm/dd hh:nn"/>
  182. <Cell col="34" text="bind:acptidnm"/>
  183. <Cell col="35" text="bind:rtnappdt" mask="yyyy/mm/dd hh:nn"/>
  184. <Cell col="36" text="bind:rtnappidnm"/>
  185. <Cell col="37" text="bind:rtncnfmdt" mask="yyyy/mm/dd hh:nn"/>
  186. <Cell col="38" text="bind:rtncnfmidnm"/>
  187. <Cell col="39" text="bind:rtnresn"/>
  188. <Cell col="40" text="bind:spredt" mask="yyyy/mm/dd hh:nn"/>
  189. <Cell col="41" text="bind:spreidnm"/>
  190. <Cell col="42" text="bind:sprecnfmdt" mask="yyyy/mm/dd hh:nn"/>
  191. <Cell col="43" text="bind:sprecnfmidnm"/>
  192. <Cell col="44" text="bind:prcpno"/>
  193. <Cell col="45" text="bind:prcphistno"/>
  194. <Cell col="46" text="bind:drugdd"/>
  195. <Cell col="47" text="bind:drugno"/>
  196. <Cell col="48" text="bind:ioflag"/>
  197. <Cell col="49" text="bind:instcd"/>
  198. <Cell col="50" text="bind:narcflag"/>
  199. <Cell col="51" text="bind:prntflag"/>
  200. <Cell col="52" text="bind:orddd"/>
  201. <Cell col="53" text="bind:orddeptcd"/>
  202. <Cell col="54" text="bind:prcpgenrflag"/>
  203. <Cell col="55" text="bind:drugkind"/>
  204. </Band>
  205. </Format>
  206. </Formats>
  207. </Grid>
  208. <Grid id="grd_sprelist" class="datagrid2" taborder="2" binddataset="ds_main_narclist" useinputpanel="false" position="absolute 8 350 1203 790" visible="false">
  209. <Formats>
  210. <Format id="default">
  211. <Columns>
  212. <Column size="25"/>
  213. <Column size="29"/>
  214. <Column size="60"/>
  215. <Column size="80"/>
  216. <Column size="65"/>
  217. <Column size="58"/>
  218. <Column size="90"/>
  219. <Column size="150"/>
  220. <Column size="50"/>
  221. <Column size="33"/>
  222. <Column size="50"/>
  223. <Column size="26"/>
  224. <Column size="50"/>
  225. <Column size="29"/>
  226. <Column size="34"/>
  227. <Column size="50"/>
  228. <Column size="34"/>
  229. <Column size="100"/>
  230. <Column size="65"/>
  231. <Column size="100"/>
  232. <Column size="62"/>
  233. <Column size="0"/>
  234. <Column size="0"/>
  235. <Column size="0"/>
  236. <Column size="0"/>
  237. <Column size="0"/>
  238. <Column size="0"/>
  239. <Column size="0"/>
  240. <Column size="0"/>
  241. <Column size="0"/>
  242. <Column size="0"/>
  243. <Column size="0"/>
  244. </Columns>
  245. <Rows>
  246. <Row size="24" band="head"/>
  247. <Row size="24"/>
  248. </Rows>
  249. <Band id="head">
  250. <Cell/>
  251. <Cell col="1"/>
  252. <Cell col="2" text="상태"/>
  253. <Cell col="3" text="처방일자"/>
  254. <Cell col="4" text="환자번호"/>
  255. <Cell col="5" text="환자명"/>
  256. <Cell col="6" text="약품코드"/>
  257. <Cell col="7" text="약품명"/>
  258. <Cell col="8" text="총량"/>
  259. <Cell col="9" text="총량"/>
  260. <Cell col="10" text="일수량"/>
  261. <Cell col="11" text="일수량"/>
  262. <Cell col="12" text="일용량"/>
  263. <Cell col="13" text="일용량"/>
  264. <Cell col="14" text="횟수"/>
  265. <Cell col="15" text="잔량"/>
  266. <Cell col="16" text="잔량"/>
  267. <Cell col="17" text="반납신청일시"/>
  268. <Cell col="18" text="반납신청&#10;담당자"/>
  269. <Cell col="19" text="반납확인일시"/>
  270. <Cell col="20" text="반납확인&#10;담당자"/>
  271. <Cell col="21" text="prcpno"/>
  272. <Cell col="22" text="prcphistno"/>
  273. <Cell col="23" text="drugdd"/>
  274. <Cell col="24" text="drugno"/>
  275. <Cell col="25" text="ioflag"/>
  276. <Cell col="26" text="instcd"/>
  277. <Cell col="27" text="narcflag"/>
  278. <Cell col="28" text="prntflag"/>
  279. <Cell col="29" text="orddd"/>
  280. <Cell col="30" text="orddeptcd"/>
  281. <Cell col="31" text="prcpgenrflag"/>
  282. </Band>
  283. <Band id="body">
  284. <Cell celltype="head" text="expr:currow + 1"/>
  285. <Cell col="1" displaytype="checkbox" edittype="checkbox" text="bind:sel"/>
  286. <Cell col="2" displaytype="combo" edittype="combo" text="bind:narcstat"/>
  287. <Cell col="3" text="bind:prcpdd" mask="yyyy/mm/dd"/>
  288. <Cell col="4" text="bind:pid"/>
  289. <Cell col="5" text="bind:patnm"/>
  290. <Cell col="6" text="bind:prcpcd"/>
  291. <Cell col="7" text="bind:drugnm"/>
  292. <Cell col="8" text="bind:totdrugqty"/>
  293. <Cell col="9" text="bind:prcpqtyunit"/>
  294. <Cell col="10" text="bind:dayprcpqty"/>
  295. <Cell col="11" text="bind:prcpqtyunit"/>
  296. <Cell col="12" text="bind:prcpvol"/>
  297. <Cell col="13" text="bind:prcpvolunit"/>
  298. <Cell col="14" text="bind:prcptims"/>
  299. <Cell col="15" text="bind:spreqty"/>
  300. <Cell col="16" text="bind:prcpvolunit"/>
  301. <Cell col="17" text="bind:spredt" mask="expr:utlf_isNull(spredt) ? &quot;yyyy/mm/dd hh:nn&quot; : &quot;&quot;"/>
  302. <Cell col="18" text="bind:spreidnm"/>
  303. <Cell col="19" text="bind:sprecnfmdt" mask="expr:utlf_isNull(sprecnfmdt) ? &quot;yyyy/mm/dd hh:nn&quot; : &quot;&quot;"/>
  304. <Cell col="20" text="bind:sprecnfmidnm"/>
  305. <Cell col="21" text="bind:prcpno"/>
  306. <Cell col="22" text="bind:prcphistno"/>
  307. <Cell col="23" text="bind:drugdd"/>
  308. <Cell col="24" text="bind:drugno"/>
  309. <Cell col="25" text="bind:ioflag"/>
  310. <Cell col="26" text="bind:instcd"/>
  311. <Cell col="27" text="bind:narcflag"/>
  312. <Cell col="28" text="bind:prntflag"/>
  313. <Cell col="29" text="bind:orddd"/>
  314. <Cell col="30" text="bind:orddeptcd"/>
  315. <Cell col="31" text="bind:prcpgenrflag"/>
  316. </Band>
  317. </Format>
  318. </Formats>
  319. </Grid>
  320. <ActiveX id="CommAX" position="absolute 278 465 323 510" progid="{87A84390-EB86-424F-97B9-45E53A5EFE28}" useautobitmapcache="1" anchor="default" taborder="3"/>
  321. <Grid id="grd_narclist" class="datagrid2" taborder="4" binddataset="ds_main_narclist" useinputpanel="false" position="absolute 8 390 1203 830" oncelldblclick="grd_narclist_oncelldblclick">
  322. <Formats>
  323. <Format id="default">
  324. <Columns>
  325. <Column size="25"/>
  326. <Column size="30"/>
  327. <Column size="56"/>
  328. <Column size="56"/>
  329. <Column size="56"/>
  330. <Column size="67"/>
  331. <Column size="41"/>
  332. <Column size="70"/>
  333. <Column size="40"/>
  334. <Column size="65"/>
  335. <Column size="50"/>
  336. <Column size="90"/>
  337. <Column size="150"/>
  338. <Column size="40"/>
  339. <Column size="27"/>
  340. <Column size="36"/>
  341. <Column size="27"/>
  342. <Column size="40"/>
  343. <Column size="28"/>
  344. <Column size="26"/>
  345. <Column size="32"/>
  346. <Column size="28"/>
  347. <Column size="28"/>
  348. <Column size="29"/>
  349. <Column size="32"/>
  350. <Column size="35"/>
  351. <Column size="8"/>
  352. <Column size="70"/>
  353. <Column size="6"/>
  354. <Column size="0"/>
  355. <Column size="0"/>
  356. <Column size="70"/>
  357. <Column size="9"/>
  358. <Column size="70"/>
  359. <Column size="9"/>
  360. <Column size="70"/>
  361. <Column size="9"/>
  362. <Column size="70"/>
  363. <Column size="7"/>
  364. <Column size="70"/>
  365. <Column size="100"/>
  366. <Column size="7"/>
  367. <Column size="85"/>
  368. <Column size="7"/>
  369. <Column size="85"/>
  370. <Column size="0"/>
  371. <Column size="0"/>
  372. <Column size="0"/>
  373. <Column size="0"/>
  374. <Column size="0"/>
  375. <Column size="0"/>
  376. <Column size="0"/>
  377. <Column size="0"/>
  378. <Column size="0"/>
  379. <Column size="0"/>
  380. <Column size="0"/>
  381. </Columns>
  382. <Rows>
  383. <Row size="24" band="head"/>
  384. <Row size="24"/>
  385. </Rows>
  386. <Band id="head">
  387. <Cell/>
  388. <Cell col="1"/>
  389. <Cell col="2" text="불출상태"/>
  390. <Cell col="3" text="반환상태"/>
  391. <Cell col="4" text="반납상태"/>
  392. <Cell col="5" text="처방일자"/>
  393. <Cell col="6" text="투약번호"/>
  394. <Cell col="7" text="수행부서"/>
  395. <Cell col="8" text="병실"/>
  396. <Cell col="9" text="환자번호"/>
  397. <Cell col="10" text="환자명"/>
  398. <Cell col="11" text="약품코드"/>
  399. <Cell col="12" text="약품명"/>
  400. <Cell col="13" colspan="2" text="총량" taborder="undefined"/>
  401. <Cell col="15" colspan="2" text="일수량" taborder="undefined"/>
  402. <Cell col="17" colspan="2" text="일용량" taborder="undefined"/>
  403. <Cell col="19" text="횟수"/>
  404. <Cell col="20" colspan="2" text="잔량" taborder="undefined"/>
  405. <Cell col="22" colspan="2" text="반환횟수" taborder="undefined"/>
  406. <Cell col="24" colspan="2" text="반환수량" taborder="undefined"/>
  407. <Cell col="26" text="조제일시"/>
  408. <Cell col="27" text="조제&#10;약사"/>
  409. <Cell col="28" text="투약일시"/>
  410. <Cell col="29" text="투약&#10;약사"/>
  411. <Cell col="30" text="수령일시"/>
  412. <Cell col="31" text="수령&#10;담당자"/>
  413. <Cell col="32" text="병동수령일시"/>
  414. <Cell col="33" text="부서확인&#10;간호사"/>
  415. <Cell col="34" text="반환신청일시"/>
  416. <Cell col="35" text="반환신청&#10;간호사"/>
  417. <Cell col="36" text="반환일시"/>
  418. <Cell col="37" text="반환&#10;담당자"/>
  419. <Cell col="38" text="반환확인일시"/>
  420. <Cell col="39" text="반환확인&#10;약사"/>
  421. <Cell col="40" text="반환사유"/>
  422. <Cell col="41" text="잔량반납&#10;신청일시"/>
  423. <Cell col="42" text="잔량반납신청&#10;간호사"/>
  424. <Cell col="43" text="잔량반납&#10;확인일시"/>
  425. <Cell col="44" text="잔량반납확인&#10;약사"/>
  426. <Cell col="45" text="prcpno"/>
  427. <Cell col="46" text="prcphistno"/>
  428. <Cell col="47" text="drugdd"/>
  429. <Cell col="48" text="drugno"/>
  430. <Cell col="49" text="ioflag"/>
  431. <Cell col="50" text="instcd"/>
  432. <Cell col="51" text="narcflag"/>
  433. <Cell col="52" text="prntflag"/>
  434. <Cell col="53" text="orddd"/>
  435. <Cell col="54" text="orddeptcd"/>
  436. <Cell col="55" text="prcpgenrflag"/>
  437. </Band>
  438. <Band id="body">
  439. <Cell celltype="head" text="expr:currow + 1"/>
  440. <Cell col="1" displaytype="checkbox" edittype="checkbox" text="bind:sel"/>
  441. <Cell col="2" displaytype="combo" edittype="combo" text="bind:narcstat" combodataset="ds_init_narcstat" combocodecol="cdid" combodatacol="cdnm"/>
  442. <Cell col="3" displaytype="combo" edittype="combo" text="bind:cnclstat" combodataset="ds_init_cnclstat" combocodecol="cdid" combodatacol="cdnm"/>
  443. <Cell col="4" displaytype="combo" edittype="combo" text="bind:rtnstat" combodataset="ds_init_rtnstat" combocodecol="cdid" combodatacol="cdnm"/>
  444. <Cell col="5" text="bind:prcpdd" mask="####/##/##"/>
  445. <Cell col="6" displaytype="text" edittype="text" text="bind:drugno"/>
  446. <Cell col="7" text="bind:issdeptcdnm"/>
  447. <Cell col="8" text="bind:roomcd"/>
  448. <Cell col="9" text="bind:pid"/>
  449. <Cell col="10" text="bind:patnm"/>
  450. <Cell col="11" text="bind:prcpcd"/>
  451. <Cell col="12" text="bind:drugnm"/>
  452. <Cell col="13" text="bind:totdrugqty"/>
  453. <Cell col="14" text="bind:prcpqtyunit"/>
  454. <Cell col="15" text="bind:dayprcpqty"/>
  455. <Cell col="16" text="bind:prcpqtyunit"/>
  456. <Cell col="17" text="bind:prcpvol"/>
  457. <Cell col="18" text="bind:prcpvolunit"/>
  458. <Cell col="19" text="bind:prcptims"/>
  459. <Cell col="20" text="bind:spreqty"/>
  460. <Cell col="21" text="bind:prcpvolunit"/>
  461. <Cell col="22" text="bind:rtnqty"/>
  462. <Cell col="23" text="bind:rtnunit"/>
  463. <Cell col="24" text="bind:returnqty"/>
  464. <Cell col="25" text="bind:prcpqtyunit"/>
  465. <Cell col="26" text="bind:prcpdt" mask="expr:utlf_isNull(prcpdt)? &quot;yyyy/mm/dd hh:nn&quot; : &quot;&quot;"/>
  466. <Cell col="27" text="bind:prcpidnm"/>
  467. <Cell col="28" text="bind:drugdt" mask="expr:utlf_isNull(drugdt)? &quot;yyyy/mm/dd hh:nn&quot; : &quot;&quot;"/>
  468. <Cell col="29" text="bind:drugidnm"/>
  469. <Cell col="30" text="bind:delivedt" mask="yyyy/mm/dd hh:nn"/>
  470. <Cell col="31" text="bind:deliveidnm"/>
  471. <Cell col="32" text="bind:acptdt" mask="expr:utlf_isNull(acptdt)? &quot;yyyy/mm/dd hh:nn&quot; : &quot;&quot;"/>
  472. <Cell col="33" text="bind:acptidnm"/>
  473. <Cell col="34" text="bind:rtnappdt" mask="expr:utlf_isNull(rtnappdt)? &quot;yyyy/mm/dd hh:nn&quot; : &quot;&quot;"/>
  474. <Cell col="35" text="bind:rtnappidnm"/>
  475. <Cell col="36" text="bind:rtndt" mask="expr:utlf_isNull(rtndt)? &quot;yyyy/mm/dd hh:nn&quot; : &quot;&quot;"/>
  476. <Cell col="37" text="bind:rtnidnm"/>
  477. <Cell col="38" text="bind:rtncnfmdt" mask="expr:utlf_isNull(rtncnfmdt)? &quot;yyyy/mm/dd hh:nn&quot; : &quot;&quot;"/>
  478. <Cell col="39" text="bind:rtncnfmidnm"/>
  479. <Cell col="40" text="bind:rtnresn"/>
  480. <Cell col="41" text="bind:spredt" mask="expr:utlf_isNull(spredt)? &quot;yyyy/mm/dd hh:nn&quot; : &quot;&quot;"/>
  481. <Cell col="42" text="bind:spreidnm"/>
  482. <Cell col="43" text="bind:sprecnfmdt" mask="expr:utlf_isNull(sprecnfmdt)? &quot;yyyy/mm/dd hh:nn&quot; : &quot;&quot;"/>
  483. <Cell col="44" text="bind:sprecnfmidnm"/>
  484. <Cell col="45" text="bind:prcpno"/>
  485. <Cell col="46" text="bind:prcphistno"/>
  486. <Cell col="47" text="bind:drugdd"/>
  487. <Cell col="48" text="bind:drugno"/>
  488. <Cell col="49" text="bind:ioflag"/>
  489. <Cell col="50" text="bind:instcd"/>
  490. <Cell col="51" text="bind:narcflag"/>
  491. <Cell col="52" text="bind:prntflag"/>
  492. <Cell col="53" text="bind:orddd"/>
  493. <Cell col="54" text="bind:orddeptcd"/>
  494. <Cell col="55" text="bind:prcpgenrflag"/>
  495. </Band>
  496. </Format>
  497. </Formats>
  498. </Grid>
  499. <Div id="group4" taborder="5" style="background:#f8f8f8ff;border:1 solid #9ebed4ff ;" class="cell_1" visible="false" position="absolute 461 406 696 476">
  500. <Layouts>
  501. <Layout>
  502. <Static id="caption6" text="약제담당자 ID" class="tit_2" position="absolute 9 13 114 31" anchor="default"/>
  503. <Edit id="input3" taborder="1" position="absolute 120 9 220 28" anchor="default" onkeyup="group4_input3_onkeyup"/>
  504. <Button id="button4" taborder="2" text="취소" class="btn4" position="absolute 164 34 220 56" anchor="default" onclick="group4_button4_onclick"/>
  505. </Layout>
  506. </Layouts>
  507. </Div>
  508. </Layout>
  509. </Layouts>
  510. <Objects>
  511. <Dataset id="ds_main_narclist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" reversesubsum="false">
  512. <ColumnInfo>
  513. <Column id="sel" type="STRING"/>
  514. <Column id="narcstat" type="STRING"/>
  515. <Column id="cnclstat" type="STRING"/>
  516. <Column id="rtnstat" type="STRING"/>
  517. <Column id="prcpdd" type="STRING"/>
  518. <Column id="drugno" type="STRING"/>
  519. <Column id="issdeptcdnm" type="STRING"/>
  520. <Column id="roomcd" type="STRING"/>
  521. <Column id="pid" type="STRING"/>
  522. <Column id="patnm" type="STRING"/>
  523. <Column id="prcpcd" type="STRING"/>
  524. <Column id="drugnm" type="STRING"/>
  525. <Column id="totdrugqty" type="STRING"/>
  526. <Column id="prcpqtyunit" type="STRING"/>
  527. <Column id="dayprcpqty" type="STRING"/>
  528. <Column id="prcpqtyunit" type="STRING"/>
  529. <Column id="prcpvol" type="STRING"/>
  530. <Column id="prcpvolunit" type="STRING"/>
  531. <Column id="prcptims" type="STRING"/>
  532. <Column id="spreqty" type="STRING"/>
  533. <Column id="prcpvolunit" type="STRING"/>
  534. <Column id="rtnqty" type="STRING"/>
  535. <Column id="rtnunit" type="STRING"/>
  536. <Column id="returnqty" type="STRING"/>
  537. <Column id="prcpqtyunit" type="STRING"/>
  538. <Column id="prcpdt" type="STRING"/>
  539. <Column id="prcpidnm" type="STRING"/>
  540. <Column id="drugdt" type="STRING"/>
  541. <Column id="drugidnm" type="STRING"/>
  542. <Column id="delivedt" type="STRING"/>
  543. <Column id="deliveidnm" type="STRING"/>
  544. <Column id="acptdt" type="STRING"/>
  545. <Column id="acptidnm" type="STRING"/>
  546. <Column id="rtnappdt" type="STRING"/>
  547. <Column id="rtnappidnm" type="STRING"/>
  548. <Column id="rtndt" type="STRING"/>
  549. <Column id="rtnidnm" type="STRING"/>
  550. <Column id="rtncnfmdt" type="STRING"/>
  551. <Column id="rtncnfmidnm" type="STRING"/>
  552. <Column id="rtnresn" type="STRING"/>
  553. <Column id="spredt" type="STRING"/>
  554. <Column id="spreidnm" type="STRING"/>
  555. <Column id="sprecnfmdt" type="STRING"/>
  556. <Column id="sprecnfmidnm" type="STRING"/>
  557. <Column id="prcpno" type="STRING"/>
  558. <Column id="prcphistno" type="STRING"/>
  559. <Column id="drugdd" type="STRING"/>
  560. <Column id="drugno" type="STRING"/>
  561. <Column id="ioflag" type="STRING"/>
  562. <Column id="instcd" type="STRING"/>
  563. <Column id="narcflag" type="STRING"/>
  564. <Column id="prntflag" type="STRING"/>
  565. <Column id="orddd" type="STRING"/>
  566. <Column id="orddeptcd" type="STRING"/>
  567. <Column id="prcpgenrflag" type="STRING"/>
  568. </ColumnInfo>
  569. <Rows>
  570. <Row/>
  571. </Rows>
  572. </Dataset>
  573. <Dataset id="ds_send_srchinfo" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  574. <ColumnInfo>
  575. <Column id="narcflag" type="STRING" size="256" sumtext="마약향정구분"/>
  576. <Column id="timeflag" type="STRING" size="256" sumtext="조회구간구분"/>
  577. <Column id="fst_dd" type="STRING" size="256" sumtext="시작일자"/>
  578. <Column id="last_dd" type="STRING" size="256" sumtext="종료일자"/>
  579. <Column id="srchdrugkind" type="STRING" size="256" sumtext="약주사구분"/>
  580. <Column id="srchioflag" type="STRING" size="256" sumtext="병동외래구분"/>
  581. <Column id="drugflag" type="STRING" size="256" sumtext="병동조회구분"/>
  582. <Column id="srchroot" type="STRING" size="256" sumtext="마약switch구분"/>
  583. <Column id="narcstat" type="STRING" size="256" sumtext="불출상태"/>
  584. <Column id="cnclstat" type="STRING" size="256" sumtext="반환상태"/>
  585. <Column id="rtnstat" type="STRING" size="256" sumtext="반납상태"/>
  586. <Column id="nodeliveflag" type="STRING" size="256" sumtext="미불출상태"/>
  587. <Column id="narctype" type="STRING" size="256" sumtext="마약코드"/>
  588. <Column id="pid" type="STRING" size="256" sumtext="환자번호"/>
  589. <Column id="ward" type="STRING" size="256" sumtext="병동코드"/>
  590. <Column id="srchdrugno" type="STRING" size="256" sumtext="투약번호"/>
  591. <Column id="barcode" type="STRING" size="256" sumtext="바코드"/>
  592. <Column id="narccd" type="STRING" size="256" sumtext="마약종류"/>
  593. <Column id="barcode_2" type="STRING" size="256" sumtext="바코드전용여부"/>
  594. <Column id="srchdeptcd" type="STRING" size="256" sumtext="수행부서코드"/>
  595. <Column id="srchprcpkind" type="STRING" size="256" sumtext="처방구분"/>
  596. <Column id="srchprcpkindall" type="STRING" size="256" sumtext="처방구분전체"/>
  597. <Column id="prntdt" type="STRING" size="256" sumtext="출력일자"/>
  598. <Column id="issdeptcd" type="STRING" size="256" sumtext="수행부서"/>
  599. <Column id="selkey" type="STRING" size="256" sumtext="체크박스선택 조합기"/>
  600. </ColumnInfo>
  601. </Dataset>
  602. <Dataset id="ds_send_srchcond" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  603. <ColumnInfo>
  604. <Column id="deptflag" type="STRING" size="256"/>
  605. <Column id="narcflag" type="STRING" size="256"/>
  606. </ColumnInfo>
  607. <Rows>
  608. <Row>
  609. <Col id="narcflag">M</Col>
  610. </Row>
  611. </Rows>
  612. </Dataset>
  613. <Dataset id="ds_send_prntinfo" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  614. <Dataset id="ds_send_narcinfo_srchinfo" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  615. <Dataset id="ds_send_narcinfo_narclist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  616. <Dataset id="ds_send_narcinfo_userinfo" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  617. <Dataset id="ds_send_userinfo" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  618. <ColumnInfo>
  619. <Column id="userid" type="STRING" size="256"/>
  620. </ColumnInfo>
  621. <Rows>
  622. <Row/>
  623. </Rows>
  624. </Dataset>
  625. <Dataset id="ds_send_lblskip" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  626. <Dataset id="ds_temp_srchinfo" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  627. <ColumnInfo>
  628. <Column id="narcflag" type="STRING" size="256"/>
  629. <Column id="timeflag" type="STRING" size="256"/>
  630. <Column id="fst_dd" type="STRING" size="256"/>
  631. <Column id="last_dd" type="STRING" size="256"/>
  632. <Column id="pid" type="STRING" size="256"/>
  633. <Column id="ward" type="STRING" size="256"/>
  634. <Column id="srchdrugno" type="STRING" size="256"/>
  635. <Column id="barcode" type="STRING" size="256"/>
  636. <Column id="srchdrugkind" type="STRING" size="256"/>
  637. <Column id="srchioflag" type="STRING" size="256"/>
  638. <Column id="drugflag" type="STRING" size="256"/>
  639. <Column id="srchroot" type="STRING" size="256"/>
  640. <Column id="narcstat" type="STRING" size="256"/>
  641. <Column id="cnclflag" type="STRING" size="256"/>
  642. <Column id="cnclstat" type="STRING" size="256"/>
  643. <Column id="rtnflag" type="STRING" size="256"/>
  644. <Column id="rtnstat" type="STRING" size="256"/>
  645. <Column id="narctypeflag" type="STRING" size="256"/>
  646. <Column id="narctype" type="STRING" size="256"/>
  647. <Column id="srchid" type="STRING" size="256"/>
  648. <Column id="narccd" type="STRING" size="256"/>
  649. <Column id="barcode_2" type="STRING" size="256"/>
  650. <Column id="phamid" type="STRING" size="256"/>
  651. </ColumnInfo>
  652. <Rows>
  653. <Row>
  654. <Col id="narcflag"/>
  655. <Col id="timeflag">2</Col>
  656. <Col id="fst_dd"/>
  657. <Col id="last_dd"/>
  658. <Col id="pid"/>
  659. <Col id="ward"/>
  660. <Col id="srchdrugno"/>
  661. <Col id="barcode"/>
  662. <Col id="srchdrugkind"/>
  663. <Col id="srchioflag">I</Col>
  664. <Col id="drugflag">I</Col>
  665. <Col id="srchroot"/>
  666. <Col id="narcstat"/>
  667. <Col id="cnclflag"/>
  668. <Col id="cnclstat"/>
  669. <Col id="rtnflag"/>
  670. <Col id="rtnstat"/>
  671. <Col id="narctypeflag"/>
  672. <Col id="narctype"/>
  673. <Col id="srchid"/>
  674. <Col id="narccd"/>
  675. <Col id="barcode_2">drug</Col>
  676. <Col id="phamid"/>
  677. </Row>
  678. </Rows>
  679. </Dataset>
  680. <Dataset id="ds_temp_srchcond_narclist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  681. <ColumnInfo>
  682. <Column id="sel" type="STRING" size="256"/>
  683. <Column id="narcnm" type="STRING" size="256"/>
  684. <Column id="narccd" type="STRING" size="256"/>
  685. </ColumnInfo>
  686. <Rows>
  687. <Row/>
  688. </Rows>
  689. </Dataset>
  690. <Dataset id="ds_temp_srchcond_ward" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  691. <ColumnInfo>
  692. <Column id="deptcd" type="STRING" size="256"/>
  693. <Column id="deptnm" type="STRING" size="256"/>
  694. </ColumnInfo>
  695. </Dataset>
  696. <Dataset id="ds_temp_userinfo" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  697. <ColumnInfo>
  698. <Column id="userid" type="STRING" size="256"/>
  699. <Column id="usernm" type="STRING" size="256"/>
  700. <Column id="userdeptcd" type="STRING" size="256"/>
  701. <Column id="userdeptnm" type="STRING" size="256"/>
  702. </ColumnInfo>
  703. </Dataset>
  704. <Dataset id="ds_temp_chkcashinfo" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  705. <Dataset id="ds_init_narcstat" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  706. <ColumnInfo>
  707. <Column id="cdnm" type="STRING" size="256"/>
  708. <Column id="cdid" type="STRING" size="256"/>
  709. </ColumnInfo>
  710. <Rows>
  711. <Row>
  712. <Col id="cdnm">미신청</Col>
  713. <Col id="cdid">1</Col>
  714. </Row>
  715. <Row>
  716. <Col id="cdnm">불출신청</Col>
  717. <Col id="cdid">2</Col>
  718. </Row>
  719. <Row>
  720. <Col id="cdnm">출력완료</Col>
  721. <Col id="cdid">3</Col>
  722. </Row>
  723. <Row>
  724. <Col id="cdnm">조제완료</Col>
  725. <Col id="cdid">4</Col>
  726. </Row>
  727. <Row>
  728. <Col id="cdnm">불출</Col>
  729. <Col id="cdid">5</Col>
  730. </Row>
  731. <Row>
  732. <Col id="cdnm">부서확인</Col>
  733. <Col id="cdid">6</Col>
  734. </Row>
  735. </Rows>
  736. </Dataset>
  737. <Dataset id="ds_init_cnclstat" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  738. <ColumnInfo>
  739. <Column id="cdid" type="STRING" size="256"/>
  740. <Column id="cdnm" type="STRING" size="256"/>
  741. </ColumnInfo>
  742. <Rows>
  743. <Row>
  744. <Col id="cdnm">-</Col>
  745. </Row>
  746. <Row>
  747. <Col id="cdid">0</Col>
  748. <Col id="cdnm">반환대상</Col>
  749. </Row>
  750. <Row>
  751. <Col id="cdid">1</Col>
  752. <Col id="cdnm">반환신청</Col>
  753. </Row>
  754. <Row>
  755. <Col id="cdid">2</Col>
  756. <Col id="cdnm">반환확인</Col>
  757. </Row>
  758. <Row>
  759. <Col id="cdid">7</Col>
  760. <Col id="cdnm">반환종료</Col>
  761. </Row>
  762. </Rows>
  763. </Dataset>
  764. <Dataset id="ds_init_rtnstat" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  765. <ColumnInfo>
  766. <Column id="cdid" type="STRING" size="256"/>
  767. <Column id="cdnm" type="STRING" size="256"/>
  768. </ColumnInfo>
  769. <Rows>
  770. <Row>
  771. <Col id="cdnm">-</Col>
  772. </Row>
  773. <Row>
  774. <Col id="cdid">0</Col>
  775. <Col id="cdnm">잔량대상</Col>
  776. </Row>
  777. <Row>
  778. <Col id="cdid">1</Col>
  779. <Col id="cdnm">잔량신청</Col>
  780. </Row>
  781. <Row>
  782. <Col id="cdid">2</Col>
  783. <Col id="cdnm">잔량확인</Col>
  784. </Row>
  785. </Rows>
  786. </Dataset>
  787. <Dataset id="ds_temp_bknarclist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  788. <Dataset id="ds_temp_bknarclist2" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  789. <Dataset id="ds_send" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  790. <ColumnInfo>
  791. <Column id="lblskip" type="STRING" size="256"/>
  792. </ColumnInfo>
  793. <Rows>
  794. <Row/>
  795. </Rows>
  796. </Dataset>
  797. <Dataset id="ds_temp_ret" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  798. <Dataset id="ds_main_rtnlist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  799. </Objects>
  800. <Bind>
  801. <BindItem id="item1" compid="group3.group2.input1" propid="value" datasetid="ds_temp_srchinfo" columnid="srchid"/>
  802. <BindItem id="item2" compid="group3.group2.input9" propid="value" datasetid="ds_temp_srchinfo" columnid="barcode"/>
  803. <BindItem id="item3" compid="group4.input3" propid="value" datasetid="ds_temp_srchinfo" columnid="phamid"/>
  804. <BindItem id="item0" compid="group3.group2.Static00" propid="text" datasetid="ds_temp_userinfo" columnid="usernm"/>
  805. </Bind>
  806. <Script type="xscript4.0"><![CDATA[/***************************************************************************************
  807. * System Name :
  808. * Job Name :
  809. * Creator :
  810. * Make Date : 2015-11-13
  811. * Description :
  812. *---------------------------------------------------------------------------------------
  813. * Modify Date Modifier Modify Description
  814. *---------------------------------------------------------------------------------------
  815. * 2015-11-13 Live Converter TF->XP
  816. *
  817. *---------------------------------------------------------------------------------------
  818. ****************************************************************************************/
  819. include "com_commonxp::comm_main.xjs";
  820. //include "ast_pharmacyxp::SMADT30600.xjs"
  821. /******************************************************************
  822. * Argument :
  823. * Description : 초기화
  824. ******************************************************************/
  825. function SMADT30600_oninit(obj:Form, e:InitEventInfo)
  826. {
  827. frmf_initForm(obj);
  828. }
  829. function SMADT30600_onload(obj:Form, e:LoadEventInfo)
  830. {
  831. fInit();
  832. }
  833. function fInit() {
  834. group3.group2.caption1.text = "";
  835. // grd_narclist.fixedcellcheckbox(0,1) = true;
  836. // grd_sprelist.fixedcellcheckbox(0,1) = true;
  837. // grd_outnarc.fixedcellcheckbox(0,1) = true;
  838. //구분 초기화(전체)
  839. ds_temp_srchinfo.setColumn(0, "narcflag", "M");
  840. ds_temp_srchinfo.setColumn(0, "srchdrugkind", "T");
  841. ds_temp_srchinfo.setColumn(0, "drugflag", "I");
  842. // fChkIOTotal();
  843. ds_temp_srchinfo.setColumn(0, "narcstat", "T");
  844. // rdo_cncl.disabled = true;
  845. ds_temp_srchinfo.setColumn(0, "cnclstat", "");
  846. // rdo_rtn.disabled = true;
  847. ds_temp_srchinfo.setColumn(0, "rtnstat", "");
  848. ds_temp_srchinfo.setColumn(0, "narctypeflag", "T");
  849. ds_temp_srchinfo.setColumn(0, "srchioflag", "I");
  850. fChgIOFlag();
  851. //토글초기화
  852. ds_temp_srchinfo.setColumn(0, "srchroot", "M");
  853. grd_narclist.visible = true;
  854. //조회날짜 초기화
  855. ds_temp_srchinfo.setColumn(0, "fst_dd", utlf_getCurrentDate());
  856. ds_temp_srchinfo.setColumn(0, "last_dd", utlf_getCurrentDate());
  857. //병동 Combo 조회
  858. ds_send_srchcond.setColumn(0, "deptflag", "W");
  859. var oParam = {};
  860. oParam.id = "TRADT30101";
  861. oParam.service = "pharmacyprescriptionapp.Narcotics";
  862. oParam.method = "reqGetSrchList";
  863. oParam.inds = "req=ds_send_srchcond";
  864. oParam.outds = "ds_temp_srchcond_ward=ward ds_temp_srchcond_narclist=narclist";
  865. oParam.async = false;
  866. //oParam.callback = "cf_TRADT30101";
  867. tranf_submit(oParam);
  868. //astfAddCombo("/root/temp/srchcond", "ward", "wardcd,wardnm", ",");
  869. //로그인 사용자 셋팅
  870. var userid = sysf_getUserId();
  871. //model.setValue("/root/temp/srchinfo/srchid", userid);
  872. //fChgUserID();
  873. group3.group2.input1.setFocus();
  874. //gTimer1 = window.setInterval("fClearUserID()",90000);
  875. this.setFocus();
  876. }
  877. /******************************************************************
  878. * Argument :
  879. * Description : 입원외래구분 클릭시
  880. ******************************************************************/
  881. function fChgIOFlag() {
  882. var ioflag = ds_temp_srchinfo.getColumn(0, "srchioflag");
  883. if(ioflag == "O"){
  884. ds_temp_srchinfo.setColumn(0, "drugflag", "");
  885. //rdo_drugflag.visible = false;
  886. } else if(ioflag == "I"){
  887. ds_temp_srchinfo.setColumn(0, "drugflag", "I");
  888. //rdo_drugflag.visible = true;
  889. }
  890. fChgSwitch();
  891. fGetNarcData();
  892. }
  893. /******************************************************************
  894. * Argument :
  895. * Description : switch case변경
  896. ******************************************************************/
  897. function fChgSwitch() {
  898. var srchroot = ds_temp_srchinfo.getColumn(0, "srchroot");
  899. var ioflag = ds_temp_srchinfo.getColumn(0, "srchioflag");
  900. var drugflag = ds_temp_srchinfo.getColumn(0, "drugflag");
  901. if(srchroot == "M"){
  902. if(ioflag == "O"){
  903. grd_narclist.visible = false;
  904. grd_sprelist.visible = false;
  905. grd_outnarc.visible = true;
  906. } else {
  907. if(drugflag == "L"){
  908. grd_narclist.visible = false;
  909. grd_sprelist.visible = false;
  910. grd_outnarc.visible = true;
  911. } else {
  912. grd_narclist.visible = true;
  913. grd_sprelist.visible = false;
  914. grd_outnarc.visible = false;
  915. }
  916. }
  917. } else if(srchroot == "R"){
  918. grd_narclist.visible = false;
  919. grd_sprelist.visible = true;
  920. grd_outnarc.visible = false;
  921. }
  922. }
  923. /******************************************************************
  924. * Argument :
  925. * Description : 마약리스트 조회
  926. ******************************************************************/
  927. function fGetNarcData() {
  928. // grd_narclist.fixedcellischeck(0, 1) = false;
  929. // grd_outnarc.fixedcellischeck(0, 1) = false;
  930. // ds_send_srchinfo.copyData(ds_temp_srchinfo);
  931. ds_send_srchinfo.copyRow(ds_send_srchinfo.addRow(),ds_temp_srchinfo,0);
  932. var oParam = {};
  933. oParam.id = "TRADT30102";
  934. oParam.service = "pharmacyprescriptionapp.Narcotics";
  935. oParam.method = "reqGetNarcData";
  936. oParam.inds = "req=ds_send_srchinfo";
  937. oParam.outds = "ds_main_narclist=narclist";
  938. oParam.async = false;
  939. oParam.callback = "cf_TRADT30102";
  940. tranf_submit(oParam);
  941. ds_main_narclist.addColumn("prcpqtyunit2", "string", 256);
  942. ds_main_narclist.addColumn("dayprcpqtyunit", "string", 256);
  943. ds_main_narclist.addColumn("prcpvolunit2", "string", 256);
  944. for( var i = 0; i < ds_main_narclist.rowcount; i++ ){
  945. var unit = ds_main_narclist.getColumn(i, "prcpqtyunit");
  946. var volunit = ds_main_narclist.getColumn(i, "prcpvolunit");
  947. ds_main_narclist.setColumn(i, "prcpqtyunit2", unit);
  948. ds_main_narclist.setColumn(i, "dayprcpqtyunit", unit);
  949. ds_main_narclist.setColumn(i, "prcpvolunit2", volunit);
  950. }
  951. }
  952. function cf_TRADT30102(sSvcId, nErrorCode, sErrorMsg) {
  953. if(nErrorCode < 0) return;
  954. dsf_setTypeFormat(ds_main_narclist, "prcptims:INT^prcpdayno:INT^rtnqty:INT^prcpno:INT^prcphistno:INT^drugno:INT");
  955. }
  956. /******************************************************************
  957. * Argument : fClearUserID()
  958. * Description :
  959. ******************************************************************/
  960. function fClearUserID(){
  961. if( !utlf_isNull(ds_temp_userinfo.getColumn(0, "userid")) ){
  962. ds_temp_srchinfo.setColumn(0, "srchid", "");
  963. ds_temp_userinfo.setColumn(0, "userid", "");
  964. var sUserid = ds_temp_srchinfo.getColumn(0, "srchid");
  965. ds_temp_userinfo.setColumn(0, "userid", "");
  966. //if(sUserid.length == 8 || sUserid.length == 9 || sUserid.length == 10){
  967. ds_send_userinfo.setColumn(0, "userid", sUserid);
  968. var oParam = {};
  969. oParam.id = "TRADT30104";
  970. oParam.service = "pharmacyprescriptionapp.DrugReturn";
  971. oParam.method = "reqGetUserInfo";
  972. oParam.inds = "req=ds_send_userinfo";
  973. oParam.outds = "ds_temp_userinfo=userinfo";
  974. oParam.async = false;
  975. //oParam.callback = "cf_TRADT30104";
  976. tranf_submit(oParam);
  977. ds_temp_userinfo.clearData();
  978. ds_temp_userinfo.addRow();
  979. //처방리스트들도 같이 삭제.
  980. ds_main_narclist.clearData();
  981. ds_temp_srchinfo.setColumn(0, "srchid","");
  982. ds_temp_userinfo.setColumn(0, "usernm", "");
  983. group3.group2.input1.setFocus();
  984. }
  985. }
  986. /******************************************************************
  987. * Argument : fChgUserID()
  988. * Description : userid 변경시
  989. ******************************************************************/
  990. function fChgUserID() {
  991. var sUserid = ds_temp_srchinfo.getColumn(0, "srchid");
  992. ds_temp_userinfo.setColumn(0, "userid","");
  993. ds_send_userinfo.setColumn(0, "userid", sUserid);
  994. var oParam = {};
  995. oParam.id = "TRADT30104";
  996. oParam.service = "pharmacyprescriptionapp.DrugReturn";
  997. oParam.method = "reqGetUserInfo";
  998. oParam.inds = "req=ds_send_userinfo";
  999. oParam.outds = "ds_temp_userinfo=userinfo";
  1000. oParam.async = false;
  1001. //oParam.callback = "cf_TRADT30104";
  1002. tranf_submit(oParam);
  1003. if( utlf_isNull(ds_temp_userinfo.getColumn(0, "userid")) ){
  1004. sysf_messageBox("사용자ID 정보가 없습니다.\n다시","C001");
  1005. ds_temp_userinfo.clearData();
  1006. ds_temp_userinfo.addRow();
  1007. ds_temp_srchinfo.setColumn(0, "srchid","");
  1008. ds_temp_userinfo.setColumn(0, "usernm", "");
  1009. group3.group2.input1.setFocus();
  1010. } else {
  1011. ds_temp_srchinfo.setColumn(0, "srchid","");
  1012. //처방리스트 리셋
  1013. ds_main_narclist.clearData();
  1014. group3.group2.input9.setFocus();
  1015. }
  1016. }
  1017. /******************************************************************
  1018. * Argument : fChgUserIDPharm()
  1019. * Description : 약제 담당자 id인지 체크
  1020. ******************************************************************/
  1021. function fChgUserIDPharm() {
  1022. var sUserid = ds_temp_srchinfo.getColumn(0, "phamid");
  1023. ds_send_userinfo.setColumn(0, "userid", sUserid);
  1024. var oParam = {};
  1025. oParam.id = "TRADT30104";
  1026. oParam.service = "pharmacyprescriptionapp.DrugReturn";
  1027. oParam.method = "reqGetUserInfo";
  1028. oParam.inds = "req=ds_send_userinfo";
  1029. oParam.outds = "ds_temp_userinfo=userinfo";
  1030. oParam.async = false;
  1031. //oParam.callback = "cf_TRADT30104";
  1032. tranf_submit(oParam);
  1033. ds_temp_srchinfo.setColumn(0, "phamid","");
  1034. if( ds_temp_userinfo.getColumn(0, "grupjoblncd") != "15" ){
  1035. sysf_messageBox("약제 담당자 ID가 아닙니다.\n다시","C001");
  1036. group4.input3.setFocus();
  1037. } else {
  1038. group4.visible = false;
  1039. // if ( gTimer1 != null ){
  1040. // window.clearinterval(gTimer1);
  1041. // }
  1042. this.close();
  1043. }
  1044. }
  1045. /******************************************************************
  1046. * Argument : fClickToggle(chk)
  1047. * Description : 토글클릭시
  1048. ******************************************************************/
  1049. function fClickToggle(chk) {
  1050. if(chk == "1"){
  1051. ds_temp_srchinfo.setColumn(0, "srchroot", "M");
  1052. } else if(chk == "2"){
  1053. ds_temp_srchinfo.setColumn(0, "srchroot", "R");
  1054. }
  1055. fChgSwitch();
  1056. fGetNarcData();
  1057. }
  1058. /******************************************************************
  1059. * Argument : fChkPatSearch()
  1060. * Description : 환자별 조회인지 체크
  1061. ******************************************************************/
  1062. function fChkPatSearch() {
  1063. var pid = ds_temp_srchinfo.getColumn(0, "pid");
  1064. if( !utlf_isNull(pid) && ds_main_narclist.rowcount != 0){
  1065. for(var i = 0; i < ds_main_narclist.rowcount; i++){
  1066. if( ds_main_narclist.getColumn(i, "narcstat") != "1"){
  1067. ds_main_narclist.setColumn(i, "sel", "Y");
  1068. }
  1069. }
  1070. }
  1071. }
  1072. /******************************************************************
  1073. * Argument : fClickToggle(chk)
  1074. * Description : 액팅후 체크표시 cach
  1075. ******************************************************************/
  1076. function fChkCash(chk) {
  1077. var pid = ds_temp_srchinfo.getColumn(0, "pid");
  1078. if( !utlf_isNull(pid) && ds_main_narclist.rowcount != 0){
  1079. if(chk == "before"){
  1080. ds_temp_chkcashinfo.clearData();
  1081. for( var i = 0; i < ds_main_narclist.rowcount; i++ ){
  1082. if( ds_main_narclist.getColumn(i, "sel") == "Y" ){
  1083. var iRow = ds_temp_chkcashinfo.addRow();
  1084. ds_temp_chkcashinfo.copyRow(iRow, ds_main_narclist, i);
  1085. }
  1086. }
  1087. } else if (chk == "after"){
  1088. for(var a = 0; a < ds_temp_chkcashinfo.rowcount; a++){
  1089. var cash_prcpdd = ds_temp_chkcashinfo.getColumn(a, "prcpdd");
  1090. var cash_prcpno = ds_temp_chkcashinfo.getColumn(a, "prcpno");
  1091. for(var b = 0; b < ds_main_narclist.rowcount; b++){
  1092. var search_prcpdd = ds_main_narclist.getColumn(b, "prcpdd");
  1093. var search_prcpno = ds_main_narclist.getColumn(b, "prcpno");
  1094. if(cash_prcpdd == search_prcpdd && cash_prcpno == search_prcpno){
  1095. ds_main_narclist.setColumn(b, "sel", "Y");
  1096. }
  1097. }
  1098. }
  1099. } else {
  1100. }
  1101. }
  1102. }
  1103. /******************************************************************
  1104. * Argument : fChgBarcode()
  1105. * Description : 바코드 변경시
  1106. ******************************************************************/
  1107. function fChgBarcode() {
  1108. var iRowNo = 0;
  1109. var sBar = ds_temp_srchinfo.getColumn(0, "barcode");
  1110. if(sBar.length >= 21){
  1111. if( utlf_isNull(ds_temp_userinfo.getColumn(0, "userid")) ){
  1112. sysf_messageBox("사용자ID가 없습니다. 사용자ID부터","C001");
  1113. ds_temp_srchinfo.setColumn(0, "srchid","");
  1114. ds_temp_srchinfo.setColumn(0, "barcode","");
  1115. group3.group2.input1.setFocus();
  1116. } else if(sBar.substr(0,1) != "M"){
  1117. sysf_messageBox("바코드 정보가 다릅니다. 바코드를 다시","C001");
  1118. ds_temp_srchinfo.setColumn(0, "barcode","");
  1119. group3.group2.input9.setFocus();
  1120. } else {
  1121. //해당 바코드를 확인 처리 하기전 노드를 백업하여 기존에 이미 확인한 리스트들이 사라지지 않도록 한다.
  1122. ds_temp_bknarclist.clearData();
  1123. ds_temp_bknarclist.copyData(ds_main_narclist);
  1124. //바코드로 먼저 해당처방을 조회함
  1125. fGetNarcData();
  1126. //바코드로 Acting처리가 가능한 처방인지 체크함
  1127. //바코드로 처리가능한 Acting : 조제완료, 불출, 잔량반납확인, 반환확인
  1128. //바코드로 조회시 데이터는 한건만 조회됨.
  1129. if(sBar.substr(2,1) == "O" || sBar.substr(2,1) == "E" || sBar.substr(2,1) == "D"){
  1130. if( ds_temp_srchinfo.getColumn(0, "srchroot") == "M" ){
  1131. if( ds_main_narclist.getColumn(0, "narcstat")=="4"){
  1132. //바코드로 취소는 불가능 조회만가능
  1133. ds_main_narclist.setColumn(0, "sel","Y");
  1134. fNarcActing("Drug");
  1135. fSetNarcNodes("ADD");
  1136. return;
  1137. }
  1138. }
  1139. }
  1140. fSetNarcNodes("ADD");
  1141. ds_temp_srchinfo.setColumn(0, "barcode","");
  1142. }
  1143. } else {
  1144. sysf_messageBox("바코드 정보가 다릅니다.\n다시","C001");
  1145. ds_temp_srchinfo.setColumn(0, "barcode","");
  1146. group3.group2.input9.setFocus();
  1147. }
  1148. }
  1149. /******************************************************************
  1150. * Argument : fSetNarcNodes(chk)
  1151. * Description : 백업해 두었던 노드들을 다시 추가 한다.
  1152. ******************************************************************/
  1153. function fSetNarcNodes(pFlag) {
  1154. var iDeleteNode = 0;
  1155. var sChkYn = "";
  1156. var iRowNo = 0;
  1157. if( ds_temp_bknarclist.rowcount >= 1) {
  1158. if(pFlag == "ADD") {
  1159. ds_temp_bknarclist2.clearData();
  1160. ds_temp_bknarclist2.copyData(ds_main_narclist);
  1161. iRowNo = ds_main_narclist.rowcount;
  1162. for(var iRNo = 0; iRNo < ds_temp_bknarclist.rowcount ; iRNo++) {
  1163. sChkYn = "Y";
  1164. //중복처방은 복사하지 않음.
  1165. for(var iNo = 0; iNo < ds_main_narclist.rowcount; iNo++) {
  1166. if(( ds_main_narclist.getColumn(iNo, "prcpdd") == ds_temp_bknarclist.getColumn(iRNo, "prcpdd"))
  1167. && (ds_main_narclist.getColumn(iNo, "prcpno") == ds_temp_bknarclist.getColumn(iRNo, "prcpno"))) {
  1168. sChkYn = "N";
  1169. break;
  1170. }
  1171. }
  1172. if(sChkYn == "Y") {
  1173. ds_temp_bknarclist2.addRow();
  1174. iRowNo++;
  1175. dsf_copyColInfo(ds_temp_bknarclist2, ds_temp_bknarclist);
  1176. ds_temp_bknarclist2.copyRow(iRowNo, ds_temp_bknarclist, iRNo);
  1177. }
  1178. }
  1179. ds_main_narclist.copyData(ds_temp_bknarclist2);
  1180. ds_temp_bknarclist2.clearData();
  1181. } if(pFlag == "COPY") {
  1182. ds_main_narclist.copyData(ds_temp_bknarclist);
  1183. }
  1184. }
  1185. }
  1186. /******************************************************************
  1187. * Argument : fNarcActing(sActing)
  1188. * Description : 마약 Acting 버튼 클릭시 -- 2009-05-20 김귀남 변경
  1189. ******************************************************************/
  1190. function fNarcActing(sActing) {
  1191. if( utlf_isNull(ds_temp_userinfo.getColumn(0, "userid")) ){
  1192. sysf_messageBox("사용자ID가 없습니다. 사용자ID를 먼저","C001");
  1193. ds_temp_srchinfo.setColumn(0, "srchid","");
  1194. opener.group3.group2.ipt_srchid.setFocus();
  1195. return;
  1196. }
  1197. var iActing_Cnt = 0; // 행위 구분을 위한 카운트값
  1198. var sActing_nm = ""; // 해당 행위의 명칭
  1199. var sActingAfter = "";
  1200. var selCnt = 0;
  1201. //액팅전 체크표시 cash
  1202. fChkCash("before");
  1203. ds_send_narcinfo_narclist.clearData();
  1204. dsf_copyColInfo(ds_send_narcinfo_narclist, ds_main_narclist);
  1205. // **** 체크박스 선택 값 카운트 Start ****
  1206. for(var i = 0; i < ds_main_narclist.rowcount; i++){
  1207. var sel = ds_main_narclist.getColumn(i, "sel");
  1208. var sNarcStat = ds_main_narclist.getColumn(i, "narcstat");
  1209. if(sel == "Y" && sNarcStat != "1") selCnt++; // 선택된 값(sel == "Y") 들 중 미신청 값은 제외
  1210. }
  1211. if(selCnt == 0) {
  1212. sysf_messageBox("선택된 데이터가","I004");
  1213. return;
  1214. }
  1215. // **** 체크박스 선택 값 카운트 End ****
  1216. for( var i = 0; i < ds_main_narclist.rowcount; i++){
  1217. var sel = ds_main_narclist.getColumn(i, "sel"); // 선택여부
  1218. var sNarcStat = ds_main_narclist.getColumn(i, "narcstat"); // 불출상태
  1219. var sCnclStat = ds_main_narclist.getColumn(i, "cnclstat"); // 반환상태
  1220. var sRtnStat = ds_main_narclist.getColumn(i, "rtnstat"); // 반납상태
  1221. var sDrugFlag = ds_main_narclist.getColumn(i, "drugflag"); // 마약/향정구분
  1222. var sReturnFlag = ds_main_narclist.getColumn(i, "returnflag"); // 반납여부
  1223. var sDrugKind = ds_main_narclist.getColumn(i, "drugkind"); // 발생구분
  1224. var sIOflag = ds_main_narclist.getColumn(i, "ioflag"); // 입원/외래구분
  1225. var sPrcphistcd = ds_main_narclist.getColumn(i, "prcphistcd"); // 처방상태
  1226. var sPid = ds_main_narclist.getColumn(i, "pid"); // 환자번호
  1227. var sPrcpcd = ds_main_narclist.getColumn(i, "prcpcd"); // 약품코드
  1228. var sDrugno = ds_main_narclist.getColumn(i, "drugno"); // 약품코드
  1229. var sMsg = "*투약번호 : "+sDrugno+" *환자번호 : "+ sPid+ " *약품코드 : "+ sPrcpcd + "\n";
  1230. //=========================================== 제한조건 체크 Start ================================================//
  1231. // 변수명 parameter 명칭 동작가능상태 //
  1232. //------------------------------------------------------------------------------------------------------------//
  1233. // sCnclStat 1. 7 : 반환종료 sCnclStat == "7" ( 진행불가 ) //
  1234. //------------------------------------------------------------------------------------------------------------//
  1235. // sActing - 1. Prcp : 조제확인 sNarcStat == "3" [출력완료] //
  1236. // 2. PrcpCncl : 조제취소 sNarcStat == "4" [조제완료] //
  1237. // 3. Drug : 불출확인 sNarcStat == "4" [조제완료] //
  1238. // 4. DrugCncl : 불출취소 sNarcStat == "5" [불출] //
  1239. // 5. Rtn : 반환확인 sCnclStat == "1" [반환신청] //
  1240. // 6. RtnCncl : 반환취소 (2009-05-05 추가) sCnclStat == "2" [반환확인] //
  1241. // 7. Spre : 잔량확인 sRtnStat == "1" [잔량신청] //
  1242. // 8. SpreCncl : 잔량취소 (2009-05-05 추가) sRtnStat == "2" [잔량확인] //
  1243. //============================================================================================================//
  1244. if(sel == 'Y'){
  1245. // *** 반환종료 *** 처방 메시지 처리 (진행불가) Start
  1246. if(sCnclStat == "7" && (sNarcStat == "3" || sNarcStat == "4")){
  1247. //메세지처리 반환종료 된 처방입니다.
  1248. messageBox(sMsg+"반환 종료 되었습니다. 반환처방전을 출력","I008");
  1249. return;
  1250. } else if(sCnclStat == "7" && sNarcStat == "2"){
  1251. //메세지처리 : 반환종료되었습니다.
  1252. messageBox(sMsg+"반환","I002");
  1253. return;
  1254. }
  1255. // *** 반환종료 *** 처방 메시지 처리 (진행불가) End
  1256. if(sActing == "Prcp"){ // ***조제확인*** 출력완료 일 때만 기능 동작
  1257. //이선경 2008-07-23 start
  1258. /*
  1259. if(sCnclStat != ""){
  1260. if(messageBox("반환된 처방입니다. 조제완료를", "Q002") == "7") {
  1261. return;
  1262. }
  1263. }
  1264. */
  1265. // 한영현/간호 ITC 협의사항 - 'D'인 처방도 정상적인 흐름으로 처리 후 다시 반환처리 - 2009.06.04 (목) 김귀남
  1266. //이선경 2008-07-23 end
  1267. if(sNarcStat == "2"){ // [불출신청] 상태일 때
  1268. sysf_messageBox("마약처방전이 출력되지","E007");
  1269. return;
  1270. }
  1271. if(parseInt(sNarcStat, 10) > 3){ // [출력완료] 상태 이상일 때
  1272. sysf_messageBox("이미 조제완료된 처방","E008");
  1273. return;
  1274. }
  1275. if(sNarcStat == "3"){ // [출력완료] 일 때만 기능 동작
  1276. var iRow = ds_send_narcinfo_narclist.addRow();
  1277. ds_send_narcinfo_narclist.copyRow(iRow, ds_main_narclist, i);
  1278. sActing_nm = "조제완료";
  1279. iActing_Cnt++;
  1280. } else { // 불출상태가 [미신청]일때
  1281. sActing_nm = "조제완료";
  1282. }
  1283. } else if(sActing == "PrcpCncl"){ // ***조제취소***
  1284. //이선경 2008-07-23 start
  1285. if( !utlf_isNull(sCnclStat) ){
  1286. if(sysf_messageBox("반환된 처방입니다. 조제취소를", "Q002") == "7") {
  1287. return;
  1288. }
  1289. }
  1290. //이선경 2008-07-23 end
  1291. if(sNarcStat == "4"){ // [조제완료] 상태일 때
  1292. var iRow = ds_send_narcinfo_narclist.addRow();
  1293. ds_send_narcinfo_narclist.copyRow(iRow, ds_main_narclist, i);
  1294. iActing_Cnt++;
  1295. }
  1296. sActing_nm = "조제취소";
  1297. } else if(sActing == "Drug"){ // ***불출확인***
  1298. //이선경 2008-07-23 start
  1299. /*
  1300. if(sCnclStat != ""){
  1301. if(messageBox("반환된 처방입니다. 불출확인를", "Q002") == "7") {
  1302. return;
  1303. }
  1304. }
  1305. */
  1306. // 한영현/간호 ITC 협의사항 - 'D'인 처방도 정상적인 흐름으로 처리 후 다시 반환처리 - 2009.06.04 (목) 김귀남
  1307. //이선경 2008-07-23 end
  1308. if(sNarcStat == "4"){ // [조제완료] 상태일 때
  1309. var iRow = ds_send_narcinfo_narclist.addRow();
  1310. ds_send_narcinfo_narclist.copyRow(iRow, ds_main_narclist, i);
  1311. iActing_Cnt++;
  1312. }
  1313. sActing_nm = "불출";
  1314. } else if(sActing == "DrugCncl"){ // ***불출취소***
  1315. //이선경 2008-07-23 start
  1316. if(sCnclStat != ""){
  1317. if(sysf_messageBox("반환된 처방입니다. 불출취소를", "Q002") == "7") {
  1318. return;
  1319. }
  1320. }
  1321. //이선경 2008-07-23 end
  1322. if(sNarcStat == "5"){ // [불출] 상태일 때
  1323. var iRow = ds_send_narcinfo_narclist.addRow();
  1324. ds_send_narcinfo_narclist.copyRow(iRow, ds_main_narclist, i);
  1325. iActing_Cnt++;
  1326. }
  1327. sActing_nm = "불출취소";
  1328. } else if(sActing == "Spre"){ // ***잔량확인***
  1329. if(sRtnStat == "1"){ // [잔량신청] 일 때
  1330. var iRow = ds_send_narcinfo_narclist.addRow();
  1331. ds_send_narcinfo_narclist.copyRow(iRow, ds_main_narclist, i);
  1332. iActing_Cnt++;
  1333. // [반환신청] 이거나 [외래] 경구약 혹은 외용제이면서 처방상태(sReturnFlag)가 [D/C]일 경우
  1334. // 반환일시가 존재할때.
  1335. if((sCnclStat == "1" || (sIOflag == "O" && (sDrugKind == "N" || sDrugKind == "Y") && sReturnFlag == "Y"))
  1336. && !utlf_isNull(ds_main_narclist.getColumn(i, "rtndt")) ){
  1337. var vb_prcpcd = ds_main_narclist.getColumn(i, "prcpcd");
  1338. var vb_Chk = sysf_messageBox(vb_prcpcd+"마약에 대해 반환확인 데이터가 존재합니다.\n반환확인을 ", "Q004");
  1339. if(vb_Chk == 6){
  1340. var cnt = ds_send_narcinfo_narclist.rowcount;
  1341. ds_send_narcinfo_narclist.addColumn("acting_after", "string", 256);
  1342. ds_send_narcinfo_narclist.setColumn(cnt, "acting_after", "Rtn");
  1343. }
  1344. }
  1345. }
  1346. sActing_nm = "잔량반납확인";
  1347. } else if(sActing == "SpreCncl"){ // ***잔량취소***
  1348. if(sRtnStat == "2"){ // [잔량확인] 일 때
  1349. var iRow = ds_send_narcinfo_narclist.addRow();
  1350. ds_send_narcinfo_narclist.copyRow(iRow, ds_main_narclist, i);
  1351. iActing_Cnt++;
  1352. }
  1353. sActing_nm = "잔량취소";
  1354. } else if(sActing == "Rtn"){ // ***반환확인***
  1355. /*
  1356. 1. 입원 약주사, 외래주사는 간호사가 반환신청을 함
  1357. 2. 퇴원/외박/외출은 약국에서 반환을 수행(삭제, 간호에서 반환신청해야함)
  1358. 3. 외래 원내 약/외용약은 약국에서 반환을 수행
  1359. */
  1360. //이선경 2008-07-23 start
  1361. if( sIOflag !="O" && sCnclStat == "1" && sPrcphistcd == "E" && sDrugFlag !="L" && sDrugFlag != 'G'){
  1362. //messageBox("간호투약확인후 반환확인을 ", "C002");
  1363. //return;
  1364. }
  1365. //이선경 2008-07-23 end
  1366. if(sCnclStat == "1"){ // [반환신청]상태일 때 (입원/외래 공통)
  1367. var iRow = ds_send_narcinfo_narclist.addRow();
  1368. ds_send_narcinfo_narclist.copyRow(iRow, ds_main_narclist, i);
  1369. iActing_Cnt++;
  1370. /*} else if((sDrugFlag == "L" || sDrugFlag == "G") && (parseInt(sNarcStat,10) < 6 ) && sReturnFlag == "Y"){
  1371. if(model.getValue("/root/main/narclist/narclist["+i+"]/rtnqty") != ""){
  1372. astfCopyNodeSet("/root/send/narcinfo/narclist", "/root/main/narclist/narclist["+i+"]");
  1373. iActing_Cnt++;
  1374. } else {
  1375. messageBox("반환량이 없습니다. 반환량을","C001");
  1376. return;
  1377. }*/
  1378. if( !utlf_isNull(ds_main_narclist.getColumn(i, "rtnqty")) ){
  1379. } else {
  1380. sysf_messageBox("반환량이 없습니다. 반환량을","C001");
  1381. return;
  1382. }
  1383. if(sRtnStat == "1" && !utlf_isNull(ds_main_narclist.getColumn(i, "rtndt")) ){
  1384. var vb_Chk = sysf_messageBox("잔량확인 데이터가 존재합니다.\n잔랑반납확인을 ", "Q004");
  1385. if(vb_Chk == 6){
  1386. var cnt = ds_send_narcinfo_narclist.rowcount;
  1387. ds_send_narcinfo_narclist.addColumn("acting_after", "string", 256);
  1388. ds_send_narcinfo_narclist.setColumn(cnt, "acting_after", "Spre");
  1389. }
  1390. }
  1391. } else if(sIOflag == "O" && (sDrugKind == "N" || sDrugKind == "Y") && sReturnFlag == "Y"){ // [외래] 경구/외용약이면서 prcphistcd가 D,C 일 때
  1392. if( utlf_isNull(ds_main_narclist.getColumn(i, "rtnqty")) ){
  1393. sysf_messageBox("반환량이 없습니다. 반환량을","C001");
  1394. return;
  1395. }
  1396. if(isNaN(ds_main_narclist.getColumn(i, "rtnqty"))){
  1397. sysf_messageBox("반환량은 숫자로","C001");
  1398. ds_main_narclist.setColumn(i, "rtnqty", "");
  1399. return;
  1400. }
  1401. var iRow = ds_send_narcinfo_narclist.addRow();
  1402. ds_send_narcinfo_narclist.copyRow(iRow, ds_main_narclist, i);
  1403. iActing_Cnt++;
  1404. if(sRtnStat == "1" && !utlf_isNull(ds_main_narclist.getColumn(i, "rtndt")) ){
  1405. var vb_prcpcd = ds_main_narclist.getColumn(i, "prcpcd");
  1406. var vb_Chk = sysf_messageBox(vb_prcpcd+"마약에 대해 잔량확인 데이터가 존재합니다.\n잔랑반납확인을 ", "Q004");
  1407. if(vb_Chk == 6){
  1408. var cnt = ds_send_narcinfo_narclist.rowcount;
  1409. ds_send_narcinfo_narclist.addColumn("acting_after", "string", 256);
  1410. ds_send_narcinfo_narclist.setColumn(cnt, "acting_after", "Spre");
  1411. }
  1412. }
  1413. }
  1414. sActing_nm = "반환확인";
  1415. } else if(sActing == "RtnCncl"){ // ***반환취소***
  1416. if(sCnclStat == "2"){ // [반환확인] 일 때
  1417. var iRow = ds_send_narcinfo_narclist.addRow();
  1418. ds_send_narcinfo_narclist.copyRow(iRow, ds_main_narclist, i);
  1419. iActing_Cnt++;
  1420. }
  1421. sActing_nm = "반환취소";
  1422. }
  1423. }
  1424. }
  1425. //=========================================== 제한조건 체크 Start ===========================================
  1426. if(iActing_Cnt == 0 && utlf_isNull(ds_temp_srchinfo.getColumn(0, "barcode")) ){
  1427. sysf_messageBox("선택된 데이터중에 ["+sActing_nm+"]할 데이터가 없거나 \n선택된 데이터가","I004");
  1428. return;
  1429. } else if(iActing_Cnt == 0 && !utlf_isNull(ds_temp_srchinfo.getColumn(0, "barcode")) ){
  1430. sysf_messageBox("이미","I001");
  1431. ds_temp_srchinfo.setColumn(0, "barcode","");
  1432. group3.group2.input9.setFocus();
  1433. return;
  1434. }
  1435. if(sActing == "Prcp" && ds_temp_srchinfo.getColumn(0, "srchioflag") == "I" && ds_temp_srchinfo.getColumn(0, "drugflag") != "L"){
  1436. if ( ds_send.getColumn(0, "lblskip") != "Y" ){
  1437. fNarcLBLPrint("Prnt");
  1438. }
  1439. }
  1440. ds_send_narcinfo_srchinfo.copyData(ds_temp_srchinfo);
  1441. ds_send_narcinfo_userinfo.copyData(ds_temp_userinfo);
  1442. ds_send_narcinfo_srchinfo.addColumn("acting", "string", 256);
  1443. ds_send_narcinfo_srchinfo.setColumn(0, "acting", sActing);
  1444. if(sActing == "Prcp" && ds_temp_srchinfo.getColumn(0, "srchioflag") == "I" && ds_temp_srchinfo.getColumn(0, "drugflag") != "L"){
  1445. if ( ds_send.getColumn(0, "lblskip") != "Y" ){
  1446. dsf_setTypeFormat(ds_send_narcinfo_narclist, "prcpno:INT^prcphistno:INT^drugno:INT");
  1447. var oParam = {};
  1448. oParam.id = "TXADT30102";
  1449. oParam.service = "pharmacyprescriptionapp.Narcotics";
  1450. oParam.method = "reqExeNarcLblCnt";
  1451. oParam.inds = "req=ds_send_narcinfo_narclist srch=ds_send_narcinfo_srchinfo user=ds_send_narcinfo_userinfo";
  1452. oParam.outds = "ds_temp_ret=item";
  1453. oParam.async = false;
  1454. //oParam.callback = "cf_TXADT30102";
  1455. tranf_submit(oParam);
  1456. }
  1457. }
  1458. var oParam = {};
  1459. oParam.id = "TXADT30101";
  1460. oParam.service = "pharmacyprescriptionapp.Narcotics";
  1461. oParam.method = "reqExeNarcData";
  1462. oParam.inds = "req=ds_send_narcinfo_narclist srch=ds_send_narcinfo_srchinfo user=ds_send_narcinfo_userinfo";
  1463. oParam.outds = "ds_main_narclist=narclist";
  1464. oParam.async = false;
  1465. oParam.callback = "cf_TXADT30101";
  1466. tranf_submit(oParam);
  1467. //액팅전 체크표시 다시 표시
  1468. // grd_narclist.fixedcellischeck(0, 1) = false;
  1469. // grd_outnarc.fixedcellischeck(0, 1) = false;
  1470. fChkCash("after");
  1471. ds_temp_srchinfo.setColumn(0, "barcode","");
  1472. group3.group2.input9.setFocus();
  1473. }
  1474. /******************************************************************
  1475. * Argument : fIptRtnCnts()
  1476. * Description : 반환량입력시
  1477. ******************************************************************/
  1478. function fIptRtnCnts() {
  1479. var RtnCnts = ds_main_narclist.getColumn(0, "rtnqty");
  1480. //그리드와 데이터셋이 다르며 데이터셋에 데이터가 담기거나 하는 곳이 없음.
  1481. //var RtnCnfmDt = model.getValue("/root/main/rtnlist/rtnlist["+grd_outnarc.row+"]/rtncnfmdt");
  1482. var cRow = ds_main_narclist.rowposition;
  1483. var RtnCnfmDt = ds_main_rtnlist.getColumn(cRow, "rtncnfmdt");
  1484. if( !utlf_isNull(RtnCnts) ){
  1485. //반납의뢰인 약품만 반납처리함
  1486. if( !utlf_isNull(RtnCnfmDt) ){
  1487. sysf_messageBox("반환완료된 약품","E008");
  1488. return;
  1489. }
  1490. //반납량을 입력하지 않았을 경우
  1491. if(RtnCnts == "0"){
  1492. sysf_messageBox("반환량을","C001");
  1493. ds_main_narclist.setColumn(cRow, "rtnqty", "");
  1494. return;
  1495. }
  1496. if(isNaN(RtnCnts)){
  1497. sysf_messageBox("반환량은 숫자로","C001");
  1498. ds_main_narclist.setColumn(cRow, "rtnqty", "");
  1499. return;
  1500. }
  1501. ds_main_narclist.setColumn(cRow, "sel", "Y");
  1502. ds_main_narclist.rowposition = ds_main_narclist.rowposition + 1;
  1503. grd_outnarc.showEditor(true);
  1504. }
  1505. }
  1506. /********************************화면 Event Start*****************************/
  1507. /******************************************************************
  1508. * Argument :
  1509. * Description : 담당자ID 입력 후 enter event
  1510. ******************************************************************/
  1511. function group3_group2_input1_onkeyup(obj:Edit, e:KeyEventInfo)
  1512. {
  1513. if( e.keycode == 13 ){
  1514. group3.group2.input9.setFocus();
  1515. }
  1516. }
  1517. /******************************************************************
  1518. * Argument :
  1519. * Description : 담당자ID 입력 후 focusOut event
  1520. ******************************************************************/
  1521. function group3_group2_input1_onkillfocus(obj:Edit, e:KillFocusEventInfo)
  1522. {
  1523. group3.group2.caption1.text = "";
  1524. if ( utlf_isNull(ds_temp_srchinfo.getColumn(0, "srchid")) ) {
  1525. ds_temp_srchinfo.setColumn(0, "srchid", "");
  1526. if( utlf_isNull(ds_temp_userinfo.getColumn(0, "userid")) ){
  1527. group3.group2.caption1.text = "사용자ID를 입력하십시오.";
  1528. ds_temp_userinfo.clearData();
  1529. ds_temp_userinfo.addRow();
  1530. group3.group2.input1.setFocus();
  1531. } else {
  1532. group3.group2.input9.setFocus();
  1533. }
  1534. } else {
  1535. fChgUserID();
  1536. }
  1537. }
  1538. /******************************************************************
  1539. * Argument :
  1540. * Description : 바코드 입력 후 focusOut event
  1541. ******************************************************************/
  1542. function group3_group2_input9_onkeyup(obj:Edit, e:KeyEventInfo)
  1543. {
  1544. if( e.keycode == 13 ){
  1545. group3.group2.caption1.text = "";
  1546. group3.group2.input9.enable = false;
  1547. group3.group2.input9.updateToDataset();
  1548. fChgBarcode();
  1549. group3.group2.input9.enable = true;
  1550. group3.group2.input9.setFocus();
  1551. }
  1552. }
  1553. /******************************************************************
  1554. * Argument :
  1555. * Description : 불출확인 button event
  1556. ******************************************************************/
  1557. function group3_group2_button1_onclick(obj:Button, e:ClickEventInfo)
  1558. {
  1559. fNarcActing("Drug");
  1560. }
  1561. /******************************************************************
  1562. * Argument :
  1563. * Description : 불출취소 button event
  1564. ******************************************************************/
  1565. function group3_group2_button2_onclick(obj:Button, e:ClickEventInfo)
  1566. {
  1567. group3.group2.caption1.text = "";
  1568. fNarcActing("DrugCncl");
  1569. }
  1570. /******************************************************************
  1571. * Argument :
  1572. * Description : key event
  1573. ******************************************************************/
  1574. function group3_onkeyup(obj:Div, e:KeyEventInfo)
  1575. {
  1576. if( e.keycode == 27 || e.keycode == 81 ){// 'ESC' or 'Q' 키가 눌려진 경우
  1577. var answer = sysf_messageBox("마약불출 프로그램 종료를 ", "Q004") ;
  1578. if(answer == 6)
  1579. {
  1580. group4.visible = true;
  1581. group3.group2.enable = false;
  1582. }
  1583. }
  1584. if( e.keycode == 121 ){
  1585. ds_temp_srchinfo.setColumn(0, "srchid",""); //담당자
  1586. ds_temp_userinfo.setColumn(0, "usernm", ""); //담자자명
  1587. ds_temp_srchinfo.setColumn(0, "barcode",""); //바코드
  1588. ds_main_narclist.clearData(); //내역
  1589. group3.group2.input9.setFocus();
  1590. }
  1591. }
  1592. /******************************************************************
  1593. * Argument :
  1594. * Description : grou4 약제 담당자ID event
  1595. ******************************************************************/
  1596. function group4_input3_onkeyup(obj:Edit, e:KeyEventInfo)
  1597. {
  1598. if( e.keycode == 13 ){
  1599. group4.input3.updateToDataset();
  1600. fChgUserIDPharm();
  1601. }
  1602. }
  1603. /******************************************************************
  1604. * Argument :
  1605. * Description : grou4 취소 button event
  1606. ******************************************************************/
  1607. function group4_button4_onclick(obj:Button, e:ClickEventInfo)
  1608. {
  1609. group4.visible = false;
  1610. group3.group2.enable = true;
  1611. group3.group2.input1.setFocus();
  1612. }
  1613. /******************************************************************
  1614. * Argument :
  1615. * Description : grd_narclist event
  1616. ******************************************************************/
  1617. function grd_narclist_oncelldblclick(obj:Grid, e:GridClickEventInfo)
  1618. {
  1619. var cRow = ds_main_narclist.rowposition;
  1620. ds_temp_srchinfo.setColumn(0, "pid", ds_main_narclist.getColumn(cRow, "pid"));
  1621. //model.refresh();
  1622. fGetNarcData();
  1623. //환자별 조회라면 체크 표시
  1624. fChkPatSearch();
  1625. }
  1626. /******************************************************************
  1627. * Argument :
  1628. * Description : grd_outnarc event
  1629. ******************************************************************/
  1630. function grd_outnarc_oncelldblclick(obj:Grid, e:GridClickEventInfo)
  1631. {
  1632. var cRow = ds_main_narclist.rowposition;
  1633. ds_temp_srchinfo.setColumn(0, "pid", ds_main_narclist.getColumn(cRow, "pid"));
  1634. //model.refresh();
  1635. fGetNarcData();
  1636. //환자별 조회라면 체크 표시
  1637. fChkPatSearch();
  1638. }
  1639. /******************************************************************
  1640. * Argument :
  1641. * Description : grd_outnarc event
  1642. ******************************************************************/
  1643. function grd_outnarc_onkeydown(obj:Grid, e:KeyEventInfo)
  1644. {
  1645. var cCol = grd_outnarc.currentcol;
  1646. var rtnqtyCol = grd_outnarc.getBindCellIndex("body", "returnqty");
  1647. if( cCol == rtnqtyCol ){
  1648. fIptRtnCnts();
  1649. }
  1650. }
  1651. ]]></Script>
  1652. </Form>
  1653. </FDL>