diff --git a/src/components/Groupe_Apprenant.js b/src/components/Groupe_Apprenant.js index 4ee7ec0..d2f6cfd 100644 --- a/src/components/Groupe_Apprenant.js +++ b/src/components/Groupe_Apprenant.js @@ -60,7 +60,36 @@ import Module_Selection_Apprenants from "./Module_Selection_Apprenants"; import { FcAlarmClock, FcMultipleSmartphones, FcWorkflow } from "react-icons/fc"; +import { makeStyles } from "@material-ui/core/styles"; +import CancelPresentationIcon from '@mui/icons-material/CancelPresentation'; +import { IconButton } from '@material-ui/core'; +import Paper from '@material-ui/core/Paper'; +import Draggable from 'react-draggable'; + +const useStyles = makeStyles((theme) => ({ + + dialog: { + position: 'fixed', + // left: 10, + top: 400 + }, + + paper: { + overflowY: 'unset', + }, + customizedButton: { + position: 'absolute', + left: '95%', + top: '-9%', + backgroundColor: 'lightgray', + color: 'gray', + }, +})); + + const Groupe_Apprenant = (props) => { + + const classes = useStyles(); const history = useHistory(); const [submenu, setsubmenu] = useState(""); const [rowss, setRows] = useState([]); @@ -71,6 +100,8 @@ const Groupe_Apprenant = (props) => { date_today_90j.setDate(date_today_90j.getDate() + 90); + + const [p_filtre1, setp_filtre1] = useState(""); const [p_filtre1_value, setp_filtre1_value] = useState(""); @@ -939,7 +970,7 @@ const Groupe_Apprenant = (props) => { } if (file_1_name && file_1_name.name) { - console.log(" ### Traitement de : ", file_1_name.name); + //console.log(" ### Traitement de : ", file_1_name.name); const formData = new FormData(); formData.append('File', file_1_name); @@ -1867,14 +1898,12 @@ const Groupe_Apprenant = (props) => { alert(res.data.message); - if (document.getElementById('myRef')) { - // myRef.current.scrollIntoView({ behavior: "smooth" }); - var divh = document.getElementById('myRef').offsetTop; - window.scrollTo({ - top: divh, - behavior: "smooth", - }); - } + + window.scrollTo({ + top: 0, + behavior: "smooth", + }); + } else { @@ -1908,10 +1937,14 @@ const Groupe_Apprenant = (props) => { form.append("split_type", p_detail_split_type_auto); form.append("class_id", p_detail_class_id_auto); form.append("session_id", p_detail_session_id_auto); + form.append("type_groupe_code", p_detail_type_groupe_code_auto); var myurl = process.env.REACT_APP_API_URL + "myclass/api/Automatic_Split_Member_Inscrit_To_Grps/"; + + + setLoading(true); axios.post(myurl, form).then(res => { //console.log(" In Automatic_Split_Membre_No_Grp_Creation res.data.status = " + res.data.status); @@ -1928,20 +1961,17 @@ const Groupe_Apprenant = (props) => { setgrp_apprenant_data_edit_mode(""); setSelectionModel([]); clear_DetailFieds(); - // Dialog_GRP_AUTOMATIC_handleClose_buton(); + Dialog_GRP_AUTOMATIC_handleClose_buton(); Getall_Partner_Groupe_Inscrit(); alert(res.data.message); - if (document.getElementById('myRef')) { - // myRef.current.scrollIntoView({ behavior: "smooth" }); - var divh = document.getElementById('myRef').offsetTop; - window.scrollTo({ - top: divh, - behavior: "smooth", - }); - } + window.scrollTo({ + top: 0, + behavior: "smooth", + }); + } else { @@ -2076,6 +2106,10 @@ const Groupe_Apprenant = (props) => { setsubmenu_grp_dialog("update"); } + const handleClose = () => { + //setOpen(false); + }; + return (