|
|
|
@ -9,6 +9,7 @@ import {
|
|
|
|
|
Currency,
|
|
|
|
|
CURRENCY_OPTIONS,
|
|
|
|
|
} from '~/utils/offers/currency/CurrencyEnum';
|
|
|
|
|
import { validateNumber } from '~/utils/offers/form';
|
|
|
|
|
|
|
|
|
|
import { EducationFieldOptions } from '../../EducationFields';
|
|
|
|
|
import { EducationLevelOptions } from '../../EducationLevels';
|
|
|
|
@ -34,10 +35,11 @@ function YoeSection() {
|
|
|
|
|
label="Total YOE"
|
|
|
|
|
placeholder="0"
|
|
|
|
|
required={true}
|
|
|
|
|
type="number"
|
|
|
|
|
type="text"
|
|
|
|
|
{...register(`background.totalYoe`, {
|
|
|
|
|
min: { message: FieldError.NON_NEGATIVE_NUMBER, value: 0 },
|
|
|
|
|
required: FieldError.REQUIRED,
|
|
|
|
|
validate: validateNumber,
|
|
|
|
|
valueAsNumber: true,
|
|
|
|
|
})}
|
|
|
|
|
/>
|
|
|
|
@ -48,9 +50,10 @@ function YoeSection() {
|
|
|
|
|
<FormTextInput
|
|
|
|
|
errorMessage={backgroundFields?.specificYoes?.[0]?.yoe?.message}
|
|
|
|
|
label="Specific YOE 1"
|
|
|
|
|
type="number"
|
|
|
|
|
type="text"
|
|
|
|
|
{...register(`background.specificYoes.0.yoe`, {
|
|
|
|
|
min: { message: FieldError.NON_NEGATIVE_NUMBER, value: 0 },
|
|
|
|
|
validate: validateNumber,
|
|
|
|
|
valueAsNumber: true,
|
|
|
|
|
})}
|
|
|
|
|
/>
|
|
|
|
@ -64,9 +67,10 @@ function YoeSection() {
|
|
|
|
|
<FormTextInput
|
|
|
|
|
errorMessage={backgroundFields?.specificYoes?.[1]?.yoe?.message}
|
|
|
|
|
label="Specific YOE 2"
|
|
|
|
|
type="number"
|
|
|
|
|
type="text"
|
|
|
|
|
{...register(`background.specificYoes.1.yoe`, {
|
|
|
|
|
min: { message: FieldError.NON_NEGATIVE_NUMBER, value: 0 },
|
|
|
|
|
validate: validateNumber,
|
|
|
|
|
valueAsNumber: true,
|
|
|
|
|
})}
|
|
|
|
|
/>
|
|
|
|
@ -119,9 +123,10 @@ function FullTimeJobFields() {
|
|
|
|
|
placeholder="0.00"
|
|
|
|
|
startAddOn="$"
|
|
|
|
|
startAddOnType="label"
|
|
|
|
|
type="number"
|
|
|
|
|
type="text"
|
|
|
|
|
{...register(`background.experiences.0.totalCompensation.value`, {
|
|
|
|
|
min: { message: FieldError.NON_NEGATIVE_NUMBER, value: 0 },
|
|
|
|
|
validate: validateNumber,
|
|
|
|
|
valueAsNumber: true,
|
|
|
|
|
})}
|
|
|
|
|
/>
|
|
|
|
@ -142,9 +147,10 @@ function FullTimeJobFields() {
|
|
|
|
|
<FormTextInput
|
|
|
|
|
errorMessage={experiencesField?.durationInMonths?.message}
|
|
|
|
|
label="Duration (months)"
|
|
|
|
|
type="number"
|
|
|
|
|
type="text"
|
|
|
|
|
{...register(`background.experiences.0.durationInMonths`, {
|
|
|
|
|
min: { message: FieldError.NON_NEGATIVE_NUMBER, value: 0 },
|
|
|
|
|
validate: validateNumber,
|
|
|
|
|
valueAsNumber: true,
|
|
|
|
|
})}
|
|
|
|
|
/>
|
|
|
|
@ -188,9 +194,10 @@ function InternshipJobFields() {
|
|
|
|
|
placeholder="0.00"
|
|
|
|
|
startAddOn="$"
|
|
|
|
|
startAddOnType="label"
|
|
|
|
|
type="number"
|
|
|
|
|
type="text"
|
|
|
|
|
{...register(`background.experiences.0.monthlySalary.value`, {
|
|
|
|
|
min: { message: FieldError.NON_NEGATIVE_NUMBER, value: 0 },
|
|
|
|
|
validate: validateNumber,
|
|
|
|
|
valueAsNumber: true,
|
|
|
|
|
})}
|
|
|
|
|
/>
|
|
|
|
@ -205,9 +212,10 @@ function InternshipJobFields() {
|
|
|
|
|
<FormTextInput
|
|
|
|
|
errorMessage={experiencesField?.durationInMonths?.message}
|
|
|
|
|
label="Duration (months)"
|
|
|
|
|
type="number"
|
|
|
|
|
type="text"
|
|
|
|
|
{...register(`background.experiences.0.durationInMonths`, {
|
|
|
|
|
min: { message: FieldError.NON_NEGATIVE_NUMBER, value: 0 },
|
|
|
|
|
validate: validateNumber,
|
|
|
|
|
valueAsNumber: true,
|
|
|
|
|
})}
|
|
|
|
|
/>
|
|
|
|
|