feat: gestion des no data dans les table [#33]

This commit is contained in:
N3WT DE COMPET
2025-05-17 14:35:33 +02:00
parent 3990d75e52
commit 2888f8dcce
14 changed files with 258 additions and 103 deletions

View File

@ -12,6 +12,7 @@ import TeacherItem from './TeacherItem';
import logger from '@/utils/logger';
import { useEstablishment } from '@/context/EstablishmentContext';
import SectionHeader from '@/components/SectionHeader';
import AlertMessage from '@/components/AlertMessage';
const ItemTypes = {
SPECIALITY: 'speciality',
@ -579,6 +580,13 @@ const TeachersSection = ({
data={newTeacher ? [newTeacher, ...teachers] : teachers}
columns={columns}
renderCell={renderTeacherCell}
emptyMessage={
<AlertMessage
type="warning"
title="Aucun enseignant enregistré"
message="Veuillez procéder à la création d'un nouvel enseignant."
/>
}
/>
<Popup
visible={popupVisible}