invoicePaper.html 8.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278
  1. <!-- include 'header' -->
  2. <link rel=stylesheet href="<?= WEB_SITE_GLOBAL ?>css/jquery.validator.css">
  3. <script type="text/javascript" src="<?= WEB_SITE_GLOBAL ?>js/jquery.validator.min.js"></script>
  4. <script type="text/javascript" src="<?= WEB_SITE_GLOBAL ?>js/zh-CN.js"></script>
  5. <script src="<?= WEB_SITE_GLOBAL ?>js/invoice.validator.js"></script>
  6. <script src="<?= WEB_SITE_GLOBAL ?>js/invoice.js"></script>
  7. <link rel=stylesheet href="<?= WEB_SITE_GLOBAL ?>js/DataTables/jquery.dataTables.css">
  8. <script type="text/javascript" src="<?= WEB_SITE_GLOBAL ?>js/DataTables/jquery.dataTables.min.js"></script>
  9. <script type="text/javascript" src="<?= WEB_SITE_GLOBAL ?>js/dataTables.fixedColumns.min.js"></script>
  10. <link href="<?= WEB_SITE_GLOBAL ?>css/datepicker.min.css" rel="stylesheet" type="text/css">
  11. <script src="<?= WEB_SITE_GLOBAL ?>js/datepicker.min.js"></script>
  12. <script src="<?= WEB_SITE_GLOBAL ?>js/datepicker.zh.js"></script>
  13. <body>
  14. <div class="mainLayout">
  15. <div class="mainMenu">
  16. <div class="menuItem">
  17. <a href="#" class="mLogo">CLD</a>
  18. <ul>
  19. <!-- include 'menuReceipt' -->
  20. </ul>
  21. </div>
  22. </div>
  23. <div class="warpContent">
  24. <div class="subMenu fL">
  25. <div class="menuItem">
  26. <!-- include 'invoiceMenu' -->
  27. </div>
  28. </div>
  29. <div class="adminContent autoHeight">
  30. <legend>
  31. 纸质发票</legend>
  32. <div class="demandCate">
  33. <form action="/invoicePaper" id="iaa" method="get" >
  34. <ul class="cateList">
  35. <li>
  36. <select name="invoiceType" node-invoiceType class="select">
  37. <option <!-- if {{invoiceType}}=='ALL' --> selected <!-- endif --> value="ALL">全部</option>
  38. <option <!-- if {{invoiceType}}=='ORDINARY' --> selected <!-- endif --> value="ORDINARY" >普通发票</option>
  39. <option <!-- if {{invoiceType}}=='SPECIAL' --> selected <!-- endif --> value="SPECIAL" >专用发票</option>
  40. </select>
  41. </li>
  42. <li><select name="status" node-invoiceType class="select">
  43. <option <!-- if {{status}}=='ALL' --> selected <!-- endif --> value="ALL" >全部</option>
  44. <option <!-- if {{status}}=='PRINTED' --> selected <!-- endif --> value="PRINTED" >已打印</option>
  45. <option <!-- if {{status}}=='UNPRINT' --> selected <!-- endif --> value="UNPRINT" >未打印</option>
  46. <option <!-- if {{status}}=='TICKET' --> selected <!-- endif --> value="TICKET" >退票</option>
  47. </select>
  48. </li>
  49. <li>
  50. <div class="search">
  51. <div class="input-append">
  52. <input class="datepicker-here span3" name="date" value="{{dateString}}" placeholder="按时间筛选" type="text" data-range="true" data-multiple-dates-separator=" : " data-language="zh">
  53. <button class="btn btn-small" type="submit">查询</button>
  54. </div>
  55. </div>
  56. </li>
  57. <li>
  58. <a class="button" href="#addpaper" data-toggle="modal">生成纸质发票</a>
  59. </li>
  60. </ul>
  61. </form>
  62. </div>
  63. <div class="saeaList">
  64. <table id="example" class="stripe row-border order-column" cellspacing="0" width="2400" >
  65. <thead>
  66. <tr class="thead">
  67. <th>操作</th>
  68. <th>发票代码</th>
  69. <th>发票号</th>
  70. <th>开票流水号</th>
  71. <th>开票单位(抬头)</th>
  72. <th>开票金额</th>
  73. <th>开票内容</th>
  74. <th>发票申请人</th>
  75. <th>打印时间</th>
  76. </tr>
  77. </thead>
  78. <tbody>
  79. </tbody>
  80. </table>
  81. </div>
  82. </div>
  83. </div>
  84. </div>
  85. <!--弹出 纸质-->
  86. <div class="modal hide fade" id="addpaper">
  87. <form action="/invoicePaperAdd" id="IPA" method="post">
  88. <div class="modal-dialog ">
  89. <div class="modal-content">
  90. <div class="modal-header">
  91. <h3>生成纸质发票</h3>
  92. </div>
  93. <div class="modal-body saeaList">
  94. <table class="table table-bordered table-condensed">
  95. <tbody>
  96. <tr>
  97. <th colspan="2" class="taC">填写生成规则</th>
  98. </tr>
  99. <tr>
  100. <th class="taC" width="100"><span class="colRed">*</span>发票类型</th>
  101. <td>
  102. <label for="invoicePlain" class="radio inline"><input type="radio" checked name="invoiceType" value="0" data-rule="checked" >增值税普通发票</label>
  103. <label for="invoiceSpecial" class="radio inline"><input type="radio" name="invoiceType" value="1" >增值税专用发票</label>
  104. </td>
  105. </tr>
  106. <tr>
  107. <th class="taC" width="100"><span class="colRed">*</span>发票代码</th>
  108. <td><input type="number" name="invoiceCode" id="invoiceCode" value=""></td>
  109. </tr>
  110. <tr>
  111. <th class="taC" width="100"><span class="colRed">*</span>起始编号</th>
  112. <td><input type="number" name="invoiceNoStart" id="invoiceNoStart" value=""></td>
  113. </tr>
  114. <tr>
  115. <th class="taC" width="100"><span class="colRed">*</span>发票数量</th>
  116. <td><input type="number" name="invoiceNoTotal" id="invoiceNoTotal" step="1"></td>
  117. </tr>
  118. <tr>
  119. <th class="taC" width="100">末张编号</th>
  120. <td><input value="" id="invoiceNoEnd" disabled type="text"></td>
  121. </tr>
  122. </tbody>
  123. </table>
  124. </div>
  125. <div class="modal-footer">
  126. <input type="submit" class="button" value="确认生成">
  127. <a href="#" class="button btn-gray" data-dismiss="modal" aria-hidden="true">关闭</a>
  128. </div>
  129. </div></div>
  130. </form>
  131. </div>
  132. <div loading-msg='true' style="position:absolute; left:50%; top:50%; "></div>
  133. <div class="modal fade" id="approvalInvice">
  134. <div id="nc"></div>
  135. </div>
  136. <!--退票-->
  137. <script type="text/javascript">autoFlashHeight();</script>
  138. <script type="text/javascript">
  139. $(document).ready( function () {
  140. var table =$('#example').DataTable({
  141. language: {
  142. "sProcessing": "处理中...",
  143. "sLengthMenu": "显示 _MENU_ 项结果",
  144. "sSearch": "搜索:",
  145. "sInfoEmpty": "显示第 0 至 0 项结果,共 0 项",
  146. "sEmptyTable": "表中数据为空",
  147. "oPaginate": {
  148. "sFirst": "首页",
  149. "sPrevious": "上页",
  150. "sNext": "下页",
  151. "sLast": "末页"
  152. },
  153. "sInfo": "显示第 _START_ 至 _END_ 项结果,共 _TOTAL_ 项",
  154. },
  155. "paging": false,
  156. "ordering": false,
  157. "info": false,
  158. //'filter':false,
  159. scrollY: "700px",
  160. scrollX: true,
  161. scrollCollapse: true,
  162. paging: true,
  163. serverSide: true,
  164. ajax: {
  165. url: '/ajaxGetinvoicePaperAchieve',
  166. type: 'POST',
  167. "data": function ( d ) {
  168. return $.extend( {}, d, {
  169. "status": '{{status}}',
  170. 'invoiceType':'{{invoiceType}}',
  171. 'date':'{{dateString}}',
  172. } );
  173. }
  174. }
  175. });
  176. setSearchLo('invoicepaper');
  177. } );
  178. function nodeInvoiceApproval(iidKey){
  179. var postData = iidKey;
  180. var type =$(this).attr("data-type");
  181. $("#nc").html('');
  182. $("div[loading-msg='true']").html("<img src='/global/img/loadIco.gif' />");
  183. var url = "/ajaxGetInvoiceApprovalDetail";
  184. $.ajax({
  185. url : url,
  186. type : "post",
  187. cache : false,
  188. dataType : "json",
  189. data : {
  190. serial : postData
  191. },
  192. global : true,
  193. success : function(data) {
  194. if (data.status == 1) {
  195. $("#nc").html(data.html);
  196. } else
  197. $("div[loading-msg='true']").html("illegal request");
  198. },
  199. error : function(err) {
  200. $("div[loading-msg='true']").html("");
  201. }
  202. });
  203. }
  204. function nodeInvoice(iidKey){
  205. var postData = iidKey;
  206. var type =$(this).attr("data-type");
  207. $("#nc").html('');
  208. var po='INVOICE';
  209. $("div[loading-msg='true']").html("<img src='/global/img/loadIco.gif' />");
  210. var url = "/ajaxGetInvoiceInfoByType";
  211. $.ajax({
  212. url : url,
  213. type : "post",
  214. cache : false,
  215. dataType : "json",
  216. data : {
  217. serial : postData,
  218. type:po
  219. },
  220. global : true,
  221. success : function(data) {
  222. if (data.status == 1) {
  223. $("div[loading-msg='true']").html("");
  224. if(type=='receivables')
  225. $("#nr").html(data.html);
  226. else
  227. $("#nc").html(data.html);
  228. } else
  229. $("div[loading-msg='true']").html("illegal request");
  230. },
  231. error : function(err) {
  232. $("div[loading-msg='true']").html("");
  233. }
  234. });
  235. }
  236. </script>
  237. </body>