userCreditHistory.blade.php 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. @extends('admin.table_layouts')
  2. @section('content')
  3. <div class="page-content container-fluid">
  4. <x-admin.table-panel :title="trans('admin.menu.user.credit_log')" :theads="[
  5. '#',
  6. trans('common.account'),
  7. trans('model.order.id'),
  8. trans('model.user_credit.before'),
  9. trans('model.user_credit.amount'),
  10. trans('model.user_credit.after'),
  11. trans('model.common.description'),
  12. trans('model.user_credit.created_at'),
  13. ]" :count="trans('admin.logs.counts', ['num' => $userCreditLogs->total()])" :pagination="$userCreditLogs->links()">
  14. <x-slot:filters>
  15. <x-admin.filter.input class="col-lg-3 col-sm-6" name="username" :placeholder="trans('common.account')" />
  16. </x-slot:filters>
  17. <x-slot:tbody>
  18. @foreach ($userCreditLogs as $log)
  19. <tr>
  20. <td> {{ $log->id }} </td>
  21. <td>
  22. @if (empty($log->user))
  23. 【{{ trans('common.deleted_item', ['attribute' => trans('common.account')]) }}】
  24. @else
  25. <a href="{{ route('admin.log.credit', ['username' => $log->user->username]) }}"> {{ $log->user->username }} </a>
  26. @endif
  27. </td>
  28. <td> {{ $log->order_id }} </td>
  29. <td> {{ $log->before }} </td>
  30. <td> {{ $log->amount }} </td>
  31. <td> {{ $log->after }} </td>
  32. <td> {{ __($log->description) }} </td>
  33. <td> {{ $log->created_at }} </td>
  34. </tr>
  35. @endforeach
  36. </x-slot:tbody>
  37. </x-admin.table-panel>
  38. </div>
  39. @endsection