Commit Graph

647 Commits

Author SHA1 Message Date
Nati Nigussie
d18a91b061 Merge pull request #33 from Tria-plc/estif-branch-1
EMALICENSI-36 fixes
2026-08-27 10:43:52 +03:00
estifanos
f01c0ec31e feat: add INSPECTION_FAILED state, enforce inspection scheduling locks, and improve adjustment round UI for section locking and remark labeling 2026-08-27 07:36:07 +00:00
Mihretu Endeshaw
f7c886d59b Merge pull request #32 from Tria-plc/feature/exam-attempt-domain
Feature/exam attempt domain
2026-08-27 10:25:43 +03:00
Estifo77
b85281812d Merge branch 'WorkflowChange' of https://github.com/Tria-plc/emaui into estif-branch-1 2026-08-27 10:10:43 +03:00
estifanos
4ec585f407 feat: include location and physical attributes in seafarer registration default answers 2026-08-27 06:47:44 +00:00
Nati Nigussie
c94811900d Merge pull request #31 from Tria-plc/WorkflowChange
Remove 'assign-reviewer' action and related functionality from licens…
2026-08-26 17:12:08 +03:00
Nati
580ceaa139 Remove 'assign-reviewer' action and related functionality from license review process 2026-08-26 14:08:09 +00:00
Nati Nigussie
64bf89d8e8 Merge pull request #30 from Tria-plc/WorkflowChange
Workflow change
2026-08-26 16:37:53 +03:00
Nati
2a16ca8584 Merge branch 'WorkflowChange' of github.com:Tria-plc/emaui into WorkflowChange 2026-08-26 13:34:24 +00:00
Nati
b5f1ffa6b8 Add 'assign-reviewer' action and related functionality for license review process 2026-08-26 13:34:06 +00:00
Nati Nigussie
55f2eec924 Merge pull request #29 from Tria-plc/WorkflowChange
Workflow change
2026-08-26 15:36:46 +03:00
Nati Nigussie
3644350e42 Merge pull request #25 from Tria-plc/estif-branch-1
fixes on vessel report by tade
2026-08-26 15:34:40 +03:00
estifanos
3955dab014 adding bypass payment 2026-08-26 12:17:46 +00:00
estifanos
f20ed670de fixes on backoffice for endorcement 2026-08-26 12:12:30 +00:00
estifanos
32ac18adc2 endorcement 2026-08-26 11:52:13 +00:00
Estifo77
08e9b73b8f Merge branch 'WorkflowChange' of https://github.com/Tria-plc/emaui into estif-branch-1 2026-08-26 13:27:12 +03:00
estifanos
b099870370 fix: prevent out-of-bounds wizard steps and remove duplicate FieldCondition property definition 2026-08-26 09:52:31 +00:00
estifanos
3cab22b58d fix: update conditional requirement validation to allow expressions using anyOf without a field 2026-08-26 09:44:37 +00:00
estifanos
13c3e8974d feat: consolidate CoC and GOC endorsement workflows into a new ENDORSEMENT_SEAFARER type and add anyOf support to conditional form field logic. 2026-08-26 09:44:08 +00:00
Nati Nigussie
8ca375a114 Merge pull request #28 from Tria-plc/WorkflowChange
Workflow change
2026-08-26 12:19:31 +03:00
Nati
207994df69 Implement nationality-based document requirements and add cancellation feature for seafarer registration 2026-08-26 09:14:45 +00:00
mihretue
c753009ed9 refactor(api): resolve the backend URL in one place
VITE_BASE_API_URL with a localhost:3001/api fallback was re-derived in six
files across libs/api, libs/auth, the portal and the backoffice — and a seventh
site (UserManagementPage) read the env raw with no fallback at all, handing the
IAM user-management app an undefined apiUrl whenever no .env was present.

BASE_API_URL in base-query-with-reauth.ts is now the single definition,
exported from @ema-platform/api; every other site imports it. Trims the env
value and treats blank as unset, matching how the backend reads its own keys.
2026-08-26 09:09:25 +00:00
mihretue
5ad43ba760 fix(exam): step the exam form instead of validating hidden tabs
Submitting from Basic Info complained that required fields on the Settings
tab were empty — a correct error the user could not act on, since Settings
had not been shown yet.

