Skip to content

WEB-1099: Strip leading hierarchy dots from report select option names - #3792

Open
Farah-Nahle-FOO wants to merge 1 commit into
openMF:devfrom
foodeveloper:WEB-1099-fix-office-dropdown-leading-dots
Open

WEB-1099: Strip leading hierarchy dots from report select option names#3792
Farah-Nahle-FOO wants to merge 1 commit into
openMF:devfrom
foodeveloper:WEB-1099-fix-office-dropdown-leading-dots

Conversation

@Farah-Nahle-FOO

@Farah-Nahle-FOO Farah-Nahle-FOO commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Description

Office names in report parameter dropdowns (e.g. Reports > Active Loans - Summary > Office) were displayed with leading dots such as ...Foo or ........Foo - Dubai Branch. Fineract's report SQL prefixes office names with dots to encode hierarchy depth, and the frontend's SelectOption model — which backs every report "select" type parameter, not just Office — was passing that raw string through unchanged.

Stripped the leading dot prefix when the option name is constructed in SelectOption (src/app/reports/common-models/select-option.model.ts), so all report select dropdowns render clean names (Foo, Foo - Dubai Branch, etc.) instead of the raw hierarchy-encoded string. No new dependencies required.

Related issues and discussion

WEB-1099

Screenshots, if any

image

Checklist

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

  • If you have multiple commits please combine them into one commit by squashing them.
  • Read and understood the contribution guidelines at web-app/.github/CONTRIBUTING.md.

Summary by CodeRabbit

  • Bug Fixes
    • Option names now consistently display without leading dots.
    • Non-string option values continue to be handled unchanged.

@Farah-Nahle-FOO
Farah-Nahle-FOO requested a review from a team August 4, 2026 08:33
@coderabbitai

coderabbitai Bot commented Aug 4, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@Farah-Nahle-FOO, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 54 minutes

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 708091ce-3c23-448d-b28c-ced4deaae639

📥 Commits

Reviewing files that changed from the base of the PR and between e842bba and 9dcaac7.

📒 Files selected for processing (1)
  • src/app/reports/common-models/select-option.model.ts

Note

.coderabbit.yaml has unrecognized properties

CodeRabbit is using all valid settings from your configuration. Unrecognized properties (listed below) have been ignored and may indicate typos or deprecated fields that can be removed.

⚠️ Parsing warnings (1)
Validation error: Unrecognized key: "pre_merge_checks"
⚙️ Configuration instructions
  • Please see the configuration documentation for more information.
  • You can also validate your configuration using the online YAML validator.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Walkthrough

The SelectOption constructor now removes leading dots from string option names. Non-string names remain unchanged. Constructor and ID handling remain unchanged.

Changes

Select option normalization

Layer / File(s) Summary
Normalize option names
src/app/reports/common-models/select-option.model.ts
The constructor strips leading dots from string names and preserves non-string names. It keeps the existing constructor signature and ID handling.

Estimated code review effort: 1 (Trivial) | ~3 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the change to strip leading hierarchy dots from report select option names.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (1)
src/app/reports/common-models/select-option.model.ts (1)

16-17: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Add focused tests for the normalization contract.

Cover multiple leading dots, names without leading dots, non-string values, and unchanged IDs.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@src/app/reports/common-models/select-option.model.ts` around lines 16 - 17,
In the tests for the select-option model constructor, add focused cases covering
removal of multiple leading dots, preservation of names without leading dots,
passthrough of non-string names, and preservation of the supplied ID. Use the
existing model construction and assertion patterns without changing the
normalization implementation.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Nitpick comments:
In `@src/app/reports/common-models/select-option.model.ts`:
- Around line 16-17: In the tests for the select-option model constructor, add
focused cases covering removal of multiple leading dots, preservation of names
without leading dots, passthrough of non-string names, and preservation of the
supplied ID. Use the existing model construction and assertion patterns without
changing the normalization implementation.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 722ca25b-a388-4c9e-92da-28ba24468154

📥 Commits

Reviewing files that changed from the base of the PR and between 815600b and 4af3eac.

📒 Files selected for processing (1)
  • src/app/reports/common-models/select-option.model.ts

@Farah-Nahle-FOO
Farah-Nahle-FOO force-pushed the WEB-1099-fix-office-dropdown-leading-dots branch from 7916238 to 9dcaac7 Compare August 5, 2026 06:33
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.

1 participant