amenities

package
v0.0.0-...-d22e7c3 Latest Latest
Warning

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

Go to latest
Published: Apr 16, 2020 License: GPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Amenities

type Amenities struct {
	ID        string      `db:"id"`
	Name      string      `db:"name"`
	Type      int         `db:"type"`
	ImagePath string      `db:"image_path"`
	CreatedAt time.Time   `db:"created_at"`
	UpdatedAt pq.NullTime `db:"updated_at"`
	IsDeleted bool        `db:"is_deleted"`
	IsTest    bool        `db:"is_test"`
}

Amenities struct @database: project, table: amenities

type Repository

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

Repository of amenities

func New

func New() *Repository

New amenities repo

func (Repository) Create

func (r Repository) Create(ctx context.Context, amenities entity.Amenities) error

Create a new amenities

func (Repository) Delete

func (r Repository) Delete(ctx context.Context, amenitiesID string) error

Delete the amenities

func (Repository) Get

func (r Repository) Get(ctx context.Context, amenitiesID ...string) ([]entity.Amenities, error)

Get amenities

func (Repository) Update

func (r Repository) Update(ctx context.Context, amenities entity.Amenities) error

Update amenities

Jump to

Keyboard shortcuts

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