service

package
v0.0.0-...-40c2b8a Latest Latest
Warning

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

Go to latest
Published: Dec 20, 2023 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddUserToEvent

func AddUserToEvent(objectId primitive.ObjectID, email string) (entity.Event, error)

func CreateEvent

func CreateEvent(creatorEmail string, req *EventCreateRequest) (entity.Event, error)

func GetDetailedEvents

func GetDetailedEvents(email string, from int, to int) ([]entity.EventWithUserState, error)

func GetEvent

func GetEvent(objectId primitive.ObjectID) (entity.Event, error)

func GetEventsForUser

func GetEventsForUser(email string, from int, to int) ([]entity.EventWithUserState, error)

func RemoveUserFromEvent

func RemoveUserFromEvent(objectId primitive.ObjectID, email string) (entity.Event, error)

func UpdateEvent

func UpdateEvent(objectId primitive.ObjectID, req *EventCreateRequest) (entity.Event, error)

Types

type EventCreateRequest

type EventCreateRequest struct {
	Title       string `json:"title"`
	Description string `json:"description"`
	Slots       int    `json:"slots"`
	EventDate   string `json:"eventDate"`
}

Jump to

Keyboard shortcuts

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