|
楼主 |
发表于 2017-5-3 17:01:37
|
显示全部楼层
哦, 我在base.js修改如下,
Model.prototype.bindUpdateDateTime = function(){
var $root = $(this.getRootNode());
var $dateTime = $root.find('.x-portal-datetime');
var now = bizUtil.getSystemDatetime();
if($dateTime.size()>0){
var model = this;
var fn = function(){
now = justep.Date.increase(now, 1, 's');
$dateTime.text(justep.Date.toString(now, 'yyyy-MM-dd hh:mm:ss'));
};
this._updateDateTimeHandle = window.setInterval(justep.Util.bindModelFn(this, fn, this), 1000);
}
};
这样的话请求减少了,但会有一定的延时,求指教,谢谢。 |
|