sqlstore

package
v5.22.0-rc3 Latest Latest
Warning

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

Go to latest
Published: Apr 14, 2020 License: AGPL-3.0, Apache-2.0 Imports: 29 Imported by: 10

Documentation

Index

Constants

View Source
const (
	ALL_CHANNEL_MEMBERS_FOR_USER_CACHE_SIZE = model.SESSION_CACHE_SIZE
	ALL_CHANNEL_MEMBERS_FOR_USER_CACHE_SEC  = 900 // 15 mins

	ALL_CHANNEL_MEMBERS_NOTIFY_PROPS_FOR_CHANNEL_CACHE_SIZE = model.SESSION_CACHE_SIZE
	ALL_CHANNEL_MEMBERS_NOTIFY_PROPS_FOR_CHANNEL_CACHE_SEC  = 1800 // 30 mins

	CHANNEL_CACHE_SEC = 900 // 15 mins
)
View Source
const (
	INDEX_TYPE_FULL_TEXT = "full_text"
	INDEX_TYPE_DEFAULT   = "default"
	DB_PING_ATTEMPTS     = 18
	DB_PING_TIMEOUT_SECS = 10
)
View Source
const (
	EXIT_GENERIC_FAILURE             = 1
	EXIT_CREATE_TABLE                = 100
	EXIT_DB_OPEN                     = 101
	EXIT_PING                        = 102
	EXIT_NO_DRIVER                   = 103
	EXIT_TABLE_EXISTS                = 104
	EXIT_TABLE_EXISTS_MYSQL          = 105
	EXIT_COLUMN_EXISTS               = 106
	EXIT_DOES_COLUMN_EXISTS_POSTGRES = 107
	EXIT_DOES_COLUMN_EXISTS_MYSQL    = 108
	EXIT_DOES_COLUMN_EXISTS_MISSING  = 109
	EXIT_CREATE_COLUMN_POSTGRES      = 110
	EXIT_CREATE_COLUMN_MYSQL         = 111
	EXIT_CREATE_COLUMN_MISSING       = 112
	EXIT_REMOVE_COLUMN               = 113
	EXIT_RENAME_COLUMN               = 114
	EXIT_MAX_COLUMN                  = 115
	EXIT_ALTER_COLUMN                = 116
	EXIT_CREATE_INDEX_POSTGRES       = 117
	EXIT_CREATE_INDEX_MYSQL          = 118
	EXIT_CREATE_INDEX_FULL_MYSQL     = 119
	EXIT_CREATE_INDEX_MISSING        = 120
	EXIT_REMOVE_INDEX_POSTGRES       = 121
	EXIT_REMOVE_INDEX_MYSQL          = 122
	EXIT_REMOVE_INDEX_MISSING        = 123
	EXIT_REMOVE_TABLE                = 134
	EXIT_CREATE_INDEX_SQLITE         = 135
	EXIT_REMOVE_INDEX_SQLITE         = 136
	EXIT_TABLE_EXISTS_SQLITE         = 137
	EXIT_DOES_COLUMN_EXISTS_SQLITE   = 138
	EXIT_ALTER_PRIMARY_KEY           = 139
)
View Source
const (
	CURRENT_SCHEMA_VERSION   = VERSION_5_22_0
	VERSION_5_22_0           = "5.22.0"
	VERSION_5_21_0           = "5.21.0"
	VERSION_5_20_0           = "5.20.0"
	VERSION_5_19_0           = "5.19.0"
	VERSION_5_18_0           = "5.18.0"
	VERSION_5_17_0           = "5.17.0"
	VERSION_5_16_0           = "5.16.0"
	VERSION_5_15_0           = "5.15.0"
	VERSION_5_14_0           = "5.14.0"
	VERSION_5_13_0           = "5.13.0"
	VERSION_5_12_0           = "5.12.0"
	VERSION_5_11_0           = "5.11.0"
	VERSION_5_10_0           = "5.10.0"
	VERSION_5_9_0            = "5.9.0"
	VERSION_5_8_0            = "5.8.0"
	VERSION_5_7_0            = "5.7.0"
	VERSION_5_6_0            = "5.6.0"
	VERSION_5_5_0            = "5.5.0"
	VERSION_5_4_0            = "5.4.0"
	VERSION_5_3_0            = "5.3.0"
	VERSION_5_2_0            = "5.2.0"
	VERSION_5_1_0            = "5.1.0"
	VERSION_5_0_0            = "5.0.0"
	VERSION_4_10_0           = "4.10.0"
	VERSION_4_9_0            = "4.9.0"
	VERSION_4_8_1            = "4.8.1"
	VERSION_4_8_0            = "4.8.0"
	VERSION_4_7_2            = "4.7.2"
	VERSION_4_7_1            = "4.7.1"
	VERSION_4_7_0            = "4.7.0"
	VERSION_4_6_0            = "4.6.0"
	VERSION_4_5_0            = "4.5.0"
	VERSION_4_4_0            = "4.4.0"
	VERSION_4_3_0            = "4.3.0"
	VERSION_4_2_0            = "4.2.0"
	VERSION_4_1_0            = "4.1.0"
	VERSION_4_0_0            = "4.0.0"
	VERSION_3_10_0           = "3.10.0"
	VERSION_3_9_0            = "3.9.0"
	VERSION_3_8_0            = "3.8.0"
	VERSION_3_7_0            = "3.7.0"
	VERSION_3_6_0            = "3.6.0"
	VERSION_3_5_0            = "3.5.0"
	VERSION_3_4_0            = "3.4.0"
	VERSION_3_3_0            = "3.3.0"
	VERSION_3_2_0            = "3.2.0"
	VERSION_3_1_0            = "3.1.0"
	VERSION_3_0_0            = "3.0.0"
	OLDEST_SUPPORTED_VERSION = VERSION_3_0_0
)
View Source
const (
	EXIT_VERSION_SAVE                   = 1003
	EXIT_THEME_MIGRATION                = 1004
	EXIT_TEAM_INVITEID_MIGRATION_FAILED = 1006
)
View Source
const (
	MAX_GROUP_CHANNELS_FOR_PROFILES = 50
)
View Source
const (
	MISSING_STATUS_ERROR = "store.sql_status.get.missing.app_error"
)
View Source
const (
	SESSIONS_CLEANUP_DELAY_MILLISECONDS = 100
)
View Source
const (
	TEAM_MEMBER_EXISTS_ERROR = "store.sql_team.save_member.exists.app_error"
)
View Source
const (
	UPDATE_POST_HAS_REACTIONS_ON_DELETE_QUERY = `` /* 148-byte string literal not displayed */

)

Variables

View Source
var (
	USER_SEARCH_TYPE_NAMES_NO_FULL_NAME = []string{"Username", "Nickname"}
	USER_SEARCH_TYPE_NAMES              = []string{"Username", "FirstName", "LastName", "Nickname"}
	USER_SEARCH_TYPE_ALL_NO_FULL_NAME   = []string{"Username", "Nickname", "Email"}
	USER_SEARCH_TYPE_ALL                = []string{"Username", "FirstName", "LastName", "Nickname", "Email"}
)
View Source
var CHANNEL_MEMBERS_WITH_SCHEME_SELECT_QUERY = `` /* 710-byte string literal not displayed */

Functions

func CheckRelationalIntegrity

func CheckRelationalIntegrity(ss *SqlSupplier, results chan<- store.IntegrityCheckResult)

func IsUniqueConstraintError

func IsUniqueConstraintError(err error, indexName []string) bool

func MapStringsToQueryParams

func MapStringsToQueryParams(list []string, paramPrefix string) (string, map[string]interface{})

Converts a list of strings into a list of query parameters and a named parameter map that can be used as part of a SQL query.

func NewChannelMemberFromModel

func NewChannelMemberFromModel(cm *model.ChannelMember) *channelMember

func NewTeamMemberFromModel

func NewTeamMemberFromModel(tm *model.TeamMember) *teamMember

Types

type JSONSerializable

type JSONSerializable interface {
	ToJson() string
}

type Role

type Role struct {
	Id            string
	Name          string
	DisplayName   string
	Description   string
	CreateAt      int64
	UpdateAt      int64
	DeleteAt      int64
	Permissions   string
	SchemeManaged bool
	BuiltIn       bool
}

func NewRoleFromModel

func NewRoleFromModel(role *model.Role) *Role

func (Role) ToModel

func (role Role) ToModel() *model.Role

type SqlAuditStore

type SqlAuditStore struct {
	SqlStore
}

func (SqlAuditStore) Get

func (s SqlAuditStore) Get(user_id string, offset int, limit int) (model.Audits, *model.AppError)

func (SqlAuditStore) PermanentDeleteByUser

func (s SqlAuditStore) PermanentDeleteByUser(userId string) *model.AppError

func (SqlAuditStore) Save

func (s SqlAuditStore) Save(audit *model.Audit) *model.AppError

type SqlBotStore

type SqlBotStore struct {
	SqlStore
	// contains filtered or unexported fields
}

SqlBotStore is a store for managing bots in the database. Bots are otherwise normal users with extra metadata record in the Bots table. The primary key for a bot matches the primary key value for corresponding User record.

func (SqlBotStore) Get

func (us SqlBotStore) Get(botUserId string, includeDeleted bool) (*model.Bot, *model.AppError)

Get fetches the given bot in the database.

func (SqlBotStore) GetAll

func (us SqlBotStore) GetAll(options *model.BotGetOptions) ([]*model.Bot, *model.AppError)

GetAll fetches from all bots in the database.

func (SqlBotStore) PermanentDelete

func (us SqlBotStore) PermanentDelete(botUserId string) *model.AppError

PermanentDelete removes the bot from the database altogether. If the corresponding user is to be deleted, it must be done via the user store.

func (SqlBotStore) Save

func (us SqlBotStore) Save(bot *model.Bot) (*model.Bot, *model.AppError)

Save persists a new bot to the database. It assumes the corresponding user was saved via the user store.

func (SqlBotStore) Update

func (us SqlBotStore) Update(bot *model.Bot) (*model.Bot, *model.AppError)

Update persists an updated bot to the database. It assumes the corresponding user was updated via the user store.

type SqlChannelMemberHistoryStore

type SqlChannelMemberHistoryStore struct {
	SqlStore
}

func (SqlChannelMemberHistoryStore) GetUsersInChannelDuring

func (s SqlChannelMemberHistoryStore) GetUsersInChannelDuring(startTime int64, endTime int64, channelId string) ([]*model.ChannelMemberHistoryResult, *model.AppError)

func (SqlChannelMemberHistoryStore) LogJoinEvent

func (s SqlChannelMemberHistoryStore) LogJoinEvent(userId string, channelId string, joinTime int64) *model.AppError

func (SqlChannelMemberHistoryStore) LogLeaveEvent

func (s SqlChannelMemberHistoryStore) LogLeaveEvent(userId string, channelId string, leaveTime int64) *model.AppError

func (SqlChannelMemberHistoryStore) PermanentDeleteBatch

func (s SqlChannelMemberHistoryStore) PermanentDeleteBatch(endTime int64, limit int64) (int64, *model.AppError)

type SqlChannelStore

type SqlChannelStore struct {
	SqlStore
	// contains filtered or unexported fields
}

func (SqlChannelStore) AnalyticsDeletedTypeCount

func (s SqlChannelStore) AnalyticsDeletedTypeCount(teamId string, channelType string) (int64, *model.AppError)

func (SqlChannelStore) AnalyticsTypeCount

func (s SqlChannelStore) AnalyticsTypeCount(teamId string, channelType string) (int64, *model.AppError)

func (SqlChannelStore) AutocompleteInTeam

func (s SqlChannelStore) AutocompleteInTeam(teamId string, term string, includeDeleted bool) (*model.ChannelList, *model.AppError)

func (SqlChannelStore) AutocompleteInTeamForSearch

func (s SqlChannelStore) AutocompleteInTeamForSearch(teamId string, userId string, term string, includeDeleted bool) (*model.ChannelList, *model.AppError)

func (SqlChannelStore) ClearAllCustomRoleAssignments

func (s SqlChannelStore) ClearAllCustomRoleAssignments() *model.AppError

func (SqlChannelStore) ClearCaches

func (s SqlChannelStore) ClearCaches()

func (SqlChannelStore) CountPostsAfter

func (s SqlChannelStore) CountPostsAfter(channelId string, timestamp int64, userId string) (int, *model.AppError)

CountPostsAfter returns the number of posts in the given channel created after but not including the given timestamp. If given a non-empty user ID, only counts posts made by that user.

func (SqlChannelStore) CreateDirectChannel

func (s SqlChannelStore) CreateDirectChannel(user *model.User, otherUser *model.User) (*model.Channel, *model.AppError)

func (SqlChannelStore) Delete

