Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PostgresArticleRepository ¶
type PostgresArticleRepository struct {
// contains filtered or unexported fields
}
PostgresArticleRepository implements article repository
func NewPostgresArticleRepository ¶
func NewPostgresArticleRepository(conn *gorm.DB) *PostgresArticleRepository
NewPostgresArticleRepository return new instances of postgres article repository
func (*PostgresArticleRepository) CreateArticle ¶
func (r *PostgresArticleRepository) CreateArticle(a *model.Article) error
CreateArticle ...
func (*PostgresArticleRepository) GetAllArticle ¶
func (r *PostgresArticleRepository) GetAllArticle() ([]*model.Article, error)
GetAllArticle ...
func (*PostgresArticleRepository) GetArticleByID ¶
func (r *PostgresArticleRepository) GetArticleByID(id int) (*model.Article, error)
GetArticleByID ...
Click to show internal directories.
Click to hide internal directories.