Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrorAccountExists = errors.New("account already exists") ErrorAccountNotFound = errors.New("account not found") )
Functions ¶
This section is empty.
Types ¶
type Account ¶
type Account struct { ID uint64 `json:"id"` Name string `json:"name"` Description *string `json:"description"` Type AccountType `json:"type"` Balance currency.Amount `json:"amount"` DeletedAt *datetime.DateTime `json:"delete_at"` CreatedAt datetime.DateTime `json:"created_at"` UpdateAt datetime.DateTime `json:"updated_at"` }
type AccountType ¶
type AccountType string
const ( AccountTypeCash AccountType = "cash" AccountTypeCredit AccountType = "credit" AccountTypeDebit AccountType = "debit" )
type Invoice ¶
type Invoice struct { ID uint64 `json:"id"` Name string `json:"name"` Desc *string `json:"description"` Status InvoiceStatus `json:"status"` Type InvoiceType `json:"type"` Template *InvoiceTemplate `json:"template"` Contact *Contact `json:"contact"` Transactions []Transaction `json:"transactions"` Amount currency.Amount `json:"amount"` Date datetime.DateTime `json:"date"` CreatedAt datetime.DateTime `json:"created_at"` UpdateAt datetime.DateTime `json:"updated_at"` }
type InvoiceStatus ¶
type InvoiceStatus string
const ( InvoiceStatusPending InvoiceStatus = "Pending" InvoiceStatusPaid InvoiceStatus = "Paid" )
type InvoiceTemplate ¶
type InvoiceTemplate struct { ID uint64 `json:"id"` Name string `json:"name"` Desc *string `json:"description"` Type InvoiceType `json:"type"` Amount currency.Amount `json:"amount"` RepeatPlanner *RepeatPlanner `json:"repeat_planner"` ContactID uint64 `json:"contact_id"` Date datetime.DateTime `json:"date"` DeletedAt *datetime.DateTime `json:"delete_at"` CreatedAt datetime.DateTime `json:"created_at"` UpdateAt datetime.DateTime `json:"updated_at"` }
type InvoiceType ¶
type InvoiceType string
const ( InvoiceTypeIncome InvoiceType = "Income" InvoiceTypeExpense InvoiceType = "Expense" )
type Period ¶
type RepeatPlanner ¶
Click to show internal directories.
Click to hide internal directories.