Feature/web 1035 dynamic currency conversion webapp - #3758
Conversation
|
Note
|
| Layer / File(s) | Summary |
|---|---|
Contracts and validation src/app/organization/exchange-rates/exchange-rate.model.ts, exchange-rate-form.util.ts, exchange-rate-validators.ts |
Defines exchange-rate and conversion payload/result contracts, currency fallback helpers, and identical-currency validation. |
API service and resolvers src/app/organization/exchange-rates/exchange-rates.service.ts, *resolver.ts, exchange-rates.service.spec.ts |
Adds HTTP retrieval, CRUD, conversion, response normalization, and resolver error handling with service coverage. |
Exchange-rate screens exchange-rates/*, view-exchange-rate/*, create-exchange-rate/*, edit-exchange-rate/* |
Adds filtering, sorting, pagination, deletion, detail display, and create/edit forms with validation and formatted payloads. |
Currency conversion currency-conversion/* |
Adds conversion submission, loading/error states, normalized result display, and rate-source formatting. |
Routing and navigation src/app/organization/organization-routing.module.ts, organization.component.*, organization.module.ts |
Registers the feature components and resolvers, adds exchange-rate routes and navigation, and updates menu toggle state. |
Translations src/assets/translations/*.json |
Adds exchange-rate and currency-conversion labels, messages, and validation strings across translation catalogs. |
Estimated code review effort: 4 (Complex) | ~60 minutes
Sequence Diagram(s)
sequenceDiagram
participant User
participant CurrencyConversionComponent
participant ExchangeRatesService
participant ExchangeRatesAPI
User->>CurrencyConversionComponent: submit conversion form
CurrencyConversionComponent->>ExchangeRatesService: convertCurrency(payload)
ExchangeRatesService->>ExchangeRatesAPI: POST conversion request
ExchangeRatesAPI-->>ExchangeRatesService: conversion result
ExchangeRatesService-->>CurrencyConversionComponent: normalized result
CurrencyConversionComponent-->>User: display converted amount and rate
Suggested reviewers: adamsaghy
🚥 Pre-merge checks | ✅ 4 | ❌ 1
❌ Failed checks (1 warning)
| Check name | Status | Explanation | Resolution |
|---|---|---|---|
| Docstring Coverage | Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. | Write docstrings for the functions missing them to satisfy the coverage threshold. |
✅ Passed checks (4 passed)
| Check name | Status | Explanation |
|---|---|---|
| Description Check | ✅ Passed | Check skipped - CodeRabbit’s high-level summary is enabled. |
| Title check | ✅ Passed | The title is clearly related to the main change: adding dynamic currency conversion and exchange-rate management to the web app. |
| 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. |
✨ 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.
Comment @coderabbitai help to get the list of available commands.
There was a problem hiding this comment.
Actionable comments posted: 6
Note
Due to the large number of review comments, Critical, Major severity comments were prioritized as inline comments.
🟡 Minor comments (15)
src/assets/translations/cs-CS.json-638-638 (1)
638-638: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick winLocalize all changed Czech catalog values before merging.
The affected entries currently expose English UI text to Czech users:
src/assets/translations/cs-CS.json#L638-L638: restore the CzechFilterlabel.src/assets/translations/cs-CS.json#L782-L783: translate the currency-conversion action labels.src/assets/translations/cs-CS.json#L1602-L1603: translate the page titles.src/assets/translations/cs-CS.json#L3194-L3200: translate the exchange-rate field labels.src/assets/translations/cs-CS.json#L4197-L4201: translate the help, loading, empty-state, and validation messages.🤖 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/assets/translations/cs-CS.json` at line 638, Localize the changed English values in src/assets/translations/cs-CS.json: restore the Czech Filter label at lines 638-638, translate the currency-conversion action labels at lines 782-783, page titles at lines 1602-1603, exchange-rate field labels at lines 3194-3200, and help/loading/empty-state/validation messages at lines 4197-4201.src/assets/translations/de-DE.json-782-784 (1)
782-784: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick winComplete the German localization for the exchange-rate feature.
The newly added exchange-rate strings remain English throughout the German catalog, causing mixed-language UI text.
src/assets/translations/de-DE.json#L782-L784: Translate the currency-conversion and create-exchange-rate button labels.src/assets/translations/de-DE.json#L1603-L1605: Translate the exchange-rate navigation labels.src/assets/translations/de-DE.json#L3195-L3202: Translate the exchange-rate form-field labels.src/assets/translations/de-DE.json#L4197-L4202: Translate the loading, empty-state, and validation messages.🤖 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/assets/translations/de-DE.json` around lines 782 - 784, Complete the German localization for all exchange-rate strings by translating the currency-conversion and create-exchange-rate labels at src/assets/translations/de-DE.json lines 782-784, navigation labels at lines 1603-1605, form-field labels at lines 3195-3202, and loading, empty-state, and validation messages at lines 4197-4202; preserve the existing translation keys and JSON structure.src/assets/translations/es-CL.json-637-637 (1)
637-637: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick winTranslate the new and changed values for the Spanish-Chile catalog.
These values are English in
es-CL.json, so Spanish users will see untranslated UI text. Line 637 also regresses the existingFilterlabel fromFiltrartoFilter. Replace these values with Spanish translations, including the exchange-rate labels and validation messages consumed by the exchange-rate screens.Also applies to: 781-782, 1602-1603, 3195-3201, 4198-4202
🤖 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/assets/translations/es-CL.json` at line 637, Update the Spanish-Chile translation catalog by translating every new or changed English value in the affected entries, including the exchange-rate labels and validation messages used by the exchange-rate screens. Restore the Filter label to its existing Spanish translation, “Filtrar,” and ensure all affected catalog values are Spanish rather than English.src/assets/translations/ne-NE.json-637-637 (1)
637-637: 📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick winAdd Nepali translations for the changed UI strings.
Filternow regresses to English, while the same catalog already contains the Nepali translation"फिल्टर गर्नुहोस्". The new exchange-rate labels and validation messages are also all English, so Nepali users will see untranslated UI text.Please restore the Nepali
Filtervalue and provide approved Nepali translations for the new keys.Also applies to: 781-782, 1601-1602, 3193-3199, 4196-4200
🤖 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/assets/translations/ne-NE.json` at line 637, Update the Nepali translation catalog so the Filter key uses the existing approved value “फिल्टर गर्नुहोस्” instead of English, and add approved Nepali translations for the new exchange-rate labels and validation-message keys at the referenced sections. Preserve the existing key structure and ensure no newly changed UI strings remain in English.src/assets/translations/pt-PT.json-637-637 (1)
637-637: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick winTranslate the new exchange-rate strings in the Portuguese catalog.
Line [637] changes
Filterto English, and the added values on Lines [781]-[782], [1601]-[1602], [3193]-[3199], and [4196]-[4200] are also untranslated. These keys are rendered by the exchange-rate screens, so Portuguese users will see a mixed-language UI. Keep the keys unchanged and provide Portuguese values.Also applies to: 781-782, 1601-1602, 3193-3199, 4196-4200
🤖 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/assets/translations/pt-PT.json` at line 637, Update the Portuguese translation catalog entries referenced in the exchange-rate screens, including Filter and all added exchange-rate strings, replacing English values with accurate Portuguese translations while preserving every existing key unchanged.src/assets/translations/sw-SW.json-637-637 (1)
637-637: 📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick winTranslate the new exchange-rate strings in the Swahili catalog.
These values are English, so Swahili users will see untranslated buttons, labels, fields, and validation errors throughout the new exchange-rate workflow. Line [637] is also a regression:
Filtershould remain Kiswahili (Chuja), consistent with the existinginputs.Filterentry.Please replace these values with approved Kiswahili translations rather than English fallbacks.
Also applies to: 781-782, 1599-1600, 3191-3197, 4193-4197
🤖 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/assets/translations/sw-SW.json` at line 637, Update the Swahili catalog entries for the exchange-rate workflow, including the strings at the referenced ranges, with approved Kiswahili translations instead of English fallbacks. Restore the visible Filter entry to “Chuja” consistently with the existing inputs.Filter translation, and ensure all affected buttons, labels, fields, and validation errors are translated.src/assets/translations/es-MX.json-638-638 (1)
638-638: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick winReplace English values with Spanish translations throughout the changed es-MX entries.
These values either regress existing localization or leave the new exchange-rate UI untranslated:
src/assets/translations/es-MX.json#L638-L638: restoreFilteras"Filtrar".src/assets/translations/es-MX.json#L783-L784: translate the exchange-rate action labels.src/assets/translations/es-MX.json#L1607-L1608: translate the exchange-rate headings.src/assets/translations/es-MX.json#L3200-L3206: translate the exchange-rate form labels.src/assets/translations/es-MX.json#L4222-L4226: translate the exchange-rate status and validation messages.🤖 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/assets/translations/es-MX.json` at line 638, Replace the English values with Spanish translations in all listed es-MX.json entries: restore Filter to “Filtrar” at lines 638-638; translate the exchange-rate action labels at lines 783-784, headings at 1607-1608, form labels at 3200-3206, and status/validation messages at 4222-4226. No other translation entries require changes.src/assets/translations/fr-FR.json-637-637 (1)
637-637: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick winTranslate all newly added values in the French catalog. The affected keys are rendered directly by the French UI, so leaving their values in English produces inconsistent localization.
src/assets/translations/fr-FR.json#L637-L637: translateFilter.src/assets/translations/fr-FR.json#L781-L782: translate the exchange-rate action labels.src/assets/translations/fr-FR.json#L1605-L1606: translate the exchange-rate section labels.src/assets/translations/fr-FR.json#L3197-L3203: translate the exchange-rate field labels.src/assets/translations/fr-FR.json#L4199-L4203: translate the exchange-rate loading, empty-state, and validation messages.🤖 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/assets/translations/fr-FR.json` at line 637, Translate every newly added English value in src/assets/translations/fr-FR.json: Filter at lines 637-637, exchange-rate action labels at 781-782, section labels at 1605-1606, field labels at 3197-3203, and loading, empty-state, and validation messages at 4199-4203. Preserve all keys and JSON structure while ensuring each French UI value is properly localized.src/assets/translations/it-IT.json-637-637 (1)
637-637: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick winRestore Italian translations for the changed catalog entries.
These values are still English in the Italian catalog, including
Filter, exchange-rate labels, and currency-conversion messages. Italian users will see untranslated text in the affected screens. Replace them with Italian equivalents such asFiltro,Conversione valuta,Crea tasso di cambio,Valuta di origine, andTasso di cambio.Also applies to: 781-782, 1602-1603, 3194-3200, 4197-4201
🤖 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/assets/translations/it-IT.json` at line 637, Restore the Italian translations for the affected catalog entries in the Italian JSON resource, replacing the English values for Filter, exchange-rate labels, and currency-conversion messages with their Italian equivalents, including Filtro, Conversione valuta, Crea tasso di cambio, Valuta di origine, and Tasso di cambio.src/assets/translations/ko-KO.json-637-637 (1)
637-637: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick winKeep the Korean catalog fully localized.
The changed values introduce English text into user-facing Korean flows, including an existing regression where
Filterwas de-localized. Replace these values with product-approved Korean translations:
src/assets/translations/ko-KO.json#L637-L637: restore the KoreanFiltervalue.src/assets/translations/ko-KO.json#L780-L782: translate the exchange-rate action labels.src/assets/translations/ko-KO.json#L1603-L1604: translate the organization navigation labels.src/assets/translations/ko-KO.json#L3194-L3200: translate the currency-conversion form and result labels.src/assets/translations/ko-KO.json#L4196-L4200: translate the exchange-rate status and validation messages.🤖 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/assets/translations/ko-KO.json` at line 637, Restore Korean translations for all affected user-facing entries in src/assets/translations/ko-KO.json: lines 637-637 for Filter, 780-782 for exchange-rate actions, 1603-1604 for organization navigation, 3194-3200 for currency-conversion labels, and 4196-4200 for exchange-rate status and validation messages. Replace the English values with product-approved Korean translations while preserving the existing keys and JSON structure.src/assets/translations/lt-LT.json-781-782 (1)
781-782: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick winComplete the Lithuanian translations across all affected keys.
The
lt-LTcatalog now mixes Lithuanian and English throughout the exchange-rate workflow, and Line 637 also regresses an existing filter translation. Replace the affected values with approved Lithuanian translations:
src/assets/translations/lt-LT.json#L781-L782: translate the exchange-rate action labels.src/assets/translations/lt-LT.json#L637-L637: restore the LithuanianFiltervalue.src/assets/translations/lt-LT.json#L1601-L1602: translate the exchange-rate headings.src/assets/translations/lt-LT.json#L3193-L3199: translate the conversion field labels.src/assets/translations/lt-LT.json#L4197-L4201: translate the conversion descriptions and validation messages.🤖 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/assets/translations/lt-LT.json` around lines 781 - 782, Complete the Lithuanian catalog entries while preserving all existing keys: update src/assets/translations/lt-LT.json lines 781-782 for “Currency Conversion” and “Create Exchange Rate”, restore the Lithuanian “Filter” value at line 637, translate the exchange-rate headings at lines 1601-1602, the conversion field labels at lines 3193-3199, and the conversion descriptions and validation messages at lines 4197-4201 using the approved Lithuanian translations.src/assets/translations/lv-LV.json-781-782 (1)
781-782: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick winAdd Latvian translations instead of English fallback text.
These values will display English strings in the Latvian locale. This also regresses the existing
Filtertranslation from Latvian to English. Replace all affected values with reviewed Latvian translations.🤖 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/assets/translations/lv-LV.json` around lines 781 - 782, Replace every English fallback value identified in src/assets/translations/lv-LV.json at lines 637, 781-782, 1602-1603, 3194-3200, and 4196-4200 with reviewed Latvian translations, including restoring the existing Latvian Filter translation; update all affected translation entries without changing unrelated keys.src/app/organization/exchange-rates/currency-conversion/currency-conversion.component.html-15-16 (1)
15-16: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick winUse
mat-labelfor every conversion field. Replace the native labels and remove the custom.field-labelstyling so Angular Material owns field labeling and accessibility semantics.
src/app/organization/exchange-rates/currency-conversion/currency-conversion.component.html#L15-L16: use<mat-label>inside the source-currency form field.src/app/organization/exchange-rates/currency-conversion/currency-conversion.component.html#L36-L37: use<mat-label>inside the target-currency form field.src/app/organization/exchange-rates/currency-conversion/currency-conversion.component.html#L63-L64: use<mat-label>inside the amount form field.src/app/organization/exchange-rates/currency-conversion/currency-conversion.component.html#L89-L90: use<mat-label>inside the conversion-date form field.src/app/organization/exchange-rates/currency-conversion/currency-conversion.component.scss#L21-L27: remove the now-unneeded native-label styling.As per coding guidelines, “All visual components must strictly use Angular Material elements.”
🤖 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/organization/exchange-rates/currency-conversion/currency-conversion.component.html` around lines 15 - 16, Replace the native labels with mat-label inside each conversion mat-form-field: source currency in src/app/organization/exchange-rates/currency-conversion/currency-conversion.component.html lines 15-16, target currency at lines 36-37, amount at lines 63-64, and conversion date at lines 89-90. Remove the obsolete .field-label styling from src/app/organization/exchange-rates/currency-conversion/currency-conversion.component.scss lines 21-27.Source: Coding guidelines
src/app/organization/exchange-rates/currency-conversion/currency-conversion.component.ts-102-106 (1)
102-106: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick winTranslate fallback and rate-source labels.
The fallback error plus
Cross Rate,Administrator, andProviderare user-facing hardcoded strings. Add translation keys, including a parameterized key for the base currency, and run translation extraction. Keep backend-provided messages unchanged.As per coding guidelines, “Use proper i18n variables from
@ngx-translate/corefor all user-facing strings instead of hardcoded text.”Also applies to: 127-142
🤖 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/organization/exchange-rates/currency-conversion/currency-conversion.component.ts` around lines 102 - 106, Update the error fallback in the currency conversion component to use an ngx-translate key while preserving backend-provided messages unchanged. Replace the user-facing Cross Rate, Administrator, and Provider labels with translation lookups, using a parameterized translation key for the base-currency label. Add the required translation entries and run translation extraction.Source: Coding guidelines
src/app/organization/exchange-rates/exchange-rates.component.ts-164-168 (1)
164-168: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick winTranslate the missing-ID alert.
Exchange rate id is missing.is user-facing text and will remain English in every locale. Use a translation key and add it to the catalogs.As per coding guidelines, “Use proper i18n variables from
@ngx-translate/corefor all user-facing strings instead of hardcoded text.”🤖 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/organization/exchange-rates/exchange-rates.component.ts` around lines 164 - 168, Update deleteExchangeRate in ExchangeRatesComponent to replace the hardcoded missing-ID alert message with an `@ngx-translate/core` translation key, and add the corresponding key and localized catalog entries. Preserve the existing alert behavior and error type.Source: Coding guidelines
🧹 Nitpick comments (10)
src/app/organization/exchange-rates/currency-conversion/currency-conversion.component.scss (1)
9-46: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winReplace raw spacing values with shared 8px-grid styling. The new styles introduce raw pixel values, while the template additionally uses
gap-5pxandm-r-10, neither aligned to the required grid.
src/app/organization/exchange-rates/currency-conversion/currency-conversion.component.scss#L9-L46: replace raw sizing, spacing, color, and typography literals with applicable shared SCSS/theme variables and 8px-grid values.src/app/organization/exchange-rates/currency-conversion/currency-conversion.component.html#L111-L121: replace the 5px/10px utility classes with existing shared layout utilities that conform to the 8px grid.As per coding guidelines, “Stick to the 8px grid system for visual design and spacing” and “Leverage SCSS variables defined in
src/main.scssandsrc/theme/mifosx-theme.scss.”🤖 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/organization/exchange-rates/currency-conversion/currency-conversion.component.scss` around lines 9 - 46, The currency-conversion styles and template utilities use non-grid spacing and raw visual literals. In currency-conversion.component.scss lines 9-46, replace sizing, spacing, color, and typography values with applicable shared SCSS/theme variables and 8px-grid values, preserving the existing layout behavior. In currency-conversion.component.html lines 111-121, replace gap-5px and m-r-10 with existing shared layout utilities that conform to the 8px grid.Source: Coding guidelines
src/app/organization/exchange-rates/exchange-rates.component.ts (1)
146-160: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winRemove the
anycasts from the sorting accessor.A typed column-to-accessor map keeps unsupported column names from silently returning arbitrary fields and preserves strict typing.
🤖 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/organization/exchange-rates/exchange-rates.component.ts` around lines 146 - 160, Update the sortingDataAccessor in the exchange-rates component to remove both any casts. Introduce a strictly typed column-to-accessor mapping for the supported rate properties, use it for buyRate, sellRate, and referenceRate with the existing zero fallback, and ensure unsupported column names are not used to access arbitrary ExchangeRate fields.Source: Coding guidelines
src/app/organization/exchange-rates/exchange-rates.component.scss (1)
9-54: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winReplace off-grid spacing/sizing with shared tokens. These values break the 8px grid and avoid the approved shared styles:
src/app/organization/exchange-rates/exchange-rates.component.scss#L9-L37: replacegap: 16px 20px,max-width: 360px,font-size: 14px, and use the shared helper classes forpadding: 20px.src/app/organization/exchange-rates/exchange-rates.component.html#L9:gap-20pxis grid-aligned and already exists, but the helper still defines non-grid utils likegap-5px.src/app/organization/exchange-rates/exchange-rates.component.html#L95: usegap-8pxinstead ofgap-5px, or remove the non-gridgap-5pxutility.src/app/organization/exchange-rates/view-exchange-rate/view-exchange-rate.component.html#L9:gap-2pxis defined asgap: 2%; use an 8px grid-aligned utility instead.src/app/organization/exchange-rates/view-exchange-rate/view-exchange-rate.component.html#L54:gap-2percentdoes not resolve to a gap class; replace with an approved grid-aligned spacing utility.🤖 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/organization/exchange-rates/exchange-rates.component.scss` around lines 9 - 54, Replace off-grid spacing and sizing with approved shared tokens across src/app/organization/exchange-rates/exchange-rates.component.scss (lines 9-54): use shared padding helpers instead of padding: 20px, align the grid gap, max-width, and font-size values to approved tokens, and remove non-grid gap utilities if unused. Update exchange-rates.component.html lines 9 and 95 to use approved grid-aligned gap utilities, replacing gap-5px; update view-exchange-rate.component.html lines 9 and 54 to replace gap-2px and unresolved gap-2percent with approved 8px-grid spacing utilities.Source: Coding guidelines
src/app/organization/exchange-rates/edit-exchange-rate/edit-exchange-rate.component.scss (1)
9-41: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winHardcoded pixel values/color instead of theme SCSS variables; duplicates create-exchange-rate.component.scss.
Same 8px-grid violations (
6px,14px,4px) and hardcoded fallback color as the create form's stylesheet. As per coding guidelines, spacing should stick to "the 8px grid system" and reuse "SCSS variables defined insrc/main.scssandsrc/theme/mifosx-theme.scss."🤖 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/organization/exchange-rates/edit-exchange-rate/edit-exchange-rate.component.scss` around lines 9 - 41, The exchange-rate form styles duplicate the create form’s non-theme values and violate the 8px spacing grid. Update the selectors in `.exchange-rate-form-grid` and `.form-error` to use the existing SCSS theme variables from `main.scss` or `mifosx-theme.scss`, replacing the hardcoded color and spacing values while preserving the current layout and field sizing.Source: Coding guidelines
src/app/organization/exchange-rates/create-exchange-rate/create-exchange-rate.component.ts (1)
55-103: 📐 Maintainability & Code Quality | 🔵 Trivial | 🏗️ Heavy liftForm config and payload builder duplicate edit-exchange-rate.component.ts.
createExchangeRateForm(Lines 55-103) andbuildPayload(Lines 113-126) are structurally identical toEditExchangeRateComponent's versions, including the repeated0.0000001magic minimum. Consider extracting a shared factory (e.g., inexchange-rate-form.util.ts) that both components consume.Also applies to: 113-126
🤖 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/organization/exchange-rates/create-exchange-rate/create-exchange-rate.component.ts` around lines 55 - 103, Extract the duplicated exchange-rate form configuration and payload-building logic from createExchangeRateForm and buildPayload into a shared exchange-rate utility, then update both CreateExchangeRateComponent and EditExchangeRateComponent to use it. Centralize the 0.0000001 minimum in the shared implementation while preserving the existing validators and payload behavior.src/app/organization/exchange-rates/edit-exchange-rate/edit-exchange-rate.component.html (1)
9-219: 📐 Maintainability & Code Quality | 🔵 Trivial | 🏗️ Heavy liftTemplate duplicates create-exchange-rate.component.html.
Same content as the create form aside from the Cancel link/permission. Candidate for a shared template/component.
🤖 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/organization/exchange-rates/edit-exchange-rate/edit-exchange-rate.component.html` around lines 9 - 219, Extract the duplicated exchange-rate form markup from the edit-exchange-rate template and create-exchange-rate template into a shared template or reusable component. Preserve each form’s existing differences, including the edit Cancel router link and UPDATE_EXCHANGERATE permission, while keeping the shared controls, validation messages, and submit behavior unchanged.src/app/organization/exchange-rates/edit-exchange-rate/edit-exchange-rate.component.ts (2)
63-111: 📐 Maintainability & Code Quality | 🔵 Trivial | 🏗️ Heavy liftForm config and payload builder duplicate create-exchange-rate.component.ts.
Same structure (and the same
0.0000001magic minimum) asCreateExchangeRateComponent'screateExchangeRateForm/buildPayload. A shared abstraction would prevent the two from drifting apart.Also applies to: 121-134
🤖 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/organization/exchange-rates/edit-exchange-rate/edit-exchange-rate.component.ts` around lines 63 - 111, Extract the duplicated exchange-rate form configuration and payload construction from EditExchangeRateComponent’s createExchangeRateForm and buildPayload into a shared abstraction, then reuse it from both edit and create components. Preserve the existing validators, including the 0.0000001 minimum, field mappings, and payload behavior so the implementations cannot drift.
51-57: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winExplicit
anyfor route data typing.
currencies: anyloses type safety thatresolveCurrencyOptionsalready expects ({ currencyOptions?: Currency[]; selectedCurrencyOptions?: Currency[] }per exchange-rate-form.util.ts). As per path instructions, Angular code should have "strict type safety."♻️ Suggested typing
- .subscribe((data: { exchangeRate: ExchangeRate; currencies: any }) => { + .subscribe((data: { exchangeRate: ExchangeRate; currencies: { currencyOptions?: Currency[]; selectedCurrencyOptions?: Currency[] } }) => {🤖 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/organization/exchange-rates/edit-exchange-rate/edit-exchange-rate.component.ts` around lines 51 - 57, Replace the explicit any in the route.data subscription within the component initialization flow with the structured currencies type expected by resolveCurrencyOptions, including optional currencyOptions and selectedCurrencyOptions arrays of Currency. Preserve the existing exchangeRate typing and assignment behavior.Source: Path instructions
src/app/organization/exchange-rates/create-exchange-rate/create-exchange-rate.component.scss (1)
9-41: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winHardcoded pixel values/color instead of theme SCSS variables; duplicates edit-exchange-rate.component.scss.
6px,14px,4pxbreak the 8px grid and#44474eis a hardcoded fallback color rather than a theme variable. This file is also identical to the edit component's stylesheet. As per coding guidelines, "Stick to the 8px grid system for visual design and spacing" and "Leverage SCSS variables defined insrc/main.scssandsrc/theme/mifosx-theme.scssrather than generating custom classes and explicit pixel values."🤖 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/organization/exchange-rates/create-exchange-rate/create-exchange-rate.component.scss` around lines 9 - 41, Update the styles in .exchange-rate-form-grid and .form-error to match the shared theme conventions: replace the 6px, 14px, and 4px values with existing 8px-grid SCSS variables, replace the `#44474e` fallback in .field-label with the appropriate theme color variable, and reuse the edit exchange-rate stylesheet styles if the files are identical rather than maintaining duplicate definitions.Source: Coding guidelines
src/app/organization/exchange-rates/create-exchange-rate/create-exchange-rate.component.html (1)
9-219: 📐 Maintainability & Code Quality | 🔵 Trivial | 🏗️ Heavy liftTemplate is fully duplicated in edit-exchange-rate.component.html.
Aside from the Cancel
routerLinkand permission string, this template is identical to the edit form's. Worth factoring into a shared form component/template to avoid the two copies drifting apart.🤖 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/organization/exchange-rates/create-exchange-rate/create-exchange-rate.component.html` around lines 9 - 219, Extract the duplicated exchange-rate form markup from create-exchange-rate.component.html and edit-exchange-rate.component.html into a shared form component or reusable template. Preserve each page’s distinct Cancel routerLink and permission string through inputs or projected configuration, while keeping the shared fields, validation messages, and submit behavior consistent.
🤖 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.
Inline comments:
In
`@src/app/organization/exchange-rates/create-exchange-rate/create-exchange-rate.component.ts`:
- Around line 105-111: Update submit() to guard against repeated submissions by
tracking an in-flight state and returning early while createExchangeRate is
pending; ensure the template can use that state to disable the submit action.
Add an error callback to the subscription that presents the existing user-facing
error feedback, while preserving navigation only after a successful request.
In
`@src/app/organization/exchange-rates/edit-exchange-rate/edit-exchange-rate.component.ts`:
- Around line 113-119: Update EditExchangeRateComponent.submit() to provide an
error callback in the updateExchangeRate subscription, displaying the same user
feedback used by CreateExchangeRateComponent.submit() when the PUT fails; keep
navigation only in the success callback.
In `@src/app/organization/exchange-rates/exchange-rate.resolver.ts`:
- Around line 20-21: Update the resolve method to validate the value returned by
route.paramMap.get('id') before calling exchangeRatesService.getExchangeRate.
Handle a missing id through the resolver’s established error or fallback path,
and only invoke getExchangeRate with a confirmed string to prevent requests
using a null identifier.
In `@src/app/organization/exchange-rates/exchange-rates.component.ts`:
- Around line 174-175: Guard the delete-dialog result before accessing it and
type it as nullable in both delete dialog subscriptions:
src/app/organization/exchange-rates/exchange-rates.component.ts lines 174-175
and
src/app/organization/exchange-rates/view-exchange-rate/view-exchange-rate.component.ts
lines 53-54. Update the callbacks to accept `{ delete: true } | undefined` and
only proceed when `response?.delete` is true, preserving cancellation when the
dialog closes without a value.
In
`@src/app/organization/exchange-rates/view-exchange-rate/view-exchange-rate.component.html`:
- Around line 54-57: Update the Back button’s routerLink in the
view-exchange-rate template to use the same ../../ navigation target as the
delete flow, so it returns to the exchange-rate list instead of reloading the
current detail route.
In `@src/app/organization/organization-routing.module.ts`:
- Around line 324-375: Replace the direct exchange-rate child routes under the
organization routing configuration with a lazy loadChildren reference to the
exchange-rates feature module, preserving the exchange-rates URL segment. In
src/app/organization/organization-routing.module.ts lines 324-375, move route
ownership to that lazy module; in src/app/organization/organization.module.ts
lines 170-174, remove the eager exchange-rate component imports that are no
longer needed.
---
Minor comments:
In
`@src/app/organization/exchange-rates/currency-conversion/currency-conversion.component.html`:
- Around line 15-16: Replace the native labels with mat-label inside each
conversion mat-form-field: source currency in
src/app/organization/exchange-rates/currency-conversion/currency-conversion.component.html
lines 15-16, target currency at lines 36-37, amount at lines 63-64, and
conversion date at lines 89-90. Remove the obsolete .field-label styling from
src/app/organization/exchange-rates/currency-conversion/currency-conversion.component.scss
lines 21-27.
In
`@src/app/organization/exchange-rates/currency-conversion/currency-conversion.component.ts`:
- Around line 102-106: Update the error fallback in the currency conversion
component to use an ngx-translate key while preserving backend-provided messages
unchanged. Replace the user-facing Cross Rate, Administrator, and Provider
labels with translation lookups, using a parameterized translation key for the
base-currency label. Add the required translation entries and run translation
extraction.
In `@src/app/organization/exchange-rates/exchange-rates.component.ts`:
- Around line 164-168: Update deleteExchangeRate in ExchangeRatesComponent to
replace the hardcoded missing-ID alert message with an `@ngx-translate/core`
translation key, and add the corresponding key and localized catalog entries.
Preserve the existing alert behavior and error type.
In `@src/assets/translations/cs-CS.json`:
- Line 638: Localize the changed English values in
src/assets/translations/cs-CS.json: restore the Czech Filter label at lines
638-638, translate the currency-conversion action labels at lines 782-783, page
titles at lines 1602-1603, exchange-rate field labels at lines 3194-3200, and
help/loading/empty-state/validation messages at lines 4197-4201.
In `@src/assets/translations/de-DE.json`:
- Around line 782-784: Complete the German localization for all exchange-rate
strings by translating the currency-conversion and create-exchange-rate labels
at src/assets/translations/de-DE.json lines 782-784, navigation labels at lines
1603-1605, form-field labels at lines 3195-3202, and loading, empty-state, and
validation messages at lines 4197-4202; preserve the existing translation keys
and JSON structure.
In `@src/assets/translations/es-CL.json`:
- Line 637: Update the Spanish-Chile translation catalog by translating every
new or changed English value in the affected entries, including the
exchange-rate labels and validation messages used by the exchange-rate screens.
Restore the Filter label to its existing Spanish translation, “Filtrar,” and
ensure all affected catalog values are Spanish rather than English.
In `@src/assets/translations/es-MX.json`:
- Line 638: Replace the English values with Spanish translations in all listed
es-MX.json entries: restore Filter to “Filtrar” at lines 638-638; translate the
exchange-rate action labels at lines 783-784, headings at 1607-1608, form labels
at 3200-3206, and status/validation messages at 4222-4226. No other translation
entries require changes.
In `@src/assets/translations/fr-FR.json`:
- Line 637: Translate every newly added English value in
src/assets/translations/fr-FR.json: Filter at lines 637-637, exchange-rate
action labels at 781-782, section labels at 1605-1606, field labels at
3197-3203, and loading, empty-state, and validation messages at 4199-4203.
Preserve all keys and JSON structure while ensuring each French UI value is
properly localized.
In `@src/assets/translations/it-IT.json`:
- Line 637: Restore the Italian translations for the affected catalog entries in
the Italian JSON resource, replacing the English values for Filter,
exchange-rate labels, and currency-conversion messages with their Italian
equivalents, including Filtro, Conversione valuta, Crea tasso di cambio, Valuta
di origine, and Tasso di cambio.
In `@src/assets/translations/ko-KO.json`:
- Line 637: Restore Korean translations for all affected user-facing entries in
src/assets/translations/ko-KO.json: lines 637-637 for Filter, 780-782 for
exchange-rate actions, 1603-1604 for organization navigation, 3194-3200 for
currency-conversion labels, and 4196-4200 for exchange-rate status and
validation messages. Replace the English values with product-approved Korean
translations while preserving the existing keys and JSON structure.
In `@src/assets/translations/lt-LT.json`:
- Around line 781-782: Complete the Lithuanian catalog entries while preserving
all existing keys: update src/assets/translations/lt-LT.json lines 781-782 for
“Currency Conversion” and “Create Exchange Rate”, restore the Lithuanian
“Filter” value at line 637, translate the exchange-rate headings at lines
1601-1602, the conversion field labels at lines 3193-3199, and the conversion
descriptions and validation messages at lines 4197-4201 using the approved
Lithuanian translations.
In `@src/assets/translations/lv-LV.json`:
- Around line 781-782: Replace every English fallback value identified in
src/assets/translations/lv-LV.json at lines 637, 781-782, 1602-1603, 3194-3200,
and 4196-4200 with reviewed Latvian translations, including restoring the
existing Latvian Filter translation; update all affected translation entries
without changing unrelated keys.
In `@src/assets/translations/ne-NE.json`:
- Line 637: Update the Nepali translation catalog so the Filter key uses the
existing approved value “फिल्टर गर्नुहोस्” instead of English, and add approved
Nepali translations for the new exchange-rate labels and validation-message keys
at the referenced sections. Preserve the existing key structure and ensure no
newly changed UI strings remain in English.
In `@src/assets/translations/pt-PT.json`:
- Line 637: Update the Portuguese translation catalog entries referenced in the
exchange-rate screens, including Filter and all added exchange-rate strings,
replacing English values with accurate Portuguese translations while preserving
every existing key unchanged.
In `@src/assets/translations/sw-SW.json`:
- Line 637: Update the Swahili catalog entries for the exchange-rate workflow,
including the strings at the referenced ranges, with approved Kiswahili
translations instead of English fallbacks. Restore the visible Filter entry to
“Chuja” consistently with the existing inputs.Filter translation, and ensure all
affected buttons, labels, fields, and validation errors are translated.
---
Nitpick comments:
In
`@src/app/organization/exchange-rates/create-exchange-rate/create-exchange-rate.component.html`:
- Around line 9-219: Extract the duplicated exchange-rate form markup from
create-exchange-rate.component.html and edit-exchange-rate.component.html into a
shared form component or reusable template. Preserve each page’s distinct Cancel
routerLink and permission string through inputs or projected configuration,
while keeping the shared fields, validation messages, and submit behavior
consistent.
In
`@src/app/organization/exchange-rates/create-exchange-rate/create-exchange-rate.component.scss`:
- Around line 9-41: Update the styles in .exchange-rate-form-grid and
.form-error to match the shared theme conventions: replace the 6px, 14px, and
4px values with existing 8px-grid SCSS variables, replace the `#44474e` fallback
in .field-label with the appropriate theme color variable, and reuse the edit
exchange-rate stylesheet styles if the files are identical rather than
maintaining duplicate definitions.
In
`@src/app/organization/exchange-rates/create-exchange-rate/create-exchange-rate.component.ts`:
- Around line 55-103: Extract the duplicated exchange-rate form configuration
and payload-building logic from createExchangeRateForm and buildPayload into a
shared exchange-rate utility, then update both CreateExchangeRateComponent and
EditExchangeRateComponent to use it. Centralize the 0.0000001 minimum in the
shared implementation while preserving the existing validators and payload
behavior.
In
`@src/app/organization/exchange-rates/currency-conversion/currency-conversion.component.scss`:
- Around line 9-46: The currency-conversion styles and template utilities use
non-grid spacing and raw visual literals. In currency-conversion.component.scss
lines 9-46, replace sizing, spacing, color, and typography values with
applicable shared SCSS/theme variables and 8px-grid values, preserving the
existing layout behavior. In currency-conversion.component.html lines 111-121,
replace gap-5px and m-r-10 with existing shared layout utilities that conform to
the 8px grid.
In
`@src/app/organization/exchange-rates/edit-exchange-rate/edit-exchange-rate.component.html`:
- Around line 9-219: Extract the duplicated exchange-rate form markup from the
edit-exchange-rate template and create-exchange-rate template into a shared
template or reusable component. Preserve each form’s existing differences,
including the edit Cancel router link and UPDATE_EXCHANGERATE permission, while
keeping the shared controls, validation messages, and submit behavior unchanged.
In
`@src/app/organization/exchange-rates/edit-exchange-rate/edit-exchange-rate.component.scss`:
- Around line 9-41: The exchange-rate form styles duplicate the create form’s
non-theme values and violate the 8px spacing grid. Update the selectors in
`.exchange-rate-form-grid` and `.form-error` to use the existing SCSS theme
variables from `main.scss` or `mifosx-theme.scss`, replacing the hardcoded color
and spacing values while preserving the current layout and field sizing.
In
`@src/app/organization/exchange-rates/edit-exchange-rate/edit-exchange-rate.component.ts`:
- Around line 63-111: Extract the duplicated exchange-rate form configuration
and payload construction from EditExchangeRateComponent’s createExchangeRateForm
and buildPayload into a shared abstraction, then reuse it from both edit and
create components. Preserve the existing validators, including the 0.0000001
minimum, field mappings, and payload behavior so the implementations cannot
drift.
- Around line 51-57: Replace the explicit any in the route.data subscription
within the component initialization flow with the structured currencies type
expected by resolveCurrencyOptions, including optional currencyOptions and
selectedCurrencyOptions arrays of Currency. Preserve the existing exchangeRate
typing and assignment behavior.
In `@src/app/organization/exchange-rates/exchange-rates.component.scss`:
- Around line 9-54: Replace off-grid spacing and sizing with approved shared
tokens across src/app/organization/exchange-rates/exchange-rates.component.scss
(lines 9-54): use shared padding helpers instead of padding: 20px, align the
grid gap, max-width, and font-size values to approved tokens, and remove
non-grid gap utilities if unused. Update exchange-rates.component.html lines 9
and 95 to use approved grid-aligned gap utilities, replacing gap-5px; update
view-exchange-rate.component.html lines 9 and 54 to replace gap-2px and
unresolved gap-2percent with approved 8px-grid spacing utilities.
In `@src/app/organization/exchange-rates/exchange-rates.component.ts`:
- Around line 146-160: Update the sortingDataAccessor in the exchange-rates
component to remove both any casts. Introduce a strictly typed
column-to-accessor mapping for the supported rate properties, use it for
buyRate, sellRate, and referenceRate with the existing zero fallback, and ensure
unsupported column names are not used to access arbitrary ExchangeRate fields.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: 5d6c1deb-563c-4cc4-93fc-d87dbb0ffb28
📒 Files selected for processing (41)
src/app/organization/exchange-rates/create-exchange-rate/create-exchange-rate.component.htmlsrc/app/organization/exchange-rates/create-exchange-rate/create-exchange-rate.component.scsssrc/app/organization/exchange-rates/create-exchange-rate/create-exchange-rate.component.spec.tssrc/app/organization/exchange-rates/create-exchange-rate/create-exchange-rate.component.tssrc/app/organization/exchange-rates/currency-conversion/currency-conversion.component.htmlsrc/app/organization/exchange-rates/currency-conversion/currency-conversion.component.scsssrc/app/organization/exchange-rates/currency-conversion/currency-conversion.component.spec.tssrc/app/organization/exchange-rates/currency-conversion/currency-conversion.component.tssrc/app/organization/exchange-rates/edit-exchange-rate/edit-exchange-rate.component.htmlsrc/app/organization/exchange-rates/edit-exchange-rate/edit-exchange-rate.component.scsssrc/app/organization/exchange-rates/edit-exchange-rate/edit-exchange-rate.component.tssrc/app/organization/exchange-rates/exchange-rate-form.util.tssrc/app/organization/exchange-rates/exchange-rate-validators.tssrc/app/organization/exchange-rates/exchange-rate.model.tssrc/app/organization/exchange-rates/exchange-rate.resolver.tssrc/app/organization/exchange-rates/exchange-rates.component.htmlsrc/app/organization/exchange-rates/exchange-rates.component.scsssrc/app/organization/exchange-rates/exchange-rates.component.tssrc/app/organization/exchange-rates/exchange-rates.resolver.tssrc/app/organization/exchange-rates/exchange-rates.service.spec.tssrc/app/organization/exchange-rates/exchange-rates.service.tssrc/app/organization/exchange-rates/view-exchange-rate/view-exchange-rate.component.htmlsrc/app/organization/exchange-rates/view-exchange-rate/view-exchange-rate.component.scsssrc/app/organization/exchange-rates/view-exchange-rate/view-exchange-rate.component.tssrc/app/organization/organization-routing.module.tssrc/app/organization/organization.component.htmlsrc/app/organization/organization.component.tssrc/app/organization/organization.module.tssrc/assets/translations/cs-CS.jsonsrc/assets/translations/de-DE.jsonsrc/assets/translations/en-US.jsonsrc/assets/translations/es-CL.jsonsrc/assets/translations/es-MX.jsonsrc/assets/translations/fr-FR.jsonsrc/assets/translations/it-IT.jsonsrc/assets/translations/ko-KO.jsonsrc/assets/translations/lt-LT.jsonsrc/assets/translations/lv-LV.jsonsrc/assets/translations/ne-NE.jsonsrc/assets/translations/pt-PT.jsonsrc/assets/translations/sw-SW.json
2026ccb to
ebd273c
Compare
There was a problem hiding this comment.
Actionable comments posted: 3
🧹 Nitpick comments (1)
src/app/organization/exchange-rates/currency-conversion/currency-conversion.component.scss (1)
9-46: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winUse the project spacing and theme tokens.
820px,260px,6px,14px, and4pxbreak the required 8px grid; the custom color fallbacks also bypass the shared theme variables. Replace these with established spacing/color variables and grid-aligned values.As per coding guidelines, “Stick to the 8px grid system” and “Leverage SCSS variables defined in
src/main.scssandsrc/theme/mifosx-theme.scss.”🤖 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/organization/exchange-rates/currency-conversion/currency-conversion.component.scss` around lines 9 - 46, Update .currency-conversion-form-grid and its nested/error styles to use the established spacing and color variables from the shared theme files instead of hardcoded values and custom fallbacks; replace 820px, 260px, 6px, 14px, and 4px with appropriate 8px-grid-aligned project tokens while preserving the existing layout and error styling.Source: Coding guidelines
🤖 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.
Inline comments:
In `@src/assets/translations/fr-FR.json`:
- Line 637: Update the French translation catalog entry for the `Filter` key to
use the existing French value `Filtre` instead of the English value `Filter`.
- Around line 781-782: Complete the French exchange-rate translations in
src/assets/translations/fr-FR.json: translate the action labels at lines
781-782, headings at 1605-1606, field labels at 3197-3203, and loading,
empty-state, validation, and error messages at 4199-4203, preserving all
existing translation keys and placeholders.
In `@src/assets/translations/lv-LV.json`:
- Line 637: Fully localize the Latvian translation catalog: restore the existing
Latvian value for Filter at src/assets/translations/lv-LV.json:637-637, and
translate Currency Conversion and Create Exchange Rate at
src/assets/translations/lv-LV.json:781-782, the exchange-rate navigation labels
at 1602-1603, the exchange-rate and conversion field labels at 3194-3200, and
the exchange-rate status and validation messages at 4196-4200. Preserve the
existing translation keys and JSON structure.
---
Nitpick comments:
In
`@src/app/organization/exchange-rates/currency-conversion/currency-conversion.component.scss`:
- Around line 9-46: Update .currency-conversion-form-grid and its nested/error
styles to use the established spacing and color variables from the shared theme
files instead of hardcoded values and custom fallbacks; replace 820px, 260px,
6px, 14px, and 4px with appropriate 8px-grid-aligned project tokens while
preserving the existing layout and error styling.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: 17d7113e-9259-4a8b-b45f-e3c268de994f
📒 Files selected for processing (43)
src/app/organization/exchange-rates/create-exchange-rate/create-exchange-rate.component.htmlsrc/app/organization/exchange-rates/create-exchange-rate/create-exchange-rate.component.scsssrc/app/organization/exchange-rates/create-exchange-rate/create-exchange-rate.component.spec.tssrc/app/organization/exchange-rates/create-exchange-rate/create-exchange-rate.component.tssrc/app/organization/exchange-rates/currency-conversion/currency-conversion.component.htmlsrc/app/organization/exchange-rates/currency-conversion/currency-conversion.component.scsssrc/app/organization/exchange-rates/currency-conversion/currency-conversion.component.spec.tssrc/app/organization/exchange-rates/currency-conversion/currency-conversion.component.tssrc/app/organization/exchange-rates/edit-exchange-rate/edit-exchange-rate.component.htmlsrc/app/organization/exchange-rates/edit-exchange-rate/edit-exchange-rate.component.scsssrc/app/organization/exchange-rates/edit-exchange-rate/edit-exchange-rate.component.tssrc/app/organization/exchange-rates/exchange-rate-form.util.tssrc/app/organization/exchange-rates/exchange-rate-validators.tssrc/app/organization/exchange-rates/exchange-rate.model.tssrc/app/organization/exchange-rates/exchange-rate.resolver.tssrc/app/organization/exchange-rates/exchange-rates-routing.module.tssrc/app/organization/exchange-rates/exchange-rates.component.htmlsrc/app/organization/exchange-rates/exchange-rates.component.scsssrc/app/organization/exchange-rates/exchange-rates.component.tssrc/app/organization/exchange-rates/exchange-rates.module.tssrc/app/organization/exchange-rates/exchange-rates.resolver.tssrc/app/organization/exchange-rates/exchange-rates.service.spec.tssrc/app/organization/exchange-rates/exchange-rates.service.tssrc/app/organization/exchange-rates/view-exchange-rate/view-exchange-rate.component.htmlsrc/app/organization/exchange-rates/view-exchange-rate/view-exchange-rate.component.scsssrc/app/organization/exchange-rates/view-exchange-rate/view-exchange-rate.component.tssrc/app/organization/organization-routing.module.tssrc/app/organization/organization.component.htmlsrc/app/organization/organization.component.tssrc/app/organization/organization.module.tssrc/assets/translations/cs-CS.jsonsrc/assets/translations/de-DE.jsonsrc/assets/translations/en-US.jsonsrc/assets/translations/es-CL.jsonsrc/assets/translations/es-MX.jsonsrc/assets/translations/fr-FR.jsonsrc/assets/translations/it-IT.jsonsrc/assets/translations/ko-KO.jsonsrc/assets/translations/lt-LT.jsonsrc/assets/translations/lv-LV.jsonsrc/assets/translations/ne-NE.jsonsrc/assets/translations/pt-PT.jsonsrc/assets/translations/sw-SW.json
💤 Files with no reviewable changes (1)
- src/app/organization/organization.module.ts
🚧 Files skipped from review as they are similar to previous changes (33)
- src/app/organization/exchange-rates/view-exchange-rate/view-exchange-rate.component.scss
- src/app/organization/exchange-rates/exchange-rates.component.scss
- src/app/organization/exchange-rates/edit-exchange-rate/edit-exchange-rate.component.scss
- src/app/organization/exchange-rates/exchange-rates.resolver.ts
- src/app/organization/exchange-rates/view-exchange-rate/view-exchange-rate.component.html
- src/app/organization/exchange-rates/create-exchange-rate/create-exchange-rate.component.scss
- src/app/organization/exchange-rates/exchange-rate.resolver.ts
- src/app/organization/organization.component.ts
- src/app/organization/exchange-rates/exchange-rate-form.util.ts
- src/app/organization/exchange-rates/edit-exchange-rate/edit-exchange-rate.component.ts
- src/app/organization/exchange-rates/exchange-rate-validators.ts
- src/app/organization/exchange-rates/exchange-rates.component.html
- src/app/organization/exchange-rates/edit-exchange-rate/edit-exchange-rate.component.html
- src/app/organization/exchange-rates/exchange-rate.model.ts
- src/app/organization/exchange-rates/create-exchange-rate/create-exchange-rate.component.ts
- src/app/organization/exchange-rates/view-exchange-rate/view-exchange-rate.component.ts
- src/app/organization/exchange-rates/create-exchange-rate/create-exchange-rate.component.html
- src/app/organization/exchange-rates/exchange-rates.service.spec.ts
- src/assets/translations/it-IT.json
- src/app/organization/exchange-rates/currency-conversion/currency-conversion.component.spec.ts
- src/assets/translations/ne-NE.json
- src/assets/translations/ko-KO.json
- src/assets/translations/sw-SW.json
- src/assets/translations/pt-PT.json
- src/app/organization/organization.component.html
- src/app/organization/exchange-rates/exchange-rates.service.ts
- src/assets/translations/cs-CS.json
- src/assets/translations/es-MX.json
- src/assets/translations/es-CL.json
- src/assets/translations/lt-LT.json
- src/assets/translations/de-DE.json
- src/app/organization/exchange-rates/exchange-rates.component.ts
- src/app/organization/exchange-rates/currency-conversion/currency-conversion.component.ts
Summary
Adds Web-App support for manually managing currency exchange rates through the existing Savings Plugin APIs.
The UI supports:
Automatic external-provider synchronization is not part of this PR.
Related issues and discussion
WEB-1035
Screenshot
Screen.Recording.2026-07-26.at.1.55.45.PM.mov
Testing
npm run lintnpx ng build --configuration developmentSummary by CodeRabbit