func (s SqlChannelStore) Delete(channelId string, time int64) *model.AppError

Delete records the given deleted timestamp to the channel in question.

func (SqlChannelStore) Get

func (s SqlChannelStore) Get(id string, allowFromCache bool) (*model.Channel, *model.AppError)

func (SqlChannelStore) GetAll

func (s SqlChannelStore) GetAll(teamId string) ([]*model.Channel, *model.AppError)

func (SqlChannelStore) GetAllChannelMembersForUser

func (s SqlChannelStore) GetAllChannelMembersForUser(userId string, allowFromCache bool, includeDeleted bool) (map[string]string, *model.AppError)

func (SqlChannelStore) GetAllChannelMembersNotifyPropsForChannel

func (s SqlChannelStore) GetAllChannelMembersNotifyPropsForChannel(channelId string, allowFromCache bool) (map[string]model.StringMap, *model.AppError)

func (SqlChannelStore) GetAllChannels

func (s SqlChannelStore) GetAllChannels(offset, limit int, opts store.ChannelSearchOpts) (*model.ChannelListWithTeamData, *model.AppError)

func (SqlChannelStore) GetAllChannelsCount

func (s SqlChannelStore) GetAllChannelsCount(opts store.ChannelSearchOpts) (int64, *model.AppError)

func (SqlChannelStore) GetAllChannelsForExportAfter

func (s SqlChannelStore) GetAllChannelsForExportAfter(limit int, afterId string) ([]*model.ChannelForExport, *model.AppError)

func (SqlChannelStore) GetAllDirectChannelsForExportAfter

func (s SqlChannelStore) GetAllDirectChannelsForExportAfter(limit int, afterId string) ([]*model.DirectChannelForExport, *model.AppError)

func (SqlChannelStore) GetByName

func (s SqlChannelStore) GetByName(teamId string, name string, allowFromCache bool) (*model.Channel, *model.AppError)

func (SqlChannelStore) GetByNameIncludeDeleted

func (s SqlChannelStore) GetByNameIncludeDeleted(teamId string, name string, allowFromCache bool) (*model.Channel, *model.AppError)

func (SqlChannelStore) GetByNames

func (s SqlChannelStore) GetByNames(teamId string, names []string, allowFromCache bool) ([]*model.Channel, *model.AppError)

func (SqlChannelStore) GetChannelCounts

func (s SqlChannelStore) GetChannelCounts(teamId string, userId string) (*model.ChannelCounts, *model.AppError)

func (SqlChannelStore) GetChannelMembersForExport

func (s SqlChannelStore) GetChannelMembersForExport(userId string, teamId string) ([]*model.ChannelMemberForExport, *model.AppError)

func (SqlChannelStore) GetChannelMembersTimezones

func (s SqlChannelStore) GetChannelMembersTimezones(channelId string) ([]model.StringMap, *model.AppError)

func (SqlChannelStore) GetChannelUnread

func (s SqlChannelStore) GetChannelUnread(channelId, userId string) (*model.ChannelUnread, *model.AppError)

func (SqlChannelStore) GetChannels

func (s SqlChannelStore) GetChannels(teamId string, userId string, includeDeleted bool) (*model.ChannelList, *model.AppError)

func (SqlChannelStore) GetChannelsBatchForIndexing

func (s SqlChannelStore) GetChannelsBatchForIndexing(startTime, endTime int64, limit int) ([]*model.Channel, *model.AppError)

func (SqlChannelStore) GetChannelsByIds

func (s SqlChannelStore) GetChannelsByIds(channelIds []string, includeDeleted bool) ([]*model.Channel, *model.AppError)

func (SqlChannelStore) GetChannelsByScheme

func (s SqlChannelStore) GetChannelsByScheme(schemeId string, offset int, limit int) (model.ChannelList, *model.AppError)

func (SqlChannelStore) GetDeleted

func (s SqlChannelStore) GetDeleted(teamId string, offset int, limit int, userId string) (*model.ChannelList, *model.AppError)

func (SqlChannelStore) GetDeletedByName

func (s SqlChannelStore) GetDeletedByName(teamId string, name string) (*model.Channel, *model.AppError)

func (SqlChannelStore) GetForPost

func (s SqlChannelStore) GetForPost(postId string) (*model.Channel, *model.AppError)

func (SqlChannelStore) GetFromMaster

func (s SqlChannelStore) GetFromMaster(id string) (*model.Channel, *model.AppError)

func (SqlChannelStore) GetGuestCount

func (s SqlChannelStore) GetGuestCount(channelId string, allowFromCache bool) (int64, *model.AppError)

func (SqlChannelStore) GetMember

func (s SqlChannelStore) GetMember(channelId string, userId string) (*model.ChannelMember, *model.AppError)

func (SqlChannelStore) GetMemberCount

func (s SqlChannelStore) GetMemberCount(channelId string, allowFromCache bool) (int64, *model.AppError)

func (SqlChannelStore) GetMemberCountFromCache

func (s SqlChannelStore) GetMemberCountFromCache(channelId string) int64

func (SqlChannelStore) GetMemberForPost

func (s SqlChannelStore) GetMemberForPost(postId string, userId string) (*model.ChannelMember, *model.AppError)

func (SqlChannelStore) GetMembers

func (s SqlChannelStore) GetMembers(channelId string, offset, limit int) (*model.ChannelMembers, *model.AppError)

func (SqlChannelStore) GetMembersByIds

func (s SqlChannelStore) GetMembersByIds(channelId string, userIds []string) (*model.ChannelMembers, *model.AppError)

func (SqlChannelStore) GetMembersForUser

func (s SqlChannelStore) GetMembersForUser(teamId string, userId string) (*model.ChannelMembers, *model.AppError)

func (SqlChannelStore) GetMembersForUserWithPagination

func (s SqlChannelStore) GetMembersForUserWithPagination(teamId, userId string, page, perPage int) (*model.ChannelMembers, *model.AppError)

func (SqlChannelStore) GetMoreChannels

func (s SqlChannelStore) GetMoreChannels(teamId string, userId string, offset int, limit int) (*model.ChannelList, *model.AppError)

func (SqlChannelStore) GetPinnedPostCount

func (s SqlChannelStore) GetPinnedPostCount(channelId string, allowFromCache bool) (int64, *model.AppError)

func (SqlChannelStore) GetPinnedPosts

func (s SqlChannelStore) GetPinnedPosts(channelId string) (*model.PostList, *model.AppError)

func (SqlChannelStore) GetPublicChannelsByIdsForTeam

func (s SqlChannelStore) GetPublicChannelsByIdsForTeam(teamId string, channelIds []string) (*model.ChannelList, *model.AppError)

func (SqlChannelStore) GetPublicChannelsForTeam

func (s SqlChannelStore) GetPublicChannelsForTeam(teamId string, offset int, limit int) (*model.ChannelList, *model.AppError)

func (SqlChannelStore) GetTeamChannels

func (s SqlChannelStore) GetTeamChannels(teamId string) (*model.ChannelList, *model.AppError)

func (SqlChannelStore) GroupSyncedChannelCount added in v5.22.0

func (s SqlChannelStore) GroupSyncedChannelCount() (int64, *model.AppError)

func (SqlChannelStore) IncrementMentionCount

func (s SqlChannelStore) IncrementMentionCount(channelId string, userId string) *model.AppError

func (SqlChannelStore) InvalidateAllChannelMembersForUser

func (s SqlChannelStore) InvalidateAllChannelMembersForUser(userId string)

func (SqlChannelStore) InvalidateCacheForChannelMembersNotifyProps

func (s SqlChannelStore) InvalidateCacheForChannelMembersNotifyProps(channelId string)

func (SqlChannelStore) InvalidateChannel

func (s SqlChannelStore) InvalidateChannel(id string)

func (SqlChannelStore) InvalidateChannelByName

func (s SqlChannelStore) InvalidateChannelByName(teamId, name string)

func (SqlChannelStore) InvalidateGuestCount

func (s SqlChannelStore) InvalidateGuestCount(channelId string)

func (SqlChannelStore) InvalidateMemberCount

func (s SqlChannelStore) InvalidateMemberCount(channelId string)

func (SqlChannelStore) InvalidatePinnedPostCount

func (s SqlChannelStore) InvalidatePinnedPostCount(channelId string)

func (SqlChannelStore) IsUserInChannelUseCache

func (s SqlChannelStore) IsUserInChannelUseCache(userId string, channelId string) bool

func (SqlChannelStore) MigrateChannelMembers

func (s SqlChannelStore) MigrateChannelMembers(fromChannelId string, fromUserId string) (map[string]string, *model.AppError)

This function does the Advanced Permissions Phase 2 migration for ChannelMember objects. It performs the migration in batches as a single transaction per batch to ensure consistency but to also minimise execution time to avoid causing unnecessary table locks. **THIS FUNCTION SHOULD NOT BE USED FOR ANY OTHER PURPOSE.** Executing this function *after* the new Schemes functionality has been used on an installation will have unintended consequences.

func (SqlChannelStore) MigratePublicChannels

func (s SqlChannelStore) MigratePublicChannels() error

MigratePublicChannels initializes the PublicChannels table with data created before this version of the Mattermost server kept it up-to-date.

func (SqlChannelStore) PermanentDelete

func (s SqlChannelStore) PermanentDelete(channelId string) *model.AppError

PermanentDelete removes the given channel from the database.

func (SqlChannelStore) PermanentDeleteByTeam

func (s SqlChannelStore) PermanentDeleteByTeam(teamId string) *model.AppError

PermanentDeleteByTeam removes all channels for the given team from the database.

func (SqlChannelStore) PermanentDeleteMembersByChannel

func (s SqlChannelStore) PermanentDeleteMembersByChannel(channelId string) *model.AppError

func (SqlChannelStore) PermanentDeleteMembersByUser

func (s SqlChannelStore) PermanentDeleteMembersByUser(userId string) *model.AppError

func (SqlChannelStore) RemoveAllDeactivatedMembers

func (s SqlChannelStore) RemoveAllDeactivatedMembers(channelId string) *model.AppError

func (SqlChannelStore) RemoveMember

func (s SqlChannelStore) RemoveMember(channelId string, userId string) *model.AppError

func (SqlChannelStore) ResetAllChannelSchemes

func (s SqlChannelStore) ResetAllChannelSchemes() *model.AppError

func (SqlChannelStore) Restore

func (s SqlChannelStore) Restore(channelId string, time int64) *model.AppError

Restore reverts a previous deleted timestamp from the channel in question.

func (SqlChannelStore) Save

func (s SqlChannelStore) Save(channel *model.Channel, maxChannelsPerTeam int64) (*model.Channel, *model.AppError)

Save writes the (non-direct) channel channel to the database.

func (SqlChannelStore) SaveDirectChannel

func (s SqlChannelStore) SaveDirectChannel(directchannel *model.Channel, member1 *model.ChannelMember, member2 *model.ChannelMember) (*model.Channel, *model.AppError)

func (SqlChannelStore) SaveMember

func (SqlChannelStore) SearchAllChannels

func (SqlChannelStore) SearchArchivedInTeam

func (s SqlChannelStore) SearchArchivedInTeam(teamId string, term string, userId string) (*model.ChannelList, *model.AppError)

func (SqlChannelStore) SearchForUserInTeam

func (s SqlChannelStore) SearchForUserInTeam(userId string, teamId string, term string, includeDeleted bool) (*model.ChannelList, *model.AppError)

func (SqlChannelStore) SearchGroupChannels

func (s SqlChannelStore) SearchGroupChannels(userId, term string) (*model.ChannelList, *model.AppError)

func (SqlChannelStore) SearchInTeam

func (s SqlChannelStore) SearchInTeam(teamId string, term string, includeDeleted bool) (*model.ChannelList, *model.AppError)

func (SqlChannelStore) SearchMore

func (s SqlChannelStore) SearchMore(userId string, teamId string, term string) (*model.ChannelList, *model.AppError)

func (SqlChannelStore) SetDeleteAt

func (s SqlChannelStore) SetDeleteAt(channelId string, deleteAt, updateAt int64) *model.AppError

SetDeleteAt records the given deleted and updated timestamp to the channel in question.

func (SqlChannelStore) Update

func (s SqlChannelStore) Update(channel *model.Channel) (*model.Channel, *model.AppError)

Update writes the updated channel to the database.

func (SqlChannelStore) UpdateLastViewedAt

func (s SqlChannelStore) UpdateLastViewedAt(channelIds []string, userId string) (map[string]int64, *model.AppError)

func (SqlChannelStore) UpdateLastViewedAtPost

func (s SqlChannelStore) UpdateLastViewedAtPost(unreadPost *model.Post, userID string, mentionCount int) (*model.ChannelUnreadAt, *model.AppError)

