コアモデルの作成・DB接続をGORMを利用する形に変更
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
package model
|
||||
|
||||
import "time"
|
||||
|
||||
type Comment struct {
|
||||
ID uint `gorm:"primaryKey"`
|
||||
PageURL string `gorm:"index;size:255;not null"`
|
||||
AuthorName string `gorm:"size:100;not null"`
|
||||
Content string `gorm:"type:varchar(5000);not null"`
|
||||
UserIdentifier string `gorm:"size:255"`
|
||||
IsSpam bool `gorm:"default:false"`
|
||||
CreatedAt time.Time `gorm:"index"`
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user