fineui是帆软报表和BI产品线所使用的前端框架。
 
 
 

21 lines
513 B

Function.prototype.before = function (func) {
var __self = this;
return function () {
if (func.apply(this, arguments) === false) {
return false;
}
return __self.apply(this, arguments);
};
};
Function.prototype.after = function (func) {
var __self = this;
return function () {
var ret = __self.apply(this, arguments);
if (ret === false) {
return false;
}
func.apply(this, arguments);
return ret;
};
};