layui.use('laydate', function () {
    var laydate = layui.laydate;
    //日期时间范围
    laydate.render({
        elem: '#test10'
      , type: 'datetime'
      , range: true
    });
});

layui.use(['table', 'jquery'], function () {
    var table = layui.table;
    var form = layui.form,
       layer = parent.layer === undefined ? layui.layer : parent.layer,
       $ = layui.jquery;
    //监听表格复选框选择
    table.on('checkbox(demo)', function (obj) {
        console.log(obj)
    });
   
    var $ = layui.$, active = {
        //查询按钮
        reload: function () {

            //执行重载
            table.reload('recordtable', {
                page: {
                    curr: 1 //重新从第 1 页开始
                }
              , where: {
                 
                  dateParty: $("#test10").val()
                  , NowDateTime: new Date()
                   , phoneNumber: $("#phoneNumber").val()
                   , status: $("#status").val()
               

              }
            });
        }

    };

    $('.searchfilter .layui-btn').on('click', function () {
        var type = $(this).data('type');
        active[type] ? active[type].call(this) : '';
    });

    //回车执行
    document.onkeydown = function (event) {
        var e = event || window.event || arguments.callee.caller.arguments[0];
        if (e && e.keyCode == 13) {
            //执行重载
            table.reload('recordtable', {
                page: {
                    curr: 1 //重新从第 1 页开始
                }
              , where: {

                  dateParty: $("#test10").val()
                  , NowDateTime: new Date()
                   , phoneNumber: $("#phoneNumber").val()
                   , status: $("#status").val()
              }
            });
        }
    };


   



   

});