Skip to content

feat(account): apply the other category controls in every country - #23312

Open
AlexisAfonso wants to merge 7 commits into
feat/f1onManagerTurkiyefrom
MANAGER-22960
Open

AlexisAfonso wants to merge 7 commits into
feat/f1onManagerTurkiyefrom
MANAGER-22960

Conversation

@AlexisAfonso

Copy link
Copy Markdown
Contributor

Description

The standalone "Autre" category (legalform = other) is removed from the rules of every country on the API side (CM-448). This PR extends to every country, with no country list, what #23263 does for FR and TR:

  • Account edition (newAccountForm): the "Autre" controls (error under the category, blocked save, company data warning when switching to corporation, association or administration) apply to every account. isOtherCategoryControlActive and OTHER_CATEGORY_COUNTRIES are removed.
  • Container home reminder (OtherCategoryModal): shown to every account still in "Autre". French accounts keep the e-invoicing reform wording and link; the others get other_category_modal_description_generic (renamed from _tr, fr_FR only, other locales through translation). The account:fr-e-invoicing-other-category flag still only gates the reminder.
  • Account creation: no change, the account-creation app already filters "other" and the legacy sign-up follows the rules.

Ticket Reference: #MANAGER-22960

Additional Information

🤖 Generated with Claude Code

jmalnuit and others added 6 commits October 1, 2026 15:27
F1 Turkey - accounts whose address country is TR get a mandatory
MERSIS No (16 digits) for company legal forms, the VAT field
relabelled "Numéro de KDV" (10 digits) and an "I have a VAT number"
checkbox that makes the KDV mandatory.

The e-invoicing "Autre" category controls (MANAGER-22014, behind the
account:fr-e-invoicing-other-category flag) now also apply to Turkey,
and the generic FR validation warning gives way to the category switch
warning instead of repeating it.

Signed-off-by: jmalnuit <jonathan.malnuit@ovhcloud.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
The "Autre" category reminder (OtherCategoryModal) now also applies to
Turkish accounts. A new missing-CNIN reminder is queued right after it,
for FR/TR accounts carrying the missingCNIN certificate (provisional
value, still to be confirmed): at most once an hour, with a CTA to the
CNIN field of the account edition; its description names the local
identifier (SIRET in France, MERSIS No in Turkey).

Signed-off-by: jmalnuit <jonathan.malnuit@ovhcloud.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
For a TR address, the MERSIS No is mandatory (16 digits) for company
legal forms, the VAT label is looked up by country ("KDV", Turkey not
being a subsidiary) and an "I have a VAT number" checkbox makes the
KDV (10 digits) mandatory.

Signed-off-by: jmalnuit <jonathan.malnuit@ovhcloud.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
The e-invoicing "Autre" controls of the account edition form (error,
blocked save, company-data warning) now always apply to FR and TR
customers: they are a lasting rule. The
account:fr-e-invoicing-other-category flag only gates the temporary
home reminder (OtherCategoryModal).

Signed-off-by: jmalnuit <jonathan.malnuit@ovhcloud.com>
RG1 asks for the reminder "at every login": once dismissed, it now stays
closed for the rest of the browser session instead of coming back on
every page load. Turkish accounts get the same request without the
French e-invoicing reform wording and its economie.gouv.fr link.

Signed-off-by: jmalnuit <jonathan.malnuit@ovhcloud.com>
The standalone "Autre" category is removed from the rules of every
country (backend CM-448). The account edition controls (error, blocked
save, company data warning) and the home reminder now apply to every
account still in "Autre", with no country list. Only French accounts
keep the e-invoicing reform wording and link; the others get the same
request without them (fr_FR source, other locales through translation).

ref: #MANAGER-22960

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Alexis AFONSO <alexis.afonso@ovhcloud.com>
(user?.country ?? '').toUpperCase() === 'TR';
// The French e-invoicing reform wording and its economie.gouv.fr link only make
// sense in France; every other account gets the same request without them.
export const isFrenchAccount = (user?: Pick<User, 'country'> | null) =>

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

