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

fix(service management): fix 400 issue when clicking 'Load More' button #1175

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
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
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,12 @@
### Bugfixes

- **Service Release Process**

- Fixed "None" selection issue in Technical Integration [#1161](https://github.com/eclipse-tractusx/portal-frontend/issues/1161)

- **Service Management**
- Service Management | 400 Bad Request when Clicking 'Load More' Button [#1168](https://github.com/eclipse-tractusx/portal-frontend/issues/1168)

### Bugfixes

- **Onboarding Service Provider Management**
Expand Down
14 changes: 6 additions & 8 deletions src/features/adminBoard/serviceAdminBoardApiSlice.ts
Original file line number Diff line number Diff line change
Expand Up @@ -92,15 +92,13 @@ export const apiSlice = createApi({
endpoints: (builder) => ({
fetchInReviewServices: builder.query<ServiceResponse, ServiceRequestBody>({
query: (body) => {
const statusId = `&status=${body.statusId}`
const sortingType = `&sorting=${body.sortingType}`
const expr = `&serviceName=${body.expr}`
const statusId = body.statusId ? `&status=${body.statusId}` : ''
const sortingType = body.sortingType
? `&sorting=${body.sortingType}`
: ''
const expr = body.expr ? `&serviceName=${body.expr}` : ''
return {
url: `/api/services/serviceRelease/inReview?size=${PAGE_SIZE}&page=${
body.page
}${body.statusId && statusId}${body.sortingType && sortingType}${
body.expr && expr
}`,
url: `/api/services/serviceRelease/inReview?size=${PAGE_SIZE}&page=${body.page}${statusId}${sortingType}${expr}`,
}
},
}),
Expand Down
Loading