multivers

package module
v0.0.0-...-c1580fa Latest Latest
Warning

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

Go to latest
Published: Sep 16, 2020 License: GPL-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AdministrationGroupListPath = "/api/AdministrationGroupList"
)
View Source
const (
	AdministrationInfoListPath = "/api/AdministrationInfoList"
)
View Source
const (
	AdministrationPath = "/api/administration"
)
View Source
const (
	CustomerInfoListPath = "api/%s/CustomerInfoList.json"
)
View Source
const (
	CustomerInvoicePath = "/api/%s/CustomerInvoice/%s.json"
)
View Source
const (
	FinTransPath = "/api/%s/FinTrans"
)
View Source
const (
	JournalInfoPath = "/api/%s/JournalInfo/%d"
)
View Source
const (
	ProductGroupNVLPath = "/api/%s/ProductGroupNVL"
)
View Source
const (
	ProductGroupPath = "/api/%s/ProductGroup/%s.json"
)
View Source
const (
	ProductInfoListPath = "/ProductInfoList"
)
View Source
const (
	ProductTypeNVLPath = "/ProductTypeNVL"
)
View Source
const (
	ProjectEntryTypeNVLPath = "/ProjectEntryTypeNVL"
)
View Source
const (
	VatCodeInfoListPath = "/VatCodeInfoList"
)
View Source
const (
	VatCodeInfoPath = "/api/%s/VatCodeInfo/%d.json"
)

Variables

This section is empty.

Functions

func CheckResponse

func CheckResponse(r *http.Response) error

CheckResponse checks the API response for errors, and returns them if present. A response is considered an error if it has a status code outside the 200 range. API error responses are expected to have either no response body, or a XML response body that maps to ErrorResponse. Any other response body will be silently ignored.

func GetNewOauth2Token

func GetNewOauth2Token(oauthConfig *oauth2.Config, linkCallback LinkHandler, authorizationCallback AuthorizationHandler, tokenCallback TokenHandler) (*oauth2.Token, error)

func NewOauth2Config

func NewOauth2Config(baseURL *url.URL) *oauth2.Config

Types

type Administration

type Administration struct {
	BackupDate          string   `json:"backupDate"`
	Version             int      `json:"version"`
	GroupID             int      `json:"groupId"`
	Code                string   `json:"code"`
	ShortName           string   `json:"shortName"`
	PreviousOnlineState int      `json:"previousOnlineState"`
	OnlineState         int      `json:"onlineState"`
	Description         string   `json:"description"`
	AdministrationID    string   `json:"administrationId"`
	Users               []string `json:"users"`
	ReportPath          string   `json:"reportPath"`
}

type AdministrationGetResponse

type AdministrationGetResponse Administration

func NewAdministrationGetResponse

func NewAdministrationGetResponse() *AdministrationGetResponse

type AdministrationGroup

type AdministrationGroup struct {
}

type AdministrationGroupListGetResponse

type AdministrationGroupListGetResponse []AdministrationGroup

func NewAdministrationGroupListGetResponse

func NewAdministrationGroupListGetResponse() *AdministrationGroupListGetResponse

type AdministrationGroupListService

type AdministrationGroupListService struct {
	Client *Client
}

func NewAdministrationGroupListService

func NewAdministrationGroupListService(client *Client) *AdministrationGroupListService

func (*AdministrationGroupListService) Get

type AdministrationInfoListGetResponse

type AdministrationInfoListGetResponse []Administration

func NewAdministrationInfoListGetResponse

func NewAdministrationInfoListGetResponse() *AdministrationInfoListGetResponse

type AdministrationInfoListService

type AdministrationInfoListService struct {
	Client *Client
}

func NewAdministrationInfoListService

func NewAdministrationInfoListService(client *Client) *AdministrationInfoListService

func (*AdministrationInfoListService) Get

type AdministrationService

type AdministrationService struct {
	Client *Client
}

func NewAdministrationService

func NewAdministrationService(client *Client) *AdministrationService

func (*AdministrationService) Get

