index.blade.php 2.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. @extends('layouts.app')
  2. @section('title')查询-入库管理@endsection
  3. @section('content')
  4. <div class="d-none" id="fast">
  5. <div class="container-fluid">
  6. <table class="table table-striped table-sm text-nowrap table-hover td-min-width-80" id="table">
  7. <tr v-for="(store,i) in stores" @click="selectTr===i+1?selectTr=0:selectTr=i+1" :class="selectTr===i+1?'focusing' : ''">
  8. <td>
  9. <input class="checkItem" type="checkbox" :value="store.id">
  10. </td>
  11. <td><span>@{{ i+1 }}</span></td>
  12. <td class="text-muted"><span>@{{store.asn_code}}</span></td>
  13. <td><span>@{{store.warehouse ? store.warehouse.name : ''}}</span></td>
  14. <td class="text-muted"><span>@{{store.owner ? store.owner.name : ''}}</span></td>
  15. <td class="text-muted"><span>@{{store.stored_method}}</span></td>
  16. <td class="text-muted"><span>@{{store.status}}</span></td>
  17. <td><span>@{{store.remark}}</span></td>
  18. <td class="text-muted"><span>@{{store.created_at}}</span></td>
  19. </tr>
  20. </table>
  21. <div class="text-info h5 btn btn">{{$stores->count()}}/{{$stores->total()}}</div>
  22. {{$stores->links()}}
  23. </div>
  24. </div>
  25. @endsection
  26. @section('lastScript')
  27. <script type="text/javascript" src="{{mix('js/queryForm/header.js')}}"></script>{{--新版2--}}
  28. <script>
  29. let vue = new Vue({
  30. el:'#fast',
  31. data:{
  32. stores:[
  33. @foreach($stores as $store)
  34. {!! $store !!},
  35. @endforeach
  36. ],
  37. selectTr:''
  38. },
  39. mounted:function(){
  40. $('#fast').removeClass('d-none');
  41. let column = [
  42. {name:'index',value: '序号', neglect: true},
  43. {name:'asn_code',value: 'ASN编号'},
  44. {name:'warehouse_name',value: '仓库'},
  45. {name:'owner_name',value: '货主'},
  46. {name:'stored_method',value: '入库类型'},
  47. {name:'status',value: '状态'},
  48. {name:'remark',value: '备注'},
  49. {name:'created_at',value: '生成时间'},
  50. ];
  51. new Header({
  52. el: "table",
  53. name: "storeFast",
  54. column: column,
  55. data: this.stores,
  56. }).init();
  57. }
  58. });
  59. </script>
  60. @endsection