UpdateLastViewedAtPost updates a ChannelMember as if the user last read the channel at the time of the given post. If the provided mentionCount is -1, the given post and all posts after it are considered to be mentions. Returns an updated model.ChannelUnreadAt that can be returned to the client.

func (SqlChannelStore) UpdateMember

func (s SqlChannelStore) UpdateMember(member *model.ChannelMember) (*model.ChannelMember, *model.AppError)

func (SqlChannelStore) UpdateMembersRole added in v5.20.0

func (s SqlChannelStore) UpdateMembersRole(channelID string, userIDs []string) *model.AppError

func (SqlChannelStore) UserBelongsToChannels

func (s SqlChannelStore) UserBelongsToChannels(userId string, channelIds []string) (bool, *model.AppError)

type SqlCommandStore

type SqlCommandStore struct {
	SqlStore
}

func (SqlCommandStore) AnalyticsCommandCount

func (s SqlCommandStore) AnalyticsCommandCount(teamId string) (int64, *model.AppError)

func (SqlCommandStore) Delete

func (s SqlCommandStore) Delete(commandId string, time int64) *model.AppError

func (SqlCommandStore) Get

func (SqlCommandStore) GetByTeam

func (s SqlCommandStore) GetByTeam(teamId string) ([]*model.Command, *model.AppError)

func (SqlCommandStore) GetByTrigger

func (s SqlCommandStore) GetByTrigger(teamId string, trigger string) (*model.Command, *model.AppError)

func (SqlCommandStore) PermanentDeleteByTeam

func (s SqlCommandStore) PermanentDeleteByTeam(teamId string) *model.AppError

func (SqlCommandStore) PermanentDeleteByUser

func (s SqlCommandStore) PermanentDeleteByUser(userId string) *model.AppError

func (SqlCommandStore) Save

func (s SqlCommandStore) Save(command *model.Command) (*model.Command, *model.AppError)

func (SqlCommandStore) Update

func (s SqlCommandStore) Update(cmd *model.Command) (*model.Command, *model.AppError)

type SqlCommandWebhookStore

type SqlCommandWebhookStore struct {
	SqlStore
}

func (SqlCommandWebhookStore) Cleanup

func (s SqlCommandWebhookStore) Cleanup()

func (SqlCommandWebhookStore) Get

func (SqlCommandWebhookStore) Save

func (SqlCommandWebhookStore) TryUse

func (s SqlCommandWebhookStore) TryUse(id string, limit int) *model.AppError

type SqlComplianceStore

type SqlComplianceStore struct {
	SqlStore
}

func (SqlComplianceStore) ComplianceExport

func (s SqlComplianceStore) ComplianceExport(job *model.Compliance) ([]*model.CompliancePost, *model.AppError)

func (SqlComplianceStore) Get

func (SqlComplianceStore) GetAll

func (s SqlComplianceStore) GetAll(offset, limit int) (model.Compliances, *model.AppError)

func (SqlComplianceStore) MessageExport

func (s SqlComplianceStore) MessageExport(after int64, limit int) ([]*model.MessageExport, *model.AppError)

func (SqlComplianceStore) Save

func (SqlComplianceStore) Update

func (s SqlComplianceStore) Update(compliance *model.Compliance) (*model.Compliance, *model.AppError)

type SqlEmojiStore

type SqlEmojiStore struct {
	SqlStore
	// contains filtered or unexported fields
}

func (SqlEmojiStore) Delete

func (es SqlEmojiStore) Delete(emoji *model.Emoji, time int64) *model.AppError

func (SqlEmojiStore) Get

func (es SqlEmojiStore) Get(id string, allowFromCache bool) (*model.Emoji, *model.AppError)

func (SqlEmojiStore) GetByName

func (es SqlEmojiStore) GetByName(name string, allowFromCache bool) (*model.Emoji, *model.AppError)

func (SqlEmojiStore) GetList

func (es SqlEmojiStore) GetList(offset, limit int, sort string) ([]*model.Emoji, *model.AppError)

func (SqlEmojiStore) GetMultipleByName

func (es SqlEmojiStore) GetMultipleByName(names []string) ([]*model.Emoji, *model.AppError)

func (SqlEmojiStore) Save

func (es SqlEmojiStore) Save(emoji *model.Emoji) (*model.Emoji, *model.AppError)

func (SqlEmojiStore) Search

func (es SqlEmojiStore) Search(name string, prefixOnly bool, limit int) ([]*model.Emoji, *model.AppError)

type SqlFileInfoStore

type SqlFileInfoStore struct {
	SqlStore
	// contains filtered or unexported fields
}

func (SqlFileInfoStore) AttachToPost

func (fs SqlFileInfoStore) AttachToPost(fileId, postId, creatorId string) *model.AppError

func (SqlFileInfoStore) ClearCaches

func (fs SqlFileInfoStore) ClearCaches()

func (SqlFileInfoStore) DeleteForPost

func (fs SqlFileInfoStore) DeleteForPost(postId string) (string, *model.AppError)

func (SqlFileInfoStore) Get

func (SqlFileInfoStore) GetByPath

func (fs SqlFileInfoStore) GetByPath(path string) (*model.FileInfo, *model.AppError)

func (SqlFileInfoStore) GetForPost

func (fs SqlFileInfoStore) GetForPost(postId string, readFromMaster, includeDeleted, allowFromCache bool) ([]*model.FileInfo, *model.AppError)

func (SqlFileInfoStore) GetForUser

func (fs SqlFileInfoStore) GetForUser(userId string) ([]*model.FileInfo, *model.AppError)

func (SqlFileInfoStore) GetWithOptions added in v5.22.0

func (fs SqlFileInfoStore) GetWithOptions(page, perPage int, opt *model.GetFileInfosOptions) ([]*model.FileInfo, *model.AppError)

func (SqlFileInfoStore) InvalidateFileInfosForPostCache

func (fs SqlFileInfoStore) InvalidateFileInfosForPostCache(postId string, deleted bool)

func (SqlFileInfoStore) PermanentDelete

func (fs SqlFileInfoStore) PermanentDelete(fileId string) *model.AppError

func (SqlFileInfoStore) PermanentDeleteBatch

func (fs SqlFileInfoStore) PermanentDeleteBatch(endTime int64, limit int64) (int64, *model.AppError)

func (SqlFileInfoStore) PermanentDeleteByUser

func (fs SqlFileInfoStore) PermanentDeleteByUser(userId string) (int64, *model.AppError)

func (SqlFileInfoStore) Save

type SqlGroupStore

type SqlGroupStore struct {
	SqlStore
}

func (*SqlGroupStore) AdminRoleGroupsForSyncableMember added in v5.20.0

func (s *SqlGroupStore) AdminRoleGroupsForSyncableMember(userID, syncableID string, syncableType model.GroupSyncableType) ([]string, *model.AppError)

func (*SqlGroupStore) ChannelMembersMinusGroupMembers

func (s *SqlGroupStore) ChannelMembersMinusGroupMembers(channelID string, groupIDs []string, page, perPage int) ([]*model.UserWithGroups, *model.AppError)

ChannelMembersMinusGroupMembers returns the set of users in the given channel minus the set of users in the given groups.

func (*SqlGroupStore) ChannelMembersToAdd

func (s *SqlGroupStore) ChannelMembersToAdd(since int64, channelID *string) ([]*model.UserChannelIDPair, *model.AppError)

func (*SqlGroupStore) ChannelMembersToRemove

func (s *SqlGroupStore) ChannelMembersToRemove(channelID *string) ([]*model.ChannelMember, *model.AppError)

func (*SqlGroupStore) CountChannelMembersMinusGroupMembers

func (s *SqlGroupStore) CountChannelMembersMinusGroupMembers(channelID string, groupIDs []string) (int64, *model.AppError)

CountChannelMembersMinusGroupMembers returns the count of the set of users in the given channel minus the set of users in the given groups.

func (*SqlGroupStore) CountGroupsByChannel

func (s *SqlGroupStore) CountGroupsByChannel(channelId string, opts model.GroupSearchOpts) (int64, *model.AppError)

func (*SqlGroupStore) CountGroupsByTeam

func (s *SqlGroupStore) CountGroupsByTeam(teamId string, opts model.GroupSearchOpts) (int64, *model.AppError)

func (*SqlGroupStore) CountTeamMembersMinusGroupMembers

func (s *SqlGroupStore) CountTeamMembersMinusGroupMembers(teamID string, groupIDs []string) (int64, *model.AppError)

CountTeamMembersMinusGroupMembers returns the count of the set of users on the given team minus the set of users in the given groups.

func (*SqlGroupStore) Create

func (s *SqlGroupStore) Create(group *model.Group) (*model.Group, *model.AppError)

func (*SqlGroupStore) CreateGroupSyncable

func (s *SqlGroupStore) CreateGroupSyncable(groupSyncable *model.GroupSyncable) (*model.GroupSyncable, *model.AppError)

func (*SqlGroupStore) Delete

func (s *SqlGroupStore) Delete(groupID string) (*model.Group, *model.AppError)

func (*SqlGroupStore) DeleteGroupSyncable

func (s *SqlGroupStore) DeleteGroupSyncable(groupID string, syncableID string, syncableType model.GroupSyncableType) (*model.GroupSyncable, *model.AppError)

func (*SqlGroupStore) DeleteMember

func (s *SqlGroupStore) DeleteMember(groupID string, userID string) (*model.GroupMember, *model.AppError)

func (*SqlGroupStore) DistinctGroupMemberCount added in v5.22.0

func (s *SqlGroupStore) DistinctGroupMemberCount() (int64, *model.AppError)

func (*SqlGroupStore) Get

func (s *SqlGroupStore) Get(groupId string) (*model.Group, *model.AppError)

func (*SqlGroupStore) GetAllBySource

func (s *SqlGroupStore) GetAllBySource(groupSource model.GroupSource) ([]*model.Group, *model.AppError)

func (*SqlGroupStore) GetAllGroupSyncablesByGroupId

func (s *SqlGroupStore) GetAllGroupSyncablesByGroupId(groupID string, syncableType model.GroupSyncableType) ([]*model.GroupSyncable, *model.AppError)

func (*SqlGroupStore) GetByIDs

func (s *SqlGroupStore) GetByIDs(groupIDs []string) ([]*model.Group, *model.AppError)

func (*SqlGroupStore) GetByName

func (s *SqlGroupStore) GetByName(name string) (*model.Group, *model.AppError)

func (*SqlGroupStore) GetByRemoteID

func (s *SqlGroupStore) GetByRemoteID(remoteID string, groupSource model.GroupSource) (*model.Group, *model.AppError)

func (*SqlGroupStore) GetByUser

func (s *SqlGroupStore) GetByUser(userId string) ([]*model.Group, *model.AppError)

func (*SqlGroupStore) GetGroupSyncable

func (s *SqlGroupStore) GetGroupSyncable(groupID string, syncableID string, syncableType model.GroupSyncableType) (*model.GroupSyncable, *model.AppError)

func (*SqlGroupStore) GetGroups

func (s *SqlGroupStore) GetGroups(page, perPage int, opts model.GroupSearchOpts) ([]*model.Group, *model.AppError)

func (*SqlGroupStore) GetGroupsByChannel

func (s *SqlGroupStore) GetGroupsByChannel(channelId string, opts model.GroupSearchOpts) ([]*model.GroupWithSchemeAdmin, *model.AppError)

func (*SqlGroupStore) GetGroupsByTeam

func (s *SqlGroupStore) GetGroupsByTeam(teamId string, opts model.GroupSearchOpts) ([]*model.GroupWithSchemeAdmin, *model.AppError)

func (*SqlGroupStore) GetMemberCount

func (s *SqlGroupStore) GetMemberCount(groupID string) (int64, *model.AppError)

func (*SqlGroupStore) GetMemberUsers

func (s *SqlGroupStore) GetMemberUsers(groupID string) ([]*model.User, *model.AppError)

func (*SqlGroupStore) GetMemberUsersPage

func (s *SqlGroupStore) GetMemberUsersPage(groupID string, page int, perPage int) ([]*model.User, *model.AppError)

func (*SqlGroupStore) GroupChannelCount added in v5.22.0

func (s *SqlGroupStore) GroupChannelCount() (int64, *model.AppError)

func (*SqlGroupStore) GroupCount added in v5.22.0

func (s *SqlGroupStore) GroupCount() (int64, *model.AppError)

func (*SqlGroupStore) GroupMemberCount added in v5.22.0

func (s *SqlGroupStore) GroupMemberCount() (int64, *model.AppError)

func (*SqlGroupStore) GroupTeamCount added in v5.22.0

func (s *SqlGroupStore) GroupTeamCount() (int64, *model.AppError)

func (*SqlGroupStore) PermanentDeleteMembersByUser

