model

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

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

Go to latest
Published: Jan 24, 2021 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultDateFormat = "02/01/2006"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Invoice

type Invoice struct {
	Number string

	Date string

	Items []Item

	VAT float64

	Currency string
}

func NewInvoice

func NewInvoice() Invoice

func NewInvoiceFromDomain

func NewInvoiceFromDomain(i *invoice.Invoice) Invoice

func (Invoice) ToDomain

func (i Invoice) ToDomain() (*invoice.Invoice, error)

type Item

type Item struct {
	Description string
	Price       float64
}

type Template

type Template struct {
	Name      string
	Canonical string
}

func NewTemplateFromDomain

func NewTemplateFromDomain(t *template.Template) Template

func (Template) ToDomain

func (t Template) ToDomain() *template.Template

Jump to

Keyboard shortcuts

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