Skip to content

Commit

Permalink
Use generic interface{} instead of string for TemplateVar.templating.…
Browse files Browse the repository at this point in the history
…list.query (#151)

Return type varies depending on datasource
  • Loading branch information
hjet authored Jun 21, 2021
1 parent 354cd37 commit 90d3283
Showing 1 changed file with 18 additions and 18 deletions.
36 changes: 18 additions & 18 deletions board.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,24 +79,24 @@ type (
List []TemplateVar `json:"list"`
}
TemplateVar struct {
Name string `json:"name"`
Type string `json:"type"`
Auto bool `json:"auto,omitempty"`
AutoCount *int `json:"auto_count,omitempty"`
Datasource *string `json:"datasource"`
Refresh BoolInt `json:"refresh"`
Options []Option `json:"options"`
IncludeAll bool `json:"includeAll"`
AllFormat string `json:"allFormat"`
AllValue string `json:"allValue"`
Multi bool `json:"multi"`
MultiFormat string `json:"multiFormat"`
Query string `json:"query"`
Regex string `json:"regex"`
Current Current `json:"current"`
Label string `json:"label"`
Hide uint8 `json:"hide"`
Sort int `json:"sort"`
Name string `json:"name"`
Type string `json:"type"`
Auto bool `json:"auto,omitempty"`
AutoCount *int `json:"auto_count,omitempty"`
Datasource *string `json:"datasource"`
Refresh BoolInt `json:"refresh"`
Options []Option `json:"options"`
IncludeAll bool `json:"includeAll"`
AllFormat string `json:"allFormat"`
AllValue string `json:"allValue"`
Multi bool `json:"multi"`
MultiFormat string `json:"multiFormat"`
Query interface{} `json:"query"`
Regex string `json:"regex"`
Current Current `json:"current"`
Label string `json:"label"`
Hide uint8 `json:"hide"`
Sort int `json:"sort"`
}
// for templateVar
Option struct {
Expand Down

0 comments on commit 90d3283

Please sign in to comment.