migrations

package
v1.5.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 4, 2023 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Migrate

func Migrate()

Types

type Migration

type Migration interface {
	GetCreateAt() time.Time
	Upgrade(ormer orm.Ormer) error
}

Migration db migration base interface

type Migration20220101

type Migration20220101 struct {
}

func (Migration20220101) GetCreateAt

func (m Migration20220101) GetCreateAt() time.Time

func (Migration20220101) Upgrade

func (m Migration20220101) Upgrade(ormer orm.Ormer) error

type Migration20220309

type Migration20220309 struct {
}

func (Migration20220309) GetCreateAt

func (m Migration20220309) GetCreateAt() time.Time

func (Migration20220309) Upgrade

func (m Migration20220309) Upgrade(ormer orm.Ormer) error

type Migration20220324

type Migration20220324 struct {
}

func (Migration20220324) GetCreateAt

func (m Migration20220324) GetCreateAt() time.Time

func (Migration20220324) Upgrade

func (m Migration20220324) Upgrade(ormer orm.Ormer) error

type Migration20220414

type Migration20220414 struct {
}

func (Migration20220414) GetCreateAt

func (m Migration20220414) GetCreateAt() time.Time

func (Migration20220414) Upgrade

func (m Migration20220414) Upgrade(ormer orm.Ormer) error

type Migration20220415

type Migration20220415 struct {
}

func (Migration20220415) GetCreateAt

func (m Migration20220415) GetCreateAt() time.Time

func (Migration20220415) Upgrade

func (m Migration20220415) Upgrade(ormer orm.Ormer) error

type Migration20230703 added in v1.5.3

type Migration20230703 struct {
}

func (Migration20230703) GetCreateAt added in v1.5.3

func (m Migration20230703) GetCreateAt() time.Time

func (Migration20230703) Upgrade added in v1.5.3

func (m Migration20230703) Upgrade(ormer orm.Ormer) error

type MigrationTypes

type MigrationTypes []Migration

func (MigrationTypes) Len

func (t MigrationTypes) Len() int

Len 排序三人组

func (MigrationTypes) Less

func (t MigrationTypes) Less(i, j int) bool

Less 排序三人组

func (MigrationTypes) Swap

func (t MigrationTypes) Swap(i, j int)

Swap 排序三人组

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL