usecase

package
v0.0.0-...-354a747 Latest Latest
Warning

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

Go to latest
Published: Jul 15, 2025 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	NonUAE = "LUX"
	UAE    = "UAE"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type AccountConfig

type AccountConfig struct {
	GrantType    string `yaml:"grantType"`
	Audience     string `yaml:"audience"`
	TenantUUID   string `yaml:"tenantUUID"`
	ClientId     string `yaml:"clientId"`
	ClientSecret string `yaml:"clientSecret"`
}

private yaml

func NewConfigFromFile

func NewConfigFromFile(path string) *AccountConfig

type CreateJournalRequest

type CreateJournalRequest struct {
	Status       string        `json:"status"`
	EntryType    string        `json:"entryType"`
	SourceLedger string        `json:"sourceLedger"`
	Reference    string        `json:"reference"`
	Currency     string        `json:"currency"`
	Notes        string        `json:"notes"`
	Transactions []Transaction `json:"Transactions"`
}

Create journal

type Entry

type Entry struct {
	AccountName   string
	AccountNumber string
	Debit         string
	Credit        string
}

type Group

type Group struct {
	Entries  []*Entry
	Len      int
	Currency string
	Resident string
	Order    int
}

type LedgerAccount

type LedgerAccount struct {
	Id     int    `json:"_id"`
	Name   string `json:"name"`
	Number string `json:"number"`
}

type LedgerAccountResponse

type LedgerAccountResponse struct {
	TotalItems int             `json:"totalItems"`
	Data       []LedgerAccount `json:"data"`
}

type RequestTokenBody

type RequestTokenBody struct {
	GrantType    string `json:"grant_type"`
	Audience     string `json:"audience"`
	TenantUUID   string `json:"tenantUUID"`
	ClientId     string `json:"client_id"`
	ClientSecret string `json:"client_secret"`
}

type TokenResponse

type TokenResponse struct {
	AccessToken string `json:"access_token"`
	TokenType   string `json:"token_type"`
	ExpiresIn   string `json:"expires_in"`
	Scope       string `json:"scope"`
}

type Transaction

type Transaction struct {
	Description     string `json:"description"`
	Debit           string `json:"debit"`
	Credit          string `json:"credit"`
	TransactionDate string `json:"transactionDate"`
	PostedDate      string `json:"postedDate"`
	LedgerAccountId int    `json:"LedgerAccountId"`
	LocationId      int    `json:"LocationId"`
}

Jump to

Keyboard shortcuts

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