index.blade.php 2.7 KB

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