flist3.html 6.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166
  1. {extend name="common/common2" /}
  2. {block name="main"}
  3. <div class="ibox">
  4. <div class="ibox-content">
  5. <div class="row">
  6. <div class="col-xs-12" style="text-align: right;">
  7. <form class="form-inline" id="form-search" action="{:url('flist3')}">
  8. <div class="input-group">
  9. <input type="text" class="form-control" name="sn" placeholder="单据号">
  10. </div>
  11. <div class="input-group">
  12. <input type="text" class="form-control" name="area_title" placeholder="小区">
  13. </div>
  14. <div class="input-group">
  15. <input type="text" class="form-control" name="title" placeholder="名称">
  16. </div>
  17. <div class="input-group">
  18. <input type="text" class="form-control" name="name" placeholder="业主">
  19. </div>
  20. <div class="input-group">
  21. <input class="form-control" id="start" readonly placeholder="开始时间" name="start" >
  22. </div>
  23. <div class="input-group">
  24. <input class="form-control" id="end" readonly placeholder="结束时间" name="end" >
  25. </div>
  26. <div class="input-group">
  27. <input class="form-control" id="wstart" readonly placeholder="周期开始时间" name="wstart" >
  28. </div>
  29. <div class="input-group">
  30. <input class="form-control" id="wend" readonly placeholder="周期结束时间" name="wend" >
  31. </div>
  32. </br>
  33. </br>
  34. <div class="input-group">
  35. <select name="cate" class="form-control">
  36. <option value="">资源属性</option>
  37. <option value="1">住房</option>
  38. <option value="2">商铺</option>
  39. <option value="3">营业房</option>
  40. <option value="4">储藏室</option>
  41. <option value="5">停车位</option>
  42. </select>
  43. </div>
  44. <div class="input-group">
  45. <select name="fee" class="form-control">
  46. <option value="">收费科目</option>
  47. {foreach $fee as $k=>$v}
  48. <option value="{$v['id']}">[{$v['parent_title']}]{$v['title']}</option>
  49. {/foreach}
  50. </select>
  51. </div>
  52. <div class="input-group">
  53. <select name="c_type" class="form-control">
  54. <option value="">类型</option>
  55. {foreach $cType as $k=>$v}
  56. <option value="{$v['id']}">{$v['name']}</option>
  57. {/foreach}
  58. </select>
  59. </div>
  60. </br>
  61. </br>
  62. <div class="input-group">
  63. <span class="input-group-btn">
  64. <button class="btn-sm btn-primary" type="button" id ="search-btn" ><i class="fa fa-search"></i></button>
  65. </span> &nbsp;
  66. <span class="input-group-btn">
  67. <button class="btn-sm btn-warning" type="button" id="search-clear"><i class="fa fa-undo"></i></button>
  68. </span>&nbsp;
  69. <span class="input-group-btn">
  70. <button class="btn-sm btn-primary" data-url="{:url('fexport3')}" type="button" id ="export" ><i class="fa fa-download"></i></button>
  71. </span>
  72. </div>
  73. </form>
  74. </div>
  75. </div>
  76. </div>
  77. <div class="ibox-content">
  78. <div class="jqGrid_wrapper">
  79. <table id="table" style="border-collapse: collapse"></table>
  80. <div id="pager"></div>
  81. </div>
  82. </div>
  83. </div>
  84. {/block}
  85. {block name="script"}
  86. <script src="/static/layDate-v5.0.9/laydate.js"></script>
  87. <script>
  88. $(function () {
  89. laydate.render({
  90. elem: '#start',
  91. trigger: 'click' ,
  92. theme: '#284a94'
  93. });
  94. laydate.render({
  95. elem: '#end',
  96. trigger: 'click' ,
  97. theme: '#284a94'
  98. });
  99. laydate.render({
  100. elem: '#wstart',
  101. trigger: 'click' ,
  102. theme: '#284a94'
  103. });
  104. laydate.render({
  105. elem: '#wend',
  106. trigger: 'click' ,
  107. theme: '#284a94'
  108. });
  109. $(window).bind("resize",function(){
  110. var width=$(".jqGrid_wrapper").width();
  111. $("#table").setGridWidth(width);
  112. });
  113. $.jgrid.defaults.styleUI="Bootstrap";
  114. $("#table").jqGrid({
  115. url:"{:url('flist3',[],'')}",
  116. datatype: "json",
  117. colModel:[
  118. {label:'单据号',name:'sn',index:'sn', width:40,sortable: false},
  119. {label:'业主',name:'name',index:'name',width:30,editable: false,sortable: false},
  120. {label:'小区',name:'area_title',index:'area_title',width:30,editable: false,sortable: false},
  121. {label:'资源名称',name:'title',index:'title',width:30,editable: false,sortable: false},
  122. {label:'资源属性',name:'cate_name',index:'cate_name',width:30,editable: false,sortable: false},
  123. {label:'类型',name:'c_type_name',index:'c_type_name',width:30,editable: false,sortable: false},
  124. {label:'收费科目',name:'fee_title',index:'fee_title',width:30,editable: false,sortable: false},
  125. {label:'金额',name:'money',index:'money',width:30,editable: false,sortable: false},
  126. {label:'起止日期',name:'end',index:'end',width:50,editable: false,sortable: false,formatter:function (a,b,c){
  127. return c.start+'-'+c.end;
  128. }},
  129. {label:'备注',name:'remark',index:'remark',width:40,editable: false,sortable: false},
  130. {label:'创建日期',name:'create_time',index:'create_time',width:50,editable: false,sortable: false},
  131. ],
  132. rowNum:10,
  133. rowList:[10,20,30,50,100],
  134. pager: '#pager',
  135. sortname: 'id',
  136. viewrecords: true,
  137. autowidth:true,
  138. mtype: 'post',
  139. height: 'auto',
  140. emptyrecords: "暂无数据",
  141. sortorder: "desc",
  142. caption:"子级收费报表",
  143. loadComplete: function (xhr) {
  144. if(xhr.code==0){
  145. layer.msg(xhr.msg);
  146. return false;
  147. }
  148. var zje = xhr.zje;
  149. $('#pager_left').html('<span style="color:red;font-size: 10px;">总金额:'+zje+' 元');
  150. },
  151. });
  152. });
  153. </script>
  154. {/block}