func (s *AdministrationService) Get(administrationID string, ctx context.Context) (*AdministrationGetResponse, error)

type AuthorizationHandler

type AuthorizationHandler func(string) error

type Client

type Client struct {

	// Url pointing to base Unit4 Multivers API
	BaseURL *url.URL

	// Debugging flag
	Debug bool

	// User agent for client
	UserAgent string

	// General data
	Administration          *AdministrationService
	AdministrationInfoList  *AdministrationInfoListService
	AdministrationGroupList *AdministrationGroupListService

	// Administration data
	ProductInfoList         *ProductInfoListService
	ProductTypeNVL          *ProductTypeNVLService
	ProjectEntryTypeNVL     *ProjectEntryTypeNVLService
	VatCodeInfo             *VatCodeInfoService
	VatCodeInfoList         *VatCodeInfoListService
	ProductGroupNVL         *ProductGroupNVLService
	ProductGroup            *ProductGroupService
	CustomerInvoiceInfoList *CustomerInvoiceInfoListService
	CustomerInvoice         *CustomerInvoiceService
	FinTrans                *FinTransService
	JournalInfo             *JournalInfoService
	CustomerInfoList        *CustomerInfoListService
	// contains filtered or unexported fields
}

Client manages communication with Unit4 Multivers API

func NewClient

func NewClient(httpClient *http.Client, baseURL *url.URL) *Client

NewClient returns a new Unit4 Multivers API client

func (*Client) Do

func (c *Client) Do(req *http.Request, responseBody interface{}) (*http.Response, error)

Do sends an API request and returns the API response. The API response is XML decoded and stored in the value pointed to by v, or returned as an error if an API error has occurred. If v implements the io.Writer interface, the raw response will be written to v, without attempting to decode it.

func (*Client) GetEndpoint

func (c *Client) GetEndpoint(path string) *url.URL

func (*Client) NewRequest

func (c *Client) NewRequest(ctx context.Context, method, path string, body interface{}) (*http.Request, error)

func (*Client) SetBaseURL

func (c *Client) SetBaseURL(baseURL *url.URL)

func (*Client) SetDebug

func (c *Client) SetDebug(debug bool)

func (*Client) SetSandbox

func (c *Client) SetSandbox(sandbox bool)

type CustomerInfoList

type CustomerInfoList struct {
	AccountManagerID    string `json:"accountManagerId"`
	ApplyOrderSurcharge bool   `json:"applyOrderSurcharge"`
	BusinessNumber      string `json:"businessNumber"`
	ChargeVatTypeID     int    `json:"chargeVatTypeId"`
	City                string `json:"city"`
	CocCity             string `json:"cocCity"`
	CocDate             *Time  `json:"cocDate"`
	CocRegistration     string `json:"cocRegistration"`
	ContactPerson       string `json:"contactPerson"`
	CountryID           string `json:"countryId"`
	CreditSqueezeID     string `json:"creditSqueezeId"`
	CurrencyID          string `json:"currencyId"`
	CustomerID          string `json:"customerId"`
	CustomerStateID     string `json:"customerStateId"`
	DateChanged         *Time  `json:"dateChanged"`
	DateCreated         *Time  `json:"dateCreated"`
	Email               string `json:"email"`
	Fax                 string `json:"fax"`
	Homepage            string `json:"homepage"`
	IsDunForPayment     bool   `json:"isDunForPayment"`
	LanguageID          string `json:"languageId"`
	MobilePhone         string `json:"mobilePhone"`
	Name                string `json:"name"`
	OrganizationID      int    `json:"organizationId"`
	PaymentConditionID  string `json:"paymentConditionId"`
	RevenueAccountID    string `json:"revenueAccountId"`
	ShortName           string `json:"shortName"`
	Street1             string `json:"street1"`
	Street2             string `json:"street2"`
	Telephone           string `json:"telephone"`
	VatNumber           string `json:"vatNumber"`
	VatScenarioID       int    `json:"vatScenarioId"`
	VatVerificationDate *Time  `json:"vatVerificationDate"`
	ZipCode             string `json:"zipCode"`
}

