feat: connect organization settings profile to backend#455
Merged
codeZe-us merged 1 commit intoApr 29, 2026
Merged
Conversation
- Add src/lib/api/organization.ts with OrganizationApi.getProfile() and OrganizationApi.updateProfile() wrapping GET/PUT /api/v1/company/profile - Pre-fill company-info page from API on mount; submit calls updateProfile - Pre-fill billing-address page from profile.billing; submit persists changes - Pre-fill registered-address page from profile.registered; submit persists changes - Update settings/page.tsx to fetch real org data on mount: company name, registration number, country, and address fields all reflect live API data - Addresses section shows saved address text with Edit link, or an add prompt when empty Closes SafeVault#427
|
@MooreTheAnalyst is attempting to deploy a commit to the vestroll's projects Team on Vercel. A member of the Team first needs to authorize it. |
codeZe-us
approved these changes
Apr 29, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this PR does
Connects the Organization Settings pages to the backend so administrators can view and update their company's operational details in real time.
Changes
src/lib/api/organization.ts(new):OrganizationApiwithgetProfile()andupdateProfile()wrappingGET/PUT /api/v1/company/profile.settings/page.tsx: fetches real org data on mount — company name, registration number, country, and addresses are all live. Addresses section shows saved values with an Edit link, or an add prompt when empty.settings/company/company-info/page.tsx: pre-fills from the API on load; submits name, registration number, and country viaupdateProfile.settings/company/addresses/billing-address/page.tsx: pre-fills fromprofile.billing; submits billing address fields.settings/company/addresses/registered-address/page.tsx: pre-fills fromprofile.registered; submits registered address fields.All forms show a loading state while fetching, a saving state on submit, and inline success/error feedback.
Testing
TypeScript type-check passes with no errors in the changed files (
npx tsc --noEmit).Closes #427