Skip to content

Commit

Permalink
Merge pull request #78 from Team-return/#77-add-hire-convertible-inte…
Browse files Browse the repository at this point in the history
…gration-plan

모집의뢰서 채용 전환, 현장실습 연계 여부 추가
  • Loading branch information
dnjsdmswl authored Nov 7, 2024
2 parents 0e8af1b + 149a2f7 commit 03b5284
Show file tree
Hide file tree
Showing 5 changed files with 143 additions and 60 deletions.
4 changes: 3 additions & 1 deletion src/Apis/Recruitments/request.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,15 @@ export interface EditRecruitmentRequest {
train_pay: number;
pay: string | null;
benefits: string | null;
military: boolean;
military_support: boolean;
hiring_progress: string[];
submit_document: string;
start_date: string | null;
end_date: string | null;
etc: string | null;
flexible_working: boolean;
hire_convertible: boolean;
integration_plan: boolean;
}

export interface EditAreasType {
Expand Down
4 changes: 3 additions & 1 deletion src/Apis/Recruitments/response.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,15 @@ export interface RecruitmentFormDetailResponse {
train_pay: number;
pay: string | null;
benefits: string | null;
military: true;
military_support: true;
submit_document: string;
start_date: string;
end_date: string;
additional_qualifications: string | null;
etc: string | null;
winter_intern: boolean;
hire_convertible: boolean;
integration_plan: boolean;
}

interface nameAndId {
Expand Down
27 changes: 26 additions & 1 deletion src/Components/Detail/RecruitmentFormDetail/Basic/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -296,7 +296,7 @@ export function RecruitmentFormDetailBasic({
신청계획
</_.TitleBox>
<_.ContentBox width={20}>
{recruitmentFormDetail?.military
{recruitmentFormDetail?.military_support
? 'O'
: 'X'}
</_.ContentBox>
Expand All @@ -322,6 +322,31 @@ export function RecruitmentFormDetailBasic({
</_.Stack>
</_.Stack>
</_.Stack>
{recruitmentFormDetail?.winter_intern ? (
<_.Stack>
<_.TitleBox height={70} width={21.2}>
현장실습 연계 계획
</_.TitleBox>
<_.ContentBox height={70} width={90}>
{recruitmentFormDetail?.integration_plan === true
? '있음'
: recruitmentFormDetail?.integration_plan === false
? '없음'
: '-'}
</_.ContentBox>
</_.Stack>
) : (
<_.Stack>
<_.TitleBox height={70}>채용 전환</_.TitleBox>
<_.ContentBox height={70} width={90}>
{recruitmentFormDetail?.hire_convertible === true
? '가능'
: recruitmentFormDetail?.hire_convertible === false
? '불가능'
: '-'}
</_.ContentBox>
</_.Stack>
)}
</_.Container>
);
}
160 changes: 105 additions & 55 deletions src/Components/Detail/RecruitmentFormDetail/Edit/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -61,28 +61,31 @@ export function RecruitmentFormDetailEdit({
train_pay: recruitmentFormDetail?.train_pay,
pay: recruitmentFormDetail?.pay,
benefits: recruitmentFormDetail?.benefits,
military: recruitmentFormDetail?.military,
military_support: recruitmentFormDetail?.military_support,
hiring_progress: recruitmentFormDetail?.hiring_progress,
submit_document: recruitmentFormDetail?.submit_document,
start_date: recruitmentFormDetail?.start_date,
end_date: recruitmentFormDetail?.end_date,
etc: recruitmentFormDetail?.etc,
flexible_working: recruitmentFormDetail?.flexible_working,
hire_convertible: recruitmentFormDetail?.hire_convertible,
integration_plan: recruitmentFormDetail?.integration_plan,
});

const {
required_grade,
hire_convertible,
required_licenses,
start_date,
end_date,
train_pay,
pay,
benefits,
military,
military_support,
hiring_progress,
submit_document,
etc,
flexible_working,
integration_plan,
} = recruitmentFormDetailInfo;

const [areaId, setAreaId] = useState<number>(0);
Expand Down Expand Up @@ -415,52 +418,22 @@ export function RecruitmentFormDetailEdit({
<_.Stack>
<_.TitleBox>자격요건</_.TitleBox>
<_.Stack flexDirection="column" width={90}>
<_.Stack flexDirection="column" width={100}>
<_.Stack>
<_.TitleBox>국가자격증</_.TitleBox>
<_.ContentBox
width={54}
longText={true}
overflow="scroll"
>
{required_licenses.join(', ') || '-'}
</_.ContentBox>
<_.TitleBox
width={6}
style={{ cursor: 'pointer' }}
onClick={openEditRequiredLicensesModal}
>
<Icon
icon="EditPencil"
size={30}
color="gray70"
/>
</_.TitleBox>
<_.TitleBox>성적</_.TitleBox>
<_.ContentBox width={20}>
<_.CustomInput
width={100}
type="number"
max={100}
placeholder="성적"
style={{ paddingRight: '50px' }}
value={required_grade!}
name="required_grade"
onInput={(e) => {
const value = Number(
e.currentTarget.value
);
if (value < 0) {
e.currentTarget.value = '0';
} else if (value > 100) {
e.currentTarget.value = '100';
}
}}
onChange={recruitmentFormDetailInfohandler}
/>
<_.AbsoluteText right={50}>%</_.AbsoluteText>
</_.ContentBox>
</_.Stack>
<_.Stack width={143}>
<_.TitleBox>국가자격증</_.TitleBox>
<_.ContentBox
width={54}
longText={true}
overflow="scroll"
>
{required_licenses.join(', ') || '-'}
</_.ContentBox>
<_.TitleBox
width={6}
style={{ cursor: 'pointer' }}
onClick={openEditRequiredLicensesModal}
>
<Icon icon="EditPencil" size={30} color="gray70" />
</_.TitleBox>
</_.Stack>
</_.Stack>
</_.Stack>
Expand Down Expand Up @@ -669,35 +642,35 @@ export function RecruitmentFormDetailEdit({
<Stack direction="column">
<Stack gap={5}>
<RadioButton
name="military"
name="military_support"
onClick={() => {
setRecruitmentFormDetailInfo(
(
recruitmentFormDetailInfo
) => ({
...recruitmentFormDetailInfo,
military: true,
military_support: true,
})
);
}}
checked={military === true}
checked={military_support === true}
/>
있음
</Stack>
<Stack gap={5}>
<RadioButton
name="military"
name="military_support"
onClick={() => {
setRecruitmentFormDetailInfo(
(
recruitmentFormDetailInfo
) => ({
...recruitmentFormDetailInfo,
military: false,
military_support: false,
})
);
}}
checked={military === false}
checked={military_support === false}
/>
없음
</Stack>
Expand Down Expand Up @@ -737,6 +710,83 @@ export function RecruitmentFormDetailEdit({
</_.Stack>
</_.Stack>
</_.Stack>
{recruitmentFormDetail.winter_intern ? (
<_.Stack>
<_.TitleBox width={21.2}>현장실습 연계 계획</_.TitleBox>
<_.ContentBox width={90}>
<Stack direction="column">
<Stack gap={5}>
<RadioButton
name="integration_plan"
onClick={() => {
setRecruitmentFormDetailInfo(
(recruitmentFormDetailInfo) => ({
...recruitmentFormDetailInfo,
integration_plan: true,
})
);
}}
checked={integration_plan === true}
/>
있음
</Stack>
<Stack gap={5}>
<RadioButton
name="integration_plan"
onClick={() => {
setRecruitmentFormDetailInfo(
(recruitmentFormDetailInfo) => ({
...recruitmentFormDetailInfo,
integration_plan: false,
})
);
}}
checked={integration_plan === false}
/>
없음
</Stack>
</Stack>
</_.ContentBox>
</_.Stack>
) : (
<_.Stack>
<_.TitleBox>채용 전환</_.TitleBox>
<_.ContentBox width={20}>
<Stack direction="column">
<Stack gap={5}>
<RadioButton
name="hire_convertible"
onClick={() => {
setRecruitmentFormDetailInfo(
(recruitmentFormDetailInfo) => ({
...recruitmentFormDetailInfo,
hire_convertible: true,
})
);
}}
checked={hire_convertible === true}
/>
가능
</Stack>
<Stack gap={5}>
<RadioButton
name="hire_convertible"
onClick={() => {
setRecruitmentFormDetailInfo(
(recruitmentFormDetailInfo) => ({
...recruitmentFormDetailInfo,
hire_convertible: false,
})
);
}}
checked={hire_convertible === false}
/>
불가능
</Stack>
</Stack>
</_.ContentBox>
</_.Stack>
)}
</_.Container>
);
}
8 changes: 6 additions & 2 deletions src/Pages/PdfPage/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -417,7 +417,9 @@ export const PDFFile = () => {
병역특례기업
</td>
<td colSpan={5}>
{recruitmentDetail?.military ? 'O' : 'X'}
{recruitmentDetail?.military_support
? 'O'
: 'X'}
</td>
</tr>
<tr>
Expand All @@ -429,7 +431,9 @@ export const PDFFile = () => {
{'산업기능요원 TO\n및 신청계획'}
</td>
<td colSpan={5}>
{recruitmentDetail?.military ? 'O' : 'X'}
{recruitmentDetail?.military_support
? 'O'
: 'X'}
</td>
</tr>
<tr>
Expand Down

0 comments on commit 03b5284

Please sign in to comment.