package model type FeedSum struct { CowNum int64 `gorm:"column:cowNum"` CowNumM int64 `gorm:"column:cowNumM"` FeedDay string `gorm:"column:feedDay"` Id int64 `gorm:"column:id"` PastureId int64 `gorm:"column:pastureId"` SaleNum int64 `gorm:"column:saleNum"` } func (t *FeedSum) TableName() string { return "feed_sum" } type FeedSumAndPasture struct { FeedSum `xorm:"extends"` Pasture `xorm:"extends"` }