MyHome
MyHome copied to clipboard
Bugfix/issue 260 fix postman collection
๐ Description
Included PageInfo object as an instance variable in the GetCommunityDetailsResponse component. I also included a listAllWithPages(Pageable pageable) method which returns Page<Community> object in the CommunityService interface, and implemented in the CommunitySDJpaService. This method was used in the listAllCommunities method in the CommunityController class.
๐ Motivation and Context
When you list all communities by GET /communities, you get all the communities in a communities array, you can also page them using page and size query parameters, but no pageInfo object is returned, which is required for further pagination on the front-end. This change was added to include page information to navigate the list of communities returned by the GET /communities request. https://github.com/jmprathab/MyHome/issues/262
๐งช How Has This Been Tested?
Mockito unit test and postman test
๐ท Screenshots (if appropriate)
๐ฆ Types of changes
- [x] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
โ Checklist
- [x] My code follows the code style of this project(Do your best to follow code styles. If none apply just skip this).
- [ ] My change requires a change to the documentation.
- [ ] I have updated the documentation accordingly.