diff --git a/src/App.js b/src/App.js
index 0812ff2..e7b4150 100644
--- a/src/App.js
+++ b/src/App.js
@@ -5,13 +5,13 @@ import NotFound from './pages/NotFound'
import Contact from './pages/Contact'
import Connexion from './pages/Connexion'
import Login from './pages/Login';
-import Recherche from "./pages/recherche_new";
+
import Recherche_new_v2 from "./pages/recherche_new_v2";
import TestUrl from "./pages/testurl";
import Account from "./pages/account";
-import DisplayDetailClass from "./pages/displaydetailclass";
+
import DisplayDetailClass_new_v2 from "./pages/displaydetailclass_new_v2";
-import DisplayDetailClassAction from "./pages/displaydetailclassaction";
+
import DisplayDetailArticle from "./pages/displaydetailarticle";
import Acceuil from "./pages/acceuil";
import Partner from "./pages/partner";
@@ -19,17 +19,17 @@ import CreateAccount from "./pages/createaccount";
import PartnerLogin from "./pages/partnerlogin";
import PartnerLogin0 from "./pages/partnerlogin0";
import PartnerLogin1 from "./pages/partnerlogin1";
-import Footer from "./pages/footer";
+
import RechecheArticles from "./pages/recherchearticles";
import AddArticle from "./pages/addarticle";
import ResetUserPwd from "./pages/resetuserpwd";
import DeleteUserAccount from "./pages/deleteuseraccount";
-import QuiSommesNous from "./pages/quisommesnous";
+
import ContactezNous from "./pages/contactez_nous";
import CoupDeCoeur from "./pages/coupdecoeur";
import AccountUserActivated from "./pages/accountuseractivated";
import ProduitsService from "./pages/produitservice";
-import scrollToTop from "react-scroll-to-top";
+
import Recherche_new from "./pages/recherche_new";
import Recherche_old from "./pages/recherche";
import UserSignFirst from "./pages/usersigninfirst";
diff --git a/src/components/DisplayPartnerSession.js b/src/components/DisplayPartnerSession.js
index 3b18c1f..bdfcae1 100644
--- a/src/components/DisplayPartnerSession.js
+++ b/src/components/DisplayPartnerSession.js
@@ -1914,8 +1914,6 @@ const DisplayPartnerSession = (props) => {
}
-
-
if (String(actionmass_preinsc_val) === String("valide_inscr")) {
Accept_List_Inscritpion(tab_mongo_preins_ids);
@@ -9740,9 +9738,10 @@ const DisplayPartnerSession = (props) => {
]
const New_Option_PreInscription = [
+
+ { "id": "update_client", "label": "Demande MAJ Client", "value": "update_client" },
{ "id": "valide_inscr", "label": "Valider Inscription", "value": "valide_inscr" },
{ "id": "refuse_inscr", "label": "Refuser Inscription", "value": "refuse_inscr" },
- { "id": "update_client", "label": "Demande MAJ Client", "value": "update_client" },
]
diff --git a/src/components/UpdateAttendeeList.js b/src/components/UpdateAttendeeList.js
index 8cea195..4293d0e 100644
--- a/src/components/UpdateAttendeeList.js
+++ b/src/components/UpdateAttendeeList.js
@@ -1,18 +1,17 @@
import React, { useRef, useState, useEffect } from "react";
-import TextField from '@mui/material/TextField';
-import MenuItem from '@mui/material/MenuItem';
+
import 'react-confirm-alert/src/react-confirm-alert.css'; // Import css
import Button from '@mui/material/Button';
import axios from "axios";
import { getCookie, setCookie } from 'react-use-cookie';
import { useHistory } from "react-router-dom";
-import Rating from '@mui/material/Rating';
+
import { gridClasses } from '@mui/x-data-grid';
import "react-draft-wysiwyg/dist/react-draft-wysiwyg.css";
import Box from '@mui/material/Box';
-import { FcViewDetails, FcDisapprove } from "react-icons/fc";
+
import 'react-tooltip/dist/react-tooltip.css'
-import { FcCancel, FcApproval, FcAcceptDatabase, FcPrint, FcAlarmClock, FcMultipleSmartphones, FcWorkflow } from "react-icons/fc";
+import { FcCancel, FcApproval, FcAcceptDatabase, } from "react-icons/fc";
import 'reactjs-popup/dist/index.css';
import img_loading_spin from "./../mysy_img/mysy_spin_loading.gif";
import { CiTrash } from "react-icons/ci";
@@ -21,15 +20,7 @@ import { DataGrid, GridToolbar, frFR } from '@mui/x-data-grid';
import { useParams } from 'react-router-dom'
import Header from "./Header";
import Footer from "./Fotter";
-import { FcInfo } from "react-icons/fc";
-import { Document, Page } from 'react-pdf';
-import RadioGroup from '@mui/material/RadioGroup';
-import FormControlLabel from '@mui/material/FormControlLabel';
-import FormControl from '@mui/material/FormControl';
-import FormLabel from '@mui/material/FormLabel';
-import Radio from '@mui/material/Radio';
-import { daDK } from "@mui/material/locale";
-import Checkbox from '@mui/material/Checkbox';
+
import Link from '@mui/material/Link';
import { PiDotsThree } from "react-icons/pi";
import Popup from 'reactjs-popup';
@@ -82,259 +73,84 @@ function UpdateAttendeeList() {
const columns_preinscrit = [
{ field: 'id', headerName: 'id', hide: true },
{ field: '_id', headerName: '_id', hide: true },
- { field: 'civilite', headerName: 'Civ.', minWidth: 100, flex: 1, maxWidth: 100, hide: false, editable: true, editable: false, renderCell: (params) => , },
+ {
+ field: 'civilite', headerName: 'Civ.', minWidth: 100, flex: 1, maxWidth: 100, hide: false, editable: true,
+ type: "singleSelect",
+ valueOptions: [
+ { value: 'm', label: 'M' },
+ { value: 'mme', label: 'Mme' },
+ { value: 'neutre', label: 'Neutre' }
+ ],
+ renderCell: (params) => {
+ return (
+
+
+
+ {params.value && String(params.value) === "m" && "M"}
+ {params.value && String(params.value) === "mme" && "Mme"}
+ {params.value && String(params.value) === "neutre" && "Neutre"}
+
+
+
+ );
+ }
+ },
+
{ field: 'nom', headerName: 'nom', minWidth: 150, flex: 1, hide: false, editable: true, renderCell: (params) => , },
{ field: 'prenom', headerName: 'prenom', minWidth: 150, flex: 1, hide: false, editable: true, renderCell: (params) => , },
- { field: 'email', headerName: 'email', minWidth: 150, flex: 1, flex: 1, renderCell: (params) => , },
- {
- field: "update", headerName: 'Mise à jour',
- renderCell: (cellValues) => {
- return (
+ { field: 'email', headerName: 'email', minWidth: 150, flex: 1, editable: true, renderCell: (params) => , },
- {
- // handleClick_accept(event, cellValues);
- }}
- >
-
-
- }
- modal
- nested
- position="center center"
- >
- {close => (
-
-
- ×
-
-
MySy Information
-
- {' '}
-
- Confirmer la mise à jour des informations du stagiaire
-
-
-
- {
- // handleClick_update_data(event, cellValues);
- close();
- }}> Valider
-
-
-
- {
- //console.log('modal closed ');
- close();
- }}
- >
- Annuler
-
-
-
-
- )}
-
-
- );
- }
- },
-
- {
- field: "valide", headerName: 'Valider',
- renderCell: (cellValues) => {
- return (
-
- {
- // handleClick_accept(event, cellValues);
- }}
- >
-
-
- }
- modal
- nested
- position="center center"
- >
- {close => (
-
-
- ×
-
-
MySy Information
-
- {' '}
-
- En confirmant cette opération, l'inscription du stagiaire sera définitivement validée.
- Il (le stagiaire) sera automatiquement notifié par email de la validation de son inscription.
- Le stagiaire passera de l'onglet "préinscrit" vers l'onglet "inscription".
-
-
-
- {
- // handleClick_accept(event, cellValues);
- //console.log('modal closed ');
- close();
- }}> Valider
-
-
-
- {
- //console.log('modal closed ');
- close();
- }}
- >
- Annuler
-
-
-
-
- )}
-
-
- );
- }
- },
-
- {
- field: "refuse", headerName: 'Refuser',
- renderCell: (cellValues) => {
- return (
-
- {
- // handleClick_refuse(event, cellValues);
- }}
- >
-
-
- }
- modal
- nested
- position="center center"
- >
- {close => (
-
-
- ×
-
-
MySy Information
-
- {' '}
-
- En confirmant cette opération, l'inscription du stagiaire sera refusée .
- Il (le stagiaire) sera automatiquement notifié par email du refus de son inscription.
- Motif du refus :
-
-
-
-
-
- {
- // handleClick_refuse(event, cellValues);
- //console.log('modal closed ');
- close();
- }}> Valider
-
-
-
- {
- //console.log('modal closed ');
- close();
- }}
- >
- Annuler
-
-
-
-
- )}
-
-
-
- );
- }
- },
- {
- field: "delete", headerName: 'Supprimer',
- renderCell: (cellValues) => {
- return (
-
- {
- //handleClick_delete(event, cellValues);
- }}
- >
-
-
- }
- modal
- nested
- position="center center"
- >
- {close => (
-
-
- ×
-
-
MySy Information
-
- {' '}
-
- En confirmant cette opération, l'inscription du stagiaire sera définitivement supprimée .
-
-
-
-
- {
- // handleClick_delete(event, cellValues);
- //console.log('modal closed ');
- close();
- }}> Valider
-
-
-
- {
- //console.log('modal closed ');
- close();
- }}
- >
- Annuler
-
-
-
-
- )}
-
-
-
- );
- }
- }
]
+
+ const [Getall_Client_Communication_Contact_api, setGetall_Client_Communication_Contact_api] = useState();
+ const [Getall_Client_Communication_Contact_message, setGetall_Client_Communication_Contact_message] = useState();
+ const [Getall_Client_Communication_Contact_result, setGetall_Client_Communication_Contact_result] = useState([]);
+ function Getall_Client_Communication_Contact(event) {
+
+ var form = new FormData();
+
+ form.append("_id", client_id);
+ form.append("partner_owner_recid", partner_owner_recid);
+
+ //console.log(" ### Getall_Client_Communication_Contact form = ", form)
+ var myurl = process.env.REACT_APP_API_URL + "myclass/api/Get_Partner_Client_Communication_Contact_NO_TOKEN/";
+
+
+ setLoading(true);
+ axios.post(myurl, form).then(res => {
+
+ setLoading(false);
+ if (String(res.data.status) === String("true")) {
+ //console.log(" In Getall_Client_Communication_Contact res.data.status = " + res.data.status);
+ //console.log(" In Getall_Client_Communication_Contact res.data.message r_class = " + res.data.message);
+ setGetall_Client_Communication_Contact_api("true");
+ setGetall_Client_Communication_Contact_result(res.data.message);
+
+ }
+ else {
+ setGetall_Client_Communication_Contact_api("false");
+ setGetall_Client_Communication_Contact_message(res.data.message);
+ alert(res.data.message);
+ }
+
+ }).catch((error) => {
+ setLoading(false);
+ console.warn('Not good man :( Getall_Client_Communication_Contact = ', error);
+ setGetall_Client_Communication_Contact_api("false");
+ alert(" Impossible de recuperer la liste des stagiaires")
+ //setmyApimyApiMessage("")
+ })
+ }
+
+
const [Partner_Recid, setPartner_Recid] = useState("");
+ const [class_internal_url, setclass_internal_url] = useState("");
+
+
const [New_Getall_TrainingParticipant_result, setNew_Getall_TrainingParticipant_result] = useState([]);
@@ -345,13 +161,10 @@ function UpdateAttendeeList() {
var form = new FormData();
-
-
-
form.append("client_rattachement_id", client_id);
form.append("session_id", session_id);
form.append("partner_owner_recid", partner_owner_recid);
- form.append("status", "0");
+ form.append("status", "0");
//console.log(" ### Getall_TrainingParticipant form = ", form)
var myurl = process.env.REACT_APP_API_URL + "myclass/api/Get_Statgaire_List_Partner_with_filter_FOR_ONLY_INSCRIPTION_NO_TOKEN/";
@@ -378,10 +191,10 @@ function UpdateAttendeeList() {
var local_nom = JSON.parse(x).nom;
var local_prenom = JSON.parse(x).prenom;
var local_email = JSON.parse(x).email;
+ var local_civilite = JSON.parse(x).civilite;
setPartner_Recid(String(JSON.parse(x).partner_owner_recid))
-
-
+ setclass_internal_url(String(JSON.parse(x).class_internal_url))
//---
var node = {
@@ -390,6 +203,7 @@ function UpdateAttendeeList() {
"nom": local_nom,
"prenom": local_prenom,
"email": local_email,
+ "civilite": local_civilite,
};
new_data2.push(node);
@@ -402,8 +216,6 @@ function UpdateAttendeeList() {
setNew_Getall_TrainingParticipant_result(new_data2);
}
-
-
}
else {
setGetall_TrainingParticipant_api("false");
@@ -424,6 +236,7 @@ function UpdateAttendeeList() {
Getall_TrainingParticipant();
+ Getall_Client_Communication_Contact();
window.scrollTo({
top: 0,
behavior: "smooth",
@@ -431,43 +244,11 @@ function UpdateAttendeeList() {
}, [])
-
- function change_survey_data(e) {
-
- var tmp = tab_variable;
-
- tmp[String(e.name)] = e.value;
-
- settab_variable(tmp)
-
- }
-
- const [value, setValue] = React.useState('female');
-
- const handleChange = (event) => {
- setValue(event.target.value);
- };
-
-
-
- const [selected_qcm_value, setselected_qcm_value] = React.useState('');
- const handleChange_qcm = (event) => {
-
-
-
- document.getElementsByName(event.target.name)[0].value = event.target.value;
-
- // setselected_qcm_value(event.target.value);
- change_survey_data(event.target);
- };
-
-
-
function OnchangeCellDataGrid(params) {
// params = la nouvelle lignes
- console.log(params);
+ console.log(" ### zzz params = ", params);
var num_line = params.id; // ==> Id de la ligne changé
var colomn = params.field; // ==> colonne de la ligne changé
@@ -483,9 +264,10 @@ function UpdateAttendeeList() {
var tmp = {};
tmp['id'] = (x).id;
tmp['_id'] = (x)._id;
- tmp['nom'] = new_value
+ tmp['nom'] = new_value;
tmp['prenom'] = (x).prenom;
tmp['email'] = (x).email;
+ tmp['civilite'] = (x).civilite;
return tmp;
@@ -497,9 +279,33 @@ function UpdateAttendeeList() {
tmp['id'] = (x).id;
tmp['_id'] = (x)._id;
tmp['nom'] = (x).nom;
- tmp['prenom'] = new_value
+ tmp['prenom'] = new_value;
tmp['email'] = (x).email;
+ tmp['civilite'] = (x).civilite;
+ return tmp;
+ }
+
+ if (String(num_line) === String(localid) && colomn === "civilite") {
+ var tmp = {};
+ tmp['id'] = (x).id;
+ tmp['_id'] = (x)._id;
+ tmp['nom'] = (x).nom;
+ tmp['prenom'] = (x).prenom;
+ tmp['email'] = (x).email;
+ tmp['civilite'] = new_value;
+
+ return tmp;
+ }
+
+ if (String(num_line) === String(localid) && colomn === "email") {
+ var tmp = {};
+ tmp['id'] = (x).id;
+ tmp['_id'] = (x)._id;
+ tmp['nom'] = (x).nom;
+ tmp['prenom'] = (x).prenom;
+ tmp['email'] = new_value;
+ tmp['civilite'] = (x).civilite;
return tmp;
}
@@ -511,11 +317,15 @@ function UpdateAttendeeList() {
tmp['nom'] = (x).nom;
tmp['prenom'] = (x).prenom;
tmp['email'] = (x).email;
+ tmp['civilite'] = (x).civilite;
return tmp;
});
+
+ console.log(" ### updatedData = ", updatedData);
+
setNew_Getall_TrainingParticipant_result([]);
setNew_Getall_TrainingParticipant_result(updatedData);
@@ -524,7 +334,7 @@ function UpdateAttendeeList() {
const [Record_New_Attendee_Data_api, setRecord_New_Attendee_Data_api] = useState();
const [Record_New_Attendee_Data_message, setRecord_New_Attendee_Data_message] = useState();
- const [Record_New_Attendee_Data_result, setRecord_New_Attendee_Data_result] = useState();
+ const [Record_New_Attendee_Data_result, setRecord_New_Attendee_Data_result] = useState([]);
function Record_New_Attendee_Data() {
var form = new FormData();
@@ -539,7 +349,7 @@ function UpdateAttendeeList() {
const stored_cookie = getCookie('tokenmysypart');
form.append("client_id", client_id);
form.append("session_id", session_id);
- form.append("list_attendee_data", new_attende_dat_JSON);
+ form.append("list_attendee_data", new_attende_dat_JSON);
form.append("partner_recid", Partner_Recid);
var myurl = process.env.REACT_APP_API_URL + "myclass/api/Client_Update_Liste_Attendee_No_Token/";
@@ -581,6 +391,37 @@ function UpdateAttendeeList() {
+
+
+
+
+ {Getall_Client_Communication_Contact_result && Getall_Client_Communication_Contact_result.length > 0 &&
+
+
+
+
+ Bonjour {JSON.parse(Getall_Client_Communication_Contact_result).civilite} {JSON.parse(Getall_Client_Communication_Contact_result).nom}
+
+
+
+
+ Merci de completer les informations des participants à session de formation ci-dessous.
+
+
+ {Getall_TrainingParticipant_result && Getall_TrainingParticipant_result.length > 0 &&
+
+ Formation : {JSON.parse(Getall_TrainingParticipant_result[0]).title}
+ Code Session : {JSON.parse(Getall_TrainingParticipant_result[0]).title}
+ Titre Session : {JSON.parse(Getall_TrainingParticipant_result[0]).session_titre}
+ Date début : {JSON.parse(Getall_TrainingParticipant_result[0]).date_du}
+ Date fin : {JSON.parse(Getall_TrainingParticipant_result[0]).date_au}
+
+
+ }
+
+
+
}
+
@@ -636,8 +477,7 @@ function UpdateAttendeeList() {
nom: item.nom,
prenom: (item).prenom,
email: (item).email,
-
-
+ civilite: (item).civilite,
}
))}
@@ -664,25 +504,62 @@ function UpdateAttendeeList() {
/>
-
-
-
-
-
-
-
-
-
-
Envoyer
-
+
+
+
Mettre à jour
+ }
+ modal
+ nested
+ position="center center"
+ >
+ {close => (
+
+
+ ×
+
+
MySy Information
+
+ {' '}
+
+ En confirmant cette opération, les données des préinscrits seront mises à jour.
+
+
+
+
+
+ {
+ Record_New_Attendee_Data(event);
+ close();
+ }}> Valider
+
+
+
+ {
+ //console.log('modal closed ');
+ close();
+ }}
+ >
+ Annuler
+
+
+
+
+ )}
+
+
@@ -693,30 +570,32 @@ function UpdateAttendeeList() {
-
-
-
-
-
+
- {/*get_Given_Survey_Data_result && get_Given_Survey_Data_result.length > 0 &&
-
+ {class_internal_url && String(class_internal_url).length > 2 &&
+
-
*/}
+
}
}
- {(!Getall_TrainingParticipant_result || Getall_TrainingParticipant_result.length <= 0) &&
+
+ {(!Getall_TrainingParticipant_result || Getall_TrainingParticipant_result.length <= 0) &&
- Le document est invalide
+ Le document est invalide
-
}
+
}
+