func (s *SqlGroupStore) PermanentDeleteMembersByUser(userId string) *model.AppError

func (*SqlGroupStore) PermittedSyncableAdmins added in v5.20.0

func (s *SqlGroupStore) PermittedSyncableAdmins(syncableID string, syncableType model.GroupSyncableType) ([]string, *model.AppError)

func (*SqlGroupStore) TeamMembersMinusGroupMembers

func (s *SqlGroupStore) TeamMembersMinusGroupMembers(teamID string, groupIDs []string, page, perPage int) ([]*model.UserWithGroups, *model.AppError)

TeamMembersMinusGroupMembers returns the set of users on the given team minus the set of users in the given groups.

func (*SqlGroupStore) TeamMembersToAdd

func (s *SqlGroupStore) TeamMembersToAdd(since int64, teamID *string) ([]*model.UserTeamIDPair, *model.AppError)

func (*SqlGroupStore) TeamMembersToRemove

func (s *SqlGroupStore) TeamMembersToRemove(teamID *string) ([]*model.TeamMember, *model.AppError)

func (*SqlGroupStore) Update

func (s *SqlGroupStore) Update(group *model.Group) (*model.Group, *model.AppError)

func (*SqlGroupStore) UpdateGroupSyncable

func (s *SqlGroupStore) UpdateGroupSyncable(groupSyncable *model.GroupSyncable) (*model.GroupSyncable, *model.AppError)

func (*SqlGroupStore) UpsertMember

func (s *SqlGroupStore) UpsertMember(groupID string, userID string) (*model.GroupMember, *model.AppError)

type SqlJobStore

type SqlJobStore struct {
	SqlStore
}

func (SqlJobStore) Delete

func (jss SqlJobStore) Delete(id string) (string, *model.AppError)

func (SqlJobStore) Get

func (jss SqlJobStore) Get(id string) (*model.Job, *model.AppError)

func (SqlJobStore) GetAllByStatus

func (jss SqlJobStore) GetAllByStatus(status string) ([]*model.Job, *model.AppError)

func (SqlJobStore) GetAllByType

func (jss SqlJobStore) GetAllByType(jobType string) ([]*model.Job, *model.AppError)

func (SqlJobStore) GetAllByTypePage

func (jss SqlJobStore) GetAllByTypePage(jobType string, offset int, limit int) ([]*model.Job, *model.AppError)

func (SqlJobStore) GetAllPage

func (jss SqlJobStore) GetAllPage(offset int, limit int) ([]*model.Job, *model.AppError)

func (SqlJobStore) GetCountByStatusAndType

func (jss SqlJobStore) GetCountByStatusAndType(status string, jobType string) (int64, *model.AppError)

func (SqlJobStore) GetNewestJobByStatusAndType

func (jss SqlJobStore) GetNewestJobByStatusAndType(status string, jobType string) (*model.Job, *model.AppError)

func (SqlJobStore) Save

func (jss SqlJobStore) Save(job *model.Job) (*model.Job, *model.AppError)

func (SqlJobStore) UpdateOptimistically

func (jss SqlJobStore) UpdateOptimistically(job *model.Job, currentStatus string) (bool, *model.AppError)

func (SqlJobStore) UpdateStatus

func (jss SqlJobStore) UpdateStatus(id string, status string) (*model.Job, *model.AppError)

func (SqlJobStore) UpdateStatusOptimistically

func (jss SqlJobStore) UpdateStatusOptimistically(id string, currentStatus string, newStatus string) (bool, *model.AppError)

type SqlLicenseStore

type SqlLicenseStore struct {
	SqlStore
}

SqlLicenseStore encapsulates the database writes and reads for model.LicenseRecord objects.

func (SqlLicenseStore) Get

Get obtains the license with the provided id parameter from the database. If the license doesn't exist it returns a model.AppError with http.StatusNotFound in the StatusCode field.

func (SqlLicenseStore) Save

Save validates and stores the license instance in the database. The Id and Bytes fields are mandatory. The Bytes field is limited to a maximum of 10000 bytes. If the license ID matches an existing license in the database it returns the license stored in the database. If not, it saves the new database and returns the created license with the CreateAt field updated.

type SqlLinkMetadataStore

type SqlLinkMetadataStore struct {
	SqlStore
}

func (SqlLinkMetadataStore) Get

func (s SqlLinkMetadataStore) Get(url string, timestamp int64) (*model.LinkMetadata, *model.AppError)

func (SqlLinkMetadataStore) Save

type SqlOAuthStore

type SqlOAuthStore struct {
	SqlStore
}

func (SqlOAuthStore) DeleteApp

func (as SqlOAuthStore) DeleteApp(id string) *model.AppError

func (SqlOAuthStore) GetAccessData

func (as SqlOAuthStore) GetAccessData(token string) (*model.AccessData, *model.AppError)

func (SqlOAuthStore) GetAccessDataByRefreshToken

func (as SqlOAuthStore) GetAccessDataByRefreshToken(token string) (*model.AccessData, *model.AppError)

func (SqlOAuthStore) GetAccessDataByUserForApp

func (as SqlOAuthStore) GetAccessDataByUserForApp(userId, clientId string) ([]*model.AccessData, *model.AppError)

func (SqlOAuthStore) GetApp

func (as SqlOAuthStore) GetApp(id string) (*model.OAuthApp, *model.AppError)

func (SqlOAuthStore) GetAppByUser

func (as SqlOAuthStore) GetAppByUser(userId string, offset, limit int) ([]*model.OAuthApp, *model.AppError)

func (SqlOAuthStore) GetApps

func (as SqlOAuthStore) GetApps(offset, limit int) ([]*model.OAuthApp, *model.AppError)

func (SqlOAuthStore) GetAuthData

func (as SqlOAuthStore) GetAuthData(code string) (*model.AuthData, *model.AppError)

func (SqlOAuthStore) GetAuthorizedApps

func (as SqlOAuthStore) GetAuthorizedApps(userId string, offset, limit int) ([]*model.OAuthApp, *model.AppError)

func (SqlOAuthStore) GetPreviousAccessData

func (as SqlOAuthStore) GetPreviousAccessData(userId, clientId string) (*model.AccessData, *model.AppError)

func (SqlOAuthStore) PermanentDeleteAuthDataByUser

func (as SqlOAuthStore) PermanentDeleteAuthDataByUser(userId string) *model.AppError

func (SqlOAuthStore) RemoveAccessData

func (as SqlOAuthStore) RemoveAccessData(token string) *model.AppError

func (SqlOAuthStore) RemoveAllAccessData

func (as SqlOAuthStore) RemoveAllAccessData() *model.AppError

func (SqlOAuthStore) RemoveAuthData

func (as SqlOAuthStore) RemoveAuthData(code string) *model.AppError

func (SqlOAuthStore) SaveAccessData

func (as SqlOAuthStore) SaveAccessData(accessData *model.AccessData) (*model.AccessData, *model.AppError)

func (SqlOAuthStore) SaveApp

func (as SqlOAuthStore) SaveApp(app *model.OAuthApp) (*model.OAuthApp, *model.AppError)

func (SqlOAuthStore) SaveAuthData

func (as SqlOAuthStore) SaveAuthData(authData *model.AuthData) (*model.AuthData, *model.AppError)

func (SqlOAuthStore) UpdateAccessData

func (as SqlOAuthStore) UpdateAccessData(accessData *model.AccessData) (*model.AccessData, *model.AppError)

func (SqlOAuthStore) UpdateApp

func (as SqlOAuthStore) UpdateApp(app *model.OAuthApp) (*model.OAuthApp, *model.AppError)

type SqlPluginStore

type SqlPluginStore struct {
	SqlStore
}

func (SqlPluginStore) CompareAndDelete

func (ps SqlPluginStore) CompareAndDelete(kv *model.PluginKeyValue, oldValue []byte) (bool, *model.AppError)

func (SqlPluginStore) CompareAndSet

func (ps SqlPluginStore) CompareAndSet(kv *model.PluginKeyValue, oldValue []byte) (bool, *model.AppError)

func (SqlPluginStore) Delete

func (ps SqlPluginStore) Delete(pluginId, key string) *model.AppError

func (SqlPluginStore) DeleteAllExpired

func (ps SqlPluginStore) DeleteAllExpired() *model.AppError

func (SqlPluginStore) DeleteAllForPlugin

func (ps SqlPluginStore) DeleteAllForPlugin(pluginId string) *model.AppError

func (SqlPluginStore) Get

func (ps SqlPluginStore) Get(pluginId, key string) (*model.PluginKeyValue, *model.AppError)

func (SqlPluginStore) List

func (ps SqlPluginStore) List(pluginId string, offset int, limit int) ([]string, *model.AppError)

func (SqlPluginStore) SaveOrUpdate

func (SqlPluginStore) SetWithOptions

func (ps SqlPluginStore) SetWithOptions(pluginId string, key string, value []byte, opt model.PluginKVSetOptions) (bool, *model.AppError)

type SqlPostStore

type SqlPostStore struct {
	SqlStore
	// contains filtered or unexported fields
}

func (*SqlPostStore) AnalyticsPostCount

func (s *SqlPostStore) AnalyticsPostCount(teamId string, mustHaveFile bool, mustHaveHashtag bool) (int64, *model.AppError)

func (*SqlPostStore) AnalyticsPostCountsByDay

func (s *SqlPostStore) AnalyticsPostCountsByDay(options *model.AnalyticsPostCountsOptions) (model.AnalyticsRows, *model.AppError)

func (*SqlPostStore) AnalyticsUserCountsWithPostsByDay

func (s *SqlPostStore) AnalyticsUserCountsWithPostsByDay(teamId string) (model.AnalyticsRows, *model.AppError)

func (*SqlPostStore) ClearCaches

func (s *SqlPostStore) ClearCaches()

func (*SqlPostStore) Delete

func (s *SqlPostStore) Delete(postId string, time int64, deleteByID string) *model.AppError

func (*SqlPostStore) Get

func (s *SqlPostStore) Get(id string, skipFetchThreads bool) (*model.PostList, *model.AppError)

func (*SqlPostStore) GetDirectPostParentsForExportAfter

func (s *SqlPostStore) GetDirectPostParentsForExportAfter(limit int, afterId string) ([]*model.DirectPostForExport, *model.AppError)

func (*SqlPostStore) GetEtag

func (s *SqlPostStore) GetEtag(channelId string, allowFromCache bool) string

func (*SqlPostStore) GetFlaggedPosts

func (s *SqlPostStore) GetFlaggedPosts(userId string, offset int, limit int) (*model.PostList, *model.AppError)

func (*SqlPostStore) GetFlaggedPostsForChannel

func (s *SqlPostStore) GetFlaggedPostsForChannel(userId, channelId string, offset int, limit int) (*model.PostList, *model.AppError)

func (*SqlPostStore) GetFlaggedPostsForTeam

func (s *SqlPostStore) GetFlaggedPostsForTeam(userId, teamId string, offset int, limit int) (*model.PostList, *model.AppError)

func (*SqlPostStore) GetMaxPostSize

func (s *SqlPostStore) GetMaxPostSize() int

GetMaxPostSize returns the maximum number of runes that may be stored in a post.

func (*SqlPostStore) GetOldest

func (s *SqlPostStore) GetOldest() (*model.Post, *model.AppError)

func (*SqlPostStore) GetParentsForExportAfter

func (s *SqlPostStore) GetParentsForExportAfter(limit int, afterId string) ([]*model.PostForExport, *model.AppError)

func (*SqlPostStore) GetPostAfterTime

func (s *SqlPostStore) GetPostAfterTime(channelId string, time int64) (*model.Post, *model.AppError)

func (*SqlPostStore) GetPostIdAfterTime

func (s *SqlPostStore) GetPostIdAfterTime(channelId string, time int64) (string, *model.AppError)

func (*SqlPostStore) GetPostIdBeforeTime

func (s *SqlPostStore) GetPostIdBeforeTime(channelId string, time int64) (string, *model.AppError)

func (*SqlPostStore) GetPosts

func (s *SqlPostStore) GetPosts(options model.GetPostsOptions, _ bool) (*model.PostList, *model.AppError)

func (*SqlPostStore) GetPostsAfter

func (s *SqlPostStore) GetPostsAfter(options model.GetPostsOptions) (*model.PostList, *model.AppError)

func (*SqlPostStore) GetPostsBatchForIndexing

func (s *SqlPostStore) GetPostsBatchForIndexing(startTime int64, endTime int64, limit int) ([]*model.PostForIndexing, *model.AppError)

func (*SqlPostStore) GetPostsBefore

func (s *SqlPostStore) GetPostsBefore(options model.GetPostsOptions) (*model.PostList, *model.AppError)

func (*SqlPostStore) GetPostsByIds

