Skip to content

Fix 'Include organization name' cleared when unchecking 'Include user domain' in application subject settings#10541

Merged
PasinduYeshan merged 2 commits into
wso2:masterfrom
PasinduYeshan:fix/issue-7841
Jul 15, 2026
Merged

Fix 'Include organization name' cleared when unchecking 'Include user domain' in application subject settings#10541
PasinduYeshan merged 2 commits into
wso2:masterfrom
PasinduYeshan:fix/issue-7841

Conversation

@PasinduYeshan

Copy link
Copy Markdown
Contributor

Problem

In the Console application editor (User Attributes → Subject → "Assign alternate subject identifier"), un-checking Include user domain while Include organization name was checked silently cleared the organization-name flag on save (and vice versa). The persisted configuration came back with both flags off.

Fix

The two subject-domain checkboxes (Field.CheckboxLegacy) had no external state and no listen handler, so their value was tracked only inside react-final-form on an uncontrolled checkbox and was lost on a sibling re-render. Give both parent-owned React state with listen handlers and read that state in submitValues, mirroring the existing linked-account checkboxes. The two flags now persist independently.

Single-file, Console-UI only. No server-side, REST, or config change.

Fixes wso2/product-is#28180

@coderabbitai

coderabbitai Bot commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yml

Review profile: CHILL

Plan: Pro

Run ID: bddb6be5-a3bb-427e-ba0b-25fadffc4eed

📥 Commits

Reviewing files that changed from the base of the PR and between 68f2289 and 4f1b4d6.

📒 Files selected for processing (1)
  • .changeset/subject-domain-flags-independent.md
🚧 Files skipped from review as they are similar to previous changes (1)
  • .changeset/subject-domain-flags-independent.md

📝 Walkthrough

Walkthrough

The application attribute settings form now tracks user-domain and tenant-domain subject identifier options independently, submits both values separately, and records the fix in a patch Changesets entry.

Changes

Subject domain flag persistence

Layer / File(s) Summary
Independent checkbox state
features/admin.applications.v1/components/settings/attribute-management/advance-attribute-settings.tsx
User-domain and tenant-domain checkbox values now use separate local state and change handlers.
Independent subject payload persistence
features/admin.applications.v1/components/settings/attribute-management/advance-attribute-settings.tsx, .changeset/subject-domain-flags-independent.md
Submission uses the independent state values, with a patch Changesets entry documenting the fix.

Possibly related PRs

  • wso2/identity-apps#10515: Updates the same settings component to preserve checkbox-related values in the submission payload.

Suggested reviewers: pavindulakshan

🚥 Pre-merge checks | ✅ 6
✅ Passed checks (6 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly describes the main bug fix in application subject settings.
Description check ✅ Passed The description covers the problem, fix, scope, and linked issue, though it omits several template sections and checklist items.
Linked Issues check ✅ Passed The code changes match issue #28180 by preserving each subject-domain checkbox independently during save.
Out of Scope Changes check ✅ Passed The only extra change is a changeset entry, which is consistent with documenting the fix and not out of scope.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Changeset Required ✅ Passed The PR’s changed files include .changeset/subject-domain-flags-independent.md, and it lists the required package updates including @wso2is/console.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • 🛠️ create changeset

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 requested a review from pavinduLakshan July 15, 2026 08:26
@codecov

codecov Bot commented Jul 15, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 72.85%. Comparing base (08887b1) to head (4f1b4d6).
⚠️ Report is 8 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master   #10541   +/-   ##
=======================================
  Coverage   72.85%   72.85%           
=======================================
  Files         470      470           
  Lines       71228    71228           
  Branches      240      240           
=======================================
  Hits        51892    51892           
  Misses      19225    19225           
  Partials      111      111           
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Comment thread .changeset/subject-domain-flags-independent.md
@PasinduYeshan
PasinduYeshan merged commit 669306f into wso2:master Jul 15, 2026
6 checks passed
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.

[IS 7.1.0] Issue in enabling the 'Include Organisation name' in applications

2 participants