app.go 326 B

123456789101112131415
  1. package model
  2. import "gorm.io/gorm"
  3. type AppModel struct {
  4. gorm.Model
  5. Name string `gorm:"type:varchar(64);unique"`
  6. Desc string `gorm:"type:varchar(256)"`
  7. ImgURL string `gorm:"type:varchar(512)"`
  8. ApolloAppID string `gorm:"not null;unique"`
  9. }
  10. func (a AppModel) TableName() string {
  11. return "cc_app"
  12. }