Fix the columnName

This commit is contained in:
Raymond Feng 2013-10-03 14:49:03 -07:00
parent d0cdbd84ea
commit 1ae9478496
2 changed files with 2 additions and 2 deletions

View File

@ -1190,7 +1190,7 @@ DataSource.prototype.tableName = function (modelName) {
* @returns {String} columnName
*/
DataSource.prototype.columnName = function (modelName, propertyName) {
return this.definitions[modelName].columnName(this.connector.name);
return this.definitions[modelName].columnName(this.connector.name, propertyName);
};
/**

View File

@ -171,7 +171,7 @@ ModelBaseClass.defineProperty = function (prop, params) {
};
ModelBaseClass.getPropertyType = function (propName) {
var prop = this.properties[propName];
var prop = this.definition.properties[propName];
if(!prop) {
// The property is not part of the definition
return null;