We only check for country FR without DROM

The French e-invoicing reform also reaches the overseas territories:
the other category reminder keeps its reform wording and link for them,
with the territory list of the company information modal.

ref: #MANAGER-22960

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Alexis AFONSO <alexis.afonso@ovhcloud.com>
@AlexisAfonso
AlexisAfonso marked this pull request as ready for review October 29, 2026 09:43
Copilot AI balanced review requested due to automatic review settings October 29, 2026 09:43
@AlexisAfonso
AlexisAfonso requested a review from a team as a code owner October 29, 2026 09:43
@AlexisAfonso
AlexisAfonso requested review from MehdiZaghouani, achrafHafedh and aottr and removed request for a team October 29, 2026 09:43

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Note

Copilot was unable to run its full agentic suite in this review.

Copilot review overview

2 open issues
What changed in this PR

This PR expands the “Autre” (legalform === other) category handling from FR/TR-only to all countries, and adjusts the container modal wording/link behavior to be France-specific while keeping a generic message elsewhere.

Changes:

  • Apply “Autre” category controls globally (remove country gating) and add/adjust unit tests.
  • Update the “OtherCategoryModal” to show the French reform link/text only for French territories; show a generic message otherwise.
  • Remove now-obsolete OTHER_CATEGORY_COUNTRIES constant and update related translations/tests.
File Description
packages/​manager/​modules/​account/​src/​user/​components/​newAccountForm/​new-account-form-controller.js Removes country gating so “Autre” controls apply to all countries.
packages/​manager/​modules/​account/​src/​user/​components/​newAccountForm/​new-account-form-controller.spec.js Adds tests ensuring “Autre” selection blocks save and warning behavior is correct across countries.
packages/​manager/​modules/​account/​src/​user/​components/​newAccountForm/​new-account-form-component.constants.js Deletes OTHER_CATEGORY_COUNTRIES constant as it’s no longer needed.
packages/​manager/​apps/​container/​src/​components/​other-category-modal/​otherCategoryModal.helpers.ts Makes “Autre” detection global; introduces isFrenchAccount to gate French reform wording/link.
packages/​manager/​apps/​container/​src/​components/​other-category-modal/​otherCategoryModal.helpers.spec.ts Updates/extends tests for global “Autre” and new isFrenchAccount.
packages/​manager/​apps/​container/​src/​components/​other-category-modal/​OtherCategoryModal.component.tsx Shows <Trans> + link for FR territories; otherwise shows generic text without link.
packages/​manager/​apps/​container/​src/​components/​other-category-modal/​OtherCategoryModal.spec.tsx Updates tests to assert France-specific vs generic rendering.
packages/​manager/​apps/​container/​src/​public/​translations/​other-category-modal/​Messages_fr_FR.json Renames TR-specific description key to a generic one for non-French accounts.
packages/​manager/​apps/​container/​src/​components/​other-category-modal/​otherCategoryModal.constants.ts Updates comment to reflect feature-flag scope change.
packages/​manager/​apps/​container/​src/​components/​compliance-reminder-modal/​complianceReminderModal.constants.ts Updates comment to reflect OtherCategoryModal now applies to all countries.

Review effort: Lite

Comment on lines +13 to +16
export const isFrenchAccount = (user?: Pick<User, 'country'> | null) =>
CERTIFICATE_CHECK_COUNTRIES.includes(
(user?.country ?? '').toUpperCase() as Country,
);
Comment on lines +219 to +220
built.ctrl.model = { country, legalform: current };
built.ctrl.originalModel = { country, legalform: original };
@AlexisAfonso
AlexisAfonso force-pushed the feat/f1onManagerTurkiye branch from a129c16 to 506af23 Compare October 30, 2026 12:24
@github-actions github-actions Bot added the has conflicts Has conflicts to resolve before merging label Oct 30, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

container has conflicts Has conflicts to resolve before merging translation required

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants