Skip to content

fix: read addressStreet/addressPostcode directly from API; show — when empty#691

Merged
need4deed merged 2 commits into
developfrom
fix/657-address-editable
Jun 17, 2026
Merged

fix: read addressStreet/addressPostcode directly from API; show — when empty#691
need4deed merged 2 commits into
developfrom
fix/657-address-editable

Conversation

@nadavosa

Copy link
Copy Markdown
Collaborator

Summary

  • ApiAgentProfileGet.agentDetails extended locally with addressStreet?: string | null and addressPostcode?: string | null (mirrors fix: expose addressStreet and addressPostcode in agent GET; remove Berlin fallback be#694)
  • OrganisationDetails.tsx now initialises the edit form from details.addressStreet / details.addressPostcode directly instead of calling parseAddress() on the serialised string
  • parseAddress removed from formatters.ts (no longer needed)
  • Display mode shows "—" when address is empty (BE no longer returns "Berlin" as fallback)

Closes #657
Depends on need4deed-org/be#694 (must be merged first)

Test plan

  • Agent with address: street and postcode fields pre-populated correctly in edit form
  • Agent with no address: edit form starts empty, display shows "—"
  • Editing and saving address updates both fields via PATCH
  • No "Berlin" phantom address shown for agents with no real address

🤖 Generated with Claude Code

nadavosa and others added 2 commits June 17, 2026 11:00
Now that BE PR #694 exposes addressStreet and addressPostcode in
agentDetails, initialize the edit form from those fields instead of
parsing the serialized address string. Display shows "—" when no
address is set (BE no longer returns "Berlin" as a fallback).

Closes #657
Depends on need4deed-org/be#694

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@need4deed need4deed merged commit d9d387c into develop Jun 17, 2026
1 check passed
@need4deed need4deed deleted the fix/657-address-editable branch June 17, 2026 09:11
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.

fix: agent profile — make address editable and stop showing 'Berlin' fallback

2 participants