![](https://img-blog.csdnimg.cn/20201014180756916.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
前端
虾饺你烧麦
码农一枚
展开
-
easyui防止用户重复提交表单!
在按钮逻辑执行开始的时候,执行下面代码! $("#btnSave").css("color", "#CCC"); $('#btnSave').linkbutton('disable'); setTimeout('$("#btnSave").linkbutton("enable");$("#btnSave").css("color","black");', 1000);原创 2021-05-24 08:46:17 · 319 阅读 · 0 评论 -
js的表单form转成Object
1.写一个全局方法 $.fn.serializeObject = function () { var o = {} var a = this.serializeArray(); $.each(a, function () { if (o[this.name]) { if (!o[this.name].push) { o[this.name] = [o[this.name]]; }原创 2021-03-25 10:45:18 · 304 阅读 · 0 评论 -
JS实现date类型格式化
给Date的prototype添加format函数属性 //date格式化函数 Date.prototype.format = function (format) { var d = { "M+": this.getMonth() + 1, //月份 "d+": this.getDate(), //日 "h+": this.getHours(), //时 "m+": this.getMinutes(), //分翻译 2021-03-10 09:27:56 · 1002 阅读 · 0 评论