Skip to content

Commit

Permalink
fix(rest): show linked project in project summay tab
Browse files Browse the repository at this point in the history
Signed-off-by: Nikesh kumar <[email protected]>
  • Loading branch information
Nikesh kumar committed Jul 10, 2023
1 parent 0e75910 commit f29de2b
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions rest/resource-server/src/docs/asciidoc/projects.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -738,3 +738,4 @@ include::{snippets}/should_document_get_project_report/curl-request.adoc[]

===== Example response
include::{snippets}/should_document_get_project_report/http-response.adoc[]

Original file line number Diff line number Diff line change
Expand Up @@ -593,6 +593,7 @@ public Project convertToEmbeddedProject(Project project) {
embeddedProject.setClearingState(project.getClearingState());
embeddedProject.setVersion(project.getVersion());
embeddedProject.setVisbility(project.getVisbility());
embeddedProject.setBusinessUnit(project.getBusinessUnit());
embeddedProject.setType(null);
return embeddedProject;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,7 @@
import java.util.HashMap;
import java.util.HashSet;
import java.util.List;
import java.util.ListIterator;
import java.util.Map;
import java.util.Map.Entry;
import java.util.Objects;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -613,6 +613,7 @@ public void should_document_get_usedbyresource_for_project() throws Exception {
responseFields(
subsectionWithPath("_embedded.sw360:projects.[]name").description("The name of the project"),
subsectionWithPath("_embedded.sw360:projects.[]version").description("The project version"),
subsectionWithPath("_embedded.sw360:projects.[]businessUnit").description("The business unit this project belongs to"),
subsectionWithPath("_embedded.sw360:projects.[]projectType").description("The project type, possible values are: " + Arrays.asList(ProjectType.values())),
subsectionWithPath("_embedded.sw360:projects").description("An array of <<resources-projects, Projects resources>>"),
subsectionWithPath("_links").description("<<resources-index-links,Links>> to other resources")
Expand Down Expand Up @@ -1835,4 +1836,5 @@ public void should_document_import_cyclonedx_on_project() throws Exception {
.header("Authorization", "Bearer " + accessToken);
this.mockMvc.perform(builder).andExpect(status().isOk()).andDo(this.documentationHandler.document());
}

}

0 comments on commit f29de2b

Please sign in to comment.