Documentation ¶
Index ¶
Constants ¶
View Source
const ( UblFormat = "ubl2.1" D16bFormat = "d16b" NotificationStatusNotSent = "not_sent" NotificationStatusSent = "sent" NotificationStatusSending = "sending" SlovakInvoiceParties = "slovakParties" ForeignSupplierParty = "foreignSupplier" ForeignCustomerParty = "foreignCustomer" InvoiceDocumentType = "invoice" CreditNoteDocumentType = "creditNote" Slovakia = "SK" )
Variables ¶
View Source
var DocumentTypes = []string{InvoiceDocumentType, CreditNoteDocumentType}
View Source
var InvoiceFormats = []string{UblFormat, D16bFormat}
View Source
var InvoicePartiesTypes = []string{SlovakInvoiceParties, ForeignSupplierParty, ForeignCustomerParty}
Functions ¶
func IcosToUris ¶
Types ¶
type Draft ¶
type Invoice ¶
type Invoice struct { Id string `json:"id"` CreatedAt *time.Time `json:"createdAt,omitempty" pg:"-"` Sender string `json:"sender"` Receiver string `json:"receiver"` Format string `json:"format"` Amount float64 `json:"amount"` AmountCurrency string `json:"amountCurrency"` AmountWithoutVat float64 `json:"amountWithoutVat"` AmountWithoutVatCurrency string `json:"amountWithoutVatCurrency"` SupplierIco string `json:"supplierIco"` SupplierCountry string `json:"-" pg:"-"` CustomerIco string `json:"customerIco"` CustomerCountry string `json:"-" pg:"-"` IssueDate timeutil.Date `json:"issueDate"` CreatedBy int `json:"createdBy"` // User id of invoice creator Test bool `json:"test"` NotificationsStatus string `json:"notificationsStatus"` VisualizationCreated bool `json:"-"` }
func (*Invoice) CalculateCreatedAt ¶
func (i *Invoice) CalculateCreatedAt()
Derive created at from id
func (*Invoice) GetInvoicePartiesType ¶
type Substitute ¶
Click to show internal directories.
Click to hide internal directories.