40 lines
1.2 KiB
Go
40 lines
1.2 KiB
Go
package vo
|
|
|
|
import (
|
|
"electricity_bill_calc/model"
|
|
"electricity_bill_calc/types"
|
|
|
|
"github.com/shopspring/decimal"
|
|
)
|
|
|
|
type InvoiceResponse struct {
|
|
No string `json:"no" copier:"InvoiceNo"`
|
|
Tenement string `json:"tenement"`
|
|
Title model.InvoiceTitle `json:"title" copier:"Info"`
|
|
IssuedAt types.DateTime `json:"issuedAt"`
|
|
Amount decimal.Decimal `json:"amount" copier:"Total"`
|
|
TaxMethod int16 `json:"taxMethod"`
|
|
TaxRate decimal.Decimal `json:"taxRate"`
|
|
InvoiceType string `json:"invoiceType" copier:"Type"`
|
|
}
|
|
|
|
type InvoiceCreationForm struct {
|
|
Park string `json:"park"`
|
|
Tenement string `json:"tenement"`
|
|
TaxMethod int16 `json:"taxMethod"`
|
|
TaxRate decimal.NullDecimal `json:"taxRate"`
|
|
Covers []string `json:"covers"`
|
|
}
|
|
|
|
type ExtendedInvoiceResponse struct {
|
|
InvoiceResponse
|
|
Cargos []*model.InvoiceCargo `json:"cargos"`
|
|
Covers []*model.SimplifiedTenementCharge `json:"covers"`
|
|
}
|
|
|
|
type ExtendedInvoiceCreationForm struct {
|
|
InvoiceCreationForm
|
|
InvoiceType *string `json:"invoiceType"`
|
|
InvoiceNo string `json:"invoiceNo"`
|
|
}
|