func (s *SqlPostStore) GetPostsByIds(postIds []string) ([]*model.Post, *model.AppError)

func (*SqlPostStore) GetPostsCreatedAt

func (s *SqlPostStore) GetPostsCreatedAt(channelId string, time int64) ([]*model.Post, *model.AppError)

func (*SqlPostStore) GetPostsSince

func (s *SqlPostStore) GetPostsSince(options model.GetPostsSinceOptions, allowFromCache bool) (*model.PostList, *model.AppError)

func (*SqlPostStore) GetRepliesForExport

func (s *SqlPostStore) GetRepliesForExport(rootId string) ([]*model.ReplyForExport, *model.AppError)

func (*SqlPostStore) GetSingle

func (s *SqlPostStore) GetSingle(id string) (*model.Post, *model.AppError)

func (*SqlPostStore) InvalidateLastPostTimeCache

func (s *SqlPostStore) InvalidateLastPostTimeCache(channelId string)

func (*SqlPostStore) Overwrite

func (s *SqlPostStore) Overwrite(post *model.Post) (*model.Post, *model.AppError)

func (*SqlPostStore) OverwriteMultiple added in v5.22.0

func (s *SqlPostStore) OverwriteMultiple(posts []*model.Post) ([]*model.Post, *model.AppError)

func (*SqlPostStore) PermanentDeleteBatch

func (s *SqlPostStore) PermanentDeleteBatch(endTime int64, limit int64) (int64, *model.AppError)

func (*SqlPostStore) PermanentDeleteByChannel

func (s *SqlPostStore) PermanentDeleteByChannel(channelId string) *model.AppError

func (*SqlPostStore) PermanentDeleteByUser

func (s *SqlPostStore) PermanentDeleteByUser(userId string) *model.AppError

func (*SqlPostStore) Save

func (s *SqlPostStore) Save(post *model.Post) (*model.Post, *model.AppError)

func (*SqlPostStore) SaveMultiple added in v5.22.0

func (s *SqlPostStore) SaveMultiple(posts []*model.Post) ([]*model.Post, *model.AppError)

func (*SqlPostStore) Search

func (s *SqlPostStore) Search(teamId string, userId string, params *model.SearchParams) (*model.PostList, *model.AppError)

func (*SqlPostStore) SearchPostsInTeamForUser added in v5.22.0

func (s *SqlPostStore) SearchPostsInTeamForUser(paramsList []*model.SearchParams, userId, teamId string, isOrSearch, includeDeletedChannels bool, page, perPage int) (*model.PostSearchResults, *model.AppError)

func (*SqlPostStore) Update

func (s *SqlPostStore) Update(newPost *model.Post, oldPost *model.Post) (*model.Post, *model.AppError)

type SqlPreferenceStore

type SqlPreferenceStore struct {
	SqlStore
}

func (SqlPreferenceStore) CleanupFlagsBatch

func (s SqlPreferenceStore) CleanupFlagsBatch(limit int64) (int64, *model.AppError)

func (SqlPreferenceStore) Delete

func (s SqlPreferenceStore) Delete(userId, category, name string) *model.AppError

func (SqlPreferenceStore) DeleteCategory

func (s SqlPreferenceStore) DeleteCategory(userId string, category string) *model.AppError

func (SqlPreferenceStore) DeleteCategoryAndName

func (s SqlPreferenceStore) DeleteCategoryAndName(category string, name string) *model.AppError

func (SqlPreferenceStore) Get

func (s SqlPreferenceStore) Get(userId string, category string, name string) (*model.Preference, *model.AppError)

func (SqlPreferenceStore) GetAll

func (SqlPreferenceStore) GetCategory

func (s SqlPreferenceStore) GetCategory(userId string, category string) (model.Preferences, *model.AppError)

func (SqlPreferenceStore) PermanentDeleteByUser

func (s SqlPreferenceStore) PermanentDeleteByUser(userId string) *model.AppError

func (SqlPreferenceStore) Save

func (s SqlPreferenceStore) Save(preferences *model.Preferences) *model.AppError

type SqlReactionStore

type SqlReactionStore struct {
	SqlStore
}

func (*SqlReactionStore) BulkGetForPosts

func (s *SqlReactionStore) BulkGetForPosts(postIds []string) ([]*model.Reaction, *model.AppError)

func (*SqlReactionStore) Delete

func (s *SqlReactionStore) Delete(reaction *model.Reaction) (*model.Reaction, *model.AppError)

func (*SqlReactionStore) DeleteAllWithEmojiName

func (s *SqlReactionStore) DeleteAllWithEmojiName(emojiName string) *model.AppError

func (*SqlReactionStore) GetForPost

func (s *SqlReactionStore) GetForPost(postId string, allowFromCache bool) ([]*model.Reaction, *model.AppError)

func (*SqlReactionStore) PermanentDeleteBatch

func (s *SqlReactionStore) PermanentDeleteBatch(endTime int64, limit int64) (int64, *model.AppError)

func (*SqlReactionStore) Save

func (s *SqlReactionStore) Save(reaction *model.Reaction) (*model.Reaction, *model.AppError)

type SqlRoleStore

type SqlRoleStore struct {
	SqlStore
}

func (*SqlRoleStore) AllChannelSchemeRoles added in v5.22.0

func (s *SqlRoleStore) AllChannelSchemeRoles() ([]*model.Role, *model.AppError)

func (*SqlRoleStore) ChannelHigherScopedPermissions added in v5.22.0

func (s *SqlRoleStore) ChannelHigherScopedPermissions(roleNames []string) (map[string]*model.RolePermissions, *model.AppError)

func (*SqlRoleStore) ChannelRolesUnderTeamRole added in v5.22.0

func (s *SqlRoleStore) ChannelRolesUnderTeamRole(roleName string) ([]*model.Role, *model.AppError)

ChannelRolesUnderTeamRole finds all of the channel-scheme roles under the team of the given team-scheme role.

func (*SqlRoleStore) Delete

func (s *SqlRoleStore) Delete(roleId string) (*model.Role, *model.AppError)

func (*SqlRoleStore) Get

func (s *SqlRoleStore) Get(roleId string) (*model.Role, *model.AppError)

func (*SqlRoleStore) GetAll

func (s *SqlRoleStore) GetAll() ([]*model.Role, *model.AppError)

func (*SqlRoleStore) GetByName

func (s *SqlRoleStore) GetByName(name string) (*model.Role, *model.AppError)

func (*SqlRoleStore) GetByNames

func (s *SqlRoleStore) GetByNames(names []string) ([]*model.Role, *model.AppError)

func (*SqlRoleStore) PermanentDeleteAll

func (s *SqlRoleStore) PermanentDeleteAll() *model.AppError

func (*SqlRoleStore) Save

func (s *SqlRoleStore) Save(role *model.Role) (*model.Role, *model.AppError)

type SqlSchemeStore

type SqlSchemeStore struct {
	SqlStore
}

func (*SqlSchemeStore) CountByScope added in v5.22.0

func (s *SqlSchemeStore) CountByScope(scope string) (int64, *model.AppError)

func (*SqlSchemeStore) CountWithoutPermission added in v5.22.0

func (s *SqlSchemeStore) CountWithoutPermission(schemeScope, permissionID string, roleScope model.RoleScope, roleType model.RoleType) (int64, *model.AppError)

func (*SqlSchemeStore) Delete

func (s *SqlSchemeStore) Delete(schemeId string) (*model.Scheme, *model.AppError)

func (*SqlSchemeStore) Get

func (s *SqlSchemeStore) Get(schemeId string) (*model.Scheme, *model.AppError)

func (*SqlSchemeStore) GetAllPage

func (s *SqlSchemeStore) GetAllPage(scope string, offset int, limit int) ([]*model.Scheme, *model.AppError)

func (*SqlSchemeStore) GetByName

func (s *SqlSchemeStore) GetByName(schemeName string) (*model.Scheme, *model.AppError)

func (*SqlSchemeStore) PermanentDeleteAll

func (s *SqlSchemeStore) PermanentDeleteAll() *model.AppError

func (*SqlSchemeStore) Save

func (s *SqlSchemeStore) Save(scheme *model.Scheme) (*model.Scheme, *model.AppError)

type SqlSessionStore

type SqlSessionStore struct {
	SqlStore
}

func (SqlSessionStore) AnalyticsSessionCount

func (me SqlSessionStore) AnalyticsSessionCount() (int64, *model.AppError)

func (SqlSessionStore) Cleanup

func (me SqlSessionStore) Cleanup(expiryTime int64, batchSize int64)

func (SqlSessionStore) Get

func (me SqlSessionStore) Get(sessionIdOrToken string) (*model.Session, *model.AppError)

func (SqlSessionStore) GetSessions

func (me SqlSessionStore) GetSessions(userId string) ([]*model.Session, *model.AppError)

func (SqlSessionStore) GetSessionsWithActiveDeviceIds

func (me SqlSessionStore) GetSessionsWithActiveDeviceIds(userId string) ([]*model.Session, *model.AppError)

func (SqlSessionStore) PermanentDeleteSessionsByUser

func (me SqlSessionStore) PermanentDeleteSessionsByUser(userId string) *model.AppError

func (SqlSessionStore) Remove

func (me SqlSessionStore) Remove(sessionIdOrToken string) *model.AppError

func (SqlSessionStore) RemoveAllSessions

func (me SqlSessionStore) RemoveAllSessions() *model.AppError

func (SqlSessionStore) Save

func (me SqlSessionStore) Save(session *model.Session) (*model.Session, *model.AppError)

func (SqlSessionStore) UpdateDeviceId

func (me SqlSessionStore) UpdateDeviceId(id string, deviceId string, expiresAt int64) (string, *model.AppError)

func (SqlSessionStore) UpdateLastActivityAt

func (me SqlSessionStore) UpdateLastActivityAt(sessionId string, time int64) *model.AppError

func (SqlSessionStore) UpdateProps

func (me SqlSessionStore) UpdateProps(session *model.Session) *model.AppError

func (SqlSessionStore) UpdateRoles

func (me SqlSessionStore) UpdateRoles(userId, roles string) (string, *model.AppError)

type SqlStatusStore

type SqlStatusStore struct {
	SqlStore
}

func (SqlStatusStore) Get

func (s SqlStatusStore) Get(userId string) (*model.Status, *model.AppError)

func (SqlStatusStore) GetByIds

func (s SqlStatusStore) GetByIds(userIds []string) ([]*model.Status, *model.AppError)

func (SqlStatusStore) GetTotalActiveUsersCount

func (s SqlStatusStore) GetTotalActiveUsersCount() (int64, *model.AppError)

func (SqlStatusStore) ResetAll

func (s SqlStatusStore) ResetAll() *model.AppError

func (SqlStatusStore) SaveOrUpdate

func (s SqlStatusStore) SaveOrUpdate(status *model.Status) *model.AppError

func (SqlStatusStore) UpdateLastActivityAt

func (s SqlStatusStore) UpdateLastActivityAt(userId string, lastActivityAt int64) *model.AppError

type SqlStore

type SqlStore interface {
	DriverName() string
	GetCurrentSchemaVersion() string
	GetMaster() *gorp.DbMap
	GetSearchReplica() *gorp.DbMap
	GetReplica() *gorp.DbMap
	TotalMasterDbConnections() int
	TotalReadDbConnections() int
	TotalSearchDbConnections() int
	MarkSystemRanUnitTests()
	DoesTableExist(tablename string) bool
	DoesColumnExist(tableName string, columName string) bool
	DoesTriggerExist(triggerName string) bool
	CreateColumnIfNotExists(tableName string, columnName string, mySqlColType string, postgresColType string, defaultValue string) bool
	CreateColumnIfNotExistsNoDefault(tableName string, columnName string, mySqlColType string, postgresColType string) bool
	RemoveColumnIfExists(tableName string, columnName string) bool
	RemoveTableIfExists(tableName string) bool
	RenameColumnIfExists(tableName string, oldColumnName string, newColumnName string, colType string) bool
	GetMaxLengthOfColumnIfExists(tableName string, columnName string) string
	AlterColumnTypeIfExists(tableName string, columnName string, mySqlColType string, postgresColType string) bool
	AlterColumnDefaultIfExists(tableName string, columnName string, mySqlColDefault *string, postgresColDefault *string) bool
	AlterPrimaryKey(tableName string, columnNames []string) bool
	CreateUniqueIndexIfNotExists(indexName string, tableName string, columnName string) bool
	CreateIndexIfNotExists(indexName string, tableName string, columnName string) bool
	CreateCompositeIndexIfNotExists(indexName string, tableName string, columnNames []string) bool
	CreateFullTextIndexIfNotExists(indexName string, tableName string, columnName string) bool
	RemoveIndexIfExists(indexName string, tableName string) bool
	GetAllConns() []*gorp.DbMap
	Close()
	LockToMaster()
	UnlockFromMaster()
	Team() store.TeamStore
	Channel() store.ChannelStore
	Post() store.PostStore
	User() store.UserStore
	Bot() store.BotStore
	Audit() store.AuditStore
	ClusterDiscovery() store.ClusterDiscoveryStore
	Compliance() store.ComplianceStore
	Session() store.SessionStore
	OAuth() store.OAuthStore
	System() store.SystemStore
	Webhook() store.WebhookStore
	Command() store.CommandStore
	CommandWebhook() store.CommandWebhookStore
	Preference() store.PreferenceStore
	License() store.LicenseStore
	Token() store.TokenStore
	Emoji() store.EmojiStore
	Status() store.StatusStore
	FileInfo() store.FileInfoStore
	Reaction() store.ReactionStore
	Job() store.JobStore
	Plugin() store.PluginStore
	UserAccessToken() store.UserAccessTokenStore
	Role() store.RoleStore
	Scheme() store.SchemeStore
	TermsOfService() store.TermsOfServiceStore
	UserTermsOfService() store.UserTermsOfServiceStore
	LinkMetadata() store.LinkMetadataStore
	// contains filtered or unexported methods
}

