This is an automated email from the ASF dual-hosted git repository.
abeizn pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-devlake.git
The following commit(s) were added to refs/heads/main by this push:
new dc7d08c22 fix: Assign proper value to the column `type` of table
`boards` (#5497)
dc7d08c22 is described below
commit dc7d08c2212628007392082eb97a8d482558b55b
Author: Liang Zhang <[email protected]>
AuthorDate: Thu Jun 15 15:01:15 2023 +0800
fix: Assign proper value to the column `type` of table `boards` (#5497)
* fix: setting boards.type
* fix: unit test
---
backend/plugins/customize/service/service.go | 2 +-
backend/plugins/tapd/api/blueprint_v200.go | 1 +
backend/plugins/tapd/api/blueprint_v200_test.go | 1 +
backend/plugins/tapd/tasks/workspace_converter.go | 1 +
4 files changed, 4 insertions(+), 1 deletion(-)
diff --git a/backend/plugins/customize/service/service.go
b/backend/plugins/customize/service/service.go
index 905a3cd74..911c93928 100644
--- a/backend/plugins/customize/service/service.go
+++ b/backend/plugins/customize/service/service.go
@@ -167,7 +167,7 @@ func (s *Service) SaveBoard(boardId, boardName string)
errors.Error {
Id: boardId,
},
Name: boardName,
- Type: "kanban",
+ Type: "csv",
})
}
diff --git a/backend/plugins/tapd/api/blueprint_v200.go
b/backend/plugins/tapd/api/blueprint_v200.go
index 77da4c5d7..513eb28b8 100644
--- a/backend/plugins/tapd/api/blueprint_v200.go
+++ b/backend/plugins/tapd/api/blueprint_v200.go
@@ -109,6 +109,7 @@ func makeScopesV200(
Id:
didgen.NewDomainIdGenerator(&models.TapdWorkspace{}).Generate(tapdWorkspace.ConnectionId,
tapdWorkspace.Id),
},
Name: tapdWorkspace.Name,
+ Type: "scrum",
}
scopes = append(scopes, domainBoard)
}
diff --git a/backend/plugins/tapd/api/blueprint_v200_test.go
b/backend/plugins/tapd/api/blueprint_v200_test.go
index 0acdfff79..8d6273d28 100644
--- a/backend/plugins/tapd/api/blueprint_v200_test.go
+++ b/backend/plugins/tapd/api/blueprint_v200_test.go
@@ -70,6 +70,7 @@ func TestMakeDataSourcePipelinePlanV200(t *testing.T) {
Id: "tapd:TapdWorkspace:1:10",
},
Name: "a",
+ Type: "scrum",
}
expectScopes = append(expectScopes, tapdBoard)
diff --git a/backend/plugins/tapd/tasks/workspace_converter.go
b/backend/plugins/tapd/tasks/workspace_converter.go
index b6f616c0f..c887c0e0a 100644
--- a/backend/plugins/tapd/tasks/workspace_converter.go
+++ b/backend/plugins/tapd/tasks/workspace_converter.go
@@ -42,6 +42,7 @@ func ConvertWorkspace(taskCtx plugin.SubTaskContext)
errors.Error {
Id:
getWorkspaceIdGen().Generate(workspace.ConnectionId, workspace.Id),
},
Name: workspace.Name,
+ Type: "scrum",
Url: fmt.Sprintf("%s/%d", "https://tapd.cn", workspace.Id),
}