SMAHA02800_DM발송관리.xrw 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265
  1. <?xml version="1.0" encoding="EUC-KR"?>
  2. <!--
  3. * 제 목 : SMAHA02800.xrw
  4. * 설 명 : DM발송
  5. * 설 계 자 : 최예원
  6. * 작 성 자 : 최예원
  7. * 작 성 일 : 2010.12.15
  8. * 수정이력 : 2010.12.15 최예원 신규
  9. * 기 타 :
  10. -->
  11. <?xml-stylesheet href="../../../com/commonweb/css/common.css" type="text/css" ?>
  12. <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">
  13. <xhtml:head>
  14. <xhtml:title>건진 DM발송관리</xhtml:title>
  15. <model id="model1">
  16. <instance id="instance1">
  17. <root xmlns="">
  18. <main>
  19. <healdminfo>
  20. <healdmlist>
  21. <item/>
  22. </healdmlist>
  23. </healdminfo>
  24. <seqprntdata>
  25. <labelname>
  26. <list>
  27. <pid/>
  28. <hngnm/>
  29. <sexage/>
  30. <orddd/>
  31. </list>
  32. </labelname>
  33. </seqprntdata>
  34. <prntpatlist/>
  35. </main>
  36. <send>
  37. <srchfromdd/>
  38. <srchtodd/>
  39. <srchstate/>
  40. <clscd/>
  41. <etccd/>
  42. <printformat>02</printformat>
  43. </send>
  44. <init>
  45. <combobscdlst/>
  46. <baseinfo>
  47. <detlcodelst/>
  48. </baseinfo>
  49. </init>
  50. <hidden/>
  51. <temp/>
  52. <rexaddprnt/>
  53. </root>
  54. </instance>
  55. <submission id="TRAVB00001"/>
  56. <submission id="TRAHB00602" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" replace="instance" resultref="/root/init/baseinfo/detlcodelst"/>
  57. <submission id="TRAHA02800" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" replace="instance" resultref="/root/main/healdminfo/healdmlist"/>
  58. </model>
  59. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  60. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  61. <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
  62. <script type="javascript" src="../../../ast/tissuebankbaseweb/js/tissuebankcombolist.js"/>
  63. <script type="javascript" src="../../../ast/healexamweb/js/AHA001.js"/>
  64. <script type="javascript" src="../../../com/zipcodeweb/js/ZBP001.js"/>
  65. <script type="javascript" ev:event="xforms-ready">
  66. <![CDATA[
  67. fGetScreenInit();
  68. dtg_healdmlist.fixedcellcheckbox(0 , 1) = true;
  69. ]]>
  70. </script>
  71. <script type="javascript">
  72. <![CDATA[
  73. // 화면 초기화
  74. function fGetScreenInit(){
  75. model.removeNodeset("/root/main/healdminfo/healdmlist/item");
  76. model.setValue("/root/send/srchfromdd" , getCurrentDate());
  77. model.setValue("/root/send/srchtodd" , getCurrentDate());
  78. //공통코드
  79. model.setValue("/root/send/clscd", "G" );
  80. model.setValue("/root/send/etccd", "G16");
  81. submit("TRAHB00602");
  82. //콤포박스 초기화
  83. addComboItem("cmb_state", "전체", "all", "above");
  84. cmb_state.value = "all";
  85. model.refresh();
  86. }
  87. function fGetLabeladdr(){
  88. var nodeList = null;
  89. var nodeList = instance1.selectNodes(dtg_healdmlist.nodeset + "[chk='Y']");
  90. if((nodeList == null) || (nodeList.length < 1)){
  91. messageBox("출력할 내역이 ", "I004");
  92. return ;
  93. }
  94. var vGrd = null;
  95. var printFormat = model.getValue("/root/send/printformat");
  96. var rCSV = getNodeListCSV(nodeList);
  97. model.makeNode("/root/main/seqprntdata/labelname/list/pid");
  98. model.makeNode("/root/main/seqprntdata/labelname/list/hngnm");
  99. model.makeNode("/root/main/seqprntdata/labelname/list/sexage");
  100. model.makeNode("/root/main/seqprntdata/labelname/list/orddd");
  101. model.removenode("/root/main/seqprntdata/labelname/list");
  102. model.setValue("/root/main/seqprntdata/labelname", rCSV);
  103. var CSV = model.getValue("/root/main/seqprntdata/labelname");
  104. model.removenode("/root/main/seqprntdata/labelname");
  105. model.makeNode("/root/main/seqprntdata/labelname");
  106. setCSVToNode("/root/main/seqprntdata/labelname", CSV);
  107. model.refresh();
  108. nodeList= null;
  109. nodeList= instance1.selectNodes("/root/main/seqprntdata/item");
  110. if((nodeList != null)||(nodeList.length >0 )){
  111. if(printFormat == "01") {
  112. exeReportPreview("RPAHA00410", "XMLSTR" , "" , "" , "false" , "", "", "", "", "fasle");
  113. }else if(printFormat == "02") {
  114. exeReportPreview("RPAHA00411", "XMLSTR" , "" , "" , "false" , "", "", "", "", "fasle");
  115. }
  116. }
  117. }
  118. ]]>
  119. </script>
  120. </xhtml:head>
  121. <xhtml:body guideline="1,1194;2,784;" style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
  122. <group id="grp_tle" style="left:0px; top:0px; width:1195px; height:13px; ">
  123. <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:210px; height:14px; ">DM 발송관리</caption>
  124. </group>
  125. <group id="grp_biz" scroll="auto" style="left:0px; top:13px; width:1195px; height:744px; ">
  126. <caption id="caption1" class="tit_2" style="left:5px; top:56px; width:210px; height:14px; ">DM 발송 LIST</caption>
  127. <line id="line1" class="line_1" style="x1:0px; y1:71px; x2:1194px; y2:71px; "/>
  128. <datagrid id="dtg_healdmlist" nodeset="/root/main/healdminfo/healdmlist/item" scroll="auto" caption="^등록번호^환자명^주민번호^전화번호^핸드폰번호^우편번호^주소^누적횟수^마지막검진일" colsep="^" colwidth="25, 80, 70, 100, 100, 100, 80, 278, 55, 255" dataheight="23" ellipsis="true" explorerbar="sortshow" focuscolor="#b9e5fb" mergecellsfixedrows="bycolrec" rowheader="seq" rowheight="23" rowsep="|" tooltip="true" style="left:0px; top:75px; width:1194px; height:664px; text-align:center; ">
  129. <col checkvalue="Y,N" ref="chk" type="checkbox"/>
  130. <col ref="pid" type="output"/>
  131. <col ref="hngnm" type="output"/>
  132. <col ref="rrgstno" type="output"/>
  133. <col ref="telno" type="output"/>
  134. <col ref="mpphon" type="output"/>
  135. <col ref="zipcode" type="output" format="999-999"/>
  136. <col ref="address" type="output" style="text-align:left; "/>
  137. <col ref="accnum" type="output" style="text-align:center; "/>
  138. <col ref="testnm" type="output" format="yyyy-mm-dd" style="text-align:left; "/>
  139. <script type="javascript" ev:event="onaftersort">
  140. <![CDATA[
  141. dtg_healdmlist.gridtoinstance();
  142. ]]>
  143. </script>
  144. <script type="javascript" ev:event="onmouseup">
  145. <![CDATA[
  146. if(isDataCell()){
  147. for(var i=1; i<dtg_healdmlist.rows; i++){
  148. model.setValue("/root/main/healdminfo/healdmlist/item[" + i + "]/chk", "N");
  149. }
  150. for(var i=0; i<dtg_healdmlist.selectedRows;i++){
  151. model.setValue("/root/main/healdminfo/healdmlist/item[" + dtg_healdmlist.selectedRow(i) + "]/chk", "Y");
  152. }
  153. }
  154. ]]>
  155. </script>
  156. </datagrid>
  157. <group id="grp_sea" style="left:0px; top:10px; width:1194px; height:35px; vertical-align:top; ">
  158. <shape id="roundrect1" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:0px; width:1194px; height:35px; background-color:#fffbf2; border-color:#ffd799; "/>
  159. <caption id="caption2" class="search_name" style="left:15px; top:9px; width:86px; height:17px; ">조회조건 :</caption>
  160. <caption id="caption5" class="search_no_b" style="left:485px; top:9px; width:12px; height:17px; ">~</caption>
  161. <line id="line13" class="line_4" style="x1:1107px; y1:7px; x2:1107px; y2:29px; "/>
  162. <input id="ipt_fromdd" ref="/root/send/srchfromdd" class="input_s_essential" inputtype="date" style="left:382px; top:8px; width:100px; height:19px; "/>
  163. <input id="ipt_todd" ref="/root/send/srchtodd" class="input_s_essential" inputtype="date" style="left:500px; top:8px; width:100px; height:19px; "/>
  164. <button id="btn_sea" class="btn1_letter2" style="left:1123px; top:7px; width:56px; height:22px; ">
  165. <caption>조회</caption>
  166. <script type="javascript" ev:event="DOMActivate">
  167. <![CDATA[
  168. if(model.getValue("/root/send/srchstate") == "" || model.getValue("/root/send/srchstate") == "all"){
  169. messageBox("조회조건을", "C002");
  170. return;
  171. }
  172. submit("TRAHA02800");
  173. model.refresh();
  174. ]]>
  175. </script>
  176. </button>
  177. <caption id="caption3" class="search_name" style="left:290px; top:9px; width:86px; height:17px; ">발송일자 :</caption>
  178. <select1 id="cmb_state" ref="/root/send/srchstate" class="combo_search" appearance="minimal" style="left:110px; top:8px; width:150px; height:19px; ">
  179. <choices>
  180. <itemset nodeset="/root/init/baseinfo/detlcodelst/item">
  181. <label ref="etcdetlnm"/>
  182. <value ref="etcdetlcd"/>
  183. </itemset>
  184. </choices>
  185. </select1>
  186. </group>
  187. <button id="btn_excsave" class="btn2_letter4" style="left:1129px; top:50px; width:64px; height:19px; ">
  188. <caption>엑셀저장</caption>
  189. <script type="javascript" ev:event="DOMActivate">
  190. <![CDATA[
  191. var filename = window.fileDialog("save",",",false,"excel","xls","All File(*.*)|*.*|Excel File(*.xls)|*.xls");
  192. if (filename != ""){
  193. dtg_healdmlist.saveExcel(filename);
  194. }
  195. ]]>
  196. </script>
  197. </button>
  198. </group>
  199. <group id="grp_btn" style="left:0px; top:757px; width:1195px; height:27px; ">
  200. <button id="btn_prt" class="btn6_letter2" style="left:0px; top:4px; width:56px; height:22px; ">
  201. <caption>출력</caption>
  202. <script type="javascript" ev:event="DOMActivate">
  203. <![CDATA[
  204. fGetLabeladdr()
  205. ]]>
  206. </script>
  207. </button>
  208. <select1 id="combo2" ref="/root/send/printformat" appearance="minimal" style="left:60px; top:5px; width:100px; height:19px; ">
  209. <choices>
  210. <item>
  211. <label>2x5</label>
  212. <value>01</value>
  213. </item>
  214. <item>
  215. <label>2x8</label>
  216. <value>02</value>
  217. </item>
  218. </choices>
  219. </select1>
  220. <button id="button1" class="btn6_letter7" style="left:164px; top:4px; width:116px; height:22px; ">
  221. <caption>추후검사 출력</caption>
  222. <script type="javascript" ev:event="DOMActivate">
  223. <![CDATA[
  224. //2011.01.20 c y w 추후검사 우편물 발송 출력기능 추가.
  225. //추후검사일 경우에만..
  226. if(model.getValue("/root/send/srchstate") == "07" || model.getValue("/root/send/srchstate") == "08" || model.getValue("/root/send/srchstate") == "09"){
  227. var idx = 1;
  228. var cnt = getNodesetCount("/root/main/healdminfo/healdmlist/item");
  229. for(i=1; i<=cnt; i++){
  230. if(model.getValue("/root/main/healdminfo/healdmlist/item[" + i + "]/chk") == "Y"){
  231. model.makeValue("/root/rexaddprnt/item["+ idx +"]/pid" , model.getValue("/root/main/healdminfo/healdmlist/item["+ i +"]/pid"));
  232. model.makeValue("/root/rexaddprnt/item["+ idx +"]/hngnm" , model.getValue("/root/main/healdminfo/healdmlist/item["+ i +"]/hngnm"));
  233. model.makeValue("/root/rexaddprnt/item["+ idx +"]/rrgstno" , model.getValue("/root/main/healdminfo/healdmlist/item["+ i +"]/rrgstno"));
  234. model.makeValue("/root/rexaddprnt/item["+ idx +"]/zipcode" , model.getValue("/root/main/healdminfo/healdmlist/item["+ i +"]/zipcode"));
  235. model.makeValue("/root/rexaddprnt/item["+ idx +"]/address" , model.getValue("/root/main/healdminfo/healdmlist/item["+ i +"]/address"));
  236. model.makeValue("/root/rexaddprnt/item["+ idx +"]/testnm" , model.getValue("/root/main/healdminfo/healdmlist/item["+ i +"]/testnm"));
  237. idx++;
  238. }
  239. }
  240. var instcd = getUserInfo("dutplceinstcd");
  241. if (instcd == "031"){
  242. exeReportPreview("RPAHA02800", "XMLSTR" , "" , "" , "true" , "", "", "", "", "true");
  243. }else{
  244. exeReportPreview("RPAHA02801", "XMLSTR" , "" , "" , "true" , "", "", "", "", "true");
  245. }
  246. model.removeNodeset("/root/rexaddprnt");
  247. }else{
  248. messageBox("추후검사일 경우에만", "I006");
  249. }
  250. model.refresh();
  251. ]]>
  252. </script>
  253. </button>
  254. </group>
  255. </xhtml:body>
  256. </xhtml:html>