Documentation ¶
Index ¶
- Constants
- Variables
- func CanDoAPIRoute(c echo.Context, token *APIToken) (can bool)
- func CollectRoutesForAPITokenUsage(route echo.Route, middlewares []echo.MiddlewareFunc)
- func CreateDefaultViewsForProject(s *xorm.Session, project *Project, a web.Auth, createBacklogBucket bool, ...) (err error)
- func CreateNewProjectForUser(s *xorm.Session, u *user.User) (err error)
- func CreateProject(s *xorm.Session, project *Project, auth web.Auth, createBacklogBucket bool, ...) (err error)
- func CreateTypesenseCollections() error
- func DeleteUser(s *xorm.Session, u *user.User) (err error)
- func ExportUserData(s *xorm.Session, u *user.User) (err error)
- func FindAllOidcTeamIDsForUser(s *xorm.Session, userID int64) (ts []int64, err error)
- func FindMentionedUsersInText(s *xorm.Session, text string) (users map[int64]*user.User, err error)
- func GetAllParentProjects(s *xorm.Session, projectID int64) (allProjects map[int64]*Project, err error)
- func GetAvailableAPIRoutesForToken(c echo.Context) error
- func GetAvailableWebhookEvents() []string
- func GetLinkSharesByIDs(s *xorm.Session, ids []int64) (shares map[int64]*LinkSharing, err error)
- func GetProjectsMapByIDs(s *xorm.Session, projectIDs []int64) (projects map[int64]*Project, err error)
- func GetProjectsMapSimplByTaskIDs(s *xorm.Session, taskIDs []int64) (ps map[int64]*Project, err error)
- func GetSubscriptionsForEntities(s *xorm.Session, entityType SubscriptionEntityType, entityIDs []int64) (subscriptions map[int64][]*SubscriptionWithUser, err error)
- func GetSubscriptionsForEntitiesAndUser(s *xorm.Session, entityType SubscriptionEntityType, entityIDs []int64, ...) (subscriptions map[int64][]*SubscriptionWithUser, err error)
- func GetTables() []interface{}
- func GetTotalCount(counting interface{}) (count int64, err error)
- func GetUserOrLinkShareUser(s *xorm.Session, a web.Auth) (uu *user.User, err error)
- func HashToken(token, salt string) string
- func InitTypesense()
- func InvalidFieldError(fields []string) error
- func IsErrAPITokenInvalid(err error) bool
- func IsErrAttachmentAndCoverMustBelongToTheSameTask(err error) bool
- func IsErrBucketDoesNotBelongToProject(err error) bool
- func IsErrBucketDoesNotExist(err error) bool
- func IsErrBucketLimitExceeded(err error) bool
- func IsErrBulkTasksMustBeInSameProject(err error) bool
- func IsErrBulkTasksNeedAtLeastOne(err error) bool
- func IsErrCannotArchiveDefaultProject(err error) bool
- func IsErrCannotDeleteDefaultProject(err error) bool
- func IsErrCannotDeleteLastTeamMember(err error) bool
- func IsErrCannotRemoveLastBucket(err error) bool
- func IsErrGenericForbidden(err error) bool
- func IsErrIDCannotBeZero(err error) bool
- func IsErrInvalidAPITokenPermission(err error) bool
- func IsErrInvalidData(err error) bool
- func IsErrInvalidFilterExpression(err error) bool
- func IsErrInvalidReactionEntityKind(err error) bool
- func IsErrInvalidRelationKind(err error) bool
- func IsErrInvalidRight(err error) bool
- func IsErrInvalidSortOrder(err error) bool
- func IsErrInvalidSortParam(err error) bool
- func IsErrInvalidTaskField(err error) bool
- func IsErrInvalidTaskFilterComparator(err error) bool
- func IsErrInvalidTaskFilterConcatinator(err error) bool
- func IsErrInvalidTaskFilterValue(err error) bool
- func IsErrLabelDoesNotExist(err error) bool
- func IsErrLabelIsAlreadyOnTask(err error) bool
- func IsErrLinkSharePasswordInvalid(err error) bool
- func IsErrLinkSharePasswordRequired(err error) bool
- func IsErrLinkShareTokenInvalid(err error) bool
- func IsErrMustProvideUser(err error) bool
- func IsErrNeedToHaveProjectReadAccess(err error) bool
- func IsErrNoRightToSeeTask(err error) bool
- func IsErrOIDCTeamDoesNotExist(err error) bool
- func IsErrOIDCTeamsDoNotExistForUser(err error) bool
- func IsErrOnlyOneDoneBucketPerProject(err error) bool
- func IsErrParentTaskCannotBeTheSame(err error) bool
- func IsErrProjectCannotBeChildOfItsOwn(err error) bool
- func IsErrProjectCannotBelongToAPseudoParentProject(err error) bool
- func IsErrProjectCannotHaveACyclicRelationship(err error) bool
- func IsErrProjectDoesNotExist(err error) bool
- func IsErrProjectIdentifierIsNotUnique(err error) bool
- func IsErrProjectIsArchived(err error) bool
- func IsErrProjectShareDoesNotExist(err error) bool
- func IsErrProjectTitleCannotBeEmpty(err error) bool
- func IsErrProjectViewDoesNotExist(err error) bool
- func IsErrRelationAlreadyExists(err error) bool
- func IsErrRelationDoesNotExist(err error) bool
- func IsErrRelationTasksCannotBeTheSame(err error) bool
- func IsErrReminderRelativeToMissing(err error) bool
- func IsErrSavedFilterDoesNotExist(err error) bool
- func IsErrSavedFilterNotAvailableForLinkShare(err error) bool
- func IsErrSubscriptionAlreadyExists(err error) bool
- func IsErrTaskAttachmentDoesNotExist(err error) bool
- func IsErrTaskAttachmentIsTooLarge(err error) bool
- func IsErrTaskCannotBeEmpty(err error) bool
- func IsErrTaskCommentDoesNotExist(err error) bool
- func IsErrTaskDoesNotExist(err error) bool
- func IsErrTaskRelationCycle(err error) bool
- func IsErrTeamAlreadyHasAccess(err error) bool
- func IsErrTeamDoesNotExist(err error) bool
- func IsErrTeamDoesNotHaveAccessToProject(err error) bool
- func IsErrTeamNameCannotBeEmpty(err error) bool
- func IsErrUnknownSubscriptionEntityType(err error) bool
- func IsErrUserAlreadyAssigned(err error) bool
- func IsErrUserAlreadyHasAccess(err error) bool
- func IsErrUserDoesNotHaveAccessToProject(err error) bool
- func IsErrUserHasNoAccessToLabel(err error) bool
- func IsErrUserIsMemberOfTeam(err error) bool
- func ListUsersFromProject(s *xorm.Session, l *Project, search string) (users []*user.User, err error)
- func PermissionsAreValid(permissions APIPermissions) (err error)
- func RecalculateTaskPositions(s *xorm.Session, view *ProjectView, a web.Auth) (err error)
- func RegisterAddTaskToFilterViewCron()
- func RegisterEventForWebhook(event events.Event)
- func RegisterListeners()
- func RegisterOldExportCleanupCron()
- func RegisterOverdueReminderCron()
- func RegisterReminderCron()
- func RegisterUserDeletionCron()
- func ReindexAllTasks() (err error)
- func RemoveUnsplashPhoto(s *xorm.Session, fileID int64) (err error)
- func SetEngine() (err error)
- func SetProjectBackground(s *xorm.Session, projectID int64, background *files.File, blurHash string) (err error)
- func SetupTests()
- func SyncUpdatedTasksIntoTypesense() (err error)
- func UpdateProject(s *xorm.Session, project *Project, auth web.Auth, updateProjectBackground bool) (err error)
- func VerifyLinkSharePassword(share *LinkSharing, password string) (err error)
- type APIPermissions
- type APIToken
- func (t *APIToken) CanCreate(_ *xorm.Session, _ web.Auth) (bool, error)
- func (t *APIToken) CanDelete(s *xorm.Session, a web.Auth) (bool, error)
- func (t *APIToken) Create(s *xorm.Session, a web.Auth) (err error)
- func (t *APIToken) Delete(s *xorm.Session, a web.Auth) (err error)
- func (t *APIToken) ReadAll(s *xorm.Session, a web.Auth, search string, page int, perPage int) (result interface{}, resultCount int, numberOfTotalItems int64, err error)
- func (*APIToken) TableName() string
- type APITokenRoute
- type AddTaskToTypesense
- type Bucket
- func (b *Bucket) CanCreate(s *xorm.Session, a web.Auth) (bool, error)
- func (b *Bucket) CanDelete(s *xorm.Session, a web.Auth) (bool, error)
- func (b *Bucket) CanUpdate(s *xorm.Session, a web.Auth) (bool, error)
- func (b *Bucket) Create(s *xorm.Session, a web.Auth) (err error)
- func (b *Bucket) Delete(s *xorm.Session, a web.Auth) (err error)
- func (b *Bucket) ReadAll(s *xorm.Session, auth web.Auth, _ string, _ int, _ int) (result interface{}, resultCount int, numberOfTotalItems int64, err error)
- func (b *Bucket) TableName() string
- func (b *Bucket) Update(s *xorm.Session, _ web.Auth) (err error)
- type BucketConfigurationModeKind
- type BulkAssignees
- type BulkTask
- type DataExportReadyNotification
- type DatabaseNotifications
- func (d *DatabaseNotifications) CanUpdate(s *xorm.Session, a web.Auth) (bool, error)
- func (d *DatabaseNotifications) ReadAll(s *xorm.Session, a web.Auth, _ string, page int, perPage int) (ls interface{}, resultCount int, numberOfEntries int64, err error)
- func (d *DatabaseNotifications) Update(s *xorm.Session, _ web.Auth) (err error)
- type DecreaseAttachmentCounter
- type DecreaseProjectCounter
- type DecreaseTaskCounter
- type DecreaseTeamCounter
- type ErrAPITokenInvalid
- type ErrAttachmentDoesNotBelongToTask
- type ErrBucketDoesNotBelongToProjectView
- type ErrBucketDoesNotExist
- type ErrBucketLimitExceeded
- type ErrBulkTasksMustBeInSameProject
- type ErrBulkTasksNeedAtLeastOne
- type ErrCannotArchiveDefaultProject
- type ErrCannotDeleteDefaultProject
- type ErrCannotDeleteLastTeamMember
- type ErrCannotRemoveLastBucket
- type ErrGenericForbidden
- type ErrIDCannotBeZero
- type ErrInvalidAPITokenPermission
- type ErrInvalidData
- type ErrInvalidFilterExpression
- type ErrInvalidReactionEntityKind
- type ErrInvalidRelationKind
- type ErrInvalidRight
- type ErrInvalidSortOrder
- type ErrInvalidSortParam
- type ErrInvalidTaskField
- type ErrInvalidTaskFilterComparator
- type ErrInvalidTaskFilterConcatinator
- type ErrInvalidTaskFilterValue
- type ErrLabelDoesNotExist
- type ErrLabelIsAlreadyOnTask
- type ErrLinkSharePasswordInvalid
- type ErrLinkSharePasswordRequired
- type ErrLinkShareTokenInvalid
- type ErrMustHaveProjectViewToSortByPosition
- type ErrMustProvideUser
- type ErrNeedToHaveProjectReadAccess
- type ErrNoRightToSeeTask
- type ErrOIDCTeamDoesNotExist
- type ErrOIDCTeamsDoNotExistForUser
- type ErrOnlyOneDoneBucketPerProject
- type ErrParentTaskCannotBeTheSame
- type ErrProjectCannotBeChildOfItself
- type ErrProjectCannotBelongToAPseudoParentProject
- type ErrProjectCannotHaveACyclicRelationship
- type ErrProjectDoesNotExist
- type ErrProjectIdentifierIsNotUnique
- type ErrProjectIsArchived
- type ErrProjectShareDoesNotExist
- type ErrProjectTitleCannotBeEmpty
- type ErrProjectViewDoesNotExist
- type ErrRelationAlreadyExists
- type ErrRelationDoesNotExist
- type ErrRelationTasksCannotBeTheSame
- type ErrReminderRelativeToMissing
- type ErrSavedFilterDoesNotExist
- type ErrSavedFilterNotAvailableForLinkShare
- type ErrSubscriptionAlreadyExists
- type ErrTaskAttachmentDoesNotExist
- type ErrTaskAttachmentIsTooLarge
- type ErrTaskCannotBeEmpty
- type ErrTaskCommentDoesNotExist
- type ErrTaskDoesNotExist
- type ErrTaskRelationCycle
- type ErrTeamAlreadyHasAccess
- type ErrTeamDoesNotExist
- type ErrTeamDoesNotHaveAccessToProject
- type ErrTeamNameCannotBeEmpty
- type ErrUnknownSubscriptionEntityType
- type ErrUserAlreadyAssigned
- type ErrUserAlreadyHasAccess
- type ErrUserDoesNotHaveAccessToProject
- type ErrUserHasNoAccessToLabel
- type ErrUserIsMemberOfTeam
- type Favorite
- type FavoriteKind
- type HandleTaskCommentEditMentions
- type HandleTaskCreateMentions
- type HandleTaskUpdateLastUpdated
- type HandleTaskUpdatedMentions
- type HandleUserDataExport
- type IncreaseAttachmentCounter
- type IncreaseProjectCounter
- type IncreaseTaskCounter
- type IncreaseTeamCounter
- type Label
- func (l *Label) CanCreate(_ *xorm.Session, a web.Auth) (bool, error)
- func (l *Label) CanDelete(s *xorm.Session, a web.Auth) (bool, error)
- func (l *Label) CanRead(s *xorm.Session, a web.Auth) (bool, int, error)
- func (l *Label) CanUpdate(s *xorm.Session, a web.Auth) (bool, error)
- func (l *Label) Create(s *xorm.Session, a web.Auth) (err error)
- func (l *Label) Delete(s *xorm.Session, _ web.Auth) (err error)
- func (l *Label) ReadAll(s *xorm.Session, a web.Auth, search string, page int, perPage int) (ls interface{}, resultCount int, numberOfEntries int64, err error)
- func (l *Label) ReadOne(s *xorm.Session, _ web.Auth) (err error)
- func (*Label) TableName() string
- func (l *Label) Update(s *xorm.Session, a web.Auth) (err error)
- type LabelByTaskIDsOptions
- type LabelTask
- func (lt *LabelTask) CanCreate(s *xorm.Session, a web.Auth) (bool, error)
- func (lt *LabelTask) CanDelete(s *xorm.Session, a web.Auth) (bool, error)
- func (lt *LabelTask) Create(s *xorm.Session, auth web.Auth) (err error)
- func (lt *LabelTask) Delete(s *xorm.Session, auth web.Auth) (err error)
- func (lt *LabelTask) ReadAll(s *xorm.Session, a web.Auth, search string, page int, _ int) (result interface{}, resultCount int, numberOfTotalItems int64, err error)
- func (*LabelTask) TableName() string
- type LabelTaskBulk
- type LabelWithTaskID
- type LinkSharing
- func (share *LinkSharing) CanCreate(s *xorm.Session, a web.Auth) (bool, error)
- func (share *LinkSharing) CanDelete(s *xorm.Session, a web.Auth) (bool, error)
- func (share *LinkSharing) CanRead(s *xorm.Session, a web.Auth) (bool, int, error)
- func (share *LinkSharing) CanUpdate(s *xorm.Session, a web.Auth) (bool, error)
- func (share *LinkSharing) Create(s *xorm.Session, a web.Auth) (err error)
- func (share *LinkSharing) Delete(s *xorm.Session, _ web.Auth) (err error)
- func (share *LinkSharing) GetID() int64
- func (share *LinkSharing) ReadAll(s *xorm.Session, a web.Auth, search string, page int, perPage int) (result interface{}, resultCount int, totalItems int64, err error)
- func (share *LinkSharing) ReadOne(s *xorm.Session, _ web.Auth) (err error)
- func (LinkSharing) TableName() string
- type Message
- type OIDCTeam
- type Project
- func GetProjectByShareHash(s *xorm.Session, hash string) (project *Project, err error)
- func GetProjectSimplByTaskID(s *xorm.Session, taskID int64) (l *Project, err error)
- func GetProjectSimpleByID(s *xorm.Session, projectID int64) (project *Project, err error)
- func GetProjectsByIDs(s *xorm.Session, projectIDs []int64) (projects []*Project, err error)
- func GetProjectsSimplByTaskIDs(s *xorm.Session, taskIDs []int64) (ps []*Project, err error)
- func (p *Project) CanCreate(s *xorm.Session, a web.Auth) (bool, error)
- func (p *Project) CanDelete(s *xorm.Session, a web.Auth) (bool, error)
- func (p *Project) CanRead(s *xorm.Session, a web.Auth) (bool, int, error)
- func (p *Project) CanUpdate(s *xorm.Session, a web.Auth) (canUpdate bool, err error)
- func (p *Project) CanWrite(s *xorm.Session, a web.Auth) (bool, error)
- func (p *Project) CheckIsArchived(s *xorm.Session) (err error)
- func (p *Project) Create(s *xorm.Session, a web.Auth) (err error)
- func (p *Project) Delete(s *xorm.Session, a web.Auth) (err error)
- func (p *Project) DeleteBackgroundFileIfExists() (err error)
- func (p *Project) IsAdmin(s *xorm.Session, a web.Auth) (bool, error)
- func (p *Project) ReadAll(s *xorm.Session, a web.Auth, search string, page int, perPage int) (result interface{}, resultCount int, totalItems int64, err error)
- func (p *Project) ReadOne(s *xorm.Session, a web.Auth) (err error)
- func (p *Project) TableName() string
- func (p *Project) Update(s *xorm.Session, a web.Auth) (err error)
- type ProjectBackgroundType
- type ProjectCreatedEvent
- type ProjectCreatedNotification
- type ProjectDeletedEvent
- type ProjectDuplicate
- type ProjectSharedWithTeamEvent
- type ProjectSharedWithUserEvent
- type ProjectUIDs
- type ProjectUpdatedEvent
- type ProjectUser
- func (lu *ProjectUser) CanCreate(s *xorm.Session, a web.Auth) (bool, error)
- func (lu *ProjectUser) CanDelete(s *xorm.Session, a web.Auth) (bool, error)
- func (lu *ProjectUser) CanUpdate(s *xorm.Session, a web.Auth) (bool, error)
- func (lu *ProjectUser) Create(s *xorm.Session, a web.Auth) (err error)
- func (lu *ProjectUser) Delete(s *xorm.Session, _ web.Auth) (err error)
- func (lu *ProjectUser) ReadAll(s *xorm.Session, a web.Auth, search string, page int, perPage int) (result interface{}, resultCount int, numberOfTotalItems int64, err error)
- func (ProjectUser) TableName() string
- func (lu *ProjectUser) Update(s *xorm.Session, _ web.Auth) (err error)
- type ProjectView
- func (pv *ProjectView) CanCreate(s *xorm.Session, a web.Auth) (bool, error)
- func (pv *ProjectView) CanDelete(s *xorm.Session, a web.Auth) (bool, error)
- func (pv *ProjectView) CanRead(s *xorm.Session, a web.Auth) (bool, int, error)
- func (pv *ProjectView) CanUpdate(s *xorm.Session, a web.Auth) (bool, error)
- func (pv *ProjectView) Create(s *xorm.Session, a web.Auth) (err error)
- func (pv *ProjectView) Delete(s *xorm.Session, _ web.Auth) (err error)
- func (pv *ProjectView) ReadAll(s *xorm.Session, a web.Auth, _ string, _ int, _ int) (result interface{}, resultCount int, numberOfTotalItems int64, err error)
- func (pv *ProjectView) ReadOne(s *xorm.Session, _ web.Auth) (err error)
- func (pv *ProjectView) TableName() string
- func (pv *ProjectView) Update(s *xorm.Session, _ web.Auth) (err error)
- type ProjectViewBucketConfiguration
- type ProjectViewKind
- type ProjectWithTasksAndBuckets
- type Reaction
- func (r *Reaction) CanCreate(s *xorm.Session, a web.Auth) (bool, error)
- func (r *Reaction) CanDelete(s *xorm.Session, a web.Auth) (bool, error)
- func (r *Reaction) CanRead(s *xorm.Session, a web.Auth) (bool, int, error)
- func (r *Reaction) Create(s *xorm.Session, a web.Auth) (err error)
- func (r *Reaction) Delete(s *xorm.Session, a web.Auth) (err error)
- func (r *Reaction) ReadAll(s *xorm.Session, a web.Auth, _ string, _ int, _ int) (result interface{}, resultCount int, numberOfTotalItems int64, err error)
- func (*Reaction) TableName() string
- type ReactionKind
- type ReactionMap
- type RelatedTaskMap
- type RelationKind
- type ReminderDueNotification
- type ReminderRelation
- type RemoveTaskFromTypesense
- type Right
- type RouteDetail
- type SavedFilter
- func (sf *SavedFilter) CanCreate(_ *xorm.Session, auth web.Auth) (bool, error)
- func (sf *SavedFilter) CanDelete(s *xorm.Session, auth web.Auth) (bool, error)
- func (sf *SavedFilter) CanRead(s *xorm.Session, auth web.Auth) (bool, int, error)
- func (sf *SavedFilter) CanUpdate(s *xorm.Session, auth web.Auth) (bool, error)
- func (sf *SavedFilter) Create(s *xorm.Session, auth web.Auth) (err error)
- func (sf *SavedFilter) Delete(s *xorm.Session, _ web.Auth) error
- func (sf *SavedFilter) ReadOne(s *xorm.Session, _ web.Auth) error
- func (sf *SavedFilter) TableName() string
- func (sf *SavedFilter) Update(s *xorm.Session, _ web.Auth) error
- type SendProjectCreatedNotification
- type SendTaskAssignedNotification
- type SendTaskCommentNotification
- type SendTaskDeletedNotification
- type SendTeamMemberAddedNotification
- type SharingType
- type Subscription
- func (sb *Subscription) CanCreate(s *xorm.Session, a web.Auth) (can bool, err error)
- func (sb *Subscription) CanDelete(s *xorm.Session, a web.Auth) (can bool, err error)
- func (sb *Subscription) Create(s *xorm.Session, auth web.Auth) (err error)
- func (sb *Subscription) Delete(s *xorm.Session, auth web.Auth) (err error)
- func (sb *Subscription) TableName() string
- type SubscriptionEntityType
- type SubscriptionWithUser
- func GetSubscriptionForUser(s *xorm.Session, entityType SubscriptionEntityType, entityID int64, a web.Auth) (subscription *SubscriptionWithUser, err error)
- func GetSubscriptionsForEntity(s *xorm.Session, entityType SubscriptionEntityType, entityID int64) (subscriptions []*SubscriptionWithUser, err error)
- type Task
- func GetTaskByIDSimple(s *xorm.Session, taskID int64) (task Task, err error)
- func GetTaskSimple(s *xorm.Session, t *Task) (task Task, err error)
- func GetTaskSimpleByUUID(s *xorm.Session, uid string) (task *Task, err error)
- func GetTasksByUIDs(s *xorm.Session, uids []string, a web.Auth) (tasks []*Task, err error)
- func GetTasksSimpleByIDs(s *xorm.Session, ids []int64) (tasks []*Task, err error)
- func (t *Task) CanCreate(s *xorm.Session, a web.Auth) (bool, error)
- func (t *Task) CanDelete(s *xorm.Session, a web.Auth) (bool, error)
- func (t *Task) CanRead(s *xorm.Session, a web.Auth) (canRead bool, maxRight int, err error)
- func (t *Task) CanUpdate(s *xorm.Session, a web.Auth) (bool, error)
- func (t *Task) CanWrite(s *xorm.Session, a web.Auth) (canWrite bool, err error)
- func (t *Task) Create(s *xorm.Session, a web.Auth) (err error)
- func (t *Task) Delete(s *xorm.Session, a web.Auth) (err error)
- func (t *Task) GetFrontendURL() string
- func (t *Task) GetFullIdentifier() string
- func (t *Task) ReadAll(_ *xorm.Session, _ web.Auth, _ string, _ int, _ int) (result interface{}, resultCount int, totalItems int64, err error)
- func (t *Task) ReadOne(s *xorm.Session, a web.Auth) (err error)
- func (*Task) TableName() string
- func (t *Task) Update(s *xorm.Session, a web.Auth) (err error)
- func (t *Task) UpdateTaskLabels(s *xorm.Session, creator web.Auth, labels []*Label) (err error)
- type TaskAssginee
- func (la *TaskAssginee) CanCreate(s *xorm.Session, a web.Auth) (bool, error)
- func (la *TaskAssginee) CanDelete(s *xorm.Session, a web.Auth) (bool, error)
- func (la *TaskAssginee) Create(s *xorm.Session, a web.Auth) (err error)
- func (la *TaskAssginee) Delete(s *xorm.Session, a web.Auth) (err error)
- func (la *TaskAssginee) ReadAll(s *xorm.Session, a web.Auth, search string, page int, perPage int) (result interface{}, resultCount int, numberOfTotalItems int64, err error)
- func (TaskAssginee) TableName() string
- type TaskAssignedNotification
- type TaskAssigneeCreatedEvent
- type TaskAssigneeDeletedEvent
- type TaskAssigneeWithUser
- type TaskAttachment
- func (ta *TaskAttachment) CanCreate(s *xorm.Session, a web.Auth) (bool, error)
- func (ta *TaskAttachment) CanDelete(s *xorm.Session, a web.Auth) (bool, error)
- func (ta *TaskAttachment) CanRead(s *xorm.Session, a web.Auth) (bool, int, error)
- func (ta *TaskAttachment) Delete(s *xorm.Session, a web.Auth) error
- func (ta *TaskAttachment) NewAttachment(s *xorm.Session, f io.ReadCloser, realname string, realsize uint64, a web.Auth) error
- func (ta *TaskAttachment) ReadAll(s *xorm.Session, _ web.Auth, _ string, page int, perPage int) (result interface{}, resultCount int, numberOfTotalItems int64, err error)
- func (ta *TaskAttachment) ReadOne(s *xorm.Session, _ web.Auth) (err error)
- func (*TaskAttachment) TableName() string
- type TaskAttachmentCreatedEvent
- type TaskAttachmentDeletedEvent
- type TaskBucket
- type TaskCollection
- type TaskCollectionExpandable
- type TaskComment
- func (tc *TaskComment) CanCreate(s *xorm.Session, a web.Auth) (bool, error)
- func (tc *TaskComment) CanDelete(s *xorm.Session, a web.Auth) (bool, error)
- func (tc *TaskComment) CanRead(s *xorm.Session, a web.Auth) (bool, int, error)
- func (tc *TaskComment) CanUpdate(s *xorm.Session, a web.Auth) (bool, error)
- func (tc *TaskComment) Create(s *xorm.Session, a web.Auth) (err error)
- func (tc *TaskComment) CreateWithTimestamps(s *xorm.Session, a web.Auth) (err error)
- func (tc *TaskComment) Delete(s *xorm.Session, _ web.Auth) error
- func (tc *TaskComment) ReadAll(s *xorm.Session, auth web.Auth, search string, page int, perPage int) (result interface{}, resultCount int, numberOfTotalItems int64, err error)
- func (tc *TaskComment) ReadOne(s *xorm.Session, _ web.Auth) (err error)
- func (tc *TaskComment) TableName() string
- func (tc *TaskComment) Update(s *xorm.Session, _ web.Auth) error
- type TaskCommentCreatedEvent
- type TaskCommentDeletedEvent
- type TaskCommentNotification
- type TaskCommentUpdatedEvent
- type TaskCreatedEvent
- type TaskDeletedEvent
- type TaskDeletedNotification
- type TaskPosition
- type TaskPositionWithView
- type TaskPositionsRecalculatedEvent
- type TaskRelation
- func (rel *TaskRelation) CanCreate(s *xorm.Session, a web.Auth) (bool, error)
- func (rel *TaskRelation) CanDelete(s *xorm.Session, a web.Auth) (bool, error)
- func (rel *TaskRelation) Create(s *xorm.Session, a web.Auth) error
- func (rel *TaskRelation) Delete(s *xorm.Session, a web.Auth) error
- func (*TaskRelation) TableName() string
- type TaskRelationCreatedEvent
- type TaskRelationDeletedEvent
- type TaskReminder
- type TaskRepeatMode
- type TaskUpdatedEvent
- type TaskWithComments
- type Team
- func (t *Team) CanCreate(_ *xorm.Session, a web.Auth) (bool, error)
- func (t *Team) CanDelete(s *xorm.Session, a web.Auth) (bool, error)
- func (t *Team) CanRead(s *xorm.Session, a web.Auth) (bool, int, error)
- func (t *Team) CanUpdate(s *xorm.Session, a web.Auth) (bool, error)
- func (t *Team) Create(s *xorm.Session, a web.Auth) (err error)
- func (t *Team) CreateNewTeam(s *xorm.Session, a web.Auth, firstUserShouldBeAdmin bool) (err error)
- func (t *Team) Delete(s *xorm.Session, a web.Auth) (err error)
- func (t *Team) IsAdmin(s *xorm.Session, a web.Auth) (bool, error)
- func (t *Team) ReadAll(s *xorm.Session, a web.Auth, search string, page int, perPage int) (result interface{}, resultCount int, numberOfTotalItems int64, err error)
- func (t *Team) ReadOne(s *xorm.Session, _ web.Auth) (err error)
- func (Team) TableName() string
- func (t *Team) Update(s *xorm.Session, _ web.Auth) (err error)
- type TeamCreatedEvent
- type TeamDeletedEvent
- type TeamMember
- func (tm *TeamMember) CanCreate(s *xorm.Session, a web.Auth) (bool, error)
- func (tm *TeamMember) CanDelete(s *xorm.Session, a web.Auth) (bool, error)
- func (tm *TeamMember) CanUpdate(s *xorm.Session, a web.Auth) (bool, error)
- func (tm *TeamMember) Create(s *xorm.Session, a web.Auth) (err error)
- func (tm *TeamMember) Delete(s *xorm.Session, _ web.Auth) (err error)
- func (tm *TeamMember) IsAdmin(s *xorm.Session, a web.Auth) (bool, error)
- func (tm *TeamMember) MembershipExists(s *xorm.Session) (exists bool, err error)
- func (*TeamMember) TableName() string
- func (tm *TeamMember) Update(s *xorm.Session, _ web.Auth) (err error)
- type TeamMemberAddedEvent
- type TeamMemberAddedNotification
- type TeamProject
- func (tl *TeamProject) CanCreate(s *xorm.Session, a web.Auth) (bool, error)
- func (tl *TeamProject) CanDelete(s *xorm.Session, a web.Auth) (bool, error)
- func (tl *TeamProject) CanUpdate(s *xorm.Session, a web.Auth) (bool, error)
- func (tl *TeamProject) Create(s *xorm.Session, a web.Auth) (err error)
- func (tl *TeamProject) Delete(s *xorm.Session, _ web.Auth) (err error)
- func (tl *TeamProject) ReadAll(s *xorm.Session, a web.Auth, search string, page int, perPage int) (result interface{}, resultCount int, totalItems int64, err error)
- func (TeamProject) TableName() string
- func (tl *TeamProject) Update(s *xorm.Session, _ web.Auth) (err error)
- type TeamUser
- type TeamWithRight
- type TypesenseSync
- type UndoneTaskOverdueNotification
- type UndoneTasksOverdueNotification
- type UnsplashPhoto
- type UpdateTaskInSavedFilterViews
- type UpdateTaskInTypesense
- type UpdateTaskPositionsInTypesense
- type UserDataExportRequestedEvent
- type UserMentionedInTaskNotification
- type UserWithRight
- type ValidationHTTPError
- type Webhook
- func (w *Webhook) CanCreate(s *xorm.Session, a web.Auth) (bool, error)
- func (w *Webhook) CanDelete(s *xorm.Session, a web.Auth) (bool, error)
- func (w *Webhook) CanRead(s *xorm.Session, a web.Auth) (bool, int, error)
- func (w *Webhook) CanUpdate(s *xorm.Session, a web.Auth) (bool, error)
- func (w *Webhook) Create(s *xorm.Session, a web.Auth) (err error)
- func (w *Webhook) Delete(s *xorm.Session, _ web.Auth) (err error)
- func (w *Webhook) ReadAll(s *xorm.Session, a web.Auth, _ string, page int, perPage int) (result interface{}, resultCount int, numberOfTotalItems int64, err error)
- func (w *Webhook) TableName() string
- func (w *Webhook) Update(s *xorm.Session, _ web.Auth) (err error)
- type WebhookListener
- type WebhookPayload
Constants ¶
const ( ReactionKindTask = iota ReactionKindComment )
const ( SubscriptionEntityUnknown = iota SubscriptionEntityNamespace // Kept even though not used anymore since we don't want to manually change all ids SubscriptionEntityProject SubscriptionEntityTask )
const APITokenPrefix = `tk_`
const ErrCodeAPITokenInvalid = 14001
ErrCodeAPITokenInvalid holds the unique world-error code of this error
const ErrCodeAttachmentDoesNotBelongToTask = 4020
ErrCodeAttachmentDoesNotBelongToTask holds the unique world-error code of this error
const ErrCodeBucketDoesNotBelongToProject = 10002
ErrCodeBucketDoesNotBelongToProject holds the unique world-error code of this error
const ErrCodeBucketDoesNotExist = 10001
ErrCodeBucketDoesNotExist holds the unique world-error code of this error
const ErrCodeBucketLimitExceeded = 10004
ErrCodeBucketLimitExceeded holds the unique world-error code of this error
const ErrCodeBulkTasksMustBeInSameProject = 4003
ErrCodeBulkTasksMustBeInSameProject holds the unique world-error code of this error
const ErrCodeBulkTasksNeedAtLeastOne = 4004
ErrCodeBulkTasksNeedAtLeastOne holds the unique world-error code of this error
const ErrCodeCannotArchiveDefaultProject = 3013
ErrCodeCannotArchiveDefaultProject holds the unique world-error code of this error
const ErrCodeCannotDeleteDefaultProject = 3012
ErrCodeCannotDeleteDefaultProject holds the unique world-error code of this error
const ErrCodeCannotDeleteLastTeamMember = 6006
ErrCodeCannotDeleteLastTeamMember holds the unique world-error code of this error
const ErrCodeCannotRemoveLastBucket = 10003
ErrCodeCannotRemoveLastBucket holds the unique world-error code of this error
const ErrCodeIDCannotBeZero = 2001
ErrCodeIDCannotBeZero holds the unique world-error code of this error
const ErrCodeInvalidAPITokenPermission = 14002
ErrCodeInvalidAPITokenPermission holds the unique world-error code of this error
const ErrCodeInvalidData = 2002
ErrCodeInvalidData holds the unique world-error code of this error
const ErrCodeInvalidFilterExpression = 4024
ErrCodeInvalidFilterExpression holds the unique world-error code of this error
const ErrCodeInvalidReactionEntityKind = 4025
ErrCodeInvalidReactionEntityKind holds the unique world-error code of this error
const ErrCodeInvalidRelationKind = 4007
ErrCodeInvalidRelationKind holds the unique world-error code of this error
const ErrCodeInvalidRight = 9001
ErrCodeInvalidRight holds the unique world-error code of this error
const ErrCodeInvalidSortOrder = 4014
ErrCodeInvalidSortOrder holds the unique world-error code of this error
const ErrCodeInvalidSortParam = 4013
ErrCodeInvalidSortParam holds the unique world-error code of this error
const ErrCodeInvalidTaskField = 4016
ErrCodeInvalidTaskField holds the unique world-error code of this error
const ErrCodeInvalidTaskFilterComparator = 4017
ErrCodeInvalidTaskFilterComparator holds the unique world-error code of this error
const ErrCodeInvalidTaskFilterConcatinator = 4018
ErrCodeInvalidTaskFilterConcatinator holds the unique world-error code of this error
const ErrCodeInvalidTaskFilterValue = 4019
ErrCodeInvalidTaskFilterValue holds the unique world-error code of this error
const ErrCodeLabelDoesNotExist = 8002
ErrCodeLabelDoesNotExist holds the unique world-error code of this error
const ErrCodeLabelIsAlreadyOnTask = 8001
ErrCodeLabelIsAlreadyOnTask holds the unique world-error code of this error
ErrCodeLinkSharePasswordInvalid holds the unique world-error code of this error
ErrCodeLinkSharePasswordRequired holds the unique world-error code of this error
ErrCodeLinkShareTokenInvalid holds the unique world-error code of this error
const ErrCodeMustHaveProjectViewToSortByPosition = 4026
ErrCodeMustHaveProjectViewToSortByPosition holds the unique world-error code of this error
const ErrCodeMustProvideUser = 12003
ErrCodeMustProvideUser holds the unique world-error code of this error
const ErrCodeNeedToHaveProjectReadAccess = 3004
ErrCodeNeedToHaveProjectReadAccess holds the unique world-error code of this error
const ErrCodeNoRightToSeeTask = 4005
ErrCodeNoRightToSeeTask holds the unique world-error code of this error
const ErrCodeOIDCTeamDoesNotExist = 6008
ErrCodeTeamDoesNotExist holds the unique world-error code of this error
const ErrCodeOIDCTeamsDoNotExistForUser = 6009
ErrCodeTeamDoesNotExist holds the unique world-error code of this error
const ErrCodeOnlyOneDoneBucketPerProject = 10005
ErrCodeOnlyOneDoneBucketPerProject holds the unique world-error code of this error
const ErrCodeParentTaskCannotBeTheSame = 4006
ErrCodeParentTaskCannotBeTheSame holds the unique world-error code of this error
const ErrCodeProjectCannotBeChildOfItself = 3010
ErrCodeProjectCannotBeChildOfItself holds the unique world-error code of this error
const ErrCodeProjectCannotBelongToAPseudoParentProject = 3009
ErrCodeProjectCannotBelongToAPseudoParentProject holds the unique world-error code of this error
const ErrCodeProjectCannotHaveACyclicRelationship = 3011
ErrCodeProjectCannotHaveACyclicRelationship holds the unique world-error code of this error
const ErrCodeProjectDoesNotExist = 3001
ErrCodeProjectDoesNotExist holds the unique world-error code of this error
const ErrCodeProjectIdentifierIsNotUnique = 3007
ErrCodeProjectIdentifierIsNotUnique holds the unique world-error code of this error
const ErrCodeProjectIsArchived = 3008
ErrCodeProjectIsArchived holds the unique world-error code of this error
ErrCodeProjectShareDoesNotExist holds the unique world-error code of this error
const ErrCodeProjectTitleCannotBeEmpty = 3005
ErrCodeProjectTitleCannotBeEmpty holds the unique world-error code of this error
const ErrCodeProjectViewDoesNotExist = 3014
ErrCodeProjectViewDoesNotExist holds the unique world-error code of this error
const ErrCodeRelationAlreadyExists = 4008
ErrCodeRelationAlreadyExists holds the unique world-error code of this error
const ErrCodeRelationDoesNotExist = 4009
ErrCodeRelationDoesNotExist holds the unique world-error code of this error
const ErrCodeRelationTasksCannotBeTheSame = 4010
ErrCodeRelationTasksCannotBeTheSame holds the unique world-error code of this error
const ErrCodeReminderRelativeToMissing = 4022
ErrCodeRelationDoesNotExist holds the unique world-error code of this error
const ErrCodeSavedFilterDoesNotExist = 11001
ErrCodeSavedFilterDoesNotExist holds the unique world-error code of this error
ErrCodeSavedFilterNotAvailableForLinkShare holds the unique world-error code of this error
const ErrCodeSubscriptionAlreadyExists = 12002
ErrCodeSubscriptionAlreadyExists holds the unique world-error code of this error
const ErrCodeTaskAttachmentDoesNotExist = 4011
ErrCodeTaskAttachmentDoesNotExist holds the unique world-error code of this error
const ErrCodeTaskAttachmentIsTooLarge = 4012
ErrCodeTaskAttachmentIsTooLarge holds the unique world-error code of this error
const ErrCodeTaskCannotBeEmpty = 4001
ErrCodeTaskCannotBeEmpty holds the unique world-error code of this error
const ErrCodeTaskCommentDoesNotExist = 4015
ErrCodeTaskCommentDoesNotExist holds the unique world-error code of this error
const ErrCodeTaskDoesNotExist = 4002
ErrCodeTaskDoesNotExist holds the unique world-error code of this error
const ErrCodeTaskRelationCycle = 4023
ErrCodeTaskRelationCycle holds the unique world-error code of this error
const ErrCodeTeamAlreadyHasAccess = 6004
ErrCodeTeamAlreadyHasAccess holds the unique world-error code of this error
const ErrCodeTeamDoesNotExist = 6002
ErrCodeTeamDoesNotExist holds the unique world-error code of this error
const ErrCodeTeamDoesNotHaveAccessToProject = 6007
ErrCodeTeamDoesNotHaveAccessToProject holds the unique world-error code of this error
const ErrCodeTeamNameCannotBeEmpty = 6001
ErrCodeTeamNameCannotBeEmpty holds the unique world-error code of this error
const ErrCodeUnknownSubscriptionEntityType = 12001
ErrCodeUnknownSubscriptionEntityType holds the unique world-error code of this error
const ErrCodeUserAlreadyAssigned = 4021
ErrCodeUserAlreadyAssigned holds the unique world-error code of this error
const ErrCodeUserAlreadyHasAccess = 7002
ErrCodeUserAlreadyHasAccess holds the unique world-error code of this error
const ErrCodeUserDoesNotHaveAccessToProject = 7003
ErrCodeUserDoesNotHaveAccessToProject holds the unique world-error code of this error
const ErrCodeUserHasNoAccessToLabel = 8003
ErrCodeUserHasNoAccessToLabel holds the unique world-error code of this error
const ErrCodeUserIsMemberOfTeam = 6005
ErrCodeUserIsMemberOfTeam holds the unique world-error code of this error
const ErrorCodeGenericForbidden = 0001
ErrorCodeGenericForbidden holds the unique world-error code of this error
const FavoritesPseudoProjectID = -1
const ProjectBackgroundUpload string = "upload"
ProjectBackgroundUpload represents the project upload background type
const (
RightUnknown = -1
)
define unknown right
Variables ¶
var FavoritesPseudoProject = Project{ ID: FavoritesPseudoProjectID, Title: "Favorites", Description: "This project has all tasks marked as favorites.", IsFavorite: true, Position: -1, Views: []*ProjectView{ { ID: -1, ProjectID: FavoritesPseudoProjectID, Title: "List", ViewKind: ProjectViewKindList, Position: 100, Filter: "done = false", }, { ID: -2, ProjectID: FavoritesPseudoProjectID, Title: "Gantt", ViewKind: ProjectViewKindGantt, Position: 200, }, { ID: -3, ProjectID: FavoritesPseudoProjectID, Title: "Table", ViewKind: ProjectViewKindTable, Position: 300, }, }, Created: time.Now(), Updated: time.Now(), }
FavoritesPseudoProject holds all tasks marked as favorites
Functions ¶
func CanDoAPIRoute ¶ added in v0.22.0
CanDoAPIRoute checks if a token is allowed to use the current api route
func CollectRoutesForAPITokenUsage ¶ added in v0.22.0
func CollectRoutesForAPITokenUsage(route echo.Route, middlewares []echo.MiddlewareFunc)
CollectRoutesForAPITokenUsage gets called for every added APITokenRoute and builds a list of all routes we can use for the api tokens.
func CreateDefaultViewsForProject ¶ added in v0.24.0
func CreateNewProjectForUser ¶ added in v0.21.0
CreateNewProjectForUser creates a new inbox project for a user. To prevent import cycles, we can't do that directly in the user.Create function.
func CreateProject ¶ added in v0.21.0
func CreateTypesenseCollections ¶ added in v0.22.0
func CreateTypesenseCollections() error
func DeleteUser ¶ added in v0.18.0
DeleteUser completely removes a user and all their associated projects and tasks. This action is irrevocable. Public to allow deletion from the CLI.
func ExportUserData ¶ added in v0.18.0
func FindAllOidcTeamIDsForUser ¶ added in v0.24.0
func FindMentionedUsersInText ¶ added in v0.18.0
func GetAllParentProjects ¶ added in v0.24.0
func GetAllParentProjects(s *xorm.Session, projectID int64) (allProjects map[int64]*Project, err error)
GetAllParentProjects returns all parents of a given project
func GetAvailableAPIRoutesForToken ¶ added in v0.22.0
func GetAvailableAPIRoutesForToken(c echo.Context) error
GetAvailableAPIRoutesForToken returns a list of all API routes which are available for token usage. @Summary Get a list of all token api routes @Description Returns a list of all API routes which are available to use with an api token, not a user login. @tags api @Produce json @Security JWTKeyAuth @Success 200 {array} models.APITokenRoute "The list of all routes." @Router /routes [get]
func GetAvailableWebhookEvents ¶ added in v0.22.0
func GetAvailableWebhookEvents() []string
func GetLinkSharesByIDs ¶ added in v0.17.0
GetLinkSharesByIDs returns all link shares from a slice of ids
func GetProjectsMapByIDs ¶ added in v0.24.0
func GetProjectsMapByIDs(s *xorm.Session, projectIDs []int64) (projects map[int64]*Project, err error)
GetProjectsMapByIDs returns a map of projects from a slice with project ids
func GetProjectsMapSimplByTaskIDs ¶ added in v0.24.0
func GetProjectsMapSimplByTaskIDs(s *xorm.Session, taskIDs []int64) (ps map[int64]*Project, err error)
GetProjectsMapSimplByTaskIDs gets a list of projects by a task ids
func GetSubscriptionsForEntities ¶ added in v0.24.3
func GetSubscriptionsForEntities(s *xorm.Session, entityType SubscriptionEntityType, entityIDs []int64) (subscriptions map[int64][]*SubscriptionWithUser, err error)
GetSubscriptionsForEntities returns a list of subscriptions to for an entity ID
func GetSubscriptionsForEntitiesAndUser ¶ added in v0.24.3
func GetSubscriptionsForEntitiesAndUser(s *xorm.Session, entityType SubscriptionEntityType, entityIDs []int64, u *user.User) (subscriptions map[int64][]*SubscriptionWithUser, err error)
func GetTables ¶
func GetTables() []interface{}
GetTables returns all structs which are also a table.
func GetTotalCount ¶
GetTotalCount returns the total amount of something
func GetUserOrLinkShareUser ¶ added in v0.17.0
GetUserOrLinkShareUser returns either a user or a link share disguised as a user.
func InitTypesense ¶ added in v0.22.0
func InitTypesense()
func InvalidFieldError ¶ added in v0.22.0
func IsErrAPITokenInvalid ¶ added in v0.22.0
IsErrAPITokenInvalid checks if an error is ErrAPITokenInvalid.
func IsErrAttachmentAndCoverMustBelongToTheSameTask ¶ added in v0.20.0
IsErrAttachmentAndCoverMustBelongToTheSameTask checks if an error is ErrAttachmentDoesNotBelongToTask.
func IsErrBucketDoesNotBelongToProject ¶ added in v0.21.0
IsErrBucketDoesNotBelongToProject checks if an error is ErrBucketDoesNotBelongToProjectView.
func IsErrBucketDoesNotExist ¶
IsErrBucketDoesNotExist checks if an error is ErrBucketDoesNotExist.
func IsErrBucketLimitExceeded ¶ added in v0.15.0
IsErrBucketLimitExceeded checks if an error is ErrBucketLimitExceeded.
func IsErrBulkTasksMustBeInSameProject ¶ added in v0.21.0
IsErrBulkTasksMustBeInSameProject checks if an error is a ErrBulkTasksMustBeInSameProject.
func IsErrBulkTasksNeedAtLeastOne ¶
IsErrBulkTasksNeedAtLeastOne checks if an error is a ErrBulkTasksNeedAtLeastOne.
func IsErrCannotArchiveDefaultProject ¶ added in v0.21.0
IsErrCannotArchiveDefaultProject checks if an error is a project is archived error.
func IsErrCannotDeleteDefaultProject ¶ added in v0.21.0
IsErrCannotDeleteDefaultProject checks if an error is a project is archived error.
func IsErrCannotDeleteLastTeamMember ¶
IsErrCannotDeleteLastTeamMember checks if an error is ErrCannotDeleteLastTeamMember.
func IsErrCannotRemoveLastBucket ¶
IsErrCannotRemoveLastBucket checks if an error is ErrCannotRemoveLastBucket.
func IsErrGenericForbidden ¶
IsErrGenericForbidden checks if an error is a ErrGenericForbidden.
func IsErrIDCannotBeZero ¶
IsErrIDCannotBeZero checks if an error is a ErrIDCannotBeZero.
func IsErrInvalidAPITokenPermission ¶ added in v0.22.0
IsErrInvalidAPITokenPermission checks if an error is ErrInvalidAPITokenPermission.
func IsErrInvalidData ¶
IsErrInvalidData checks if an error is a ErrIDCannotBeZero.
func IsErrInvalidFilterExpression ¶ added in v0.24.0
IsErrInvalidFilterExpression checks if an error is ErrInvalidFilterExpression.
func IsErrInvalidReactionEntityKind ¶ added in v0.24.0
IsErrInvalidReactionEntityKind checks if an error is ErrInvalidReactionEntityKind.
func IsErrInvalidRelationKind ¶
IsErrInvalidRelationKind checks if an error is ErrInvalidRelationKind.
func IsErrInvalidRight ¶
IsErrInvalidRight checks if an error is ErrInvalidRight.
func IsErrInvalidSortOrder ¶
IsErrInvalidSortOrder checks if an error is ErrInvalidSortOrder.
func IsErrInvalidSortParam ¶
IsErrInvalidSortParam checks if an error is ErrInvalidSortParam.
func IsErrInvalidTaskField ¶
IsErrInvalidTaskField checks if an error is ErrInvalidTaskField.
func IsErrInvalidTaskFilterComparator ¶
IsErrInvalidTaskFilterComparator checks if an error is ErrInvalidTaskFilterComparator.
func IsErrInvalidTaskFilterConcatinator ¶
IsErrInvalidTaskFilterConcatinator checks if an error is ErrInvalidTaskFilterConcatinator.
func IsErrInvalidTaskFilterValue ¶ added in v0.14.0
IsErrInvalidTaskFilterValue checks if an error is ErrInvalidTaskFilterValue.
func IsErrLabelDoesNotExist ¶
IsErrLabelDoesNotExist checks if an error is ErrLabelDoesNotExist.
func IsErrLabelIsAlreadyOnTask ¶
IsErrLabelIsAlreadyOnTask checks if an error is ErrLabelIsAlreadyOnTask.
func IsErrLinkSharePasswordInvalid ¶ added in v0.17.0
IsErrLinkSharePasswordInvalid checks if an error is ErrLinkSharePasswordInvalid.
func IsErrLinkSharePasswordRequired ¶ added in v0.17.0
IsErrLinkSharePasswordRequired checks if an error is ErrLinkSharePasswordRequired.
func IsErrLinkShareTokenInvalid ¶ added in v0.21.0
IsErrLinkShareTokenInvalid checks if an error is ErrLinkShareTokenInvalid.
func IsErrMustProvideUser ¶ added in v0.24.3
IsErrMustProvideUser checks if an error is ErrMustProvideUser.
func IsErrNeedToHaveProjectReadAccess ¶ added in v0.21.0
IsErrNeedToHaveProjectReadAccess checks if an error is a ErrProjectDoesNotExist.
func IsErrNoRightToSeeTask ¶
IsErrNoRightToSeeTask checks if an error is ErrNoRightToSeeTask.
func IsErrOIDCTeamDoesNotExist ¶ added in v0.24.0
IsErrOIDCTeamDoesNotExist checks if an error is ErrOIDCTeamDoesNotExist.
func IsErrOIDCTeamsDoNotExistForUser ¶ added in v0.24.0
IsErrOIDCTeamsDoNotExistForUser checks if an error is ErrOIDCTeamsDoNotExistForUser.
func IsErrOnlyOneDoneBucketPerProject ¶ added in v0.21.0
IsErrOnlyOneDoneBucketPerProject checks if an error is ErrBucketLimitExceeded.
func IsErrParentTaskCannotBeTheSame ¶
IsErrParentTaskCannotBeTheSame checks if an error is ErrParentTaskCannotBeTheSame.
func IsErrProjectCannotBeChildOfItsOwn ¶ added in v0.21.0
IsErrProjectCannotBeChildOfItsOwn checks if an error is a project is archived error.
func IsErrProjectCannotBelongToAPseudoParentProject ¶ added in v0.21.0
IsErrProjectCannotBelongToAPseudoParentProject checks if an error is a project is archived error.
func IsErrProjectCannotHaveACyclicRelationship ¶ added in v0.21.0
IsErrProjectCannotHaveACyclicRelationship checks if an error is a project is archived error.
func IsErrProjectDoesNotExist ¶ added in v0.21.0
IsErrProjectDoesNotExist checks if an error is a ErrProjectDoesNotExist.
func IsErrProjectIdentifierIsNotUnique ¶ added in v0.21.0
IsErrProjectIdentifierIsNotUnique checks if an error is a ErrProjectIdentifierIsNotUnique.
func IsErrProjectIsArchived ¶ added in v0.21.0
IsErrProjectIsArchived checks if an error is a project is archived error.
func IsErrProjectShareDoesNotExist ¶ added in v0.21.0
IsErrProjectShareDoesNotExist checks if an error is a ErrProjectShareDoesNotExist.
func IsErrProjectTitleCannotBeEmpty ¶ added in v0.21.0
IsErrProjectTitleCannotBeEmpty checks if an error is a ErrProjectTitleCannotBeEmpty.
func IsErrProjectViewDoesNotExist ¶ added in v0.24.0
IsErrProjectViewDoesNotExist checks if an error is a project is archived error.
func IsErrRelationAlreadyExists ¶
IsErrRelationAlreadyExists checks if an error is ErrRelationAlreadyExists.
func IsErrRelationDoesNotExist ¶
IsErrRelationDoesNotExist checks if an error is ErrRelationDoesNotExist.
func IsErrRelationTasksCannotBeTheSame ¶
IsErrRelationTasksCannotBeTheSame checks if an error is ErrRelationTasksCannotBeTheSame.
func IsErrReminderRelativeToMissing ¶ added in v0.21.0
IsErrReminderRelativeToMissing checks if an error is ErrReminderRelativeToMissing.
func IsErrSavedFilterDoesNotExist ¶ added in v0.15.0
IsErrSavedFilterDoesNotExist checks if an error is ErrSavedFilterDoesNotExist.
func IsErrSavedFilterNotAvailableForLinkShare ¶ added in v0.15.0
IsErrSavedFilterNotAvailableForLinkShare checks if an error is ErrSavedFilterNotAvailableForLinkShare.
func IsErrSubscriptionAlreadyExists ¶ added in v0.17.0
IsErrSubscriptionAlreadyExists checks if an error is ErrSubscriptionAlreadyExists.
func IsErrTaskAttachmentDoesNotExist ¶
IsErrTaskAttachmentDoesNotExist checks if an error is ErrTaskAttachmentDoesNotExist.
func IsErrTaskAttachmentIsTooLarge ¶
IsErrTaskAttachmentIsTooLarge checks if an error is ErrTaskAttachmentIsTooLarge.
func IsErrTaskCannotBeEmpty ¶
IsErrTaskCannotBeEmpty checks if an error is a ErrProjectDoesNotExist.
func IsErrTaskCommentDoesNotExist ¶
IsErrTaskCommentDoesNotExist checks if an error is ErrTaskCommentDoesNotExist.
func IsErrTaskDoesNotExist ¶
IsErrTaskDoesNotExist checks if an error is a ErrProjectDoesNotExist.
func IsErrTaskRelationCycle ¶ added in v0.23.0
IsErrTaskRelationCycle checks if an error is ErrTaskRelationCycle.
func IsErrTeamAlreadyHasAccess ¶
IsErrTeamAlreadyHasAccess checks if an error is ErrTeamAlreadyHasAccess.
func IsErrTeamDoesNotExist ¶
IsErrTeamDoesNotExist checks if an error is ErrTeamDoesNotExist.
func IsErrTeamDoesNotHaveAccessToProject ¶ added in v0.21.0
IsErrTeamDoesNotHaveAccessToProject checks if an error is a ErrProjectDoesNotExist.
func IsErrTeamNameCannotBeEmpty ¶
IsErrTeamNameCannotBeEmpty checks if an error is a ErrTeamNameCannotBeEmpty.
func IsErrUnknownSubscriptionEntityType ¶ added in v0.17.0
IsErrUnknownSubscriptionEntityType checks if an error is ErrUnknownSubscriptionEntityType.
func IsErrUserAlreadyAssigned ¶ added in v0.20.0
IsErrUserAlreadyAssigned checks if an error is ErrUserAlreadyAssigned.
func IsErrUserAlreadyHasAccess ¶
IsErrUserAlreadyHasAccess checks if an error is ErrUserAlreadyHasAccess.
func IsErrUserDoesNotHaveAccessToProject ¶ added in v0.21.0
IsErrUserDoesNotHaveAccessToProject checks if an error is a ErrProjectDoesNotExist.
func IsErrUserHasNoAccessToLabel ¶
IsErrUserHasNoAccessToLabel checks if an error is ErrUserHasNoAccessToLabel.
func IsErrUserIsMemberOfTeam ¶
IsErrUserIsMemberOfTeam checks if an error is ErrUserIsMemberOfTeam.
func ListUsersFromProject ¶ added in v0.21.0
func ListUsersFromProject(s *xorm.Session, l *Project, search string) (users []*user.User, err error)
ListUsersFromProject returns a list with all users who have access to a project, regardless of the method which gave them access
func PermissionsAreValid ¶ added in v0.22.0
func PermissionsAreValid(permissions APIPermissions) (err error)
func RecalculateTaskPositions ¶ added in v0.24.0
func RegisterAddTaskToFilterViewCron ¶ added in v0.24.3
func RegisterAddTaskToFilterViewCron()
func RegisterEventForWebhook ¶ added in v0.22.0
func RegisterListeners ¶ added in v0.17.0
func RegisterListeners()
RegisterListeners registers all event listeners
func RegisterOldExportCleanupCron ¶ added in v0.18.0
func RegisterOldExportCleanupCron()
func RegisterOverdueReminderCron ¶ added in v0.17.0
func RegisterOverdueReminderCron()
RegisterOverdueReminderCron registers a function which checks once a day for tasks that are overdue and not done.
func RegisterReminderCron ¶ added in v0.16.0
func RegisterReminderCron()
RegisterReminderCron registers a cron function which runs every minute to check if any reminders are due the next minute to send emails.
func RegisterUserDeletionCron ¶ added in v0.18.0
func RegisterUserDeletionCron()
RegisterUserDeletionCron registers the cron job that actually removes users who are scheduled to delete.
func ReindexAllTasks ¶ added in v0.22.0
func ReindexAllTasks() (err error)
func RemoveUnsplashPhoto ¶ added in v0.14.0
RemoveUnsplashPhoto removes an unsplash photo from the db
func SetProjectBackground ¶ added in v0.21.0
func SetProjectBackground(s *xorm.Session, projectID int64, background *files.File, blurHash string) (err error)
SetProjectBackground sets a background file as project background in the db
func SetupTests ¶
func SetupTests()
SetupTests takes care of seting up the db, fixtures etc. This is an extra function to be able to call the fixtures setup from the integration tests.
func SyncUpdatedTasksIntoTypesense ¶ added in v0.22.0
func SyncUpdatedTasksIntoTypesense() (err error)
func UpdateProject ¶ added in v0.21.0
func VerifyLinkSharePassword ¶ added in v0.17.0
func VerifyLinkSharePassword(share *LinkSharing, password string) (err error)
VerifyLinkSharePassword checks if a password of a link share matches a provided one.
Types ¶
type APIPermissions ¶ added in v0.22.0
type APIToken ¶ added in v0.22.0
type APIToken struct { // The unique, numeric id of this api key. ID int64 `xorm:"bigint autoincr not null unique pk" json:"id" param:"token"` // A human-readable name for this token Title string `xorm:"not null" json:"title" valid:"required"` // The actual api key. Only visible after creation. Token string `xorm:"-" json:"token,omitempty"` TokenSalt string `xorm:"not null" json:"-"` TokenHash string `xorm:"not null unique" json:"-"` TokenLastEight string `xorm:"not null index varchar(8)" json:"-"` // The permissions this token has. Possible values are available via the /routes endpoint and consist of the keys of the list from that endpoint. For example, if the token should be able to read all tasks as well as update existing tasks, you should add `{"tasks":["read_all","update"]}`. Permissions APIPermissions `xorm:"json not null" json:"permissions" valid:"required"` // The date when this key expires. ExpiresAt time.Time `xorm:"not null" json:"expires_at" valid:"required"` // A timestamp when this api key was created. You cannot change this value. Created time.Time `xorm:"created not null" json:"created"` OwnerID int64 `xorm:"bigint not null" json:"-"` web.Rights `xorm:"-" json:"-"` web.CRUDable `xorm:"-" json:"-"` }
func GetAPITokenByID ¶ added in v0.22.0
func GetTokenFromTokenString ¶ added in v0.22.0
GetTokenFromTokenString returns the full token object from the original token string.
func (*APIToken) Create ¶ added in v0.22.0
Create creates a new token @Summary Create a new api token @Description Create a new api token to use on behalf of the user creating it. @tags api @Accept json @Produce json @Security JWTKeyAuth @Param token body models.APIToken true "The token object with required fields" @Success 200 {object} models.APIToken "The created token." @Failure 400 {object} web.HTTPError "Invalid token object provided." @Failure 500 {object} models.Message "Internal error" @Router /tokens [put]
func (*APIToken) Delete ¶ added in v0.22.0
Delete deletes a token @Summary Deletes an existing api token @Description Delete any of the user's api tokens. @tags api @Accept json @Produce json @Security JWTKeyAuth @Param tokenID path int true "Token ID" @Success 200 {object} models.Message "Successfully deleted." @Failure 404 {object} web.HTTPError "The token does not exist." @Failure 500 {object} models.Message "Internal error" @Router /tokens/{tokenID} [delete]
func (*APIToken) ReadAll ¶ added in v0.22.0
func (t *APIToken) ReadAll(s *xorm.Session, a web.Auth, search string, page int, perPage int) (result interface{}, resultCount int, numberOfTotalItems int64, err error)
ReadAll returns all api tokens the current user has created @Summary Get all api tokens of the current user @Description Returns all api tokens the current user has created. @tags api @Accept json @Produce json @Security JWTKeyAuth @Param page query int false "The page number, used for pagination. If not provided, the first page of results is returned." @Param per_page query int false "The maximum number of tokens per page. This parameter is limited by the configured maximum of items per page." @Param s query string false "Search tokens by their title." @Success 200 {array} models.APIToken "The list of all tokens" @Failure 500 {object} models.Message "Internal server error" @Router /tokens [get]
type APITokenRoute ¶ added in v0.22.0
type APITokenRoute map[string]*RouteDetail
type AddTaskToTypesense ¶ added in v0.22.0
type AddTaskToTypesense struct { }
AddTaskToTypesense represents a listener
func (*AddTaskToTypesense) Handle ¶ added in v0.22.0
func (l *AddTaskToTypesense) Handle(msg *message.Message) (err error)
Handle is executed when the event AddTaskToTypesense listens on is fired
func (*AddTaskToTypesense) Name ¶ added in v0.22.0
func (l *AddTaskToTypesense) Name() string
Name defines the name for the AddTaskToTypesense listener
type Bucket ¶
type Bucket struct { // The unique, numeric id of this bucket. ID int64 `xorm:"bigint autoincr not null unique pk" json:"id" param:"bucket"` // The title of this bucket. Title string `xorm:"text not null" valid:"required" minLength:"1" json:"title"` // The project this bucket belongs to. ProjectID int64 `xorm:"-" json:"-" param:"project"` // The project view this bucket belongs to. ProjectViewID int64 `xorm:"bigint not null" json:"project_view_id" param:"view"` // All tasks which belong to this bucket. Tasks []*Task `xorm:"-" json:"tasks"` // How many tasks can be at the same time on this board max Limit int64 `xorm:"default 0" json:"limit" minimum:"0" valid:"range(0|9223372036854775807)"` // The number of tasks currently in this bucket Count int64 `xorm:"-" json:"count"` // The position this bucket has when querying all buckets. See the tasks.position property on how to use this. Position float64 `xorm:"double null" json:"position"` // A timestamp when this bucket was created. You cannot change this value. Created time.Time `xorm:"created not null" json:"created"` // A timestamp when this bucket was last updated. You cannot change this value. Updated time.Time `xorm:"updated not null" json:"updated"` // The user who initially created the bucket. CreatedBy *user.User `xorm:"-" json:"created_by" valid:"-"` CreatedByID int64 `xorm:"bigint not null" json:"-"` // Including the task collection type so we can use task filters on kanban TaskCollection `xorm:"-" json:"-"` web.Rights `xorm:"-" json:"-"` web.CRUDable `xorm:"-" json:"-"` }
Bucket represents a kanban bucket
func GetTasksInBucketsForView ¶ added in v0.24.0
func (*Bucket) Create ¶
Create creates a new bucket @Summary Create a new bucket @Description Creates a new kanban bucket on a project. @tags project @Accept json @Produce json @Security JWTKeyAuth @Param id path int true "Project Id" @Param view path int true "Project view ID" @Param bucket body models.Bucket true "The bucket object" @Success 200 {object} models.Bucket "The created bucket object." @Failure 400 {object} web.HTTPError "Invalid bucket object provided." @Failure 404 {object} web.HTTPError "The project does not exist." @Failure 500 {object} models.Message "Internal error" @Router /projects/{id}/views/{view}/buckets [put]
func (*Bucket) Delete ¶
Delete removes a bucket, but no tasks @Summary Deletes an existing bucket @Description Deletes an existing kanban bucket and dissociates all of its task. It does not delete any tasks. You cannot delete the last bucket on a project. @tags project @Accept json @Produce json @Security JWTKeyAuth @Param projectID path int true "Project Id" @Param bucketID path int true "Bucket Id" @Param view path int true "Project view ID" @Success 200 {object} models.Message "Successfully deleted." @Failure 404 {object} web.HTTPError "The bucket does not exist." @Failure 500 {object} models.Message "Internal error" @Router /projects/{projectID}/views/{view}/buckets/{bucketID} [delete]
func (*Bucket) ReadAll ¶
func (b *Bucket) ReadAll(s *xorm.Session, auth web.Auth, _ string, _ int, _ int) (result interface{}, resultCount int, numberOfTotalItems int64, err error)
ReadAll returns all manual buckets for a certain project @Summary Get all kanban buckets of a project @Description Returns all kanban buckets which belong to that project. Buckets are always sorted by their `position` in ascending order. To get all buckets with their tasks, use the tasks endpoint with a kanban view. @tags project @Accept json @Produce json @Security JWTKeyAuth @Param id path int true "Project ID" @Param view path int true "Project view ID" @Success 200 {array} models.Bucket "The buckets" @Failure 500 {object} models.Message "Internal server error" @Router /projects/{id}/views/{view}/buckets [get]
func (*Bucket) Update ¶
Update Updates an existing bucket @Summary Update an existing bucket @Description Updates an existing kanban bucket. @tags project @Accept json @Produce json @Security JWTKeyAuth @Param projectID path int true "Project Id" @Param bucketID path int true "Bucket Id" @Param view path int true "Project view ID" @Param bucket body models.Bucket true "The bucket object" @Success 200 {object} models.Bucket "The created bucket object." @Failure 400 {object} web.HTTPError "Invalid bucket object provided." @Failure 404 {object} web.HTTPError "The bucket does not exist." @Failure 500 {object} models.Message "Internal error" @Router /projects/{projectID}/views/{view}/buckets/{bucketID} [post]
type BucketConfigurationModeKind ¶ added in v0.24.0
type BucketConfigurationModeKind int
const ( BucketConfigurationModeNone BucketConfigurationModeKind = iota BucketConfigurationModeManual BucketConfigurationModeFilter )
func (*BucketConfigurationModeKind) MarshalJSON ¶ added in v0.24.0
func (p *BucketConfigurationModeKind) MarshalJSON() ([]byte, error)
func (*BucketConfigurationModeKind) UnmarshalJSON ¶ added in v0.24.0
func (p *BucketConfigurationModeKind) UnmarshalJSON(bytes []byte) error
type BulkAssignees ¶
type BulkAssignees struct { // A project with all assignees Assignees []*user.User `json:"assignees"` TaskID int64 `json:"-" param:"projecttask"` web.CRUDable `json:"-"` web.Rights `json:"-"` }
BulkAssignees is a helper struct used to update multiple assignees at once.
func (*BulkAssignees) Create ¶
Create adds new assignees to a task @Summary Add multiple new assignees to a task @Description Adds multiple new assignees to a task. The assignee needs to have access to the project, the doer must be able to edit this task. Every user not in the project will be unassigned from the task, pass an empty array to unassign everyone. @tags assignees @Accept json @Produce json @Security JWTKeyAuth @Param assignee body models.BulkAssignees true "The array of assignees" @Param taskID path int true "Task ID" @Success 201 {object} models.TaskAssginee "The created assingees object." @Failure 400 {object} web.HTTPError "Invalid assignee object provided." @Failure 500 {object} models.Message "Internal error" @Router /tasks/{taskID}/assignees/bulk [post]
type BulkTask ¶
type BulkTask struct { // A project of task ids to update IDs []int64 `json:"task_ids"` Tasks []*Task `json:"-"` Task }
BulkTask is the definition of a bulk update task
func (*BulkTask) GetTasksByIDs ¶
GetTasksByIDs returns all tasks for a project of ids
func (*BulkTask) Update ¶
Update updates a bunch of tasks at once @Summary Update a bunch of tasks at once @Description Updates a bunch of tasks at once. This includes marking them as done. Note: although you could supply another ID, it will be ignored. Use task_ids instead. @tags task @Accept json @Produce json @Security JWTKeyAuth @Param task body models.BulkTask true "The task object. Looks like a normal task, the only difference is it uses an array of project_ids to update." @Success 200 {object} models.Task "The updated task object." @Failure 400 {object} web.HTTPError "Invalid task object provided." @Failure 403 {object} web.HTTPError "The user does not have access to the task (aka its project)" @Failure 500 {object} models.Message "Internal error" @Router /tasks/bulk [post]
type DataExportReadyNotification ¶ added in v0.18.0
DataExportReadyNotification represents a DataExportReadyNotification notification
func (*DataExportReadyNotification) Name ¶ added in v0.18.0
func (n *DataExportReadyNotification) Name() string
Name returns the name of the notification
func (*DataExportReadyNotification) ToDB ¶ added in v0.18.0
func (n *DataExportReadyNotification) ToDB() interface{}
ToDB returns the DataExportReadyNotification notification in a format which can be saved in the db
func (*DataExportReadyNotification) ToMail ¶ added in v0.18.0
func (n *DataExportReadyNotification) ToMail() *notifications.Mail
ToMail returns the mail notification for DataExportReadyNotification
type DatabaseNotifications ¶ added in v0.17.0
type DatabaseNotifications struct { notifications.DatabaseNotification // Whether or not to mark this notification as read or unread. // True is read, false is unread. Read bool `xorm:"-" json:"read"` web.CRUDable `xorm:"-" json:"-"` web.Rights `xorm:"-" json:"-"` }
DatabaseNotifications is a wrapper around the crud operations that come with a database notification.
func (*DatabaseNotifications) CanUpdate ¶ added in v0.17.0
CanUpdate checks if a user can mark a notification as read.
func (*DatabaseNotifications) ReadAll ¶ added in v0.17.0
func (d *DatabaseNotifications) ReadAll(s *xorm.Session, a web.Auth, _ string, page int, perPage int) (ls interface{}, resultCount int, numberOfEntries int64, err error)
ReadAll returns all database notifications for a user @Summary Get all notifications for the current user @Description Returns an array with all notifications for the current user. @tags subscriptions @Accept json @Produce json @Param page query int false "The page number. Used for pagination. If not provided, the first page of results is returned." @Param per_page query int false "The maximum number of items per page. Note this parameter is limited by the configured maximum of items per page." @Security JWTKeyAuth @Success 200 {array} notifications.DatabaseNotification "The notifications" @Failure 403 {object} web.HTTPError "Link shares cannot have notifications." @Failure 500 {object} models.Message "Internal error" @Router /notifications [get]
func (*DatabaseNotifications) Update ¶ added in v0.17.0
Update marks a notification as read. @Summary Mark a notification as (un-)read @Description Marks a notification as either read or unread. A user can only mark their own notifications as read. @tags subscriptions @Accept json @Produce json @Security JWTKeyAuth @Param id path int true "Notification ID" @Success 200 {object} models.DatabaseNotifications "The notification to mark as read." @Failure 403 {object} web.HTTPError "The user does not have access to that notification." @Failure 403 {object} web.HTTPError "Link shares cannot have notifications." @Failure 404 {object} web.HTTPError "The notification does not exist." @Failure 500 {object} models.Message "Internal error" @Router /notifications/{id} [post]
type DecreaseAttachmentCounter ¶ added in v0.22.0
type DecreaseAttachmentCounter struct { }
DecreaseAttachmentCounter represents a listener
func (*DecreaseAttachmentCounter) Handle ¶ added in v0.22.0
func (s *DecreaseAttachmentCounter) Handle(_ *message.Message) (err error)
Handle is executed when the event DecreaseAttachmentCounter listens on is fired
func (*DecreaseAttachmentCounter) Name ¶ added in v0.22.0
func (s *DecreaseAttachmentCounter) Name() string
Name defines the name for the DecreaseAttachmentCounter listener
type DecreaseProjectCounter ¶ added in v0.21.0
type DecreaseProjectCounter struct { }
func (*DecreaseProjectCounter) Handle ¶ added in v0.21.0
func (s *DecreaseProjectCounter) Handle(_ *message.Message) (err error)
func (*DecreaseProjectCounter) Name ¶ added in v0.21.0
func (s *DecreaseProjectCounter) Name() string
type DecreaseTaskCounter ¶ added in v0.17.0
type DecreaseTaskCounter struct { }
DecreaseTaskCounter represents a listener
func (*DecreaseTaskCounter) Handle ¶ added in v0.17.0
func (s *DecreaseTaskCounter) Handle(_ *message.Message) (err error)
Handle is executed when the event DecreaseTaskCounter listens on is fired
func (*DecreaseTaskCounter) Name ¶ added in v0.17.0
func (s *DecreaseTaskCounter) Name() string
Name defines the name for the DecreaseTaskCounter listener
type DecreaseTeamCounter ¶ added in v0.17.0
type DecreaseTeamCounter struct { }
DecreaseTeamCounter represents a listener
func (*DecreaseTeamCounter) Handle ¶ added in v0.17.0
func (s *DecreaseTeamCounter) Handle(_ *message.Message) (err error)
Handle is executed when the event DecreaseTeamCounter listens on is fired
func (*DecreaseTeamCounter) Name ¶ added in v0.17.0
func (s *DecreaseTeamCounter) Name() string
Name defines the name for the DecreaseTeamCounter listener
type ErrAPITokenInvalid ¶ added in v0.22.0
type ErrAPITokenInvalid struct { }
ErrAPITokenInvalid represents an error where an api token is invalid
func (*ErrAPITokenInvalid) Error ¶ added in v0.22.0
func (err *ErrAPITokenInvalid) Error() string
func (ErrAPITokenInvalid) HTTPError ¶ added in v0.22.0
func (err ErrAPITokenInvalid) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrAttachmentDoesNotBelongToTask ¶ added in v0.20.0
ErrAttachmentDoesNotBelongToTask represents an error where the provided task cover attachment does not belong to the same task
func (ErrAttachmentDoesNotBelongToTask) Error ¶ added in v0.20.0
func (err ErrAttachmentDoesNotBelongToTask) Error() string
func (ErrAttachmentDoesNotBelongToTask) HTTPError ¶ added in v0.20.0
func (err ErrAttachmentDoesNotBelongToTask) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrBucketDoesNotBelongToProjectView ¶ added in v0.24.0
ErrBucketDoesNotBelongToProjectView represents an error where a kanban bucket does not belong to a project
func (ErrBucketDoesNotBelongToProjectView) Error ¶ added in v0.24.0
func (err ErrBucketDoesNotBelongToProjectView) Error() string
func (ErrBucketDoesNotBelongToProjectView) HTTPError ¶ added in v0.24.0
func (err ErrBucketDoesNotBelongToProjectView) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrBucketDoesNotExist ¶
type ErrBucketDoesNotExist struct {
BucketID int64
}
ErrBucketDoesNotExist represents an error where a kanban bucket does not exist
func (ErrBucketDoesNotExist) Error ¶
func (err ErrBucketDoesNotExist) Error() string
func (ErrBucketDoesNotExist) HTTPError ¶
func (err ErrBucketDoesNotExist) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrBucketLimitExceeded ¶ added in v0.15.0
ErrBucketLimitExceeded represents an error where a task is being created or moved to a bucket which has its limit already exceeded.
func (ErrBucketLimitExceeded) Error ¶ added in v0.15.0
func (err ErrBucketLimitExceeded) Error() string
func (ErrBucketLimitExceeded) HTTPError ¶ added in v0.15.0
func (err ErrBucketLimitExceeded) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrBulkTasksMustBeInSameProject ¶ added in v0.21.0
ErrBulkTasksMustBeInSameProject represents a "ErrBulkTasksMustBeInSameProject" kind of error.
func (ErrBulkTasksMustBeInSameProject) Error ¶ added in v0.21.0
func (err ErrBulkTasksMustBeInSameProject) Error() string
func (ErrBulkTasksMustBeInSameProject) HTTPError ¶ added in v0.21.0
func (err ErrBulkTasksMustBeInSameProject) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrBulkTasksNeedAtLeastOne ¶
type ErrBulkTasksNeedAtLeastOne struct{}
ErrBulkTasksNeedAtLeastOne represents a "ErrBulkTasksNeedAtLeastOne" kind of error.
func (ErrBulkTasksNeedAtLeastOne) Error ¶
func (err ErrBulkTasksNeedAtLeastOne) Error() string
func (ErrBulkTasksNeedAtLeastOne) HTTPError ¶
func (err ErrBulkTasksNeedAtLeastOne) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrCannotArchiveDefaultProject ¶ added in v0.21.0
type ErrCannotArchiveDefaultProject struct {
ProjectID int64
}
ErrCannotArchiveDefaultProject represents an error where the default project is being deleted
func (*ErrCannotArchiveDefaultProject) Error ¶ added in v0.21.0
func (err *ErrCannotArchiveDefaultProject) Error() string
func (*ErrCannotArchiveDefaultProject) HTTPError ¶ added in v0.21.0
func (err *ErrCannotArchiveDefaultProject) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrCannotDeleteDefaultProject ¶ added in v0.21.0
type ErrCannotDeleteDefaultProject struct {
ProjectID int64
}
ErrCannotDeleteDefaultProject represents an error where the default project is being deleted
func (*ErrCannotDeleteDefaultProject) Error ¶ added in v0.21.0
func (err *ErrCannotDeleteDefaultProject) Error() string
func (*ErrCannotDeleteDefaultProject) HTTPError ¶ added in v0.21.0
func (err *ErrCannotDeleteDefaultProject) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrCannotDeleteLastTeamMember ¶
ErrCannotDeleteLastTeamMember represents an error where a user wants to delete the last member of a team (probably himself)
func (ErrCannotDeleteLastTeamMember) Error ¶
func (err ErrCannotDeleteLastTeamMember) Error() string
func (ErrCannotDeleteLastTeamMember) HTTPError ¶
func (err ErrCannotDeleteLastTeamMember) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrCannotRemoveLastBucket ¶
ErrCannotRemoveLastBucket represents an error where a kanban bucket is the last on a project and thus cannot be removed.
func (ErrCannotRemoveLastBucket) Error ¶
func (err ErrCannotRemoveLastBucket) Error() string
func (ErrCannotRemoveLastBucket) HTTPError ¶
func (err ErrCannotRemoveLastBucket) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrGenericForbidden ¶
type ErrGenericForbidden struct{}
ErrGenericForbidden represents a "UsernameAlreadyExists" kind of error.
func (ErrGenericForbidden) Error ¶
func (err ErrGenericForbidden) Error() string
func (ErrGenericForbidden) HTTPError ¶
func (err ErrGenericForbidden) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrIDCannotBeZero ¶
type ErrIDCannotBeZero struct{}
ErrIDCannotBeZero represents a "IDCannotBeZero" kind of error. Used if an ID (of something, not defined) is 0 where it should not.
func (ErrIDCannotBeZero) Error ¶
func (err ErrIDCannotBeZero) Error() string
func (ErrIDCannotBeZero) HTTPError ¶
func (err ErrIDCannotBeZero) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrInvalidAPITokenPermission ¶ added in v0.22.0
ErrInvalidAPITokenPermission represents an error where an api token is invalid
func (*ErrInvalidAPITokenPermission) Error ¶ added in v0.22.0
func (err *ErrInvalidAPITokenPermission) Error() string
func (ErrInvalidAPITokenPermission) HTTPError ¶ added in v0.22.0
func (err ErrInvalidAPITokenPermission) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrInvalidData ¶
type ErrInvalidData struct {
Message string
}
ErrInvalidData represents a "ErrInvalidData" kind of error. Used when a struct is invalid -> validation failed.
func (ErrInvalidData) Error ¶
func (err ErrInvalidData) Error() string
func (ErrInvalidData) HTTPError ¶
func (err ErrInvalidData) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrInvalidFilterExpression ¶ added in v0.24.0
ErrInvalidFilterExpression represents an error where the task filter expression was invalid
func (ErrInvalidFilterExpression) Error ¶ added in v0.24.0
func (err ErrInvalidFilterExpression) Error() string
func (ErrInvalidFilterExpression) HTTPError ¶ added in v0.24.0
func (err ErrInvalidFilterExpression) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrInvalidReactionEntityKind ¶ added in v0.24.0
type ErrInvalidReactionEntityKind struct {
Kind string
}
ErrInvalidReactionEntityKind represents an error where the reaction kind is invalid
func (ErrInvalidReactionEntityKind) Error ¶ added in v0.24.0
func (err ErrInvalidReactionEntityKind) Error() string
func (ErrInvalidReactionEntityKind) HTTPError ¶ added in v0.24.0
func (err ErrInvalidReactionEntityKind) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrInvalidRelationKind ¶
type ErrInvalidRelationKind struct {
Kind RelationKind
}
ErrInvalidRelationKind represents an error where the user tries to use an invalid relation kind
func (ErrInvalidRelationKind) Error ¶
func (err ErrInvalidRelationKind) Error() string
func (ErrInvalidRelationKind) HTTPError ¶
func (err ErrInvalidRelationKind) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrInvalidRight ¶
type ErrInvalidRight struct {
Right Right
}
ErrInvalidRight represents an error where a right is invalid
func (ErrInvalidRight) Error ¶
func (err ErrInvalidRight) Error() string
func (ErrInvalidRight) HTTPError ¶
func (err ErrInvalidRight) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrInvalidSortOrder ¶
type ErrInvalidSortOrder struct {
OrderBy sortOrder
}
ErrInvalidSortOrder represents an error where the provided sort order is invalid
func (ErrInvalidSortOrder) Error ¶
func (err ErrInvalidSortOrder) Error() string
func (ErrInvalidSortOrder) HTTPError ¶
func (err ErrInvalidSortOrder) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrInvalidSortParam ¶
type ErrInvalidSortParam struct {
SortBy string
}
ErrInvalidSortParam represents an error where the provided sort param is invalid
func (ErrInvalidSortParam) Error ¶
func (err ErrInvalidSortParam) Error() string
func (ErrInvalidSortParam) HTTPError ¶
func (err ErrInvalidSortParam) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrInvalidTaskField ¶
type ErrInvalidTaskField struct {
TaskField string
}
ErrInvalidTaskField represents an error where the provided task field is invalid
func (ErrInvalidTaskField) Error ¶
func (err ErrInvalidTaskField) Error() string
func (ErrInvalidTaskField) HTTPError ¶
func (err ErrInvalidTaskField) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrInvalidTaskFilterComparator ¶
type ErrInvalidTaskFilterComparator struct {
Comparator taskFilterComparator
}
ErrInvalidTaskFilterComparator represents an error where the provided task field is invalid
func (ErrInvalidTaskFilterComparator) Error ¶
func (err ErrInvalidTaskFilterComparator) Error() string
func (ErrInvalidTaskFilterComparator) HTTPError ¶
func (err ErrInvalidTaskFilterComparator) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrInvalidTaskFilterConcatinator ¶
type ErrInvalidTaskFilterConcatinator struct {
Concatinator taskFilterConcatinator
}
ErrInvalidTaskFilterConcatinator represents an error where the provided task field is invalid
func (ErrInvalidTaskFilterConcatinator) Error ¶
func (err ErrInvalidTaskFilterConcatinator) Error() string
func (ErrInvalidTaskFilterConcatinator) HTTPError ¶
func (err ErrInvalidTaskFilterConcatinator) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrInvalidTaskFilterValue ¶ added in v0.14.0
type ErrInvalidTaskFilterValue struct { Value interface{} Field string }
ErrInvalidTaskFilterValue represents an error where the provided task filter value is invalid
func (ErrInvalidTaskFilterValue) Error ¶ added in v0.14.0
func (err ErrInvalidTaskFilterValue) Error() string
func (ErrInvalidTaskFilterValue) HTTPError ¶ added in v0.14.0
func (err ErrInvalidTaskFilterValue) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrLabelDoesNotExist ¶
type ErrLabelDoesNotExist struct {
LabelID int64
}
ErrLabelDoesNotExist represents an error where a label does not exist
func (ErrLabelDoesNotExist) Error ¶
func (err ErrLabelDoesNotExist) Error() string
func (ErrLabelDoesNotExist) HTTPError ¶
func (err ErrLabelDoesNotExist) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrLabelIsAlreadyOnTask ¶
ErrLabelIsAlreadyOnTask represents an error where a label is already bound to a task
func (ErrLabelIsAlreadyOnTask) Error ¶
func (err ErrLabelIsAlreadyOnTask) Error() string
func (ErrLabelIsAlreadyOnTask) HTTPError ¶
func (err ErrLabelIsAlreadyOnTask) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrLinkSharePasswordInvalid ¶ added in v0.17.0
type ErrLinkSharePasswordInvalid struct {
}ErrLinkSharePasswordInvalid represents an error where a subscription entity type is unknown
func (*ErrLinkSharePasswordInvalid) Error ¶ added in v0.17.0
func (err *ErrLinkSharePasswordInvalid) Error() string
func (ErrLinkSharePasswordInvalid) HTTPError ¶ added in v0.17.0
func (err ErrLinkSharePasswordInvalid) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrLinkSharePasswordRequired ¶ added in v0.17.0
type ErrLinkSharePasswordRequired struct {
}ErrLinkSharePasswordRequired represents an error where a link share authentication requires a password and none was provided
func (*ErrLinkSharePasswordRequired) Error ¶ added in v0.17.0
func (err *ErrLinkSharePasswordRequired) Error() string
func (ErrLinkSharePasswordRequired) HTTPError ¶ added in v0.17.0
func (err ErrLinkSharePasswordRequired) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrLinkShareTokenInvalid ¶ added in v0.21.0
type ErrLinkShareTokenInvalid struct { }
ErrLinkShareTokenInvalid represents an error where a link share token is invalid
func (*ErrLinkShareTokenInvalid) Error ¶ added in v0.21.0
func (err *ErrLinkShareTokenInvalid) Error() string
func (ErrLinkShareTokenInvalid) HTTPError ¶ added in v0.21.0
func (err ErrLinkShareTokenInvalid) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrMustHaveProjectViewToSortByPosition ¶ added in v0.24.0
type ErrMustHaveProjectViewToSortByPosition struct{}
ErrMustHaveProjectViewToSortByPosition represents an error where no project view id was supplied
func (ErrMustHaveProjectViewToSortByPosition) Error ¶ added in v0.24.0
func (err ErrMustHaveProjectViewToSortByPosition) Error() string
func (ErrMustHaveProjectViewToSortByPosition) HTTPError ¶ added in v0.24.0
func (err ErrMustHaveProjectViewToSortByPosition) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrMustProvideUser ¶ added in v0.24.3
type ErrMustProvideUser struct { }
ErrMustProvideUser represents an error where you need to provide a user to fetch subscriptions
func (*ErrMustProvideUser) Error ¶ added in v0.24.3
func (err *ErrMustProvideUser) Error() string
func (ErrMustProvideUser) HTTPError ¶ added in v0.24.3
func (err ErrMustProvideUser) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrNeedToHaveProjectReadAccess ¶ added in v0.21.0
ErrNeedToHaveProjectReadAccess represents an error, where the user dont has read access to that Project
func (ErrNeedToHaveProjectReadAccess) Error ¶ added in v0.21.0
func (err ErrNeedToHaveProjectReadAccess) Error() string
func (ErrNeedToHaveProjectReadAccess) HTTPError ¶ added in v0.21.0
func (err ErrNeedToHaveProjectReadAccess) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrNoRightToSeeTask ¶
ErrNoRightToSeeTask represents an error where a user does not have the right to see a task
func (ErrNoRightToSeeTask) Error ¶
func (err ErrNoRightToSeeTask) Error() string
func (ErrNoRightToSeeTask) HTTPError ¶
func (err ErrNoRightToSeeTask) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrOIDCTeamDoesNotExist ¶ added in v0.24.0
ErrOIDCTeamDoesNotExist represents an error where a team with specified oidcId property does not exist for a given issuer
func (ErrOIDCTeamDoesNotExist) Error ¶ added in v0.24.0
func (err ErrOIDCTeamDoesNotExist) Error() string
ErrTeamDoesNotExist represents an error where a team does not exist
func (ErrOIDCTeamDoesNotExist) HTTPError ¶ added in v0.24.0
func (err ErrOIDCTeamDoesNotExist) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrOIDCTeamsDoNotExistForUser ¶ added in v0.24.0
type ErrOIDCTeamsDoNotExistForUser struct {
UserID int64
}
ErrOIDCTeamsDoNotExistForUser represents an error where an oidcTeam does not exist for the user
func (ErrOIDCTeamsDoNotExistForUser) Error ¶ added in v0.24.0
func (err ErrOIDCTeamsDoNotExistForUser) Error() string
func (ErrOIDCTeamsDoNotExistForUser) HTTPError ¶ added in v0.24.0
func (err ErrOIDCTeamsDoNotExistForUser) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrOnlyOneDoneBucketPerProject ¶ added in v0.21.0
ErrOnlyOneDoneBucketPerProject represents an error where a bucket is set to the done bucket but one already exists for its project.
func (*ErrOnlyOneDoneBucketPerProject) Error ¶ added in v0.21.0
func (err *ErrOnlyOneDoneBucketPerProject) Error() string
func (*ErrOnlyOneDoneBucketPerProject) HTTPError ¶ added in v0.21.0
func (err *ErrOnlyOneDoneBucketPerProject) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrParentTaskCannotBeTheSame ¶
type ErrParentTaskCannotBeTheSame struct {
TaskID int64
}
ErrParentTaskCannotBeTheSame represents an error where the user tries to set a tasks parent as the same
func (ErrParentTaskCannotBeTheSame) Error ¶
func (err ErrParentTaskCannotBeTheSame) Error() string
func (ErrParentTaskCannotBeTheSame) HTTPError ¶
func (err ErrParentTaskCannotBeTheSame) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrProjectCannotBeChildOfItself ¶ added in v0.21.0
type ErrProjectCannotBeChildOfItself struct {
ProjectID int64
}
ErrProjectCannotBeChildOfItself represents an error where a project cannot become a child of its own
func (*ErrProjectCannotBeChildOfItself) Error ¶ added in v0.21.0
func (err *ErrProjectCannotBeChildOfItself) Error() string
func (*ErrProjectCannotBeChildOfItself) HTTPError ¶ added in v0.21.0
func (err *ErrProjectCannotBeChildOfItself) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrProjectCannotBelongToAPseudoParentProject ¶ added in v0.21.0
ErrProjectCannotBelongToAPseudoParentProject represents an error where a project cannot belong to a pseudo project
func (*ErrProjectCannotBelongToAPseudoParentProject) Error ¶ added in v0.21.0
func (err *ErrProjectCannotBelongToAPseudoParentProject) Error() string
func (*ErrProjectCannotBelongToAPseudoParentProject) HTTPError ¶ added in v0.21.0
func (err *ErrProjectCannotBelongToAPseudoParentProject) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrProjectCannotHaveACyclicRelationship ¶ added in v0.21.0
ErrProjectCannotHaveACyclicRelationship represents an error where a project cannot have a cyclic parent relationship
func (*ErrProjectCannotHaveACyclicRelationship) CycleString ¶ added in v0.21.0
func (err *ErrProjectCannotHaveACyclicRelationship) CycleString() string
func (*ErrProjectCannotHaveACyclicRelationship) Error ¶ added in v0.21.0
func (err *ErrProjectCannotHaveACyclicRelationship) Error() string
func (*ErrProjectCannotHaveACyclicRelationship) HTTPError ¶ added in v0.21.0
func (err *ErrProjectCannotHaveACyclicRelationship) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrProjectDoesNotExist ¶ added in v0.21.0
type ErrProjectDoesNotExist struct {
ID int64
}
ErrProjectDoesNotExist represents a "ErrProjectDoesNotExist" kind of error. Used if the project does not exist.
func (ErrProjectDoesNotExist) Error ¶ added in v0.21.0
func (err ErrProjectDoesNotExist) Error() string
func (ErrProjectDoesNotExist) HTTPError ¶ added in v0.21.0
func (err ErrProjectDoesNotExist) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrProjectIdentifierIsNotUnique ¶ added in v0.21.0
type ErrProjectIdentifierIsNotUnique struct {
Identifier string
}
ErrProjectIdentifierIsNotUnique represents a "ErrProjectIdentifierIsNotUnique" kind of error. Used if the provided project identifier is not unique.
func (ErrProjectIdentifierIsNotUnique) Error ¶ added in v0.21.0
func (err ErrProjectIdentifierIsNotUnique) Error() string
func (ErrProjectIdentifierIsNotUnique) HTTPError ¶ added in v0.21.0
func (err ErrProjectIdentifierIsNotUnique) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrProjectIsArchived ¶ added in v0.21.0
type ErrProjectIsArchived struct {
ProjectID int64
}
ErrProjectIsArchived represents an error, where a project is archived
func (ErrProjectIsArchived) Error ¶ added in v0.21.0
func (err ErrProjectIsArchived) Error() string
func (ErrProjectIsArchived) HTTPError ¶ added in v0.21.0
func (err ErrProjectIsArchived) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrProjectShareDoesNotExist ¶ added in v0.21.0
type ErrProjectShareDoesNotExist struct {}
ErrProjectShareDoesNotExist represents a "ErrProjectShareDoesNotExist" kind of error. Used if the project share does not exist.
func (ErrProjectShareDoesNotExist) Error ¶ added in v0.21.0
func (err ErrProjectShareDoesNotExist) Error() string
func (ErrProjectShareDoesNotExist) HTTPError ¶ added in v0.21.0
func (err ErrProjectShareDoesNotExist) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrProjectTitleCannotBeEmpty ¶ added in v0.21.0
type ErrProjectTitleCannotBeEmpty struct{}
ErrProjectTitleCannotBeEmpty represents a "ErrProjectTitleCannotBeEmpty" kind of error. Used if the project does not exist.
func (ErrProjectTitleCannotBeEmpty) Error ¶ added in v0.21.0
func (err ErrProjectTitleCannotBeEmpty) Error() string
func (ErrProjectTitleCannotBeEmpty) HTTPError ¶ added in v0.21.0
func (err ErrProjectTitleCannotBeEmpty) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrProjectViewDoesNotExist ¶ added in v0.24.0
type ErrProjectViewDoesNotExist struct {
ProjectViewID int64
}
ErrProjectViewDoesNotExist represents an error where the default project is being deleted
func (*ErrProjectViewDoesNotExist) Error ¶ added in v0.24.0
func (err *ErrProjectViewDoesNotExist) Error() string
func (*ErrProjectViewDoesNotExist) HTTPError ¶ added in v0.24.0
func (err *ErrProjectViewDoesNotExist) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrRelationAlreadyExists ¶
type ErrRelationAlreadyExists struct { Kind RelationKind TaskID int64 OtherTaskID int64 }
ErrRelationAlreadyExists represents an error where the user tries to create an already existing relation
func (ErrRelationAlreadyExists) Error ¶
func (err ErrRelationAlreadyExists) Error() string
func (ErrRelationAlreadyExists) HTTPError ¶
func (err ErrRelationAlreadyExists) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrRelationDoesNotExist ¶
type ErrRelationDoesNotExist struct { Kind RelationKind TaskID int64 OtherTaskID int64 }
ErrRelationDoesNotExist represents an error where a task relation does not exist.
func (ErrRelationDoesNotExist) Error ¶
func (err ErrRelationDoesNotExist) Error() string
func (ErrRelationDoesNotExist) HTTPError ¶
func (err ErrRelationDoesNotExist) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrRelationTasksCannotBeTheSame ¶
ErrRelationTasksCannotBeTheSame represents an error where the user tries to relate a task with itself
func (ErrRelationTasksCannotBeTheSame) Error ¶
func (err ErrRelationTasksCannotBeTheSame) Error() string
func (ErrRelationTasksCannotBeTheSame) HTTPError ¶
func (err ErrRelationTasksCannotBeTheSame) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrReminderRelativeToMissing ¶ added in v0.21.0
type ErrReminderRelativeToMissing struct {
TaskID int64
}
ErrReminderRelativeToMissing represents an error where a task has a relative reminder without reference date
func (ErrReminderRelativeToMissing) Error ¶ added in v0.21.0
func (err ErrReminderRelativeToMissing) Error() string
func (ErrReminderRelativeToMissing) HTTPError ¶ added in v0.21.0
func (err ErrReminderRelativeToMissing) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrSavedFilterDoesNotExist ¶ added in v0.15.0
type ErrSavedFilterDoesNotExist struct {
SavedFilterID int64
}
ErrSavedFilterDoesNotExist represents an error where a kanban bucket does not exist
func (ErrSavedFilterDoesNotExist) Error ¶ added in v0.15.0
func (err ErrSavedFilterDoesNotExist) Error() string
func (ErrSavedFilterDoesNotExist) HTTPError ¶ added in v0.15.0
func (err ErrSavedFilterDoesNotExist) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrSavedFilterNotAvailableForLinkShare ¶ added in v0.15.0
type ErrSavedFilterNotAvailableForLinkShare struct {}
ErrSavedFilterNotAvailableForLinkShare represents an error where a kanban bucket does not exist
func (ErrSavedFilterNotAvailableForLinkShare) Error ¶ added in v0.15.0
func (err ErrSavedFilterNotAvailableForLinkShare) Error() string
func (ErrSavedFilterNotAvailableForLinkShare) HTTPError ¶ added in v0.15.0
func (err ErrSavedFilterNotAvailableForLinkShare) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrSubscriptionAlreadyExists ¶ added in v0.17.0
type ErrSubscriptionAlreadyExists struct { EntityID int64 EntityType SubscriptionEntityType UserID int64 }
ErrSubscriptionAlreadyExists represents an error where a subscription entity already exists
func (*ErrSubscriptionAlreadyExists) Error ¶ added in v0.17.0
func (err *ErrSubscriptionAlreadyExists) Error() string
func (ErrSubscriptionAlreadyExists) HTTPError ¶ added in v0.17.0
func (err ErrSubscriptionAlreadyExists) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrTaskAttachmentDoesNotExist ¶
ErrTaskAttachmentDoesNotExist represents an error where the user tries to relate a task with itself
func (ErrTaskAttachmentDoesNotExist) Error ¶
func (err ErrTaskAttachmentDoesNotExist) Error() string
func (ErrTaskAttachmentDoesNotExist) HTTPError ¶
func (err ErrTaskAttachmentDoesNotExist) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrTaskAttachmentIsTooLarge ¶
type ErrTaskAttachmentIsTooLarge struct {
Size uint64
}
ErrTaskAttachmentIsTooLarge represents an error where the user tries to relate a task with itself
func (ErrTaskAttachmentIsTooLarge) Error ¶
func (err ErrTaskAttachmentIsTooLarge) Error() string
func (ErrTaskAttachmentIsTooLarge) HTTPError ¶
func (err ErrTaskAttachmentIsTooLarge) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrTaskCannotBeEmpty ¶
type ErrTaskCannotBeEmpty struct{}
ErrTaskCannotBeEmpty represents a "ErrTaskCannotBeEmpty" kind of error.
func (ErrTaskCannotBeEmpty) Error ¶
func (err ErrTaskCannotBeEmpty) Error() string
func (ErrTaskCannotBeEmpty) HTTPError ¶
func (err ErrTaskCannotBeEmpty) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrTaskCommentDoesNotExist ¶
ErrTaskCommentDoesNotExist represents an error where a task comment does not exist
func (ErrTaskCommentDoesNotExist) Error ¶
func (err ErrTaskCommentDoesNotExist) Error() string
func (ErrTaskCommentDoesNotExist) HTTPError ¶
func (err ErrTaskCommentDoesNotExist) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrTaskDoesNotExist ¶
type ErrTaskDoesNotExist struct {
ID int64
}
ErrTaskDoesNotExist represents a "ErrProjectDoesNotExist" kind of error. Used if the project does not exist.
func (ErrTaskDoesNotExist) Error ¶
func (err ErrTaskDoesNotExist) Error() string
func (ErrTaskDoesNotExist) HTTPError ¶
func (err ErrTaskDoesNotExist) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrTaskRelationCycle ¶ added in v0.23.0
type ErrTaskRelationCycle struct { Kind RelationKind TaskID int64 OtherTaskID int64 }
ErrTaskRelationCycle represents an error where the user tries to create an already existing relation
func (ErrTaskRelationCycle) Error ¶ added in v0.23.0
func (err ErrTaskRelationCycle) Error() string
func (ErrTaskRelationCycle) HTTPError ¶ added in v0.23.0
func (err ErrTaskRelationCycle) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrTeamAlreadyHasAccess ¶
ErrTeamAlreadyHasAccess represents an error where a team already has access to a project
func (ErrTeamAlreadyHasAccess) Error ¶
func (err ErrTeamAlreadyHasAccess) Error() string
func (ErrTeamAlreadyHasAccess) HTTPError ¶
func (err ErrTeamAlreadyHasAccess) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrTeamDoesNotExist ¶
type ErrTeamDoesNotExist struct {
TeamID int64
}
func (ErrTeamDoesNotExist) Error ¶
func (err ErrTeamDoesNotExist) Error() string
func (ErrTeamDoesNotExist) HTTPError ¶
func (err ErrTeamDoesNotExist) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrTeamDoesNotHaveAccessToProject ¶ added in v0.21.0
ErrTeamDoesNotHaveAccessToProject represents an error, where the Team is not the owner of that Project (used i.e. when deleting a Project)
func (ErrTeamDoesNotHaveAccessToProject) Error ¶ added in v0.21.0
func (err ErrTeamDoesNotHaveAccessToProject) Error() string
func (ErrTeamDoesNotHaveAccessToProject) HTTPError ¶ added in v0.21.0
func (err ErrTeamDoesNotHaveAccessToProject) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrTeamNameCannotBeEmpty ¶
type ErrTeamNameCannotBeEmpty struct {
TeamID int64
}
ErrTeamNameCannotBeEmpty represents an error where a team name is empty.
func (ErrTeamNameCannotBeEmpty) Error ¶
func (err ErrTeamNameCannotBeEmpty) Error() string
func (ErrTeamNameCannotBeEmpty) HTTPError ¶
func (err ErrTeamNameCannotBeEmpty) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrUnknownSubscriptionEntityType ¶ added in v0.17.0
type ErrUnknownSubscriptionEntityType struct {
EntityType SubscriptionEntityType
}
ErrUnknownSubscriptionEntityType represents an error where a subscription entity type is unknown
func (*ErrUnknownSubscriptionEntityType) Error ¶ added in v0.17.0
func (err *ErrUnknownSubscriptionEntityType) Error() string
func (ErrUnknownSubscriptionEntityType) HTTPError ¶ added in v0.17.0
func (err ErrUnknownSubscriptionEntityType) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrUserAlreadyAssigned ¶ added in v0.20.0
ErrUserAlreadyAssigned represents an error where the user is already assigned to this task
func (ErrUserAlreadyAssigned) Error ¶ added in v0.20.0
func (err ErrUserAlreadyAssigned) Error() string
func (ErrUserAlreadyAssigned) HTTPError ¶ added in v0.20.0
func (err ErrUserAlreadyAssigned) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrUserAlreadyHasAccess ¶
ErrUserAlreadyHasAccess represents an error where a user already has access to a project
func (ErrUserAlreadyHasAccess) Error ¶
func (err ErrUserAlreadyHasAccess) Error() string
func (ErrUserAlreadyHasAccess) HTTPError ¶
func (err ErrUserAlreadyHasAccess) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrUserDoesNotHaveAccessToProject ¶ added in v0.21.0
ErrUserDoesNotHaveAccessToProject represents an error, where the user is not the owner of that Project (used i.e. when deleting a Project)
func (ErrUserDoesNotHaveAccessToProject) Error ¶ added in v0.21.0
func (err ErrUserDoesNotHaveAccessToProject) Error() string
func (ErrUserDoesNotHaveAccessToProject) HTTPError ¶ added in v0.21.0
func (err ErrUserDoesNotHaveAccessToProject) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrUserHasNoAccessToLabel ¶
ErrUserHasNoAccessToLabel represents an error where a user does not have the right to see a label
func (ErrUserHasNoAccessToLabel) Error ¶
func (err ErrUserHasNoAccessToLabel) Error() string
func (ErrUserHasNoAccessToLabel) HTTPError ¶
func (err ErrUserHasNoAccessToLabel) HTTPError() web.HTTPError
HTTPError holds the http error description
type ErrUserIsMemberOfTeam ¶
ErrUserIsMemberOfTeam represents an error where a user is already member of a team.
func (ErrUserIsMemberOfTeam) Error ¶
func (err ErrUserIsMemberOfTeam) Error() string
func (ErrUserIsMemberOfTeam) HTTPError ¶
func (err ErrUserIsMemberOfTeam) HTTPError() web.HTTPError
HTTPError holds the http error description
type Favorite ¶ added in v0.18.0
type Favorite struct { EntityID int64 `xorm:"bigint not null pk"` UserID int64 `xorm:"bigint not null pk"` Kind FavoriteKind `xorm:"int not null pk"` }
Favorite represents an entity which is a favorite to someone
type FavoriteKind ¶ added in v0.18.0
type FavoriteKind int
FavoriteKind represents the kind of entities that can be marked as favorite
const ( FavoriteKindUnknown FavoriteKind = iota FavoriteKindTask FavoriteKindProject )
type HandleTaskCommentEditMentions ¶ added in v0.18.0
type HandleTaskCommentEditMentions struct { }
HandleTaskCommentEditMentions represents a listener
func (*HandleTaskCommentEditMentions) Handle ¶ added in v0.18.0
func (s *HandleTaskCommentEditMentions) Handle(msg *message.Message) (err error)
Handle is executed when the event HandleTaskCommentEditMentions listens on is fired
func (*HandleTaskCommentEditMentions) Name ¶ added in v0.18.0
func (s *HandleTaskCommentEditMentions) Name() string
Name defines the name for the HandleTaskCommentEditMentions listener
type HandleTaskCreateMentions ¶ added in v0.18.0
type HandleTaskCreateMentions struct { }
HandleTaskCreateMentions represents a listener
func (*HandleTaskCreateMentions) Handle ¶ added in v0.18.0
func (s *HandleTaskCreateMentions) Handle(msg *message.Message) (err error)
Handle is executed when the event HandleTaskCreateMentions listens on is fired
func (*HandleTaskCreateMentions) Name ¶ added in v0.18.0
func (s *HandleTaskCreateMentions) Name() string
Name defines the name for the HandleTaskCreateMentions listener
type HandleTaskUpdateLastUpdated ¶ added in v0.20.3
type HandleTaskUpdateLastUpdated struct { }
HandleTaskUpdateLastUpdated represents a listener
func (*HandleTaskUpdateLastUpdated) Handle ¶ added in v0.20.3
func (s *HandleTaskUpdateLastUpdated) Handle(msg *message.Message) (err error)
Handle is executed when the event HandleTaskUpdateLastUpdated listens on is fired
func (*HandleTaskUpdateLastUpdated) Name ¶ added in v0.20.3
func (s *HandleTaskUpdateLastUpdated) Name() string
Name defines the name for the HandleTaskUpdateLastUpdated listener
type HandleTaskUpdatedMentions ¶ added in v0.18.0
type HandleTaskUpdatedMentions struct { }
HandleTaskUpdatedMentions represents a listener
func (*HandleTaskUpdatedMentions) Handle ¶ added in v0.18.0
func (s *HandleTaskUpdatedMentions) Handle(msg *message.Message) (err error)
Handle is executed when the event HandleTaskUpdatedMentions listens on is fired
func (*HandleTaskUpdatedMentions) Name ¶ added in v0.18.0
func (s *HandleTaskUpdatedMentions) Name() string
Name defines the name for the HandleTaskUpdatedMentions listener
type HandleUserDataExport ¶ added in v0.18.0
type HandleUserDataExport struct { }
HandleUserDataExport represents a listener
func (*HandleUserDataExport) Handle ¶ added in v0.18.0
func (s *HandleUserDataExport) Handle(msg *message.Message) (err error)
Handle is executed when the event HandleUserDataExport listens on is fired
func (*HandleUserDataExport) Name ¶ added in v0.18.0
func (s *HandleUserDataExport) Name() string
Name defines the name for the HandleUserDataExport listener
type IncreaseAttachmentCounter ¶ added in v0.22.0
type IncreaseAttachmentCounter struct { }
IncreaseAttachmentCounter represents a listener
func (*IncreaseAttachmentCounter) Handle ¶ added in v0.22.0
func (s *IncreaseAttachmentCounter) Handle(_ *message.Message) (err error)
Handle is executed when the event IncreaseAttachmentCounter listens on is fired
func (*IncreaseAttachmentCounter) Name ¶ added in v0.22.0
func (s *IncreaseAttachmentCounter) Name() string
Name defines the name for the IncreaseAttachmentCounter listener
type IncreaseProjectCounter ¶ added in v0.21.0
type IncreaseProjectCounter struct { }
func (*IncreaseProjectCounter) Handle ¶ added in v0.21.0
func (s *IncreaseProjectCounter) Handle(_ *message.Message) (err error)
func (*IncreaseProjectCounter) Name ¶ added in v0.21.0
func (s *IncreaseProjectCounter) Name() string
type IncreaseTaskCounter ¶ added in v0.17.0
type IncreaseTaskCounter struct { }
IncreaseTaskCounter represents a listener
func (*IncreaseTaskCounter) Handle ¶ added in v0.17.0
func (s *IncreaseTaskCounter) Handle(_ *message.Message) (err error)
Handle is executed when the event IncreaseTaskCounter listens on is fired
func (*IncreaseTaskCounter) Name ¶ added in v0.17.0
func (s *IncreaseTaskCounter) Name() string
Name defines the name for the IncreaseTaskCounter listener
type IncreaseTeamCounter ¶ added in v0.17.0
type IncreaseTeamCounter struct { }
IncreaseTeamCounter represents a listener
func (*IncreaseTeamCounter) Handle ¶ added in v0.17.0
func (s *IncreaseTeamCounter) Handle(_ *message.Message) (err error)
Handle is executed when the event IncreaseTeamCounter listens on is fired
func (*IncreaseTeamCounter) Name ¶ added in v0.17.0
func (s *IncreaseTeamCounter) Name() string
Name defines the name for the IncreaseTeamCounter listener
type Label ¶
type Label struct { // The unique, numeric id of this label. ID int64 `xorm:"bigint autoincr not null unique pk" json:"id" param:"label"` // The title of the lable. You'll see this one on tasks associated with it. Title string `xorm:"varchar(250) not null" json:"title" valid:"runelength(1|250)" minLength:"1" maxLength:"250"` // The label description. Description string `xorm:"longtext null" json:"description"` // The color this label has in hex format. HexColor string `xorm:"varchar(6) null" json:"hex_color" valid:"runelength(0|7)" maxLength:"7"` CreatedByID int64 `xorm:"bigint not null" json:"-"` // The user who created this label CreatedBy *user.User `xorm:"-" json:"created_by"` // A timestamp when this label was created. You cannot change this value. Created time.Time `xorm:"created not null" json:"created"` // A timestamp when this label was last updated. You cannot change this value. Updated time.Time `xorm:"updated not null" json:"updated"` web.CRUDable `xorm:"-" json:"-"` web.Rights `xorm:"-" json:"-"` }
Label represents a label
func GetLabelSimple ¶ added in v0.20.3
func (*Label) Create ¶
Create creates a new label @Summary Create a label @Description Creates a new label. @tags labels @Accept json @Produce json @Security JWTKeyAuth @Param label body models.Label true "The label object" @Success 201 {object} models.Label "The created label object." @Failure 400 {object} web.HTTPError "Invalid label object provided." @Failure 500 {object} models.Message "Internal error" @Router /labels [put]
func (*Label) Delete ¶
Delete deletes a label @Summary Delete a label @Description Delete an existing label. The user needs to be the creator of the label to be able to do this. @tags labels @Accept json @Produce json @Security JWTKeyAuth @Param id path int true "Label ID" @Success 200 {object} models.Label "The label was successfully deleted." @Failure 403 {object} web.HTTPError "Not allowed to delete the label." @Failure 404 {object} web.HTTPError "Label not found." @Failure 500 {object} models.Message "Internal error" @Router /labels/{id} [delete]
func (*Label) ReadAll ¶
func (l *Label) ReadAll(s *xorm.Session, a web.Auth, search string, page int, perPage int) (ls interface{}, resultCount int, numberOfEntries int64, err error)
ReadAll gets all labels a user can use @Summary Get all labels a user has access to @Description Returns all labels which are either created by the user or associated with a task the user has at least read-access to. @tags labels @Accept json @Produce json @Param page query int false "The page number. Used for pagination. If not provided, the first page of results is returned." @Param per_page query int false "The maximum number of items per page. Note this parameter is limited by the configured maximum of items per page." @Param s query string false "Search labels by label text." @Security JWTKeyAuth @Success 200 {array} models.Label "The labels" @Failure 500 {object} models.Message "Internal error" @Router /labels [get]
func (*Label) ReadOne ¶
ReadOne gets one label @Summary Gets one label @Description Returns one label by its ID. @tags labels @Accept json @Produce json @Param id path int true "Label ID" @Security JWTKeyAuth @Success 200 {object} models.Label "The label" @Failure 403 {object} web.HTTPError "The user does not have access to the label" @Failure 404 {object} web.HTTPError "Label not found" @Failure 500 {object} models.Message "Internal error" @Router /labels/{id} [get]
func (*Label) Update ¶
Update updates a label @Summary Update a label @Description Update an existing label. The user needs to be the creator of the label to be able to do this. @tags labels @Accept json @Produce json @Security JWTKeyAuth @Param id path int true "Label ID" @Param label body models.Label true "The label object" @Success 200 {object} models.Label "The created label object." @Failure 400 {object} web.HTTPError "Invalid label object provided." @Failure 403 {object} web.HTTPError "Not allowed to update the label." @Failure 404 {object} web.HTTPError "Label not found." @Failure 500 {object} models.Message "Internal error" @Router /labels/{id} [put]
type LabelByTaskIDsOptions ¶
type LabelByTaskIDsOptions struct { User web.Auth Search []string Page int PerPage int TaskIDs []int64 GetUnusedLabels bool GroupByLabelIDsOnly bool GetForUser bool }
LabelByTaskIDsOptions is a struct to not clutter the function with too many optional parameters.
type LabelTask ¶
type LabelTask struct { // The unique, numeric id of this label. ID int64 `xorm:"bigint autoincr not null unique pk" json:"-"` TaskID int64 `xorm:"bigint INDEX not null" json:"-" param:"projecttask"` // The label id you want to associate with a task. LabelID int64 `xorm:"bigint INDEX not null" json:"label_id" param:"label"` // A timestamp when this task was created. You cannot change this value. Created time.Time `xorm:"created not null" json:"created"` web.CRUDable `xorm:"-" json:"-"` web.Rights `xorm:"-" json:"-"` }
LabelTask represents a relation between a label and a task
func (*LabelTask) Create ¶
Create adds a label to a task @Summary Add a label to a task @Description Add a label to a task. The user needs to have write-access to the project to be able do this. @tags labels @Accept json @Produce json @Security JWTKeyAuth @Param task path int true "Task ID" @Param label body models.LabelTask true "The label object" @Success 201 {object} models.LabelTask "The created label relation object." @Failure 400 {object} web.HTTPError "Invalid label object provided." @Failure 403 {object} web.HTTPError "Not allowed to add the label." @Failure 404 {object} web.HTTPError "The label does not exist." @Failure 500 {object} models.Message "Internal error" @Router /tasks/{task}/labels [put]
func (*LabelTask) Delete ¶
Delete deletes a label on a task @Summary Remove a label from a task @Description Remove a label from a task. The user needs to have write-access to the project to be able do this. @tags labels @Accept json @Produce json @Security JWTKeyAuth @Param task path int true "Task ID" @Param label path int true "Label ID" @Success 200 {object} models.Message "The label was successfully removed." @Failure 403 {object} web.HTTPError "Not allowed to remove the label." @Failure 404 {object} web.HTTPError "Label not found." @Failure 500 {object} models.Message "Internal error" @Router /tasks/{task}/labels/{label} [delete]
func (*LabelTask) ReadAll ¶
func (lt *LabelTask) ReadAll(s *xorm.Session, a web.Auth, search string, page int, _ int) (result interface{}, resultCount int, numberOfTotalItems int64, err error)
ReadAll gets all labels on a task @Summary Get all labels on a task @Description Returns all labels which are assicociated with a given task. @tags labels @Accept json @Produce json @Param task path int true "Task ID" @Param page query int false "The page number. Used for pagination. If not provided, the first page of results is returned." @Param per_page query int false "The maximum number of items per page. Note this parameter is limited by the configured maximum of items per page." @Param s query string false "Search labels by label text." @Security JWTKeyAuth @Success 200 {array} models.Label "The labels" @Failure 500 {object} models.Message "Internal error" @Router /tasks/{task}/labels [get]
type LabelTaskBulk ¶
type LabelTaskBulk struct { // All labels you want to update at once. Labels []*Label `json:"labels"` TaskID int64 `json:"-" param:"projecttask"` web.CRUDable `json:"-"` web.Rights `json:"-"` }
LabelTaskBulk is a helper struct to update a bunch of labels at once
func (*LabelTaskBulk) Create ¶
Create updates a bunch of labels on a task at once @Summary Update all labels on a task. @Description Updates all labels on a task. Every label which is not passed but exists on the task will be deleted. Every label which does not exist on the task will be added. All labels which are passed and already exist on the task won't be touched. @tags labels @Accept json @Produce json @Security JWTKeyAuth @Param label body models.LabelTaskBulk true "The array of labels" @Param taskID path int true "Task ID" @Success 201 {object} models.LabelTaskBulk "The updated labels object." @Failure 400 {object} web.HTTPError "Invalid label object provided." @Failure 500 {object} models.Message "Internal error" @Router /tasks/{taskID}/labels/bulk [post]
type LabelWithTaskID ¶ added in v0.20.3
LabelWithTaskID is a helper struct, contains the label + its task ID
func GetLabelsByTaskIDs ¶ added in v0.20.3
func GetLabelsByTaskIDs(s *xorm.Session, opts *LabelByTaskIDsOptions) (ls []*LabelWithTaskID, resultCount int, totalEntries int64, err error)
GetLabelsByTaskIDs is a helper function to get all labels for a set of tasks Used when getting all labels for one task as well when getting all lables
type LinkSharing ¶
type LinkSharing struct { // The ID of the shared thing ID int64 `xorm:"bigint autoincr not null unique pk" json:"id" param:"share"` // The public id to get this shared project Hash string `xorm:"varchar(40) not null unique" json:"hash" param:"hash"` // The name of this link share. All actions someone takes while being authenticated with that link will appear with that name. Name string `xorm:"text null" json:"name"` // The ID of the shared project ProjectID int64 `xorm:"bigint not null" json:"-" param:"project"` // The right this project is shared with. 0 = Read only, 1 = Read & Write, 2 = Admin. See the docs for more details. Right Right `xorm:"bigint INDEX not null default 0" json:"right" valid:"length(0|2)" maximum:"2" default:"0"` // The kind of this link. 0 = undefined, 1 = without password, 2 = with password. SharingType SharingType `xorm:"bigint INDEX not null default 0" json:"sharing_type" valid:"length(0|2)" maximum:"2" default:"0"` // The password of this link share. You can only set it, not retrieve it after the link share has been created. Password string `xorm:"text null" json:"password"` // The user who shared this project // A timestamp when this project was shared. You cannot change this value. Created time.Time `xorm:"created not null" json:"created"` // A timestamp when this share was last updated. You cannot change this value. Updated time.Time `xorm:"updated not null" json:"updated"` web.CRUDable `xorm:"-" json:"-"` web.Rights `xorm:"-" json:"-"` }
LinkSharing represents a shared project
func GetLinkShareByHash ¶
func GetLinkShareByHash(s *xorm.Session, hash string) (share *LinkSharing, err error)
GetLinkShareByHash returns a link share by hash
func GetLinkShareByID ¶ added in v0.17.0
func GetLinkShareByID(s *xorm.Session, id int64) (share *LinkSharing, err error)
GetLinkShareByID returns a link share by its id.
func GetLinkShareFromClaims ¶
func GetLinkShareFromClaims(claims jwt.MapClaims) (share *LinkSharing, err error)
GetLinkShareFromClaims builds a link sharing object from jwt claims
func (*LinkSharing) Create ¶
Create creates a new link share for a given project @Summary Share a project via link @Description Share a project via link. The user needs to have write-access to the project to be able do this. @tags sharing @Accept json @Produce json @Security JWTKeyAuth @Param project path int true "Project ID" @Param label body models.LinkSharing true "The new link share object" @Success 201 {object} models.LinkSharing "The created link share object." @Failure 400 {object} web.HTTPError "Invalid link share object provided." @Failure 403 {object} web.HTTPError "Not allowed to add the project share." @Failure 404 {object} web.HTTPError "The project does not exist." @Failure 500 {object} models.Message "Internal error" @Router /projects/{project}/shares [put]
func (*LinkSharing) Delete ¶
Delete removes a link share @Summary Remove a link share @Description Remove a link share. The user needs to have write-access to the project to be able do this. @tags sharing @Accept json @Produce json @Security JWTKeyAuth @Param project path int true "Project ID" @Param share path int true "Share Link ID" @Success 200 {object} models.Message "The link was successfully removed." @Failure 403 {object} web.HTTPError "Not allowed to remove the link." @Failure 404 {object} web.HTTPError "Share Link not found." @Failure 500 {object} models.Message "Internal error" @Router /projects/{project}/shares/{share} [delete]
func (*LinkSharing) GetID ¶
func (share *LinkSharing) GetID() int64
GetID returns the ID of the links sharing object
func (*LinkSharing) ReadAll ¶
func (share *LinkSharing) ReadAll(s *xorm.Session, a web.Auth, search string, page int, perPage int) (result interface{}, resultCount int, totalItems int64, err error)
ReadAll returns all shares for a given project @Summary Get all link shares for a project @Description Returns all link shares which exist for a given project @tags sharing @Accept json @Produce json @Param project path int true "Project ID" @Param page query int false "The page number. Used for pagination. If not provided, the first page of results is returned." @Param per_page query int false "The maximum number of items per page. Note this parameter is limited by the configured maximum of items per page." @Param s query string false "Search shares by hash." @Security JWTKeyAuth @Success 200 {array} models.LinkSharing "The share links" @Failure 500 {object} models.Message "Internal error" @Router /projects/{project}/shares [get]
func (*LinkSharing) ReadOne ¶
ReadOne returns one share @Summary Get one link shares for a project @Description Returns one link share by its ID. @tags sharing @Accept json @Produce json @Param project path int true "Project ID" @Param share path int true "Share ID" @Security JWTKeyAuth @Success 200 {object} models.LinkSharing "The share links" @Failure 403 {object} web.HTTPError "No access to the project" @Failure 404 {object} web.HTTPError "Share Link not found." @Failure 500 {object} models.Message "Internal error" @Router /projects/{project}/shares/{share} [get]
type Message ¶
type Message struct { // A standard message. Message string `json:"message"` }
Message is a standard message
type OIDCTeam ¶ added in v0.24.0
OIDCTeam is the relevant data for a team and is delivered by oidc token
type Project ¶ added in v0.21.0
type Project struct { // The unique, numeric id of this project. ID int64 `xorm:"bigint autoincr not null unique pk" json:"id" param:"project"` // The title of the project. You'll see this in the overview. Title string `xorm:"varchar(250) not null" json:"title" valid:"required,runelength(1|250)" minLength:"1" maxLength:"250"` // The description of the project. Description string `xorm:"longtext null" json:"description"` // The unique project short identifier. Used to build task identifiers. Identifier string `xorm:"varchar(10) null" json:"identifier" valid:"runelength(0|10)" minLength:"0" maxLength:"10"` // The hex color of this project HexColor string `xorm:"varchar(6) null" json:"hex_color" valid:"runelength(0|7)" maxLength:"7"` OwnerID int64 `xorm:"bigint INDEX not null" json:"-"` ParentProjectID int64 `xorm:"bigint INDEX null" json:"parent_project_id"` ParentProject *Project `xorm:"-" json:"-"` // The user who created this project. Owner *user.User `xorm:"-" json:"owner" valid:"-"` // Whether a project is archived. IsArchived bool `xorm:"not null default false" json:"is_archived" query:"is_archived"` // The id of the file this project has set as background BackgroundFileID int64 `xorm:"null" json:"-"` // Holds extra information about the background set since some background providers require attribution or similar. If not null, the background can be accessed at /projects/{projectID}/background BackgroundInformation interface{} `xorm:"-" json:"background_information"` // Contains a very small version of the project background to use as a blurry preview until the actual background is loaded. Check out https://blurha.sh/ to learn how it works. BackgroundBlurHash string `xorm:"varchar(50) null" json:"background_blur_hash"` // True if a project is a favorite. Favorite projects show up in a separate parent project. This value depends on the user making the call to the api. IsFavorite bool `xorm:"-" json:"is_favorite"` // The subscription status for the user reading this project. You can only read this property, use the subscription endpoints to modify it. // Will only returned when retreiving one project. Subscription *Subscription `xorm:"-" json:"subscription,omitempty"` // The position this project has when querying all projects. See the tasks.position property on how to use this. Position float64 `xorm:"double null" json:"position"` Views []*ProjectView `xorm:"-" json:"views"` // A timestamp when this project was created. You cannot change this value. Created time.Time `xorm:"created not null" json:"created"` // A timestamp when this project was last updated. You cannot change this value. Updated time.Time `xorm:"updated not null" json:"updated"` web.CRUDable `xorm:"-" json:"-"` web.Rights `xorm:"-" json:"-"` }
Project represents a project of tasks
func GetProjectByShareHash ¶ added in v0.21.0
GetProjectByShareHash returns a link share by its hash
func GetProjectSimplByTaskID ¶ added in v0.21.0
GetProjectSimplByTaskID gets a project by a task id
func GetProjectSimpleByID ¶ added in v0.21.0
GetProjectSimpleByID gets a project with only the basic items, aka no tasks or user objects. Returns an error if the project does not exist.
func GetProjectsByIDs ¶ added in v0.21.0
func GetProjectsSimplByTaskIDs ¶ added in v0.22.0
func (*Project) CanWrite ¶ added in v0.21.0
CanWrite return whether the user can write on that project or not
func (*Project) CheckIsArchived ¶ added in v0.21.0
CheckIsArchived returns an ErrProjectIsArchived if the project or any of its parent projects is archived.
func (*Project) Create ¶ added in v0.21.0
Create implements the create method of CRUDable @Summary Creates a new project @Description Creates a new project. If a parent project is provided the user needs to have write access to that project. @tags project @Accept json @Produce json @Security JWTKeyAuth @Param project body models.Project true "The project you want to create." @Success 201 {object} models.Project "The created project." @Failure 400 {object} web.HTTPError "Invalid project object provided." @Failure 403 {object} web.HTTPError "The user does not have access to the project" @Failure 500 {object} models.Message "Internal error" @Router /projects [put]
func (*Project) Delete ¶ added in v0.21.0
Delete implements the delete method of CRUDable @Summary Deletes a project @Description Delets a project @tags project @Produce json @Security JWTKeyAuth @Param id path int true "Project ID" @Success 200 {object} models.Message "The project was successfully deleted." @Failure 400 {object} web.HTTPError "Invalid project object provided." @Failure 403 {object} web.HTTPError "The user does not have access to the project" @Failure 500 {object} models.Message "Internal error" @Router /projects/{id} [delete]
func (*Project) DeleteBackgroundFileIfExists ¶ added in v0.21.0
DeleteBackgroundFileIfExists deletes the list's background file from the db and the filesystem, if one exists
func (*Project) IsAdmin ¶ added in v0.21.0
IsAdmin returns whether the user has admin rights on the project or not
func (*Project) ReadAll ¶ added in v0.21.0
func (p *Project) ReadAll(s *xorm.Session, a web.Auth, search string, page int, perPage int) (result interface{}, resultCount int, totalItems int64, err error)
ReadAll gets all projects a user has access to @Summary Get all projects a user has access to @Description Returns all projects a user has access to. @tags project @Accept json @Produce json @Param page query int false "The page number. Used for pagination. If not provided, the first page of results is returned." @Param per_page query int false "The maximum number of items per page. Note this parameter is limited by the configured maximum of items per page." @Param s query string false "Search projects by title." @Param is_archived query bool false "If true, also returns all archived projects." @Security JWTKeyAuth @Success 200 {array} models.Project "The projects" @Failure 403 {object} web.HTTPError "The user does not have access to the project" @Failure 500 {object} models.Message "Internal error" @Router /projects [get]
func (*Project) ReadOne ¶ added in v0.21.0
ReadOne gets one project by its ID @Summary Gets one project @Description Returns a project by its ID. @tags project @Accept json @Produce json @Security JWTKeyAuth @Param id path int true "Project ID" @Success 200 {object} models.Project "The project" @Failure 403 {object} web.HTTPError "The user does not have access to the project" @Failure 500 {object} models.Message "Internal error" @Router /projects/{id} [get]
func (*Project) Update ¶ added in v0.21.0
Update implements the update method of CRUDable @Summary Updates a project @Description Updates a project. This does not include adding a task (see below). @tags project @Accept json @Produce json @Security JWTKeyAuth @Param id path int true "Project ID" @Param project body models.Project true "The project with updated values you want to update." @Success 200 {object} models.Project "The updated project." @Failure 400 {object} web.HTTPError "Invalid project object provided." @Failure 403 {object} web.HTTPError "The user does not have access to the project" @Failure 500 {object} models.Message "Internal error" @Router /projects/{id} [post]
type ProjectBackgroundType ¶ added in v0.21.0
type ProjectBackgroundType struct {
Type string
}
ProjectBackgroundType holds a project background type
type ProjectCreatedEvent ¶ added in v0.21.0
ProjectCreatedEvent represents an event where a project has been created
func (*ProjectCreatedEvent) Name ¶ added in v0.21.0
func (l *ProjectCreatedEvent) Name() string
Name defines the name for ProjectCreatedEvent
type ProjectCreatedNotification ¶ added in v0.21.0
type ProjectCreatedNotification struct { Doer *user.User `json:"doer"` Project *Project `json:"project"` }
ProjectCreatedNotification represents a ProjectCreatedNotification notification
func (*ProjectCreatedNotification) Name ¶ added in v0.21.0
func (n *ProjectCreatedNotification) Name() string
Name returns the name of the notification
func (*ProjectCreatedNotification) ToDB ¶ added in v0.21.0
func (n *ProjectCreatedNotification) ToDB() interface{}
ToDB returns the ProjectCreatedNotification notification in a format which can be saved in the db
func (*ProjectCreatedNotification) ToMail ¶ added in v0.21.0
func (n *ProjectCreatedNotification) ToMail() *notifications.Mail
ToMail returns the mail notification for ProjectCreatedNotification
type ProjectDeletedEvent ¶ added in v0.21.0
ProjectDeletedEvent represents an event where a project has been deleted
func (*ProjectDeletedEvent) Name ¶ added in v0.21.0
func (p *ProjectDeletedEvent) Name() string
Name defines the name for ProjectDeletedEvent
type ProjectDuplicate ¶ added in v0.21.0
type ProjectDuplicate struct { // The project id of the project to duplicate ProjectID int64 `json:"-" param:"projectid"` // The target parent project ParentProjectID int64 `json:"parent_project_id,omitempty"` // The copied project Project *Project `json:"duplicated_project,omitempty"` web.Rights `json:"-"` web.CRUDable `json:"-"` }
ProjectDuplicate holds everything needed to duplicate a project
func (*ProjectDuplicate) CanCreate ¶ added in v0.21.0
CanCreate checks if a user has the right to duplicate a project
func (*ProjectDuplicate) Create ¶ added in v0.21.0
Create duplicates a project @Summary Duplicate an existing project @Description Copies the project, tasks, files, kanban data, assignees, comments, attachments, lables, relations, backgrounds, user/team rights and link shares from one project to a new one. The user needs read access in the project and write access in the parent of the new project. @tags project @Accept json @Produce json @Security JWTKeyAuth @Param projectID path int true "The project ID to duplicate" @Param project body models.ProjectDuplicate true "The target parent project which should hold the copied project." @Success 201 {object} models.ProjectDuplicate "The created project." @Failure 400 {object} web.HTTPError "Invalid project duplicate object provided." @Failure 403 {object} web.HTTPError "The user does not have access to the project or its parent." @Failure 500 {object} models.Message "Internal error" @Router /projects/{projectID}/duplicate [put]
type ProjectSharedWithTeamEvent ¶ added in v0.21.0
type ProjectSharedWithTeamEvent struct {}
ProjectSharedWithTeamEvent represents an event where a project has been shared with a team
func (*ProjectSharedWithTeamEvent) Name ¶ added in v0.21.0
func (p *ProjectSharedWithTeamEvent) Name() string
Name defines the name for ProjectSharedWithTeamEvent
type ProjectSharedWithUserEvent ¶ added in v0.21.0
type ProjectSharedWithUserEvent struct {}
ProjectSharedWithUserEvent represents an event where a project has been shared with a user
func (*ProjectSharedWithUserEvent) Name ¶ added in v0.21.0
func (p *ProjectSharedWithUserEvent) Name() string
Name defines the name for ProjectSharedWithUserEvent
type ProjectUIDs ¶ added in v0.21.0
type ProjectUIDs struct { ProjectOwnerID int64 `xorm:"projectOwner"` ProjectUserID int64 `xorm:"ulID"` TeamProjectUserID int64 `xorm:"tlUID"` }
ProjectUIDs hold all kinds of user IDs from accounts who have access to a project
type ProjectUpdatedEvent ¶ added in v0.21.0
ProjectUpdatedEvent represents an event where a project has been updated
func (*ProjectUpdatedEvent) Name ¶ added in v0.21.0
func (p *ProjectUpdatedEvent) Name() string
Name defines the name for ProjectUpdatedEvent
type ProjectUser ¶ added in v0.21.0
type ProjectUser struct { // The unique, numeric id of this project <-> user relation. ID int64 `xorm:"bigint autoincr not null unique pk" json:"id"` // The username. Username string `xorm:"-" json:"user_id" param:"user"` // Used internally to reference the user UserID int64 `xorm:"bigint not null INDEX" json:"-"` // The project id. ProjectID int64 `xorm:"bigint not null INDEX" json:"-" param:"project"` // The right this user has. 0 = Read only, 1 = Read & Write, 2 = Admin. See the docs for more details. Right Right `xorm:"bigint INDEX not null default 0" json:"right" valid:"length(0|2)" maximum:"2" default:"0"` // A timestamp when this relation was created. You cannot change this value. Created time.Time `xorm:"created not null" json:"created"` // A timestamp when this relation was last updated. You cannot change this value. Updated time.Time `xorm:"updated not null" json:"updated"` web.CRUDable `xorm:"-" json:"-"` web.Rights `xorm:"-" json:"-"` }
ProjectUser represents a project <-> user relation
func (*ProjectUser) CanCreate ¶ added in v0.21.0
CanCreate checks if the user can create a new user <-> project relation
func (*ProjectUser) CanDelete ¶ added in v0.21.0
CanDelete checks if the user can delete a user <-> project relation
func (*ProjectUser) CanUpdate ¶ added in v0.21.0
CanUpdate checks if the user can update a user <-> project relation
func (*ProjectUser) Create ¶ added in v0.21.0
Create creates a new project <-> user relation @Summary Add a user to a project @Description Gives a user access to a project. @tags sharing @Accept json @Produce json @Security JWTKeyAuth @Param id path int true "Project ID" @Param project body models.ProjectUser true "The user you want to add to the project." @Success 201 {object} models.ProjectUser "The created user<->project relation." @Failure 400 {object} web.HTTPError "Invalid user project object provided." @Failure 404 {object} web.HTTPError "The user does not exist." @Failure 403 {object} web.HTTPError "The user does not have access to the project" @Failure 500 {object} models.Message "Internal error" @Router /projects/{id}/users [put]
func (*ProjectUser) Delete ¶ added in v0.21.0
Delete deletes a project <-> user relation @Summary Delete a user from a project @Description Delets a user from a project. The user won't have access to the project anymore. @tags sharing @Produce json @Security JWTKeyAuth @Param projectID path int true "Project ID" @Param userID path int true "User ID" @Success 200 {object} models.Message "The user was successfully removed from the project." @Failure 403 {object} web.HTTPError "The user does not have access to the project" @Failure 404 {object} web.HTTPError "user or project does not exist." @Failure 500 {object} models.Message "Internal error" @Router /projects/{projectID}/users/{userID} [delete]
func (*ProjectUser) ReadAll ¶ added in v0.21.0
func (lu *ProjectUser) ReadAll(s *xorm.Session, a web.Auth, search string, page int, perPage int) (result interface{}, resultCount int, numberOfTotalItems int64, err error)
ReadAll gets all users who have access to a project @Summary Get users on a project @Description Returns a project with all users which have access on a given project. @tags sharing @Accept json @Produce json @Param id path int true "Project ID" @Param page query int false "The page number. Used for pagination. If not provided, the first page of results is returned." @Param per_page query int false "The maximum number of items per page. Note this parameter is limited by the configured maximum of items per page." @Param s query string false "Search users by its name." @Security JWTKeyAuth @Success 200 {array} models.UserWithRight "The users with the right they have." @Failure 403 {object} web.HTTPError "No right to see the project." @Failure 500 {object} models.Message "Internal error" @Router /projects/{id}/users [get]
func (ProjectUser) TableName ¶ added in v0.21.0
func (ProjectUser) TableName() string
TableName is the table name for ProjectUser
func (*ProjectUser) Update ¶ added in v0.21.0
Update updates a user <-> project relation @Summary Update a user <-> project relation @Description Update a user <-> project relation. Mostly used to update the right that user has. @tags sharing @Accept json @Produce json @Param projectID path int true "Project ID" @Param userID path int true "User ID" @Param project body models.ProjectUser true "The user you want to update." @Security JWTKeyAuth @Success 200 {object} models.ProjectUser "The updated user <-> project relation." @Failure 403 {object} web.HTTPError "The user does not have admin-access to the project" @Failure 404 {object} web.HTTPError "User or project does not exist." @Failure 500 {object} models.Message "Internal error" @Router /projects/{projectID}/users/{userID} [post]
type ProjectView ¶ added in v0.24.0
type ProjectView struct { // The unique numeric id of this view ID int64 `xorm:"autoincr not null unique pk" json:"id" param:"view"` // The title of this view Title string `xorm:"varchar(255) not null" json:"title" valid:"required,runelength(1|250)"` // The project this view belongs to ProjectID int64 `xorm:"not null index" json:"project_id" param:"project"` // The kind of this view. Can be `list`, `gantt`, `table` or `kanban`. ViewKind ProjectViewKind `xorm:"not null" json:"view_kind"` // The filter query to match tasks by. Check out https://vikunja.io/docs/filters for a full explanation. Filter string `xorm:"text null default null" query:"filter" json:"filter"` // The position of this view in the list. The list of all views will be sorted by this parameter. Position float64 `xorm:"double null" json:"position"` // The bucket configuration mode. Can be `none`, `manual` or `filter`. `manual` allows to move tasks between buckets as you normally would. `filter` creates buckets based on a filter for each bucket. BucketConfigurationMode BucketConfigurationModeKind `xorm:"default 0" json:"bucket_configuration_mode"` // When the bucket configuration mode is not `manual`, this field holds the options of that configuration. BucketConfiguration []*ProjectViewBucketConfiguration `xorm:"json" json:"bucket_configuration"` // The ID of the bucket where new tasks without a bucket are added to. By default, this is the leftmost bucket in a view. DefaultBucketID int64 `xorm:"bigint INDEX null" json:"default_bucket_id"` // If tasks are moved to the done bucket, they are marked as done. If they are marked as done individually, they are moved into the done bucket. DoneBucketID int64 `xorm:"bigint INDEX null" json:"done_bucket_id"` // A timestamp when this view was updated. You cannot change this value. Updated time.Time `xorm:"updated not null" json:"updated"` // A timestamp when this reaction was created. You cannot change this value. Created time.Time `xorm:"created not null" json:"created"` web.CRUDable `xorm:"-" json:"-"` web.Rights `xorm:"-" json:"-"` }
func GetProjectViewByID ¶ added in v0.24.0
func GetProjectViewByID(s *xorm.Session, id int64) (view *ProjectView, err error)
func GetProjectViewByIDAndProject ¶ added in v0.24.0
func GetProjectViewByIDAndProject(s *xorm.Session, viewID, projectID int64) (view *ProjectView, err error)
func (*ProjectView) Create ¶ added in v0.24.0
Create adds a new project view @Summary Create a project view @Description Create a project view in a specific project. @tags project @Accept json @Produce json @Security JWTKeyAuth @Param project path int true "Project ID" @Param view body models.ProjectView true "The project view you want to create." @Success 200 {object} models.ProjectView "The created project view" @Failure 403 {object} web.HTTPError "The user does not have access to create a project view" @Failure 500 {object} models.Message "Internal error" @Router /projects/{project}/views [put]
func (*ProjectView) Delete ¶ added in v0.24.0
Delete removes the project view @Summary Delete a project view @Description Deletes a project view. @tags project @Accept json @Produce json @Security JWTKeyAuth @Param project path int true "Project ID" @Param id path int true "Project View ID" @Success 200 {object} models.Message "The project view was successfully deleted." @Failure 403 {object} web.HTTPError "The user does not have access to the project view" @Failure 500 {object} models.Message "Internal error" @Router /projects/{project}/views/{id} [delete]
func (*ProjectView) ReadAll ¶ added in v0.24.0
func (pv *ProjectView) ReadAll(s *xorm.Session, a web.Auth, _ string, _ int, _ int) (result interface{}, resultCount int, numberOfTotalItems int64, err error)
ReadAll gets all project views @Summary Get all project views for a project @Description Returns all project views for a sepcific project @tags project @Accept json @Produce json @Security JWTKeyAuth @Param project path int true "Project ID" @Success 200 {array} models.ProjectView "The project views" @Failure 500 {object} models.Message "Internal error" @Router /projects/{project}/views [get]
func (*ProjectView) ReadOne ¶ added in v0.24.0
ReadOne implements the CRUD method to get one project view @Summary Get one project view @Description Returns a project view by its ID. @tags project @Accept json @Produce json @Security JWTKeyAuth @Param project path int true "Project ID" @Param id path int true "Project View ID" @Success 200 {object} models.ProjectView "The project view" @Failure 403 {object} web.HTTPError "The user does not have access to this project view" @Failure 500 {object} models.Message "Internal error" @Router /projects/{project}/views/{id} [get]
func (*ProjectView) TableName ¶ added in v0.24.0
func (pv *ProjectView) TableName() string
func (*ProjectView) Update ¶ added in v0.24.0
Update is the handler to update a project view @Summary Updates a project view @Description Updates a project view. @tags project @Accept json @Produce json @Security JWTKeyAuth @Param project path int true "Project ID" @Param id path int true "Project View ID" @Param view body models.ProjectView true "The project view with updated values you want to change." @Success 200 {object} models.ProjectView "The updated project view." @Failure 400 {object} web.HTTPError "Invalid project view object provided." @Failure 500 {object} models.Message "Internal error" @Router /projects/{project}/views/{id} [post]
type ProjectViewBucketConfiguration ¶ added in v0.24.0
type ProjectViewKind ¶ added in v0.24.0
type ProjectViewKind int
const ( ProjectViewKindList ProjectViewKind = iota ProjectViewKindGantt ProjectViewKindTable ProjectViewKindKanban )
func (*ProjectViewKind) MarshalJSON ¶ added in v0.24.0
func (p *ProjectViewKind) MarshalJSON() ([]byte, error)
func (*ProjectViewKind) UnmarshalJSON ¶ added in v0.24.0
func (p *ProjectViewKind) UnmarshalJSON(bytes []byte) error
type ProjectWithTasksAndBuckets ¶ added in v0.21.0
type ProjectWithTasksAndBuckets struct { Project ChildProjects []*ProjectWithTasksAndBuckets `xorm:"-" json:"child_projects"` // An array of tasks which belong to the project. Tasks []*TaskWithComments `xorm:"-" json:"tasks"` // Only used for migration. Buckets []*Bucket `xorm:"-" json:"buckets"` TaskBuckets []*TaskBucket `xorm:"-" json:"task_buckets"` Positions []*TaskPosition `xorm:"-" json:"positions"` BackgroundFileID int64 `xorm:"null" json:"background_file_id"` }
type Reaction ¶ added in v0.24.0
type Reaction struct { // The unique numeric id of this reaction ID int64 `xorm:"autoincr not null unique pk" json:"-" param:"reaction"` // The user who reacted User *user.User `xorm:"-" json:"user" valid:"-"` UserID int64 `xorm:"bigint not null INDEX" json:"-"` // The id of the entity you're reacting to EntityID int64 `xorm:"bigint not null INDEX" json:"-" param:"entityid"` // The entity kind which you're reacting to. Can be 0 for task, 1 for comment. EntityKind ReactionKind `xorm:"bigint not null INDEX" json:"-"` EntityKindString string `xorm:"-" json:"-" param:"entitykind"` // The actual reaction. This can be any valid utf character or text, up to a length of 20. Value string `xorm:"varchar(20) not null INDEX" json:"value" valid:"required"` // A timestamp when this reaction was created. You cannot change this value. Created time.Time `xorm:"created not null" json:"created"` web.CRUDable `xorm:"-" json:"-"` web.Rights `xorm:"-" json:"-"` }
func (*Reaction) Create ¶ added in v0.24.0
Create adds a new reaction to an entity @Summary Add a reaction to an entity @Description Add a reaction to an entity. Will do nothing if the reaction already exists. @tags task @Accept json @Produce json @Security JWTKeyAuth @Param id path int true "Entity ID" @Param kind path int true "The kind of the entity. Can be either `tasks` or `comments` for task comments" @Param project body models.Reaction true "The reaction you want to add to the entity." @Success 200 {object} models.Reaction "The created reaction" @Failure 403 {object} web.HTTPError "The user does not have access to the entity" @Failure 500 {object} models.Message "Internal error" @Router /{kind}/{id}/reactions [put]
func (*Reaction) Delete ¶ added in v0.24.0
Delete removes the user's own reaction @Summary Removes the user's reaction @Description Removes the reaction of that user on that entity. @tags task @Accept json @Produce json @Security JWTKeyAuth @Param id path int true "Entity ID" @Param kind path int true "The kind of the entity. Can be either `tasks` or `comments` for task comments" @Param project body models.Reaction true "The reaction you want to add to the entity." @Success 200 {object} models.Message "The reaction was successfully removed." @Failure 403 {object} web.HTTPError "The user does not have access to the entity" @Failure 500 {object} models.Message "Internal error" @Router /{kind}/{id}/reactions/delete [post]
func (*Reaction) ReadAll ¶ added in v0.24.0
func (r *Reaction) ReadAll(s *xorm.Session, a web.Auth, _ string, _ int, _ int) (result interface{}, resultCount int, numberOfTotalItems int64, err error)
ReadAll gets all reactions for an entity @Summary Get all reactions for an entity @Description Returns all reactions for an entity @tags task @Accept json @Produce json @Security JWTKeyAuth @Param id path int true "Entity ID" @Param kind path int true "The kind of the entity. Can be either `tasks` or `comments` for task comments" @Success 200 {array} models.ReactionMap "The reactions" @Failure 403 {object} web.HTTPError "The user does not have access to the entity" @Failure 500 {object} models.Message "Internal error" @Router /{kind}/{id}/reactions [get]
type ReactionKind ¶ added in v0.24.0
type ReactionKind int
type ReactionMap ¶ added in v0.24.0
type RelatedTaskMap ¶
type RelatedTaskMap map[RelationKind][]*Task
RelatedTaskMap holds all relations of a single task, grouped by relation kind. This avoids the need for an extra type TaskWithRelation (or similar).
type RelationKind ¶
type RelationKind string
RelationKind represents a kind of relation between to tasks
const ( RelationKindUnknown RelationKind = `unknown` RelationKindSubtask RelationKind = `subtask` RelationKindParenttask RelationKind = `parenttask` RelationKindRelated RelationKind = `related` RelationKindDuplicateOf RelationKind = `duplicateof` RelationKindDuplicates RelationKind = `duplicates` RelationKindBlocking RelationKind = `blocking` RelationKindBlocked RelationKind = `blocked` RelationKindPreceeds RelationKind = `precedes` RelationKindFollows RelationKind = `follows` RelationKindCopiedFrom RelationKind = `copiedfrom` RelationKindCopiedTo RelationKind = `copiedto` )
All valid relation kinds
type ReminderDueNotification ¶ added in v0.17.0
type ReminderDueNotification struct { User *user.User `json:"user,omitempty"` Task *Task `json:"task"` Project *Project `json:"project"` }
ReminderDueNotification represents a ReminderDueNotification notification
func (*ReminderDueNotification) Name ¶ added in v0.17.0
func (n *ReminderDueNotification) Name() string
Name returns the name of the notification
func (*ReminderDueNotification) ToDB ¶ added in v0.17.0
func (n *ReminderDueNotification) ToDB() interface{}
ToDB returns the ReminderDueNotification notification in a format which can be saved in the db
func (*ReminderDueNotification) ToMail ¶ added in v0.17.0
func (n *ReminderDueNotification) ToMail() *notifications.Mail
ToMail returns the mail notification for ReminderDueNotification
type ReminderRelation ¶ added in v0.21.0
type ReminderRelation string
ReminderRelation represents the date attribute of the task which a period based reminder relates to
const ( ReminderRelationDueDate ReminderRelation = `due_date` ReminderRelationStartDate ReminderRelation = `start_date` ReminderRelationEndDate ReminderRelation = `end_date` )
All valid ReminderRelations
type RemoveTaskFromTypesense ¶ added in v0.22.0
type RemoveTaskFromTypesense struct { }
RemoveTaskFromTypesense represents a listener
func (*RemoveTaskFromTypesense) Handle ¶ added in v0.22.0
func (s *RemoveTaskFromTypesense) Handle(msg *message.Message) (err error)
Handle is executed when the event RemoveTaskFromTypesense listens on is fired
func (*RemoveTaskFromTypesense) Name ¶ added in v0.22.0
func (s *RemoveTaskFromTypesense) Name() string
Name defines the name for the RemoveTaskFromTypesense listener
type RouteDetail ¶ added in v0.22.0
type SavedFilter ¶ added in v0.15.0
type SavedFilter struct { // The unique numeric id of this saved filter ID int64 `xorm:"autoincr not null unique pk" json:"id" param:"filter"` // The actual filters this filter contains Filters *TaskCollection `xorm:"JSON not null" json:"filters" valid:"required"` // The title of the filter. Title string `xorm:"varchar(250) not null" json:"title" valid:"required,runelength(1|250)" minLength:"1" maxLength:"250"` // The description of the filter Description string `xorm:"longtext null" json:"description"` OwnerID int64 `xorm:"bigint not null INDEX" json:"-"` // The user who owns this filter Owner *user.User `xorm:"-" json:"owner" valid:"-"` // True if the filter is a favorite. Favorite filters show up in a separate parent project together with favorite projects. IsFavorite bool `xorm:"default false" json:"is_favorite"` // A timestamp when this filter was created. You cannot change this value. Created time.Time `xorm:"created not null" json:"created"` // A timestamp when this filter was last updated. You cannot change this value. Updated time.Time `xorm:"updated not null" json:"updated"` web.CRUDable `xorm:"-" json:"-"` web.Rights `xorm:"-" json:"-"` }
SavedFilter represents a saved bunch of filters
func (*SavedFilter) CanCreate ¶ added in v0.15.0
CanCreate checks if a user has the right to update a saved filter
func (*SavedFilter) CanDelete ¶ added in v0.15.0
CanDelete checks if a user has the right to delete a saved filter
func (*SavedFilter) CanRead ¶ added in v0.15.0
CanRead checks if a user has the right to read a saved filter
func (*SavedFilter) CanUpdate ¶ added in v0.15.0
CanUpdate checks if a user has the right to update a saved filter
func (*SavedFilter) Create ¶ added in v0.15.0
Create creates a new saved filter @Summary Creates a new saved filter @Description Creates a new saved filter @tags filter @Accept json @Produce json @Security JWTKeyAuth @Success 201 {object} models.SavedFilter "The Saved Filter" @Failure 403 {object} web.HTTPError "The user does not have access to that saved filter." @Failure 500 {object} models.Message "Internal error" @Router /filters [put]
func (*SavedFilter) Delete ¶ added in v0.15.0
Delete removes a saved filter @Summary Removes a saved filter @Description Removes a saved filter by its ID. @tags filter @Accept json @Produce json @Security JWTKeyAuth @Param id path int true "Filter ID" @Success 200 {object} models.SavedFilter "The Saved Filter" @Failure 403 {object} web.HTTPError "The user does not have access to that saved filter." @Failure 404 {object} web.HTTPError "The saved filter does not exist." @Failure 500 {object} models.Message "Internal error" @Router /filters/{id} [delete]
func (*SavedFilter) ReadOne ¶ added in v0.15.0
ReadOne returns one saved filter @Summary Gets one saved filter @Description Returns a saved filter by its ID. @tags filter @Accept json @Produce json @Security JWTKeyAuth @Param id path int true "Filter ID" @Success 200 {object} models.SavedFilter "The Saved Filter" @Failure 403 {object} web.HTTPError "The user does not have access to that saved filter." @Failure 500 {object} models.Message "Internal error" @Router /filters/{id} [get]
func (*SavedFilter) TableName ¶ added in v0.15.0
func (sf *SavedFilter) TableName() string
TableName returns a better table name for saved filters
func (*SavedFilter) Update ¶ added in v0.15.0
Update updates an existing filter @Summary Updates a saved filter @Description Updates a saved filter by its ID. @tags filter @Accept json @Produce json @Security JWTKeyAuth @Param id path int true "Filter ID" @Success 200 {object} models.SavedFilter "The Saved Filter" @Failure 403 {object} web.HTTPError "The user does not have access to that saved filter." @Failure 404 {object} web.HTTPError "The saved filter does not exist." @Failure 500 {object} models.Message "Internal error" @Router /filters/{id} [post]
type SendProjectCreatedNotification ¶ added in v0.21.0
type SendProjectCreatedNotification struct { }
SendProjectCreatedNotification represents a listener
func (*SendProjectCreatedNotification) Handle ¶ added in v0.21.0
func (s *SendProjectCreatedNotification) Handle(msg *message.Message) (err error)
Handle is executed when the event SendProjectCreatedNotification listens on is fired
func (*SendProjectCreatedNotification) Name ¶ added in v0.21.0
func (s *SendProjectCreatedNotification) Name() string
Name defines the name for the SendProjectCreatedNotification listener
type SendTaskAssignedNotification ¶ added in v0.17.0
type SendTaskAssignedNotification struct { }
SendTaskAssignedNotification represents a listener
func (*SendTaskAssignedNotification) Handle ¶ added in v0.17.0
func (s *SendTaskAssignedNotification) Handle(msg *message.Message) (err error)
Handle is executed when the event SendTaskAssignedNotification listens on is fired
func (*SendTaskAssignedNotification) Name ¶ added in v0.17.0
func (s *SendTaskAssignedNotification) Name() string
Name defines the name for the SendTaskAssignedNotification listener
type SendTaskCommentNotification ¶ added in v0.17.0
type SendTaskCommentNotification struct { }
SendTaskCommentNotification represents a listener
func (*SendTaskCommentNotification) Handle ¶ added in v0.17.0
func (s *SendTaskCommentNotification) Handle(msg *message.Message) (err error)
Handle is executed when the event SendTaskCommentNotification listens on is fired
func (*SendTaskCommentNotification) Name ¶ added in v0.17.0
func (s *SendTaskCommentNotification) Name() string
Name defines the name for the SendTaskCommentNotification listener
type SendTaskDeletedNotification ¶ added in v0.17.0
type SendTaskDeletedNotification struct { }
SendTaskDeletedNotification represents a listener
func (*SendTaskDeletedNotification) Handle ¶ added in v0.17.0
func (s *SendTaskDeletedNotification) Handle(msg *message.Message) (err error)
Handle is executed when the event SendTaskDeletedNotification listens on is fired
func (*SendTaskDeletedNotification) Name ¶ added in v0.17.0
func (s *SendTaskDeletedNotification) Name() string
Name defines the name for the SendTaskDeletedNotification listener
type SendTeamMemberAddedNotification ¶ added in v0.17.0
type SendTeamMemberAddedNotification struct { }
SendTeamMemberAddedNotification represents a listener
func (*SendTeamMemberAddedNotification) Handle ¶ added in v0.17.0
func (s *SendTeamMemberAddedNotification) Handle(msg *message.Message) (err error)
Handle is executed when the event SendTeamMemberAddedNotification listens on is fired
func (*SendTeamMemberAddedNotification) Name ¶ added in v0.17.0
func (s *SendTeamMemberAddedNotification) Name() string
Name defines the name for the SendTeamMemberAddedNotification listener
type SharingType ¶
type SharingType int
SharingType holds the sharing type
const ( SharingTypeUnknown SharingType = iota SharingTypeWithoutPassword SharingTypeWithPassword )
These consts represent all valid link sharing types
type Subscription ¶ added in v0.17.0
type Subscription struct { // The numeric ID of the subscription ID int64 `xorm:"autoincr not null unique pk" json:"id"` EntityType SubscriptionEntityType `xorm:"index not null" json:"entity"` Entity string `xorm:"-" json:"-" param:"entity"` // The id of the entity to subscribe to. EntityID int64 `xorm:"bigint index not null" json:"entity_id" param:"entityID"` // The user who made this subscription UserID int64 `xorm:"bigint index not null" json:"-"` // A timestamp when this subscription was created. You cannot change this value. Created time.Time `xorm:"created not null" json:"created"` web.CRUDable `xorm:"-" json:"-"` web.Rights `xorm:"-" json:"-"` }
Subscription represents a subscription for an entity
func (*Subscription) CanCreate ¶ added in v0.17.0
CanCreate checks if a user can subscribe to an entity
func (*Subscription) CanDelete ¶ added in v0.17.0
CanDelete checks if a user can delete a subscription
func (*Subscription) Create ¶ added in v0.17.0
Create subscribes the current user to an entity @Summary Subscribes the current user to an entity. @Description Subscribes the current user to an entity. @tags subscriptions @Accept json @Produce json @Security JWTKeyAuth @Param entity path string true "The entity the user subscribes to. Can be either `project` or `task`." @Param entityID path string true "The numeric id of the entity to subscribe to." @Success 201 {object} models.Subscription "The subscription" @Failure 403 {object} web.HTTPError "The user does not have access to subscribe to this entity." @Failure 412 {object} web.HTTPError "The subscription already exists." @Failure 412 {object} web.HTTPError "The subscription entity is invalid." @Failure 500 {object} models.Message "Internal error" @Router /subscriptions/{entity}/{entityID} [put]
func (*Subscription) Delete ¶ added in v0.17.0
Delete unsubscribes the current user to an entity @Summary Unsubscribe the current user from an entity. @Description Unsubscribes the current user to an entity. @tags subscriptions @Accept json @Produce json @Security JWTKeyAuth @Param entity path string true "The entity the user subscribed to. Can be either `project` or `task`." @Param entityID path string true "The numeric id of the subscribed entity to." @Success 200 {object} models.Subscription "The subscription" @Failure 403 {object} web.HTTPError "The user does not have access to subscribe to this entity." @Failure 404 {object} web.HTTPError "The subscription does not exist." @Failure 500 {object} models.Message "Internal error" @Router /subscriptions/{entity}/{entityID} [delete]
func (*Subscription) TableName ¶ added in v0.17.0
func (sb *Subscription) TableName() string
TableName gives us a better table name for the subscriptions table
type SubscriptionEntityType ¶ added in v0.17.0
type SubscriptionEntityType int
SubscriptionEntityType represents all entities which can be subscribed to
func (SubscriptionEntityType) MarshalJSON ¶ added in v0.24.3
func (st SubscriptionEntityType) MarshalJSON() ([]byte, error)
func (*SubscriptionEntityType) UnmarshalJSON ¶ added in v0.24.3
func (st *SubscriptionEntityType) UnmarshalJSON(bytes []byte) error
type SubscriptionWithUser ¶ added in v0.24.3
type SubscriptionWithUser struct { Subscription `xorm:"extends"` User *user.User `xorm:"extends" json:"user"` }
func GetSubscriptionForUser ¶ added in v0.24.3
func GetSubscriptionForUser(s *xorm.Session, entityType SubscriptionEntityType, entityID int64, a web.Auth) (subscription *SubscriptionWithUser, err error)
func GetSubscriptionsForEntity ¶ added in v0.24.3
func GetSubscriptionsForEntity(s *xorm.Session, entityType SubscriptionEntityType, entityID int64) (subscriptions []*SubscriptionWithUser, err error)
type Task ¶
type Task struct { // The unique, numeric id of this task. ID int64 `xorm:"bigint autoincr not null unique pk" json:"id" param:"projecttask"` // The task text. This is what you'll see in the project. Title string `xorm:"TEXT not null" json:"title" valid:"minstringlength(1)" minLength:"1"` // The task description. Description string `xorm:"longtext null" json:"description"` // Whether a task is done or not. Done bool `xorm:"INDEX null" json:"done"` // The time when a task was marked as done. DoneAt time.Time `xorm:"INDEX null 'done_at'" json:"done_at"` // The time when the task is due. DueDate time.Time `xorm:"DATETIME INDEX null 'due_date'" json:"due_date"` // An array of reminders that are associated with this task. Reminders []*TaskReminder `xorm:"-" json:"reminders"` // The project this task belongs to. ProjectID int64 `xorm:"bigint INDEX not null" json:"project_id" param:"project"` // An amount in seconds this task repeats itself. If this is set, when marking the task as done, it will mark itself as "undone" and then increase all remindes and the due date by its amount. RepeatAfter int64 `xorm:"bigint INDEX null" json:"repeat_after" valid:"range(0|9223372036854775807)"` // Can have three possible values which will trigger when the task is marked as done: 0 = repeats after the amount specified in repeat_after, 1 = repeats all dates each months (ignoring repeat_after), 3 = repeats from the current date rather than the last set date. RepeatMode TaskRepeatMode `xorm:"not null default 0" json:"repeat_mode"` // The task priority. Can be anything you want, it is possible to sort by this later. Priority int64 `xorm:"bigint null" json:"priority"` // When this task starts. StartDate time.Time `xorm:"DATETIME INDEX null 'start_date'" json:"start_date" query:"-"` // When this task ends. EndDate time.Time `xorm:"DATETIME INDEX null 'end_date'" json:"end_date" query:"-"` // An array of users who are assigned to this task Assignees []*user.User `xorm:"-" json:"assignees"` // An array of labels which are associated with this task. This property is read-only, you must use the separate endpoint to add labels to a task. Labels []*Label `xorm:"-" json:"labels"` // The task color in hex HexColor string `xorm:"varchar(6) null" json:"hex_color" valid:"runelength(0|7)" maxLength:"7"` // Determines how far a task is left from being done PercentDone float64 `xorm:"DOUBLE null" json:"percent_done"` // The task identifier, based on the project identifier and the task's index Identifier string `xorm:"-" json:"identifier"` // The task index, calculated per project Index int64 `xorm:"bigint not null default 0" json:"index"` // The UID is currently not used for anything other than CalDAV, which is why we don't expose it over json UID string `xorm:"varchar(250) null" json:"-"` // All related tasks, grouped by their relation kind RelatedTasks RelatedTaskMap `xorm:"-" json:"related_tasks"` // All attachments this task has. This property is read-onlym, you must use the separate endpoint to add attachments to a task. Attachments []*TaskAttachment `xorm:"-" json:"attachments"` // If this task has a cover image, the field will return the id of the attachment that is the cover image. CoverImageAttachmentID int64 `xorm:"bigint default 0" json:"cover_image_attachment_id"` // True if a task is a favorite task. Favorite tasks show up in a separate "Important" project. This value depends on the user making the call to the api. IsFavorite bool `xorm:"-" json:"is_favorite"` // The subscription status for the user reading this task. You can only read this property, use the subscription endpoints to modify it. // Will only returned when retrieving one task. Subscription *Subscription `xorm:"-" json:"subscription,omitempty"` // A timestamp when this task was created. You cannot change this value. Created time.Time `xorm:"created not null" json:"created"` // A timestamp when this task was last updated. You cannot change this value. Updated time.Time `xorm:"updated not null" json:"updated"` // The bucket id. Will only be populated when the task is accessed via a view with buckets. // Can be used to move a task between buckets. In that case, the new bucket must be in the same view as the old one. BucketID int64 `xorm:"-" json:"bucket_id"` // The position of the task - any task project can be sorted as usual by this parameter. // When accessing tasks via views with buckets, this is primarily used to sort them based on a range. // Positions are always saved per view. They will automatically be set if you request the tasks through a view // endpoint, otherwise they will always be 0. To update them, take a look at the Task Position endpoint. Position float64 `xorm:"-" json:"position"` // Reactions on that task. Reactions ReactionMap `xorm:"-" json:"reactions"` // The user who initially created the task. CreatedBy *user.User `xorm:"-" json:"created_by" valid:"-"` CreatedByID int64 `xorm:"bigint not null" json:"-"` // ID of the user who put that task on the project web.CRUDable `xorm:"-" json:"-"` web.Rights `xorm:"-" json:"-"` }
Task represents an task in a project
func GetTaskByIDSimple ¶
GetTaskByIDSimple returns a raw task without extra data by the task ID
func GetTaskSimple ¶
GetTaskSimple returns a raw task without extra data
func GetTaskSimpleByUUID ¶ added in v0.22.0
func GetTasksByUIDs ¶
GetTasksByUIDs gets all tasks from a bunch of uids
func GetTasksSimpleByIDs ¶ added in v0.24.0
func (*Task) Create ¶
Create is the implementation to create a project task @Summary Create a task @Description Inserts a task into a project. @tags task @Accept json @Produce json @Security JWTKeyAuth @Param id path int true "Project ID" @Param task body models.Task true "The task object" @Success 201 {object} models.Task "The created task object." @Failure 400 {object} web.HTTPError "Invalid task object provided." @Failure 403 {object} web.HTTPError "The user does not have access to the project" @Failure 500 {object} models.Message "Internal error" @Router /projects/{id}/tasks [put]
func (*Task) Delete ¶
Delete implements the delete method for a task @Summary Delete a task @Description Deletes a task from a project. This does not mean "mark it done". @tags task @Produce json @Security JWTKeyAuth @Param id path int true "Task ID" @Success 200 {object} models.Message "The created task object." @Failure 400 {object} web.HTTPError "Invalid task ID provided." @Failure 403 {object} web.HTTPError "The user does not have access to the project" @Failure 500 {object} models.Message "Internal error" @Router /tasks/{id} [delete]
func (*Task) GetFrontendURL ¶ added in v0.17.0
func (*Task) GetFullIdentifier ¶ added in v0.17.0
GetFullIdentifier returns the task identifier if the task has one and the index prefixed with # otherwise.
func (*Task) ReadAll ¶
func (t *Task) ReadAll(_ *xorm.Session, _ web.Auth, _ string, _ int, _ int) (result interface{}, resultCount int, totalItems int64, err error)
ReadAll is a dummy function to still have that endpoint documented @Summary Get tasks @Description Returns all tasks on any project the user has access to. @tags task @Accept json @Produce json @Param page query int false "The page number. Used for pagination. If not provided, the first page of results is returned." @Param per_page query int false "The maximum number of items per page. Note this parameter is limited by the configured maximum of items per page." @Param s query string false "Search tasks by task text." @Param sort_by query string false "The sorting parameter. You can pass this multiple times to get the tasks ordered by multiple different parametes, along with `order_by`. Possible values to sort by are `id`, `title`, `description`, `done`, `done_at`, `due_date`, `created_by_id`, `project_id`, `repeat_after`, `priority`, `start_date`, `end_date`, `hex_color`, `percent_done`, `uid`, `created`, `updated`. Default is `id`." @Param order_by query string false "The ordering parameter. Possible values to order by are `asc` or `desc`. Default is `asc`." @Param filter query string false "The filter query to match tasks by. Check out https://vikunja.io/docs/filters for a full explanation of the feature." @Param filter_timezone query string false "The time zone which should be used for date match (statements like "now" resolve to different actual times)" @Param filter_include_nulls query string false "If set to true the result will include filtered fields whose value is set to `null`. Available values are `true` or `false`. Defaults to `false`." @Param expand query string false "If set to `subtasks`, Vikunja will fetch only tasks which do not have subtasks and then in a second step, will fetch all of these subtasks. This may result in more tasks than the pagination limit being returned, but all subtasks will be present in the response. You can only set this to `subtasks`." @Security JWTKeyAuth @Success 200 {array} models.Task "The tasks" @Failure 500 {object} models.Message "Internal error" @Router /tasks/all [get]
func (*Task) ReadOne ¶
ReadOne gets one task by its ID @Summary Get one task @Description Returns one task by its ID @tags task @Accept json @Produce json @Param id path int true "The task ID" @Security JWTKeyAuth @Success 200 {object} models.Task "The task" @Failure 404 {object} models.Message "Task not found" @Failure 500 {object} models.Message "Internal error" @Router /tasks/{id} [get]