easyui如何转换日期?

时间范围查询 应该怎么使用下面方法的转换日期?

   function searchScore(){
        $('#datalist').datagrid('reload',{
            'superviseVO.begindate': $('#begindate').datebox('getValue'),
            'superviseVO.enddate': $('#enddate').datebox('getValue'),
        });
    }

![img](

![img](

https://img-mid.csdnimg.cn/release/static/image/mid/ask/159536296626160.png)
https://img-mid.csdnimg.cn/release/static/image/mid/ask/451946296626188.png)

function formatDate(date, format) {
if (!format)
format = "yyyy-MM-dd HH:mm:ss";
date = new Date(parseInt(date));
var dict = {
"yyyy" : date.getFullYear(),
"M" : date.getMonth() + 1,
"d" : date.getDate(),
"H" : date.getHours(),
"m" : date.getMinutes(),
"s" : date.getSeconds(),
"S" : date.getMilliseconds(),
"MM" : ("" + (date.getMonth() + 101)).substr(1),
"dd" : ("" + (date.getDate() + 100)).substr(1),
"HH" : ("" + (date.getHours() + 100)).substr(1),
"mm" : ("" + (date.getMinutes() + 100)).substr(1),
"ss" : ("" + (date.getSeconds() + 100)).substr(1)
};
return format.replace(/(y+|M+|d+|H+|s+|m+|S)/g, function(a) {
return dict[a]
})
}

写个类似的函数,然后在要转换的地方调用这个函数