17/02/23 - 14h
parent
2f78c5c780
commit
e53f45f19d
|
@ -13,6 +13,8 @@ import MenuItem from '@mui/material/MenuItem';
|
|||
import { AiOutlineEdit } from "react-icons/ai";
|
||||
import { FcCancel, FcApproval, FcAcceptDatabase, FcPrint } from "react-icons/fc";
|
||||
import { DataGrid, GridToolbar, frFR, GridCellParams } from '@mui/x-data-grid';
|
||||
import { AiFillFolderOpen, AiFillMinusSquare } from "react-icons/ai";
|
||||
|
||||
import Popup from 'reactjs-popup';
|
||||
import 'reactjs-popup/dist/index.css';
|
||||
import DatePicker from "react-datepicker";
|
||||
|
@ -400,6 +402,70 @@ function GestionAdministrative(props) {
|
|||
form.append("date", date);
|
||||
form.append("matin", matin_val);
|
||||
form.append("apresmidi", apresmidi_val);
|
||||
form.append("class_internal_url", internal_url);
|
||||
|
||||
//console.log(" ## form = ", form);
|
||||
|
||||
var myurl = process.env.REACT_APP_API_URL + "myclass/api/UpdateUserEmargementDate/";
|
||||
axios.post(myurl, form).then(res => {
|
||||
|
||||
if (String(res.data.status) !== "false") {
|
||||
//console.log(" In UpdateStagiaireData res.data.status = " + res.data.status);
|
||||
//console.log(" In UpdateStagiaireData res.data.message r_class = " + res.data.message);
|
||||
setUpdateStagiaireEmargement_api("true");
|
||||
setUpdateStagiaireEmargement_result(res.data.message);
|
||||
GetListeEmargement(mysession);
|
||||
}
|
||||
else {
|
||||
setUpdateStagiaireEmargement_api("false");
|
||||
setUpdateStagiaireEmargement_message(res.data.message);
|
||||
|
||||
}
|
||||
|
||||
}).catch((error) => {
|
||||
|
||||
console.warn('handleClick_valide_emargement : Not good man :( mysearchtext = ' + error);
|
||||
setUpdateStagiaireEmargement_api("false");
|
||||
|
||||
})
|
||||
|
||||
}
|
||||
|
||||
|
||||
function handleClick_valide_emargement_One(tab_data) {
|
||||
|
||||
var date = tab_data.date;
|
||||
var email = tab_data.email;
|
||||
var matin = tab_data.matin;
|
||||
var matin_val = "";
|
||||
var apresmidi = tab_data.apresmidi;
|
||||
var apresmidi_val = "";
|
||||
|
||||
if (matin === true) {
|
||||
matin_val = "1"
|
||||
} else if (matin === false) {
|
||||
matin_val = "0"
|
||||
}
|
||||
|
||||
if (apresmidi === true) {
|
||||
apresmidi_val = "1"
|
||||
} else if (apresmidi === false) {
|
||||
apresmidi_val = "0"
|
||||
}
|
||||
/*console.log(" ### date , email, matin,matin_val, apresmidi, apresmidi_val = ",
|
||||
date, email, matin, matin_val, apresmidi, apresmidi_val);*/
|
||||
|
||||
var form = new FormData();
|
||||
//form.append("token","K3cw63eKokKSbV4spjQ48SUNnfy80yrXfA");
|
||||
const stored_cookie = getCookie('tokenmysypart');
|
||||
form.append("token", stored_cookie);
|
||||
form.append("session_id", mysession);
|
||||
form.append("email", email);
|
||||
form.append("date", date);
|
||||
form.append("matin", matin_val);
|
||||
form.append("apresmidi", apresmidi_val);
|
||||
form.append("class_internal_url", internal_url);
|
||||
|
||||
|
||||
|
||||
var myurl = process.env.REACT_APP_API_URL + "myclass/api/UpdateUserEmargementDate/";
|
||||
|
@ -493,6 +559,7 @@ function GestionAdministrative(props) {
|
|||
}
|
||||
|
||||
var status = "0";
|
||||
|
||||
var employeur = cellValues.row.employeur;
|
||||
if (String(employeur) === "undefined") {
|
||||
employeur = ""
|
||||
|
@ -1707,7 +1774,7 @@ function GestionAdministrative(props) {
|
|||
|
||||
var nom_fiche_detaillee = "Fiche_Detaillee.pdf";
|
||||
|
||||
var url = process.env.REACT_APP_API_URL + "myclass/api/PrintAttendeeDetail_perSession/" + stored_cookie + "/" + mysession + "/" + selectedattendeeemail+ "/" + internal_url;
|
||||
var url = process.env.REACT_APP_API_URL + "myclass/api/PrintAttendeeDetail_perSession/" + stored_cookie + "/" + mysession + "/" + selectedattendeeemail + "/" + internal_url;
|
||||
|
||||
|
||||
axios.get(url, { responseType: 'blob', },)
|
||||
|
@ -1741,7 +1808,7 @@ function GestionAdministrative(props) {
|
|||
|
||||
var nom_fiche_detaillee = "Fiche_Detaillee.pdf";
|
||||
|
||||
var url = process.env.REACT_APP_API_URL + "myclass/api/PrintAttendeeDetail_perSession/" + stored_cookie + "/" + mysession + "/" + addendeeEmail+ "/" + internal_url;
|
||||
var url = process.env.REACT_APP_API_URL + "myclass/api/PrintAttendeeDetail_perSession/" + stored_cookie + "/" + mysession + "/" + addendeeEmail + "/" + internal_url;
|
||||
|
||||
|
||||
axios.get(url, { responseType: 'blob', },)
|
||||
|
@ -2343,6 +2410,41 @@ function GestionAdministrative(props) {
|
|||
form.append("token", stored_cookie);
|
||||
form.append("session_id", mysession);
|
||||
form.append("attendee_email", selectedattendeeemail);
|
||||
form.append("class_internal_url", internal_url);
|
||||
|
||||
|
||||
var myurl = process.env.REACT_APP_API_URL + "myclass/api/SendTrainingEvaluationEmail/";
|
||||
|
||||
axios.post(myurl, form).then(res => {
|
||||
|
||||
if (String(res.data.status) == "true") {
|
||||
//console.log(" In SendEvaluationEmail res.data.status = " + res.data.status);
|
||||
//console.log(" In SendEvaluationEmail res.data.message r_class = " + res.data.message);
|
||||
setSendEvaluationEmail_api("true");
|
||||
setSendEvaluationEmail_result(res.data.message);
|
||||
|
||||
}
|
||||
else {
|
||||
setSendEvaluationEmail_api("false");
|
||||
setSendEvaluationEmail_message(res.data.message);
|
||||
}
|
||||
|
||||
}).catch((error) => {
|
||||
console.warn('Not good man :( SendEvaluationEmail = ', error);
|
||||
setSendEvaluationEmail_api("false");
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
function SendEvaluationEmail_One(email) {
|
||||
|
||||
var form = new FormData();
|
||||
const stored_cookie = getCookie('tokenmysypart');
|
||||
form.append("token", stored_cookie);
|
||||
form.append("session_id", mysession);
|
||||
form.append("attendee_email", email);
|
||||
form.append("class_internal_url", internal_url);
|
||||
|
||||
|
||||
var myurl = process.env.REACT_APP_API_URL + "myclass/api/SendTrainingEvaluationEmail/";
|
||||
|
||||
|
@ -2453,7 +2555,7 @@ function GestionAdministrative(props) {
|
|||
}
|
||||
|
||||
const [retval_ch, setretval_ch] = useState();
|
||||
function actionmass_preinsc_Traitemet() {
|
||||
async function actionmass_preinsc_Traitemet() {
|
||||
|
||||
var liste_formation = GetSelectedRows_PresInsc_Ids();
|
||||
for (var i = 0; i < liste_formation.length; i++) {
|
||||
|
@ -2510,6 +2612,7 @@ function GestionAdministrative(props) {
|
|||
}
|
||||
//console.log(" retval de ", email + " = retval_ch =", retval_ch);
|
||||
|
||||
await sleep(100);
|
||||
}
|
||||
setSelectionModel([]);
|
||||
setactionmass_preinsc_val();
|
||||
|
@ -2543,16 +2646,16 @@ function GestionAdministrative(props) {
|
|||
|
||||
}
|
||||
|
||||
function actionmass_insc_Traitemet() {
|
||||
async function actionmass_insc_Traitemet() {
|
||||
|
||||
var liste_formation = GetSelectedRows_Insc_Ids();
|
||||
for (var i = 0; i < liste_formation.length; i++) {
|
||||
|
||||
|
||||
var line = JSON.parse(rowss_insc[i]);
|
||||
console.log(" line = ", line);
|
||||
var email = line.email;
|
||||
console.log(" Traitement de email = ", email);
|
||||
if (String(actionmass_insc_val) === "confirmation") {
|
||||
if (String(actionmass_insc_val) === "confirmation") {
|
||||
|
||||
SendInscriptionConfirmation(email);
|
||||
} else if (String(actionmass_insc_val) === "impression") {
|
||||
|
@ -2561,6 +2664,7 @@ function GestionAdministrative(props) {
|
|||
DownloadAttendeeDetail_one(email);
|
||||
|
||||
}
|
||||
await sleep(100);
|
||||
|
||||
}
|
||||
|
||||
|
@ -2568,6 +2672,109 @@ function GestionAdministrative(props) {
|
|||
setactionmass_insc_val();
|
||||
}
|
||||
|
||||
const [actionmass_emarg_val, setactionmass_emarg_val] = useState();
|
||||
const actionmass_emarg = (event) => {
|
||||
const value = event.target.value;
|
||||
|
||||
|
||||
if (String(value) === "valider" || String(value) === "demande emargement") {
|
||||
setactionmass_emarg_val(value);
|
||||
}
|
||||
else {
|
||||
setactionmass_emarg_val();
|
||||
}
|
||||
}
|
||||
|
||||
function GetSelectedRows_Emarg_Ids() {
|
||||
|
||||
var tab_tmp = []
|
||||
for (var i = 0; i < selectionModel_emarg.length; i++) {
|
||||
var myid = parseInt(String(selectionModel_emarg[i]));
|
||||
//var line = JSON.parse(rowss[myid]);
|
||||
tab_tmp.push(myid);
|
||||
}
|
||||
return tab_tmp;
|
||||
|
||||
}
|
||||
|
||||
async function actionmass_emarge_Traitemet() {
|
||||
var liste_formation = GetSelectedRows_Emarg_Ids();
|
||||
for (var i = 0; i < liste_formation.length; i++) {
|
||||
var line = JSON.parse(rowss_emarg[i]);
|
||||
//console.log(" line = ", line);
|
||||
var email = line.email;
|
||||
//console.log(" Traitement de email = ", email);
|
||||
|
||||
if (String(actionmass_emarg_val) === "demande emargement") {
|
||||
ActionMassListEmargement();
|
||||
}
|
||||
await sleep(100)
|
||||
}
|
||||
setSelectionModel_emarg([]);
|
||||
actionmass_emarg_val();
|
||||
}
|
||||
|
||||
|
||||
const [actionmass_eval_val, setactionmass_eval_val] = useState();
|
||||
const actionmass_evaluation = (event) => {
|
||||
const value = event.target.value;
|
||||
|
||||
console.log(" ### actionmass_evaluation = ", value);
|
||||
|
||||
if (String(value) === "demande evaluation") {
|
||||
setactionmass_eval_val(value);
|
||||
console.log(" ### LAAA = ", value);
|
||||
}
|
||||
|
||||
else {
|
||||
setactionmass_eval_val();
|
||||
}
|
||||
}
|
||||
|
||||
function GetSelectedRows_Evaluation_Ids() {
|
||||
|
||||
var tab_tmp = []
|
||||
for (var i = 0; i < selectionModel_evaluation.length; i++) {
|
||||
var myid = parseInt(String(selectionModel_evaluation[i]));
|
||||
//var line = JSON.parse(rowss[myid]);
|
||||
tab_tmp.push(myid);
|
||||
}
|
||||
return tab_tmp;
|
||||
|
||||
}
|
||||
|
||||
const sleep = (milliseconds) => {
|
||||
return new Promise(resolve => setTimeout(resolve, milliseconds))
|
||||
}
|
||||
|
||||
async function actionmass_Evaluation_Traitemet() {
|
||||
var liste_formation = GetSelectedRows_Evaluation_Ids();
|
||||
for (var i = 0; i < liste_formation.length; i++) {
|
||||
var line = JSON.parse(rowss_evaluation[i]);
|
||||
//console.log(" line = ", line);
|
||||
var email = line.email;
|
||||
|
||||
if (String(actionmass_eval_val) === "demande evaluation") {
|
||||
|
||||
SendEvaluationEmail_One(email);
|
||||
}
|
||||
await sleep(100)
|
||||
}
|
||||
setSelectionModel_evaluation([]);
|
||||
setactionmass_eval_val();
|
||||
}
|
||||
|
||||
const [reduction_session, setreduction_session] = useState("0");
|
||||
function Session_small() {
|
||||
if (String(reduction_session) === "1") {
|
||||
setreduction_session("0");
|
||||
}
|
||||
else if (String(reduction_session) === "0") {
|
||||
setreduction_session("1");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return (
|
||||
<div className='gestionadministrative'>
|
||||
<Helmet>
|
||||
|
@ -2709,9 +2916,6 @@ function GestionAdministrative(props) {
|
|||
</option>
|
||||
))}
|
||||
</select>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
@ -2720,6 +2924,16 @@ function GestionAdministrative(props) {
|
|||
|
||||
<div className="session_data" onChange={IssessionChanged}>
|
||||
|
||||
{mysession && String(reduction_session) === "0" && <div className="div_row" style={{ "border": "None", "height": "1rem" }}>
|
||||
<div onClick={Session_small} className="session_open_close"> Reduire la fenetre <AiFillMinusSquare /></div>
|
||||
</div>
|
||||
}
|
||||
|
||||
{mysession && String(reduction_session) === "1" && <div className="div_row" style={{ "border": "None", "height": "1rem" }}>
|
||||
<div onClick={Session_small} className="session_open_close"> Ouvrir la fenetre <AiFillFolderOpen /></div>
|
||||
</div>
|
||||
}
|
||||
|
||||
{mysession && <div className="div_row" style={{ "border": "None" }}>
|
||||
|
||||
<div className="session_caract" style={{ "float": "right" }}>
|
||||
|
@ -2823,240 +3037,237 @@ function GestionAdministrative(props) {
|
|||
</TextField>
|
||||
</div>
|
||||
|
||||
|
||||
<div className="session_caract"> Adresse<br />
|
||||
<TextField
|
||||
sx={{ '& legend': { display: 'none' }, '& fieldset': { top: 0 }, }}
|
||||
required
|
||||
name="adresse"
|
||||
id="adresse"
|
||||
|
||||
InputLabelProps={{
|
||||
shrink: true,
|
||||
}}
|
||||
disabled={false}
|
||||
className="disabled_style"
|
||||
|
||||
/>
|
||||
</div>
|
||||
<div className="session_caract"> Code postal<br />
|
||||
<TextField
|
||||
sx={{ '& legend': { display: 'none' }, '& fieldset': { top: 0 }, }}
|
||||
required
|
||||
name="code_postal"
|
||||
id="code_postal"
|
||||
|
||||
InputLabelProps={{
|
||||
shrink: true,
|
||||
}}
|
||||
disabled={false}
|
||||
className="disabled_style"
|
||||
|
||||
/>
|
||||
</div>
|
||||
<div className="session_caract"> Ville<br />
|
||||
<TextField
|
||||
sx={{ '& legend': { display: 'none' }, '& fieldset': { top: 0 }, }}
|
||||
required
|
||||
name="ville"
|
||||
id="ville"
|
||||
|
||||
InputLabelProps={{
|
||||
shrink: true,
|
||||
}}
|
||||
disabled={false}
|
||||
className="disabled_style"
|
||||
|
||||
/>
|
||||
</div>
|
||||
|
||||
<div className="session_caract"> Formateur<br />
|
||||
<TextField
|
||||
sx={{ '& legend': { display: 'none' }, '& fieldset': { top: 0 }, }}
|
||||
required
|
||||
name="formateur"
|
||||
id="formateur"
|
||||
|
||||
InputLabelProps={{
|
||||
shrink: true,
|
||||
}}
|
||||
disabled={false}
|
||||
className="disabled_style"
|
||||
|
||||
/>
|
||||
</div>
|
||||
|
||||
<div className="session_caract"> Nombre participants *<br />
|
||||
<TextField sx={{ '& legend': { display: 'none' }, '& fieldset': { top: 0 }, }}
|
||||
required
|
||||
name="nb_participant"
|
||||
id="nb_participant"
|
||||
type="number"
|
||||
InputLabelProps={{
|
||||
shrink: true,
|
||||
}}
|
||||
inputProps={{ min: "1", max: "1000", step: "1" }}
|
||||
disabled={false}
|
||||
className="disabled_style"
|
||||
/>
|
||||
</div>
|
||||
|
||||
<div className="session_caract"> Prix session <br />
|
||||
<TextField sx={{ '& legend': { display: 'none' }, '& fieldset': { top: 0 }, }}
|
||||
required
|
||||
name="prix_session"
|
||||
id="prix_session"
|
||||
type="number"
|
||||
InputLabelProps={{
|
||||
shrink: true,
|
||||
}}
|
||||
inputProps={{ min: "1", max: "1000", step: "1" }}
|
||||
disabled={false}
|
||||
className="disabled_style"
|
||||
/>
|
||||
</div>
|
||||
|
||||
|
||||
<div className="div_row" style={{ "border": "None" }}>
|
||||
<div className="session_caract"> Date Debut des inscriptions *
|
||||
<DatePicker
|
||||
{String(reduction_session) === "0" && <div>
|
||||
<div className="session_caract"> Adresse<br />
|
||||
<TextField
|
||||
sx={{ '& legend': { display: 'none' }, '& fieldset': { top: 0 }, }}
|
||||
required
|
||||
name="sessiondatedebutinscription"
|
||||
id="sessiondatedebutinscription"
|
||||
selected={SessionstartDateInscription}
|
||||
onChange={(date) => {
|
||||
setSessionstartDateInscription(date);
|
||||
setsessionChanged(true);
|
||||
}
|
||||
name="adresse"
|
||||
id="adresse"
|
||||
|
||||
}
|
||||
showTimeSelect
|
||||
//filterTime={filterPassedTime_start}
|
||||
dateFormat="dd/MM/yyyy HH:mm"
|
||||
className="disabled_style"
|
||||
locale='fr-FR'
|
||||
|
||||
/>
|
||||
</div>
|
||||
|
||||
|
||||
<div className="session_caract"> Date Fin des inscriptions *
|
||||
<DatePicker
|
||||
required
|
||||
name="sessiondatefininscription"
|
||||
id="sessiondatefininscription"
|
||||
selected={SessionendDateInscription}
|
||||
onChange={(date) => {
|
||||
setSessionendDateInscription(date);
|
||||
setsessionChanged(true);
|
||||
}
|
||||
}
|
||||
showTimeSelect
|
||||
//filterTime={filterPassedTime_end}
|
||||
dateFormat="dd/MM/yyyy HH:mm"
|
||||
className="disabled_style"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div className="div_row" style={{ "border": "None" }}>
|
||||
{!fields1desabled && <div className="session_caract">Choisir un modèle d'attestation :
|
||||
|
||||
<select id="certif_liste" name="certif_liste" value={selectedCertif} onChange={handleChangeselectedCertif} className="selectsession">
|
||||
<option value="">Choisir un modèle </option>
|
||||
{GetAttestation_Certif_result &&
|
||||
GetAttestation_Certif_result.map((certificat) => (
|
||||
<option value={JSON.parse(certificat).nom}>
|
||||
{JSON.parse(certificat).nom}
|
||||
|
||||
</option>
|
||||
))}
|
||||
</select>
|
||||
<img className="preview_certif" src={urlpreview_certif} />
|
||||
|
||||
</div>}
|
||||
{fields1desabled && <div className="session_caract">Le modèle d'attestation :
|
||||
|
||||
<img className="preview_certif" src={urlpreview_certif} />
|
||||
|
||||
</div>}
|
||||
|
||||
<div className="session_caract"> Contenu de la formation (max 800 caractères)<br />
|
||||
<i> (à afficher sur l'attestation) </i>
|
||||
{!fields1desabled && <br />}
|
||||
{!fields1desabled && <br />}
|
||||
|
||||
<Editor
|
||||
onInit={(evt, editor) => editorRef_contenu_ftion.current = editor}
|
||||
initialValue={field_contenu_ftion}
|
||||
onKeyUp={editor_contenu_ftion_keyup}
|
||||
disabled={fields1desabled}
|
||||
|
||||
init={{
|
||||
resize: false,
|
||||
|
||||
height: 200,
|
||||
menubar: false,
|
||||
plugins: [
|
||||
'advlist autolink lists link image charmap print preview anchor',
|
||||
'searchreplace visualblocks code fullscreen',
|
||||
'insertdatetime media table paste code help wordcount'
|
||||
],
|
||||
toolbar: false,
|
||||
content_style: 'body { font-family:Helvetica,Arial,sans-serif; font-size:12px; }'
|
||||
InputLabelProps={{
|
||||
shrink: true,
|
||||
}}
|
||||
disabled={false}
|
||||
className="disabled_style"
|
||||
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div className="session_caract"> Code postal<br />
|
||||
<TextField
|
||||
sx={{ '& legend': { display: 'none' }, '& fieldset': { top: 0 }, }}
|
||||
required
|
||||
name="code_postal"
|
||||
id="code_postal"
|
||||
|
||||
InputLabelProps={{
|
||||
shrink: true,
|
||||
}}
|
||||
disabled={false}
|
||||
className="disabled_style"
|
||||
|
||||
<div className="div_row" style={{ "border": "None" }}>
|
||||
|
||||
</div>
|
||||
/>
|
||||
</div>
|
||||
<div className="session_caract"> Ville<br />
|
||||
<TextField
|
||||
sx={{ '& legend': { display: 'none' }, '& fieldset': { top: 0 }, }}
|
||||
required
|
||||
name="ville"
|
||||
id="ville"
|
||||
|
||||
InputLabelProps={{
|
||||
shrink: true,
|
||||
}}
|
||||
disabled={false}
|
||||
className="disabled_style"
|
||||
|
||||
{sessionChanged && <div className="div_row" style={{ "border": "None", "color": "orange", "textAlign": "center" }}>
|
||||
/!\ Pensez à enregistrer les modifications
|
||||
</div>}
|
||||
|
||||
{!sessionChanged && String(CreateSessionFormation_api) === "true" &&
|
||||
<div className="div_row okUpdateData" style={{ "textAlign": "center" }}>
|
||||
La session de formation à été bien mise à jour.
|
||||
</div>}
|
||||
|
||||
{String(CreateSessionFormation_api) === "false" &&
|
||||
<div className="div_row koUpdateData" style={{ "textAlign": "center" }}>
|
||||
{CreateSessionFormation_message}
|
||||
</div>}
|
||||
|
||||
|
||||
{<div className="div_row" style={{ "border": "None", "color": "orange", "textAlign": "center" }}>
|
||||
|
||||
<div className="div_row_gauche" style={{ "textAlign": 'left', 'marginLeft': '15px' }}>
|
||||
|
||||
{sessionChanged && mysession &&
|
||||
<Button variant="contained" className="bton_envoyer" onClick={CreateSessionFormation}>Enregistrer les modifications
|
||||
</Button>}
|
||||
/>
|
||||
</div>
|
||||
|
||||
<div className="div_row_droite" style={{ "textAlign": 'right', 'marginRight': '15px' }}>
|
||||
{!sessionChanged && mysession && fields1desabled &&
|
||||
<Button variant="contained" className="bton_fermer" onClick={enableSessionFields}>Editer
|
||||
</Button>}
|
||||
|
||||
{((sessionChanged && mysession) || !fields1desabled) &&
|
||||
<Button variant="contained" className="bton_fermer" onClick={annuleSessionUpdate}>Annuler les modifications
|
||||
</Button>}
|
||||
|
||||
|
||||
<div className="session_caract"> Formateur<br />
|
||||
<TextField
|
||||
sx={{ '& legend': { display: 'none' }, '& fieldset': { top: 0 }, }}
|
||||
required
|
||||
name="formateur"
|
||||
id="formateur"
|
||||
|
||||
InputLabelProps={{
|
||||
shrink: true,
|
||||
}}
|
||||
disabled={false}
|
||||
className="disabled_style"
|
||||
|
||||
/>
|
||||
</div>
|
||||
|
||||
<div className="session_caract"> Nombre participants *<br />
|
||||
<TextField sx={{ '& legend': { display: 'none' }, '& fieldset': { top: 0 }, }}
|
||||
required
|
||||
name="nb_participant"
|
||||
id="nb_participant"
|
||||
type="number"
|
||||
InputLabelProps={{
|
||||
shrink: true,
|
||||
}}
|
||||
inputProps={{ min: "1", max: "1000", step: "1" }}
|
||||
disabled={false}
|
||||
className="disabled_style"
|
||||
/>
|
||||
</div>
|
||||
|
||||
<div className="session_caract"> Prix session <br />
|
||||
<TextField sx={{ '& legend': { display: 'none' }, '& fieldset': { top: 0 }, }}
|
||||
required
|
||||
name="prix_session"
|
||||
id="prix_session"
|
||||
type="number"
|
||||
InputLabelProps={{
|
||||
shrink: true,
|
||||
}}
|
||||
inputProps={{ min: "1", max: "1000", step: "1" }}
|
||||
disabled={false}
|
||||
className="disabled_style"
|
||||
/>
|
||||
</div>
|
||||
|
||||
|
||||
<div className="div_row" style={{ "border": "None" }}>
|
||||
<div className="session_caract"> Date Debut des inscriptions *
|
||||
<DatePicker
|
||||
required
|
||||
name="sessiondatedebutinscription"
|
||||
id="sessiondatedebutinscription"
|
||||
selected={SessionstartDateInscription}
|
||||
onChange={(date) => {
|
||||
setSessionstartDateInscription(date);
|
||||
setsessionChanged(true);
|
||||
}
|
||||
|
||||
}
|
||||
showTimeSelect
|
||||
//filterTime={filterPassedTime_start}
|
||||
dateFormat="dd/MM/yyyy HH:mm"
|
||||
className="disabled_style"
|
||||
locale='fr-FR'
|
||||
|
||||
/>
|
||||
</div>
|
||||
|
||||
|
||||
<div className="session_caract"> Date Fin des inscriptions *
|
||||
<DatePicker
|
||||
required
|
||||
name="sessiondatefininscription"
|
||||
id="sessiondatefininscription"
|
||||
selected={SessionendDateInscription}
|
||||
onChange={(date) => {
|
||||
setSessionendDateInscription(date);
|
||||
setsessionChanged(true);
|
||||
}
|
||||
}
|
||||
showTimeSelect
|
||||
//filterTime={filterPassedTime_end}
|
||||
dateFormat="dd/MM/yyyy HH:mm"
|
||||
className="disabled_style"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div className="div_row" style={{ "border": "None" }}>
|
||||
{!fields1desabled && <div className="session_caract">Choisir un modèle d'attestation :
|
||||
|
||||
<select id="certif_liste" name="certif_liste" value={selectedCertif} onChange={handleChangeselectedCertif} className="selectsession">
|
||||
<option value="">Choisir un modèle </option>
|
||||
{GetAttestation_Certif_result &&
|
||||
GetAttestation_Certif_result.map((certificat) => (
|
||||
<option value={JSON.parse(certificat).nom}>
|
||||
{JSON.parse(certificat).nom}
|
||||
|
||||
</option>
|
||||
))}
|
||||
</select>
|
||||
<img className="preview_certif" src={urlpreview_certif} />
|
||||
|
||||
</div>}
|
||||
{fields1desabled && <div className="session_caract">Le modèle d'attestation :
|
||||
|
||||
<img className="preview_certif" src={urlpreview_certif} />
|
||||
|
||||
</div>}
|
||||
|
||||
<div className="session_caract"> Contenu de la formation (max 800 caractères)<br />
|
||||
<i> (à afficher sur l'attestation) </i>
|
||||
{!fields1desabled && <br />}
|
||||
{!fields1desabled && <br />}
|
||||
|
||||
<Editor
|
||||
onInit={(evt, editor) => editorRef_contenu_ftion.current = editor}
|
||||
initialValue={field_contenu_ftion}
|
||||
onKeyUp={editor_contenu_ftion_keyup}
|
||||
disabled={fields1desabled}
|
||||
|
||||
init={{
|
||||
resize: false,
|
||||
|
||||
height: 200,
|
||||
menubar: false,
|
||||
plugins: [
|
||||
'advlist autolink lists link image charmap print preview anchor',
|
||||
'searchreplace visualblocks code fullscreen',
|
||||
'insertdatetime media table paste code help wordcount'
|
||||
],
|
||||
toolbar: false,
|
||||
content_style: 'body { font-family:Helvetica,Arial,sans-serif; font-size:12px; }'
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div className="div_row" style={{ "border": "None" }}>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
{sessionChanged && <div className="div_row" style={{ "border": "None", "color": "orange", "textAlign": "center" }}>
|
||||
/!\ Pensez à enregistrer les modifications
|
||||
</div>}
|
||||
|
||||
{!sessionChanged && String(CreateSessionFormation_api) === "true" &&
|
||||
<div className="div_row okUpdateData" style={{ "textAlign": "center" }}>
|
||||
La session de formation à été bien mise à jour.
|
||||
</div>}
|
||||
|
||||
{String(CreateSessionFormation_api) === "false" &&
|
||||
<div className="div_row koUpdateData" style={{ "textAlign": "center" }}>
|
||||
{CreateSessionFormation_message}
|
||||
</div>}
|
||||
|
||||
|
||||
{<div className="div_row" style={{ "border": "None", "color": "orange", "textAlign": "center" }}>
|
||||
|
||||
<div className="div_row_gauche" style={{ "textAlign": 'left', 'marginLeft': '15px' }}>
|
||||
|
||||
{sessionChanged && mysession &&
|
||||
<Button variant="contained" className="bton_envoyer" onClick={CreateSessionFormation}>Enregistrer les modifications
|
||||
</Button>}
|
||||
</div>
|
||||
|
||||
<div className="div_row_droite" style={{ "textAlign": 'right', 'marginRight': '15px' }}>
|
||||
{!sessionChanged && mysession && fields1desabled &&
|
||||
<Button variant="contained" className="bton_fermer" onClick={enableSessionFields}>Editer
|
||||
</Button>}
|
||||
|
||||
{((sessionChanged && mysession) || !fields1desabled) &&
|
||||
<Button variant="contained" className="bton_fermer" onClick={annuleSessionUpdate}>Annuler les modifications
|
||||
</Button>}
|
||||
|
||||
</div>
|
||||
|
||||
</div>}
|
||||
|
||||
</div>}
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
@ -3124,7 +3335,7 @@ function GestionAdministrative(props) {
|
|||
|
||||
{selectionModel && selectionModel.length >= 1 &&
|
||||
<div className="div_row" style={{ "border": "none" }}>
|
||||
<div style={{ "width": "50%", "float": "left" }}>
|
||||
<div className="block_en_mass">
|
||||
<nav className='traitement_mass'>Traitement en masse</nav>
|
||||
<select
|
||||
id={"actionmass_preinsc"} name={"actionmass_preinsc"}
|
||||
|
@ -3235,7 +3446,7 @@ function GestionAdministrative(props) {
|
|||
/>
|
||||
<br />
|
||||
{selectionModel_insc && selectionModel_insc.length >= 1 &&
|
||||
<div style={{ "width": "50%", "float": "left" }}>
|
||||
<div className="block_en_mass">
|
||||
<nav className='traitement_mass'>Traitement en masse / Inscrit</nav>
|
||||
<select
|
||||
id={"actionmassinscr"} name={"actionmassinscr"}
|
||||
|
@ -3370,11 +3581,73 @@ function GestionAdministrative(props) {
|
|||
|
||||
|
||||
/>
|
||||
{selectionModel_emarg && selectionModel_emarg.length >= 1 &&
|
||||
<div className="block_en_mass">
|
||||
<nav className='traitement_mass'>Traitement en masse / Emarge</nav>
|
||||
<select
|
||||
id={"actionmassemarg"} name={"actionmassemarg"}
|
||||
onChange={actionmass_emarg}
|
||||
className="action_mass">
|
||||
<option selected value="n/a">Choisir une action</option>
|
||||
<option value="demande emargement">Demande emargement</option>
|
||||
|
||||
</select>
|
||||
|
||||
{actionmass_emarg_val &&
|
||||
<Popup
|
||||
trigger={<Button className="bton_traiter_en_mass" >
|
||||
<FcAcceptDatabase /> Traiter
|
||||
|
||||
</Button>}
|
||||
modal
|
||||
nested
|
||||
position="center center"
|
||||
>
|
||||
|
||||
{close => (
|
||||
<div>
|
||||
<button className="gest_close" onClick={close}>
|
||||
×
|
||||
</button>
|
||||
<div className="gest_header"> MySy Information </div>
|
||||
<div className="gest_content">
|
||||
{' '}
|
||||
|
||||
Confirmer l'action <b> {actionmass_emarg_val} </b> en masse.
|
||||
</div>
|
||||
<div className="gest_actions">
|
||||
<div style={{ "width": "45%", "float": "left" }}>
|
||||
<button className="gest_bton_popup" onClick={(event) => {
|
||||
actionmass_emarge_Traitemet();
|
||||
close();
|
||||
}}> Valider </button>
|
||||
|
||||
</div>
|
||||
<div style={{ "width": "45%", "float": "right" }}>
|
||||
<button
|
||||
className="gest_bton_popup"
|
||||
onClick={() => {
|
||||
//console.log('modal closed ');
|
||||
close();
|
||||
}}
|
||||
>
|
||||
Annuler
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
)}
|
||||
</Popup>
|
||||
}
|
||||
<br />
|
||||
|
||||
|
||||
</div>
|
||||
}
|
||||
|
||||
<br />
|
||||
<Button className="bton_emarge" onClick={ActionMassListEmargement}>Envoyer les demandes d'emargement</Button><br />
|
||||
|
||||
{/*<Button className="bton_emarge" onClick={ActionMassListEmargement}>Envoyer les demandes d'emargement</Button><br />
|
||||
*/}
|
||||
|
||||
|
||||
</div>
|
||||
|
@ -3432,6 +3705,69 @@ function GestionAdministrative(props) {
|
|||
|
||||
/>
|
||||
|
||||
{selectionModel_evaluation && selectionModel_evaluation.length >= 1 &&
|
||||
<div className="block_en_mass">
|
||||
<nav className='traitement_mass'>Traitement en masse / Evaluation</nav>
|
||||
<select
|
||||
id={"actionmassemarg"} name={"actionmassemarg"}
|
||||
onChange={actionmass_evaluation}
|
||||
className="action_mass">
|
||||
<option selected value="n/a">Choisir une action</option>
|
||||
<option value="demande evaluation">Demande évaluation</option>
|
||||
|
||||
</select>
|
||||
|
||||
{actionmass_eval_val &&
|
||||
<Popup
|
||||
trigger={<Button className="bton_traiter_en_mass" >
|
||||
<FcAcceptDatabase /> Traiter
|
||||
|
||||
</Button>}
|
||||
modal
|
||||
nested
|
||||
position="center center"
|
||||
>
|
||||
|
||||
{close => (
|
||||
<div>
|
||||
<button className="gest_close" onClick={close}>
|
||||
×
|
||||
</button>
|
||||
<div className="gest_header"> MySy Information </div>
|
||||
<div className="gest_content">
|
||||
{' '}
|
||||
|
||||
Confirmer l'action <b> {actionmass_eval_val} </b> en masse.
|
||||
</div>
|
||||
<div className="gest_actions">
|
||||
<div style={{ "width": "45%", "float": "left" }}>
|
||||
<button className="gest_bton_popup" onClick={(event) => {
|
||||
actionmass_Evaluation_Traitemet();
|
||||
close();
|
||||
}}> Valider </button>
|
||||
|
||||
</div>
|
||||
<div style={{ "width": "45%", "float": "right" }}>
|
||||
<button
|
||||
className="gest_bton_popup"
|
||||
onClick={() => {
|
||||
//console.log('modal closed ');
|
||||
close();
|
||||
}}
|
||||
>
|
||||
Annuler
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
)}
|
||||
</Popup>
|
||||
}
|
||||
<br />
|
||||
|
||||
|
||||
</div>
|
||||
}
|
||||
|
||||
<br />
|
||||
|
||||
|
|
|
@ -211,7 +211,7 @@
|
|||
padding: 6px !important;
|
||||
}
|
||||
|
||||
.preview_certif{
|
||||
.preview_certif {
|
||||
display: block;
|
||||
width: 90%;
|
||||
height: 180px;
|
||||
|
@ -432,8 +432,8 @@
|
|||
.css-qiwgdb {
|
||||
padding: 6px !important;
|
||||
}
|
||||
|
||||
.preview_certif{
|
||||
|
||||
.preview_certif {
|
||||
display: block;
|
||||
width: 90%;
|
||||
height: 200px;
|
||||
|
@ -660,13 +660,14 @@
|
|||
padding: 6px !important;
|
||||
}
|
||||
|
||||
.preview_certif{
|
||||
.preview_certif {
|
||||
display: block;
|
||||
width: 90%;
|
||||
height: 180px;
|
||||
border-radius: 1rem !important;
|
||||
margin-top: 1rem !important;
|
||||
}
|
||||
|
||||
.preview_certif:hover {
|
||||
transform: scale(2);
|
||||
margin-left: 5rem;
|
||||
|
@ -692,7 +693,7 @@
|
|||
//border: 1px solid black;
|
||||
border-width: 0.01rem;
|
||||
width: 100%;
|
||||
margin-bottom: 1rem;
|
||||
//margin-bottom: 1rem;
|
||||
border-radius: 1rem;
|
||||
}
|
||||
|
||||
|
@ -772,7 +773,7 @@
|
|||
.detail_class_submenu:hover {
|
||||
background-color: #104277;
|
||||
color: white;
|
||||
}
|
||||
}
|
||||
|
||||
.detail_class_submenu:focus {
|
||||
//border: 3px dotted green;
|
||||
|
@ -856,7 +857,7 @@
|
|||
margin: 5px !important;
|
||||
}
|
||||
|
||||
.preview_certif{
|
||||
.preview_certif {
|
||||
display: block;
|
||||
width: 90%;
|
||||
height: 200px;
|
||||
|
@ -879,6 +880,21 @@
|
|||
height: 2.5rem;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.block_en_mass {
|
||||
width: 50%;
|
||||
float: left;
|
||||
margin-bottom: 1rem;
|
||||
}
|
||||
|
||||
.session_open_close {
|
||||
cursor: pointer;
|
||||
text-align: right;
|
||||
font-size: small;
|
||||
margin-right: 10px;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// end media
|
||||
|
@ -930,7 +946,7 @@
|
|||
margin-left: 5%;
|
||||
height: 2.5rem;
|
||||
color: white;
|
||||
|
||||
|
||||
}
|
||||
|
||||
.bton_fermer {
|
||||
|
@ -953,6 +969,6 @@
|
|||
}
|
||||
|
||||
|
||||
.tox-statusbar{
|
||||
.tox-statusbar {
|
||||
display: none !important;
|
||||
}
|
Loading…
Reference in New Issue