Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: reverted changes in api and mapper #22

Merged
merged 1 commit into from
May 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
Loading