bc37e97ae9
* Applying migration changes * Fixing linter erros * Restoring userID * Updated user id length * Update server/app/category_boards.go * Skiped creating categories for boards belonging to DMs * Handled private group messages as well * fix sql error for insert_at * fix timestamp parsing Co-authored-by: Mattermod <mattermod@users.noreply.github.com> Co-authored-by: Harshil Sharma <harshilsharma63@gmail.com> Co-authored-by: Doug Lauder <wiggin77@warpmail.net>
27 lines
654 B
Go
27 lines
654 B
Go
package app
|
|
|
|
import "github.com/mattermost/focalboard/server/model"
|
|
|
|
func (a *App) GetUserCategoryBoards(userID, teamID string) ([]model.CategoryBoards, error) {
|
|
return a.store.GetUserCategoryBoards(userID, teamID)
|
|
}
|
|
|
|
func (a *App) AddUpdateUserCategoryBoard(teamID, userID, categoryID, boardID string) error {
|
|
err := a.store.AddUpdateCategoryBoard(userID, categoryID, boardID)
|
|
if err != nil {
|
|
return err
|
|
}
|
|
|
|
a.blockChangeNotifier.Enqueue(func() error {
|
|
a.wsAdapter.BroadcastCategoryBoardChange(
|
|
teamID,
|
|
userID,
|
|
model.BoardCategoryWebsocketData{
|
|
BoardID: boardID,
|
|
CategoryID: categoryID,
|
|
})
|
|
return nil
|
|
})
|
|
|
|
return nil
|
|
}
|