Documentation ¶
Overview ¶
The query package provides the functionality to query records. By using reflections the package is structure-agnostic.
Index ¶
- Variables
- type DateTerm
- type DateTerms
- type Element
- type ElementGroup
- type Key
- type KeyValue
- type Keys
- type Output
- type OutputMode
- type Outputs
- type Queryable
- type Queryables
- func (q Queryables) PPKeys(mode OutputMode)
- func (q Queryables) PPTypes()
- func (q Queryables) QueryAcc(s schema.Schema, termsInput, dateInput, selectInput string, mode OutputMode, ...)
- func (q Queryables) QueryablesFromUserInput(input string) (Queryables, error)
- func (q Queryables) String() string
- func (q Queryables) Types() []string
- type SearchTerm
- type SearchTerms
Constants ¶
This section is empty.
Variables ¶
View Source
var AccQueryables = Queryables{ { Name: "customer", Type: schema.Party{}, }, { Name: "employee", Type: schema.Party{}, }, { Name: "expense", Type: schema.Expense{}, }, { Name: "invoice", Type: schema.Invoice{}, }, { Name: "misc-record", Type: schema.MiscRecord{}, }, { Name: "project", Type: schema.Project{}, }, { Name: "transaction", Type: schema.Transaction{}, }, }
Functions ¶
This section is empty.
Types ¶
type ElementGroup ¶
type ElementGroup []Element
func NewElements ¶
func NewElements(ele interface{}) ElementGroup
func (ElementGroup) DateMatch ¶
func (g ElementGroup) DateMatch(ranges DateTerms) ElementGroup
func (ElementGroup) MatchTerm ¶
func (g ElementGroup) MatchTerm(terms SearchTerms, caseSensitive bool) ElementGroup
func (ElementGroup) Select ¶
func (g ElementGroup) Select(sel []string, caseSensitive bool) ElementGroup
type Key ¶
type Key struct { Name string Queryables Queryables }
type Output ¶
func (Output) OpenAttachment ¶
func (o Output) OpenAttachment()
func (Output) PPKeyValue ¶
func (o Output) PPKeyValue(a *schema.Schema, mode OutputMode, render bool)
type Outputs ¶
type Outputs []Output
func (Outputs) PPKeyValue ¶
func (o Outputs) PPKeyValue(s schema.Schema, mode OutputMode, render, openAttachment bool)
type Queryables ¶
type Queryables []Queryable
func (Queryables) PPKeys ¶
func (q Queryables) PPKeys(mode OutputMode)
func (Queryables) PPTypes ¶
func (q Queryables) PPTypes()
func (Queryables) QueryAcc ¶
func (q Queryables) QueryAcc(s schema.Schema, termsInput, dateInput, selectInput string, mode OutputMode, render, caseSensitive, openAttachment bool)
func (Queryables) QueryablesFromUserInput ¶
func (q Queryables) QueryablesFromUserInput(input string) (Queryables, error)
func (Queryables) String ¶
func (q Queryables) String() string
func (Queryables) Types ¶
func (q Queryables) Types() []string
type SearchTerms ¶
type SearchTerms []SearchTerm
Click to show internal directories.
Click to hide internal directories.