type CustomerInfoListGetResponse

type CustomerInfoListGetResponse []CustomerInfoList

func NewCustomerInfoListGetResponse

func NewCustomerInfoListGetResponse() *CustomerInfoListGetResponse

type CustomerInfoListService

type CustomerInfoListService struct {
	Client *Client
}

func NewCustomerInfoListService

func NewCustomerInfoListService(client *Client) *CustomerInfoListService

func (*CustomerInfoListService) Get

type CustomerInvoice

type CustomerInvoice struct {
	AccountManager         string                `json:"accountManager"`
	AccountManagerID       string                `json:"accountManagerId"`
	Messages               []Message             `json:"messages"`
	AmountCreditSqueeze    float64               `json:"amountCreditSqueeze"`
	AmountCreditSqueezeCur float64               `json:"amountCreditSqueezeCur"`
	AmountRebate           float64               `json:"amountRebate"`
	AmountRebateCur        float64               `json:"amountRebateCur"`
	AmountTotal            float64               `json:"amountTotal"`
	AmountTotalCur         float64               `json:"amountTotalCur"`
	BordereauxNumber       string                `json:"bordereauxNumber"`
	CanChange              bool                  `json:"canChange"`
	ContactPerson          string                `json:"contactPerson"`
	ContactPersonID        string                `json:"contactPersonId"`
	CurrencyID             string                `json:"currencyId"`
	CustomerID             string                `json:"customerId"`
	CustomerInvoiceLinces  []CustomerInvoiceLine `json:"customerInvoiceLines"`
	DocumentNumber         int                   `json:"documentNumber"`
	DunForPayment          bool                  `json:"dunForPayment"`
	ExchangeRate           float64               `json:"exchangeRate"`
	FiscalYear             int                   `json:"fiscalYear"`
	InvoiceDate            DateNLNL              `json:"invoiceDate"`
	InvoiceExpirationDate  DateNLNL              `json:"invoiceExpirationDate"`
	InvoiceID              string                `json:"invoiceId"`
	InvoiceType            InvoiceType           `json:"invoiceType"`
	JournalID              string                `json:"journalId"`
	JournalSection         string                `json:"journalSection"`
	JournalTransaction     int                   `json:"journalTransaction"`
	KvcPaymentCondition    bool                  `json:"kvcPaymentCondition"`
	MandateID              string                `json:"mandateId"`
	NumberOfReminder       int                   `json:"numberOfReminders"`
	OpeningBalance         bool                  `json:"openingBalance"`
	OrderID                string                `json:"orderId"`
	PaymentConditionID     string                `json:"paymentConditionId"`
	PaymentReference       string                `json:"paymentReference"`
	PeriodNumber           int                   `json:"periodNumber"`
	ProcessedBy            string                `json:"processedBy"`
	ProcessedByID          string                `json:"processedById"`
	RebateExpirationDate   string                `json:"rebateExpirationDate"`
	Reference              string                `json:"reference"`
	SystemInvoice          bool                  `json:"systemInvoice"`
	TotalAmountVatExcl     float64               `json:"totalAmountVatExcl"`
	TotalAmountVatExclCur  float64               `json:"totalAmountVatExclCur"`
	VatAdjusted            bool                  `json:"vatAdjusted"`
	VatAmount              float64               `json:"vatAmount"`
	VatAmountCur           float64               `json:"vatAmountCur"`
	VatOnInvoice           bool                  `json:"vatOnInvoice"`
	VatScenarioID          int                   `json:"vatScenarioId"`
	VatTransactionLines    []VatTransactionLine  `json:"vatTransactionLines"`
}

type CustomerInvoiceGetResponse

type CustomerInvoiceGetResponse CustomerInvoice

type CustomerInvoiceInfo

