No Description

districtRoi45day.blade.php 8.0KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151
  1. @extends('admin/master')
  2. @section('content')
  3. <body>
  4. <div class="page-container">
  5. <div>
  6. <div>
  7. <input class="input-text" style="width:6%;text-align:center" type="text" value="数据分类"/>
  8. <select style="width:10%;text-align:center" id='data_type' name="data_type">
  9. <option value="0">7日roi明细</option>
  10. <option value="1">7日roi汇总</option>
  11. <option value="2">每日roi明细</option>
  12. <option value="5">15日roi明细</option>
  13. <option value="6" >15日roi汇总</option>
  14. <option value="3">30日roi明细</option>
  15. <option value="4">30日roi汇总</option>
  16. <option value="7" selected>45日roi明细</option>
  17. <option value="8">45日roi汇总</option>
  18. </select>
  19. <input class="input-text" style="width:5%;text-align:center" type="text" value="所属城市"/>
  20. <input id="city" type="text" class="input-text" style="width:6%;text-align:center" name="city" value="{{$city?$city:''}}">
  21. <input class="input-text" style="width:6%;text-align:center" type="text" value="开始时间"/>
  22. <input id="stime" type="text" onfocus="WdatePicker({ dateFmt:'yyyy-MM-dd' })" class="input-text Wdate" style="width:12%;text-align:center;margin-left: -5px" name="stime" value="{{$stime?$stime:''}}">
  23. <input class="input-text" style="width:6%;text-align:center" type="text" value="结束时间"/>
  24. <input id="etime"type="text" onfocus="WdatePicker({ dateFmt:'yyyy-MM-dd' })" class="input-text Wdate" style="width:12%;text-align:center;margin-left: -5px" name="etime" value="{{$etime?$etime:''}}">
  25. <a class="btn btn-primary radius" style="margin-left: 5px" onclick="user_search()" href="javascript:;">搜索</a>
  26. <a class="btn btn-primary radius" onclick="statistics_export()" href="javascript:;"><i class="Hui-iconfont"></i> 导出数据</a>
  27. </div>
  28. </div>
  29. <div class="mt-20">
  30. <table class="table table-border table-bordered table-bg table-hover table-sort">
  31. <thead>
  32. <tr class="text-c">
  33. <th width="5%">日期</th>
  34. <th width="5%">城市</th>
  35. <th width="5%">投放成本</th>
  36. <th width="5%">加粉数</th>
  37. <th width="5%">下单人数</th>
  38. <th width="5%">新粉成单数</th>
  39. <th width="5%">新粉收入</th>
  40. <th width="5%">新粉ROI</th>
  41. <th width="5%">45日累计成单数</th>
  42. <th width="5%">45日累计收入</th>
  43. <th width="5%">45日累计ROI</th>
  44. </tr>
  45. </thead>
  46. <tbody>
  47. @if($result)
  48. @foreach($result as $a)
  49. <tr class="text-c" style=" text-align:center;">
  50. <td>{{$a['ad_time']}}</td>
  51. <td>{{$a['city']}}</td>
  52. <td>{{$a['cost']}}</td>
  53. <td>{{$a['gzh_count']}}</td>
  54. <td>{{$a['fan_count']}}</td>
  55. <td>{{$a['new_fan_order_count']}}</td>
  56. <td>{{$a['new_fan_order_amount']}}</td>
  57. <td>{{$a['new_roi']}}</td>
  58. <td>{{$a['order_count']}}</td>
  59. <td>{{$a['order_amount']}}</td>
  60. <td>{{$a['total_roi']}}</td>
  61. </tr>
  62. @endforeach
  63. @endif
  64. </tbody>
  65. </table>
  66. </div>
  67. <div id="page" class="page_div"></div>
  68. </div>
  69. <!--_footer 作为公共模版分离出去-->
  70. <script type="text/javascript" src="/admin/lib/jquery/1.9.1/jquery.min.js"></script>
  71. <script type="text/javascript" src="/admin/lib/layer/2.4/layer.js"></script>
  72. <script type="text/javascript" src="/admin/static/h-ui/js/H-ui.min.js"></script>
  73. <script type="text/javascript" src="/admin/static/h-ui.admin/js/H-ui.admin.js"></script>
  74. <script type="text/javascript" src="/admin/lib/page/paging.js"></script>
  75. <script type="text/javascript" src="/admin/lib/My97DatePicker/4.8/WdatePicker.js"></script>
  76. <!--/_footer 作为公共模版分离出去-->
  77. <!--/_footer 作为公共模版分离出去-->
  78. <script type="text/javascript">
  79. function user_search(){
  80. var stime = $('#stime').val();
  81. var etime = $('#etime').val();
  82. var city = $('#city').val();
  83. //var page = {{$page}};
  84. location.href = 'districtRoi45day?stime='+stime+'&etime='+etime+'&city='+city;
  85. }
  86. //导出
  87. function statistics_export(){
  88. var stime = $('#stime').val();
  89. var etime = $('#etime').val();
  90. var city = $('#city').val();
  91. location.href = '/admin/statistics/districtRoi45day_export?stime='+stime+'&etime='+etime+'&city='+city;
  92. }
  93. $("#data_type").change(function(){
  94. var date_type = $(this).val();
  95. if(date_type == 0){
  96. location.href='districtRoi7day';
  97. }
  98. else if(date_type == 1){
  99. location.href='districtRoi7dayTotal';
  100. }
  101. else if(date_type == 2){
  102. location.href='districtRoi';
  103. }
  104. else if(date_type == 3){
  105. location.href='districtRoi30day';
  106. }
  107. else if(date_type == 4){
  108. location.href='districtRoi30dayTotal';
  109. }
  110. else if(date_type == 5){
  111. location.href='districtRoi15day';
  112. }
  113. else if(date_type == 6){
  114. location.href='districtRoi15dayTotal';
  115. }
  116. else if(date_type == 7){
  117. location.href='districtRoi45day';
  118. }
  119. else if(date_type == 8){
  120. location.href='districtRoi45dayTotal';
  121. }
  122. })
  123. /*分页*/
  124. $("#page").paging({
  125. pageNo:{{$page}},
  126. totalPage: {{$pages}},
  127. totalSize: {{$count}},
  128. callback: function(num) {
  129. var stime = $('#stime').val();
  130. var etime = $('#etime').val();
  131. var city = $('#city').val();
  132. location.href='districtRoi45day?page='+num+'&stime='+stime+'&etime='+etime+'&city='+city;
  133. }
  134. })
  135. </script>
  136. </body>
  137. @endsection