Merge branch 'WorkflowChange' of github.com:Tria-plc/emaui into WorkflowChange

This commit is contained in:
Nati
2026-08-24 12:37:42 +00:00
5 changed files with 27 additions and 27 deletions

View File

@@ -67,7 +67,11 @@ const STATUS_TONE: Record<string, StatusTone> = {
PUBLISHED: 'success',
};
const FORM_LABEL: Record<string, string> = { ESSAY: "Essay", CHOICE: "Choice" };
const FORM_LABEL: Record<string, string> = {
ESSAY: "Essay",
CHOICE: "Choice",
BOTH: "Both",
};
const TYPE_LABEL: Record<string, string> = { WRITTEN: "Written", ORAL: "Oral" };
const ADMIN_LABEL: Record<string, string> = {
OFFLINE: "Offline",

View File

@@ -249,6 +249,7 @@ function ExamForm({
data={[
{ value: "ESSAY", label: t("exam.form.essay") },
{ value: "CHOICE", label: t("exam.form.choice") },
{ value: "BOTH", label: t("exam.form.both") },
]}
value={form}
onChange={setForm}

View File

@@ -15,12 +15,7 @@ export type ExamAdministrationMethod = "OFFLINE" | "ONLINE";
export type ExamEvaluationMethod = "SUM" | "AVERAGE" | "PERCENTAGE";
export type ExamSelectionMethod = "MANUAL" | "RANDOM";
export type ExamStatus =
| "PENDING"
| "ACTIVE"
| "COMPLETED"
| "CANCELLED"
| "POSTPONED"
| "PUBLISHED";
"PENDING" | "ACTIVE" | "COMPLETED" | "CANCELLED" | "POSTPONED" | "PUBLISHED";
/** Only populated when the exam is fetched with `?i=questions,questions.options`. */
export interface QuestionOptionBrief {
@@ -108,19 +103,14 @@ export interface RandomQuestionsPayload {
/** What the invigilator recorded on the day (US-EXAM-009). */
export type AttendanceStatus =
| 'REGISTERED'
| 'PRESENT'
| 'ABSENT'
| 'LATE'
| 'WITHDRAWN'
| 'DISQUALIFIED';
"REGISTERED" | "PRESENT" | "ABSENT" | "LATE" | "WITHDRAWN" | "DISQUALIFIED";
export interface ExamRegistration {
id: string;
examId: string;
profileId: string;
admissionNumber: string;
kind: 'NEW' | 'RETAKE';
kind: "NEW" | "RETAKE";
attemptNumber: number;
attendanceStatus: AttendanceStatus;
attendanceRemark: string | null;
@@ -134,12 +124,14 @@ export interface ExamRegistration {
seafarerNumber: string | null;
};
/** The candidate's online sitting, when one has been started. */
attempt?: { id: string; status: 'IN_PROGRESS' | 'SUBMITTED' | 'EXPIRED' } | null;
attempt?: {
id: string;
status: "IN_PROGRESS" | "SUBMITTED" | "EXPIRED";
} | null;
}
export type RegradeOutcome =
| { graded: true; resultId: string }
| { graded: false; reason: string };
{ graded: true; resultId: string } | { graded: false; reason: string };
export interface RecordAttendancePayload {
registrationId: string;
@@ -148,17 +140,10 @@ export interface RecordAttendancePayload {
}
export type ExamIncidentType =
| 'MISCONDUCT'
| 'TECHNICAL_FAILURE'
| 'MEDICAL'
| 'ADMINISTRATIVE'
| 'OTHER';
"MISCONDUCT" | "TECHNICAL_FAILURE" | "MEDICAL" | "ADMINISTRATIVE" | "OTHER";
export type ExamIncidentStatus =
| 'OPEN'
| 'UNDER_REVIEW'
| 'RESOLVED'
| 'DISMISSED';
"OPEN" | "UNDER_REVIEW" | "RESOLVED" | "DISMISSED";
export interface ExamIncident {
id: string;
@@ -183,6 +168,6 @@ export interface CreateIncidentPayload {
export interface ResolveIncidentPayload {
incidentId: string;
outcome: 'RESOLVED' | 'DISMISSED';
outcome: "RESOLVED" | "DISMISSED";
resolution: string;
}

View File

@@ -257,6 +257,7 @@ export const am: Translations = {
oral: "ቃል",
essay: "ኢሴይ",
choice: "ምርጫ",
both: "ሁለቱም",
offline: "ከመስመር ውጪ",
online: "በመስመር",
onlineChoiceOnlyHint: "የመስመር ላይ ፈተናዎች በራስ-ሰር ይመዘገባሉ፣ ይህም ለምርጫ ጥያቄዎች ብቻ ይሰራል።",
@@ -309,6 +310,7 @@ export const am: Translations = {
formType: {
ESSAY: "ኢሴይ",
CHOICE: "ምርጫ",
BOTH: "ሁለቱም",
},
admin: {
OFFLINE: "ከመስመር ውጪ",
@@ -1007,7 +1009,10 @@ export const am: Translations = {
requestAdjustment: "ማስተካከያ ጠይቅ",
reject: "አትቀበል",
scheduleExam: "የፈተና ቀጠሮ ስጥ",
recordExamOutcome: "የፈተና ውጤት መዝግብ",
confirmPayment: "ክፍያ አረጋግጥ",
scheduleIssuance: "የመረከቢያ ቀጠሮ ያዝ",
issueCertificate: "ሰርተፍኬት ስጥ",
print: "ሰነድ አትም",
copyLink: "አገናኝ ቅዳ",
downloadDocuments: "ሁሉንም ሰነዶች አውርድ",

View File

@@ -256,6 +256,7 @@ export const en = {
oral: 'Oral',
essay: 'Essay',
choice: 'Choice',
both: 'Both',
offline: 'Offline',
online: 'Online',
onlineChoiceOnlyHint: 'Online exams are graded automatically, which only works for multiple choice.',
@@ -307,6 +308,7 @@ export const en = {
formType: {
ESSAY: 'Essay',
CHOICE: 'Choice',
BOTH: 'Both',
},
admin: {
OFFLINE: 'Offline',
@@ -1016,7 +1018,10 @@ export const en = {
requestAdjustment: 'Request adjustment',
reject: 'Reject',
scheduleExam: 'Schedule exam',
recordExamOutcome: 'Record exam outcome',
confirmPayment: 'Confirm payment',
scheduleIssuance: 'Schedule pickup',
issueCertificate: 'Issue certificate',
print: 'Print dossier',
copyLink: 'Copy link',
downloadDocuments: 'Download all documents',