type CustomerInvoiceInfo struct {
	City                      string                    `json:"city"`
	ContactPerson             string                    `json:"contactPerson"`
	CreditSqueezeRemaining    float64                   `json:"creditSqueezeRemaining"`
	CreditSqueezeRemainingCur float64                   `json:"creditSqueezeRemainingCur"`
	CurrencyDescription       string                    `json:"currencyDescription"`
	CurrencyID                string                    `json:"currencyId"`
	CurrentExchangeRate       float64                   `json:"currentExchangeRate"`
	CustomerID                string                    `json:"customerId"`
	CustomerInvoiceLines      []CustomerInvoiceInfoLine `json:"customerInvoiceLines"`
	CustomerName              string                    `json:"customerName"`
	DaysOld                   int                       `json:"daysOld"`
	DunForPayment             bool                      `json:"dunForPayment"`
	ExchangeRate              float64                   `json:"exchangeRate"`
	FiscalYear                int                       `json:"fiscalYear"`
	InvoiceAmount             float64                   `json:"invoiceAmount"`
	InvoicieAmountCur         float64                   `json:"invoiceAmountCur"`
	InvoiceBalance            float64                   `json:"invoiceBalance"`
	InvoiceBalanceCur         float64                   `json:"invoiceBalanceCur"`
	InvoiceDate               DateNLNL                  `json:"invoiceDate"`
	InvoiceExpirationDate     DateNLNL                  `json:"invoiceExpirationDate"`
	InvoiceID                 string                    `json:"invoiceId"`
	InvoiceReference          string                    `json:"invoiceReference"`
	IsAdvance                 bool                      `json:"isAdvance"`
	Name                      string                    `json:"name"`
	PaymentConditionID        string                    `json:"paymentConditionId"`
	PaymentDate               DateNLNL                  `json:"paymentDate"`
	PaymentReference          string                    `json:"paymentReference"`
	PhoneNumber               string                    `json:"phoneNumber"`
	RebateExpirationDate      DateNLNL                  `json:"rebateExpirationDate"`
	RebateRemaining           float64                   `json:"rebateRemaining"`
	RebateRemainingCur        float64                   `json:"rebateRemainingCur"`
	ReminderCount             float64                   `json:"reminderCount"`
	SettledAmount             float64                   `json:"settledAmount"`
	SettledAmountCur          float64                   `json:"settledAmountCur"`
	Shortname                 string                    `json:"shortName"`
	State                     InvoiceState              `json:"state"`
	Street                    string                    `json:"street"`
	TurnoverAmount            float64                   `json:"turnoverAmount"`
	VatAmount                 float64                   `json:"vatAmount"`
	VatAmountCur              float64                   `json:"vatAmountCur"`
	ZipCode                   string                    `json:"zipCode"`
}

type CustomerInvoiceInfoLine

type CustomerInvoiceInfoLine struct {
	Amount        float64 `json:"amount"`
	AmountCur     float64 `json:"amountCur"`
	Description   string  `json:"description"`
	Permanence    bool    `json:"permanence"`
	VatCodeID     int     `json:"vatCodeId"`
	VatPercentage float64 `json:"vatPercentage"`
}

type CustomerInvoiceInfoListByFiscalYearGetParams

type CustomerInvoiceInfoListByFiscalYearGetParams struct {
	CustomerID string `schema:"id,omitempty"`
}

func (*CustomerInvoiceInfoListByFiscalYearGetParams) FromQueryParams

func (p *CustomerInvoiceInfoListByFiscalYearGetParams) FromQueryParams(queryParams url.Values) error

type CustomerInvoiceInfoListByFiscalYearGetResponse

type CustomerInvoiceInfoListByFiscalYearGetResponse []CustomerInvoiceInfo

type CustomerInvoiceInfoListByIDGetParams

type CustomerInvoiceInfoListByIDGetParams struct {
	StartDate    DateNLNL     `schema:"startDate,omitempty"`
	EndDate      DateNLNL     `schema:"endDate,omitempty"`
	InvoiceState InvoiceState `schema:"invoiceState,omitempty"`
}

func (*CustomerInvoiceInfoListByIDGetParams) FromQueryParams

