@extends('base.base')
@section('base')
    <!-- {{ trans('messages.内容区域') }} -->
    <div class="main-panel">
        <div class="content-wrapper">

            <div class="row">
                {{$list}}
            </div>
        </div>
    </div>
    <script>
        function add(){
            var page = layer.open({
                type: 2,
                title: '{{ trans('messages.添加IP白名单') }}',
                shadeClose: true,
                shade: 0.8,
                area: ['70%', '90%'],
                content: '/admin/IpWhiteList/add'
            });
        }
        function update(id){
            var page = layer.open({
                type: 2,
                title: '{{ trans('messages.修改IP白名单') }}',
                shadeClose: true,
                shade: 0.8,
                area: ['70%', '90%'],
                content: '/admin/IpWhiteList/update/'+id
            });
        }
        function del(id){
            myConfirm("{{ trans('messages.删除操作不可逆,是否继续?') }}", function(){
                myRequest("/admin/IpWhiteList/del/"+id, "post", {}, function(res){
                    layer.msg(res.msg)
                    setTimeout(function(){
                        window.location.reload();
                    },1500)
                });
            });
        }
    </script>
@endsection
