fixing show total student data

This commit is contained in:
Dimas Atmodjo 2024-12-18 17:23:38 +07:00
parent 51ddcf098c
commit 3fa01af39b
4 changed files with 3 additions and 15 deletions

View File

@ -187,7 +187,7 @@ const Feedback = () => {
out of {data.TOTAL_STUDENT} students out of {data.TOTAL_STUDENT} students
</> </>
):( ):(
`${data.TOTAL_STUDENT} students` `${data.STUDENTS} students`
)} )}
</Card.Text> </Card.Text>
{/* <Button as={Link} to={`c/${data.ID_CLASS}`} variant="warning" className='py-2 w-100 rounded-35'>See Details</Button> */} {/* <Button as={Link} to={`c/${data.ID_CLASS}`} variant="warning" className='py-2 w-100 rounded-35'>See Details</Button> */}

View File

@ -70,7 +70,7 @@ const ManageClasses = () => {
out of {data.TOTAL_STUDENT} students out of {data.TOTAL_STUDENT} students
</> </>
):( ):(
`${data.TOTAL_STUDENT} students` `${data.STUDENTS} students`
)} )}
</Card.Text> </Card.Text>
<Button as={Link} to={`d/${data.ID_CLASS}`} variant="warning" className='py-2 w-100 rounded-35'>See Details</Button> <Button as={Link} to={`d/${data.ID_CLASS}`} variant="warning" className='py-2 w-100 rounded-35'>See Details</Button>

View File

@ -62,15 +62,6 @@ const ManageStudents = () => {
await editStudent(selectedStudent.ID, formData); await editStudent(selectedStudent.ID, formData);
}; };
const handleDelete = async (id) => {
handleShowLoader('Deleted', 'Are you sure you want to delete this student?', false, '', true);
const confirmDelete = async () => {
handleCloseLoader();
await deleteStudent(id);
}
setLoaderState(prev => ({ ...prev, handleConfirm: confirmDelete }));
}
const handleDragOver = (e) => { const handleDragOver = (e) => {
e.preventDefault(); // Mencegah browser membuka file e.preventDefault(); // Mencegah browser membuka file
e.stopPropagation(); e.stopPropagation();
@ -173,9 +164,6 @@ const ManageStudents = () => {
<Button size='sm' className='btn-edit' onClick={() => handleShow(student)}> <Button size='sm' className='btn-edit' onClick={() => handleShow(student)}>
<i className="bi bi-pencil-square"></i> <i className="bi bi-pencil-square"></i>
</Button> </Button>
<Button size='sm' className='btn-delete' onClick={() => handleDelete(student.ID)}>
<i className="bi bi-trash3"></i>
</Button>
</td> </td>
</tr> </tr>
)) ))

View File

@ -191,7 +191,7 @@ const Monitoring = () => {
out of {data.TOTAL_STUDENT} students out of {data.TOTAL_STUDENT} students
</> </>
):( ):(
`${data.TOTAL_STUDENT} students` `${data.STUDENTS} students`
)} )}
</Card.Text> </Card.Text>
<Button as={Link} to={`c/${data.ID_CLASS}`} variant="warning" className='py-2 w-100 rounded-35'>See Details</Button> <Button as={Link} to={`c/${data.ID_CLASS}`} variant="warning" className='py-2 w-100 rounded-35'>See Details</Button>