示例#1
0
        public void OnPost(int id, int boardId, int userId, bool backlog)
        {
            Debug.WriteLine("Post");

            UserStory          = boards.GetUserStory(id, boardId, backlog);
            UserStory.ColumnId = userId;
            boards.UpdateUserStory(UserStory, boardId, backlog);
        }
        public IActionResult OnGet(int id, int boardId, bool backlog)
        {
            IsBacklog = backlog;

            UserStory = boards.GetUserStory(id, boardId, backlog);

            return(Page());
        }
示例#3
0
        // For refreshing the page when moving a card
        public IActionResult OnGetColumn(int boardId, int userStoryId, int column, bool backlog)
        {
            UserStory updated = boards.GetUserStory(userStoryId, boardId, backlog);

            int result = updated.ColumnId + column;

            if (result > -1 && result < Board.Columns)
            {
                updated.ColumnId = result; // F**K THIS
                if (backlog)
                {
                    updated.Priority = result;          // IF WE ARE IN THE BACKLOG, REMEMBER TO UPDATE THE PRIORITY AS WELL, AS THAT'S WHAT THE COLUMNS REPRESENT.
                }
                boards.UpdateUserStory(updated, boards.GetBoard(boardId).Id, backlog);
            }

            return(Page());
        }
示例#4
0
        public void OnGet(int id, int boardId, bool backlog)
        {
            IsBacklog     = backlog;
            ColumnsToDraw = backlog ? Backlog.Columns : Board.Columns; // If backlog is true, use backlog columns, else use board columns. This is just shorthand for if/else.

            this.boardId = boardId;

            UserStories = boards.GetUserStories(boardId);
            UserStory   = boards.GetUserStory(id, boardId, backlog);
        }
示例#5
0
        public void OnGet(int id, int boardId, bool backlog)
        {
            IsBacklog = backlog;

            UserStory = boards.GetUserStory(id, boardId, backlog);
        }