You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
64 lines
2.9 KiB
64 lines
2.9 KiB
@push("header")
|
|
<!-- third party css -->
|
|
<link href="/plugins/datatables/dataTables.bootstrap4.css" rel="stylesheet" type="text/css"/>
|
|
<link href="/plugins/datatables/responsive.bootstrap4.css" rel="stylesheet" type="text/css"/>
|
|
@endpush
|
|
|
|
@push("footer")
|
|
<!-- third party js -->
|
|
<script src="/plugins/datatables/jquery.dataTables.min.js"></script>
|
|
<script src="/plugins/datatables/dataTables.bootstrap4.js"></script>
|
|
<script src="/plugins/datatables/dataTables.responsive.min.js"></script>
|
|
<script src="/plugins/datatables/responsive.bootstrap4.min.js"></script>
|
|
<script src="/plugins/datatables/dataTables.buttons.min.js"></script>
|
|
<script src="/plugins/datatables/buttons.bootstrap4.min.js"></script>
|
|
<script src="/plugins/datatables/buttons.html5.min.js"></script>
|
|
<script src="/plugins/datatables/buttons.flash.min.js"></script>
|
|
<script src="/plugins/datatables/buttons.print.min.js"></script>
|
|
<script src="/plugins/datatables/dataTables.keyTable.min.js"></script>
|
|
<script src="/plugins/datatables/dataTables.select.min.js"></script>
|
|
{{-- <script src="/plugins/pdfmake/pdfmake.min.js"></script>--}}
|
|
{{-- <script src="/plugins/pdfmake/vfs_fonts.js"></script>--}}
|
|
<!-- third party js ends -->
|
|
<script>
|
|
$(function () {
|
|
var datatable_default_configs = {
|
|
dom: 'Bfrtip',
|
|
buttons: [
|
|
'csv', 'excel', 'print'
|
|
],
|
|
sorting: true,
|
|
order: [],
|
|
paging: false,
|
|
searching: true,
|
|
language: {
|
|
"search": "搜索",
|
|
"lengthMenu": "每页显示 _MENU_ 条记录",
|
|
"zeroRecords": "没有任何记录",
|
|
"info": "",
|
|
"infoEmpty": "没有匹配的记录",
|
|
"infoFiltered": "从 _MAX_ 条记录中搜索的结果",
|
|
"oPaginate": {
|
|
"sFirst": "首页",
|
|
"sPrevious": "上页",
|
|
"sNext": "下页",
|
|
"sLast": "末页"
|
|
},
|
|
}
|
|
};
|
|
|
|
if ("undefined" != typeof datatable_configs) {
|
|
datatable_default_configs = $.extend(datatable_default_configs, datatable_configs);
|
|
}
|
|
|
|
var table = $('.table-datatable').DataTable(datatable_default_configs);
|
|
|
|
$('.dt-buttons,.dataTables_filter').addClass('float-left').addClass("mr-3");
|
|
$('.dt-buttons .buttons-csv').html("<i class='la la-file-excel-o'></i> 导出");
|
|
$('.dt-buttons .buttons-print').html("<i class='la la-print'></i> 打印");
|
|
$(".dataTables_filter .form-control").removeClass("form-control-sm");
|
|
$(".dataTable").before("<div class='clearfix'></div>");
|
|
});
|
|
</script>
|
|
@endpush
|