self_flist2.html 8.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195
  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('selfFlist2',[],'')}/id/{$id}">
  8. <div class="input-group">
  9. <input type="text" class="form-control" name="area_title" placeholder="小区">
  10. </div>
  11. <div class="input-group">
  12. <input type="text" class="form-control" name="title" placeholder="名称">
  13. </div>
  14. <div class="input-group">
  15. <input type="text" class="form-control" name="name" placeholder="业主">
  16. </div>
  17. <div class="input-group">
  18. <input class="form-control" id="start" readonly placeholder="开始时间" name="start" >
  19. </div>
  20. <div class="input-group">
  21. <input class="form-control" id="end" readonly placeholder="结束时间" name="end" >
  22. </div>
  23. <div class="input-group">
  24. <input class="form-control" id="wstart" readonly placeholder="周期开始时间" name="wstart" >
  25. </div>
  26. <div class="input-group">
  27. <input class="form-control" id="wend" readonly placeholder="周期结束时间" name="wend" >
  28. </div>
  29. <div class="input-group">
  30. <select name="cate" class="form-control">
  31. <option value="">资源属性</option>
  32. <option value="1">住房</option>
  33. <option value="2">商铺</option>
  34. <option value="3">营业房</option>
  35. <option value="4">储藏室</option>
  36. <option value="5">停车位</option>
  37. </select>
  38. </div>
  39. </br>
  40. </br>
  41. <div class="input-group">
  42. <select name="fee" class="form-control">
  43. <option value="">收费科目</option>
  44. {foreach $fee as $k=>$v}
  45. <option value="{$v['id']}">[{$v['parent_title']}]{$v['title']}</option>
  46. {/foreach}
  47. </select>
  48. </div>
  49. <div class="input-group">
  50. <select name="c_type" class="form-control">
  51. <option value="">类型</option>
  52. {foreach $cType as $k=>$v}
  53. <option value="{$v['id']}">{$v['name']}</option>
  54. {/foreach}
  55. </select>
  56. </div>
  57. <div class="input-group">
  58. <select name="status" class="form-control">
  59. <option value="">状态</option>
  60. <option value="0">已拒绝</option>
  61. <option value="1">退款中</option>
  62. <option value="2">已退款</option>
  63. </select>
  64. </div>
  65. </br>
  66. </br>
  67. <div class="input-group">
  68. <span class="input-group-btn">
  69. <button class="btn-sm btn-primary" type="button" id ="search-btn" ><i class="fa fa-search"></i></button>
  70. </span> &nbsp;
  71. <span class="input-group-btn">
  72. <button class="btn-sm btn-warning" type="button" id="search-clear"><i class="fa fa-undo"></i></button>
  73. </span>&nbsp;
  74. <span class="input-group-btn">
  75. <button class="btn-sm btn-primary" data-url="{:url('selfFexport2',[],'')}/id/{$id}" type="button" id ="export" ><i class="fa fa-download"></i></button>
  76. </span>
  77. </div>
  78. </form>
  79. </div>
  80. </div>
  81. </div>
  82. <div class="ibox-content">
  83. <div class="jqGrid_wrapper">
  84. <table id="table" style="border-collapse: collapse"></table>
  85. <div id="pager"></div>
  86. </div>
  87. </div>
  88. </div>
  89. {/block}
  90. {block name="script"}
  91. <script src="/static/layDate-v5.0.9/laydate.js"></script>
  92. <script>
  93. $(function () {
  94. laydate.render({
  95. elem: '#start',
  96. trigger: 'click' ,
  97. theme: '#148d8f'
  98. });
  99. laydate.render({
  100. elem: '#end',
  101. trigger: 'click' ,
  102. theme: '#148d8f'
  103. });
  104. laydate.render({
  105. elem: '#wstart',
  106. trigger: 'click' ,
  107. theme: '#148d8f'
  108. });
  109. laydate.render({
  110. elem: '#wend',
  111. trigger: 'click' ,
  112. theme: '#148d8f'
  113. });
  114. $(window).bind("resize",function(){
  115. var width=$(".jqGrid_wrapper").width();
  116. $("#table").setGridWidth(width);
  117. });
  118. $.jgrid.defaults.styleUI="Bootstrap";
  119. $("#table").jqGrid({
  120. url:"{:url('selfFlist2',[],'')}/id/{$id}",
  121. datatype: "json",
  122. colModel:[
  123. {label:'业主',name:'name',index:'name',width:30,editable: false,sortable: false},
  124. {label:'小区',name:'area_title',index:'area_title',width:30,editable: false,sortable: false},
  125. {label:'资源名称',name:'title',index:'title',width:30,editable: false,sortable: false},
  126. {label:'资源属性',name:'cate_name',index:'cate_name',width:30,editable: false,sortable: false},
  127. {label:'类型',name:'c_type_name',index:'c_type_name',width:30,editable: false,sortable: false},
  128. {label:'退费科目',name:'fee_title',index:'fee_title',width:30,editable: false,sortable: false},
  129. {label:'退费金额',name:'money',index:'money',width:30,editable: false,sortable: false},
  130. {label:'起止日期',name:'end',index:'end',width:50,editable: false,sortable: false,formatter:function (a,b,c){
  131. return c.start+'-'+c.end;
  132. }},
  133. {label:'备注',name:'remark',index:'remark',width:40,editable: false,sortable: false},
  134. {label:'状态',name:'status',index:'status',width:30,editable: false,sortable: false,formatter:function (a,b,c){
  135. if(a===0){
  136. return '已拒绝';
  137. }else if(a===1){
  138. return '退款中';
  139. }else {
  140. return '已退款';
  141. }
  142. }},
  143. {label:'退款原因',name:'reason',index:'reason',width:40,editable: false,sortable: false},
  144. {label:'退款姓名',name:'refund_name',index:'refund_name',width:40,editable: false,sortable: false},
  145. {label:'退款账号',name:'refund_account',index:'refund_account',width:40,editable: false,sortable: false},
  146. {label:'退款卡号',name:'refund_bank',index:'refund_bank',width:40,editable: false,sortable: false},
  147. {label:'凭证',name:'voucher',index:'voucher',width:30,editable: false,sortable: false,formatter:function (a,b,c){
  148. if(a){
  149. return '<img src="'+a+'" width="60" onclick="open_img(this)"></img>';
  150. }else {
  151. return '';
  152. }
  153. }},
  154. {label:'创建日期',name:'refund_time',index:'refund_time',width:50,editable: false,sortable: false},
  155. {label:'操作',width:60,sortable: false,formatter: function (a, b, c) {
  156. var flist2Print_url = "{:url('flist2Print',[],'')}/id/"+c.id;
  157. var btn = '';
  158. btn+= '<a href="'+flist2Print_url+'" ><span class="label label-primary" >打印</span></a>';
  159. return btn;
  160. }},
  161. ],
  162. rowNum:10,
  163. rowList:[10,20,30,50,100],
  164. pager: '#pager',
  165. sortname: 'id',
  166. viewrecords: true,
  167. autowidth:true,
  168. mtype: 'post',
  169. height: 'auto',
  170. emptyrecords: "暂无数据",
  171. sortorder: "desc",
  172. caption:"{$m_name}",
  173. loadComplete: function (xhr) {
  174. if(xhr.code==0){
  175. layer.msg(xhr.msg);
  176. return false;
  177. }
  178. var zje = xhr.money;
  179. $('#pager_left').html('<span style="color:red;font-size: 10px;">总金额:'+zje.toFixed(2)+' 元');
  180. },
  181. });
  182. });
  183. </script>
  184. {/block}