sbt-idp/cope2n-fe/src/pages/reviews2/const.ts
2024-06-03 13:59:26 +07:00

75 lines
2.2 KiB
TypeScript

import { t } from '@lingui/macro';
export const counter_measure_map = {
invalid_image: 'Remove this image from the evaluation report',
missing_information: 'Remove this image from the evaluation report',
too_blurry_text: 'Remove this image from the evaluation report',
too_small_text: 'Remove this image from the evaluation report',
ocr_cannot_extract: 'Improve OCR',
wrong_feedback: 'Update revised result and re-calculate accuracy',
handwritten: 'Remove this image from the evaluation report',
other: 'other',
};
export const REASON_BAD_QUALITY = [
{ value: 'invalid_image', label: t`Invalid image` },
{
value: 'missing_information',
label: t`Missing information`,
},
{ value: 'too_blurry_text', label: t`Too blurry text` },
{ value: 'too_small_text', label: t`Too small text` },
{ value: 'handwritten', label: t`Handwritten` },
{ value: 'wrong_feedback', label: t`Wrong Feedback` },
{ value: 'ocr_cannot_extract', label: t`Ocr cannot extract` },
{ value: 'other', label: t`Other` },
];
export const SOLUTION_BAD_QUALITY = [
{
value: 'Remove this image from the evaluation report',
label: t`Remove this image from the evaluation report`,
},
{ value: 'Improve OCR', label: t`Improve OCR` },
{
value: 'Update revised result and re-calculate accuracy',
label: t`Update revised result and re-calculate accuracy`,
},
{ value: 'other', label: t`Other` },
];
export const SUBSIDIARIES = [
{ value: 'SEAO', label: 'SEAO' },
{ value: 'SEAU', label: 'SEAU' },
{ value: 'SESP', label: 'SESP' },
{ value: 'SME', label: 'SME' },
{ value: 'SEPCO', label: 'SEPCO' },
{ value: 'TSE', label: 'TSE' },
{ value: 'SEIN', label: 'SEIN' },
];
export const SOURCE_KEYS = [
'retailername',
'sold_to_party',
'invoice_no',
'purchase_date',
'imei_number',
];
export const FEEDBACK_RESULT = 'Feedback Result';
export const FEEDBACK_ACCURACY = 'Feedback Accuracy';
export const PREDICTED_RESULT = 'Predicted Result';
export const REVIEWED_ACCURACY = 'Reviewed Accuracy';
export const REVIEWED_RESULT = 'Reviewed Result';
export const SOURCE_OBJECT_NAMES = [
FEEDBACK_RESULT,
FEEDBACK_ACCURACY,
PREDICTED_RESULT,
REVIEWED_ACCURACY,
REVIEWED_RESULT
];
export type RecentRequest = {
request_id: string,
time: Date
}