Open ariesbrylle-bms opened 3 years ago
When I console log the board data, the map object has the items and its column item.
Hi @TacticCoder, really need your help here. Thank you.
Please post your code.
Please post your code.
@TacticCoder
This is how I initialized my boardRepository
const boardRepository = new BoardRepository([]);
This is how I update the data
useEffect(() => { if (boardData.length > 0) { console.log("should update data"); boardRepository.updateData(boardData); } }, [boardData]);
And this is my component {boardData.length > 0 ? ( <Board boardRepository={boardRepository} open={(data) => { console.log(data); }} onDragEnd={(srcColumnId, destColumnId, draggedItem) => { console.log(srcColumnId, destColumnId, draggedItem.attributes.id); // console.log(state.info_boards[destColumnId - 1]); }} boardBackground={CONSTANTS.OFFICIAL_BG_COLOR} cardNameTextColor={CONSTANTS.PRIMARY_COLOR} cardIconColor={CONSTANTS.PRIMARY_COLOR} badgeBackgroundColor={CONSTANTS.PRIMARY_COLOR} columnNameTextColor={CONSTANTS.PRIMARY_COLOR} emptyIconColor={CONSTANTS.PRIMARY_COLOR} emptyText="No Issue on this Board." ref={boardRef} /> ) : ( <View style={{ height: "100%" }}>
</View>
)}
Were you able to replicate the issue @TacticCoder ? :)
hi @TacticCoder same issue , Have you solved this problem yet ? @ariesbrylle-bms
hi @TacticCoder same issue , Have you solved this problem yet ? @ariesbrylle-bms
No, I wasn't able to solve the problem yet.
If I initialized the board like this
<Board boardRepository={new BoardRepository(boardData)} open={(data) => { }}
/>
I experience this issue https://github.com/bear-junior/react-native-draganddrop-board/issues/19
However, I used my code above (comments above) I experience this issue.
Hello, any help please :) Thank you. I really can't figure out what's wrong with it :)
Here's how to replicate the issue:
Go to board screen: Board is successfully loaded.
Leave the board screen.
Go back again to the board screen: Board is not loaded.
But once I reloaded the app, it's working again.
Here's my code for the creation and updating of the board.
// create let boardRepository = new BoardRepository(); or let boardRepository = new BoardRepository([]);
// update useEffect(() => { if (boardData.length > 0) { console.log("should update data"); boardRepository.updateData(boardData); } }, [boardData]);
Note: it always logged "should update data" so it means that there's data that should be loaded.