The primary action now reads "Next" while Basic Info is open and validates
only that tab before moving on; Create/Update appears on Settings, the final
step, alongside a Back button. Submit still checks both tabs, since the tab
headers stay clickable and a user can reach Settings without going through
Next.
2026-08-26 06:24:49 +00:00
Estifo77
a86f4750bc Merge branch 'WorkflowChange' of https://github.com/Tria-plc/emaui into estif-branch-1 2026-08-26 08:43:31 +03:00
mihretue
baea9f2b57 chore(dev): serve the portal on 3000 for the Fayda redirect
The Fayda redirect URI registered for local testing is
http://localhost:3000/callback, matched exactly by the provider, so the portal
has to be the thing listening there. Its dev and preview servers move from 4200
to 3000 and the API moves to 3001.

Every hardcoded fallback to http://localhost:3000/api follows — six copies of
the same default across libs/api, libs/auth, the portal and the backoffice —
otherwise a developer without a .env would have had the app calling itself.

e2e is unaffected: it binds its own ports (3011/4302/4303) explicitly.
2026-08-25 19:04:27 +00:00
mihretue
16a5dec734 docs(env): add the .env.example the README already told people to copy
README.md line 72 says `cp .env.example .env`, but no such file existed and
.gitignore's `.env.*` rule would have swallowed it — hence the explicit
negation alongside it.

Documents the two variables the code actually reads, VITE_BASE_API_URL and
VITE_USE_MOCKS, rather than the longer list in the README, none of which is
referenced anywhere in apps/ or libs/. Notes that Vite resolves this from the
workspace root via envDir, and that Fayda needs nothing here beyond the callback
path matching the API's FAYDA_REDIRECT_URI.
2026-08-25 18:18:02 +00:00
mihretue
0582c311c9 feat(signup): serve the Fayda callback at /callback too
Fayda matches the registered redirect URI exactly, and the value being
registered first is a bare /callback. The descriptive path stays so the route
still reads as part of signup once that can be changed.
2026-08-25 13:24:29 +00:00
mihretue
c4c84abc66 refactor(signup): drive Fayda through register-with-fayda
Follows the API back to a single endpoint. The page posts { action: 'start' }
to open the attempt, the callback page posts { action: 'verify', ... } to get
the verified identity, and the existing signup submission is unchanged.

Drops the post-signup link call: there is no longer a link endpoint, and the
account is created by the signup endpoint that already owns user creation.
2026-08-25 13:01:40 +00:00
mihretue
933ba41476 feat(signup): verify identity with Fayda and prefill the form
Adds "Continue with Fayda" to the existing signup page. It is an alternative
way to fill the form, not a second signup: the applicant still submits to
/auth/signup-with-pwd through the same schema, the same validation and the same
redirect to OTP verification, and signing up without Fayda is unchanged.

The page asks the API for an authorization URL, keeps the returned handle and
state in sessionStorage for the round trip, and FaydaCallbackPage hands the
code back to /auth/fayda/callback. No Fayda protocol logic lives here — the
PKCE verifier, the client key and the token exchange stay on the server. Once
the account exists the page posts the verification token to /auth/fayda/link so
the identity is recorded against it; that call is best-effort, since the
account is already usable without it.

Prefilled fields carry a "From Fayda" badge and stay editable, and a value
that already belongs to another account is badged as such so the applicant can
see which one to change rather than reading a single opaque signup error.
Cancellation, an expired session, a mismatched state and an incomplete callback
each get their own message.

Amharic strings are a first pass and want a native speaker's review.
2026-08-25 12:30:57 +00:00
Nati
bd65fc0eab Enhance certificate designer and seafarer registration features with image support and dynamic department/rank options 2026-08-24 14:15:55 +00:00
mihretue
b49de1c1a8 fix(exam): guard question assignment once the paper is locked
The detail page fired assign/draw requests blind and surfaced the raw
backend key to the user — a locked paper showed up as the literal string
"paper_locked_after_registration" in a toast.

Manage Questions is now disabled once any candidate has registered, with a
tooltip and badge explaining why; both the manual assign and the random draw
live behind that modal, so one guard covers the same ground the backend's
assertPaperEditable does. The empty-paper alert now explains the deadlock
instead of telling the user to click a button that will fail, and both
error handlers translate paper_locked_after_registration in case someone
registers while the modal is open.

