02/08/2024 - 17h

recette2
cherif 2024-08-02 20:15:25 +02:00
parent 3a9b3ec036
commit 026534282f
1 changed files with 56 additions and 48 deletions

View File

@ -153,6 +153,7 @@ const Groupe_Apprenant = (props) => {
{ field: 'code', headerName: 'Code', flex: 1, hide: false, minWidth: 180, renderCell: (params) => <ExpandableCell_50 {...params} />, },
{ field: 'nom', headerName: 'Nom', flex: 1, hide: false, minWidth: 180, renderCell: (params) => <ExpandableCell_50 {...params} />, },
{ field: 'type_groupe_code', headerName: 'Type GRoupe', flex: 1, hide: false, minWidth: 180, renderCell: (params) => <ExpandableCell_50 {...params} />, },
{ field: 'nb_membre', headerName: 'Nb membres', flex: 1, hide: false, minWidth: 180, renderCell: (params) => <ExpandableCell_50 {...params} />, },
{ field: 'class_id', headerName: 'class_id', hide: true, Width: 0 },
{
@ -193,7 +194,15 @@ const Groupe_Apprenant = (props) => {
field: "delete", headerName: 'Supprimer',
renderCell: (cellValues) => {
return (
<nav>
{String(cellValues.row.nb_membre) !== "0" && <Button onClick={(e) => {
alert(" Vous devez supprimer les membres avant de supprimer le groupe");
}}>
<CiTrash />
</Button>}
{String(cellValues.row.nb_membre) === "0" &&
<Popup
trigger={<Button
@ -241,9 +250,9 @@ const Groupe_Apprenant = (props) => {
</div>
</div>
)}
</Popup>
</Popup>}
</nav>
);
}
}
@ -2547,8 +2556,7 @@ const Groupe_Apprenant = (props) => {
type_groupe_code: JSON.parse(item).type_groupe_code,
class_id: JSON.parse(item).class_id,
session_id: JSON.parse(item).session_id,
nb_membre: JSON.parse(item).nb_membre,
}
))}
@ -2712,7 +2720,7 @@ const Groupe_Apprenant = (props) => {
id='menu_import_participant' name='menu_import_participant' onClick={(event) => {
setDialog_GRP_AUTOMATIC_open(true);
}} > Subdivision automatique
}} > Création automatique
&nbsp; <FcMultipleSmartphones />
</Button>