From 806708a26614f4926b1276be0e0b600971afc7a7 Mon Sep 17 00:00:00 2001 From: cherif Date: Wed, 5 Jun 2024 22:58:50 +0200 Subject: [PATCH] 05/06/2024 - 23h --- src/components/DisplayPartnerSession.js | 51 ++++++++++++++++++------- 1 file changed, 38 insertions(+), 13 deletions(-) diff --git a/src/components/DisplayPartnerSession.js b/src/components/DisplayPartnerSession.js index 83aee7b..cf71c7e 100644 --- a/src/components/DisplayPartnerSession.js +++ b/src/components/DisplayPartnerSession.js @@ -10,7 +10,7 @@ import { DataGrid, GridToolbar, frFR } from '@mui/x-data-grid'; import "react-draft-wysiwyg/dist/react-draft-wysiwyg.css"; import { Editor } from '@tinymce/tinymce-react'; import parse from 'html-react-parser'; -import { FcViewDetails, FcDisapprove, FcInfo } from "react-icons/fc"; +import { FcViewDetails, FcDisapprove, FcInfo, FcExpired } from "react-icons/fc"; import 'react-tooltip/dist/react-tooltip.css' import { Tooltip } from 'react-tooltip' import add_plus from "../mysy_img/plus.png"; @@ -195,7 +195,31 @@ const DisplayPartnerSession = (props) => { const columns = [ { field: 'id', headerName: 'id', hide: true }, { field: '_id', headerName: '_id', hide: true }, + { field: 'session_alert_message', headerName: 'session_alert_message', hide: true }, { field: 'class_internal_url', headerName: 'class_internal_url', hide: true }, + + { + field: 'is_session_alert', headerName: '', hide: false, Width: 50, flex: 1, + + + renderCell: (cellValues) => { + return ( +
+ {cellValues.row.is_session_alert && String(cellValues.row.is_session_alert) === "1" && } + {cellValues.row.is_session_alert && String(cellValues.row.is_session_alert) !== "1" && ""} + +
+ + ); + } + + }, + { field: 'code_session', headerName: 'Code session', hide: false, minWidth: 200, flex: 1, renderCell: (params) => , }, { field: 'session_title', headerName: 'Titre', hide: false, flex: 1, minWidth: 250, renderCell: (params) => , }, @@ -286,8 +310,8 @@ const DisplayPartnerSession = (props) => { { field: 'published', headerName: 'publié', minWidth: datagrid_columns_size_model1, align: "center", hide: true, renderCell: (params) => , }, { field: 'site_formation_id', headerName: 'site_formation_id', with: 0, align: "center", hide: true, }, - - + + { field: 'qty_in_quotation', headerName: 'Place Non validé ', with: 150, align: "center", hide: false, renderCell: (params) => , }, { field: 'qty_in_quotation_list_quotation', headerName: 'List Devis ', with: 150, align: "center", hide: false, renderCell: (params) => , }, @@ -2456,7 +2480,7 @@ const DisplayPartnerSession = (props) => { const [selectionModel_insc, setSelectionModel_insc] = React.useState([]); const [rowss_insc, setRows_insc] = useState([]); const [rowss_preinsc, setRows_preinsc] = useState([]); - + const [GetListePreinscrit_insc_api, setGetListePreinscrit_insc_api] = useState(); const [GetListePreinscrit_insc_meassage, setGetListePreinscrit_insc_meassage] = useState(); const [GetListePreinscrit_insc_result, setGetListePreinscrit_insc_result] = useState([]) @@ -8637,7 +8661,7 @@ const DisplayPartnerSession = (props) => { } - + const [Add_One_Sequence_Session_Ressource_Mass_api, setAdd_One_Sequence_Session_Ressource_Mass_api] = useState(); const [Add_One_Sequence_Session_Ressource_Mass_message, setAdd_One_Sequence_Session_Ressource_Mass_message] = useState(); const [Add_One_Sequence_Session_Ressource_Mass_result, setAdd_One_Sequence_Session_Ressource_Mass_result] = useState(); @@ -13030,7 +13054,8 @@ const DisplayPartnerSession = (props) => { qty_in_quotation: JSON.parse(item).qty_in_quotation, qty_in_quotation_list_quotation: JSON.parse(item).qty_in_quotation_list_quotation, - + is_session_alert: JSON.parse(item).is_session_alert, + session_alert_message: JSON.parse(item).session_alert_message, } ))} @@ -14471,7 +14496,7 @@ const DisplayPartnerSession = (props) => { {String(addOneSession) === "1" &&
Ajout d'une session de formation
- +
Choisir une formation
@@ -14591,7 +14616,7 @@ const DisplayPartnerSession = (props) => { } /> - +
@@ -14622,7 +14647,7 @@ const DisplayPartnerSession = (props) => { } /> - +
@@ -14654,7 +14679,7 @@ const DisplayPartnerSession = (props) => { } /> - + @@ -14688,7 +14713,7 @@ const DisplayPartnerSession = (props) => { /> - +
@@ -14802,7 +14827,7 @@ const DisplayPartnerSession = (props) => { } /> - +
A distance
@@ -14826,7 +14851,7 @@ const DisplayPartnerSession = (props) => { /> } /> - +
Site de Formation