Registrations come from the query ExamCandidatesPanel already runs on this
page, so RTK Query serves it from cache rather than issuing a second request.
2026-08-24 14:04:24 +00:00
mihretue
34208ed0d6 feat(exam): show candidate answers + prefill auto-scores in RecordResultModal
Wires useGetGradingSheetQuery into the grading modal: a new 'Candidate's
Answer' column shows the selected option or essay text per question, and
whichever CHOICE scores auto-grading could already compute get prefilled
into the score inputs (tagged 'Auto-graded', still editable — the examiner
can override). Grading a mixed or ESSAY paper no longer means guessing at
what was answered or re-deriving the CHOICE portion by eye.

Degrades to blank inputs exactly as before for an OFFLINE candidate or one
who hasn't sat an online attempt (gradingSheet returns empty answers for
those, not an error).
2026-08-24 13:02:08 +00:00
mihretue
e0ed10b823 Merge remote-tracking branch 'origin/dev' into feature/exam-attempt-domain
# Conflicts:
#	apps/backoffice/src/app/features/exam/pages/ExamDetailPage.tsx
2026-08-24 12:59:11 +00:00
mihretue
35961ec809 feat(exam): let ONLINE exams take ESSAY/BOTH form, add grading-sheet API
Frontend half of the backend change: ExamPage no longer disables the
form Select or force-resets it to CHOICE when administrationMethod is
ONLINE (backend's assertOnlineIsChoiceOnly is gone, matching gate
removed here). Also wires up GET .../grading-sheet as
useGetGradingSheetQuery — RecordResultModal wiring (show candidate
answers, prefill auto-computed CHOICE scores) is next.
2026-08-24 12:57:37 +00:00
Nati Nigussie
60c93453a7 Merge pull request #27 from Tria-plc/WorkflowChange
Workflow change
2026-08-24 15:39:28 +03:00
Nati
4a3ad7c2e6 Merge branch 'WorkflowChange' of github.com:Tria-plc/emaui into WorkflowChange 2026-08-24 12:37:42 +00:00
Nati
294a8ded6c Refactor exam form handling to support mixed paper types and update related interfaces 2026-08-24 12:37:06 +00:00
mihretue
9f8f29d614 fix(exam): stop hiding non-CHOICE questions from OFFLINE assignment picker
eligibleQuestions filtered by q.form === exam.form, which matched the
backend's own restriction (assertUsable) only for ONLINE exams. Once
exam.form gained the "BOTH" value for OFFLINE mixed papers, no question
ever has form "BOTH", so the picker silently emptied out or, for a
plain CHOICE-form exam, looked CHOICE-only regardless of administration
method. Now mirrors the backend: CHOICE-only gate applies only when
administrationMethod is ONLINE.
2026-08-24 11:30:56 +00:00
mihretue
97ebff3b21 Merge remote-tracking branch 'origin/dev' into feature/exam-attempt-domain 2026-08-24 11:25:31 +00:00
Nati Nigussie
d03164f639 Merge pull request #26 from Tria-plc/WorkflowChange
Workflow change
2026-08-24 12:17:08 +03:00
nati14575
ff47c7b0aa Add support for "BOTH" exam form type and update translations 2026-08-24 12:13:18 +03:00
Nati
895690de80 Fix for rank selection 2026-08-24 08:20:13 +00:00
Nati
a84177cf12 Fix 2026-08-24 07:49:10 +00:00
Nati
302c0242dd Add rank selection and condition handling to certificate designer and requirements 2026-08-24 07:39:24 +00:00
Nati
1af7e90c21 Merge branch 'WorkflowChange' of github.com:Tria-plc/emaui into WorkflowChange 2026-08-24 06:13:50 +00:00
Nati
f973bff641 Add Rank and Department management to ConfigurationPage with new RankDepartmentTab 2026-08-24 06:13:43 +00:00
estifanos
573b203422 refactor: remove bypass payment capability check and enable bypass button unconditionally 2026-08-22 08:01:18 +00:00
estifanos
3d6deb03f6 feat: add payment and bypass actions to the in-flight vessel registration application table 2026-08-22 07:58:08 +00:00
Fistum
0ac969cca2 logestics chnage 2026-08-22 07:54:35 +00:00
estifanos
ae0dfdece3 refactor: update vessel registration route path in onboarding navigation 2026-08-22 06:57:22 +00:00