SMADT00600_반환약관리.xrw 36 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881
  1. <?xml version="1.0" encoding="EUC-KR"?>
  2. <?xml-stylesheet href="../../../com/commonweb/css/common.css" type="text/css" ?>
  3. <xhtml:html xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.w3.org/2002/01/xforms" xmlns:ev="http://www.w3.org/2001/xml-events">
  4. <xhtml:head>
  5. <xhtml:title>반환약관리</xhtml:title>
  6. <model id="model1">
  7. <instance id="instance1">
  8. <root xmlns="">
  9. <main>
  10. <rtnlist>
  11. <rtnlist>
  12. <sel/>
  13. <pid/>
  14. <hngnm/>
  15. <wardnm/>
  16. <roomcd/>
  17. <prcpcd/>
  18. <prcpnm/>
  19. <prcpqty/>
  20. <dayprcpqty/>
  21. <prcptims/>
  22. <prcpdayno/>
  23. <rtnqty/>
  24. <dayrtnqty/>
  25. <rtntims/>
  26. <rtndayno/>
  27. <rtncnts/>
  28. <rtncntsunit/>
  29. <rtnstocqty/>
  30. <rtnrsn/>
  31. <rtnnm/>
  32. <rtndt/>
  33. <rtncnfmdt/>
  34. <rgstdt/>
  35. <prcpdd/>
  36. <prcpno/>
  37. <prcphistno/>
  38. <instcd/>
  39. <drugdd/>
  40. <drugno/>
  41. <ioflag/>
  42. <prcpclscd/>
  43. <prcpgenrflag/>
  44. <prcpkindcd/>
  45. <rtnflag/>
  46. <drugflag/>
  47. <delivecrite/>
  48. <packvol/>
  49. <rtndrugtims/>
  50. <rtndrugdayno/>
  51. <calcmthdcd/>
  52. <totdrugqty/>
  53. <cretno/>
  54. <drugflagnm/>
  55. <rtnstocdeptcd/>
  56. <packunit/>
  57. <rtnunit/>
  58. <drugsumdt/>
  59. <orddeptnm/>
  60. <orddrnm/>
  61. <calcmthdcdnm/>
  62. <delivecritenm/>
  63. <prcpqty2/>
  64. <rtnqty2/>
  65. </rtnlist>
  66. </rtnlist>
  67. <prcplist>
  68. <prcplist>
  69. <prcpcd/>
  70. <hngnm/>
  71. <prcpqty/>
  72. <prcpqtyunit/>
  73. <prcptims/>
  74. <prcpdayno/>
  75. <prcpmixno/>
  76. <rtndt/>
  77. <rtnid/>
  78. <mthdnm/>
  79. </prcplist>
  80. </prcplist>
  81. <rtngrouplist>
  82. <rtnlist>
  83. <prcpcd/>
  84. <prcpnm/>
  85. <rtnqty/>
  86. <rtnstocqty/>
  87. </rtnlist>
  88. </rtngrouplist>
  89. </main>
  90. <send>
  91. <srchinfo/>
  92. <deptinfo>
  93. <deptflag/>
  94. </deptinfo>
  95. <rtninfo>
  96. <rtnlist/>
  97. <userinfo>
  98. <userid/>
  99. <userdeptcd/>
  100. </userinfo>
  101. <srchinfo/>
  102. </rtninfo>
  103. <prcpinfo/>
  104. <userinfo>
  105. <userid/>
  106. </userinfo>
  107. <seldata>
  108. <pid/>
  109. <orddd/>
  110. <cretno/>
  111. </seldata>
  112. </send>
  113. <init/>
  114. <hidden>
  115. <ret/>
  116. </hidden>
  117. <temp>
  118. <srchinfo>
  119. <prcpdd/>
  120. <ioflag>I</ioflag>
  121. <rtnflag>1</rtnflag>
  122. <pid/>
  123. <patnm/>
  124. <barcode/>
  125. <ward/>
  126. <userid/>
  127. <rtnflag_all/>
  128. <drugflag>I</drugflag>
  129. <spclflag/>
  130. <chk_spclflag/>
  131. <srchddflag>R</srchddflag>
  132. <srchpidonly/>
  133. <rtnstocdeptcd/>
  134. <eflag/>
  135. <prcptodd/>
  136. <drugkindflag/>
  137. <drugkindflag_all/>
  138. <drugcd/>
  139. <powderflag/>
  140. <coldflag/>
  141. <rflag/>
  142. <indrugno/>
  143. </srchinfo>
  144. <deptlist>
  145. <ward>
  146. <wardcd/>
  147. <wardnm/>
  148. </ward>
  149. </deptlist>
  150. <userinfo>
  151. <userinfo>
  152. <userid/>
  153. <usernm/>
  154. <userdeptcd/>
  155. <userdeptnm/>
  156. </userinfo>
  157. </userinfo>
  158. <disflag/>
  159. </temp>
  160. </root>
  161. </instance>
  162. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  163. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  164. <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
  165. <script type="javascript" src="../../../ast/pharmacyweb/js/SMADT00600.js"/>
  166. <script type="javascript" src="../../../ast/commonweb/js/AST.js"/>
  167. <script type="javascript" ev:event="xforms-ready">
  168. <![CDATA[
  169. fInit();
  170. ]]>
  171. </script>
  172. <script type="javascript">
  173. <![CDATA[
  174. // 2008-10-17 전체선택 추가
  175. function fTotAllSelect() {
  176. grd_rtnlist.fixedcellischeck(0,0)=false; //grid 캡션의 checkbox clear
  177. //if ((model.getValue("/root/temp/srchinfo/ioflag")=="I") || (model.getValue("/root/temp/srchinfo/pid") == "" )) {
  178. // grd_rtnlist.fixedcellcheckbox(0,0) = false;
  179. //}else{
  180. grd_rtnlist.fixedcellcheckbox(0,0) = true;
  181. //}
  182. }
  183. ]]>
  184. </script>
  185. <submission id="TRADT00601" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/deptinfo" replace="instance" resultref="/root/temp/deptlist"/>
  186. <submission id="TRADT00602" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/srchinfo" replace="instance" resultref="/root/main/rtnlist"/>
  187. <submission id="TRADT00603" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/prcpinfo" replace="instance" resultref="/root/main/prcplist"/>
  188. <submission id="TRADT00604" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/userinfo" replace="instance" resultref="/root/temp/userinfo"/>
  189. <submission id="TRADT00605" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/srchinfo" replace="instance" resultref="/root/main/rtngrouplist"/>
  190. <submission id="TRADT00606" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/seldata" replace="instance" resultref="/root/hidden"/>
  191. <submission id="TXADT00601" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/rtninfo" replace="instance" resultref="/root/main/rtnlist"/>
  192. <submission id="TXADT00602" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/rtninfo" replace="instance" resultref="/root/main/rtnlist"/>
  193. <submission id="TRADT30401" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/srchcond" replace="instance" resultref="/root/temp/srchcond"/>
  194. <submission id="TRADT30405" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/dutdeptinfo" replace="instance" resultref="/root/temp/dutdeptinfo"/>
  195. <submission id="TRADT30101" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/srchcond" replace="instance" resultref="/root/temp/srchcond"/>
  196. <submission id="TRADT01106" mediatype="application/x-www-form-urlencoded" method="post" replace="instance" resultref="/root/init/misdeptlist"/>
  197. <!--<bind id="bind1" ref="/root/main/rtnlist/rtnlist/rtncnts" readonly="../rtnflag != &quot;1&quot;"/>-->
  198. <!--<bind id="bind2" ref="/root/main/rtnlist/rtnlist/sel" readonly="../rtnflag != &quot;1&quot;"/>-->
  199. </model>
  200. </xhtml:head>
  201. <xhtml:body guideline="1,1194;" style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
  202. <group id="group1" style="left:0px; top:0px; width:1194px; height:13px; ">
  203. <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:800px; height:14px; ">반환약관리</caption>
  204. <caption id="caption12" visibility="hidden" style="left:925px; top:0px; width:268px; height:13px; ">* 퇴원약 반환확인은 병동투약관리에서 하십시요.</caption>
  205. </group>
  206. <group id="group3" scroll="auto" style="left:0px; top:13px; width:1195px; height:744px; ">
  207. <datagrid id="datagrid1" nodeset="/root/main/rtngrouplist/rtnlist" class="datagrid2" caption="처방코드^처방명^계산반환수량^실반환수량^caption1" colsep="^" colwidth="75, 88, 44, 46, 18" mergecellsfixedrows="bycolrec" rowsep="|" style="left:980px; top:125px; width:214px; height:615px; ">
  208. <col ref="prcpcd"/>
  209. <col ref="prcpnm"/>
  210. <col ref="rtnqty" style="text-align:right; "/>
  211. <col ref="rtnstocqty" style="text-align:right; "/>
  212. <col ref="allyn" visibility="hidden"/>
  213. </datagrid>
  214. <shape id="roundrect2" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:5px; top:92px; width:318px; height:30px; background-color:transparent; border-color:#7cbbdd; border-style:solid; "/>
  215. <caption id="caption51" style="left:108px; top:101px; width:50px; height:14px; vertical-align:middle; ">미처리</caption>
  216. <caption id="caption53" class="color_2" style="left:170px; top:100px; width:15px; height:15px; vertical-align:middle; "/>
  217. <group id="group2" style="left:0px; top:3px; width:1195px; height:87px; ">
  218. <shape id="roundrect1" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:3px; width:1194px; height:82px; background-color:#fffbf2; border-color:#ffd799; "/>
  219. <select id="checkbox2" ref="/root/temp/srchinfo/rtnflag" class="checkbox_search" overflow="visible" appearance="full" cols="4" rows="1" sep="|" style="left:175px; top:35px; width:170px; height:20px; border-style:none; ">
  220. <choices>
  221. <item>
  222. <label>미처리</label>
  223. <value>1</value>
  224. </item>
  225. <item>
  226. <label>처리</label>
  227. <value>2</value>
  228. </item>
  229. <item>
  230. <label>의사반환</label>
  231. <value>3</value>
  232. </item>
  233. </choices>
  234. <script type="javascript" ev:event="xforms-value-changed">
  235. <![CDATA[
  236. fChgRtnFlag();
  237. ]]>
  238. </script>
  239. </select>
  240. <caption id="caption25" style="left:1085px; top:15px; width:100px; height:13px; ">* 재고반영안됨 *</caption>
  241. <caption id="caption1" class="search_name" style="left:15px; top:65px; width:86px; height:17px; ">등록번호 :</caption>
  242. <caption id="caption2" class="search_name" style="left:1008px; top:66px; width:75px; height:17px; ">바코드 :</caption>
  243. <caption id="caption3" class="search_name" style="left:222px; top:65px; width:75px; height:17px; ">환자명 :</caption>
  244. <caption id="caption4" class="search_name" style="left:15px; top:10px; width:90px; height:17px; ">조회조건 :</caption>
  245. <caption id="caption5" class="search_name" style="left:427px; top:35px; width:65px; height:17px; ">구분 :</caption>
  246. <select1 id="radio2" ref="/root/temp/srchinfo/ioflag" class="radio_search" appearance="full" cols="3" rows="1" overflow="visible" style="left:595px; top:35px; width:95px; height:20px; border-style:none; ">
  247. <choices>
  248. <item>
  249. <label>외래</label>
  250. <value>O</value>
  251. </item>
  252. <item>
  253. <label>병동</label>
  254. <value>I</value>
  255. </item>
  256. </choices>
  257. <script type="javascript" ev:event="xforms-value-changed">
  258. <![CDATA[
  259. // 2009.12.03 pymi (s)
  260. if(radio2.value == "I") {
  261. model.setValue("/root/temp/srchinfo/eflag", "N");
  262. caption12.visible = true;
  263. } else {
  264. model.setValue("/root/temp/srchinfo/eflag", "Y");
  265. caption12.visible = false;
  266. }
  267. // (e)
  268. fTotAllSelect(); // 2008-10-17 grid 캡션선택시 전체 선택처리(병동제외)
  269. fChgIOFlag();
  270. //fRtnData();
  271. ]]>
  272. </script>
  273. </select1>
  274. <input id="input1" ref="/root/temp/srchinfo/pid" class="input_search" autonext="false" maxlength="10" style="left:105px; top:64px; width:80px; height:19px; ">
  275. <script type="javascript" ev:event="onkeyup">
  276. <![CDATA[
  277. // 2008-10-06 event.keyCode=13 정상적으로 실행 안되는 경우가 발생하여 변경
  278. inputEnterKey("btn_sea","DOMActivate");
  279. ]]>
  280. </script>
  281. </input>
  282. <input id="input2" ref="/root/temp/srchinfo/prcptodd" class="input_search" visibility="visible" inputtype="date" style="left:343px; top:10px; width:100px; height:19px; "/>
  283. <caption id="caption7" class="search_name" style="left:35px; top:35px; width:104px; height:17px; ">반납구분 :</caption>
  284. <input id="input3" ref="/root/temp/srchinfo/patnm" class="input_search" autonext="false" maxlength="30" style="left:298px; top:64px; width:97px; height:19px; "/>
  285. <input id="input4" ref="/root/temp/srchinfo/barcode" class="input_search" style="left:1085px; top:64px; width:104px; height:19px; ">
  286. <script type="javascript" ev:event="onkeyup">
  287. <![CDATA[
  288. if(event.keyCode == "13") {
  289. fTotAllSelect(); // 2008-10-17 grid 캡션선택시 전체 선택처리(병동제외)
  290. fRtnData();
  291. }
  292. ]]>
  293. </script>
  294. </input>
  295. <caption id="caption9" class="search_name" style="left:785px; top:64px; width:86px; height:17px; ">수행부서 :</caption>
  296. <input id="input5" ref="/root/temp/srchinfo/prcpdd" class="input_search" inputtype="date" style="left:215px; top:10px; width:100px; height:19px; "/>
  297. <button id="btn_sea" class="btn1_letter2" style="left:860px; top:9px; width:56px; height:22px; ">
  298. <caption>조회</caption>
  299. <script type="javascript" ev:event="DOMActivate">
  300. <![CDATA[
  301. //2008-10-17 등록번호로만 조회/검색일자구분 추가 Start
  302. var srchpid = "";
  303. var srchpidonly = "";
  304. var srchddflag = "";
  305. srchpid = model.getValue("/root/temp/srchinfo/pid");
  306. srchpidonly = model.getValue("/root/temp/srchinfo/srchpidonly");
  307. srchddflag = model.getValue("/root/temp/srchinfo/srchddflag");
  308. if (model.getValue("/root/temp/srchinfo/rtnflag") == "" ) {
  309. messageBox("반납구분을","C001");
  310. return;
  311. }
  312. if (srchpidonly == "Y") {
  313. if (model.getValue("/root/temp/srchinfo/pid") == "" ) {
  314. messageBox("등록번호를","C001");
  315. return;
  316. }
  317. } else {
  318. if (srchddflag == "") {
  319. messageBox("검색일자구분을","C001");
  320. return;
  321. }
  322. if (srchddflag == "O" && model.getValue("/root/temp/srchinfo/prcpdd") == "" ) {
  323. messageBox("적용일자를","C001");
  324. return;
  325. }
  326. if (srchddflag == "R" && model.getValue("/root/temp/srchinfo/prcpdd") == "" ) {
  327. messageBox("반환일자를","C001");
  328. return;
  329. }
  330. }
  331. fTotAllSelect();
  332. //2008-10-17 등록번호로만 조회/검색일자구분 추가 Check End
  333. fRtnData();
  334. // for (var i=1; i<grd_rtnlist.rows; i++) {
  335. // if(model.getValue("/root/main/rtnlist/rtnlist["+i+"]/drugflagnm") == "원외"){
  336. // grd_rtnlist.cellStyle("background-color", i, grd_rtnlist.colRef("drugflagnm")) ="#ffffcc";
  337. // }
  338. // }
  339. model.refresh();
  340. ]]>
  341. </script>
  342. </button>
  343. <select id="checkbox1" ref="/root/temp/srchinfo/rtnflag_all" overflow="visible" appearance="full" style="left:125px; top:35px; width:45px; height:20px; border-style:none; ">
  344. <choices>
  345. <item>
  346. <label>전체</label>
  347. <value>A</value>
  348. </item>
  349. </choices>
  350. <script type="javascript" ev:event="xforms-value-changed">
  351. <![CDATA[
  352. fChgRtnFlagAll();
  353. ]]>
  354. </script>
  355. </select>
  356. <select1 id="rdo_drugflag" ref="/root/temp/srchinfo/drugflag" class="radio_search" appearance="full" cols="2" overflow="visible" style="left:695px; top:35px; width:130px; height:20px; border-style:none; ">
  357. <choices>
  358. <item>
  359. <label>병동</label>
  360. <value>I</value>
  361. </item>
  362. <item>
  363. <label>외출/외박</label>
  364. <value>G</value>
  365. </item>
  366. </choices>
  367. <script type="javascript" ev:event="xforms-value-changed">
  368. <![CDATA[
  369. fTotAllSelect(); // 2008-10-17 grid 캡션선택시 전체 선택처리(병동제외)
  370. //fRtnData();
  371. ]]>
  372. </script>
  373. </select1>
  374. <select id="checkbox3" ref="/root/temp/srchinfo/chk_spclflag" overflow="visible" appearance="full" style="left:487px; top:36px; width:105px; height:20px; border-style:none; ">
  375. <choices>
  376. <item>
  377. <label>특수조제실대상</label>
  378. <value>Y</value>
  379. </item>
  380. </choices>
  381. <script type="javascript" ev:event="xforms-value-changed">
  382. <![CDATA[
  383. if(model.getValue("/root/temp/srchinfo/chk_spclflag") == "Y"){
  384. model.setValue("/root/temp/srchinfo/spclflag", "S");
  385. } else {
  386. model.setValue("/root/temp/srchinfo/spclflag", "M");
  387. }
  388. model.refresh();
  389. ]]>
  390. </script>
  391. </select>
  392. <select1 id="combo1" ref="/root/temp/srchinfo/srchddflag" visibility="visible" appearance="minimal" style="left:105px; top:10px; width:105px; height:19px; ">
  393. <choices>
  394. <item>
  395. <label>적용일자</label>
  396. <value>O</value>
  397. </item>
  398. <item>
  399. <label>반환저장일자</label>
  400. <value>R</value>
  401. </item>
  402. <item>
  403. <label>반환확인일자</label>
  404. <value>C</value>
  405. </item>
  406. <item>
  407. <label>처방출력일시</label>
  408. <value>P</value>
  409. </item>
  410. <item>
  411. <label>집계일시</label>
  412. <value>S</value>
  413. </item>
  414. </choices>
  415. <script type="javascript" ev:event="xforms-value-changed">
  416. <![CDATA[
  417. var ddflag = model.getValue("/root/temp/srchinfo/srchddflag");
  418. if(ddflag == "C") {
  419. model.setValue("/root/temp/srchinfo/rtnflag", "2" );
  420. model.setValue("/root/temp/srchinfo/rtnflag_all", "");
  421. model.refresh();
  422. checkbox1.disabled = true;
  423. checkbox2.disabled = true;
  424. } else {
  425. checkbox1.disabled = false;
  426. checkbox2.disabled = false;
  427. }
  428. ]]>
  429. </script>
  430. </select1>
  431. <select id="checkbox4" ref="/root/temp/srchinfo/srchpidonly" overflow="visible" appearance="full" style="left:187px; top:66px; width:28px; height:20px; border-style:none; ">
  432. <choices>
  433. <item>
  434. <label/>
  435. <value>Y</value>
  436. </item>
  437. </choices>
  438. <script type="javascript" ev:event="xforms-value-changed">
  439. <![CDATA[
  440. //alert (model.getValue("/root/temp/srchinfo/srchpidonly"));
  441. if(model.getValue("/root/temp/srchinfo/srchpidonly") == "Y") {
  442. combo1.disabled = true; //검색구분
  443. input5.disabled = true; //검색일자
  444. input2.disabled = true; //검색일자
  445. } else {
  446. combo1.disabled = false; //검색구분
  447. input5.disabled = false; //검색일자
  448. input2.disabled = false; //검색일자
  449. }
  450. ]]>
  451. </script>
  452. </select>
  453. <select1 id="combo2" ref="/root/temp/srchinfo/ward" visibility="visible" appearance="minimal" cols="2" editmode="inputsearch" style="left:874px; top:64px; width:121px; height:19px; ">
  454. <choices>
  455. <itemset nodeset="/root/temp/srchcond/dept">
  456. <label ref="deptnm"/>
  457. <value ref="deptcd"/>
  458. </itemset>
  459. </choices>
  460. <script type="javascript" ev:event="xforms-value-changed">
  461. <![CDATA[
  462. fTotAllSelect(); // 2008-10-17 grid 캡션선택시 전체 선택처리(병동제외)
  463. //fRtnData();
  464. ]]>
  465. </script>
  466. </select1>
  467. <select id="checkbox5" ref="/root/temp/srchinfo/eflag" overflow="visible" appearance="full" style="left:345px; top:35px; width:100px; height:20px; border-style:none; ">
  468. <choices>
  469. <item>
  470. <label>반환요청만</label>
  471. <value>Y</value>
  472. </item>
  473. </choices>
  474. </select>
  475. <caption id="caption18" style="left:315px; top:9px; width:30px; height:25px; font-weight:bold; text-align:center; vertical-align:middle; ">~</caption>
  476. <select id="checkbox6" ref="/root/temp/srchinfo/drugkindflag" class="checkbox_search" overflow="visible" appearance="full" cols="2" rows="1" sep="|" style="left:515px; top:11px; width:120px; height:20px; border-style:none; ">
  477. <choices>
  478. <item>
  479. <label>내외용약</label>
  480. <value>1</value>
  481. </item>
  482. <item>
  483. <label>주사</label>
  484. <value>2</value>
  485. </item>
  486. </choices>
  487. <script type="javascript" ev:event="xforms-value-changed">
  488. <![CDATA[
  489. fChgDrugkindFlag();
  490. ]]>
  491. </script>
  492. </select>
  493. <select id="checkbox7" ref="/root/temp/srchinfo/drugkindflag_all" overflow="visible" appearance="full" style="left:460px; top:11px; width:45px; height:20px; border-style:none; ">
  494. <choices>
  495. <item>
  496. <label>전체</label>
  497. <value>A</value>
  498. </item>
  499. </choices>
  500. <script type="javascript" ev:event="xforms-value-changed">
  501. <![CDATA[
  502. fChgDrugkindFlagAll();
  503. ]]>
  504. </script>
  505. </select>
  506. <caption id="caption13" class="search_name" style="left:590px; top:65px; width:100px; height:17px; ">약품코드 :</caption>
  507. <input id="input7" ref="/root/temp/srchinfo/drugcd" class="input_search" autonext="false" maxlength="30" style="left:679px; top:64px; width:90px; height:19px; ">
  508. <script type="javascript" ev:event="onkeyup">
  509. <![CDATA[
  510. inputEnterKey("btn_sea","DOMActivate");
  511. ]]>
  512. </script>
  513. </input>
  514. <select id="checkbox8" ref="/root/temp/srchinfo/powderflag" overflow="visible" appearance="full" style="left:645px; top:11px; width:70px; height:20px; border-style:none; ">
  515. <choices>
  516. <item>
  517. <label>Powder</label>
  518. <value>P</value>
  519. </item>
  520. </choices>
  521. </select>
  522. <select id="checkbox9" ref="/root/temp/srchinfo/coldflag" overflow="visible" appearance="full" style="left:721px; top:11px; width:60px; height:20px; border-style:none; ">
  523. <choices>
  524. <item>
  525. <label>냉장약</label>
  526. <value>COLD</value>
  527. </item>
  528. </choices>
  529. </select>
  530. <select id="checkbox10" ref="/root/temp/srchinfo/rflag" overflow="visible" appearance="full" style="left:793px; top:11px; width:60px; height:20px; border-style:none; ">
  531. <choices>
  532. <item>
  533. <label>정규</label>
  534. <value>R</value>
  535. </item>
  536. </choices>
  537. </select>
  538. <caption id="caption14" class="search_name" style="left:410px; top:65px; width:103px; height:17px; ">투약번호 :</caption>
  539. <input id="input8" ref="/root/temp/srchinfo/indrugno" class="input_search" autonext="false" maxlength="30" style="left:499px; top:64px; width:71px; height:19px; ">
  540. <script type="javascript" ev:event="onkeyup">
  541. <![CDATA[
  542. inputEnterKey("btn_sea","DOMActivate");
  543. ]]>
  544. </script>
  545. </input>
  546. </group>
  547. <caption id="caption55" style="left:188px; top:101px; width:50px; height:14px; vertical-align:middle; ">처리</caption>
  548. <caption id="caption47" class="cell_2" style="left:10px; top:98px; width:70px; height:20px; vertical-align:middle; ">범 례</caption>
  549. <caption id="caption49" class="color_0" style="left:90px; top:100px; width:15px; height:15px; vertical-align:middle; "/>
  550. <datagrid id="grd_prcplist" nodeset="/root/main/prcplist/prcplist" caption="^처방코드^처방명^일수량^1회수량^단위^횟수^일수^Mix^반환일시^반환약사^용법" colsep="^" colwidth="22, 75, 201, 55, 55, 36, 36, 40, 33, 120, 63, 119" extendlastcol="scroll" mergecellsfixedrows="bycolrec" rowheader="seq" rowsep="|" style="left:0px; top:520px; width:975px; height:220px; ">
  551. <col ref="prcphistcd"/>
  552. <col ref="prcpcd"/>
  553. <col ref="hngnm" style="text-align:left; "/>
  554. <col ref="prcpqty" format="#.###" style="text-align:right; "/>
  555. <col ref="prcpqty2" format="#.###" style="text-align:right; "/>
  556. <col ref="prcpqtyunit" style="text-align:right; "/>
  557. <col ref="prcptims" style="text-align:right; "/>
  558. <col ref="prcpdayno" style="text-align:right; "/>
  559. <col ref="prcpmixno"/>
  560. <col ref="rtndt" format="yyyy-mm-dd hh:mm:ss"/>
  561. <col ref="rtnid"/>
  562. <col ref="mthdnm" style="text-align:left; "/>
  563. </datagrid>
  564. <button id="button1" class="btn4_letter4" style="left:810px; top:100px; width:80px; height:22px; ">
  565. <caption>반환확인</caption>
  566. <script type="javascript" ev:event="DOMActivate">
  567. <![CDATA[
  568. model.setValue("/root/temp/disflag","");
  569. fSaveRtnList();
  570. fRtnData();
  571. ]]>
  572. </script>
  573. </button>
  574. <button id="button2" class="btn4_letter4" style="left:893px; top:100px; width:80px; height:22px; ">
  575. <caption>반환취소</caption>
  576. <script type="javascript" ev:event="DOMActivate">
  577. <![CDATA[
  578. //20090917 이선경 주석
  579. /*if ( model.getValue("/root/temp/srchinfo/ioflag") =="I" ) {
  580. messageBox("외래만 처리 가능합니다.", "C004");
  581. return;
  582. }
  583. model.setValue("/root/send/seldata/pid", model.getValue("/root/main/rtnlist/rtnlist["+grd_rtnlist.row+"]/pid"));
  584. model.setValue("/root/send/seldata/orddd", model.getValue("/root/main/rtnlist/rtnlist["+grd_rtnlist.row+"]/prcpdd"));
  585. model.setValue("/root/send/seldata/cretno", model.getValue("/root/main/rtnlist/rtnlist["+grd_rtnlist.row+"]/cretno"));
  586. submit("TRADT00606");
  587. if ( model.getValue("/root/hidden/ret/calcflag") =="N" ){
  588. messageBox("수납 완료건이므로 취소 불가능합니다.", "C004");
  589. return;
  590. }*/
  591. //20090917 이선경 수정 : 반환취소시 처방상태를 D,C->E로 롤백하진 않고 반환확인자, 반환확인일시만 클리어
  592. fSaveRtnCancel();
  593. fRtnData();
  594. ]]>
  595. </script>
  596. </button>
  597. <caption id="caption8" class="search_name" style="left:959px; top:47px; width:75px; height:17px; ">약사ID :</caption>
  598. <input id="input6" ref="/root/temp/srchinfo/userid" class="input_search" autonext="false" maxlength="10" style="left:1035px; top:45px; width:69px; height:19px; ">
  599. <script type="javascript" ev:event="xforms-value-changed">
  600. <![CDATA[
  601. fGetUserInfo();
  602. ]]>
  603. </script>
  604. <script type="javascript" ev:event="onkeyup">
  605. <![CDATA[
  606. if(event.keyCode == "13") {
  607. setInputNodeCurText();
  608. fGetUserInfo();
  609. }
  610. ]]>
  611. </script>
  612. </input>
  613. <output id="output1" ref="/root/temp/userinfo/userinfo/usernm" class="output_search" style="left:1107px; top:45px; width:80px; height:19px; font-weight:bold; text-align:center; "/>
  614. <output id="output3" ref="/root/temp/userinfo/userinfo/userid" visibility="hidden" style="left:975px; top:85px; width:65px; height:19px; "/>
  615. <output id="output4" ref="/root/temp/userinfo/userinfo/userdeptcd" visibility="hidden" style="left:975px; top:105px; width:70px; height:19px; "/>
  616. <caption id="caption10" class="color_5" style="left:230px; top:100px; width:15px; height:15px; vertical-align:middle; "/>
  617. <caption id="caption11" style="left:253px; top:101px; width:50px; height:14px; vertical-align:middle; ">의사반환</caption>
  618. <button id="btn_large" class="btn2_letter4" style="left:740px; top:101px; width:64px; height:19px; ">
  619. <caption>확대보기</caption>
  620. <script type="javascript" ev:event="DOMActivate">
  621. <![CDATA[
  622. if ( grd_rtnlist.attribute("width") == 975){
  623. grd_rtnlist.attribute("width") =1194;
  624. btn_large.attribute("text")="축소보기"
  625. } else {
  626. grd_rtnlist.attribute("width")=975;
  627. btn_large.attribute("text")="확대보기"
  628. }
  629. ]]>
  630. </script>
  631. </button>
  632. <button id="button3" class="btn6_letter2" _auth="X" style="left:1138px; top:100px; width:56px; height:22px; ">
  633. <caption>출력</caption>
  634. <script type="javascript" ev:event="DOMActivate">
  635. <![CDATA[
  636. exeReportPreview("RPADT00601", "XMLSTR", "", "", "true","","","","","true");
  637. ]]>
  638. </script>
  639. </button>
  640. <button id="button4" class="btn1_letter5" style="left:1045px; top:100px; width:92px; height:22px; ">
  641. <caption>약품별조회</caption>
  642. <script type="javascript" ev:event="DOMActivate">
  643. <![CDATA[
  644. //2008-10-17 등록번호로만 조회/검색일자구분 추가 Start
  645. var srchpid = "";
  646. var srchpidonly = "";
  647. var srchddflag = "";
  648. srchpid = model.getValue("/root/temp/srchinfo/pid");
  649. srchpidonly = model.getValue("/root/temp/srchinfo/srchpidonly");
  650. srchddflag = model.getValue("/root/temp/srchinfo/srchddflag");
  651. if (srchpidonly == "Y") {
  652. if (model.getValue("/root/temp/srchinfo/pid") == "" ) {
  653. messageBox("등록번호를","C001");
  654. return;
  655. }
  656. } else {
  657. if (srchddflag == "") {
  658. messageBox("검색일자구분을","C001");
  659. return;
  660. }
  661. if (srchddflag == "O" && model.getValue("/root/temp/srchinfo/prcpdd") == "" ) {
  662. messageBox("적용일자를","C001");
  663. return;
  664. }
  665. if (srchddflag == "R" && model.getValue("/root/temp/srchinfo/prcpdd") == "" ) {
  666. messageBox("반환일자를","C001");
  667. return;
  668. }
  669. }
  670. fTotAllSelect();
  671. //2008-10-17 등록번호로만 조회/검색일자구분 추가 Check End
  672. model.removeNodeset("/root/main/prcplist");
  673. model.copyNode("/root/send/srchinfo","/root/temp/srchinfo");
  674. submit("TRADT00605");
  675. //조회조건중 수행부서가 값이 있으면 약품별조회후 출력시 함게 출력되도록
  676. model.makeValue("/root/temp/srchinfo/wardnm", combo2.label);
  677. //해당row에 색깔 처리
  678. datagrid1.rebuildStyle();
  679. setRowStyle("datagrid1" , "2" , "Y" , "allyn", "equal" );
  680. ]]>
  681. </script>
  682. </button>
  683. <datagrid id="grd_rtnlist" nodeset="/root/main/rtnlist/rtnlist" class="datagrid2" caption="^원외^등록번호^성명^투약번호^병동^병실^처방코드^처방명^1회수량^수량^수량^횟수^일수^rtnqty^반납&#xA;수량^반납&#xA;수량^반납&#xA;횟수^반납&#xA;일수^계산된반환수량^계산된반환수량^실반환량^실반환량^반환량^반환량^실반환&#xA;수량^반환사유^반환자^처방입력일시^적용일자^반환일시^반환확인일시^집계일시^진료과^담당의^수가계산방법^불출계산기준^prcpno^prcphistno^instcd^drugdd^ioflag^prcpclscd^prcpgenrflag^prcpkindcd^rtnflag^drugflag^delivecrite^packvol^rtndrugtims^rtndrugdayno^calcmthdcd^totdrugqty^prcpdd^cretno" colsep="^" colwidth="27, 34, 56, 57, 54, 73, 52, 91, 151, 55, 63, 1, 40, 40, 30, 30, 0, 40, 40, 30, 30, 42, 30, 47, 30, 126, 126, 60, 134, 98, 135, 135, 134, 83, 85, 134, 123, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100" explorerbar="sortshow" frozencols="9" mergecellsfixedrows="bycolrec" rowsep="|" style="left:0px; top:125px; width:975px; height:390px; text-align:center; ">
  684. <col checkvalue="Y,N" ref="sel" type="checkbox"/>
  685. <col ref="drugflagnm" style="text-align:center; "/>
  686. <col ref="pid"/>
  687. <col ref="hngnm" style="text-align:center; "/>
  688. <col ref="drugno" style="text-align:center; "/>
  689. <col ref="wardnm" visibility="hidden"/>
  690. <col ref="roomcd"/>
  691. <col ref="prcpcd"/>
  692. <col ref="prcpnm" style="text-align:left; "/>
  693. <col ref="prcpqty"/>
  694. <col ref="dayprcpqty" style="text-align:right; "/>
  695. <col ref="prcpqty2"/>
  696. <col ref="prcptims" style="text-align:right; "/>
  697. <col ref="prcpdayno" style="text-align:right; "/>
  698. <col ref="rtnqty" visibility="hidden"/>
  699. <col ref="dayrtnqty" style="text-align:right; "/>
  700. <col ref="rtnqty" style="text-align:right; "/>
  701. <col ref="rtntims" style="text-align:right; "/>
  702. <col ref="rtndayno" style="text-align:right; "/>
  703. <col ref="rtncnts" format="#.###" style="text-align:right; "/>
  704. <col ref="packunit" style="text-align:left; "/>
  705. <col class="gridinput" autonext="false" ref="rtnstocqty" type="input" format="9999" maxlength="4" style="text-align:right; "/>
  706. <col ref="rtnunit" style="text-align:left; "/>
  707. <col class="gridinput" autonext="false" ref="rtncnts" type="input" visibility="hidden" format="9999" maxlength="4" style="left:922px; top:32px; width:60px; height:23px; text-align:right; "/>
  708. <col ref="rtncntsunit" visibility="hidden"/>
  709. <col ref="rtnstocqty" visibility="hidden" style="text-align:right; "/>
  710. <col ref="rtnrsn"/>
  711. <col ref="rtnnm"/>
  712. <col ref="rgstdt" visibility="visible" format="yyyy-mm-dd hh:mm:ss" style="text-align:center; "/>
  713. <col ref="drugdd" format="yyyy-mm-dd" style="text-align:center; "/>
  714. <col ref="rtndt" format="yyyy-mm-dd hh:mm:ss"/>
  715. <col ref="rtncnfmdt" format="yyyy-mm-dd hh:mm:ss"/>
  716. <col ref="drugsumdt" format="yyyy-mm-dd hh:mm:ss"/>
  717. <col ref="orddeptnm"/>
  718. <col ref="orddrnm" style="text-align:center; "/>
  719. <col ref="calcmthdcdnm" style="text-align:left; "/>
  720. <col ref="delivecritenm" style="text-align:left; "/>
  721. <col ref="prcpno" visibility="hidden"/>
  722. <col ref="prcphistno" visibility="hidden"/>
  723. <col ref="instcd" visibility="hidden"/>
  724. <col ref="drugdd" visibility="hidden"/>
  725. <col ref="ioflag" visibility="hidden"/>
  726. <col ref="prcpclscd" visibility="hidden"/>
  727. <col ref="prcpgenrflag" visibility="hidden"/>
  728. <col ref="prcpkindcd" visibility="hidden"/>
  729. <col ref="rtnflag" visibility="hidden"/>
  730. <col ref="drugflag" visibility="hidden"/>
  731. <col ref="delivecrite" visibility="hidden"/>
  732. <col ref="packvol" visibility="hidden"/>
  733. <col ref="rtndrugtims" visibility="hidden"/>
  734. <col ref="rtndrugdayno" visibility="hidden"/>
  735. <col ref="calcmthdcd" visibility="hidden"/>
  736. <col ref="totdrugqty" visibility="hidden"/>
  737. <col ref="prcpdd" visibility="hidden"/>
  738. <col ref="cretno" visibility="hidden"/>
  739. <col/>
  740. <col/>
  741. <script type="javascript" ev:event="xforms-value-changed">
  742. <![CDATA[
  743. if(model.getValue("/root/main/rtnlist/rtnlist[" + grd_rtnlist.row + "]/rtncnfmdt") != "") {
  744. //fIptRtnCnts(grd_rtnlist.row);
  745. }
  746. ]]>
  747. </script>
  748. <script type="javascript" ev:event="ondblclick">
  749. <![CDATA[
  750. fGetRtnPrcpData();
  751. ]]>
  752. </script>
  753. <script type="javascript" ev:event="onclick">
  754. <![CDATA[
  755. // 2008-10-17 전체선택시 반환량 자동 계산되도록 처리.
  756. /* if (grd_rtnlist.row == 0 && grd_rtnlist.col== 0 ) { //
  757. for (var i=1; i<grd_rtnlist.rows; i++) {
  758. grd_rtnlist.row = i;
  759. grd_rtnlist.col = 0;
  760. if (model.getValue("/root/main/rtnlist/rtnlist["+i+"]/rtncnfmdt") =="" ){ // 반납처리 안된것만 처리
  761. if (model.getValue("/root/main/rtnlist/rtnlist["+i+"]/sel")=="Y"){
  762. grd_rtnlist.rowStatus(i)="2"; //Update상태를 강제로 넣어준다.
  763. alert("dd");
  764. }
  765. //이선경 주석(20090121) 쿼리에서 조회할때 자동계산해서 값을 가져오도록 수정
  766. //fIptRtnCnts();
  767. }else{
  768. model.setValue("/root/main/rtnlist/rtnlist["+i+"]/sel","N");
  769. grd_rtnlist.rowStatus(i)="0";
  770. //return;
  771. }
  772. }
  773. }
  774. model.refresh();*/
  775. ]]>
  776. </script>
  777. <script type="javascript" ev:event="onaftersort">
  778. <![CDATA[
  779. grd_rtnlist.gridToInstance();
  780. ]]>
  781. </script>
  782. <script type="javascript" ev:event="onmouseup">
  783. <![CDATA[
  784. if ( grd_rtnlist.iscell(event.target) && grd_rtnlist.row >0){
  785. if(grd_rtnlist.col != grd_rtnlist.colRef("sel")){
  786. for ( var i =1 ; i< grd_rtnlist.rows ;i++){
  787. model.setValue("/root/main/rtnlist/rtnlist[" + i + "]/sel", "N");
  788. }
  789. for ( var i =0 ; i< grd_rtnlist.selectedRows;i++){
  790. if ( grd_rtnlist.isReadOnly(grd_rtnlist.selectedRow(i) , 1) == false ){
  791. model.setValue("/root/main/rtnlist/rtnlist[" + grd_rtnlist.selectedRow(i) + "]/sel", "Y");
  792. //grd_rtnlist.rowStatus(i)="2";
  793. grd_rtnlist.addStatus(i,"update");
  794. } else {
  795. model.setValue("/root/main/rtnlist/rtnlist[" + grd_rtnlist.selectedRow(i) + "]/sel", "N");
  796. //grd_rtnlist.rowStatus(i)="0";
  797. grd_rtnlist.removeStatus(i,"update");
  798. }
  799. }
  800. }
  801. model.refresh();
  802. }
  803. ]]>
  804. </script>
  805. </datagrid>
  806. <select1 id="combo3" ref="/root/temp/srchinfo/rtnstocdeptcd" appearance="minimal" style="left:605px; top:102px; width:120px; height:19px; ">
  807. <choices>
  808. <itemset nodeset="/root/init/misdeptlist/deptlist">
  809. <label ref="deptnm"/>
  810. <value ref="deptcd"/>
  811. </itemset>
  812. </choices>
  813. </select1>
  814. <caption id="caption24" style="left:530px; top:102px; width:74px; height:20px; font-weight:bold; color:#ff0000; ">실입고부서</caption>
  815. <shape id="roundrect3" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:455px; top:10px; width:175px; height:25px; background-color:transparent; border-color:#aad799; border-style:solid; "/>
  816. <button id="button5" class="btn4_letter4" style="left:996px; top:14px; width:80px; height:22px; ">
  817. <caption>폐기처리</caption>
  818. <script type="javascript" ev:event="DOMActivate">
  819. <![CDATA[
  820. model.setValue("/root/temp/disflag","Y");
  821. fSaveRtnList();
  822. fRtnData();
  823. ]]>
  824. </script>
  825. </button>
  826. <shape id="roundrect4" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:985px; top:10px; width:205px; height:29px; background-color:transparent; border-color:#aad799; border-style:solid; "/>
  827. </group>
  828. <group id="group4" scroll="auto" style="left:0px; top:757px; width:1195px; height:27px; ">
  829. <button id="btn_prt" class="btn6_letter2" style="left:0px; top:5px; width:56px; height:22px; ">
  830. <caption>출력</caption>
  831. <script type="javascript" ev:event="DOMActivate">
  832. <![CDATA[
  833. //1일기준인지 1회기준인지 체크하여 컬럼을 hidden
  834. var colHidnValue = grdBaseColHidn("D");
  835. //1회 기준
  836. if( colHidnValue == "C") {
  837. model.makeValue("/root/send/srchinfo/prcpqty2chk", "Y");
  838. }
  839. exeReportPreview("RPADT00602", "XMLSTR", "", "", "true","","","","","true");
  840. ]]>
  841. </script>
  842. </button>
  843. <button id="button6" class="btn2_letter2" style="left:65px; top:5px; width:42px; height:19px; ">
  844. <caption>엑셀</caption>
  845. <script type="javascript" ev:event="DOMActivate">
  846. <![CDATA[
  847. var file = window.fileDialog("save","","false","","xls","Excel Files(*.xls)|*.xls");
  848. grd_rtnlist.saveExcel(file);
  849. ]]>
  850. </script>
  851. </button>
  852. </group>
  853. </xhtml:body>
  854. </xhtml:html>