implemented post creation, deletion and update api
This commit is contained in:
@@ -6,5 +6,5 @@ type Post struct {
|
||||
gorm.Model // includes ID, CreatedAt, UpdatedAt, DeletedAt
|
||||
Title string `gorm:"not null"`
|
||||
Content string `gorm:"type:text; not null"`
|
||||
AuthorID uint // foreign key to User
|
||||
Author string `gorm:"not null"`
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user