type SqlSupplier

type SqlSupplier struct {
	// contains filtered or unexported fields
}

func NewSqlSupplier

func NewSqlSupplier(settings model.SqlSettings, metrics einterfaces.MetricsInterface) *SqlSupplier

func (*SqlSupplier) AlterColumnDefaultIfExists

func (ss *SqlSupplier) AlterColumnDefaultIfExists(tableName string, columnName string, mySqlColDefault *string, postgresColDefault *string) bool

func (*SqlSupplier) AlterColumnTypeIfExists

func (ss *SqlSupplier) AlterColumnTypeIfExists(tableName string, columnName string, mySqlColType string, postgresColType string) bool

func (*SqlSupplier) AlterPrimaryKey added in v5.22.0

func (ss *SqlSupplier) AlterPrimaryKey(tableName string, columnNames []string) bool

func (*SqlSupplier) Audit

func (ss *SqlSupplier) Audit() store.AuditStore

func (*SqlSupplier) Bot

func (ss *SqlSupplier) Bot() store.BotStore

func (*SqlSupplier) Channel

func (ss *SqlSupplier) Channel() store.ChannelStore

func (*SqlSupplier) ChannelMemberHistory

func (ss *SqlSupplier) ChannelMemberHistory() store.ChannelMemberHistoryStore

func (*SqlSupplier) CheckIntegrity

func (ss *SqlSupplier) CheckIntegrity() <-chan store.IntegrityCheckResult

func (*SqlSupplier) Close

func (ss *SqlSupplier) Close()

func (*SqlSupplier) ClusterDiscovery

func (ss *SqlSupplier) ClusterDiscovery() store.ClusterDiscoveryStore

func (*SqlSupplier) Command

func (ss *SqlSupplier) Command() store.CommandStore

func (*SqlSupplier) CommandWebhook

func (ss *SqlSupplier) CommandWebhook() store.CommandWebhookStore

func (*SqlSupplier) Compliance

func (ss *SqlSupplier) Compliance() store.ComplianceStore

func (*SqlSupplier) Context added in v5.22.0

func (ss *SqlSupplier) Context() context.Context

func (*SqlSupplier) CreateColumnIfNotExists

func (ss *SqlSupplier) CreateColumnIfNotExists(tableName string, columnName string, mySqlColType string, postgresColType string, defaultValue string) bool

func (*SqlSupplier) CreateColumnIfNotExistsNoDefault

func (ss *SqlSupplier) CreateColumnIfNotExistsNoDefault(tableName string, columnName string, mySqlColType string, postgresColType string) bool

func (*SqlSupplier) CreateCompositeIndexIfNotExists

func (ss *SqlSupplier) CreateCompositeIndexIfNotExists(indexName string, tableName string, columnNames []string) bool

func (*SqlSupplier) CreateFullTextIndexIfNotExists

func (ss *SqlSupplier) CreateFullTextIndexIfNotExists(indexName string, tableName string, columnName string) bool

func (*SqlSupplier) CreateIndexIfNotExists

func (ss *SqlSupplier) CreateIndexIfNotExists(indexName string, tableName string, columnName string) bool

func (*SqlSupplier) CreateUniqueIndexIfNotExists

func (ss *SqlSupplier) CreateUniqueIndexIfNotExists(indexName string, tableName string, columnName string) bool

func (*SqlSupplier) DoesColumnExist

func (ss *SqlSupplier) DoesColumnExist(tableName string, columnName string) bool

func (*SqlSupplier) DoesTableExist

func (ss *SqlSupplier) DoesTableExist(tableName string) bool

func (*SqlSupplier) DoesTriggerExist

func (ss *SqlSupplier) DoesTriggerExist(triggerName string) bool

func (*SqlSupplier) DriverName

func (ss *SqlSupplier) DriverName() string

func (*SqlSupplier) DropAllTables

func (ss *SqlSupplier) DropAllTables()

func (*SqlSupplier) Emoji

func (ss *SqlSupplier) Emoji() store.EmojiStore

func (*SqlSupplier) FileInfo

func (ss *SqlSupplier) FileInfo() store.FileInfoStore

func (*SqlSupplier) GetAllConns

func (ss *SqlSupplier) GetAllConns() []*gorp.DbMap

func (*SqlSupplier) GetCurrentSchemaVersion

func (ss *SqlSupplier) GetCurrentSchemaVersion() string

func (*SqlSupplier) GetMaster

func (ss *SqlSupplier) GetMaster() *gorp.DbMap

func (*SqlSupplier) GetMaxLengthOfColumnIfExists

func (ss *SqlSupplier) GetMaxLengthOfColumnIfExists(tableName string, columnName string) string

func (*SqlSupplier) GetReplica

func (ss *SqlSupplier) GetReplica() *gorp.DbMap

func (*SqlSupplier) GetSearchReplica

func (ss *SqlSupplier) GetSearchReplica() *gorp.DbMap

func (*SqlSupplier) Group

func (ss *SqlSupplier) Group() store.GroupStore

func (*SqlSupplier) Job

func (ss *SqlSupplier) Job() store.JobStore

func (*SqlSupplier) License

func (ss *SqlSupplier) License() store.LicenseStore

func (*SqlSupplier) LinkMetadata

func (ss *SqlSupplier) LinkMetadata() store.LinkMetadataStore

func (*SqlSupplier) LockToMaster

func (ss *SqlSupplier) LockToMaster()

func (*SqlSupplier) MarkSystemRanUnitTests

func (ss *SqlSupplier) MarkSystemRanUnitTests()

func (*SqlSupplier) OAuth

func (ss *SqlSupplier) OAuth() store.OAuthStore

func (*SqlSupplier) Plugin

func (ss *SqlSupplier) Plugin() store.PluginStore

func (*SqlSupplier) Post

func (ss *SqlSupplier) Post() store.PostStore

func (*SqlSupplier) Preference

func (ss *SqlSupplier) Preference() store.PreferenceStore

func (*SqlSupplier) Reaction

func (ss *SqlSupplier) Reaction() store.ReactionStore

func (*SqlSupplier) RemoveColumnIfExists

func (ss *SqlSupplier) RemoveColumnIfExists(tableName string, columnName string) bool

func (*SqlSupplier) RemoveIndexIfExists

func (ss *SqlSupplier) RemoveIndexIfExists(indexName string, tableName string) bool

func (*SqlSupplier) RemoveTableIfExists

func (ss *SqlSupplier) RemoveTableIfExists(tableName string) bool

func (*SqlSupplier) RenameColumnIfExists

func (ss *SqlSupplier) RenameColumnIfExists(tableName string, oldColumnName string, newColumnName string, colType string) bool

func (*SqlSupplier) Role

func (ss *SqlSupplier) Role() store.RoleStore

func (*SqlSupplier) Scheme

func (ss *SqlSupplier) Scheme() store.SchemeStore

func (*SqlSupplier) Session

func (ss *SqlSupplier) Session() store.SessionStore

func (*SqlSupplier) SetContext added in v5.22.0

func (ss *SqlSupplier) SetContext(context context.Context)

func (*SqlSupplier) Status

func (ss *SqlSupplier) Status() store.StatusStore

func (*SqlSupplier) System

func (ss *SqlSupplier) System() store.SystemStore

func (*SqlSupplier) Team

func (ss *SqlSupplier) Team() store.TeamStore

func (*SqlSupplier) TermsOfService

func (ss *SqlSupplier) TermsOfService() store.TermsOfServiceStore

func (*SqlSupplier) Token

func (ss *SqlSupplier) Token() store.TokenStore

func (*SqlSupplier) TotalMasterDbConnections

func (ss *SqlSupplier) TotalMasterDbConnections() int

func (*SqlSupplier) TotalReadDbConnections

func (ss *SqlSupplier) TotalReadDbConnections() int

func (*SqlSupplier) TotalSearchDbConnections

func (ss *SqlSupplier) TotalSearchDbConnections() int

func (*SqlSupplier) UnlockFromMaster

func (ss *SqlSupplier) UnlockFromMaster()

func (*SqlSupplier) User

func (ss *SqlSupplier) User() store.UserStore

func (*SqlSupplier) UserAccessToken

func (ss *SqlSupplier) UserAccessToken() store.UserAccessTokenStore

func (*SqlSupplier) UserTermsOfService

func (ss *SqlSupplier) UserTermsOfService() store.UserTermsOfServiceStore

func (*SqlSupplier) Webhook

func (ss *SqlSupplier) Webhook() store.WebhookStore

type SqlSupplierStores

type SqlSupplierStores struct {
	TermsOfService store.TermsOfServiceStore

	UserTermsOfService store.UserTermsOfServiceStore
	// contains filtered or unexported fields
}

type SqlSystemStore

type SqlSystemStore struct {
	SqlStore
}

func (SqlSystemStore) Get

func (SqlSystemStore) GetByName

func (s SqlSystemStore) GetByName(name string) (*model.System, *model.AppError)

func (SqlSystemStore) PermanentDeleteByName

func (s SqlSystemStore) PermanentDeleteByName(name string) (*model.System, *model.AppError)

func (SqlSystemStore) Save

func (s SqlSystemStore) Save(system *model.System) *model.AppError

func (SqlSystemStore) SaveOrUpdate

func (s SqlSystemStore) SaveOrUpdate(system *model.System) *model.AppError

func (SqlSystemStore) Update

func (s SqlSystemStore) Update(system *model.System) *model.AppError

type SqlTeamStore

type SqlTeamStore struct {
	SqlStore
}

func (SqlTeamStore) AnalyticsGetTeamCountForScheme

func (s SqlTeamStore) AnalyticsGetTeamCountForScheme(schemeId string) (int64, *model.AppError)

func (SqlTeamStore) AnalyticsPrivateTeamCount

func (s SqlTeamStore) AnalyticsPrivateTeamCount() (int64, *model.AppError)

func (SqlTeamStore) AnalyticsPublicTeamCount

func (s SqlTeamStore) AnalyticsPublicTeamCount() (int64, *model.AppError)

func (SqlTeamStore) AnalyticsTeamCount

func (s SqlTeamStore) AnalyticsTeamCount(includeDeleted bool) (int64, *model.AppError)

func (SqlTeamStore) ClearAllCustomRoleAssignments

func (s SqlTeamStore) ClearAllCustomRoleAssignments() *model.AppError

func (SqlTeamStore) ClearCaches

func (s SqlTeamStore) ClearCaches()

func (SqlTeamStore) Get

func (s SqlTeamStore) Get(id string) (*model.Team, *model.AppError)

func (SqlTeamStore) GetActiveMemberCount

func (s SqlTeamStore) GetActiveMemberCount(teamId string, restrictions *model.ViewUsersRestrictions) (int64, *model.AppError)

func (SqlTeamStore) GetAll

func (s SqlTeamStore) GetAll() ([]*model.Team, *model.AppError)

func (SqlTeamStore) GetAllForExportAfter

func (s SqlTeamStore) GetAllForExportAfter(limit int, afterId string) ([]*model.TeamForExport, *model.AppError)

func (SqlTeamStore) GetAllPage

func (s SqlTeamStore) GetAllPage(offset int, limit int) ([]*model.Team, *model.AppError)

func (SqlTeamStore) GetAllPrivateTeamListing

func (s SqlTeamStore) GetAllPrivateTeamListing() ([]*model.Team, *model.AppError)

func (SqlTeamStore) GetAllPrivateTeamPageListing

func (s SqlTeamStore) GetAllPrivateTeamPageListing(offset int, limit int) ([]*model.Team, *model.AppError)

