categories to db
This commit is contained in:
14
gorm/category.go
Normal file
14
gorm/category.go
Normal file
@ -0,0 +1,14 @@
|
||||
package gorm
|
||||
|
||||
type Category struct {
|
||||
ID int
|
||||
ParentID int
|
||||
Title string
|
||||
Name string
|
||||
FlatName string
|
||||
Level int
|
||||
}
|
||||
|
||||
func (Category) TableName() string {
|
||||
return "categories"
|
||||
}
|
Reference in New Issue
Block a user