diff --git a/view/next-project/src/components/common/RecordAddModal/RecordAddModal.tsx b/view/next-project/src/components/common/RecordAddModal/RecordAddModal.tsx index 9810c32..7f95dba 100644 --- a/view/next-project/src/components/common/RecordAddModal/RecordAddModal.tsx +++ b/view/next-project/src/components/common/RecordAddModal/RecordAddModal.tsx @@ -53,8 +53,7 @@ interface CurriculumChapters { } interface Teacher { - user_id: number | string; - record_id: string; + user_id: string; } interface User { @@ -72,7 +71,7 @@ const RecordAddModal: FC = (props) => { const [curriculumChapter, setCurriculumChapter] = useState(); const [records, setRecords] = useState([]); const [users, setUsers] = useState([{ id: '', name: '' }]); - const [teacherData, setTeacherData] = useState({ user_id: 1, record_id: '' }); + const [teacherData, setTeacherData] = useState({ user_id: '1' }); const [isAnimationOpen, setIsAnimationOpen] = useState(false); const [newRecordId, setNewRecordId] = useState(''); @@ -128,8 +127,8 @@ const RecordAddModal: FC = (props) => { ) => { setRecordData({ ...recordData, [input]: e.target.value }); }; - - const handleTeacher = () => (e: React.ChangeEvent) => { + + const handleTeacher = (e: React.ChangeEvent) => { setTeacherData({ ...teacherData, user_id: e.target.value }); };