func (SqlTeamStore) GetAllPublicTeamPageListing

func (s SqlTeamStore) GetAllPublicTeamPageListing(offset int, limit int) ([]*model.Team, *model.AppError)

func (SqlTeamStore) GetAllTeamListing

func (s SqlTeamStore) GetAllTeamListing() ([]*model.Team, *model.AppError)

func (SqlTeamStore) GetAllTeamPageListing

func (s SqlTeamStore) GetAllTeamPageListing(offset int, limit int) ([]*model.Team, *model.AppError)

func (SqlTeamStore) GetByInviteId

func (s SqlTeamStore) GetByInviteId(inviteId string) (*model.Team, *model.AppError)

func (SqlTeamStore) GetByName

func (s SqlTeamStore) GetByName(name string) (*model.Team, *model.AppError)

func (SqlTeamStore) GetByNames added in v5.22.0

func (s SqlTeamStore) GetByNames(names []string) ([]*model.Team, *model.AppError)

func (SqlTeamStore) GetChannelUnreadsForAllTeams

func (s SqlTeamStore) GetChannelUnreadsForAllTeams(excludeTeamId, userId string) ([]*model.ChannelUnread, *model.AppError)

func (SqlTeamStore) GetChannelUnreadsForTeam

func (s SqlTeamStore) GetChannelUnreadsForTeam(teamId, userId string) ([]*model.ChannelUnread, *model.AppError)

func (SqlTeamStore) GetMember

func (s SqlTeamStore) GetMember(teamId string, userId string) (*model.TeamMember, *model.AppError)

func (SqlTeamStore) GetMembers

func (s SqlTeamStore) GetMembers(teamId string, offset int, limit int, restrictions *model.ViewUsersRestrictions) ([]*model.TeamMember, *model.AppError)

func (SqlTeamStore) GetMembersByIds

func (s SqlTeamStore) GetMembersByIds(teamId string, userIds []string, restrictions *model.ViewUsersRestrictions) ([]*model.TeamMember, *model.AppError)

func (SqlTeamStore) GetTeamMembersForExport

func (s SqlTeamStore) GetTeamMembersForExport(userId string) ([]*model.TeamMemberForExport, *model.AppError)

func (SqlTeamStore) GetTeamsByScheme

func (s SqlTeamStore) GetTeamsByScheme(schemeId string, offset int, limit int) ([]*model.Team, *model.AppError)

func (SqlTeamStore) GetTeamsByUserId

func (s SqlTeamStore) GetTeamsByUserId(userId string) ([]*model.Team, *model.AppError)

func (SqlTeamStore) GetTeamsForUser

func (s SqlTeamStore) GetTeamsForUser(userId string) ([]*model.TeamMember, *model.AppError)

func (SqlTeamStore) GetTeamsForUserWithPagination

func (s SqlTeamStore) GetTeamsForUserWithPagination(userId string, page, perPage int) ([]*model.TeamMember, *model.AppError)

func (SqlTeamStore) GetTotalMemberCount

func (s SqlTeamStore) GetTotalMemberCount(teamId string, restrictions *model.ViewUsersRestrictions) (int64, *model.AppError)

func (SqlTeamStore) GetUserTeamIds

func (s SqlTeamStore) GetUserTeamIds(userID string, allowFromCache bool) ([]string, *model.AppError)

GetUserTeamIds get the team ids to which the user belongs to. allowFromCache parameter does not have any effect in this Store

func (SqlTeamStore) GroupSyncedTeamCount added in v5.22.0

func (s SqlTeamStore) GroupSyncedTeamCount() (int64, *model.AppError)

func (SqlTeamStore) InvalidateAllTeamIdsForUser

func (s SqlTeamStore) InvalidateAllTeamIdsForUser(userId string)

func (SqlTeamStore) MigrateTeamMembers

func (s SqlTeamStore) MigrateTeamMembers(fromTeamId string, fromUserId string) (map[string]string, *model.AppError)

This function does the Advanced Permissions Phase 2 migration for TeamMember objects. It performs the migration in batches as a single transaction per batch to ensure consistency but to also minimise execution time to avoid causing unnecessary table locks. **THIS FUNCTION SHOULD NOT BE USED FOR ANY OTHER PURPOSE.** Executing this function *after* the new Schemes functionality has been used on an installation will have unintended consequences.

func (SqlTeamStore) PermanentDelete

func (s SqlTeamStore) PermanentDelete(teamId string) *model.AppError

func (SqlTeamStore) RemoveAllMembersByTeam

func (s SqlTeamStore) RemoveAllMembersByTeam(teamId string) *model.AppError

func (SqlTeamStore) RemoveAllMembersByUser

func (s SqlTeamStore) RemoveAllMembersByUser(userId string) *model.AppError

func (SqlTeamStore) RemoveMember

func (s SqlTeamStore) RemoveMember(teamId string, userId string) *model.AppError

func (SqlTeamStore) ResetAllTeamSchemes

func (s SqlTeamStore) ResetAllTeamSchemes() *model.AppError

func (SqlTeamStore) Save

func (s SqlTeamStore) Save(team *model.Team) (*model.Team, *model.AppError)

Save adds the team to the database if a team with the same name does not already exist in the database. It returns the team added if the operation is successful.

func (SqlTeamStore) SaveMember

func (s SqlTeamStore) SaveMember(member *model.TeamMember, maxUsersPerTeam int) (*model.TeamMember, *model.AppError)

SaveMember adds a team member using the team Id of the member if the member does not already exist in the database and if the number of existing team members are less than the maximum allowed users per team. It returns the team member added if the operation is successful.

func (SqlTeamStore) SearchAll

func (s SqlTeamStore) SearchAll(term string) ([]*model.Team, *model.AppError)

func (SqlTeamStore) SearchAllPaged

func (s SqlTeamStore) SearchAllPaged(term string, page int, perPage int) ([]*model.Team, int64, *model.AppError)

SearchAllPaged returns a teams list and the total count of teams that matched the search.

func (SqlTeamStore) SearchOpen

func (s SqlTeamStore) SearchOpen(term string) ([]*model.Team, *model.AppError)

func (SqlTeamStore) SearchPrivate

func (s SqlTeamStore) SearchPrivate(term string) ([]*model.Team, *model.AppError)

func (SqlTeamStore) Update

func (s SqlTeamStore) Update(team *model.Team) (*model.Team, *model.AppError)

Update updates the details of the team passed as the parameter using the team Id if the team exists in the database. It returns the updated team if the operation is successful.

func (SqlTeamStore) UpdateLastTeamIconUpdate

func (s SqlTeamStore) UpdateLastTeamIconUpdate(teamId string, curTime int64) *model.AppError

func (SqlTeamStore) UpdateMember

func (s SqlTeamStore) UpdateMember(member *model.TeamMember) (*model.TeamMember, *model.AppError)

UpdateMember updates the team member if the team member exists in the database. It returns the updated team member if the operation is successful.

func (SqlTeamStore) UpdateMembersRole added in v5.20.0

func (s SqlTeamStore) UpdateMembersRole(teamID string, userIDs []string) *model.AppError

func (SqlTeamStore) UserBelongsToTeams

func (s SqlTeamStore) UserBelongsToTeams(userId string, teamIds []string) (bool, *model.AppError)

type SqlTermsOfServiceStore

type SqlTermsOfServiceStore struct {
	SqlStore
	// contains filtered or unexported fields
}

func (SqlTermsOfServiceStore) Get

func (s SqlTermsOfServiceStore) Get(id string, allowFromCache bool) (*model.TermsOfService, *model.AppError)

func (SqlTermsOfServiceStore) GetLatest

func (s SqlTermsOfServiceStore) GetLatest(allowFromCache bool) (*model.TermsOfService, *model.AppError)

func (SqlTermsOfServiceStore) Save

type SqlTokenStore

type SqlTokenStore struct {
	SqlStore
}

func (SqlTokenStore) Cleanup

func (s SqlTokenStore) Cleanup()

func (SqlTokenStore) Delete

func (s SqlTokenStore) Delete(token string) *model.AppError

func (SqlTokenStore) GetByToken

func (s SqlTokenStore) GetByToken(tokenString string) (*model.Token, *model.AppError)

func (SqlTokenStore) RemoveAllTokensByType

func (s SqlTokenStore) RemoveAllTokensByType(tokenType string) *model.AppError

func (SqlTokenStore) Save

func (s SqlTokenStore) Save(token *model.Token) *model.AppError

type SqlUserAccessTokenStore

type SqlUserAccessTokenStore struct {
	SqlStore
}

func (SqlUserAccessTokenStore) Delete

func (s SqlUserAccessTokenStore) Delete(tokenId string) *model.AppError

func (SqlUserAccessTokenStore) DeleteAllForUser

func (s SqlUserAccessTokenStore) DeleteAllForUser(userId string) *model.AppError

func (SqlUserAccessTokenStore) Get

func (SqlUserAccessTokenStore) GetAll

func (s SqlUserAccessTokenStore) GetAll(offset, limit int) ([]*model.UserAccessToken, *model.AppError)

func (SqlUserAccessTokenStore) GetByToken

func (s SqlUserAccessTokenStore) GetByToken(tokenString string) (*model.UserAccessToken, *model.AppError)

func (SqlUserAccessTokenStore) GetByUser

func (s SqlUserAccessTokenStore) GetByUser(userId string, offset, limit int) ([]*model.UserAccessToken, *model.AppError)

func (SqlUserAccessTokenStore) Save

func (SqlUserAccessTokenStore) Search

func (SqlUserAccessTokenStore) UpdateTokenDisable

func (s SqlUserAccessTokenStore) UpdateTokenDisable(tokenId string) *model.AppError

func (SqlUserAccessTokenStore) UpdateTokenEnable

func (s SqlUserAccessTokenStore) UpdateTokenEnable(tokenId string) *model.AppError

type SqlUserStore

type SqlUserStore struct {
	SqlStore
	// contains filtered or unexported fields
}

func (SqlUserStore) AnalyticsActiveCount

func (us SqlUserStore) AnalyticsActiveCount(timePeriod int64, options model.UserCountOptions) (int64, *model.AppError)

func (SqlUserStore) AnalyticsGetInactiveUsersCount

func (us SqlUserStore) AnalyticsGetInactiveUsersCount() (int64, *model.AppError)

func (SqlUserStore) AnalyticsGetSystemAdminCount

func (us SqlUserStore) AnalyticsGetSystemAdminCount() (int64, *model.AppError)

func (SqlUserStore) AutocompleteUsersInChannel added in v5.22.0

func (us SqlUserStore) AutocompleteUsersInChannel(teamId, channelId, term string, options *model.UserSearchOptions) (*model.UserAutocompleteInChannel, *model.AppError)

func (SqlUserStore) ClearAllCustomRoleAssignments

func (us SqlUserStore) ClearAllCustomRoleAssignments() *model.AppError

func (SqlUserStore) ClearCaches

func (us SqlUserStore) ClearCaches()

func (SqlUserStore) Count

func (us SqlUserStore) Count(options model.UserCountOptions) (int64, *model.AppError)

func (SqlUserStore) DeactivateGuests

func (us SqlUserStore) DeactivateGuests() ([]string, *model.AppError)

func (SqlUserStore) DemoteUserToGuest

func (us SqlUserStore) DemoteUserToGuest(userId string) *model.AppError

func (SqlUserStore) Get

func (us SqlUserStore) Get(id string) (*model.User, *model.AppError)

func (SqlUserStore) GetAll

func (us SqlUserStore) GetAll() ([]*model.User, *model.AppError)

func (SqlUserStore) GetAllAfter

func (us SqlUserStore) GetAllAfter(limit int, afterId string) ([]*model.User, *model.AppError)

func (SqlUserStore) GetAllProfiles

func (us SqlUserStore) GetAllProfiles(options *model.UserGetOptions) ([]*model.User, *model.AppError)

func (SqlUserStore) GetAllProfilesInChannel

func (us SqlUserStore) GetAllProfilesInChannel(channelId string, allowFromCache bool) (map[string]*model.User, *model.AppError)

func (SqlUserStore) GetAllUsingAuthService

func (us SqlUserStore) GetAllUsingAuthService(authService string) ([]*model.User, *model.AppError)

func (SqlUserStore) GetAnyUnreadPostCountForChannel

func (us SqlUserStore) GetAnyUnreadPostCountForChannel(userId string, channelId string) (int64, *model.AppError)

func (SqlUserStore) GetByAuth

func (us SqlUserStore) GetByAuth(authData *string, authService string) (*model.User, *model.AppError)

func (SqlUserStore) GetByEmail

func (us SqlUserStore) GetByEmail(email string) (*model.User, *model.AppError)

func (SqlUserStore) GetByUsername

func (us SqlUserStore) GetByUsername(username string) (*model.User, *model.AppError)

