Documentation ¶
Index ¶
- Variables
- func AddCharge(key string) error
- func AddExpoClient(UUID string, expoID string) error
- func AddQuery(q Query) (int64, error)
- func AnswerDuplicates()
- func AnswerQuery(key int64, answer string, list string) error
- func CreateTables()
- func FastForward()
- func Init()
- func MoveToFront(key int64) error
- func RandomLinks() []string
- func RemoveExpoClient(UUID string) error
- func ResetDB()
- type Charge
- type Expo
- type Query
Constants ¶
This section is empty.
Variables ¶
View Source
var SQLDB *sql.DB
SQLDB database
View Source
var SQLPath string
SQLPath path do db
Functions ¶
func AddExpoClient ¶
AddExpoClient - adds a new Expo Client to the list
func AnswerQuery ¶
AnswerQuery move a query to the resolved table with jimmy's answer
func MoveToFront ¶
MoveToFront moves a query to the front of the queue
func RandomLinks ¶
func RandomLinks() []string
func RemoveExpoClient ¶
RemoveExpoClient - removes the Expo Client associated with the device UUID
Types ¶
type Expo ¶
func GetExpoClients ¶
GetExpoClients - gets all of the ExpoIDs to send push notifications to
type Query ¶
type Query struct { Key int64 `json:"key"` Text string `json:"text"` Type string `json:"type"` Answer string `json:"answer"` List []string `json:"list"` ListJ string `json:"-"` Position int64 `json:"-"` Token string `json:"token"` Priority time.Time `json:"-"` Paid bool `json:"paid"` }
Query type
func CheckQuery ¶
CheckQuery see if a query is resolved and return the answer
func GetQuestion ¶
GetQuestion get a question by query id
func IsDuplicate ¶
IsDuplicate check if a text string has been answered
Click to show internal directories.
Click to hide internal directories.