Skip to content

Commit

Permalink
[Feat] 파트 필터링 (#358)
Browse files Browse the repository at this point in the history
* feat: 연장 파트 필터링

* fix: 디자인 제외
  • Loading branch information
lydiacho authored Aug 7, 2024
1 parent 37391a4 commit 651847e
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/views/ApplyPage/components/PartSection/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@ const PartSection = ({
const { getValues } = useFormContext();

const partOptions = questionTypes?.sort((a, b) => a.id - b.id).map(({ typeKr }) => typeKr);
// 지원 연장 파트
const filteredPartOptions = partOptions?.filter((part) => part === '안드로이드');

const selectedPart: string = getValues('part');
const filteredQuestions = questions?.find((item) => item.part === selectedPart)?.questions;
Expand All @@ -52,7 +54,7 @@ const PartSection = ({
label="지원파트"
name="part"
placeholder="지원하고 싶은 파트를 선택해주세요."
options={partOptions || []}
options={filteredPartOptions || []}
size="lg"
required
disabled={isReview}
Expand Down

0 comments on commit 651847e

Please sign in to comment.