SMDRA00200_보고서-내원체크현황통계.xrw 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224
  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>Untitle</xhtml:title>
  6. <model id="model1">
  7. <instance id="instance1">
  8. <root xmlns="">
  9. <main>
  10. <list>
  11. <msg>
  12. <stationnm/>
  13. <count/>
  14. <chosdd/>
  15. <duration/>
  16. </msg>
  17. </list>
  18. </main>
  19. <send>
  20. <chosdds/>
  21. <chosdde/>
  22. <stationcds/>
  23. <chosddselect/>
  24. </send>
  25. <properties>
  26. <error>
  27. <msg/>
  28. </error>
  29. </properties>
  30. <init>
  31. <station>
  32. <msg>
  33. <stationcd/>
  34. <stationnm/>
  35. </msg>
  36. </station>
  37. </init>
  38. <temp/>
  39. <total>
  40. <totalcount>0</totalcount>
  41. </total>
  42. </root>
  43. </instance>
  44. <script type="javascript" ev:event="xforms-ready">
  45. <![CDATA[
  46. // 당일날짜 세팅
  47. model.setValue("/root/send/chosdds", getCurrentDate());
  48. model.setValue("/root/send/chosdde", getCurrentDate());
  49. submit("TRDRA00102");// 스테이션 명
  50. model.removeNodeset("/root/main/list/msg");
  51. addComboItem("cmb_st");
  52. model.refresh();
  53. ]]>
  54. </script>
  55. <submission id="TRDRA00201" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" replace="instance" resultref="/root/main/list"/>
  56. <submission id="TRDRA00102" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/temp" replace="instance" resultref="/root/init/station"/>
  57. </model>
  58. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  59. <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
  60. <script type="javascript" src="../../../com/authinfoweb/js/ZSA001.js"/>
  61. <script type="javascript" src="../../../com/basiccodeweb/js/ZBC001.js"/>
  62. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  63. </xhtml:head>
  64. <xhtml:body guideline="1,1193;1,1195;2,49;" style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
  65. <group id="group1" style="left:0px; top:0px; width:1194px; height:13px; ">
  66. <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:800px; height:14px; ">내원체크 현황 통계</caption>
  67. </group>
  68. <group id="group3" style="left:0px; top:13px; width:1195px; height:767px; ">
  69. <group id="group2" style="left:0px; top:10px; width:1194px; height:35px; ">
  70. <shape id="roundrect1" class="roundrect_search" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:0px; width:1194px; height:35px; background-color:#fffbf2; border-color:#ffd799; "/>
  71. <caption id="caption1" class="search_name" style="left:335px; top:9px; width:89px; height:17px; ">스테이션명</caption>
  72. <button id="button1" class="btn1_letter2" style="left:1125px; top:7px; width:56px; height:22px; ">
  73. <caption>조회</caption>
  74. <script type="javascript" ev:event="DOMActivate">
  75. <![CDATA[
  76. var chosddsDate = input11.value;
  77. var chosddeDate = input12.value;
  78. if(chosddsDate>chosddeDate){
  79. messageBox("조회하고자 하는 내원일자를 제대로", "C001");
  80. }else if(chosddsDate.length<8 | chosddeDate.length<8){
  81. messageBox("조회하고자 하는 내원일자를 제대로", "C001");
  82. }else{
  83. submit("TRDRA00201");
  84. var vRow = grd_scrnlist.rows;
  85. var totalcount=0;
  86. for(var i = 1; i<vRow; i++){
  87. if((model.getValue("/root/main/list/msg["+i+"]/count"))==""){
  88. totalcount +=0;
  89. }else{
  90. totalcount +=parseInt(model.getValue("/root/main/list/msg["+i+"]/count"));
  91. }
  92. }
  93. model.setValue("/root/total/totalcount", totalcount);
  94. var eatdds = (model.getValue("/root/send/chosdds").toDate("YYYYMMDD")).getDateFormat("YYYY-MM-DD");
  95. var eatdde = (model.getValue("/root/send/chosdde").toDate("YYYYMMDD")).getDateFormat("YYYY-MM-DD");
  96. for(var j=1; j<vRow; j++){
  97. model.setValue("/root/main/list/msg["+j+"]/duration", eatdds+" ~ "+eatdde);
  98. }
  99. model.refresh();
  100. }
  101. ]]>
  102. </script>
  103. </button>
  104. <line id="line2" class="line_4" style="x1:1110px; y1:7px; x2:1110px; y2:27px; border-color:#ffe4bb; border-left-style:solid; "/>
  105. <caption id="caption5" class="search_name" style="left:11px; top:9px; width:84px; height:17px; ">내원일자</caption>
  106. <input id="input11" ref="/root/send/chosdds" class="input_s_essential" inputtype="date" format="yyyy-mm-dd" style="left:105px; top:8px; width:100px; height:19px; ">
  107. <script type="javascript" ev:event="DOMFocusOut">
  108. <![CDATA[
  109. ]]>
  110. </script>
  111. </input>
  112. <input id="input12" ref="/root/send/chosdde" class="input_s_essential" editable="true" inputtype="date" format="yyyy-mm-dd" style="left:220px; top:8px; width:100px; height:19px; "/>
  113. <select1 id="cmb_st" ref="/root/send/stationcds" appearance="minimal" style="left:435px; top:8px; width:100px; height:19px; ">
  114. <choices>
  115. <itemset nodeset="/root/init/station/msg">
  116. <label ref="stationnm"/>
  117. <value ref="stationcd"/>
  118. </itemset>
  119. </choices>
  120. </select1>
  121. <caption id="caption3" class="search_name" style="left:550px; top:9px; width:99px; height:17px; ">기간선택</caption>
  122. <select1 id="combo2" ref="/root/send/chosddselect" appearance="minimal" style="left:630px; top:8px; width:100px; height:19px; ">
  123. <choices>
  124. <item>
  125. <label>- 선택 -</label>
  126. <value/>
  127. </item>
  128. <item>
  129. <label>일</label>
  130. <value>D</value>
  131. </item>
  132. <item>
  133. <label>주</label>
  134. <value>W</value>
  135. </item>
  136. <item>
  137. <label>월</label>
  138. <value>M</value>
  139. </item>
  140. <item>
  141. <label>년</label>
  142. <value>Y</value>
  143. </item>
  144. </choices>
  145. <script type="javascript" ev:event="xforms-select">
  146. <![CDATA[
  147. var chosddSelect = model.getValue("/root/send/chosddselect");
  148. var date2 = (model.getValue("/root/send/chosdde"));
  149. var chosddedate = date2.toDate();
  150. if(chosddSelect =='D'){
  151. model.setValue("/root/send/chosdds" , (chosddedate.getAddDate(0,"D")).getDateFormat());
  152. }else if(chosddSelect =='W'){
  153. model.setValue("/root/send/chosdds" , (chosddedate.getAddDate(-6,"D")).getDateFormat());
  154. }else if(chosddSelect =='M'){
  155. model.setValue("/root/send/chosdds" , (chosddedate.getAddDate(-1,"M")).getDateFormat());
  156. }else if(chosddSelect =='Y'){
  157. model.setValue("/root/send/chosdds" , (chosddedate.getAddDate(-1,"Y")).getDateFormat());
  158. }else{
  159. model.setValue("/root/send/chosdds" ,getCurrentDate());
  160. model.setValue("/root/send/chosdde", getCurrentDate());
  161. }
  162. model.refresh();
  163. ]]>
  164. </script>
  165. </select1>
  166. <caption id="caption7" class="search_no_b" style="left:206px; top:8px; width:15px; height:17px; ">~</caption>
  167. </group>
  168. <caption id="caption2" class="tit_2" style="left:5px; top:60px; width:300px; height:14px; font-family:돋움; vertical-align:middle; ">내원체크 현황 통계</caption>
  169. <line id="line1" class="line_1" style="x1:0px; y1:75px; x2:1194px; y2:75px; "/>
  170. <datagrid id="grd_scrnlist" nodeset="/root/main/list/msg" visibility="visible" caption="스테이션명^내원 환자수^내원일자^기 간" colsep="^" colwidth="227, 143, 125, 204" dataheight="23" defaultrows="1" mergecellsfixedrows="bycolrec" rowheader="seq" rowheight="23" style="left:0px; top:80px; width:1194px; height:660px; ">
  171. <col explorerbar="sortshowmove" ref="stationnm" style="text-align:center; "/>
  172. <col explorerbar="sortshowmove" ref="count" style="left:698px; top:23px; width:386px; height:23px; text-align:center; "/>
  173. <col explorerbar="sortshowmove" ref="chosdd" format="yyyy-mm-dd" style="text-align:center; "/>
  174. <col explorerbar="sortshowmove" ref="duration" visibility="hidden" style="text-align:center; "/>
  175. </datagrid>
  176. <button id="btn_cle" class="btn4_letter3" style="left:1125px; top:745px; width:68px; height:22px; background-image:../../../com/commonweb/images/btn4_letter3.gif; ">
  177. <caption>초기화</caption>
  178. <script type="javascript" ev:event="DOMActivate">
  179. <![CDATA[
  180. model.reset();
  181. model.refresh();
  182. ]]>
  183. </script>
  184. </button>
  185. <button id="button3" class="btn2_letter4" style="left:1070px; top:54px; width:64px; height:19px; ">
  186. <caption>엑셀저장</caption>
  187. <script type="javascript" ev:event="DOMActivate">
  188. <![CDATA[
  189. var dataYn = model.getValue("/root/main/list/msg["+1+"]/count");
  190. if(dataYn == ""){
  191. messageBox("조회된 ", "E013");
  192. return;
  193. }else{
  194. var fileName = window.fileDialog("save",",",false,"보고서-내원체크현황통계","xls","All Files(*.*)|*.*|Excel Files(*.xls)|*.xls");
  195. }
  196. if(fileName !=""){
  197. grd_scrnlist.saveExcel(fileName);
  198. }
  199. ]]>
  200. </script>
  201. </button>
  202. <caption id="caption4" class="search_name" style="left:10px; top:744px; width:112px; height:17px; ">총 내원 환자수</caption>
  203. <button id="btn_print" class="btn6_letter2" style="left:1137px; top:53px; width:56px; height:22px; ">
  204. <caption>출력</caption>
  205. <script type="javascript" ev:event="DOMActivate">
  206. <![CDATA[
  207. var dataYn = model.getValue("/root/main/list/msg["+1+"]/stationnm");
  208. if(dataYn == ""){
  209. messageBox("조회된 ", "E013");
  210. return;
  211. }else{
  212. exeReportPreview("RPDRA00201", "XMLSTR" , "/root/main/list/msg");
  213. }
  214. ]]>
  215. </script>
  216. </button>
  217. <caption id="caption8" style="left:205px; top:745px; width:100px; height:20px; ">명</caption>
  218. <output id="output1" ref="/root/total/totalcount" style="left:130px; top:745px; width:70px; height:19px; text-align:right; "/>
  219. </group>
  220. </xhtml:body>
  221. </xhtml:html>