func (p *CustomerInvoiceInfoListByIDGetParams) FromQueryParams(queryParams url.Values) error

type CustomerInvoiceInfoListByIDGetResponse

type CustomerInvoiceInfoListByIDGetResponse []CustomerInvoiceInfo

type CustomerInvoiceInfoListService

type CustomerInvoiceInfoListService struct {
	Client *Client
}

func NewCustomerInvoiceInfoListService

func NewCustomerInvoiceInfoListService(client *Client) *CustomerInvoiceInfoListService

func (*CustomerInvoiceInfoListService) GetByFiscalYear

func (*CustomerInvoiceInfoListService) GetByID

func (*CustomerInvoiceInfoListService) NewByFiscalYearGetParams

func (*CustomerInvoiceInfoListService) NewByFiscalYearGetResponse

func (*CustomerInvoiceInfoListService) NewByIDGetParams

func (*CustomerInvoiceInfoListService) NewByIDGetResponse

type CustomerInvoiceLine

type CustomerInvoiceLine struct {
	AccountID                       string        `json:"accountId"`
	Messages                        []Message     `json:"messages"`
	CanChange                       bool          `json:"canChange"`
	CostCentreID                    string        `json:"costCentreId"`
	CostCentreIDRequired            bool          `json:"costCentreIdRequired"`
	CostUnitID                      string        `json:"costUnitId"`
	CostUnitIDRequired              bool          `json:"costUnitIdRequired"`
	CreditAmount                    float64       `json:"creditAmount"`
	CreditAmountCur                 float64       `json:"creditAmountCur"`
	CurrencyID                      string        `json:"currencyId"`
	DebitAmount                     float64       `json:"debitAmount"`
	DebitAmountCur                  float64       `json:"debitAmountCur"`
	Description                     string        `json:"description"`
	DocumentNumber                  int           `json:"documentNumber"`
	ExchangeRate                    float64       `json:"exchangeRate"`
	IsSubAdminSpecificationRequired bool          `json:"isSubAdminSpecificationRequired"`
	JournalSection                  int           `json:"journalSection"`
	LineNumbers                     []int         `json:"lineNumbers"`
	Quantity                        float64       `json:"quantity"`
	SubAdminSpecifications          []interface{} `json:"subAdminSpecifications"`
	TransactionDate                 string        `json:"transactionDate"`
	VatCodeID                       int           `json:"vatCodeId"`
	VatType                         int           `json:"vatType"`
}

type CustomerInvoiceService

type CustomerInvoiceService struct {
	Client *Client
}

func NewCustomerInvoiceService

func NewCustomerInvoiceService(client *Client) *CustomerInvoiceService

func (*CustomerInvoiceService) Get

func (*CustomerInvoiceService) NewGetResponse

type DateNLNL

type DateNLNL struct {
	date.Date
}

func NewDateNLNL

func NewDateNLNL(year int, month time.Month, day int) DateNLNL

func (*DateNLNL) MarshalJSON

func (d *DateNLNL) MarshalJSON() ([]byte, error)

func (*DateNLNL) UnmarshalJSON

func (d *DateNLNL) UnmarshalJSON(text []byte) (err error)

type ErrorResponse

type ErrorResponse struct {
	// HTTP response that caused this error
	Response *http.Response

	// HTTP status code
	Code int

	// Fault message
	Message string `json:"Message"`
}

func (*ErrorResponse) Error

func (r *ErrorResponse) Error() string

type FinTrans

type FinTrans struct {
	JournalID          string          `json:"journalId"`
	FiscalYear         int             `json:"fiscalYear"`
	JournalTransaction int             `json:"journalTransaction,omitempty"`
	PeriodNumber       int             `json:"periodNumber"`
	TransactionDate    string          `json:"transactionDate"`
	Description        string          `json:"description"`
	Document           string          `json:"document"`
	FinTransEntries    FinTransEntries `json:"finTransEntries"`
}

type FinTransEntries

type FinTransEntries []FinTransEntry

