Extract functions to base connector
move getAddModifyColumns and getDropColumns to base
This commit is contained in:
parent
e81de01aa6
commit
dc1e0d8050
|
@ -156,13 +156,6 @@ function mixinMigration(MySQL, mysql) {
|
|||
});
|
||||
};
|
||||
|
||||
MySQL.prototype.getAddModifyColumns = function(model, actualFields) {
|
||||
var sql = [];
|
||||
var self = this;
|
||||
sql = sql.concat(self.getColumnsToAdd(model, actualFields));
|
||||
return sql;
|
||||
};
|
||||
|
||||
MySQL.prototype.getColumnsToAdd = function(model, actualFields) {
|
||||
var self = this;
|
||||
var m = this.getModelDefinition(model);
|
||||
|
@ -222,13 +215,6 @@ function mixinMigration(MySQL, mysql) {
|
|||
return sql;
|
||||
};
|
||||
|
||||
MySQL.prototype.getDropColumns = function(model, actualFields) {
|
||||
var sql = [];
|
||||
var self = this;
|
||||
sql = sql.concat(self.getColumnsToDrop(model, actualFields));
|
||||
return sql;
|
||||
};
|
||||
|
||||
MySQL.prototype.getColumnsToDrop = function(model, actualFields) {
|
||||
var self = this;
|
||||
var fields = actualFields;
|
||||
|
|
Loading…
Reference in New Issue