Skip to content

Commit

Permalink
feat: reverted changes in api and mapper (#22)
Browse files Browse the repository at this point in the history
  • Loading branch information
JordenReuter authored May 8, 2024
1 parent 7ecd4c9 commit ea3066c
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -125,10 +125,10 @@ default void createThemeAfter(@MappingTarget ThemeDTO target, Theme themeInfo, S
target.setProperties(String.valueOf(themeInfo.getProperties()));
}
if (target.getFaviconUrl() == null) {
target.setFaviconUrl(path.replace("/load", "") + "/themes/" + target.getName() + "/favicon");
target.setFaviconUrl(path + "/themes/" + target.getName() + "/favicon");
}
if (target.getLogoUrl() == null) {
target.setLogoUrl(path.replace("/load", "") + "/themes/" + target.getName() + "/logo");
target.setLogoUrl(path + "/themes/" + target.getName() + "/logo");
}
}

Expand Down
2 changes: 1 addition & 1 deletion src/main/openapi/openapi-bff.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ servers:
- url: http://onecx-shell-bff:8080/

paths:
/workspaceConfig/load:
/workspaceConfig:
post:
tags:
- "WorkspaceConfig"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -295,7 +295,7 @@ void loadWorkspaceConfigByBaseUrlTest() {
.header(APM_HEADER_PARAM, ADMIN)
.contentType(APPLICATION_JSON)
.body(new LoadWorkspaceConfigRequestDTO().path("/w1Url"))
.post("load")
.post()
.then()
.statusCode(Response.Status.OK.getStatusCode())
.contentType(APPLICATION_JSON)
Expand Down Expand Up @@ -326,7 +326,7 @@ void loadWorkspaceConfig_MissingBaseUrlTest() {
.header(APM_HEADER_PARAM, ADMIN)
.contentType(APPLICATION_JSON)
.body(new LoadWorkspaceConfigRequestDTO())
.post("load")
.post()
.then()
.statusCode(BAD_REQUEST.getStatusCode())
.contentType(APPLICATION_JSON)
Expand All @@ -352,7 +352,7 @@ void loadWorkspaceConfig_WorkspaceNotFoundTest() {
.header(APM_HEADER_PARAM, ADMIN)
.contentType(APPLICATION_JSON)
.body(new LoadWorkspaceConfigRequestDTO().path("/w1Url"))
.post("load")
.post()
.then()
.statusCode(NOT_FOUND.getStatusCode());
Assertions.assertNotNull(output);
Expand Down Expand Up @@ -395,7 +395,7 @@ void loadWorkspaceConfigByEmptyProductsTest() {
.header(APM_HEADER_PARAM, ADMIN)
.contentType(APPLICATION_JSON)
.body(new LoadWorkspaceConfigRequestDTO().path("/w1Url"))
.post("load")
.post()
.then()
.statusCode(Response.Status.OK.getStatusCode())
.contentType(APPLICATION_JSON)
Expand Down Expand Up @@ -427,7 +427,7 @@ void loadWorkspaceConfig_ErrorTest() {
.header(APM_HEADER_PARAM, ADMIN)
.contentType(APPLICATION_JSON)
.body(new LoadWorkspaceConfigRequestDTO().path("/w1Url"))
.post("load")
.post()
.then()
.statusCode(BAD_REQUEST.getStatusCode());
Assertions.assertNotNull(output);
Expand Down Expand Up @@ -466,7 +466,7 @@ void loadWorkspaceConfig_errorThemeTest() {
.header(APM_HEADER_PARAM, ADMIN)
.contentType(APPLICATION_JSON)
.body(new LoadWorkspaceConfigRequestDTO().path("/w1Url"))
.post("load")
.post()
.then()
.statusCode(BAD_REQUEST.getStatusCode());

Expand Down Expand Up @@ -515,7 +515,7 @@ void loadWorkspace_errorProductTest() {
.header(APM_HEADER_PARAM, ADMIN)
.contentType(APPLICATION_JSON)
.body(new LoadWorkspaceConfigRequestDTO().path("/w1Url"))
.post("load")
.post()
.then()
.statusCode(BAD_REQUEST.getStatusCode());

Expand Down

0 comments on commit ea3066c

Please sign in to comment.