fee_search.html 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115
  1. <!DOCTYPE html>
  2. <html xmlns:th="http://www.thymeleaf.org">
  3. <div th:replace="~{mobile/header :: header}"></div>
  4. <script>
  5. $(function(){
  6. getFee();
  7. bindList();
  8. });
  9. function getFee(){
  10. $.ajax({
  11. type: "GET",
  12. dataType: "json",
  13. url: pagePath + "/mobile/fee/searchList",
  14. data: {
  15. "timestamp": new Date().getTime()
  16. },
  17. success: function (result) {
  18. if (result.success) {
  19. bindList(result.obj.feeList);
  20. } else {
  21. alert(result.message);
  22. }
  23. },
  24. error: function () {
  25. alert("系统错误!");
  26. //errorMessage('系统错误!');
  27. }
  28. });
  29. }
  30. function bindList(list){
  31. if (list) {
  32. $("#feeList li").remove();
  33. for (var i = 0; i < list.length; i++) {
  34. var fee=list[i];
  35. var li='<li>';
  36. li+='<div class="data">'+fee.fee_type+'</div>';
  37. li+='<div class="data">';
  38. //水费
  39. li+='<div class="cell">';
  40. li+='<span>'+fee.total_fee+'元</span>';
  41. if(fee.is_paid=="1"){
  42. li+='<span style="color:black;" class="status">已缴费</span>';
  43. }else{
  44. li+='<span style="color:red;" class="status">未缴费</span>';
  45. }
  46. li+='</div>';
  47. li+='<div class="data">';
  48. if(fee.fee_type=="水费"||fee.fee_type=="电费"){
  49. li+='<span>抄表日期:</span>';
  50. }else{
  51. li+='<span>应缴费日期:</span>';
  52. }
  53. li+=fee.pay_time+'</div>';
  54. li+='</div>';
  55. li+='</div>';
  56. li+='</li>';
  57. var $li = $(li);
  58. $("#feeList").append($li);
  59. }
  60. }
  61. }
  62. </script>
  63. <body>
  64. <header>
  65. <a class="back" href="javascript:history.go(-1);"> <i class="iconfont icon-fanhui"></i></a>
  66. <span >费用查询</span>
  67. </header>
  68. <!-- 内容 -->
  69. <section class="content has_header">
  70. <div class="list">
  71. <ul id="feeList">
  72. </ul>
  73. </div>
  74. </section>
  75. <div class="bottom-fxied">
  76. <footer>
  77. <span>
  78. <a th:href="@{/mobile/home}" >
  79. <i class="iconfont icon-shouye"></i>
  80. <div>首页</div>
  81. </a>
  82. </span>
  83. <span>
  84. <a th:href="@{/mobile/company/companyPage}" >
  85. <i class="iconfont icon-enterprise"></i>
  86. <div>产品</div>
  87. </a>
  88. </span>
  89. <span>
  90. <a th:href="@{/mobile/service}" class="active">
  91. <i class="iconfont icon-msnui-service"></i>
  92. <div>服务</div>
  93. </a>
  94. </span>
  95. <span>
  96. <a th:href="@{/mobile/login}">
  97. <i class="iconfont icon-wo"></i>
  98. <div>我</div>
  99. </a>
  100. </span>
  101. </footer>
  102. </div>
  103. </body>
  104. </html>