Merge pull request #1081 from layui/2.x

Merge 2.x
pull/1085/head v2.7.4
贤心 2022-07-11 00:12:24 +08:00 committed by GitHub
commit 46621b1f6e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 13 additions and 5 deletions

2
dist/layui.js vendored

File diff suppressed because one or more lines are too long

View File

@ -405,7 +405,8 @@ layui.use(['table', 'dropdown'], function(){
}, function(value, index){ }, function(value, index){
obj.update({ obj.update({
email: value email: value
}, true); }, true); // 参数 true 为新版新增功能,详见文档
/* /*
// 上述 obj.update() 只是在前端临时更新数据视图 // 上述 obj.update() 只是在前端临时更新数据视图
// 在实际业务中,当发送修改请求成功后,可再执行 reloadData 来重载数据 // 在实际业务中,当发送修改请求成功后,可再执行 reloadData 来重载数据
@ -448,7 +449,7 @@ layui.use(['table', 'dropdown'], function(){
var update = {}; var update = {};
update[field] = value; update[field] = value;
obj.update(update, true); obj.update(update, true); // 参数 true 为新版新增功能,详见文档
}); });
}); });
</script> </script>

View File

@ -1,7 +1,7 @@
{ {
"name": "layui", "name": "layui",
"realname": "layui", "realname": "layui",
"version": "2.7.3", "version": "2.7.4",
"description": "Classic modular Front-End UI library", "description": "Classic modular Front-End UI library",
"main": "dist/layui.js", "main": "dist/layui.js",
"license": "MIT", "license": "MIT",

View File

@ -15,7 +15,7 @@
} }
,Layui = function(){ ,Layui = function(){
this.v = '2.7.3'; // layui 版本号 this.v = '2.7.4'; // layui 版本号
} }
//识别预先可能定义的指定全局对象 //识别预先可能定义的指定全局对象

View File

@ -530,6 +530,7 @@
//delete options.dateTime; //delete options.dateTime;
//delete that.endDate; //delete that.endDate;
delete laydate.thisId; delete laydate.thisId;
typeof options.close === 'function' && options.close(that);
}); });
} }
return that; return that;
@ -1739,6 +1740,12 @@
//减去一天,得到当前月最后一天 //减去一天,得到当前月最后一天
return new Date(thisDate.getTime() - 1000*60*60*24).getDate(); return new Date(thisDate.getTime() - 1000*60*60*24).getDate();
}; };
// 关闭日期面板
laydate.close = function(id){
var elem = lay('#'+ (id ? ('layui-laydate'+ id) : Class.thisElemDate));
elem.remove();
};
//加载方式 //加载方式
isLayui ? ( isLayui ? (