Documentation ¶
Index ¶
- type Address
- type Attachment
- type Board
- type BoardNotification
- type BoardPermission
- type GeoLocation
- type Repository
- func (db *Repository) AddTaskAttachment(ctx context.Context, taskID, filePath string, attachment *tasksv1.Attachment) (*tasksv1.Task, error)
- func (db *Repository) AddTaskStatus(ctx context.Context, boardId string, status *tasksv1.TaskStatus) (*tasksv1.Board, error)
- func (db *Repository) AddTaskTag(ctx context.Context, boardId string, tag *tasksv1.TaskTag) (*tasksv1.Board, error)
- func (db *Repository) AssignTask(ctx context.Context, taskID, assigneeID, assignedByUserId string) (*tasksv1.Task, error)
- func (db *Repository) CompleteTask(ctx context.Context, taskID string) (*tasksv1.Task, error)
- func (db *Repository) CreateBoard(ctx context.Context, board *tasksv1.Board) error
- func (db *Repository) CreateTask(ctx context.Context, task *tasksv1.Task) error
- func (db *Repository) DeleteBoard(ctx context.Context, id string) error
- func (db *Repository) DeleteNotification(ctx context.Context, boardID, notificationName string) (*tasksv1.Board, error)
- func (db *Repository) DeleteStatusFromTasks(ctx context.Context, boardId string, status string) error
- func (db *Repository) DeleteTagsFromTasks(ctx context.Context, boardId string, tag string) error
- func (db *Repository) DeleteTask(ctx context.Context, id string) error
- func (db *Repository) DeleteTaskAttachment(ctx context.Context, taskID, attachmentName string) (*tasksv1.Task, error)
- func (db *Repository) DeleteTaskStatus(ctx context.Context, boardID, status string) (*tasksv1.Board, error)
- func (db *Repository) DeleteTaskTag(ctx context.Context, boardID, tag string) (*tasksv1.Board, error)
- func (db *Repository) DeleteTasksMatchingQuery(ctx context.Context, queries []*tasksv1.TaskQuery) error
- func (db *Repository) GetBoard(ctx context.Context, id string) (*tasksv1.Board, error)
- func (db *Repository) GetTask(ctx context.Context, taskID string) (*tasksv1.Task, error)
- func (db *Repository) ListBoards(ctx context.Context) ([]*tasksv1.Board, error)
- func (db *Repository) ListTasks(ctx context.Context, queries []*tasksv1.TaskQuery, ...) ([]*tasksv1.Task, int, error)
- func (db *Repository) SaveNotification(ctx context.Context, boardID string, notification *tasksv1.BoardNotification) (*tasksv1.Board, error)
- func (db *Repository) UpdateBoard(ctx context.Context, update *tasksv1.UpdateBoardRequest) (*tasksv1.Board, error)
- func (db *Repository) UpdateTask(ctx context.Context, authenticatedUserId string, ...) (*tasksv1.Task, error)
- type Task
- type TaskStatus
- type TaskTag
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Address ¶
type Address struct { PostalCode string `bson:"postalCode"` City string `bson:"city"` Street string `bson:"street"` Extra string `bson:"extra,omitempty"` }
func (*Address) ToProto ¶
func (addr *Address) ToProto() *customerv1.Address
type Attachment ¶
type Attachment struct { Filename string `bson:"filename"` Name string `bson:"name"` ContentType string `bson:"contentType"` }
func (*Attachment) ToProto ¶
func (at *Attachment) ToProto() *tasksv1.Attachment
type Board ¶
type Board struct { ID primitive.ObjectID `bson:"_id,omitempty"` DisplayName string `bson:"displayName,omitempty"` Description string `bson:"description,omitempty"` WritePermissions *BoardPermission `bson:"writePermissions,omitempty"` ReadPermissions *BoardPermission `bson:"readPermissions,omitempty"` Notifications []BoardNotification `bson:"notifications"` OwnerID string `bson:"ownerId"` TaskStatuses []TaskStatus `bson:"statuses,omitempty"` TaskTags []TaskTag `bson:"tags,omitempty"` EligibleUserIds []string `bson:"eligibleUserIds,omitempty"` EligibleRoleIds []string `bson:"eligibleRoleIds,omitempty"` }
type BoardNotification ¶
type BoardNotification struct { Name string `bson:"name"` SubjectTemplate string `bson:"subjectTemplate"` MessageTemplate string `bson:"messageTemplate"` UserIds []string `bson:"userIds,omitempty"` RoleIds []string `bson:"roleIds,omitempty"` DayTime []*commonv1.DayTime `bson:"sendTimes"` EventTypes []tasksv1.EventType `bson:"eventTypes"` NotificationType tasksv1.NotificationType `bson:"notificationType"` }
func (*BoardNotification) ToProto ¶
func (not *BoardNotification) ToProto() *tasksv1.BoardNotification
type BoardPermission ¶
type BoardPermission struct { AllowRoles []string `bson:"allowRoles,omitempty"` AllowUsers []string `bson:"allowUsers,omitempty"` DenyRoles []string `bson:"denyRoles,omitempty"` DenyUsers []string `bson:"denyUsers,omitempty"` }
func (*BoardPermission) ToProto ¶
func (perm *BoardPermission) ToProto() *tasksv1.BoardPermission
type GeoLocation ¶
func (*GeoLocation) ToProto ¶
func (geo *GeoLocation) ToProto() *commonv1.GeoLocation
type Repository ¶
type Repository struct {
// contains filtered or unexported fields
}
func (*Repository) AddTaskAttachment ¶
func (db *Repository) AddTaskAttachment(ctx context.Context, taskID, filePath string, attachment *tasksv1.Attachment) (*tasksv1.Task, error)
func (*Repository) AddTaskStatus ¶ added in v0.3.0
func (db *Repository) AddTaskStatus(ctx context.Context, boardId string, status *tasksv1.TaskStatus) (*tasksv1.Board, error)
func (*Repository) AddTaskTag ¶ added in v0.3.0
func (*Repository) AssignTask ¶
func (*Repository) CompleteTask ¶
func (*Repository) CreateBoard ¶
func (*Repository) CreateTask ¶
func (*Repository) DeleteBoard ¶
func (db *Repository) DeleteBoard(ctx context.Context, id string) error
func (*Repository) DeleteNotification ¶
func (*Repository) DeleteStatusFromTasks ¶ added in v0.3.0
func (*Repository) DeleteTagsFromTasks ¶ added in v0.3.0
func (*Repository) DeleteTask ¶
func (db *Repository) DeleteTask(ctx context.Context, id string) error
func (*Repository) DeleteTaskAttachment ¶
func (*Repository) DeleteTaskStatus ¶ added in v0.3.0
func (*Repository) DeleteTaskTag ¶ added in v0.3.0
func (*Repository) DeleteTasksMatchingQuery ¶ added in v0.3.0
func (*Repository) ListBoards ¶
func (*Repository) SaveNotification ¶
func (db *Repository) SaveNotification(ctx context.Context, boardID string, notification *tasksv1.BoardNotification) (*tasksv1.Board, error)
func (*Repository) UpdateBoard ¶ added in v0.4.0
func (db *Repository) UpdateBoard(ctx context.Context, update *tasksv1.UpdateBoardRequest) (*tasksv1.Board, error)
func (*Repository) UpdateTask ¶
func (db *Repository) UpdateTask(ctx context.Context, authenticatedUserId string, update *tasksv1.UpdateTaskRequest) (*tasksv1.Task, error)
type Task ¶
type Task struct { ID primitive.ObjectID `bson:"_id,omitempty"` BoardID string `bson:"boardId"` Title string `bson:"title"` Description string `bson:"description"` Creator string `bson:"creator"` Assignee string `bson:"assignee,omitempty"` GeoLocation *GeoLocation `bson:"location,omitempty"` Address *Address `bson:"address,omitempty"` Tags []string `bson:"tags"` Status string `bson:"status"` AssignedBy string `bson:"assignedBy,omitempty"` DueTime time.Time `bson:"dueTime,omitempty"` CreateTime time.Time `bson:"createTime"` UpdateTime time.Time `bson:"updateTime"` AssignTime time.Time `bson:"assignTime,omitempty"` CompleteTime time.Time `bson:"completeTime,omitempty"` Properties map[string][]byte `bson:"properties"` Attachments []Attachment `bson:"attachments"` }
type TaskStatus ¶
type TaskStatus struct { Status string `bson:"status"` Description string `bson:"description,omitempty"` Color string `bson:"color"` }
func (*TaskStatus) ToProto ¶
func (status *TaskStatus) ToProto() *tasksv1.TaskStatus
Click to show internal directories.
Click to hide internal directories.