- Updated imports for better readability in LicenseApplicationPage.
- Introduced legacy profile sources for backward compatibility in LicenseApplicationPage.
- Enhanced user profile handling by utilizing accountUser in LicenseApplicationPage.
- Improved application state management in LicenseApplicationPage to include accountUser.
- Refactored RequireSeafarerProfile to check for existing applications and handle navigation accordingly.
- Cleaned up navigation items in PortalLayout for better readability and maintainability.
- Created error context markdown files for failed tests in seafarer registration, detailing validation errors related to profile details.
- Added binary files (PNG, ZIP, WEBM) for test results, including snapshots and traces for debugging purposes.
- Updated test cases to include new error context and media files for better analysis of failures.
/seafarer-registration had a page of its own that wrote the profile directly
and created no application at all. A "submitted" registration was therefore
never reviewed, never approved and never numbered — there was nothing for an
officer to open. The shared wizard, the review queue and the approval side
effects all already existed; only the route pointed away from them.
The page is deleted rather than repaired. It was a second wizard maintained
alongside the config-driven one, and the seed already describes every step it
was hand-rolling — including the physical characteristics and medical details
added this release, which it would not have known about. /seafarer-registration
now redirects, so navigation, deep links and the profile gate keep working.
Also adds Configuration -> Number Formats, for the shape of generated seafarer,
seaman book and BTC numbers. The sample is rendered by the server rather than
formatted here, so the preview cannot drift from what an approval will actually
generate, and asking for one never consumes a number.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
The approved single-page register -- with the detail modal that shows a
seafarer's full standing -- had been replaced by a three-file grid that
carried no profile view. That is why the seafarer profile appeared
missing from the backoffice entirely.
Restores his page and points it at /seafarer-registry. The list is
served whole and filtered in the browser: the filters are instant facets
over a page-sized list, and a round trip per keystroke would make the
search feel slower than the data it searches.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
/seafarer-registration was wrapped in RequireSeafarerProfile, which sends
an applicant with an incomplete profile to /profile first. That gate
belongs to the replacement design, where registration is filled in from
the profile. Mengestab's approved wizard asks for those same personal,
identity and contact details itself across its four steps, so the gate
bounced the applicant out before they ever saw the form -- which is why
the approved UI looked missing rather than merely unreachable.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Both listed hardcoded samples -- a CoC application permanently awaiting
examination, an endorsement from Greece. They now show the seafarer's
own certificates and applications.
Status badges are keyed by the workflow's own values rather than display
strings, so a status the map has not seen falls back to grey instead of
rendering colourless, and the label is derived from the status itself
rather than stored beside it where the two can disagree.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
These three carried hardcoded sample data -- a certificate expiring in
2026, a fully-ticked training list, an eligibility checklist that always
passed. They now read the portal endpoints and show the seafarer's own
record.
Expiry is taken from the server rather than recomputed in the browser:
it is the same figure the eligibility gate uses, and a client clock that
is wrong or in another timezone would otherwise show a seafarer a
different number than the officer sees. Eligibility likewise -- the
screen asks whether it may apply rather than deciding for itself, so it
cannot offer a button the API then refuses.
The seaman-book stepper is derived from the application's status instead
of a stored timeline, because the status is what the workflow actually
moves; a second record of the same journey would only drift out of step.
Status colours are keyed by the workflow's own values, so an unmapped
status falls back to grey rather than vanishing.
/medical and /basic-safety-training had no route at all -- both silently
fell through to the dashboard, which is why the pages looked unreachable
rather than merely unwired.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Restores three pages the current router imports that Mengestab's branch
never had -- MySeaRecordsPage, VesselTransferPage,
VesselRegistrationStatusPage -- from history, along with the vessel
mock module the status page reads.
Also fixes a dead comparison in VesselRegistrationPage: the block only
renders while a registration is *not* approved, so the nested
`status === 'Approved'` inside it is provably false and TypeScript
refuses it. Rendering behaviour is unchanged.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Copied verbatim from the pre-override branch so the approved screens are
recoverable at this exact commit before any wiring changes them.
Brings back the richer flows the client signed off: a four-step seafarer
registration wizard with bilingual inputs and an Ethiopic date picker,
the vessel-owner portal (its own register/login/dashboard), ownership
transfer, and the seaman book, certificate, medical and endorsement
screens.
Six of these pages already call an API; ten are mockups carrying
hardcoded data. Both are committed as-is here -- the wiring that follows
is a separate commit so the diff shows exactly what changed from what
the client approved.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Seafarer and vessel registration were filtered out of the operations
step by `requiresOperatorMode !== false`, so someone registering as a
seafarer or vessel owner landed on an onboarding screen that did not
describe them. Both now appear, grouped apart from the company modes:
declaring "I am a seafarer" is a different kind of statement from "my
company forwards freight".
The designer's preview was gated on the Handlebars source alone, which a
canvas layout does not have until the server compiles it on save -- so
the button was dead for exactly the designs the canvas exists for.
Editing looked broken rather than deliberately read-only: every seeded
template is PUBLISHED, and a published design is immutable because
certificates were issued from it. Says so, and offers the new-version
action that is the way forward.
Reviewing officers saw company, capital and staff tabs on seafarer
certificate applications, because PRESENTATION is keyed by the generic
licence keys and the fifty-odd rank-specific CoC/CoP keys fell through
to the company default. Matched by prefix instead, so a certificate
configured tomorrow gets the right presentation without a code change.
Seaman book and BTC are wired to the newly seeded licence types and no
longer marked "soon".
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
- Implemented ExamStageActions component to manage actions related to exam booking and payment based on application status.
- Added mock-base-query for development, providing a partial mock backend for various API endpoints.
- Introduced mock-data for simulating responses in the mock-base-query, covering profiles, vessels, applications, licenses, exams, and notifications.
- Introduced `landing-copy.ts` containing text for the public landing page, supporting both English and Amharic languages.
- Added `landing.css` for styling the landing page, ensuring scoped styles to prevent conflicts with other app styles.
- Implemented smooth scrolling and animations for a better user experience.
- Added RequirePermission component to manage access based on user permissions.
- Integrated permission checks in MySeaRecordsPage, SeafarerRegistrationPage, VesselRegistrationPage, WaiverPage, and PortalLayout.
- Updated router to enforce permissions for specific routes.
- Introduced PORTAL_PERMISSIONS and LICENSE_PERMISSIONS constants for consistent permission management.
- Enhanced usePermissions hook to fetch permissions from the server and determine access rights.
- Refactored UI components to conditionally render based on user permissions, improving security and user experience.
Resolved by unifying on the lib/data AdvancedTable (PR #10) as the canonical
table component: kept its API plus teammate i18n/feature work, kept the
folder-per-table structure (index.tsx + columns.tsx + actions.tsx) across all
27 tables, removed the parallel lib/table implementation, and fixed
pre-existing compile breaks in ExamDetailPage/QuestionAssigner/RecordResultModal.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
feat(waiver): implement waiver page with application tracking and letter download feature
feat(ui): introduce AdvancedTable component for enhanced table functionality across the application
chore: update package-lock.json to remove unnecessary dependencies
- Added useLocalized hook to provide a stable function for retrieving bilingual values based on the current language.
- Updated various components across the portal and backoffice to utilize the new useLocalized hook for consistent bilingual label rendering.
- Refactored localized function in licensing.helpers to handle empty Amharic strings correctly.
- Enhanced localization handling in LicenseApplicationPage, ProfilePage, and other components to ensure proper language switching.