foodservice

package
v0.0.0-...-25e8c23 Latest Latest
Warning

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

Go to latest
Published: Apr 11, 2023 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Run

func Run(cfg *Config) error

Types

type Config

type Config struct {
	DatabaseAddr     string
	DatabaseUser     string
	DatabasePassword string
	DatabaseName     string

	ApiAddr string
}

func (*Config) Validate

func (c *Config) Validate() error

type HealthzModel

type HealthzModel struct {
	IsHealthy    bool   `json:"is_healthy"`
	ErrorMessage string `json:"error_message"`
}

type Ingredient

type Ingredient struct {
	Id     int64  `json:"id"`
	Name   string `json:"name"`
	Amount string `json:"amount"`
}

type Recipe

type Recipe struct {
	Id          int64        `json:"id"`
	Name        string       `json:"name"`
	Img         string       `json:"img"`
	Ingredients []Ingredient `json:"ingredients",pg:"rel:has-many"`
	Steps       []Step       `json:"steps",pg:"rel:has-many"`
}

type Step

type Step struct {
	Id          int64  `json:"id"`
	Instruction string `json:"instruction"`
}

Jump to

Keyboard shortcuts

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