var util = jsloader.resolve("freequery.common.util");
var BusinessViewHandler = function(businessView) {
this.businessView = businessView;
this.queryType = this.businessView.bv.queryType;
};
lang.extend(BusinessViewHandler, "freequery.widget.Module2");
BusinessViewHandler.prototype.destroy = function() {
BusinessViewHandler.superclass.destroy.call(this);
};
BusinessViewHandler.prototype.isEnabled = function(){
return true;
}
BusinessViewHandler.prototype.readConfig = function() {
var config = {
toolbar : {
items : [ {
id : "saveEx",
image : "img/save.gif",
title : "保存",
command : "SAVE_BUSINESS",//用于下面execute方法
before : "save"
}]
}
};
}
};
return config;
};
BusinessViewHandler.prototype.execute = function(cmd, btn) {
switch (cmd) {
case "SAVE_BUSINESS":
try {
this.businessView.onSave();
}catch (e){
break;
}
break;
break;
}
break;
}
};
|