Documentation
¶
Index ¶
- Constants
- func ConsumptionListToString(consumptions []Consumption, child Child, products []Product) string
- type Address
- type Adult
- type Child
- type Consumption
- type Customer
- func (c Customer) ChildrenNames(joinWith string) string
- func (c Customer) ChildrenNamesWithId(joinWith string) string
- func (c Customer) ChildrenNamesWithSurname(joinWith string) string
- func (c Customer) FirstAdult() Adult
- func (c Customer) FirstAdultName() string
- func (c Customer) FirstAdultNameWithId() string
- func (c Customer) String() string
- type Invoice
- type InvoiceHolder
- type Line
- type Product
- type Sequence
Constants ¶
View Source
const ConsumptionIdLength = 8
Variables ¶
This section is empty.
Functions ¶
func ConsumptionListToString ¶
func ConsumptionListToString(consumptions []Consumption, child Child, products []Product) string
Types ¶
type Address ¶
func (Address) CompleteAddress ¶ added in v0.18.0
type Adult ¶
type Adult struct {
Name string
Surname string
SecondSurname string
TaxID string
Role adult_role.AdultRole
Address Address
Email string
MobilePhone string
HomePhone string
GrandMotherPhone string
GrandParentPhone string
WorkPhone string
BirthDate time.Time
Nationality string
}
func (Adult) MobilePhoneFmt ¶
func (Adult) NameAndSurname ¶ added in v0.18.0
type Child ¶
type Child struct {
Id int
Name string
Surname string
SecondSurname string
TaxID string
BirthDate time.Time
Group group_type.GroupType
Note string
Active bool
}
func (Child) NameAndSurname ¶
func (Child) NameWithId ¶
type Consumption ¶
type Consumption struct {
Id string
ChildId int
ProductId string
Units float64
YearMonth string
Note string
IsRectification bool
InvoiceId string
}
func (Consumption) String ¶
func (c Consumption) String() string
type Customer ¶
type Customer struct {
Id int
Active bool
Children []Child
Adults []Adult
InvoiceHolder InvoiceHolder
Note string
Language language.Language
ChangedOn time.Time
}
func (Customer) ChildrenNames ¶
func (Customer) ChildrenNamesWithId ¶ added in v0.18.0
func (Customer) ChildrenNamesWithSurname ¶ added in v0.18.0
func (Customer) FirstAdult ¶
func (Customer) FirstAdultName ¶
func (Customer) FirstAdultNameWithId ¶
type Invoice ¶
type InvoiceHolder ¶
type InvoiceHolder struct {
Name string
TaxID string
Address Address
Email string
SendEmail bool
PaymentType payment_type.PaymentType
BankAccount string
IsBusiness bool
}
func (InvoiceHolder) BankAccountFmt ¶
func (i InvoiceHolder) BankAccountFmt() string
func (InvoiceHolder) Mail ¶
func (i InvoiceHolder) Mail() string
func (InvoiceHolder) PaymentInfoFmt ¶
func (i InvoiceHolder) PaymentInfoFmt() string
type Product ¶
type Product struct {
Id string
Name string
ShortName string
Price float64
TaxPercentage float64
IsSubsidy bool
}
func GetProduct ¶
type Sequence ¶
type Sequence struct {
Id sequence_type.SequenceType
Counter int
}
Source Files
¶
Click to show internal directories.
Click to hide internal directories.