reward_list.blade.php 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122
  1. @extends('base.base')
  2. @section('base')
  3. <div class="container-fluid">
  4. <div class="row">
  5. <div class="col-12">
  6. <div class="card">
  7. <div class="card-header">
  8. <h3 class="card-title">推广员奖励报表</h3>
  9. </div>
  10. <div class="card-body">
  11. <form class="form-inline mb-4" method="post" action="{{ route('admin.extension_new.reward') }}">
  12. @csrf
  13. <div class="form-group mx-sm-3 mb-2">
  14. <label for="UserID" class="mr-2">会员ID:</label>
  15. <input type="text" class="form-control" name="UserID" id="UserID" value="{{ $UserID }}">
  16. </div>
  17. <div class="form-group mx-sm-3 mb-2">
  18. <label for="SpreaderID" class="mr-2">上级ID:</label>
  19. <input type="text" class="form-control" name="SpreaderID" id="SpreaderID" value="{{ $SpreaderID }}">
  20. </div>
  21. {{-- <div class="form-group mx-sm-3 mb-2">--}}
  22. {{-- <label for="Type" class="mr-2">选择类型:</label>--}}
  23. {{-- <select class="form-control" name="Type" id="Type">--}}
  24. {{-- <option value="">全部</option>--}}
  25. {{-- <option value="1" @if($Type == 1) selected @endif>注册</option>--}}
  26. {{-- <option value="2" @if($Type == 2) selected @endif>对局</option>--}}
  27. {{-- <option value="3" @if($Type == 3) selected @endif>充值</option>--}}
  28. {{-- </select>--}}
  29. {{-- </div>--}}
  30. <div class="form-group mx-sm-3 mb-2">
  31. <label for="start_time" class="mr-2">发放时间:</label>
  32. <input type="datetime-local" step="01" name="start_time" id="start_time" class="form-control" value="{{ $start_time }}">
  33. <input type="datetime-local" step="01" name="end_time" id="end_time" class="form-control ml-2" value="{{ $end_time }}">
  34. </div>
  35. <a href="{{ route('admin.extension_new.reward') }}" class="btn btn-secondary mb-2 mr-2">重置</a>
  36. <button type="submit" class="btn btn-primary mb-2">搜索</button>
  37. </form>
  38. <div class="mb-3">
  39. 自动审核:
  40. @if($AutoVerify == 1)
  41. 已开启 <button class="btn btn-sm btn-dark" onclick="autoVerify(0)">关闭</button>
  42. @else
  43. 已关闭 <button class="btn btn-sm btn-dark" onclick="autoVerify(1)">开启</button>
  44. @endif
  45. </div>
  46. <div class="table-responsive">
  47. <table class="table table-bordered">
  48. <thead>
  49. <tr>
  50. <th>推广员ID</th>
  51. <th>会员ID</th>
  52. <th>发放时间</th>
  53. <th>佣金金额</th>
  54. <th>订单号</th>
  55. {{-- <th>类型</th>--}}
  56. <th>佣金比例</th>
  57. <th>充值金额</th>
  58. </tr>
  59. </thead>
  60. <tbody>
  61. @foreach($list as $value)
  62. <tr>
  63. <td>
  64. <a href="/admin/global/id_find?UserID={{$value->SpreaderID}}">{{$value->SpreaderGameID}}</a>
  65. </td>
  66. <td>
  67. <a href="/admin/global/id_find?UserID={{$value->UserID}}">{{$value->GameID}}</a>
  68. </td>
  69. <td>{{date("Y-m-d H:i:s", strtotime($value->created_at))}}</td>
  70. <td>{{$value->commission_amount}}</td>
  71. <td>{{$value->order_sn}}</td>
  72. {{-- <td>{{$value->TypeDesc}}</td>--}}
  73. <td>{{$value->commission_rate}}%</td>
  74. <td>{{$value->deposit_amount}}</td>
  75. </tr>
  76. @endforeach
  77. </tbody>
  78. </table>
  79. </div>
  80. <div class="card-footer clearfix">
  81. 总共 <b>{{ $list->appends([
  82. 'UserID' => $UserID,
  83. 'SpreaderID' => $SpreaderID,
  84. 'start_time' => $start_time,
  85. 'end_time' => $end_time,
  86. 'Type' => $Type
  87. ])->total() }}</b> 条, 分为 <b>{{ $list->lastPage() }}</b> 页
  88. {{ $list->links() }}
  89. </div>
  90. </div>
  91. </div>
  92. </div>
  93. </div>
  94. </div>
  95. @endsection
  96. @section('scripts')
  97. <script>
  98. $(function() {
  99. $('#start_time, #end_time').datetimepicker({
  100. format: 'YYYY-MM-DD HH:mm:ss'
  101. });
  102. });
  103. // 自动审核开关
  104. function autoVerify(StatusValue) {
  105. $.post("/admin/extension_new/auto_verify", {
  106. StatusValue: StatusValue,
  107. _token: '{{ csrf_token() }}'
  108. }, function(res) {
  109. if (res.code === 0) {
  110. alert('设置成功');
  111. location.reload();
  112. } else {
  113. alert(res.msg || '设置失败');
  114. }
  115. });
  116. }
  117. </script>
  118. @endsection