31/01/2024 - 16h
parent
8024e787b6
commit
0008cc73be
|
@ -143,6 +143,19 @@ const DisplayPartnerSession = (props) => {
|
|||
);
|
||||
}
|
||||
|
||||
|
||||
|
||||
function Display_Colunm_text({ value }) {
|
||||
|
||||
return (
|
||||
<div style={{ paddingLeft: "5px", paddingRight: "10px", "display": "block", wordBreak: "break-all" }}>
|
||||
{value}
|
||||
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
const [datagrid_columns_size_model1, setdatagrid_columns_size_model1] = useState(200);
|
||||
const [datagrid_columns_size_model2, setdatagrid_columns_size_model2] = useState(100);
|
||||
|
||||
|
@ -155,18 +168,22 @@ const DisplayPartnerSession = (props) => {
|
|||
|
||||
{
|
||||
field: 'statut', headerName: 'Statut', hide: true, width: datagrid_columns_size_model2,
|
||||
valueFormatter: (params) => {
|
||||
if (String(params.value) === "0")
|
||||
return "Inactif";
|
||||
else if (String(params.value) === "1")
|
||||
return "Actif";
|
||||
else
|
||||
return "?";
|
||||
renderCell: (cellValues) => {
|
||||
return (
|
||||
|
||||
<div style={{ paddingLeft: "5px", paddingRight: "10px", "display": "block", wordBreak: "break-all" }}>
|
||||
{String(cellValues.row.distantiel) === "1" && "Actif"}
|
||||
{String(cellValues.row.distantiel) !== "1" && "Inactif"}
|
||||
|
||||
</div>
|
||||
|
||||
);
|
||||
},
|
||||
|
||||
},
|
||||
|
||||
{
|
||||
field: 'etape', headerName: 'Etape', hide: false, width: datagrid_columns_size_model2,
|
||||
field: 'etape', headerName: 'Etape', hide: false, width: datagrid_columns_size_model2, renderCell: (params) => <ExpandableCell_50 {...params} />,
|
||||
|
||||
},
|
||||
{ field: 'class_external_code', headerName: 'Code Formation', align: "center", hideable: true, flex: 1, hide: true, minWidth: 150, renderCell: (params) => <ExpandableCell_50 {...params} />, },
|
||||
|
@ -174,28 +191,37 @@ const DisplayPartnerSession = (props) => {
|
|||
{ field: 'date_fin', headerName: 'Fin', hideable: false, width: datagrid_columns_size_model2, },
|
||||
{
|
||||
field: 'distantiel', headerName: 'Distantiel', hideable: false, width: datagrid_columns_size_model2,
|
||||
valueFormatter: (params) => {
|
||||
if (String(params.value) === "0")
|
||||
return "Non";
|
||||
else if (String(params.value) === "1")
|
||||
return "Oui";
|
||||
else
|
||||
return "?";
|
||||
renderCell: (cellValues) => {
|
||||
return (
|
||||
|
||||
<div style={{ paddingLeft: "5px", paddingRight: "10px", "display": "block", wordBreak: "break-all" }}>
|
||||
{String(cellValues.row.distantiel) === "1" && "Oui"}
|
||||
{String(cellValues.row.distantiel) !== "1" && "Non"}
|
||||
|
||||
</div>
|
||||
|
||||
);
|
||||
},
|
||||
|
||||
},
|
||||
{
|
||||
field: 'presentiel', headerName: 'Presentiel', width: datagrid_columns_size_model2,
|
||||
valueFormatter: (params) => {
|
||||
if (String(params.value) === "0")
|
||||
return "Non";
|
||||
else if (String(params.value) === "1")
|
||||
return "Oui";
|
||||
else
|
||||
return "?";
|
||||
renderCell: (cellValues) => {
|
||||
return (
|
||||
|
||||
<div style={{ paddingLeft: "5px", paddingRight: "10px", "display": "block", wordBreak: "break-all" }}>
|
||||
{String(cellValues.row.presentiel) === "1" && "Oui"}
|
||||
{String(cellValues.row.presentiel) !== "1" && "Non"}
|
||||
|
||||
</div>
|
||||
|
||||
);
|
||||
},
|
||||
|
||||
|
||||
},
|
||||
{ field: 'formateur', headerName: 'Formateur', minWidth: datagrid_columns_size_model1, hide: true, hideable: true, renderCell: (params) => <ExpandableCell_50 {...params} />, },
|
||||
{ field: 'nb_participant', headerName: 'Nb Parti.', minWidth: datagrid_columns_size_model2, align: "center", hide: true, },
|
||||
{ field: 'nb_participant', headerName: 'Nb Parti.', minWidth: datagrid_columns_size_model2, align: "center", hide: true, renderCell: (params) => <ExpandableCell_50 {...params} />, },
|
||||
{
|
||||
field: 'taux_remplissage', headerName: 'Remplissage', align: "center", flex: 1, minWidth: 100, maxWidth: 150, flex: 1,
|
||||
align: "left",
|
||||
|
@ -218,12 +244,12 @@ const DisplayPartnerSession = (props) => {
|
|||
},
|
||||
{ field: 'nb_inscrit', headerName: 'Inscrits', minWidth: 20, align: "center", hide: true, hideable: true, },
|
||||
{ field: 'nb_preinscrit', headerName: 'Preinscrits', minWidth: 20, align: "center", hide: true, hideable: true, },
|
||||
{ field: 'prix_session', headerName: 'Prix', minWidth: 20, align: "center", },
|
||||
{ field: 'prix_session', headerName: 'Prix', minWidth: 20, align: "center", renderCell: (params) => <ExpandableCell_50 {...params} />, },
|
||||
{ field: 'title', headerName: 'Formation', minWidth: 250, flex: 1, align: "center", hide: true, hideable: true, renderCell: (params) => <ExpandableCell_50 {...params} />, },
|
||||
{ field: 'domaine', headerName: 'Domaine', minWidth: datagrid_columns_size_model1, align: "center", hide: true, hideable: true, },
|
||||
{ field: 'published', headerName: 'publié', minWidth: datagrid_columns_size_model1, align: "center", hide: true, hideable: true, },
|
||||
{ field: 'domaine', headerName: 'Domaine', minWidth: datagrid_columns_size_model1, align: "center", hide: true, hideable: true, renderCell: (params) => <ExpandableCell_50 {...params} />, },
|
||||
{ field: 'published', headerName: 'publié', minWidth: datagrid_columns_size_model1, align: "center", hide: true, hideable: true, renderCell: (params) => <ExpandableCell_50 {...params} />, },
|
||||
|
||||
{ field: 'duration', headerName: 'Durée', minWidth: datagrid_columns_size_model2, align: "center", hide: true, hideable: true, },
|
||||
{ field: 'duration', headerName: 'Durée', minWidth: datagrid_columns_size_model2, align: "center", hide: true, hideable: true, renderCell: (params) => <ExpandableCell_50 {...params} />, },
|
||||
{
|
||||
field: "Detail", headerName: 'Voir détail',
|
||||
renderCell: (cellValues) => {
|
||||
|
@ -724,6 +750,22 @@ const DisplayPartnerSession = (props) => {
|
|||
{ field: 'nom', headerName: 'nom', width: 150, hide: false, editable: true },
|
||||
{ field: 'prenom', headerName: 'prenom', width: 150, hide: false, editable: false },
|
||||
|
||||
{ field: 'statut', headerName: 'Statut', width: 150, hide: false, editable: false ,
|
||||
renderCell: (cellValues) => {
|
||||
return (
|
||||
|
||||
<div style={{ paddingLeft: "5px", paddingRight: "10px", "display": "block", wordBreak: "break-all" }}>
|
||||
{String(cellValues.row.statut) === "0" && "Init"}
|
||||
{String(cellValues.row.statut) === "1" && "Envoyé"}
|
||||
{String(cellValues.row.statut) === "2" && "Validé"}
|
||||
|
||||
</div>
|
||||
|
||||
);
|
||||
},
|
||||
},
|
||||
{ field: 'date_envoi', headerName: 'Envoyé le', width: 150, hide: false, editable: false },
|
||||
|
||||
{
|
||||
field: "valide", headerName: 'Valider',
|
||||
renderCell: (cellValues) => {
|
||||
|
@ -1609,6 +1651,12 @@ const DisplayPartnerSession = (props) => {
|
|||
document.getElementById("historique").style.fontWeight = "normal";
|
||||
}
|
||||
|
||||
if (document.getElementById("emargement")) {
|
||||
document.getElementById("emargement").style.backgroundColor = "#d8edfc";
|
||||
document.getElementById("emargement").style.color = "black";
|
||||
document.getElementById("emargement").style.fontWeight = "normal";
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
async function submenu_detail_session() {
|
||||
|
@ -1654,6 +1702,12 @@ const DisplayPartnerSession = (props) => {
|
|||
document.getElementById("historique").style.color = "black";
|
||||
document.getElementById("historique").style.fontWeight = "normal";
|
||||
}
|
||||
|
||||
if (document.getElementById("emargement")) {
|
||||
document.getElementById("emargement").style.backgroundColor = "#d8edfc";
|
||||
document.getElementById("emargement").style.color = "black";
|
||||
document.getElementById("emargement").style.fontWeight = "normal";
|
||||
}
|
||||
}
|
||||
|
||||
async function submenu_sequence_session() {
|
||||
|
@ -1701,6 +1755,12 @@ const DisplayPartnerSession = (props) => {
|
|||
document.getElementById("historique").style.fontWeight = "normal";
|
||||
}
|
||||
|
||||
|
||||
if (document.getElementById("emargement")) {
|
||||
document.getElementById("emargement").style.backgroundColor = "#d8edfc";
|
||||
document.getElementById("emargement").style.color = "black";
|
||||
document.getElementById("emargement").style.fontWeight = "normal";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
@ -1811,9 +1871,11 @@ const DisplayPartnerSession = (props) => {
|
|||
document.getElementById("preinscrit").style.fontWeight = "normal";
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
if (document.getElementById("emargement")) {
|
||||
document.getElementById("emargement").style.backgroundColor = "#d8edfc";
|
||||
document.getElementById("emargement").style.color = "black";
|
||||
document.getElementById("emargement").style.fontWeight = "normal";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
@ -1824,7 +1886,7 @@ const DisplayPartnerSession = (props) => {
|
|||
document.getElementById("editique").style.backgroundColor = "#104277";
|
||||
document.getElementById("editique").style.color = "white";
|
||||
document.getElementById("editique").style.fontWeight = "bold";
|
||||
console.log(" editique");
|
||||
|
||||
}
|
||||
|
||||
if (document.getElementById("inscrit")) {
|
||||
|
@ -1836,16 +1898,19 @@ const DisplayPartnerSession = (props) => {
|
|||
if (document.getElementById("detail_session")) {
|
||||
document.getElementById("detail_session").style.backgroundColor = "#d8edfc";
|
||||
document.getElementById("detail_session").style.color = "black";
|
||||
document.getElementById("detail_session").style.fontWeight = "normal";
|
||||
}
|
||||
|
||||
if (document.getElementById("preinscrit")) {
|
||||
document.getElementById("preinscrit").style.backgroundColor = "#d8edfc";
|
||||
document.getElementById("preinscrit").style.color = "black";
|
||||
document.getElementById("preinscrit").style.fontWeight = "normal";
|
||||
}
|
||||
|
||||
if (document.getElementById("sequence_session")) {
|
||||
document.getElementById("sequence_session").style.backgroundColor = "#d8edfc";
|
||||
document.getElementById("sequence_session").style.color = "black";
|
||||
document.getElementById("sequence_session").style.fontWeight = "normal";
|
||||
}
|
||||
|
||||
if (document.getElementById("historique")) {
|
||||
|
@ -1854,6 +1919,11 @@ const DisplayPartnerSession = (props) => {
|
|||
document.getElementById("historique").style.fontWeight = "normal";
|
||||
}
|
||||
|
||||
if (document.getElementById("emargement")) {
|
||||
document.getElementById("emargement").style.backgroundColor = "#d8edfc";
|
||||
document.getElementById("emargement").style.color = "black";
|
||||
document.getElementById("emargement").style.fontWeight = "normal";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
@ -2592,16 +2662,16 @@ const DisplayPartnerSession = (props) => {
|
|||
const New_civilite = [
|
||||
{ "id": "Mme", "label": "Mme", "value": "Mme" },
|
||||
{ "id": "M", "label": "M", "value": "M" },
|
||||
{ "id": "Neutre", "label": "Neutre", "value": "Neutre" },
|
||||
{ "id": "Neutre", "label": "Neutre", "value": "Neutre" },
|
||||
]
|
||||
|
||||
const New_type_apprenant = [
|
||||
|
||||
const New_type_apprenant = [
|
||||
{ "id": "0", "label": "Autre", "value": "0" },
|
||||
{ "id": "1", "label": "Salariés", "value": "1" },
|
||||
{ "id": "2", "label": "Apprentis", "value": "2" },
|
||||
{ "id": "3", "label": "Particuliers", "value": "3" },
|
||||
{ "id": "4", "label": "Rech. Emploi", "value": "4" },
|
||||
|
||||
{ "id": "2", "label": "Apprentis", "value": "2" },
|
||||
{ "id": "3", "label": "Particuliers", "value": "3" },
|
||||
{ "id": "4", "label": "Rech. Emploi", "value": "4" },
|
||||
|
||||
]
|
||||
|
||||
const [myinscript_status, setmyinscript_status] = useState("");
|
||||
|
@ -7743,6 +7813,7 @@ const DisplayPartnerSession = (props) => {
|
|||
} else {
|
||||
//console.log("erreur rrrr:" + data['status'])
|
||||
setGetListePreinscrit_emarg_api("false");
|
||||
alert(data['message']);
|
||||
|
||||
}
|
||||
|
||||
|
@ -7750,11 +7821,16 @@ const DisplayPartnerSession = (props) => {
|
|||
setLoading(false);
|
||||
console.error('Error:', error);
|
||||
setGetListePreinscrit_emarg_api("false");
|
||||
alert(" Impossible de récupérer les données d'émargement")
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
|
||||
const New_Option_Emargement_Masse = [
|
||||
{ "id": "demande emargement", "label": "Envoyer demande émargement", "value": "demande emargement" },
|
||||
]
|
||||
|
||||
const [actionmass_emarg_val, setactionmass_emarg_val] = useState();
|
||||
const actionmass_emarg = (event) => {
|
||||
const value = event.target.value;
|
||||
|
@ -7791,12 +7867,13 @@ const DisplayPartnerSession = (props) => {
|
|||
if (String(actionmass_emarg_val) === "demande emargement") {
|
||||
ActionMassListEmargement();
|
||||
}
|
||||
await sleep(50)
|
||||
await sleep(20)
|
||||
}
|
||||
setSelectionModel_emarg([]);
|
||||
setactionmass_emarg_val();
|
||||
|
||||
GetListeEmargement(selected_session_id, selected_internal_url);
|
||||
alert(" La demande d'émargement a été envoyée" );
|
||||
|
||||
}
|
||||
|
||||
|
@ -7807,7 +7884,7 @@ const DisplayPartnerSession = (props) => {
|
|||
|
||||
clean_old_messages();
|
||||
if (selectionModel_emarg.length <= 0) {
|
||||
alert(" Selectionnez un enregistrement pour envoyer la demande d'emargement");
|
||||
alert(" Sélectionnez un enregistrement pour envoyer la demande d'émargement");
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -7836,13 +7913,15 @@ const DisplayPartnerSession = (props) => {
|
|||
|
||||
setActionMassListEmargement_api("true");
|
||||
setActionMassListEmargement_result(res.data.message);
|
||||
|
||||
} else if (String(res.data.status) === String("Err_Connexion")) {
|
||||
alert('Erreur: ' + res.data.message);
|
||||
alert(res.data.message);
|
||||
history.push("/Connexion");
|
||||
}
|
||||
else {
|
||||
setActionMassListEmargement_api("false");
|
||||
setActionMassListEmargement_message(res.data.message);
|
||||
alert(res.data.message);
|
||||
|
||||
}
|
||||
|
||||
|
@ -8893,7 +8972,7 @@ const DisplayPartnerSession = (props) => {
|
|||
|
||||
}}
|
||||
|
||||
renderInput={(params) => <TextField {...params} label="" />
|
||||
renderInput={(params) => <TextField {...params} placeholder="Choisir une option " />
|
||||
}
|
||||
/>
|
||||
{/*<TextField
|
||||
|
@ -8937,7 +9016,7 @@ const DisplayPartnerSession = (props) => {
|
|||
}
|
||||
}}
|
||||
|
||||
renderInput={(params) => <TextField {...params} label="" />
|
||||
renderInput={(params) => <TextField {...params} placeholder="Choisir une option " />
|
||||
}
|
||||
/>
|
||||
|
||||
|
@ -8989,7 +9068,7 @@ const DisplayPartnerSession = (props) => {
|
|||
}
|
||||
}}
|
||||
|
||||
renderInput={(params) => <TextField {...params} label="" />
|
||||
renderInput={(params) => <TextField {...params} placeholder="Choisir une option " />
|
||||
}
|
||||
/>
|
||||
{/*<TextField
|
||||
|
@ -12249,7 +12328,7 @@ const DisplayPartnerSession = (props) => {
|
|||
|
||||
<div className="session_caract"> <b> Civilité </b><br />
|
||||
|
||||
<Autocomplete
|
||||
<Autocomplete
|
||||
disablePortal
|
||||
name="one_civilite_part"
|
||||
id="one_civilite_part"
|
||||
|
@ -12453,7 +12532,7 @@ const DisplayPartnerSession = (props) => {
|
|||
</div>
|
||||
|
||||
<div className="session_caract"> Type apprenant <br />
|
||||
<Autocomplete
|
||||
<Autocomplete
|
||||
disablePortal
|
||||
name="one_detail_type_apprenant"
|
||||
id="one_detail_type_apprenant"
|
||||
|
@ -12465,7 +12544,7 @@ const DisplayPartnerSession = (props) => {
|
|||
|
||||
}
|
||||
}}
|
||||
|
||||
|
||||
renderInput={(params) => <TextField {...params} label="" />
|
||||
}
|
||||
/>
|
||||
|
@ -12727,21 +12806,21 @@ const DisplayPartnerSession = (props) => {
|
|||
<h5> Ajout d'un nouveau participant</h5>
|
||||
|
||||
<div className="session_caract"> <b> Civilité </b><br />
|
||||
<Autocomplete
|
||||
disablePortal
|
||||
name="one_civilite_part"
|
||||
id="one_civilite_part"
|
||||
className="disabled_style enable_style"
|
||||
<Autocomplete
|
||||
disablePortal
|
||||
name="one_civilite_part"
|
||||
id="one_civilite_part"
|
||||
className="disabled_style enable_style"
|
||||
|
||||
options={New_civilite}
|
||||
onChange={(event, value) => {
|
||||
if (value && value.value) {
|
||||
setp_one_civilite_part(value.value);
|
||||
options={New_civilite}
|
||||
onChange={(event, value) => {
|
||||
if (value && value.value) {
|
||||
setp_one_civilite_part(value.value);
|
||||
}
|
||||
}}
|
||||
renderInput={(params) => <TextField {...params} label="" />
|
||||
}
|
||||
}}
|
||||
renderInput={(params) => <TextField {...params} label="" />
|
||||
}
|
||||
/>
|
||||
/>
|
||||
|
||||
{/*<TextField
|
||||
required
|
||||
|
@ -12950,7 +13029,7 @@ const DisplayPartnerSession = (props) => {
|
|||
|
||||
<div className="session_caract"> <b> Civilité </b><br />
|
||||
|
||||
<Autocomplete
|
||||
<Autocomplete
|
||||
disablePortal
|
||||
name="one_status_part"
|
||||
id="one_civilite_part"
|
||||
|
@ -13091,7 +13170,7 @@ const DisplayPartnerSession = (props) => {
|
|||
</div>
|
||||
|
||||
<div className="session_caract"> Statut Inscription <br />
|
||||
<Autocomplete
|
||||
<Autocomplete
|
||||
disablePortal
|
||||
name="one_status_part"
|
||||
id="one_status_part"
|
||||
|
@ -13101,14 +13180,14 @@ const DisplayPartnerSession = (props) => {
|
|||
onChange={(event, value) => {
|
||||
if (value && value.value) {
|
||||
setmyinscript_status(value.value);
|
||||
|
||||
|
||||
}
|
||||
}}
|
||||
renderInput={(params) => <TextField {...params} label="" />
|
||||
}
|
||||
/>
|
||||
|
||||
{/*<TextField
|
||||
{/*<TextField
|
||||
sx={{ '& legend': { display: 'none' }, '& fieldset': { top: 0 }, }}
|
||||
required
|
||||
select
|
||||
|
@ -13153,7 +13232,7 @@ const DisplayPartnerSession = (props) => {
|
|||
</div>
|
||||
|
||||
<div className="session_caract"> Type apprenant <br />
|
||||
<Autocomplete
|
||||
<Autocomplete
|
||||
disablePortal
|
||||
name="one_detail_type_apprenant"
|
||||
id="one_detail_type_apprenant"
|
||||
|
@ -13162,16 +13241,16 @@ const DisplayPartnerSession = (props) => {
|
|||
onChange={(event, value) => {
|
||||
if (value && value._id) {
|
||||
setp_one_detail_type_apprenant(value._id);
|
||||
|
||||
|
||||
|
||||
}
|
||||
}}
|
||||
|
||||
|
||||
renderInput={(params) => <TextField {...params} label="" />
|
||||
}
|
||||
/>
|
||||
|
||||
|
||||
|
||||
{/*<TextField
|
||||
sx={{ '& legend': { display: 'none' }, '& fieldset': { top: 0 }, }}
|
||||
required
|
||||
|
@ -14379,12 +14458,64 @@ const DisplayPartnerSession = (props) => {
|
|||
{String(submenu) === String("emargement") && <div style={{ "border": "None" }}>
|
||||
|
||||
<div className="div_row" style={{ "textAlign": "right", "marginTop": "0.5rem" }}>
|
||||
<Button className="bton_emarge" onClick={ConfirmInitListEmargement}>Initialiser la liste émargement</Button>
|
||||
<Button className="bton_emarge" onClick={DownloadListEmargement}>Imprimer la liste émargement</Button>
|
||||
<Button className="bton_emarge" onClick={ConfirmEnvoiListEmargement}>Envoyer les demandes d'émargement</Button><br />
|
||||
|
||||
<Popup
|
||||
trigger={
|
||||
<Button className="bton_emarge">Initialiser la liste</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">
|
||||
{' '}
|
||||
|
||||
|
||||
<font> Confirmez la (ré)initialisation de la liste d'émargement. <br />
|
||||
<font color="red"> /!\ Si un tableau d'émargement existe pour cette session, il sera supprimé et récréé </font>
|
||||
</font>
|
||||
|
||||
|
||||
</div>
|
||||
<div className="gest_actions">
|
||||
<div style={{ "width": "45%", "float": "left" }}>
|
||||
<button className="gest_bton_popup" onClick={(event) => {
|
||||
CreateListEmargement();
|
||||
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>
|
||||
|
||||
|
||||
<Button className="bton_emarge" onClick={DownloadListEmargement}>Imprimer la liste</Button>
|
||||
<Button className="bton_emarge" onClick={ConfirmEnvoiListEmargement}>Envoyer demandes émargement</Button><br />
|
||||
</div>
|
||||
|
||||
<div className="session_data" style={{ height: 500, width: '100%' }}>
|
||||
|
||||
<DataGrid
|
||||
checkboxSelection
|
||||
onSelectionModelChange={(newSelectionModel_emarg) => {
|
||||
|
@ -14410,7 +14541,8 @@ const DisplayPartnerSession = (props) => {
|
|||
sequence_end: JSON.parse(item).sequence_end,
|
||||
is_present: JSON.parse(item).is_present,
|
||||
|
||||
|
||||
statut: JSON.parse(item).statut,
|
||||
date_envoi: JSON.parse(item).date_envoi,
|
||||
}
|
||||
))}
|
||||
|
||||
|
@ -14426,71 +14558,100 @@ const DisplayPartnerSession = (props) => {
|
|||
|
||||
|
||||
/>
|
||||
{selectionModel_emarg && selectionModel_emarg.length >= 1 &&
|
||||
<div className="block_en_mass">
|
||||
<nav className='traitement_mass'>Traitement en masse / Emarge</nav>
|
||||
<select
|
||||
<div className="div_row"> </div>
|
||||
<div className="div_row">
|
||||
{selectionModel_emarg && selectionModel_emarg.length >= 1 &&
|
||||
<div className="block_en_mass">
|
||||
<nav >Traitement en masse </nav><br />
|
||||
|
||||
<Autocomplete
|
||||
disablePortal
|
||||
id="combo-box-demo"
|
||||
className="block_en_mass_select"
|
||||
fullWidth
|
||||
options={New_Option_Emargement_Masse}
|
||||
onChange={(event, value) => {
|
||||
if (value && value.value) {
|
||||
if (String(value.value) === "demande emargement") {
|
||||
|
||||
setactionmass_emarg_val(value.value);
|
||||
|
||||
}
|
||||
else {
|
||||
setactionmass_emarg_val("");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}}
|
||||
|
||||
renderInput={(params) => <TextField {...params} placeholder="Choisir une option" />
|
||||
}
|
||||
/>
|
||||
|
||||
{/*<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>
|
||||
</select>*/}
|
||||
|
||||
{actionmass_emarg_val &&
|
||||
<Popup
|
||||
trigger={<Button className="bton_traiter_en_mass" >
|
||||
<FcAcceptDatabase /> Traiter
|
||||
{actionmass_emarg_val &&
|
||||
<Popup
|
||||
trigger={<Button className="bton_enreg" >
|
||||
<FcAcceptDatabase /> Traiter
|
||||
|
||||
</Button>}
|
||||
modal
|
||||
nested
|
||||
position="center center"
|
||||
>
|
||||
</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>
|
||||
{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 style={{ "width": "45%", "float": "right" }}>
|
||||
<button
|
||||
className="gest_bton_popup"
|
||||
onClick={() => {
|
||||
//console.log('modal closed ');
|
||||
<div className="gest_actions">
|
||||
<div style={{ "width": "45%", "float": "left" }}>
|
||||
<button className="gest_bton_popup" onClick={(event) => {
|
||||
actionmass_emarge_Traitemet();
|
||||
close();
|
||||
}}
|
||||
>
|
||||
Annuler
|
||||
</button>
|
||||
}}> 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>
|
||||
</div>
|
||||
)}
|
||||
</Popup>
|
||||
}
|
||||
<br />
|
||||
)}
|
||||
</Popup>
|
||||
}
|
||||
<br />
|
||||
|
||||
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
|
||||
<br />
|
||||
<br />
|
||||
</div>
|
||||
{/*<Button className="bton_emarge" onClick={ActionMassListEmargement}>Envoyer les demandes d'emargement</Button><br />
|
||||
*/}
|
||||
|
||||
|
|
|
@ -376,25 +376,25 @@ const DistplayPartnerTraningsPage = (props) => {
|
|||
{ field: 'presentiel', headerName: 'Présentiel', hide: true, Width: 0, },
|
||||
{ field: 'distanciel', headerName: 'Distanciel', hide: true, Width: 0, },
|
||||
{ field: 'cible', headerName: 'Cible', hide: true, Width: 0, },
|
||||
{ field: 'duration_unit', headerName: 'duration_unit', hide: true, Width: 0,editable: false, },
|
||||
{ field: 'duration_in_hour', headerName: 'duration_in_hour', hide: true, Width: 0,editable: false, },
|
||||
{ field: 'duration_unit', headerName: 'duration_unit', hide: true, Width: 0, editable: false, },
|
||||
{ field: 'duration_in_hour', headerName: 'duration_in_hour', hide: true, Width: 0, editable: false, },
|
||||
{ field: 'currency', headerName: 'currency', hide: true, Width: 0, editable: false, },
|
||||
|
||||
|
||||
{ field: 'zone_diffusion', headerName: 'zone_diffusion', hide: true, maxWidth: 1, editable: false, },
|
||||
{ field: 'internal_url', headerName: 'internal_url', hide: true, editable: false, },
|
||||
{ field: 'internal_url', headerName: 'internal_url', hide: true, editable: false, },
|
||||
{ field: 'external_code', headerName: 'Code Formation', hideable: false, minWidth: 150, flex: 1, maxWidth: 250, editable: false, renderCell: (params) => <ExpandableCell_50 {...params} />, },
|
||||
{ field: 'title', headerName: 'Titre', hideable: false, minWidth: 300, flex: 1, editable: false, renderCell: (params) => <ExpandableCell_50 {...params} />, },
|
||||
{ field: 'title', headerName: 'Titre', hideable: false, minWidth: 300, flex: 1, editable: false, renderCell: (params) => <ExpandableCell_50 {...params} />, },
|
||||
{ field: 'domain', headerName: 'Domaine', minWidth: 50, flex: 1, maxWidth: 150, hideable: true, editable: false, },
|
||||
{ field: 'metier', headerName: 'Métier', minWidth: 50, flex: 1, maxWidth: 150, hideable: true, hide: true, editable: false, },
|
||||
{ field: 'nb_session_formation', headerName: 'Nb Session', minWidth: 50, flex: 1, maxWidth: 100, hideable: true, hide: false , editable: false, align: "center",},
|
||||
{ field: 'url', headerName: 'lien', minWidth: 20, hideable: true, hide: true, editable: false, },
|
||||
{ field: 'metier', headerName: 'Métier', minWidth: 50, flex: 1, maxWidth: 150, hideable: true, hide: true, editable: false, },
|
||||
{ field: 'nb_session_formation', headerName: 'Nb Session', minWidth: 50, flex: 1, maxWidth: 100, hideable: true, hide: false, editable: false, align: "center", },
|
||||
{ field: 'url', headerName: 'lien', minWidth: 20, hideable: true, hide: true, editable: false, },
|
||||
{ field: 'description', headerName: 'Description', hide: true, resizable: true, minWidth: 250, maxWidth: 300, flex: 1, renderCell: (params) => <ExpandableCell_50 {...params} />, },
|
||||
|
||||
{ field: 'price', headerName: 'Prix', minWidth: 50, flex: 1, maxWidth: 100, align: "center", resizable: true, hide: ismobilephone_columns_hide, editable: false, },
|
||||
{ field: 'price', headerName: 'Prix', minWidth: 50, flex: 1, maxWidth: 100, align: "center", resizable: true, hide: ismobilephone_columns_hide, editable: false, },
|
||||
{
|
||||
field: 'published', headerName: 'Publié', minWidth: 50, flex: 1, maxWidth: 100, align: "center", resizable: true, editable: false,
|
||||
valueFormatter: (params) => {
|
||||
field: 'published', headerName: 'Publié', minWidth: 50, flex: 1, maxWidth: 100, align: "center", resizable: true, editable: false,
|
||||
valueFormatter: (params) => {
|
||||
if (String(params.value) === "0")
|
||||
return "Non";
|
||||
else if (String(params.value) === "1")
|
||||
|
@ -404,7 +404,7 @@ const DistplayPartnerTraningsPage = (props) => {
|
|||
},
|
||||
},
|
||||
{
|
||||
field: "management", headerName: 'Gestion', minWidth: 50, flex: 1, maxWidth: 100,
|
||||
field: "management", headerName: 'Gestion', minWidth: 50, flex: 1, maxWidth: 100,
|
||||
renderCell: (cellValues) => {
|
||||
return (
|
||||
|
||||
|
@ -1266,7 +1266,7 @@ const DistplayPartnerTraningsPage = (props) => {
|
|||
},
|
||||
"& .MuiDataGrid-cellContent": {
|
||||
minHeight: 50,
|
||||
|
||||
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -1953,7 +1953,7 @@ const DistplayPartnerTraningsPage = (props) => {
|
|||
components={{
|
||||
Toolbar: GridToolbar,
|
||||
}}
|
||||
|
||||
|
||||
getCellClassName={(params) => {
|
||||
if (params.field === 'published' && String(params.value) === "1") {
|
||||
return 'cell--published';
|
||||
|
@ -1983,7 +1983,7 @@ const DistplayPartnerTraningsPage = (props) => {
|
|||
getEstimatedRowHeight={() => 200}
|
||||
getRowHeight={() => "auto"}
|
||||
sx={datagridSx}
|
||||
|
||||
|
||||
|
||||
/>
|
||||
</Box>
|
||||
|
@ -1993,8 +1993,10 @@ const DistplayPartnerTraningsPage = (props) => {
|
|||
<div className="div_row">
|
||||
{selectionModel && selectionModel.length >= 1 && <div className="block_en_mass">
|
||||
<nav >Traitement en masse </nav>
|
||||
|
||||
<br />
|
||||
|
||||
<Autocomplete
|
||||
//sx={{ '& legend': { display: 'none' }, '& fieldset': { top: 0 } }}
|
||||
disablePortal
|
||||
id="combo-box-demo"
|
||||
className="block_en_mass_select"
|
||||
|
@ -2010,12 +2012,10 @@ const DistplayPartnerTraningsPage = (props) => {
|
|||
else {
|
||||
setactionmass_ftion_val();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}}
|
||||
|
||||
renderInput={(params) => <TextField {...params} label="" />
|
||||
hiddenLabel="true"
|
||||
renderInput={(params) => <TextField {...params} placeholder="Choisir une option " variant="outlined" />
|
||||
}
|
||||
/>
|
||||
|
||||
|
|
|
@ -49,6 +49,7 @@ import allLocales from '@fullcalendar/core/locales-all'
|
|||
import { RepeatOnRounded } from "@mui/icons-material";
|
||||
import { alignPropType } from "react-bootstrap/esm/types";
|
||||
|
||||
|
||||
import ToggleSwitch from "./ToggleSwitch";
|
||||
import ToggleSwitch_v2_mysy from "./ToggleSwitch_v2_mysy";
|
||||
import Autocomplete from '@mui/material/Autocomplete';
|
||||
|
@ -275,7 +276,7 @@ const Module_Editique = (props) => {
|
|||
|
||||
var nom_fichier_cmd = "Convention.zip";
|
||||
|
||||
if( String(selected_convention_id).trim() === ""){
|
||||
if (String(selected_convention_id).trim() === "") {
|
||||
alert(" Vous devez choisir un modèle de document ");
|
||||
return;
|
||||
}
|
||||
|
@ -320,7 +321,7 @@ const Module_Editique = (props) => {
|
|||
|
||||
var nom_fichier_cmd = "Convocation.zip";
|
||||
|
||||
if( String(selected_convention_id).trim() === ""){
|
||||
if (String(selected_convention_id).trim() === "") {
|
||||
alert(" Vous devez choisir un modèle de document ");
|
||||
return;
|
||||
}
|
||||
|
@ -334,8 +335,8 @@ const Module_Editique = (props) => {
|
|||
|
||||
}
|
||||
|
||||
console.log(" ### url = ", url);
|
||||
|
||||
console.log(" ### url = ", url);
|
||||
|
||||
//console.log(" nom_fichier_cmd = ", nom_fichier_cmd, " --- selected_session_id = ", selected_session_id, " --- selected_convention_id =", selected_convention_id);
|
||||
setLoading(true);
|
||||
axios.get(url, { responseType: 'blob', },)
|
||||
|
@ -847,7 +848,7 @@ const Module_Editique = (props) => {
|
|||
var myurl = process.env.REACT_APP_API_URL + "myclass/api/Prepare_and_Send_Convocation_From_Session_By_Email/";
|
||||
if (String(selected_convention_id) === "default_mail") {
|
||||
// Il s'agit d'envoyer les convention par defaut de type mail
|
||||
myurl = process.env.REACT_APP_API_URL + "myclass/api/Prepare_and_Send_Default_Convocation_From_Session_By_Email/";
|
||||
myurl = process.env.REACT_APP_API_URL + "myclass/api/Prepare_and_Send_Default_Convocation_From_Session_By_Email/";
|
||||
}
|
||||
|
||||
//console.log(" ### myurl = ", myurl);
|
||||
|
@ -919,6 +920,11 @@ const Module_Editique = (props) => {
|
|||
};
|
||||
|
||||
|
||||
const New_Option_Type_Document = [
|
||||
{ "id": "email", "label": "Email", "value": "email" },
|
||||
{ "id": "pdf", "label": "PDF", "value": "pdf" },
|
||||
]
|
||||
|
||||
return (
|
||||
|
||||
<div className="module_editique">
|
||||
|
@ -1070,7 +1076,28 @@ const Module_Editique = (props) => {
|
|||
|
||||
|
||||
<div className="session_caract_Dialog" > Type Document<br />
|
||||
<TextField
|
||||
|
||||
<Autocomplete
|
||||
disablePortal
|
||||
sx={{ '& legend': { display: 'none' }, '& fieldset': { top: 0 } }}
|
||||
|
||||
name="event_dialog_type_convention"
|
||||
id="event_dialog_type_convention"
|
||||
fullWidth
|
||||
options={New_Option_Type_Document}
|
||||
onChange={(event, value) => {
|
||||
if (value && value.value) {
|
||||
setselected_convention_type(value.value);
|
||||
Get_List_Stagiaire_Convocations(action_server_ref_interne_doc, action_server_nom_doc,
|
||||
String(value.value), Dialog_1_message);
|
||||
|
||||
}
|
||||
}}
|
||||
renderInput={(params) => <TextField {...params} label="" />
|
||||
}
|
||||
/>
|
||||
|
||||
{/*<TextField
|
||||
sx={{ '& legend': { display: 'none' }, '& fieldset': { top: 0 } }}
|
||||
|
||||
name="event_dialog_type_convention"
|
||||
|
@ -1091,7 +1118,7 @@ const Module_Editique = (props) => {
|
|||
|
||||
<MenuItem value="email" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Email </MenuItem>
|
||||
<MenuItem value="pdf" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >PDF </MenuItem>
|
||||
</TextField>
|
||||
</TextField>*/}
|
||||
|
||||
</div>
|
||||
|
||||
|
@ -1168,8 +1195,6 @@ const Module_Editique = (props) => {
|
|||
|
||||
value="pdf"
|
||||
fullWidth
|
||||
|
||||
|
||||
/>
|
||||
|
||||
|
||||
|
@ -1377,7 +1402,26 @@ const Module_Editique = (props) => {
|
|||
</DialogContentText>
|
||||
|
||||
<div className="session_caract_Dialog" > Type Document<br />
|
||||
<TextField
|
||||
<Autocomplete
|
||||
disablePortal
|
||||
name="event_dialog_type_convention"
|
||||
id="event_dialog_type_convention"
|
||||
sx={{ '& legend': { display: 'none' }, '& fieldset': { top: 0 } }}
|
||||
fullWidth
|
||||
options={New_Option_Type_Document}
|
||||
onChange={(event, value) => {
|
||||
if (value && value.value) {
|
||||
setselected_convention_type(value.value);
|
||||
|
||||
Get_List_Stagiaire_Conventions(action_server_ref_interne_doc, action_server_nom_doc,
|
||||
String(value.value), Dialog_1_message);
|
||||
}
|
||||
}}
|
||||
renderInput={(params) => <TextField {...params} label="" />
|
||||
}
|
||||
/>
|
||||
|
||||
{/*<TextField
|
||||
sx={{ '& legend': { display: 'none' }, '& fieldset': { top: 0 } }}
|
||||
|
||||
name="event_dialog_type_convention"
|
||||
|
@ -1398,7 +1442,7 @@ const Module_Editique = (props) => {
|
|||
|
||||
<MenuItem value="email" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Email </MenuItem>
|
||||
<MenuItem value="pdf" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >PDF </MenuItem>
|
||||
</TextField>
|
||||
</TextField>*/}
|
||||
|
||||
</div>
|
||||
|
||||
|
@ -1468,6 +1512,8 @@ const Module_Editique = (props) => {
|
|||
</div>}
|
||||
|
||||
{String(selected_convention_type) === "pdf" && <div className="session_caract_Dialog" > Type Document<br />
|
||||
|
||||
|
||||
<TextField
|
||||
sx={{ '& legend': { display: 'none' }, '& fieldset': { top: 0 } }}
|
||||
|
||||
|
@ -1476,12 +1522,8 @@ const Module_Editique = (props) => {
|
|||
|
||||
value="pdf"
|
||||
fullWidth
|
||||
|
||||
|
||||
/>
|
||||
|
||||
|
||||
|
||||
</div>}
|
||||
|
||||
|
||||
|
@ -1749,7 +1791,7 @@ const Module_Editique = (props) => {
|
|||
minHeight: 270, flexGrow: 1,
|
||||
boxShadow: 1,
|
||||
borderRadius: 2,
|
||||
bgcolor: "yellowgreen"
|
||||
bgcolor: "#DAF7A6",
|
||||
}}>
|
||||
|
||||
|
||||
|
@ -1773,12 +1815,25 @@ const Module_Editique = (props) => {
|
|||
|
||||
{JSON.parse(document).list_document_history_event &&
|
||||
JSON.parse(document).list_document_history_event.map((history_doc) => (
|
||||
<nav>
|
||||
{String(history_doc.local_target_collection_name).trim() === "" &&
|
||||
<TreeItem className="test02" nodeId={history_doc._id}
|
||||
sx={{ color: 'darkslateblue', fontWeight: 'light', fontStyle: 'italic', mt: '10px' }}
|
||||
label={(String(history_doc.date_update).substring(0, 16) + " Par " + String(history_doc.local_update_by_email))}
|
||||
icon={<FcInfo />}
|
||||
/>}
|
||||
|
||||
<TreeItem className="test02" nodeId={history_doc._id}
|
||||
label={(String(history_doc.date_update).substring(0, 16) + " Par " + String(history_doc.local_update_by_email))} />
|
||||
{String(history_doc.local_target_collection_name).trim() !== "" &&
|
||||
<TreeItem className="test02" nodeId={history_doc._id}
|
||||
label={(String(history_doc.date_update).substring(0, 16) + " Par " + String(history_doc.local_update_by_email) + ". " + String(history_doc.local_target_collection) + " Pour " + String(history_doc.local_target_collection_name))}
|
||||
sx={{ color: 'darkslateblue', fontWeight: 'light', fontStyle: 'italic', mt: '10px' }}
|
||||
icon={<FcInfo />} />
|
||||
}
|
||||
</nav>
|
||||
|
||||
))}
|
||||
|
||||
|
||||
{/*!JSON.parse(document).list_document_history_event || (JSON.parse(document).list_document_history_event).length <= 0 &&
|
||||
<TreeItem nodeId={"0"} label="Aucun"
|
||||
className="test02" />*/}
|
||||
|
|
|
@ -607,7 +607,7 @@ const TestUrl_New = (props) => {
|
|||
<br />
|
||||
|
||||
<h2> Module Ediditique </h2>
|
||||
<Module_Editique conntected_employee_id={"1234"} related_collection={"session_formation"} related_collection_recid={"65224c1c7e5ee82f3a74afc6"}/>
|
||||
<Module_Editique conntected_employee_id={"1234"} related_collection={"session_formation"} related_collection_recid={"65b378562f89e592bf0e4b78"}/>
|
||||
|
||||
<Button variant="contained" className="bton_enreg"
|
||||
onClick={afficher_champs_spec}>
|
||||
|
|
|
@ -2251,11 +2251,22 @@
|
|||
|
||||
.bton_emarge {
|
||||
border-radius: 5rem;
|
||||
font-size: small;
|
||||
font-size: 11px;
|
||||
padding: 0.5rem;
|
||||
background: rgb(129, 188, 58);
|
||||
margin-left: 5px;
|
||||
margin-right: 5px;
|
||||
color: white;
|
||||
}
|
||||
|
||||
.bton_emarge:hover {
|
||||
border-radius: 5rem;
|
||||
font-size: 11px;
|
||||
padding: 0.5rem;
|
||||
background: rgb(129, 188, 58);
|
||||
margin-left: 5px;
|
||||
margin-right: 5px;
|
||||
color: white;
|
||||
}
|
||||
|
||||
.css-1x5jdm {
|
||||
|
|
Loading…
Reference in New Issue