queries

package
v0.0.0-...-25459cf Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 6, 2025 License: AGPL-3.0 Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CompletePostMeta

func CompletePostMeta(in ...models.Post) ([]models.Post, error)

func GetPost

func GetPost(tx *gorm.DB, id uint, user *uint) (models.Post, error)

func GetPostByAlias

func GetPostByAlias(tx *gorm.DB, alias, area string, user *uint) (models.Post, error)

func ListPost

func ListPost(tx *gorm.DB, take int, offset int, order any, user *uint) ([]models.Post, error)

Types

type FeedEntry

type FeedEntry struct {
	Type      string    `json:"type"`
	Data      any       `json:"data"`
	CreatedAt time.Time `json:"created_at"`
}

func GetFeed

func GetFeed(c *fiber.Ctx, limit int, user *uint, cursor *time.Time) ([]FeedEntry, error)

func ListPostForFeed

func ListPostForFeed(tx *gorm.DB, limit int, user *uint, api string) ([]FeedEntry, error)

func ListReaderPagesForFeed

func ListReaderPagesForFeed(limit int, cursor *time.Time) ([]FeedEntry, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL