Hi,
I'm trying to get a list of all the boards related to a specific project by using the following line:
List<Board> sourceProjectBoards = boardManager.getBoardsForProject(sourceProject.getId())
I'm getting the following error:
Error: java.lang.NullPointerException: Cannot invoke method getBoardsForProject() on null object
I understand that I need to get the boardManager object, but I can't figure out how to do that.
Initially I thought it will be similar to how I get projectManager or workflowManager, etc. Using the ComponentAccessor.
But it seemed to be not the case in this one.
Any advice?
Hi
It is too late but the answer is
ComponentAccessor.getComponent(BoardManager.class);
Hmm...My understanding is that projects and boards are not linked directly.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Carlos Garcia Navarro to my understanding there has to be some relationship. As when I'm navigating to a particular project, I get on the top left corner a list of all the boards that are associated with this project.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.