Merge pull request #498 from didikeke/master
fix foreign key dataType bug
This commit is contained in:
commit
9083370e17
|
@ -1710,7 +1710,7 @@ DataSource.prototype.defineForeignKey = function defineForeignKey(className, key
|
||||||
}
|
}
|
||||||
|
|
||||||
var fkDef = {type: pkType};
|
var fkDef = {type: pkType};
|
||||||
var foreignMeta = this.columnMetadata(foreignClassName, key);
|
var foreignMeta = this.columnMetadata(foreignClassName, pkName);
|
||||||
if(foreignMeta && foreignMeta.dataType) {
|
if(foreignMeta && foreignMeta.dataType) {
|
||||||
fkDef[this.connector.name] = {};
|
fkDef[this.connector.name] = {};
|
||||||
fkDef[this.connector.name].dataType = foreignMeta.dataType;
|
fkDef[this.connector.name].dataType = foreignMeta.dataType;
|
||||||
|
|
Loading…
Reference in New Issue