Documentation ¶
Index ¶
- Constants
- Variables
- func GetMap(mateo model.Mateo, sort string) map[string]interface{}
- func GetMockDB(t *testing.T) sqlmock.Sqlmock
- func GetValues(mateo model.Mateo, sort string) []driver.Value
- func InsertDinner(date time.Time, venue string, lastName string) (map[string]interface{}, error)
- func InsertGuest(dinnerID int64, mateoID int64) error
- func InsertGuests(dinnerID int64, lastNames []string) ([]string, error)
- func InsertInvite(inviteID string, inviteType string, mateoID int64, dinnerID *int64, ...) (map[string]interface{}, error)
- func InsertMessage(event string, mateoID int64) (map[string]interface{}, error)
- func SelectAllDinners() ([]map[string]interface{}, error)
- func SelectAllGuestsForDinner(dinnerID int64) ([]string, error)
- func SelectAllInvitesForDinner(dinnerID int64) ([]map[string]interface{}, error)
- func SelectAllMateos() ([]map[string]interface{}, error)
- func SelectAllMateosExceptHost(hostID int64) ([]map[string]interface{}, error)
- func SelectAllMateosLegacy() ([]map[string]interface{}, error)
- func SelectInviteByID(inviteID string) (map[string]interface{}, error)
- func SelectLatestDinner() (map[string]interface{}, error)
- func SelectMateoByID(mateoID int64) (map[string]interface{}, error)
- func SelectMateoByInviteID(inviteID string) (map[string]interface{}, error)
- func SelectMateoByLastName(lastName string) (map[string]interface{}, error)
- func SelectRecentMessagesForMateoEvent(event string, mateoID int64) ([]map[string]interface{}, error)
- func UpdateDinnerVenue(dinnerID int64, venue string) error
- func UpdateInvite(inviteID string, inviteStatus string) (map[string]interface{}, error)
- type Mock
- type MockRow
Constants ¶
View Source
const ( SelectAllMateosExpectedQuery = `` /* 464-byte string literal not displayed */ SelectAllMateosLegacyExpectedQuery = `` /* 517-byte string literal not displayed */ )
Variables ¶
View Source
var ( TestJohn = model.Mateo{ ID: 1, FirstName: "John", LastName: "Doe", Email: "john.doe@example.com", TotalAttended: 5, TotalHosted: 2, GuestRatio: 2.5, } TestAdam = model.Mateo{ ID: 2, FirstName: "Adam", LastName: "Samuel", Email: "adam.samuel@example.com", TotalAttended: 4, TotalHosted: 2, GuestRatio: 2.0, } // Legacy TestBob = model.Mateo{ ID: 3, FirstName: "Bob", LastName: "Jane", Email: "bob.jane@example.com", LastHostDate: "12-05-19", Attended: 4, } TestDavid = model.Mateo{ ID: 4, FirstName: "David", LastName: "Wilson", Email: "david.wilson@example.com", LastHostDate: "01-06-19", Attended: 1, } )
Functions ¶
func InsertDinner ¶
func InsertGuest ¶
func InsertInvite ¶
func InsertMessage ¶
func SelectAllDinners ¶
func SelectAllMateos ¶
func SelectAllMateosLegacy ¶
func SelectInviteByID ¶
func SelectLatestDinner ¶
func SelectMateoByID ¶
func SelectMateoByInviteID ¶
func SelectMateoByLastName ¶
func UpdateDinnerVenue ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.