type FinTransEntry

type FinTransEntry struct {
	Type                       string          `json:"$type,omitempty"`                      // "UNIT4.Multivers.API.BL.Financial.Edit.BasicEntryProxy, UNIT4.Multivers.API.Web.WebApi.Model",
	AccountID                  string          `json:"accountId,omitempty"`                  // "4500",
	CostCentreID               string          `json:"costCentreId,omitempty"`               //"",
	CostCentreIDRequired       bool            `json:"costCentreIdRequired,omitempty"`       //false
	CostUnitID                 string          `json:"costUnitId,omitempty"`                 //""
	CostUnitIDRequired         bool            `json:"costUnitIdRequired,omitempty"`         //false,
	CreditAmount               decimal.Decimal `json:"creditAmount"`                         //100.00,
	DebitAmount                decimal.Decimal `json:"debitAmount"`                          //0.0,
	Description                string          `json:"description,omitempty"`                //"Test Basicentry",
	Document                   string          `json:"document,omitempty"`                   //"",
	NonDeductibleVatPercentage float64         `json:"nondeductibleVatPercentage,omitempty"` // 0.0,
	Quantity                   float64         `json:"quantity,omitempty"`                   // 0.0,
	TransactionDate            string          `json:"transactionDate,omitempty"`            // "28-2-2018",
	VatAmount                  decimal.Decimal `json:"vatAmount,omitempty"`                  // 17.36,
	VatChanged                 bool            `json:"vatChanged,omitempty"`                 // false,
	VatCodeID                  int             `json:"vatCodeId,omitempty"`                  // 2,
	VatIncluded                bool            `json:"vatIncluded,omitempty"`                // true,
	VatScenarioID              int             `json:"vatScenarioId,omitempty"`              // 6,
	VatType                    int             `json:"vatType,omitempty"`                    // 0
}

type FinTransGetResponse

type FinTransGetResponse FinTrans

type FinTransService

type FinTransService struct {
	Client *Client
}

func NewFinTransService

func NewFinTransService(client *Client) *FinTransService

func (*FinTransService) NewGetResponse

func (s *FinTransService) NewGetResponse() *FinTransGetResponse

func (*FinTransService) Post

func (s *FinTransService) Post(database string, finTrans FinTrans, ctx context.Context) (*FinTransGetResponse, error)

type InvoiceState

type InvoiceState int
const (
	CustomerInvoiceInfoListByFiscalYearPath              = "api/%s/CustomerInvoiceInfoList/ByFiscalYear/%d/%d.json"
	CustomerInvoiceInfoListByIDPath                      = "api/%s/CustomerInvoiceInfoList/%s.json"
	InvoiceStateAny                         InvoiceState = 0
	InvoiceStateOpen                        InvoiceState = 1
	InvoiceStatePayedInFull                 InvoiceState = 2
)

type InvoiceType

type InvoiceType int

type JournalInfo

type JournalInfo struct {
	AccountID                     string  `json:"accountId"`
	JournalID                     string  `json:"journalId"`
	AmendmentBalance              float64 `json:"amendmentBalance"`
	BankAccountID                 string  `json:"bankAccountId"`
	CurrencyID                    string  `json:"currencyId"`
	Description                   string  `json:"description"`
	EndBalance                    float64 `json:"endBalance"`
	EntriesToMatchCount           int     `json:"entriesToMatchCount"`
	FiscalYear                    int     `json:"fiscalYear"`
	JournalKind                   int     `json:"journalKind"`
	JournalTransaction            int     `json:"journalTransaction"`
	JournalType                   int     `json:"journalType"`
	LastElectronicTransactionDate string  `json:"lastEletronicTransactionDate"`
	LastTransactionDate           string  `json:"lastTransactionDate"`
	OpeningBalanceJournal         bool    `json:"openingBalanceJournal"`
	RangeID                       string  `json:"rangeId"`

	SheetNumberDay    int     `json:"sheetNumberDay"`
	SheetNumberPeriod int     `json:"sheetNumberPeriod"`
	StartBalance      float64 `json:"startBalance"`
	// contains filtered or unexported fields
}

