Skip to content

Conversation

@Dhanno98
Copy link
Contributor

@Dhanno98 Dhanno98 commented Feb 10, 2026

Description

Implements FINERACT-2408: This PR adds entityStatus mapping for SAVING and SHARE entities in the search API.

The /v1/search endpoint returned an empty entityStatus for entities of type SAVING and SHARE.

This happened because SearchMapper.mapRow() in SearchReadPlatformServiceImpl did not contain handling for these entity types, so the status defaulted to an empty EnumOptionData.

Solution

Added missing mappings in SearchMapper.mapRow():

  1. For SAVING entity types:

    • Get the SavingsAccountStatusEnumData using SavingsEnumerations.status().
    • Convert it to EnumOptionData using the status data's id, code, and value.
  2. For SHARE entity types:

    • Get the ShareAccountStatusEnumData using SharesEnumerations.status().
    • Convert it to EnumOptionData using the status data's id, code, and value.

To support this conversion, overloaded status() methods are introduced in SavingsEnumerations and SharesEnumerations.

Result

Search results for SAVING and SHARE entities now return the correct entityStatus instead of empty values.

Verification

Before Fix

Before

After Fix

After

Checklist

Please make sure these boxes are checked before submitting your pull request - thanks!

  • Write the commit message as per our guidelines
  • Acknowledge that we will not review PRs that are not passing the build ("green") - it is your responsibility to get a proposed PR to pass the build, not primarily the project's maintainers.
  • Create/update unit or integration tests for verifying the changes made.
  • Follow our coding conventions.
  • Add required Swagger annotation and update API documentation at fineract-provider/src/main/resources/static/legacy-docs/apiLive.htm with details of any API changes
  • This PR must not be a "code dump". Large changes can be made in a branch, with assistance. Ask for help on the developer mailing list.

Your assigned reviewer(s) will follow our guidelines for code reviews.

@IOhacker
Copy link
Contributor

There's a new ci action for PRs to check that new commits are signed.

All committers already have PGP/GPG keys, so just make sure you're also signing commits. You can add this to your ~/.gitconfig (or equivalent) to do it automatically:

[commit]
gpgSign = true

Upload your public key to github to make the verified badges green.

More info: FINERACT-2177, PR #5431.

Hints: 1) try it locally before pushing. 2) have git run it for you: Create .git/hooks/pre-push with:

#!/bin/sh
scripts/verify-signed-commits.sh --strict

Be sure to make that script executable.

@Dhanno98
Copy link
Contributor Author

Thanks for the heads up! I am setting up GPG signing now and will update the PR with signed commits.

@Dhanno98 Dhanno98 force-pushed the FINERACT-2408/add-entity-status-mapping-for-saving-and-share-in-search-api branch from 6a0225f to 2ed023d Compare February 11, 2026 11:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants