45 lines
2.1 KiB
Go
45 lines
2.1 KiB
Go
package model
|
|
|
|
import (
|
|
"time"
|
|
|
|
"gorm.io/gorm"
|
|
)
|
|
|
|
type AnnualReport struct {
|
|
Id int32 `gorm:"primarykey"`
|
|
CreatedAt time.Time
|
|
UpdatedAt time.Time
|
|
DeletedAt gorm.DeletedAt `gorm:"column:deleted_at;index:idx_annual_report_deleted_at;"`
|
|
FileName string `gorm:"column:file_name;type:varchar(100);not null;default:'';comment:文件名称"`
|
|
Date int64 `gorm:"column:date;type:int;not null;default:0;comment:日期"`
|
|
FileUrl string `gorm:"column:file_url;type:varchar(100);not null;default:'';comment:访问地址"`
|
|
Status int32 `gorm:"column:status;type:int;not null;default:2;comment:状态:1上架 2 下架"`
|
|
Sort int32 `gorm:"column:sort;type:int;not null;default:1;comment:排序"`
|
|
Operator string `gorm:"column:operator;type:varchar(100);not null;default:'';comment:操作人"`
|
|
OperatorId int32 `gorm:"column:operator_id;comment:操作人Id"`
|
|
}
|
|
|
|
func (*AnnualReport) TableName() string {
|
|
return "annual_report"
|
|
}
|
|
|
|
type QuarterlyReport struct {
|
|
Id int32 `gorm:"primarykey"`
|
|
CreatedAt time.Time
|
|
UpdatedAt time.Time
|
|
DeletedAt gorm.DeletedAt `gorm:"column:deleted_at;index:idx_quarterly_report_deleted_at;"`
|
|
FileName string `gorm:"column:file_name;type:varchar(100);not null;default:'';comment:文件名称"`
|
|
FileIntroduce string `gorm:"column:file_introduce;type:varchar(100);not null;default:'';comment:文件介绍"`
|
|
Attachment string `gorm:"column:attachment;type:varchar(100);not null;default:'';comment:附件"`
|
|
AttachmentName string `gorm:"column:attachment_name;type:varchar(100);not null;default:'';comment:附件名称"`
|
|
Status int32 `gorm:"column:status;type:int;not null;default:2;comment:状态:1上架 2 下架"`
|
|
Sort int32 `gorm:"column:sort;type:int;not null;default:1;comment:排序"`
|
|
Operator string `gorm:"column:operator;type:varchar(100);not null;default:'';comment:操作人"`
|
|
OperatorId int32 `gorm:"column:operator_id;comment:操作人Id"`
|
|
}
|
|
|
|
func (*QuarterlyReport) TableName() string {
|
|
return "quarterly_report"
|
|
}
|