type JournalInfoGetParams

type JournalInfoGetParams struct {
	FiscalYear int `schema:"fiscalYear"`
}

func NewJournalInfoGetParams

func NewJournalInfoGetParams() *JournalInfoGetParams

type JournalInfoGetResponse

type JournalInfoGetResponse JournalInfo

func NewJournalInfoGetResponse

func NewJournalInfoGetResponse() *JournalInfoGetResponse

type JournalInfoService

type JournalInfoService struct {
	Client *Client
}

func NewJournalInfoService

func NewJournalInfoService(client *Client) *JournalInfoService

func (*JournalInfoService) Get

func (s *JournalInfoService) Get(database string, journalId int, requestParams *JournalInfoGetParams, ctx context.Context) (*JournalInfoGetResponse, error)

type LinkHandler

type LinkHandler func(*url.URL) error

type Message

type Message struct {
}

type NVL

type NVL struct {
	Name  string `json:"name"`
	Value string `json:"value"`
}

type ProductGroup

type ProductGroup struct {
	Messages                   []Message `json:"messages"`
	CanChange                  bool      `json:"canChange"`
	Description                string    `json:"description"`
	ProductGroupID             string    `json:"productGroupId"`
	ProjectSurchargePercentage float64   `json:"projectSurchargePercentage"`
}

type ProductGroupGetResponse

type ProductGroupGetResponse ProductGroup

func NewProductGroupGetResponse

func NewProductGroupGetResponse() *ProductGroupGetResponse

type ProductGroupNVLGetResponse

type ProductGroupNVLGetResponse []NVL

func NewProductGroupNVLGetResponse

func NewProductGroupNVLGetResponse() *ProductGroupNVLGetResponse

type ProductGroupNVLService

type ProductGroupNVLService struct {
	Client *Client
}

func NewProductGroupNVLService

func NewProductGroupNVLService(client *Client) *ProductGroupNVLService

func (*ProductGroupNVLService) Get

type ProductGroupService

type ProductGroupService struct {
	Client *Client
}

func NewProductGroupService

func NewProductGroupService(client *Client) *ProductGroupService

func (*ProductGroupService) Get

func (s *ProductGroupService) Get(database string, productGroupID string, ctx context.Context) (*ProductGroupGetResponse, error)

type ProductInfo

type ProductInfo struct {
	VatCodeID          int      `json:"vatCodeId"`
	EanCode            string   `json:"eanCode"`
	ProductState       int      `json:"productState"`
	DateCreated        DateNLNL `json:"dateCreated"`
	QuantityScale      int      `json:"quantityScale"`
	ShortName          string   `json:"shortName"`
	PriceExclVat       float64  `json:"priceExclVat"`
	Description        string   `json:"description"`
	ProductGroupID     string   `json:"productGroupId"`
	ProjectSurcharge   float64  `json:"projectSurcharge"`
	PriceInclVat       float64  `json:"priceInclVat"`
	ProductID          string   `json:"productId"`
	TechnicalStock     float64  `json:"technicalStock"`
	LastUpdate         DateNLNL `json:"lastUpdate"`
	StockTransferPrice float64  `json:"stockTransferPrice"`
	DiscountAccountID  string   `json:"discountAccountId"`
	Unit               string   `json:"unit"`
	ProjectEntryType   string   `json:"projectEntryType"`
	ProductType        int      `json:"productType"`
	AccountID          string   `json:"accountId"`
	PricePer           float64  `json:"pricePer"`
}

type ProductInfoListGetParams

type ProductInfoListGetParams struct {
	ProductID      string `schema:"productId"`
	ShortName      string `schema:"shortName"`
	Description    string `schema:"description"`
	ProductGroupID string `schema:"productGroupId"`
}

func NewProductInfoListGetParams

func NewProductInfoListGetParams() *ProductInfoListGetParams

func (*ProductInfoListGetParams) FromQueryParams

