Member Quotas: New Listing API with Filtering, Pagination, and Username Support#68
Merged
jhonatapers merged 7 commits intomainfrom Aug 26, 2025
Merged
Member Quotas: New Listing API with Filtering, Pagination, and Username Support#68jhonatapers merged 7 commits intomainfrom
jhonatapers merged 7 commits intomainfrom
Conversation
Feature/list quotas
fix: ensure case-insensitive filtering in Like specification
feat: include username in quota output and response models
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces a new API endpoint to list all members' quota information, adds support for filtering and pagination, and refactors existing quota-related data structures to include usernames. The changes also improve the filtering mechanism for case-insensitive searches and update the data access layer to support the new functionality.
API and Use Case Enhancements:
listQuotastoMemberAdminAPIand implemented it inMemberAdminController, allowing clients to retrieve a paginated and filterable list of members' quota information, includingmemberId,username, and total quota. ([[1]](https://github.com/CallVDois/drive-api/pull/68/files#diff-ff9315202227c9a42496a21022efaa5998d882e993ec8c3b7908e61dd90e786cR56-R68),[[2]](https://github.com/CallVDois/drive-api/pull/68/files#diff-a83074e73dacb0218c2418ac388ce678bceb4540a2d33ec6c79203ead96aeea1R73-R96))DefaultListQuotasUseCaseandListQuotaOutputto handle the business logic for listing member quotas, and registered the use case as a Spring bean. ([[1]](https://github.com/CallVDois/drive-api/pull/68/files#diff-1cd81131b6060eefc2f7c4d350ffb071549e669781d1f6453a09845f73a6ff11R3-L12),[[2]](https://github.com/CallVDois/drive-api/pull/68/files#diff-3bb9f124c4e78cc24116c2f1ac870b08db11f59611da0ac6b73c104a83bfdbd7R1-R14),[[3]](https://github.com/CallVDois/drive-api/pull/68/files#diff-82e9353021dbb14d7d9d2e02a34c83bfb043f344041b7adf08b9d9fe2c04de44R57-R61))Domain and Data Layer Changes:
MemberGatewaywith afindAllmethod for paginated, filtered member retrieval, and implemented it inDefaultMemberGatewayusing Spring Data JPA specifications and a newFilterService. ([[1]](https://github.com/CallVDois/drive-api/pull/68/files#diff-563a68bf8e1f6aefc123425a57bdd517b7d5173e9ac8419aa2479841497d8017R12-R13),[[2]](https://github.com/CallVDois/drive-api/pull/68/files#diff-ad5dcf49c85084ae9c661202d03ecadd6da5a605972f5a436026a3c746c16078R19-R33),[[3]](https://github.com/CallVDois/drive-api/pull/68/files#diff-ad5dcf49c85084ae9c661202d03ecadd6da5a605972f5a436026a3c746c16078R45-R66))MemberJpaRepositoryto support filtered and paginated queries using JPA specifications. ([infrastructure/src/main/java/com/callv2/drive/infrastructure/member/persistence/MemberJpaRepository.javaR18-R19](https://github.com/CallVDois/drive-api/pull/68/files#diff-fb09fc39b33907c94685a89e9cadb3b5d201a468bd257aad72fbd36cc89b98c4R18-R19))DTO and Model Updates:
GetQuotaOutput,MemberQuotaResponse, and newly introducedMemberQuotaListResponse) to include theusernamefield for better client usability. ([[1]](https://github.com/CallVDois/drive-api/pull/68/files#diff-fcf56b06f21d638002da83fc363a1db494003888c08e15782539277e3a34a2f3L3-R13),[[2]](https://github.com/CallVDois/drive-api/pull/68/files#diff-3c42750b1dc9a2ddbcfab848e972160ab916455be046446f8653c269fa5c4cbfL3-R3),[[3]](https://github.com/CallVDois/drive-api/pull/68/files#diff-f6fb1948e6978cf81e20ae8a76ef36d2635ff8ac3fa78f77cefb5bc9aae3ee0eR1-R5))QuotaListOutputDTO in favor of the new, more comprehensive structures. ([application/src/main/java/com/callv2/drive/application/member/quota/retrieve/list/QuotaListOutput.javaL1-L9](https://github.com/CallVDois/drive-api/pull/68/files#diff-53eeeb0e3ba2fdd444cd2f18a01e2976970e8a7904a9d76a1497c5578603a669L1-L9))Filtering Improvements:
Likefilter to perform case-insensitive searches by converting both the field and the filter value to uppercase. ([infrastructure/src/main/java/com/callv2/drive/infrastructure/filter/Like.javaL27-R27](https://github.com/CallVDois/drive-api/pull/68/files#diff-8265fa9ead41c1a9db1c9a478f00063f3920abceb0214c93a37220a242988004L27-R27))Presentation Layer Adjustments:
MemberPresenterto handle the new output structures for both single and list quota responses. ([infrastructure/src/main/java/com/callv2/drive/infrastructure/member/presenter/MemberPresenter.javaL21-R35](https://github.com/CallVDois/drive-api/pull/68/files#diff-12b43fd72d05ff610a664da481dc94e0f28a2006babdfcb164559bd57c453806L21-R35))These changes collectively provide a robust, extensible foundation for quota management and administration in the application, enabling more detailed and user-friendly responses for quota-related API calls.