From fd4325c09c36f7820cbba5de2298462bbaebead7 Mon Sep 17 00:00:00 2001 From: cherif Date: Sun, 25 May 2025 18:28:00 +0200 Subject: [PATCH] qsdsq --- package-lock.json | 11 ++ package.json | 1 + public/img/fr_flag.png | Bin 0 -> 122 bytes src/components/Jurys.js | 34 ++-- .../Module_Session_Notes_Classement.js | 152 +++++++++++++++++- .../Partner_Config_Ftion_Initiale.js | 2 +- .../FrenchSolution.js | 4 +- .../homepage_automatic_files/new_homepage.js | 16 +- .../components/_displaypartnersession.scss | 6 +- 9 files changed, 178 insertions(+), 48 deletions(-) create mode 100644 public/img/fr_flag.png diff --git a/package-lock.json b/package-lock.json index dd0479a..10bf943 100644 --- a/package-lock.json +++ b/package-lock.json @@ -133,6 +133,7 @@ "react-md-spinner": "^1.0.0", "react-meta-tags": "^1.0.1", "react-multi-carousel": "^2.8.2", + "react-native-country-flag": "^2.0.2", "react-native-paper": "^4.9.2", "react-native-web": "^0.17.5", "react-paginate": "^8.1.1", @@ -27299,6 +27300,11 @@ "node": ">=8" } }, + "node_modules/react-native-country-flag": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/react-native-country-flag/-/react-native-country-flag-2.0.2.tgz", + "integrity": "sha512-5LMWxS79ZQ0Q9ntYgDYzWp794+HcQGXQmzzZNBR1AT7z5HcJHtX7rlk8RHi7RVzfp5gW6plWSZ4dKjRpu/OafQ==" + }, "node_modules/react-native-iphone-x-helper": { "version": "1.3.1", "resolved": "https://registry.npmjs.org/react-native-iphone-x-helper/-/react-native-iphone-x-helper-1.3.1.tgz", @@ -55530,6 +55536,11 @@ "resolved": "https://registry.npmjs.org/react-multi-carousel/-/react-multi-carousel-2.8.2.tgz", "integrity": "sha512-M9Y7DfAp8bA/r6yexttU6RLA7uyppje4c0ELRuCHZWswH+u7nr0uVP6qHNPjc4XGOEY1MYFOb5nBg7JvoKutuQ==" }, + "react-native-country-flag": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/react-native-country-flag/-/react-native-country-flag-2.0.2.tgz", + "integrity": "sha512-5LMWxS79ZQ0Q9ntYgDYzWp794+HcQGXQmzzZNBR1AT7z5HcJHtX7rlk8RHi7RVzfp5gW6plWSZ4dKjRpu/OafQ==" + }, "react-native-iphone-x-helper": { "version": "1.3.1", "resolved": "https://registry.npmjs.org/react-native-iphone-x-helper/-/react-native-iphone-x-helper-1.3.1.tgz", diff --git a/package.json b/package.json index de9b293..b3dbfc4 100644 --- a/package.json +++ b/package.json @@ -128,6 +128,7 @@ "react-md-spinner": "^1.0.0", "react-meta-tags": "^1.0.1", "react-multi-carousel": "^2.8.2", + "react-native-country-flag": "^2.0.2", "react-native-paper": "^4.9.2", "react-native-web": "^0.17.5", "react-paginate": "^8.1.1", diff --git a/public/img/fr_flag.png b/public/img/fr_flag.png new file mode 100644 index 0000000000000000000000000000000000000000..e0191b3b1f811b83bf8ac12c946d0cb7ad48e39b GIT binary patch literal 122 zcmeAS@N?(olHy`uVBq!ia0vp^0YGfZ!VDx;*b2*m6n}tEi0fNTO9ths|Ns9F$=>m~ zpgR4>on)Ytnx~6nh{y3{0T(tmFAs-SM%ErJnNW*W1tAYt913h*%;hc` { { field: 'code', headerName: 'Code', flex: 1, hide: false, minWidth: 180, renderCell: (params) => , }, { field: 'description', headerName: 'Description', flex: 1, hide: false, minWidth: 180, renderCell: (params) => , }, - { field: 'cible', headerName: 'Cible', flex: 1, hide: false, minWidth: 180, renderCell: (params) => , }, + { field: 'cible', headerName: 'Cible', flex: 1, hide: false, minWidth: 180, renderCell: (params) => , }, { field: 'email_jury', headerName: 'Mail Diff.', flex: 1, hide: false, minWidth: 180, renderCell: (params) => , }, { field: 'chef_jury_nom_prenom', headerName: 'Responsable', flex: 1, hide: false, minWidth: 180, renderCell: (params) => , }, @@ -4472,7 +4472,7 @@ const Jury = (props) => { id="detail_jury_observation" aria-label="minimum height" minRows={3} - maxRows={4} + maxRows={5} //placeholder="Minimum 3 rows" style={{ border: "1px solid gainsboro", width: '99%', padding: '2px', @@ -5241,7 +5241,7 @@ const Jury = (props) => { - zzzzz +
Créneau
@@ -5423,9 +5423,7 @@ const Jury = (props) => {
-
Salles & Materiels
-
Reservation Salle et materiel à faire
Apprenants
@@ -6351,20 +6349,7 @@ const Jury = (props) => { }, - // gestion couleur des lignes avec le statut d'inscription - '& .line--statut--annule': { - backgroundColor: '#D8D8D8', - color: 'white', - }, - - '& .line--statut--inscrit': { - backgroundColor: '#CEF6D8', - color: 'black', - }, - '& .line--statut--preinscrit': { - backgroundColor: '#F7F2E0', - color: 'black', - }, + "& .MuiDataGrid-columnHeaders": { backgroundColor: "#c8cfd5", @@ -7481,7 +7466,7 @@ const Jury = (props) => { } - + {selected_jury_cible && String(selected_jury_cible) === "soutenance" && New_Option_Cible_Jury && New_Get_List_UE_From_Session_Id_result && New_Get_List_UE_From_Session_Id_result.length > 0 && @@ -8681,11 +8666,12 @@ const Jury = (props) => { id="detail_soutenance_observation" aria-label="minimum height" - maxRows={10} + minRows={3} + maxRows={5} //placeholder="Minimum 3 rows" style={{ border: "1px solid gainsboro", width: '99%', padding: '2px', - maxHeight: '15rem', height: '10rem', minHeight: '10rem', marginBottom: '3rem' + maxHeight: '15rem', height: '5rem', minHeight: '5rem', marginBottom: '3rem' }} value={p_detail_soutenance_observation} @@ -8748,11 +8734,11 @@ const Jury = (props) => { id="detail_soutenance_observation" aria-label="minimum height" minRows={3} - maxRows={4} + maxRows={5} //placeholder="Minimum 3 rows" style={{ border: "1px solid gainsboro", width: '99%', padding: '2px', - maxHeight: '15rem', height: '10rem', minHeight: '10rem', marginBottom: '3rem' + maxHeight: '10rem', height: '5rem', minHeight: '5rem', marginBottom: '3rem' }} value={p_detail_soutenance_observation} onChange={(e) => { diff --git a/src/components/Module_Session_Notes_Classement.js b/src/components/Module_Session_Notes_Classement.js index ef80109..fc3205b 100644 --- a/src/components/Module_Session_Notes_Classement.js +++ b/src/components/Module_Session_Notes_Classement.js @@ -38,6 +38,16 @@ import { IconButton } from '@material-ui/core'; import MoreVertIcon from '@mui/icons-material/MoreVert'; import Menu from '@mui/material/Menu'; import MenuItem from '@mui/material/MenuItem'; +import { + GridToolbarContainer, GridToolbarExport, GridToolbarColumnsButton, + GridToolbarFilterButton, GridToolbarDensitySelector, GridToolbarExportContainer, useGridApiContext, + gridFilteredSortedRowIdsSelector, + gridVisibleColumnFieldsSelector, + GridValueGetterParams, + GridPreferencePanelsValue, + +} from '@mui/x-data-grid'; +import * as XLSX from 'xlsx'; function PaperComponent(props) { return ( @@ -398,7 +408,7 @@ const Module_Session_Notes_Classement = (props) => { { field: 'note_td', headerName: 'note_td', hide: true }, { field: 'note_tp', headerName: 'note_tp', hide: true }, { field: 'note_examen', headerName: 'note_examen', hide: true }, - { field: 'jury_note', headerName: 'Note Jury', hide: true}, + { field: 'jury_note', headerName: 'Note Jury', hide: true }, { field: 'jury_observation', headerName: 'Observ. Jury', width: 200, editable: jury_cell_editable, renderCell: (params) => , align: "left", }, @@ -1754,6 +1764,115 @@ const Module_Session_Notes_Classement = (props) => { }) } + // DEBUT EXPORT EXCEL DATAGRID + + function CustomToolbar(props) { + + + return ( + + + + + + + + + + + ); + } + + function getExcelData(apiRef) { + // Select rows and columns + const filteredSortedRowIds = gridFilteredSortedRowIdsSelector(apiRef); + const visibleColumnsField = gridVisibleColumnFieldsSelector(apiRef); + + // Format the data. Here we only keep the value + const data = filteredSortedRowIds.map((id) => { + const row = {}; + visibleColumnsField.forEach((field) => { + row[field] = apiRef.current.getCellParams(id, field).value; + }); + return row; + }); + + return data; + } + + + function ExportButton(props) { + return ( + + + + ); + } + + function handleExport(apiRef, data_colums) { + const data = getExcelData(apiRef); + const visibleColumnsField = gridVisibleColumnFieldsSelector(apiRef); + + + const local_config = { + keys: visibleColumnsField, + + columnNames: data_colums.filter((mydata) => (mydata).disableExport !== true).map(function (mydata) { + if (mydata.headerName && visibleColumnsField.includes(mydata.field)) { + if (mydata.headerName) { + return mydata.headerName; + } + } + + }), + + fileName: 'data_' + String(new Date().toJSON().slice(0, 10)).replaceAll("-", "_") + '.xlsx', + sheetName: 'Export_' + String(new Date().toJSON().slice(0, 10)).replaceAll("-", "_"), + }; + + local_config.columnNames = local_config.columnNames.filter(function (element) { + return element !== undefined; + }); + + + const rows = data.map((row) => { + const mRow = {}; + for (const key of local_config.keys) { + mRow[key] = row[key]; + } + return mRow; + }); + + const worksheet = XLSX.utils.json_to_sheet(rows); + XLSX.utils.sheet_add_aoa(worksheet, [[...local_config.columnNames]], { + origin: 'A1', + }); + + const workbook = XLSX.utils.book_new(); + XLSX.utils.book_append_sheet(workbook, worksheet, local_config.sheetName); + XLSX.writeFile(workbook, local_config.fileName, { compression: true }); + } + + function ExportMenuItem(props) { + const apiRef = useGridApiContext(); + const { hideMenu } = props; + + return ( + { + handleExport(apiRef, props.data_colums); + // Hide the export menu after the export + hideMenu?.(); + }} + > + Export Excel + + ); + } + + // FIN EXPORT EXCEL DATAGRID const [vue_note, setvue_note] = useState("classement"); @@ -1817,18 +1936,18 @@ const Module_Session_Notes_Classement = (props) => { {Dialog_1_message} -
Observation
+
Observation
{ @@ -2019,6 +2138,10 @@ const Module_Session_Notes_Classement = (props) => { setadd_One_Employee();*/ } }} + + + + selectionModel={selectionModel_note_Session_classement} localeText={frFR.components.MuiDataGrid.defaultProps.localeText} @@ -2054,9 +2177,14 @@ const Module_Session_Notes_Classement = (props) => { rowsPerPageOptions={[10]} disableSelectionOnClick - components={{ + /* components={{ Toolbar: GridToolbar, + }}*/ + + components={{ + Toolbar: CustomToolbar }} + componentsProps={{ toolbar: { data_colums: columns_list_session_note_classement_final } }} //sx={datagridSx} @@ -2569,9 +2697,14 @@ const Module_Session_Notes_Classement = (props) => { rowsPerPageOptions={[10]} disableSelectionOnClick - components={{ + /* components={{ Toolbar: GridToolbar, + }}*/ + + components={{ + Toolbar: CustomToolbar }} + componentsProps={{ toolbar: { data_colums: columns_list_evaluation_note_classement_final } }} //sx={datagridSx} getCellClassName={(params) => { @@ -2754,9 +2887,14 @@ const Module_Session_Notes_Classement = (props) => { rowsPerPageOptions={[10]} disableSelectionOnClick - components={{ + /* components={{ Toolbar: GridToolbar, + }}*/ + + components={{ + Toolbar: CustomToolbar }} + componentsProps={{ toolbar: { data_colums: columns_list_evaluation_detail_note_classement_final } }} //sx={datagridSx} getCellClassName={(params) => { diff --git a/src/components/Partner_Config_Ftion_Initiale.js b/src/components/Partner_Config_Ftion_Initiale.js index ddf7b79..e306a2a 100644 --- a/src/components/Partner_Config_Ftion_Initiale.js +++ b/src/components/Partner_Config_Ftion_Initiale.js @@ -502,7 +502,7 @@ const Partner_Config_Ftion_Initiale = (props) => { function Add_Config_Type_Eval() { var form = new FormData(); //form.append("token","K3cw63eKokKSbV4spjQ48SUNnfy80yrXfA"); - + const stored_cookie = getCookie('tokenmysypart'); form.append("token", stored_cookie); diff --git a/src/components/homepage_automatic_files/FrenchSolution.js b/src/components/homepage_automatic_files/FrenchSolution.js index 11db626..96901f3 100644 --- a/src/components/homepage_automatic_files/FrenchSolution.js +++ b/src/components/homepage_automatic_files/FrenchSolution.js @@ -1,3 +1,5 @@ + + const FrenchSolution = ({ width = 162, height = 120 }) => { const containerStyle = { width: width, @@ -38,7 +40,7 @@ const FrenchSolution = ({ width = 162, height = 120 }) => {
Solutions
100%
-
française 🇫🇷
+
française France
); }; diff --git a/src/components/homepage_automatic_files/new_homepage.js b/src/components/homepage_automatic_files/new_homepage.js index 925b95b..e3763f2 100644 --- a/src/components/homepage_automatic_files/new_homepage.js +++ b/src/components/homepage_automatic_files/new_homepage.js @@ -4,21 +4,12 @@ import "./new_homepage.css"; import { Helmet } from "react-helmet"; import WhyUsLayout from './WhyUsLayout.js'; import LogoCloud from './LogoCloud.js'; -import VisionSection from './VisionSection.js'; -import KeyMetrics from './KeyMetrics.js'; import Features from './Features.js'; import AboutUsSection from './block_stat/AboutUsSection.js'; import FrenchSolution from './FrenchSolution.js'; import CommentMarche from './CommentMarche.js'; import New_C_Tatif_Section from "../tarif_section_automatic_files/PricingSection" -import GO_Entreprise_Img from "../../mysy_img/mysy_training_landscape.png"; - -import Banniere_mysy_goent from "../../mysy_img/Banniere_mysy_goent.png"; -import Banniere_mysy_goent_mobile from "../../mysy_img/cherif_balde_landscape.png"; -import Banniere_mysy_goent_mobile2 from "../../mysy_img/landscape.png"; - - const New_C_A_Propos_2025 = (props) => { useEffect(() => { @@ -49,7 +40,8 @@ const New_C_A_Propos_2025 = (props) => {
- Toutes les fonctionnalités dont vous avez besoin, au meilleur prix   🇫🇷   + Toutes les fonctionnalités dont vous avez besoin, au meilleur prix   France
@@ -86,7 +78,7 @@ const New_C_A_Propos_2025 = (props) => { -
+ {/*
-
+
*/}
diff --git a/src/styles/components/_displaypartnersession.scss b/src/styles/components/_displaypartnersession.scss index 2b5c3a7..3d1876e 100644 --- a/src/styles/components/_displaypartnersession.scss +++ b/src/styles/components/_displaypartnersession.scss @@ -23,7 +23,7 @@ top: 0px; opacity: 80%; left: 0px; - } + } .spinner { width: 20rem; @@ -1882,7 +1882,7 @@ text-align: center; margin-bottom: 0.8rem; color: white; - cursor: pointer; + cursor: normal; font-style: italic; background-color: gray; font-weight: normal; @@ -2599,7 +2599,7 @@ text-align: center; margin-bottom: 0.8rem; color: white; - cursor: pointer; + cursor: normal; font-style: italic; background-color: gray; font-weight: normal;