index.blade.php 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101
  1. @extends('admin.layout')
  2. @section('content')
  3. <div class="row">
  4. <div class="col-sm-12">
  5. <div class="ibox float-e-margins">
  6. <div class="ibox-title">
  7. <h5>微信配置</h5>
  8. <div class="ibox-tools">
  9. <a class="collapse-link"> <i class="fa fa-chevron-up"></i>
  10. </a>
  11. </div>
  12. </div>
  13. <div class="ibox-content">
  14. <div class="row">
  15. <form method="GET" action="" accept-charset="UTF-8">
  16. <div class="col-sm-4">
  17. <div class="input-group">
  18. <input type="text" value="{{Request::get('keyword')}}" placeholder="请输入关键词" name="keyword"class="input-sm form-control">
  19. <span class="input-group-btn">
  20. <button type="submit" class="btn btn-sm btn-primary">搜索</button>
  21. </span>
  22. </div>
  23. </div>
  24. </form>
  25. @if(role('Wechat/App/create'))
  26. <div class="col-sm-3 pull-right">
  27. <a href="{{ U('Wechat/App/create')}}" class="btn btn-sm btn-primary pull-right">添加</a>
  28. </div>
  29. @endif
  30. </div>
  31. <table class="table table-striped table-bordered table-hover dataTables-example dataTable">
  32. <thead>
  33. <tr>
  34. <th class="sorting" data-sort="id"> ID </th>
  35. <th class="sorting" data-sort="appid"> AppID </th>
  36. <th class="sorting" data-sort="appsecret"> AppSecret </th>
  37. <th class="sorting" data-sort="created_at"> 创建时间 </th>
  38. <th class="sorting" data-sort="updated_at"> 更新时间 </th>
  39. <th width="22%">相关操作</th>
  40. </tr>
  41. </thead>
  42. <tbody>
  43. @if(isset($list))
  44. @foreach($list as $key => $item) <tr>
  45. <td>{{ $item->id }}</td>
  46. <td>{{ $item->appid }}</td>
  47. <td>{{ $item->appsecret }}</td>
  48. <td>{{ $item->created_at }}</td>
  49. <td>{{ $item->updated_at }}</td>
  50. <td>
  51. <div class="btn-group">
  52. <button data-toggle="dropdown"
  53. class="btn btn-warning btn-sm dropdown-toggle"
  54. aria-expanded="false">
  55. 操作 <span class="caret"></span>
  56. </button>
  57. <ul class="dropdown-menu">
  58. @if(role('Wechat/App/update'))
  59. <li><a href="{{ U('Wechat/App/update',['id'=>$item->id])}}" class="font-bold">修改</a></li>
  60. @endif
  61. @if(role('Wechat/App/destroy'))
  62. <li class="divider"></li>
  63. <li><a href="{{ U('Wechat/App/destroy',['id'=>$item->id])}}" onclick="return confirm('你确定执行删除操作?');">删除</a></li>
  64. @endif
  65. </ul>
  66. </div>
  67. @if(role('Wechat/App/view'))
  68. <button onclick="layer.open({type: 2,area: ['80%', '90%'],content: '{{ U('Wechat/App/view',['id'=>$item->id])}}'});" class="btn btn-primary ">查看</button>
  69. @endif
  70. </td>
  71. </tr>
  72. @endforeach
  73. @endif
  74. </tbody>
  75. </table>
  76. <div class="row">
  77. <div class="col-sm-6">
  78. <div class="dataTables_info" id="DataTables_Table_0_info"
  79. role="alert" aria-live="polite" aria-relevant="all">每页{{ $list->count() }}条,共{{ $list->lastPage() }}页,总{{ $list->total() }}条。</div>
  80. </div>
  81. <div class="col-sm-6">
  82. <div class="dataTables_paginate paging_simple_numbers" id="DataTables_Table_0_paginate">
  83. {!! $list->setPath('')->appends(Request::all())->render() !!}
  84. </div>
  85. </div>
  86. </div>
  87. </div>
  88. </div>
  89. </div>
  90. </div>
  91. @endsection