likyh commented on code in PR #3287:
URL: https://github.com/apache/incubator-devlake/pull/3287#discussion_r984200690


##########
config-ui/src/pages/blueprints/blueprint-settings.jsx:
##########
@@ -672,7 +674,10 @@ const BlueprintSettings = (props) => {
                 [Providers.JIRA].includes(c.plugin)
                   ? getJiraMappedBoards(
                       c.scope.map((s) => s.options?.boardId),
-                      allJiraResources?.boards
+                      [
+                        ...allJiraResources?.boards,
+                        ...c.scope.map((s) => s.options)

Review Comment:
   this change for what?



##########
config-ui/src/hooks/useDataScopesManager.jsx:
##########
@@ -458,14 +458,15 @@ function useDataScopesManager({
     (boardIds = [], boardListItems = []) => {
       return boardIds.map((bId, sIdx) => {
         const boardObject = boardListItems.find(
-          (apiBoard) => Number(apiBoard.id) === Number(bId)
+          (apiBoard) =>
+            Number(apiBoard.id) === Number(bId) || +apiBoard.boardId === +bId

Review Comment:
   what difference between these 2 conditions?



##########
config-ui/src/pages/blueprints/blueprint-settings.jsx:
##########
@@ -897,35 +905,64 @@ const BlueprintSettings = (props) => {
       scopeConnection?.connectionId &&
       activeBlueprint?.mode === BlueprintMode.NORMAL
     ) {
-      fetchAllResources(
-        scopeConnection?.connectionId,
-        (jiraResourcesResponse) => {
-          setConnections((Cs) =>
-            Cs.map(
-              (c) =>
-                new DataScopeConnection({
-                  ...c,
-                  boardsList: jiraResourcesResponse?.boards
-                    ? getJiraMappedBoards(
-                        c.boardIds,
-                        jiraResourcesResponse?.boards
-                      )
-                    : []
-                })
-            )
+      fetchIssueTypes()
+      fetchFields()

Review Comment:
   why fetch these two when fetch boards?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to