123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122 |
- @extends('admin/layout')
- @section('header')
- <link href="{{asset('css/plugins/switchery/switchery.css')}}" rel="stylesheet">
- <style>
- .btn-danger, .btn-primary, .btn-info {
- background: #009688 !important;
- border-color: #009688 !important;
- }
- .table-striped > tbody > tr:nth-of-type(odd) {
- background: #f8f8f8 !important;
- }
- .table-striped > tbody > tr .btn {
- background: none !important;
- }
- .table-striped > tbody > tr td {
- font-size: 14px !important;
- }
- .table-striped > tbody > tr:hover {
- background: #ffebd8 !important;
- }
- .table-striped > tbody > tr:hover .btn {
- background: #009688 !important;
- color: #fff !important;
- }
- .table-striped > tbody > tr:hover .btn .glyphicon {
- color: #fff !important;
- }
- </style>
- @endsection
- @section('content')
- @php $authUser=auth()->user() @endphp
- <body class="gray-bg">
- <div class="wrapper wrapper-content animated fadeInRight">
- <div class="row">
- <div class="col-sm-12">
- <div class="ibox float-e-margins">
- <div class="ibox-content">
- <div class="col-md-4">
- <div class="input-group">
- <span class="input-group-btn">
- <button type="button" class="btn btn-md btn-primary"
- onclick="units.read()" style="border-radius:3px;"> 全部已读</button>
- </span>
- </div>
- </div>
- <form class="row" id="searchForm" onsubmit="units.search();return false;">
- <div class="input-group">
- <input type="text" placeholder="请输入任务标题" class="input-md form-control"
- name="message" id="message" style="width: 150px;float: right">
- <span class="input-group-btn">
- <button type="button" class="btn btn-md btn-primary"
- onclick="units.search()" style="border-radius:3px;"> 搜索</button>
- <button type="button" class="btn btn-md" style="margin-left: 10px;border-radius:3px;"
- name="btnReset"> 重置</button>
- </div>
- </form>
- <hr>
- <div class="table-responsive">
- <table id="table" class="table table-condensed" data-mobile-responsive="true"></table>
- </div>
- </div>
- </div>
- </div>
- </div>
- </div>
- </body>
- @endsection
- @section('footer')
- <script src="{{asset('js/plugins/layDate-v5.0.9/laydate/laydate.js')}}"></script>
- <script>
- var units = {
- search: function () {
- tips.selectPage();
- },
- read: function () {
- var url = '/admin/mailbox/batchRead';
- var type = 'get';
- var ajaxConfig = {
- url: url,
- type: type,
- data: {},
- success: function (result) {
- layer.msg(result.message, {icon: 6});
- tips.tableRefresh();
- }
- };
- tips.ajax(ajaxConfig);
- }
- };
- var config = {};
- config.url = '/admin/mailbox';
- config.pageSize = 20;
- config.columns = [ //字段
- {
- title: '序号', align: 'center', formatter: function (value, item, index) {
- return index + 1;
- },
- width: '10px'
- },
- {title: '消息时间', field: 'created_at', align: 'center'},
- {title: '接收人', field: 'user', align: 'center'},
- {title: '消息', field: 'message', align: 'center'},
- {title: '是否已读', field: 'read', align: 'center'}
- ];
- tips.bootstrapTable(config);
- </script>
- @endsection
|