news

package
v0.0.0-...-8bc6207 Latest Latest
Warning

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

Go to latest
Published: Feb 16, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type News

type News struct {
	Id       uint64 `json:"id"`
	Title    string `json:"title"`
	FileName string `json:"file_name"`
	Content  string `json:"content"`
	Date     int64  `json:"date"`
}

type NewsRepo

type NewsRepo interface {
}

type Store

type Store struct {
	// contains filtered or unexported fields
}

func NewStore

func NewStore(scope *gocb.Scope) *Store

func (*Store) AddNews

func (m *Store) AddNews(n *News) error

func (*Store) DeleteNews

func (m *Store) DeleteNews(id uint64) error

func (*Store) EditNews

func (m *Store) EditNews(n *News) error

func (*Store) GetNewsById

func (m *Store) GetNewsById(id uint64) (n News, err error)

func (*Store) GetNewsLatest

func (m *Store) GetNewsLatest() (n News, err error)

func (*Store) ListAllNews

func (m *Store) ListAllNews() (n []News, err error)

Jump to

Keyboard shortcuts

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