SMRSO03300_출고내역조회(영양팀).xrw 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300
  1. <?xml version="1.0" encoding="EUC-KR"?>
  2. <?xml-stylesheet type="text/css" href="../../../com/commonweb/css/common.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. <list>
  11. <nutrdelive>
  12. <nutrdelivelist/>
  13. <nutrmaxdeliveno/>
  14. </nutrdelive>
  15. </list>
  16. <item/>
  17. </main>
  18. <send>
  19. <save>
  20. <nutrdelivelist/>
  21. </save>
  22. <nutrdelive>
  23. <instcd/>
  24. <goodflag/>
  25. <deliveno/>
  26. <delivedeptcd/>
  27. <iokindcd/>
  28. <windeptcd/>
  29. <windeptnm/>
  30. <delivepsn/>
  31. <delivefrdd/>
  32. <delivetodd/>
  33. <goodcd/>
  34. <goodnm/>
  35. </nutrdelive>
  36. </send>
  37. <init>
  38. <deliveqty/>
  39. <deliveamt/>
  40. </init>
  41. <hidden/>
  42. <temp/>
  43. <copynode/>
  44. </root>
  45. </instance>
  46. <bind id="delivedeptqty" ref="/root/main/list/nutrdelive/nutrdelivelist/delivedeptqty" calculate="../patmealdeliveqty +../curemealdeliveqty + ../empmealdeliveqty +../empnigtmealdeliveqty"/>
  47. <bind id="deliveamt" ref="/root/main/list/nutrdelive/nutrdelivelist/deliveamt" calculate="../delivedeptqty * ../goodunitcost"/>
  48. <script type="javascript" ev:event="xforms-ready">
  49. <![CDATA[
  50. //화면 Control을 초기화한다
  51. fInitialize();
  52. ]]>
  53. </script>
  54. <submission id="TRRSO03301" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/nutrdelive" resultref="/root/main/list/nutrdelive"/>
  55. </model>
  56. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  57. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  58. <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
  59. <script type="javascript" src="../../../mis/miscommonweb/js/MIS.js"/>
  60. <script type="javascript" src="../../../mis/miscommonweb/js/RSZ001.js"/>
  61. <script type="javascript" src="../../../com/commonweb/js/stringHelper.js"/>
  62. <script type="javascript">
  63. <![CDATA[
  64. function fInitialize() {
  65. misfGridInit(grd_nutrdelive);
  66. grd_nutrdelive.rowHeight(0) = "20";
  67. grd_nutrdelive.rowHeight(1) = "20";
  68. model.resetInstanceNode("/root/send");
  69. rszfUserGoodFlagList(cmb_goodflag,getUserInfo("userid"));
  70. rszfUserInstList(cmb_instcd,getUserInfo("userid"));
  71. misfGridInit(grd_nutrdelive);
  72. misfMsterDetailSet(grd_nutrdelive,null, "TRRSO03301" ,"Y");
  73. var curdate = getCurrentDate();
  74. var cvtdate = curdate.toDate("YYYYMMDD");
  75. model.setValue(ipt_delivefrdd.attribute("ref") , cvtdate.getAddDate(-10,"D").getDateFormat("YYYYMMDD"));
  76. model.setValue(ipt_delivetodd.attribute("ref") , curdate);
  77. model.setValue(ipt_sumdeliveqty.attribute("ref"),0);
  78. model.setValue(opt_sumdeliveamt.attribute("ref"),0);
  79. // hidden col
  80. // [2010.08.26]AS-IS 코드 TO_BE 코드 전환을 위한 물품구분 변경 (goodflag= S) => (goodflag= SF)
  81. model.setValue(cmb_goodflag.attribute("ref"),'SF');
  82. //getUserInfo("dutplceinstcd")
  83. model.setValue(cmb_instcd.attribute("ref") , getUserInfo("dutplceinstcd"));
  84. rszfGetPurcIOFlagList(cmb_iokindcd, model.getValue(cmb_instcd.attribute("ref")) , "O","Y","","%","");
  85. if(cmb_iokindcd.length> 0) cmb_iokindcd.selectedindex= 0;
  86. grd_nutrdelive.selectionmode = "free";
  87. model.refresh();
  88. }
  89. function fCheckRetrieveData(pmsg)
  90. {
  91. if(model.getValue(cmb_instcd.attribute("ref")).length== 0 )
  92. {
  93. if(pmsg == true)
  94. {
  95. messageBox("기관코드를 " ,"C002");
  96. model.setFocus("cmb_instcd");
  97. }
  98. return false;
  99. }
  100. if(model.getValue(cmb_goodflag.attribute("ref")).length== 0 )
  101. {
  102. if(pmsg == true)
  103. {
  104. messageBox("물품구분을 " ,"C002");
  105. model.setFocus("cmb_goodflag");
  106. }
  107. return false;
  108. }
  109. if(model.getValue(ipt_delivefrdd.attribute("ref")).length== 0 )
  110. {
  111. if(pmsg == true)
  112. {
  113. messageBox("출고조회시작일자를 " ,"C001");
  114. model.setFocus("ipt_delivefrdd");
  115. }
  116. return false;
  117. }
  118. if(model.getValue(ipt_delivetodd.attribute("ref")).length== 0 )
  119. {
  120. if(pmsg == true)
  121. {
  122. messageBox("출고조회종료일자를 " ,"C001");
  123. model.setFocus("ipt_delivetodd");
  124. }
  125. return false;
  126. }
  127. // 전체가 '' 임으로 아래에 걸린다.
  128. // 조회프로그램에서는
  129. // if(model.getValue(cmb_iokindcd.attribute("ref")).length== 0 )
  130. // {
  131. // if(pmsg == true)
  132. // {
  133. // messageBox("출고유형을 " ,"C001");
  134. // model.setFocus("cmb_iokindcd");
  135. // }
  136. // return false;
  137. // }
  138. return true;
  139. }
  140. function fAfterRetrieve()
  141. {
  142. var delivedeptqty = 0;
  143. var deliveamt = 0;
  144. for(var currow = grd_nutrdelive.fixedRows ; currow < grd_nutrdelive.rows ; currow++)
  145. {
  146. delivedeptqty = delivedeptqty + parseFloat( grd_nutrdelive.valueMatrix(currow , grd_nutrdelive.colRef("delivedeptqty")));
  147. if(grd_nutrdelive.valueMatrix(currow , grd_nutrdelive.colRef("deliveamt")).length>0)
  148. deliveamt = deliveamt + 0 + parseFloat(grd_nutrdelive.valueMatrix(currow , grd_nutrdelive.colRef("deliveamt")));
  149. }
  150. model.setValue(ipt_sumdeliveqty.attribute("ref"),delivedeptqty);
  151. model.setValue(opt_sumdeliveamt.attribute("ref"),deliveamt);
  152. model.refresh();
  153. }
  154. ]]>
  155. </script>
  156. </xhtml:head>
  157. <xhtml:body style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
  158. <group id="grp_tle" style="left:0px; top:0px; width:1195px; height:13px; ">
  159. <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:243px; height:14px; ">출고내역 조회</caption>
  160. </group>
  161. <group id="grp_biz" scroll="auto" style="left:0px; top:38px; width:1195px; height:744px; ">
  162. <shape id="roundrect2" class="roundrect_search" appearance="roundrect" style="left:0px; top:10px; width:1195px; height:32px; "/>
  163. <line id="line1" class="line_1" style="x1:0px; y1:75px; x2:1195px; y2:75px; "/>
  164. <select1 id="cmb_goodflag" ref="/root/send/nutrdelive/goodflag" class="combo_default" visibility="hidden" appearance="minimal" style="left:555px; top:16px; width:24px; height:19px; ">
  165. <choices>
  166. <itemset nodeset="/root/init/goodflag">
  167. <label ref="cdnm"/>
  168. <value ref="cdid"/>
  169. </itemset>
  170. </choices>
  171. <script type="javascript" ev:event="xforms-value-changed">
  172. <![CDATA[
  173. btn_search.dispatch("DOMActivate");
  174. ]]>
  175. </script>
  176. </select1>
  177. <select1 id="cmb_instcd" ref="/root/send/nutrdelive/instcd" class="combo_s_essential" appearance="minimal" style="left:100px; top:18; width:135px; height:19px; ">
  178. <choices>
  179. <itemset nodeset="/root/init/instcd">
  180. <label ref="cdnm"/>
  181. <value ref="cdid"/>
  182. </itemset>
  183. </choices>
  184. <script type="javascript" ev:event="xforms-value-changed">
  185. <![CDATA[
  186. btn_search.dispatch("DOMActivate");
  187. ]]>
  188. </script>
  189. </select1>
  190. <caption id="caption3" class="tit_2" style="left:5px; top:60px; width:118px; height:13px; ">출고내역</caption>
  191. <caption id="caption10" style="left:907px; top:52px; width:80px; height:23px; vertical-align:middle; ">출고건수 :</caption>
  192. <output id="ipt_sumdeliveqty" ref="/root/init/deliveqty" class="output_default" style="left:964px; top:54px; width:55px; height:19px; font-weight:bold; text-align:right; "/>
  193. <output id="opt_sumdeliveamt" ref="/root/init/deliveamt" class="output_default" format="#,###" style="left:1104px; top:54px; width:90px; height:19px; font-weight:bold; text-align:right; "/>
  194. <select1 id="cmb_iokindcd" ref="/root/send/nutrdelive/iokindcd" class="combo_s_essential" appearance="minimal" style="left:350px; top:18px; width:135px; height:19px; ">
  195. <choices>
  196. <itemset nodeset="/root/init/ioflag">
  197. <label ref="cdnm"/>
  198. <value ref="cdid"/>
  199. </itemset>
  200. </choices>
  201. <script type="javascript" ev:event="xforms-value-changed">
  202. <![CDATA[
  203. btn_search.dispatch("DOMActivate");
  204. ]]>
  205. </script>
  206. </select1>
  207. <button id="btn_search" class="btn1_letter2" navindex="7" style="left:1120px; top:15px; width:56px; height:22px; text-align:left; ">
  208. <caption>조회</caption>
  209. <script type="javascript" ev:event="DOMActivate">
  210. <![CDATA[
  211. if(fCheckRetrieveData(false) == false)return;
  212. misfGridInit(grd_nutrdelive);
  213. misfMsterDetailRetrieve();
  214. fAfterRetrieve();
  215. ]]>
  216. </script>
  217. </button>
  218. <datagrid id="grd_nutrdelive" nodeset="/root/main/list/nutrdelive/nutrdelivelist" caption="출고일자^출고유형^출고번호^순번^물품코드*^품명^원산지^단가^단위^환산수량^환자식출고수량*^환자식출고수량*^직원식출고수량*^직원식출고수량*^출고금액^출고자|출고일자^출고유형^출고번호^순번^물품코드*^품명^원산지^단가^단위^환산수량^일반식^치료식^직원식^직원야식^출고금액^출고자" colsep="^" colwidth="73, 90, 63, 46, 100, 240, 113, 0, 0, 0, 67, 65, 63, 66, 102, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100" dataheight="25" extendlastcol="scroll" mergecellsfixedrows="bycolrec" rowheader="update" rowheight="25" rowsep="|" style="left:0px; top:82px; width:1195px; height:643px; ">
  219. <col ref="delivedd"/>
  220. <col ref="iokindnm"/>
  221. <col ref="deliveno" style="text-align:center; "/>
  222. <col ref="deliveseqno" style="text-align:center; "/>
  223. <col ref="goodcd"/>
  224. <col ref="goodnm"/>
  225. <col ref="orgloc"/>
  226. <col ref="goodunitcost" visibility="hidden" style="text-align:right; "/>
  227. <col ref="deliveunit" visibility="hidden" style="text-align:center; "/>
  228. <col ref="exchqty" visibility="hidden"/>
  229. <col ref="patmealdeliveqty" format="#,###.#" maxlength="14.1" style="text-align:right; "/>
  230. <col ref="curemealdeliveqty" format="#,###.#" maxlength="14.1" style="text-align:right; "/>
  231. <col ref="empmealdeliveqty" format="#,###.#" maxlength="14.1" style="text-align:right; "/>
  232. <col ref="empnigtmealdeliveqty" format="#,###.#" maxlength="14.1" style="text-align:right; "/>
  233. <col ref="deliveamt" format="#,###" style="text-align:right; "/>
  234. <col ref="delivepsnnm"/>
  235. <col ref="instcd" visibility="hidden"/>
  236. <col ref="goodflag" visibility="hidden"/>
  237. <col ref="iokindcd" visibility="hidden"/>
  238. <col ref="delivedeptcd" visibility="hidden"/>
  239. <col ref="delivepsn" visibility="hidden"/>
  240. <col ref="windeptcd" visibility="hidden"/>
  241. <col ref="reqflag" visibility="hidden"/>
  242. <col ref="delivedeptqty" visibility="hidden"/>
  243. <col ref="predelivedeptqty" visibility="hidden"/>
  244. </datagrid>
  245. <input id="ipt_delivefrdd" ref="/root/send/nutrdelive/delivefrdd" class="input_s_essential" inputtype="date" style="left:760px; top:18px; width:100px; height:19px; ">
  246. <script type="javascript" ev:event="xforms-value-changed">
  247. <![CDATA[
  248. btn_search.dispatch("DOMActivate");
  249. ]]>
  250. </script>
  251. </input>
  252. <input id="ipt_delivetodd" ref="/root/send/nutrdelive/delivetodd" class="input_s_essential" inputtype="date" style="left:879px; top:18px; width:100px; height:19px; ">
  253. <script type="javascript" ev:event="xforms-value-changed">
  254. <![CDATA[
  255. btn_search.dispatch("DOMActivate");
  256. ]]>
  257. </script>
  258. </input>
  259. <caption id="caption11" class="search_n_b" style="left:864px; top:18px; width:15px; height:17px; font-weight:bolder; ">~</caption>
  260. <line id="line2" class="line_4" style="x1:1109px; y1:15px; x2:1109px; y2:42px; "/>
  261. <caption id="caption5" class="search_name" style="left:265px; top:19px; width:86px; height:17px; ">출고유형 :</caption>
  262. <caption id="caption8" class="search_name" style="left:15px; top:19; width:86px; height:17px; ">기관코드 :</caption>
  263. <caption id="caption7" class="search_name" style="left:675px; top:19px; width:86px; height:17px; ">출고일자 :</caption>
  264. <caption id="caption1" style="left:1047px; top:52px; width:80px; height:23px; vertical-align:middle; ">출고합계 :</caption>
  265. </group>
  266. <group id="group1" style="left:0px; top:12; width:1195px; height:27px; ">
  267. <button id="btn_print" class="btn6_letter2" visibility="hidden" style="left:0px; top:3px; width:56px; height:22px; ">
  268. <caption>출력</caption>
  269. </button>
  270. <button id="btn_init" class="btn4_letter3" style="left:1127px; top:3px; width:68px; height:22px; ">
  271. <caption>초기화</caption>
  272. <script type="javascript" ev:event="DOMActivate">
  273. <![CDATA[
  274. fInitialize();
  275. ]]>
  276. </script>
  277. </button>
  278. <line id="line17" class="line_6" style="x1:0px; y1:25; x2:1195px; y2:25px; "/>
  279. </group>
  280. </xhtml:body>
  281. </xhtml:html>