func (p *ProductInfoListGetParams) FromQueryParams(queryParams url.Values) error

type ProductInfoListGetResponse

type ProductInfoListGetResponse []ProductInfo

func NewProductInfoListGetResponse

func NewProductInfoListGetResponse() *ProductInfoListGetResponse

type ProductInfoListService

type ProductInfoListService struct {
	Client *Client
}

func NewProductInfoListService

func NewProductInfoListService(client *Client) *ProductInfoListService

func (*ProductInfoListService) Get

type ProductTypeNVLGetResponse

type ProductTypeNVLGetResponse []NVL

func NewProductTypeNVLGetResponse

func NewProductTypeNVLGetResponse() *ProductTypeNVLGetResponse

type ProductTypeNVLService

type ProductTypeNVLService struct {
	Client *Client
}

func NewProductTypeNVLService

func NewProductTypeNVLService(client *Client) *ProductTypeNVLService

func (*ProductTypeNVLService) Get

type ProjectEntryTypeNVLGetResponse

type ProjectEntryTypeNVLGetResponse []NVL

func NewProjectEntryTypeNVLGetResponse

func NewProjectEntryTypeNVLGetResponse() *ProjectEntryTypeNVLGetResponse

type ProjectEntryTypeNVLService

type ProjectEntryTypeNVLService struct {
	Client *Client
}

func NewProjectEntryTypeNVLService

func NewProjectEntryTypeNVLService(client *Client) *ProjectEntryTypeNVLService

func (*ProjectEntryTypeNVLService) Get

type RequestCompletionCallback

type RequestCompletionCallback func(*http.Request, *http.Response)

RequestCompletionCallback defines the type of the request callback function

type Time

type Time struct {
	time.Time
}

func (*Time) MarshalJSON

func (t *Time) MarshalJSON() ([]byte, error)

func (*Time) UnmarshalJSON

func (t *Time) UnmarshalJSON(text []byte) (err error)

type TokenHandler

type TokenHandler func(*oauth2.Token) error

type VatCodeInfo

type VatCodeInfo struct {
	Description   string  `json:"description"`
	VatCodeID     int     `json:"vatCodeID"`
	VatPercentage float64 `json:"vatPercentage"`
}

type VatCodeInfoGetResponse

type VatCodeInfoGetResponse VatCodeInfo

func NewVatCodeInfoGetResponse

func NewVatCodeInfoGetResponse() *VatCodeInfoGetResponse

type VatCodeInfoListGetResponse

type VatCodeInfoListGetResponse []VatCodeInfo

func NewVatCodeInfoListGetResponse

func NewVatCodeInfoListGetResponse() *VatCodeInfoListGetResponse

type VatCodeInfoListService

type VatCodeInfoListService struct {
	Client *Client
}

func NewVatCodeInfoListService

func NewVatCodeInfoListService(client *Client) *VatCodeInfoListService

func (*VatCodeInfoListService) Get

type VatCodeInfoService

type VatCodeInfoService struct {
	Client *Client
}

func NewVatCodeInfoService

func NewVatCodeInfoService(client *Client) *VatCodeInfoService

func (*VatCodeInfoService) Get

func (s *VatCodeInfoService) Get(database string, vatCodeID int, ctx context.Context) (*VatCodeInfoGetResponse, error)

type VatTransactionLine

type VatTransactionLine struct {
	Messages               []Message `json:"messages"`
	AmountNotDeductibleCur float64   `json:"amountNotDeductibleCur"`
	AmountTurnoverCur      float64   `json:"amountTurnoverCur"`
	CanChange              bool      `json:"canChange"`
	CurrencyID             string    `json:"currencyId"`
	FiscalYear             int       `json:"fiscalYear"`
	VatAmountCur           float64   `json:"vatAmountCur"`
	VatCodeID              int       `json:"vatCodeId"`
	VatScenarioID          int       `json:"vatScenarioId"`
	VatType                int       `json:"vatType"`
}

Jump to

Keyboard shortcuts

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