fixing show total student data
This commit is contained in:
parent
51ddcf098c
commit
3fa01af39b
|
|
@ -187,7 +187,7 @@ const Feedback = () => {
|
|||
out of {data.TOTAL_STUDENT} students
|
||||
</>
|
||||
):(
|
||||
`${data.TOTAL_STUDENT} students`
|
||||
`${data.STUDENTS} students`
|
||||
)}
|
||||
</Card.Text>
|
||||
{/* <Button as={Link} to={`c/${data.ID_CLASS}`} variant="warning" className='py-2 w-100 rounded-35'>See Details</Button> */}
|
||||
|
|
|
|||
|
|
@ -70,7 +70,7 @@ const ManageClasses = () => {
|
|||
out of {data.TOTAL_STUDENT} students
|
||||
</>
|
||||
):(
|
||||
`${data.TOTAL_STUDENT} students`
|
||||
`${data.STUDENTS} students`
|
||||
)}
|
||||
</Card.Text>
|
||||
<Button as={Link} to={`d/${data.ID_CLASS}`} variant="warning" className='py-2 w-100 rounded-35'>See Details</Button>
|
||||
|
|
|
|||
|
|
@ -62,15 +62,6 @@ const ManageStudents = () => {
|
|||
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) => {
|
||||
e.preventDefault(); // Mencegah browser membuka file
|
||||
e.stopPropagation();
|
||||
|
|
@ -173,9 +164,6 @@ const ManageStudents = () => {
|
|||
<Button size='sm' className='btn-edit' onClick={() => handleShow(student)}>
|
||||
<i className="bi bi-pencil-square"></i>
|
||||
</Button>
|
||||
<Button size='sm' className='btn-delete' onClick={() => handleDelete(student.ID)}>
|
||||
<i className="bi bi-trash3"></i>
|
||||
</Button>
|
||||
</td>
|
||||
</tr>
|
||||
))
|
||||
|
|
|
|||
|
|
@ -191,7 +191,7 @@ const Monitoring = () => {
|
|||
out of {data.TOTAL_STUDENT} students
|
||||
</>
|
||||
):(
|
||||
`${data.TOTAL_STUDENT} students`
|
||||
`${data.STUDENTS} students`
|
||||
)}
|
||||
</Card.Text>
|
||||
<Button as={Link} to={`c/${data.ID_CLASS}`} variant="warning" className='py-2 w-100 rounded-35'>See Details</Button>
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user