model

package
v0.0.0-...-e8f9835 Latest Latest
Warning

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

Go to latest
Published: Sep 20, 2021 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BaseModel

type BaseModel struct {
	ID        int32          `gorm:"primaryKey"`
	CreatedAt time.Time      `json:"created_at"`
	UpdatedAt time.Time      `json:"updated_at"`
	DeletedAt gorm.DeletedAt `gorm:"index"`
}

type PromotionAd

type PromotionAd struct {
	BaseModel
	Name        string    `json:"name" gorm:"type:varchar(255);not null;comment:广告名"`
	SpaceID     int       `json:"space_id" gorm:"type:int(11);default:null;comment:广告位id"`
	Keyword     string    `json:"keyword" gorm:"type:varchar(255);default:null;comment:精确搜索关键词"`
	HtmlContent string    `json:"html_content" gorm:"type:text;comment:静态广告的内容"`
	Text        string    `json:"text" gorm:"type:varchar(255);default:null;comment:文字"`
	Link        string    `json:"link" gorm:"type:varchar(255);default:null;comment:链接"`
	StartTime   time.Time `json:"start_time" gorm:"default:null;comment:开始时间"`
	EndTime     time.Time `json:"end_time" gorm:"default:null;comment:结束时间"`
	Status      int       `json:"status" gorm:"type:int(2);default:0"`
	Priority    int       `json:"priority" gorm:"type:int(4);default:0;comment:优先级"`
	Img         string    `json:"img" gorm:"type:varchar(255);default:null"`
}

func (PromotionAd) TableName

func (PromotionAd) TableName() string

type PromotionSpace

type PromotionSpace struct {
	BaseModel
	Name     string `json:"name" gorm:"type:varchar(255);default:null;comment:名称"`
	SpaceKey string `json:"space_key" gorm:"type:varchar(255);default:null;comment:广告位key"`
}

func (PromotionSpace) TableName

func (PromotionSpace) TableName() string

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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