feat: add posts
This commit is contained in:
@@ -19,8 +19,8 @@ type Medias struct {
|
||||
UserID int64 `json:"user_id"`
|
||||
PostID int64 `json:"post_id"`
|
||||
StorageID int64 `json:"storage_id"`
|
||||
Hash string `json:"hash"`
|
||||
Name string `json:"name"`
|
||||
UUID string `json:"uuid"`
|
||||
MimeType string `json:"mime_type"`
|
||||
Size int64 `json:"size"`
|
||||
Path string `json:"path"`
|
||||
|
||||
@@ -13,23 +13,23 @@ import (
|
||||
)
|
||||
|
||||
type Posts struct {
|
||||
ID int64 `sql:"primary_key" json:"id"`
|
||||
CreatedAt time.Time `json:"created_at"`
|
||||
UpdatedAt time.Time `json:"updated_at"`
|
||||
DeletedAt *time.Time `json:"deleted_at"`
|
||||
Type fields.PostType `json:"type"`
|
||||
Stage fields.PostStage `json:"stage"`
|
||||
Status fields.PostStatus `json:"status"`
|
||||
TenantID int64 `json:"tenant_id"`
|
||||
UserID int64 `json:"user_id"`
|
||||
Title string `json:"title"`
|
||||
Description string `json:"description"`
|
||||
PosterAssetID int64 `json:"poster_asset_id"`
|
||||
Content string `json:"content"`
|
||||
Price int64 `json:"price"`
|
||||
Discount int16 `json:"discount"`
|
||||
Views int64 `json:"views"`
|
||||
Likes int64 `json:"likes"`
|
||||
Meta *string `json:"meta"`
|
||||
Assets *string `json:"assets"`
|
||||
ID int64 `sql:"primary_key" json:"id"`
|
||||
CreatedAt time.Time `json:"created_at"`
|
||||
UpdatedAt time.Time `json:"updated_at"`
|
||||
DeletedAt *time.Time `json:"deleted_at"`
|
||||
Type fields.PostType `json:"type"`
|
||||
Stage fields.PostStage `json:"stage"`
|
||||
Status fields.PostStatus `json:"status"`
|
||||
TenantID int64 `json:"tenant_id"`
|
||||
UserID int64 `json:"user_id"`
|
||||
Title string `json:"title"`
|
||||
Description string `json:"description"`
|
||||
Content string `json:"content"`
|
||||
Price int64 `json:"price"`
|
||||
Discount int16 `json:"discount"`
|
||||
Views int64 `json:"views"`
|
||||
Likes int64 `json:"likes"`
|
||||
Meta *string `json:"meta"`
|
||||
Tags fields.Json[[]string] `json:"tags"`
|
||||
Assets fields.Json[[]fields.MediaAsset] `json:"assets"`
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user