func (SqlUserStore) GetChannelGroupUsers

func (us SqlUserStore) GetChannelGroupUsers(channelID string) ([]*model.User, *model.AppError)

func (SqlUserStore) GetEtagForAllProfiles

func (us SqlUserStore) GetEtagForAllProfiles() string

func (SqlUserStore) GetEtagForProfiles

func (us SqlUserStore) GetEtagForProfiles(teamId string) string

func (SqlUserStore) GetEtagForProfilesNotInTeam

func (us SqlUserStore) GetEtagForProfilesNotInTeam(teamId string) string

func (SqlUserStore) GetForLogin

func (us SqlUserStore) GetForLogin(loginId string, allowSignInWithUsername, allowSignInWithEmail bool) (*model.User, *model.AppError)

func (SqlUserStore) GetNewUsersForTeam

func (us SqlUserStore) GetNewUsersForTeam(teamId string, offset, limit int, viewRestrictions *model.ViewUsersRestrictions) ([]*model.User, *model.AppError)

func (SqlUserStore) GetProfileByGroupChannelIdsForUser

func (us SqlUserStore) GetProfileByGroupChannelIdsForUser(userId string, channelIds []string) (map[string][]*model.User, *model.AppError)

func (SqlUserStore) GetProfileByIds

func (us SqlUserStore) GetProfileByIds(userIds []string, options *store.UserGetByIdsOpts, _ bool) ([]*model.User, *model.AppError)

func (SqlUserStore) GetProfiles

func (us SqlUserStore) GetProfiles(options *model.UserGetOptions) ([]*model.User, *model.AppError)

func (SqlUserStore) GetProfilesByUsernames

func (us SqlUserStore) GetProfilesByUsernames(usernames []string, viewRestrictions *model.ViewUsersRestrictions) ([]*model.User, *model.AppError)

func (SqlUserStore) GetProfilesInChannel

func (us SqlUserStore) GetProfilesInChannel(channelId string, offset int, limit int) ([]*model.User, *model.AppError)

func (SqlUserStore) GetProfilesInChannelByStatus

func (us SqlUserStore) GetProfilesInChannelByStatus(channelId string, offset int, limit int) ([]*model.User, *model.AppError)

func (SqlUserStore) GetProfilesNotInChannel

func (us SqlUserStore) GetProfilesNotInChannel(teamId string, channelId string, groupConstrained bool, offset int, limit int, viewRestrictions *model.ViewUsersRestrictions) ([]*model.User, *model.AppError)

func (SqlUserStore) GetProfilesNotInTeam

func (us SqlUserStore) GetProfilesNotInTeam(teamId string, groupConstrained bool, offset int, limit int, viewRestrictions *model.ViewUsersRestrictions) ([]*model.User, *model.AppError)

func (SqlUserStore) GetProfilesWithoutTeam

func (us SqlUserStore) GetProfilesWithoutTeam(options *model.UserGetOptions) ([]*model.User, *model.AppError)

func (SqlUserStore) GetRecentlyActiveUsersForTeam

func (us SqlUserStore) GetRecentlyActiveUsersForTeam(teamId string, offset, limit int, viewRestrictions *model.ViewUsersRestrictions) ([]*model.User, *model.AppError)

func (SqlUserStore) GetSystemAdminProfiles

func (us SqlUserStore) GetSystemAdminProfiles() (map[string]*model.User, *model.AppError)

func (SqlUserStore) GetTeamGroupUsers

func (us SqlUserStore) GetTeamGroupUsers(teamID string) ([]*model.User, *model.AppError)

func (SqlUserStore) GetUnreadCount

func (us SqlUserStore) GetUnreadCount(userId string) (int64, *model.AppError)

func (SqlUserStore) GetUnreadCountForChannel

func (us SqlUserStore) GetUnreadCountForChannel(userId string, channelId string) (int64, *model.AppError)

func (SqlUserStore) GetUsersBatchForIndexing

func (us SqlUserStore) GetUsersBatchForIndexing(startTime, endTime int64, limit int) ([]*model.UserForIndexing, *model.AppError)

func (SqlUserStore) InferSystemInstallDate

func (us SqlUserStore) InferSystemInstallDate() (int64, *model.AppError)

func (SqlUserStore) InvalidateProfileCacheForUser added in v5.20.0

func (us SqlUserStore) InvalidateProfileCacheForUser(userId string)

func (SqlUserStore) InvalidateProfilesInChannelCache

func (us SqlUserStore) InvalidateProfilesInChannelCache(channelId string)

func (SqlUserStore) InvalidateProfilesInChannelCacheByUser

func (us SqlUserStore) InvalidateProfilesInChannelCacheByUser(userId string)

func (SqlUserStore) PermanentDelete

func (us SqlUserStore) PermanentDelete(userId string) *model.AppError

func (SqlUserStore) PromoteGuestToUser

func (us SqlUserStore) PromoteGuestToUser(userId string) *model.AppError

func (SqlUserStore) ResetLastPictureUpdate

func (us SqlUserStore) ResetLastPictureUpdate(userId string) *model.AppError

func (SqlUserStore) Save

func (us SqlUserStore) Save(user *model.User) (*model.User, *model.AppError)

func (SqlUserStore) Search

func (us SqlUserStore) Search(teamId string, term string, options *model.UserSearchOptions) ([]*model.User, *model.AppError)

func (SqlUserStore) SearchInChannel

func (us SqlUserStore) SearchInChannel(channelId string, term string, options *model.UserSearchOptions) ([]*model.User, *model.AppError)

func (SqlUserStore) SearchNotInChannel

func (us SqlUserStore) SearchNotInChannel(teamId string, channelId string, term string, options *model.UserSearchOptions) ([]*model.User, *model.AppError)

func (SqlUserStore) SearchNotInTeam

func (us SqlUserStore) SearchNotInTeam(notInTeamId string, term string, options *model.UserSearchOptions) ([]*model.User, *model.AppError)

func (SqlUserStore) SearchWithoutTeam

func (us SqlUserStore) SearchWithoutTeam(term string, options *model.UserSearchOptions) ([]*model.User, *model.AppError)

func (SqlUserStore) Update

func (us SqlUserStore) Update(user *model.User, trustedUpdateData bool) (*model.UserUpdate, *model.AppError)

func (SqlUserStore) UpdateAuthData

func (us SqlUserStore) UpdateAuthData(userId string, service string, authData *string, email string, resetMfa bool) (string, *model.AppError)

func (SqlUserStore) UpdateFailedPasswordAttempts

func (us SqlUserStore) UpdateFailedPasswordAttempts(userId string, attempts int) *model.AppError

func (SqlUserStore) UpdateLastPictureUpdate

func (us SqlUserStore) UpdateLastPictureUpdate(userId string) *model.AppError

func (SqlUserStore) UpdateMfaActive

func (us SqlUserStore) UpdateMfaActive(userId string, active bool) *model.AppError

func (SqlUserStore) UpdateMfaSecret

func (us SqlUserStore) UpdateMfaSecret(userId, secret string) *model.AppError

func (SqlUserStore) UpdatePassword

func (us SqlUserStore) UpdatePassword(userId, hashedPassword string) *model.AppError

func (SqlUserStore) UpdateUpdateAt

func (us SqlUserStore) UpdateUpdateAt(userId string) (int64, *model.AppError)

func (SqlUserStore) VerifyEmail

func (us SqlUserStore) VerifyEmail(userId, email string) (string, *model.AppError)

type SqlUserTermsOfServiceStore

type SqlUserTermsOfServiceStore struct {
	SqlStore
}

func (SqlUserTermsOfServiceStore) Delete

func (s SqlUserTermsOfServiceStore) Delete(userId, termsOfServiceId string) *model.AppError

func (SqlUserTermsOfServiceStore) GetByUser

func (SqlUserTermsOfServiceStore) Save

type SqlWebhookStore

type SqlWebhookStore struct {
	SqlStore
	// contains filtered or unexported fields
}

func (SqlWebhookStore) AnalyticsIncomingCount

func (s SqlWebhookStore) AnalyticsIncomingCount(teamId string) (int64, *model.AppError)

func (SqlWebhookStore) AnalyticsOutgoingCount

func (s SqlWebhookStore) AnalyticsOutgoingCount(teamId string) (int64, *model.AppError)

func (SqlWebhookStore) ClearCaches

func (s SqlWebhookStore) ClearCaches()

func (SqlWebhookStore) DeleteIncoming

func (s SqlWebhookStore) DeleteIncoming(webhookId string, time int64) *model.AppError

func (SqlWebhookStore) DeleteOutgoing

func (s SqlWebhookStore) DeleteOutgoing(webhookId string, time int64) *model.AppError

func (SqlWebhookStore) GetIncoming

func (s SqlWebhookStore) GetIncoming(id string, allowFromCache bool) (*model.IncomingWebhook, *model.AppError)

func (SqlWebhookStore) GetIncomingByChannel

func (s SqlWebhookStore) GetIncomingByChannel(channelId string) ([]*model.IncomingWebhook, *model.AppError)

func (SqlWebhookStore) GetIncomingByTeam

func (s SqlWebhookStore) GetIncomingByTeam(teamId string, offset, limit int) ([]*model.IncomingWebhook, *model.AppError)

func (SqlWebhookStore) GetIncomingByTeamByUser

func (s SqlWebhookStore) GetIncomingByTeamByUser(teamId string, userId string, offset, limit int) ([]*model.IncomingWebhook, *model.AppError)

func (SqlWebhookStore) GetIncomingList

func (s SqlWebhookStore) GetIncomingList(offset, limit int) ([]*model.IncomingWebhook, *model.AppError)

func (SqlWebhookStore) GetIncomingListByUser

func (s SqlWebhookStore) GetIncomingListByUser(userId string, offset, limit int) ([]*model.IncomingWebhook, *model.AppError)

func (SqlWebhookStore) GetOutgoing

func (s SqlWebhookStore) GetOutgoing(id string) (*model.OutgoingWebhook, *model.AppError)

func (SqlWebhookStore) GetOutgoingByChannel

func (s SqlWebhookStore) GetOutgoingByChannel(channelId string, offset, limit int) ([]*model.OutgoingWebhook, *model.AppError)

func (SqlWebhookStore) GetOutgoingByChannelByUser

func (s SqlWebhookStore) GetOutgoingByChannelByUser(channelId string, userId string, offset, limit int) ([]*model.OutgoingWebhook, *model.AppError)

func (SqlWebhookStore) GetOutgoingByTeam

func (s SqlWebhookStore) GetOutgoingByTeam(teamId string, offset, limit int) ([]*model.OutgoingWebhook, *model.AppError)

func (SqlWebhookStore) GetOutgoingByTeamByUser

func (s SqlWebhookStore) GetOutgoingByTeamByUser(teamId string, userId string, offset, limit int) ([]*model.OutgoingWebhook, *model.AppError)

func (SqlWebhookStore) GetOutgoingList

func (s SqlWebhookStore) GetOutgoingList(offset, limit int) ([]*model.OutgoingWebhook, *model.AppError)

func (SqlWebhookStore) GetOutgoingListByUser

func (s SqlWebhookStore) GetOutgoingListByUser(userId string, offset, limit int) ([]*model.OutgoingWebhook, *model.AppError)

func (SqlWebhookStore) InvalidateWebhookCache

func (s SqlWebhookStore) InvalidateWebhookCache(webhookId string)

func (SqlWebhookStore) PermanentDeleteIncomingByChannel

func (s SqlWebhookStore) PermanentDeleteIncomingByChannel(channelId string) *model.AppError

func (SqlWebhookStore) PermanentDeleteIncomingByUser

func (s SqlWebhookStore) PermanentDeleteIncomingByUser(userId string) *model.AppError

func (SqlWebhookStore) PermanentDeleteOutgoingByChannel

func (s SqlWebhookStore) PermanentDeleteOutgoingByChannel(channelId string) *model.AppError

func (SqlWebhookStore) PermanentDeleteOutgoingByUser

func (s SqlWebhookStore) PermanentDeleteOutgoingByUser(userId string) *model.AppError

func (SqlWebhookStore) SaveIncoming

func (SqlWebhookStore) SaveOutgoing

func (SqlWebhookStore) UpdateIncoming

func (SqlWebhookStore) UpdateOutgoing

type TraceOnAdapter added in v5.20.0

type TraceOnAdapter struct{}

func (*TraceOnAdapter) Printf added in v5.20.0

func (t *TraceOnAdapter) Printf(format string, v ...interface{})

type UserWithChannel

type UserWithChannel struct {
	model.User
	ChannelId string
}

type UserWithLastActivityAt

type UserWithLastActivityAt struct {
	model.User
	LastActivityAt int64
}

Jump to

Keyboard shortcuts

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