1
0
mirror of https://github.com/astaxie/beego.git synced 2024-11-22 09:10:55 +00:00

Update: removing the need to call DDLSpec in the migration file

Signed-off-by: Gnanakeethan Balasubramaniam <gnanakeethan@gmail.com>
This commit is contained in:
Gnanakeethan Balasubramaniam 2017-07-16 07:24:58 +05:30
parent cb38ab4f85
commit d58ad2ee36
No known key found for this signature in database
GPG Key ID: 24924006ABA72F31

View File

@ -80,9 +80,14 @@ func init() {
migrationMap = make(map[string]Migrationer) migrationMap = make(map[string]Migrationer)
} }
//DDLSpec implement in the Inheritance struct for defining structure
func (m *Migration) DDLSpec() {
}
// Up implement in the Inheritance struct for upgrade // Up implement in the Inheritance struct for upgrade
func (m *Migration) Up() { func (m *Migration) Up() {
m.DDLSpec()
switch m.ModifyType { switch m.ModifyType {
case "reverse": case "reverse":
m.ModifyType = "alter" m.ModifyType = "alter"