13/07/2024 - 22h
parent
60adb494f9
commit
377297cf18
|
@ -3637,7 +3637,7 @@ const AddClassManual = (props) => {
|
|||
|
||||
const otherSetting = {
|
||||
height: 300,
|
||||
yAxis: [{ label: 'rainfall (mm)' }],
|
||||
yAxis: [{ label: '' }],
|
||||
grid: { horizontal: true },
|
||||
sx: {
|
||||
[`& .${axisClasses.left} .${axisClasses.label}`]: {
|
||||
|
|
|
@ -32,7 +32,7 @@ import { IoCloseCircleOutline } from "react-icons/io5";
|
|||
import AttachFileIcon from '@mui/icons-material/AttachFile';
|
||||
import Radio from '@mui/material/Radio';
|
||||
|
||||
|
||||
import WarningAmberIcon from '@mui/icons-material/WarningAmber';
|
||||
const AddParnerClient = (props) => {
|
||||
const history = useHistory();
|
||||
const [submenu, setsubmenu] = useState("");
|
||||
|
@ -653,6 +653,10 @@ const AddParnerClient = (props) => {
|
|||
}, [props.client_mail,]);
|
||||
|
||||
|
||||
|
||||
const [has_client_invoice_email, sethas_client_invoice_email] = useState();
|
||||
|
||||
|
||||
const [fillfield_api, setfillfield_api] = useState("");
|
||||
const [fillfield_result, setfillfield_result] = useState("");
|
||||
const [fillfield_message, setfillfield_message] = useState("");
|
||||
|
@ -772,8 +776,10 @@ const AddParnerClient = (props) => {
|
|||
// Remplissage des doonées de facturation
|
||||
if (mylocalclient.invoice_email)
|
||||
setclient_invoice_email(mylocalclient.invoice_email);
|
||||
else
|
||||
else{
|
||||
setclient_invoice_email("");
|
||||
sethas_client_invoice_email("0");
|
||||
}
|
||||
|
||||
if (mylocalclient.invoice_nom)
|
||||
setclient_invoice_nom(mylocalclient.invoice_nom);
|
||||
|
@ -798,8 +804,10 @@ const AddParnerClient = (props) => {
|
|||
|
||||
if (mylocalclient.invoice_condition_paiement_id)
|
||||
setp_client_invoice_paiement_condition_id(mylocalclient.invoice_condition_paiement_id);
|
||||
else
|
||||
else{
|
||||
setp_client_invoice_paiement_condition_id("");
|
||||
sethas_client_invoice_email("0");
|
||||
}
|
||||
|
||||
if (mylocalclient.invoice_condition_paiement_code)
|
||||
setp_client_invoice_paiement_condition_code(mylocalclient.invoice_condition_paiement_code);
|
||||
|
@ -1059,6 +1067,8 @@ const AddParnerClient = (props) => {
|
|||
}
|
||||
|
||||
|
||||
const [client_has_communication_contact, setclient_has_communication_contact] = useState();
|
||||
|
||||
const [Get_List_Contact_Of_client_Part_api, setGet_List_Contact_Of_client_Part_api] = useState();
|
||||
const [Get_List_Contact_Of_client_Part_message, setGet_List_Contact_Of_client_Part_message] = useState();
|
||||
const [Get_List_Contact_Of_client_Part_result, setGet_List_Contact_Of_client_Part_result] = useState();
|
||||
|
@ -1084,6 +1094,18 @@ const AddParnerClient = (props) => {
|
|||
setGet_List_Contact_Of_client_Part_api("true");
|
||||
setGet_List_Contact_Of_client_Part_result(res.data.message);
|
||||
|
||||
var contact_com = "0";
|
||||
|
||||
const new_data = res.data.message.map((x) => {
|
||||
|
||||
//---
|
||||
var include_com = JSON.parse(x).include_com;
|
||||
if (String(include_com) === "1") {
|
||||
contact_com = "1"
|
||||
}
|
||||
});
|
||||
|
||||
setclient_has_communication_contact(contact_com);
|
||||
}
|
||||
else if (String(res.data.status) === String("Err_Connexion")) {
|
||||
alert('Erreur: ' + res.data.message);
|
||||
|
@ -1792,56 +1814,60 @@ const AddParnerClient = (props) => {
|
|||
form.append("nom", p_client_nom);
|
||||
|
||||
// Données de facturation
|
||||
var client_invoice_email = ""
|
||||
if (document.getElementsByName("client_invoice_email")) {
|
||||
client_invoice_email = document.getElementsByName("client_invoice_email")[0].value;
|
||||
var client_invoice_email = p_client_invoice_email
|
||||
|
||||
var validRegex = /^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9-]+(?:\.[a-zA-Z0-9-]+)*$/;
|
||||
|
||||
if (String(client_invoice_email) === "" || !client_invoice_email.match(validRegex) ) {
|
||||
alert("L'adresse email de facturation est invalide.");
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
if( String(p_client_invoice_paiement_condition_id).trim() === ""){
|
||||
alert(" Vous devez choisir une condition de paiement");
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
form.append("invoice_email", client_invoice_email);
|
||||
|
||||
var client_invoice_nom = ""
|
||||
if (document.getElementsByName("client_invoice_nom")) {
|
||||
client_invoice_nom = document.getElementsByName("client_invoice_nom")[0].value;
|
||||
}
|
||||
var client_invoice_nom = p_client_invoice_nom;
|
||||
|
||||
form.append("invoice_nom", client_invoice_nom);
|
||||
|
||||
var client_invoice_siret = ""
|
||||
if (document.getElementsByName("client_invoice_siret")) {
|
||||
client_invoice_siret = document.getElementsByName("client_invoice_siret")[0].value;
|
||||
}
|
||||
var client_invoice_siret = p_client_invoice_siret;
|
||||
|
||||
|
||||
form.append("invoice_siret", client_invoice_siret);
|
||||
|
||||
var client_invoice_tva = ""
|
||||
if (document.getElementsByName("client_invoice_tva")) {
|
||||
client_invoice_tva = document.getElementsByName("client_invoice_tva")[0].value;
|
||||
}
|
||||
var client_invoice_tva = p_client_invoice_tva;
|
||||
|
||||
|
||||
form.append("invoice_tva", client_invoice_tva);
|
||||
|
||||
form.append("invoice_condition_paiement_id", p_client_invoice_paiement_condition_id);
|
||||
|
||||
|
||||
var client_invoice_adresse = ""
|
||||
if (document.getElementsByName("client_invoice_adresse")) {
|
||||
client_invoice_adresse = document.getElementsByName("client_invoice_adresse")[0].value;
|
||||
}
|
||||
|
||||
var client_invoice_adresse = p_client_invoice_adresse;
|
||||
|
||||
|
||||
form.append("invoice_adresse", client_invoice_adresse);
|
||||
|
||||
var client_invoice_ville = ""
|
||||
if (document.getElementsByName("client_invoice_ville")) {
|
||||
client_invoice_ville = document.getElementsByName("client_invoice_ville")[0].value;
|
||||
}
|
||||
var client_invoice_ville = p_client_invoice_ville;
|
||||
|
||||
form.append("invoice_ville", client_invoice_ville);
|
||||
|
||||
var client_invoice_code_postal = ""
|
||||
if (document.getElementsByName("client_invoice_email")) {
|
||||
client_invoice_code_postal = document.getElementsByName("client_invoice_code_postal")[0].value;
|
||||
}
|
||||
var client_invoice_code_postal = p_client_invoice_code_postal;
|
||||
|
||||
|
||||
form.append("invoice_code_postal", client_invoice_code_postal);
|
||||
|
||||
|
||||
var client_invoice_pays = ""
|
||||
if (document.getElementsByName("client_invoice_pays")) {
|
||||
client_invoice_pays = document.getElementsByName("client_invoice_pays")[0].value;
|
||||
}
|
||||
var client_invoice_pays = p_client_invoice_pays;
|
||||
|
||||
|
||||
form.append("invoice_pays", client_invoice_pays);
|
||||
|
||||
|
||||
|
@ -1862,6 +1888,7 @@ const AddParnerClient = (props) => {
|
|||
setdatamodification_invoice("0");
|
||||
alert(" Les données de facturation ont été mises à jour.")
|
||||
Disable_invoice_fields();
|
||||
sethas_client_invoice_email("");
|
||||
alert(res.data.message);
|
||||
|
||||
|
||||
|
@ -2234,6 +2261,7 @@ const AddParnerClient = (props) => {
|
|||
var include_com = "0"
|
||||
if (is_contact_include_com) {
|
||||
include_com = "1";
|
||||
setclient_has_communication_contact("");
|
||||
}
|
||||
form.append("include_com", include_com);
|
||||
|
||||
|
@ -2510,14 +2538,9 @@ const AddParnerClient = (props) => {
|
|||
const [is_contact_include_com, setis_contact_include_com] = useState(false);
|
||||
|
||||
const New_civilite = [
|
||||
{ "id": "Mme", "label": "Mme", "value": "Mme" },
|
||||
{ "id": "M", "label": "M", "value": "M" },
|
||||
{ "id": "Neutre", "label": "Neutre", "value": "Neutre" },
|
||||
|
||||
{ "id": "mme", "label": "Mme", "value": "mme" },
|
||||
{ "id": "m", "label": "M", "value": "m" },
|
||||
{ "id": "neutre", "label": "Neutre", "value": "neutre" },
|
||||
|
||||
{ "id": "", "label": "", "value": "" },
|
||||
]
|
||||
|
||||
|
@ -3266,13 +3289,31 @@ const AddParnerClient = (props) => {
|
|||
|
||||
{String(props.new_customer) !== "1" && <div className="div_row">
|
||||
<div className="div_row">
|
||||
|
||||
<Button variant="outlined" onClick={submenu_donnee_client} className="detail_submenu client_menu" id='submenu_donnee_client' name='submenu_donnee_client'>Données Principales</Button>
|
||||
<Button variant="outlined" onClick={submenu_donnee_facturation} className="detail_submenu client_menu" id='submenu_donnee_facturation' name='submenu_donnee_facturation'>Données Facturation</Button>
|
||||
<Button variant="outlined" onClick={submenu_contact} className="detail_submenu client_menu" id='submenu_contact' name='submenu_contact'>Contact & Adresses</Button>
|
||||
<Button variant="outlined" onClick={submenu_donnee_facturation} className="detail_submenu client_menu" id='submenu_donnee_facturation' name='submenu_donnee_facturation'>Données Facturation
|
||||
{has_client_invoice_email && String(has_client_invoice_email) === "0" && <nav>
|
||||
<Tooltip className="tooltip_css" id="warn_invoice_data" style={{ "fontSize": "10px" }} />
|
||||
<a data-tooltip-id="warn_invoice_data" data-tooltip-html="Les données de facturation sont incompletes ">
|
||||
<WarningAmberIcon style={{ color: 'red', fontSize:"12px" }} />
|
||||
</a>
|
||||
</nav>}
|
||||
|
||||
</Button>
|
||||
<Button variant="outlined" onClick={submenu_contact} className="detail_submenu client_menu" id='submenu_contact' name='submenu_contact'>Contact & Adresses
|
||||
{client_has_communication_contact && String(client_has_communication_contact) === "0" && <nav>
|
||||
<Tooltip className="tooltip_css" id="warn_com_contact" style={{ "fontSize": "10px" }} />
|
||||
<a data-tooltip-id="warn_com_contact" data-tooltip-html="Aucun contact de communication ">
|
||||
<WarningAmberIcon style={{ color: 'red', fontSize:"12px" }} />
|
||||
</a>
|
||||
</nav>}
|
||||
|
||||
|
||||
</Button>
|
||||
<Button variant="outlined" onClick={submenu_activite} className="detail_submenu client_menu" id='submenu_activite' name='submenu_activite'>Activité</Button>
|
||||
<Button variant="outlined" onClick={submenu_piece_jointe} className="detail_submenu client_menu" id='submenu_piece_jointe' name='submenu_piece_jointe'>Pièces Jointes</Button>
|
||||
|
||||
{/* <Button variant="outlined" onClick={submenu_devis} className="detail_submenu" id='submenu_devis' name='submenu_devis'>Devis</Button>
|
||||
{/* zzzzz <Button variant="outlined" onClick={submenu_devis} className="detail_submenu" id='submenu_devis' name='submenu_devis'>Devis</Button>
|
||||
<Button variant="outlined" onClick={submenu_cmd} className="detail_submenu" id='submenu_cmd' name='submenu_cmd'>Commandes</Button>
|
||||
<Button variant="outlined" onClick={submenu_factures} className="detail_submenu" id='submenu_factures' name='submenu_factures'>Factures</Button>
|
||||
<Button variant="outlined" onClick={submenu_stagiaires} className="detail_submenu" id='submenu_stagiaires' name='submenu_stagiaires'>Stagiaires</Button>*/}
|
||||
|
@ -3726,7 +3767,7 @@ const AddParnerClient = (props) => {
|
|||
/>
|
||||
</div>
|
||||
|
||||
<div className="session_caract"> Conditions Paiement<br />
|
||||
<div className="session_caract"> <b> Conditions Paiement </b><br />
|
||||
{String(formedit_mode_invoice) !== "1" && <TextField
|
||||
required
|
||||
name="client_invoice_paiement_condition"
|
||||
|
|
|
@ -636,8 +636,6 @@ const Dashbord_Factures_Par_Periode = (props) => {
|
|||
{Getall_Qry_Invoice_Data_result_JSON && Getall_Qry_Invoice_Data_result_JSON.length > 0 &&
|
||||
Getall_Qry_Invoice_Data_result_JSON[0].data &&
|
||||
<BarChart
|
||||
|
||||
|
||||
dataset={Getall_Qry_Invoice_Data_result_JSON[0].data}
|
||||
xAxis={[{ scaleType: 'band', dataKey: 'month_year', tickPlacement: 'middle' }]}
|
||||
series={[
|
||||
|
|
|
@ -294,7 +294,7 @@ const Dashbord_Inscriptions_all_inscriptions = (props) => {
|
|||
const chartSetting = {
|
||||
yAxis: [
|
||||
{
|
||||
label: " Nombre d'inscription ",
|
||||
label: " Nombre d'inscriptions ",
|
||||
},
|
||||
],
|
||||
width: 1000,
|
||||
|
|
|
@ -404,82 +404,7 @@ const Dashbord_Session_Taux_Remplissage = (props) => {
|
|||
{isLoading && <div className="loader-container">
|
||||
<div className="mysy_spinner"> <img src={img_loading_spin} /> </div>
|
||||
</div>}
|
||||
{/* <div className="div_row">
|
||||
<div className="" style={{ "width": "30%" }}>
|
||||
Filtre <br />
|
||||
<TextField
|
||||
sx={{ '& legend': { display: 'none' }, '& fieldset': { top: 0 }, }}
|
||||
required
|
||||
name="filtre11"
|
||||
id="filtre11"
|
||||
select
|
||||
InputLabelProps={{
|
||||
shrink: true,
|
||||
}}
|
||||
disabled={false}
|
||||
className="disabled_style"
|
||||
value={filter_value}
|
||||
onChange={(e) => {
|
||||
setfilter_value(e.target.value);
|
||||
}
|
||||
}
|
||||
|
||||
>
|
||||
<MenuItem value="m0" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }}>Mois en cours </MenuItem>
|
||||
<MenuItem value="t0" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Trimestre en cours </MenuItem>
|
||||
<MenuItem value="d" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Choisir des dates </MenuItem>
|
||||
</TextField>
|
||||
</div>
|
||||
|
||||
{filter_value && String(filter_value) === "d" && <div>
|
||||
<div className="session_caract">
|
||||
Date Debut
|
||||
<DatePicker
|
||||
name="one_sessiondatedebut"
|
||||
id="one_sessiondatedebut"
|
||||
|
||||
selected={new Date(moment(p_filter_date_from, "dd/MM/yyyy"))}
|
||||
onChange={(date) => {
|
||||
setp_filter_date_from(format(date, 'dd/MM/yyyy'));
|
||||
|
||||
}
|
||||
}
|
||||
showTimeSelect={false}
|
||||
dateFormat="dd/MM/yyyy"
|
||||
className="disabled_style session_caract_Dialog_DatePicker"
|
||||
locale='fr-FR'
|
||||
|
||||
/>
|
||||
|
||||
</div>
|
||||
|
||||
<div className="session_caract">
|
||||
Date Fin
|
||||
<DatePicker
|
||||
name="one_sessiondatefin"
|
||||
id="one_sessiondatefin"
|
||||
selected={new Date(moment(p_filter_date_to, "dd/MM/yyyy"))}
|
||||
onChange={(date) => {
|
||||
setp_filter_date_to(format(date, 'dd/MM/yyyy'));
|
||||
|
||||
}
|
||||
}
|
||||
showTimeSelect={false}
|
||||
dateFormat="dd/MM/yyyy"
|
||||
className="disabled_style enable_style"
|
||||
/>
|
||||
|
||||
</div>
|
||||
|
||||
</div>}
|
||||
<Button variant="contained" className="bton_enreg" onClick={(e) => {
|
||||
Getall_Qry_Session_Data();
|
||||
Getall_Qry_Session_Data_By_Trainer();
|
||||
}}> Afficher
|
||||
</Button><br />
|
||||
|
||||
|
||||
</div> */}
|
||||
|
||||
<div style={{ "height": "40rem" }}>
|
||||
<div className="titre1" style={{ "float": "left", "cursor": "none" }}>
|
||||
|
|
|
@ -20349,7 +20349,7 @@ const DisplayPartnerSession = (props) => {
|
|||
|
||||
{String(submenu) === String("evaluation_session") && <div style={{ "border": "None" }}>
|
||||
|
||||
p_formateur_id = {p_formateur_id}
|
||||
|
||||
|
||||
<Module_Session_Evaluation conntected_employee_id={props.conntected_employee_id} related_collection={"session_formation"}
|
||||
related_collection_recid={selected_session_id} SessionstartDate={new Date(moment(SessionstartDate, "DD/MM/YYYY"))}
|
||||
|
|
|
@ -5738,7 +5738,7 @@ const Employes = (props) => {
|
|||
|
||||
const otherSetting = {
|
||||
height: 300,
|
||||
yAxis: [{ label: 'rainfall (mm)' }],
|
||||
yAxis: [{ label: '' }],
|
||||
grid: { horizontal: true },
|
||||
sx: {
|
||||
[`& .${axisClasses.left} .${axisClasses.label}`]: {
|
||||
|
@ -8532,6 +8532,8 @@ const Employes = (props) => {
|
|||
<Button variant="outlined" onClick={submenu_affectation} className="detail_class_submenu" id='affectation' name='affectation'>Affectation </Button>
|
||||
<Button variant="outlined" onClick={submenu_contrat} className="detail_class_submenu" id='affectation' name='contrat'>Contrat </Button>
|
||||
<Button variant="outlined" onClick={submenu_evaluation} className="detail_class_submenu" id='evaluation' name='evaluation'>Evaluation </Button>
|
||||
<Button variant="outlined" onClick={submenu_statistiques} className="detail_class_submenu" id='statistiques' name='statistiques'>Statistiques </Button>
|
||||
|
||||
</div>
|
||||
<nav style={{ "border": "None", "fontSize": "22px", "fontWeight": "600" }}> Ajouter un Employé </nav>
|
||||
|
||||
|
@ -9050,6 +9052,8 @@ const Employes = (props) => {
|
|||
<Button variant="outlined" onClick={submenu_affectation} className="detail_class_submenu" id='affectation' name='affectation'>Affectation </Button>
|
||||
<Button variant="outlined" onClick={submenu_contrat} className="detail_class_submenu" id='affectation' name='contrat'>Contrat </Button>
|
||||
<Button variant="outlined" onClick={submenu_evaluation} className="detail_class_submenu" id='evaluation' name='evaluation'>Evaluation </Button>
|
||||
<Button variant="outlined" onClick={submenu_statistiques} className="detail_class_submenu" id='statistiques' name='statistiques'>Statistiques </Button>
|
||||
|
||||
</div>
|
||||
<nav style={{ "border": "None", "fontSize": "22px", "fontWeight": "600" }}> Liste Affectations </nav>
|
||||
<div className="session_data">
|
||||
|
@ -9615,6 +9619,8 @@ const Employes = (props) => {
|
|||
<Button variant="outlined" onClick={submenu_affectation} className="detail_class_submenu" id='affectation' name='affectation'>Affectation </Button>
|
||||
<Button variant="outlined" onClick={submenu_contrat} className="detail_class_submenu" id='affectation' name='contrat'>Contrat </Button>
|
||||
<Button variant="outlined" onClick={submenu_evaluation} className="detail_class_submenu" id='evaluation' name='evaluation'>Evaluation </Button>
|
||||
<Button variant="outlined" onClick={submenu_statistiques} className="detail_class_submenu" id='statistiques' name='statistiques'>Statistiques </Button>
|
||||
|
||||
</div>
|
||||
|
||||
<nav style={{ "border": "None", "fontSize": "22px", "fontWeight": "600" }}> Droits d'accès système </nav>
|
||||
|
@ -9863,6 +9869,8 @@ const Employes = (props) => {
|
|||
<Button variant="outlined" onClick={submenu_affectation} className="detail_class_submenu" id='affectation' name='affectation'>Affectation </Button>
|
||||
<Button variant="outlined" onClick={submenu_contrat} className="detail_class_submenu" id='affectation' name='contrat'>Contrat </Button>
|
||||
<Button variant="outlined" onClick={submenu_evaluation} className="detail_class_submenu" id='evaluation' name='evaluation'>Evaluation </Button>
|
||||
<Button variant="outlined" onClick={submenu_statistiques} className="detail_class_submenu" id='statistiques' name='statistiques'>Statistiques </Button>
|
||||
|
||||
</div>
|
||||
|
||||
<div style={{ height: 550, width: '100%', paddingRight: '1px', "marginLeft": "10px", "marginRight": "10px", }}>
|
||||
|
@ -9973,6 +9981,8 @@ const Employes = (props) => {
|
|||
<Button variant="outlined" onClick={submenu_affectation} className="detail_class_submenu" id='affectation' name='affectation'>Affectation </Button>
|
||||
<Button variant="outlined" onClick={submenu_contrat} className="detail_class_submenu" id='affectation' name='contrat'>Contrat </Button>
|
||||
<Button variant="outlined" onClick={submenu_evaluation} className="detail_class_submenu" id='evaluation' name='evaluation'>Evaluation </Button>
|
||||
<Button variant="outlined" onClick={submenu_statistiques} className="detail_class_submenu" id='statistiques' name='statistiques'>Statistiques </Button>
|
||||
|
||||
</div>
|
||||
<nav style={{ "border": "None", "fontSize": "22px", "fontWeight": "600" }}> Les pièces jointes </nav>
|
||||
|
||||
|
@ -10128,6 +10138,8 @@ const Employes = (props) => {
|
|||
<Button variant="outlined" onClick={submenu_affectation} className="detail_class_submenu" id='affectation' name='affectation'>Affectation </Button>
|
||||
<Button variant="outlined" onClick={submenu_contrat} className="detail_class_submenu" id='affectation' name='contrat'>Contrat </Button>
|
||||
<Button variant="outlined" onClick={submenu_evaluation} className="detail_class_submenu" id='evaluation' name='evaluation'>Evaluation </Button>
|
||||
<Button variant="outlined" onClick={submenu_statistiques} className="detail_class_submenu" id='statistiques' name='statistiques'>Statistiques </Button>
|
||||
|
||||
</div>
|
||||
<nav style={{ "border": "None", "fontSize": "22px", "fontWeight": "600" }}> Les Compétences </nav>
|
||||
<div className="session_data" style={{ "minHeight": '15rem', "paddingLeft": "10px", "paddingRight": "10px" }}>
|
||||
|
@ -10206,6 +10218,8 @@ const Employes = (props) => {
|
|||
<Button variant="outlined" onClick={submenu_affectation} className="detail_class_submenu" id='affectation' name='affectation'>Affectation </Button>
|
||||
<Button variant="outlined" onClick={submenu_contrat} className="detail_class_submenu" id='affectation' name='contrat'>Contrat </Button>
|
||||
<Button variant="outlined" onClick={submenu_evaluation} className="detail_class_submenu" id='evaluation' name='evaluation'>Evaluation </Button>
|
||||
<Button variant="outlined" onClick={submenu_statistiques} className="detail_class_submenu" id='statistiques' name='statistiques'>Statistiques </Button>
|
||||
|
||||
</div>
|
||||
<nav style={{ "border": "None", "fontSize": "22px", "fontWeight": "600" }}> Les evaluations </nav>
|
||||
|
||||
|
|
|
@ -15,7 +15,7 @@ import 'reactjs-popup/dist/index.css';
|
|||
|
||||
import "react-datepicker/dist/react-datepicker.css";
|
||||
|
||||
|
||||
import Button from '@mui/material/Button';
|
||||
import img_loading_spin from "./../mysy_img/mysy_spin_loading.gif";
|
||||
|
||||
import Dashbord_Session_Par_Fteur from "./Dashbord_Session_Par_Fteur";
|
||||
|
@ -29,13 +29,31 @@ import Dashbord_Factures_Par_Client from "./Dashbord_Factures_Par_Client";
|
|||
import Dashbord_Factures_Devis_Par_Periode from "./Dashbord_Factures_Devis_Par_Periode";
|
||||
import Dashbord_Inscriptions_all_inscriptions from "./Dashbord_Inscription_All_Inscription";
|
||||
import Dashbord_Factures_Previsionnel_Par_Periode from "./Dashbord_Factures_Previsionnel_Par_Periode";
|
||||
|
||||
import Box from '@mui/material/Box';
|
||||
import { TbColumns2, TbColumns1 } from "react-icons/tb";
|
||||
|
||||
import { BarChart } from '@mui/x-charts';
|
||||
import { axisClasses } from '@mui/x-charts';
|
||||
import { pieArcLabelClasses } from '@mui/x-charts/PieChart';
|
||||
import Popup from 'reactjs-popup';
|
||||
import 'reactjs-popup/dist/index.css';
|
||||
import { MdDeleteForever } from "react-icons/md";
|
||||
import { RiFileExcel2Line } from "react-icons/ri";
|
||||
import Autocomplete from '@mui/material/Autocomplete';
|
||||
import TextField from '@mui/material/TextField';
|
||||
import { format } from 'date-fns'
|
||||
import moment from "moment";
|
||||
import DatePicker from "react-datepicker";
|
||||
import "react-datepicker/dist/react-datepicker.css";
|
||||
import { ResponsiveBar } from "@nivo/bar";
|
||||
import {
|
||||
useTheme,
|
||||
} from "@mui/material";
|
||||
import { tokens } from "../theme";
|
||||
|
||||
const Mon_Tableau_De_Bord = (props) => {
|
||||
|
||||
|
||||
const theme = useTheme();
|
||||
const colors = tokens(theme.palette.mode);
|
||||
const history = useHistory();
|
||||
const [isLoading, setLoading] = useState();
|
||||
|
||||
|
@ -86,6 +104,9 @@ const Mon_Tableau_De_Bord = (props) => {
|
|||
useEffect(() => {
|
||||
|
||||
|
||||
if (String(submenu) === "") {
|
||||
submenu_rapport_activite();
|
||||
}
|
||||
Get_Connected_User_Dashbord();
|
||||
window.scrollTo({
|
||||
top: 0,
|
||||
|
@ -94,16 +115,886 @@ const Mon_Tableau_De_Bord = (props) => {
|
|||
|
||||
}, [])
|
||||
|
||||
const New_option_periode = [
|
||||
{ "id": "m0", "label": "Mois en cours", "value": "m0" },
|
||||
{ "id": "m1", "label": "Mois précédant ", "value": "m1" },
|
||||
{ "id": "d", "label": "Choisir des dates", "value": "d" },
|
||||
|
||||
]
|
||||
|
||||
const New_option_group_by = [
|
||||
{ "id": "mois", "label": "Mois", "value": "mois" },
|
||||
{ "id": "class", "label": "Formation", "value": "class" },
|
||||
{ "id": "session", "label": "Session", "value": "session" },
|
||||
{ "id": "", "label": "", "value": "" },
|
||||
]
|
||||
|
||||
const [display_nb_column, setdisplay_nb_column] = useState("1");
|
||||
const [display_column_size, setdisplay_column_size] = useState("98%");
|
||||
|
||||
const [submenu, setsubmenu] = useState("");
|
||||
function submenu_montbd() {
|
||||
setsubmenu("montbd");
|
||||
|
||||
submenu_color_management("montbd");
|
||||
}
|
||||
|
||||
function submenu_rapport_activite() {
|
||||
setsubmenu("rapport_activite");
|
||||
submenu_color_management("rapport_activite");
|
||||
}
|
||||
|
||||
function submenu_rapport_financier() {
|
||||
setsubmenu("rapport_financier");
|
||||
submenu_color_management("rapport_financier");
|
||||
}
|
||||
|
||||
|
||||
|
||||
function submenu_color_management(current_menu) {
|
||||
const list_sous_menu = ["montbd", "rapport_activite", "rapport_financier"]
|
||||
|
||||
for (let i = 0; i < list_sous_menu.length; i++) {
|
||||
|
||||
var sous_menu = list_sous_menu[i];
|
||||
if (String(sous_menu) !== current_menu) {
|
||||
if (document.getElementById(sous_menu)) {
|
||||
document.getElementById(sous_menu).style.backgroundColor = "#d8edfc";
|
||||
document.getElementById(sous_menu).style.color = "black";
|
||||
document.getElementById(sous_menu).style.fontWeight = "normal";
|
||||
}
|
||||
}
|
||||
|
||||
if (String(sous_menu) === "editique") {
|
||||
if (document.getElementById(sous_menu)) {
|
||||
document.getElementById(sous_menu).style.backgroundColor = "#6C3483";
|
||||
document.getElementById(sous_menu).style.color = "#FFFFFF";
|
||||
document.getElementById(sous_menu).style.fontWeight = "bold";
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
if (document.getElementById(current_menu)) {
|
||||
document.getElementById(current_menu).style.backgroundColor = "#104277";
|
||||
document.getElementById(current_menu).style.color = "white";
|
||||
document.getElementById(current_menu).style.fontWeight = "bold";
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
var date_today_90j = new Date();
|
||||
date_today_90j.setDate(date_today_90j.getDate() - 90);
|
||||
const valueFormatter_count = (value) => `${value} Insc`;
|
||||
|
||||
const [p_filter_date_from, setp_filter_date_from] = useState(date_today_90j.toLocaleDateString('fr-FR'));
|
||||
const [p_filter_date_to, setp_filter_date_to] = useState(new Date().toLocaleDateString('fr-FR'));
|
||||
const [filter_group_by, setfilter_group_by] = useState("");
|
||||
const [filter_value, setfilter_value] = useState("d");
|
||||
|
||||
const [Getall_Qry_Inscription_Data_result_JSON, setGetall_Qry_Inscription_Data_result_JSON] = useState([]);
|
||||
|
||||
const [Getall_Qry_Inscription_Data_api, setGetall_Qry_Inscription_Data_api] = useState();
|
||||
const [Getall_Qry_Inscription_Data_message, setGetall_Qry_Inscription_Data_message] = useState();
|
||||
const [Getall_Qry_Inscription_Data_result, setGetall_Qry_Inscription_Data_result] = useState([]);
|
||||
function Getall_Qry_Inscription_Data(groupe_by) {
|
||||
|
||||
var form = new FormData();
|
||||
const stored_cookie = getCookie('tokenmysypart');
|
||||
|
||||
var date_from = "";
|
||||
if (p_filter_date_from) {
|
||||
date_from = p_filter_date_from;
|
||||
|
||||
}
|
||||
|
||||
var date_to = "";
|
||||
if (p_filter_date_to) {
|
||||
date_to = p_filter_date_to;
|
||||
|
||||
}
|
||||
|
||||
|
||||
form.append("token", stored_cookie);
|
||||
form.append("session_start_date", date_from);
|
||||
form.append("session_end_date", date_to);
|
||||
form.append("filter_value", filter_value);
|
||||
|
||||
|
||||
|
||||
var myurl = "";
|
||||
if (String(groupe_by) === "class")
|
||||
myurl = process.env.REACT_APP_API_URL + "myclass/api/Get_Qery_Inscription_Group_By_Class/";
|
||||
else if (String(groupe_by) === "session")
|
||||
myurl = process.env.REACT_APP_API_URL + "myclass/api/Get_Qery_Inscription_Group_By_Session/";
|
||||
else if (String(groupe_by) === "periode_cumule")
|
||||
myurl = process.env.REACT_APP_API_URL + "myclass/api/Get_Qery_Inscription_By_Session_By_Periode_cumule/";
|
||||
else
|
||||
myurl = process.env.REACT_APP_API_URL + "myclass/api/Get_Qery_Inscription_By_Session_By_Periode/";
|
||||
|
||||
setLoading(true);
|
||||
axios.post(myurl, form).then(res => {
|
||||
setLoading(false);
|
||||
if (String(res.data.status) === String("true")) {
|
||||
//console.log(" In Getall_Qry_Inscription_Data res.data.status = " + res.data.status);
|
||||
//console.log(" In Getall_Qry_Inscription_Data res.data.message r_class = " + res.data.message);
|
||||
|
||||
setGetall_Qry_Inscription_Data_result_JSON(JSON.parse('[' + res.data.message + ']'));
|
||||
|
||||
var jsonObj = JSON.parse('[' + res.data.message + ']');
|
||||
|
||||
//console.log(" ### jsonObj = ", jsonObj)
|
||||
|
||||
setGetall_Qry_Inscription_Data_api("true");
|
||||
setGetall_Qry_Inscription_Data_result(res.data.message);
|
||||
|
||||
|
||||
}
|
||||
else {
|
||||
setGetall_Qry_Inscription_Data_api("false");
|
||||
setGetall_Qry_Inscription_Data_message(res.data.message);
|
||||
alert(res.data.message)
|
||||
}
|
||||
|
||||
}).catch((error) => {
|
||||
setLoading(false);
|
||||
console.warn('Not good man :( Getall_Qry_Inscription_Data = ', error);
|
||||
setGetall_Qry_Inscription_Data_api("false");
|
||||
alert("Impossible de récuperer les données demandées")
|
||||
//setmyApimyApiMessage("")
|
||||
})
|
||||
}
|
||||
|
||||
const chartSetting = {
|
||||
yAxis: [
|
||||
{
|
||||
label: " ",
|
||||
},
|
||||
],
|
||||
width: 1100,
|
||||
height: 400,
|
||||
|
||||
margin: 100,
|
||||
};
|
||||
|
||||
const chartSetting_V2 = {
|
||||
yAxis: [
|
||||
{
|
||||
label: " ",
|
||||
},
|
||||
],
|
||||
width: 1100,
|
||||
height: 600,
|
||||
|
||||
margin: 100,
|
||||
};
|
||||
|
||||
|
||||
function display_inscrit_by_periode() {
|
||||
setfilter_group_by("");
|
||||
Getall_Qry_Inscription_Data("");
|
||||
}
|
||||
|
||||
function display_inscrit_by_formation() {
|
||||
setfilter_group_by("class");
|
||||
Getall_Qry_Inscription_Data("class");
|
||||
}
|
||||
|
||||
function display_inscrit_by_session() {
|
||||
setfilter_group_by("session");
|
||||
Getall_Qry_Inscription_Data("session");
|
||||
}
|
||||
|
||||
|
||||
function display_inscrit_by_periode_cumule() {
|
||||
setfilter_group_by("periode_cumule");
|
||||
Getall_Qry_Inscription_Data("periode_cumule");
|
||||
}
|
||||
|
||||
|
||||
const [Getall_Qry_Formation_Session_result_JSON, setGetall_Qry_Formation_Session_result_JSON] = useState([]);
|
||||
const [Getall_Qry_Formation_Session_api, setGetall_Qry_Formation_Session_api] = useState();
|
||||
const [Getall_Qry_Formation_Session_message, setGetall_Qry_Formation_Session_message] = useState();
|
||||
const [Getall_Qry_Formation_Session_result, setGetall_Qry_Formation_Session_result] = useState([]);
|
||||
function Getall_Qry_Formation_Session(session_groupe_by) {
|
||||
|
||||
var form = new FormData();
|
||||
const stored_cookie = getCookie('tokenmysypart');
|
||||
|
||||
var date_from = "";
|
||||
if (p_filter_date_from) {
|
||||
date_from = p_filter_date_from;
|
||||
|
||||
}
|
||||
|
||||
var date_to = "";
|
||||
if (p_filter_date_to) {
|
||||
date_to = p_filter_date_to;
|
||||
|
||||
}
|
||||
|
||||
|
||||
form.append("token", stored_cookie);
|
||||
form.append("session_start_date", date_from);
|
||||
form.append("session_end_date", date_to);
|
||||
form.append("filter_value", filter_value);
|
||||
|
||||
var myurl = process.env.REACT_APP_API_URL + "myclass/api/Get_Qery_Session_By_Periode_V2/";
|
||||
|
||||
if (String(session_groupe_by) === "periode_cumule")
|
||||
myurl = process.env.REACT_APP_API_URL + "myclass/api/Get_Qery_Session_By_Periode_Cumule_V2/";
|
||||
|
||||
else if (String(session_groupe_by) === "class")
|
||||
myurl = process.env.REACT_APP_API_URL + "myclass/api/Get_Qery_Session_By_Formation_V2/";
|
||||
|
||||
setLoading(true);
|
||||
axios.post(myurl, form).then(res => {
|
||||
setLoading(false);
|
||||
if (String(res.data.status) === String("true")) {
|
||||
console.log(" In Getall_Qry_Formation_Session res.data.status = " + res.data.status);
|
||||
console.log(" In Getall_Qry_Formation_Session res.data.message r_class = " + res.data.message);
|
||||
|
||||
|
||||
setGetall_Qry_Formation_Session_result_JSON(JSON.parse('[' + res.data.message + ']'));
|
||||
|
||||
var jsonObj = JSON.parse('[' + res.data.message + ']');
|
||||
|
||||
|
||||
setGetall_Qry_Formation_Session_api("true");
|
||||
setGetall_Qry_Formation_Session_result(res.data.message);
|
||||
|
||||
console.log(" Getall_Qry_Formation_Session_result_JSON = ", Getall_Qry_Formation_Session_result_JSON);
|
||||
|
||||
|
||||
}
|
||||
else {
|
||||
setGetall_Qry_Formation_Session_api("false");
|
||||
setGetall_Qry_Formation_Session_message(res.data.message);
|
||||
alert(res.data.message)
|
||||
}
|
||||
|
||||
}).catch((error) => {
|
||||
setLoading(false);
|
||||
console.warn('Not good man :( Getall_Qry_Formation_Session = ', error);
|
||||
setGetall_Qry_Formation_Session_api("false");
|
||||
alert("Impossible de récuperer les données demandées")
|
||||
//setmyApimyApiMessage("")
|
||||
})
|
||||
}
|
||||
|
||||
const [filter_session_group_by, setfilter_session_group_by] = useState("");
|
||||
|
||||
function display_session_by_periode() {
|
||||
setfilter_session_group_by("");
|
||||
Getall_Qry_Formation_Session("");
|
||||
}
|
||||
|
||||
|
||||
function display_session_by_formation() {
|
||||
setfilter_session_group_by("class");
|
||||
Getall_Qry_Formation_Session("class");
|
||||
}
|
||||
|
||||
|
||||
function display_session_by_periode_cumule() {
|
||||
setfilter_session_group_by("periode_cumule");
|
||||
Getall_Qry_Formation_Session("periode_cumule");
|
||||
}
|
||||
|
||||
|
||||
const [Getall_Qry_Session_Data_result_JSON, setGetall_Qry_Session_Data_result_JSON] = useState([]);
|
||||
const [Getall_Qry_Session_Data_api, setGetall_Qry_Session_Data_api] = useState();
|
||||
const [Getall_Qry_Session_Data_message, setGetall_Qry_Session_Data_message] = useState();
|
||||
const [Getall_Qry_Session_Data_result, setGetall_Qry_Session_Data_result] = useState([]);
|
||||
function Getall_Qry_Session_Data(event) {
|
||||
|
||||
var form = new FormData();
|
||||
const stored_cookie = getCookie('tokenmysypart');
|
||||
|
||||
var date_from = "";
|
||||
if (p_filter_date_from) {
|
||||
date_from = p_filter_date_from;
|
||||
|
||||
}
|
||||
|
||||
var date_to = "";
|
||||
if (p_filter_date_to) {
|
||||
date_to = p_filter_date_to;
|
||||
|
||||
}
|
||||
|
||||
form.append("token", stored_cookie);
|
||||
form.append("session_start_date", date_from);
|
||||
form.append("session_end_date", date_to);
|
||||
|
||||
|
||||
var myurl = process.env.REACT_APP_API_URL + "myclass/api/Get_Qery_List_Session_Data/";
|
||||
|
||||
//console.log(" ### form = ", form);
|
||||
|
||||
setLoading(true);
|
||||
axios.post(myurl, form).then(res => {
|
||||
setLoading(false);
|
||||
if (String(res.data.status) === String("true")) {
|
||||
//console.log(" In Getall_Qry_Session_Data res.data.status = " + res.data.status);
|
||||
//console.log(" In Getall_Qry_Session_Data res.data.message r_class = " + res.data.message);
|
||||
setGetall_Qry_Session_Data_result_JSON(JSON.parse('[' + res.data.message + ']'));
|
||||
|
||||
var jsonObj = JSON.parse('[' + res.data.message + ']');
|
||||
|
||||
setGetall_Qry_Session_Data_api("true");
|
||||
setGetall_Qry_Session_Data_result(res.data.message);
|
||||
|
||||
|
||||
}
|
||||
else {
|
||||
setGetall_Qry_Session_Data_api("false");
|
||||
setGetall_Qry_Session_Data_message(res.data.message);
|
||||
alert(res.data.message)
|
||||
}
|
||||
|
||||
}).catch((error) => {
|
||||
setLoading(false);
|
||||
console.warn('Not good man :( Getall_Qry_Session_Data = ', error);
|
||||
setGetall_Qry_Session_Data_api("false");
|
||||
alert("Impossible de récuperer les données demandées")
|
||||
//setmyApimyApiMessage("")
|
||||
})
|
||||
}
|
||||
|
||||
const [Getall_Qry_Session_Taux_Remplissage_result_JSON, setGetall_Qry_Session_Taux_Remplissage_result_JSON] = useState([]);
|
||||
const [Getall_Qry_Session_Taux_Remplissage_api, setGetall_Qry_Session_Taux_Remplissage_api] = useState();
|
||||
const [Getall_Qry_Session_Taux_Remplissage_message, setGetall_Qry_Session_Taux_Remplissage_message] = useState();
|
||||
const [Getall_Qry_Session_Taux_Remplissage_result, setGetall_Qry_Session_Taux_Remplissage_result] = useState([]);
|
||||
function Getall_Qry_Session_Taux_Remplissage(session_groupe_by) {
|
||||
|
||||
var form = new FormData();
|
||||
const stored_cookie = getCookie('tokenmysypart');
|
||||
|
||||
var date_from = "";
|
||||
if (p_filter_date_from) {
|
||||
date_from = p_filter_date_from;
|
||||
|
||||
}
|
||||
|
||||
var date_to = "";
|
||||
if (p_filter_date_to) {
|
||||
date_to = p_filter_date_to;
|
||||
|
||||
}
|
||||
|
||||
|
||||
form.append("token", stored_cookie);
|
||||
form.append("session_start_date", date_from);
|
||||
form.append("session_end_date", date_to);
|
||||
form.append("filter_value", filter_value);
|
||||
|
||||
var myurl = process.env.REACT_APP_API_URL + "myclass/api/Get_Qery_List_Taux_Remplissage_Session_Data_V2/";
|
||||
|
||||
setLoading(true);
|
||||
axios.post(myurl, form).then(res => {
|
||||
setLoading(false);
|
||||
if (String(res.data.status) === String("true")) {
|
||||
//console.log(" In Getall_Qry_Session_Taux_Remplissage res.data.status = " + res.data.status);
|
||||
//console.log(" In Getall_Qry_Session_Taux_Remplissage res.data.message r_class = " + res.data.message);
|
||||
|
||||
|
||||
setGetall_Qry_Session_Taux_Remplissage_result_JSON(JSON.parse('[' + res.data.message + ']'));
|
||||
|
||||
var jsonObj = JSON.parse('[' + res.data.message + ']');
|
||||
|
||||
|
||||
|
||||
setGetall_Qry_Session_Taux_Remplissage_api("true");
|
||||
setGetall_Qry_Session_Taux_Remplissage_result(res.data.message);
|
||||
|
||||
|
||||
}
|
||||
else {
|
||||
setGetall_Qry_Session_Taux_Remplissage_api("false");
|
||||
setGetall_Qry_Session_Taux_Remplissage_message(res.data.message);
|
||||
alert(res.data.message)
|
||||
}
|
||||
|
||||
}).catch((error) => {
|
||||
setLoading(false);
|
||||
console.warn('Not good man :( Getall_Qry_Session_Taux_Remplissage = ', error);
|
||||
setGetall_Qry_Session_Taux_Remplissage_api("false");
|
||||
alert("Impossible de récuperer les données demandées")
|
||||
//setmyApimyApiMessage("")
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
|
||||
const [p_detail_partner_client_id, setp_detail_partner_client_id] = useState("");
|
||||
const [p_detail_partner_client_nom, setp_detail_partner_client_nom] = useState("");
|
||||
|
||||
|
||||
const [Getall_Qry_Invoice_Data_result_JSON, setGetall_Qry_Invoice_Data_result_JSON] = useState([]);
|
||||
const [Getall_Qry_Invoice_Data_api, setGetall_Qry_Invoice_Data_api] = useState();
|
||||
const [Getall_Qry_Invoice_Data_message, setGetall_Qry_Invoice_Data_message] = useState();
|
||||
const [Getall_Qry_Invoice_Data_result, setGetall_Qry_Invoice_Data_result] = useState([]);
|
||||
function Getall_Qry_Invoice_Data(local_group_by) {
|
||||
|
||||
var form = new FormData();
|
||||
const stored_cookie = getCookie('tokenmysypart');
|
||||
|
||||
var date_from = "";
|
||||
if (p_filter_date_from) {
|
||||
date_from = p_filter_date_from;
|
||||
|
||||
}
|
||||
|
||||
var date_to = "";
|
||||
if (p_filter_date_to) {
|
||||
date_to = p_filter_date_to;
|
||||
|
||||
}
|
||||
|
||||
|
||||
form.append("token", stored_cookie);
|
||||
form.append("periode_start_date", date_from);
|
||||
form.append("periode_end_date", date_to);
|
||||
form.append("filter_value", filter_value);
|
||||
|
||||
|
||||
|
||||
var myurl = process.env.REACT_APP_API_URL + "myclass/api/Get_Qery_List_Factures_Data_By_Periode/";
|
||||
|
||||
if (local_group_by === "class")
|
||||
myurl = process.env.REACT_APP_API_URL + "myclass/api/Get_Qery_List_Factures_Data_By_Class/";
|
||||
|
||||
setLoading(true);
|
||||
axios.post(myurl, form).then(res => {
|
||||
setLoading(false);
|
||||
if (String(res.data.status) === String("true")) {
|
||||
//console.log(" In Getall_Qry_Invoice_Data res.data.status = " + res.data.status);
|
||||
//console.log(" In Getall_Qry_Invoice_Data res.data.message r_class = " + res.data.message);
|
||||
|
||||
setGetall_Qry_Invoice_Data_result_JSON(JSON.parse('[' + res.data.message + ']'));
|
||||
|
||||
var jsonObj = JSON.parse('[' + res.data.message + ']');
|
||||
|
||||
//console.log("jsonObj = ", jsonObj)
|
||||
|
||||
setGetall_Qry_Invoice_Data_api("true");
|
||||
setGetall_Qry_Invoice_Data_result(res.data.message);
|
||||
|
||||
|
||||
}
|
||||
else {
|
||||
setGetall_Qry_Invoice_Data_api("false");
|
||||
setGetall_Qry_Invoice_Data_message(res.data.message);
|
||||
alert(res.data.message)
|
||||
}
|
||||
|
||||
}).catch((error) => {
|
||||
setLoading(false);
|
||||
console.warn('Not good man :( Getall_Qry_Invoice_Data = ', error);
|
||||
setGetall_Qry_Invoice_Data_api("false");
|
||||
alert("Impossible de récuperer les données demandées")
|
||||
//setmyApimyApiMessage("")
|
||||
})
|
||||
}
|
||||
|
||||
const valueFormatter_CA = (value) => `${value}€`;
|
||||
|
||||
|
||||
const [filter_invoice_group_by, setfilter_invoice_group_by] = useState("periode");
|
||||
|
||||
|
||||
function display_invoice_by_formation() {
|
||||
setfilter_invoice_group_by("class");
|
||||
Getall_Qry_Invoice_Data("class");
|
||||
}
|
||||
|
||||
function display_invoice_by_periode() {
|
||||
setfilter_invoice_group_by("periode");
|
||||
Getall_Qry_Invoice_Data("");
|
||||
}
|
||||
|
||||
|
||||
function display_invoice_by_session() {
|
||||
setfilter_invoice_group_by("class");
|
||||
Getall_Qry_Invoice_Data("class");
|
||||
}
|
||||
|
||||
|
||||
function display_invoice_by_periode_cumule() {
|
||||
setfilter_invoice_group_by("class");
|
||||
Getall_Qry_Invoice_Data("class");
|
||||
}
|
||||
|
||||
|
||||
return (
|
||||
<div className="mon_tableau_de_bord">
|
||||
{isLoading && <div className="loader-container">
|
||||
<div className="mysy_spinner"> <img src={img_loading_spin} /> </div>
|
||||
</div>}
|
||||
|
||||
<div className="div_row">
|
||||
|
||||
<Button variant="outlined" onClick={submenu_montbd} className="detail_class_submenu" id='montbd' name='montbd' >Mon tableau de bord </Button>
|
||||
<Button variant="outlined" onClick={submenu_rapport_activite} className="detail_class_submenu" id='rapport_activite' name='rapport_activite' >Rapport Activite </Button>
|
||||
<Button variant="outlined" onClick={submenu_rapport_financier} className="detail_class_submenu" id='rapport_financier' name='rapport_financier' >Rapports Financiers </Button>
|
||||
|
||||
</div>
|
||||
|
||||
<div>
|
||||
|
||||
<div style={{ "width": "100%", "float": "left" }}>
|
||||
<div className="" style={{ "width": "50%", "float": "left" }}>
|
||||
Filtre <br />
|
||||
|
||||
<Autocomplete
|
||||
disablePortal
|
||||
name="filtre11"
|
||||
id="filtre11"
|
||||
className="disabled_style"
|
||||
options={New_option_periode}
|
||||
onChange={(event, value) => {
|
||||
if (value && value.value) {
|
||||
setfilter_value(value.value);
|
||||
|
||||
} else {
|
||||
setfilter_value("");
|
||||
}
|
||||
|
||||
|
||||
}}
|
||||
|
||||
renderInput={(params) => <TextField {...params} label="" placeholder="Choisir une période"
|
||||
inputProps={{ ...params.inputProps, style: { fontSize: 12, height: "1.4rem" } }}
|
||||
|
||||
/>
|
||||
}
|
||||
/>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
{filter_value && String(filter_value) === "d" &&
|
||||
<div style={{ "width": "100%", "float": "left" }}>
|
||||
<div className="" style={{ "width": "50%", "float": "left" }}>
|
||||
<div className="session_caract" style={{ "padding": '0px', 'width': '100%' }}>
|
||||
Date Debut
|
||||
<DatePicker
|
||||
name="one_sessiondatedebut"
|
||||
id="one_sessiondatedebut"
|
||||
|
||||
selected={new Date(moment(p_filter_date_from, "DD/MM/YYYY"))}
|
||||
onChange={(date) => {
|
||||
setp_filter_date_from(format(date, 'dd/MM/yyyy'));
|
||||
|
||||
}
|
||||
}
|
||||
showTimeSelect={false}
|
||||
dateFormat="dd/MM/yyyy"
|
||||
className="disabled_style"
|
||||
locale='fr-FR'
|
||||
|
||||
/>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div className="" style={{ "width": "50%", "float": "left" }}>
|
||||
<div className="session_caract" style={{ "padding": '0px', 'width': '100%' }}>
|
||||
Date Fin
|
||||
<DatePicker
|
||||
name="one_sessiondatefin"
|
||||
id="one_sessiondatefin"
|
||||
selected={new Date(moment(p_filter_date_to, "DD/MM/YYYY"))}
|
||||
onChange={(date) => {
|
||||
setp_filter_date_to(format(date, 'dd/MM/yyyy'));
|
||||
|
||||
}
|
||||
}
|
||||
showTimeSelect={false}
|
||||
dateFormat="dd/MM/yyyy"
|
||||
className="disabled_style"
|
||||
/>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>}
|
||||
|
||||
<div className="div_row">
|
||||
<Button variant="contained" className="bton_enreg" onClick={(e) => {
|
||||
|
||||
// Recuperation des rapports d'activités
|
||||
if (String(submenu) === "rapport_activite") {
|
||||
Getall_Qry_Inscription_Data("");
|
||||
Getall_Qry_Formation_Session("");
|
||||
// Getall_Qry_Session_Data();
|
||||
Getall_Qry_Session_Taux_Remplissage("");
|
||||
}
|
||||
|
||||
// Recuperation des rapports financiers
|
||||
if (String(submenu) === "rapport_financier") {
|
||||
Getall_Qry_Invoice_Data();
|
||||
}
|
||||
|
||||
}}> Afficher
|
||||
</Button><br />
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<hr className="hr_break" />
|
||||
|
||||
{String(submenu) === String("rapport_financier") && <div style={{ "border": "None" }}>
|
||||
<h3> Rapports Financiers </h3>
|
||||
|
||||
<Box >
|
||||
<div className="session_data" >
|
||||
{Getall_Qry_Invoice_Data_result_JSON && Getall_Qry_Invoice_Data_result_JSON.length > 0 &&
|
||||
Getall_Qry_Invoice_Data_result_JSON[0].data &&
|
||||
<div>
|
||||
<div className="titre1"> Le Chiffre d'affaire </div>
|
||||
<div className="parent_group_by">
|
||||
|
||||
<Button variant="outlined" onClick={display_invoice_by_periode} className="detail_class_submenu" id='montbd' name='montbd' > Par Période </Button>
|
||||
<Button variant="outlined" onClick={display_invoice_by_formation} className="detail_class_submenu" id='rapport_activite' name='rapport_activite' >Par Ftion </Button>
|
||||
<Button variant="outlined" onClick={display_invoice_by_session} className="detail_class_submenu" id='rapport_activite' name='rapport_activite' >Par Session </Button>
|
||||
<Button variant="outlined" onClick={display_invoice_by_periode_cumule} className="detail_class_submenu" id='rapport_activite' name='rapport_activite' >Par période (Cumulé) </Button>
|
||||
|
||||
</div>
|
||||
|
||||
{filter_invoice_group_by && String(filter_invoice_group_by) === "periode" && <BarChart
|
||||
dataset={Getall_Qry_Invoice_Data_result_JSON[0].data}
|
||||
xAxis={[{ scaleType: 'band', dataKey: 'month_year', tickPlacement: 'middle', }]}
|
||||
series={[
|
||||
{ dataKey: 'TotalAmount', label: 'CA TTC', valueFormatter_CA },
|
||||
{ dataKey: 'count', label: 'Count', valueFormatter_count },
|
||||
|
||||
]}
|
||||
{...chartSetting}
|
||||
margin={{ right: 15, left: 100 }}
|
||||
|
||||
/>}
|
||||
|
||||
|
||||
{filter_invoice_group_by && String(filter_invoice_group_by) === "class" &&
|
||||
<BarChart
|
||||
|
||||
dataset={Getall_Qry_Invoice_Data_result_JSON[0].data}
|
||||
xAxis={[{
|
||||
scaleType: 'band', dataKey: 'class_external_code', tickPlacement: 'middle',
|
||||
valueFormatter: (month, context) => {
|
||||
if (month) {
|
||||
if (String(month).length < 4) {
|
||||
return `${month.slice(0, 4)}`
|
||||
}
|
||||
|
||||
else if (String(month).length >= 4 && String(month).length <= 8) {
|
||||
return `${month.slice(0, 4)}` + " \n" + `${month.slice(4, String(month).length)}`
|
||||
}
|
||||
else if (String(month).length > 8) {
|
||||
return `${month.slice(0, 4)}` + " \n" + `${month.slice(4, 8)}` + " \n" + `${month.slice(8, 12)}`
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
},
|
||||
}]}
|
||||
series={[
|
||||
{ dataKey: 'TotalAmount_HT', label: 'CA HT', valueFormatter_CA },
|
||||
|
||||
|
||||
]}
|
||||
{...chartSetting}
|
||||
margin={{ right: 15, left: 100 }}
|
||||
|
||||
|
||||
/>}
|
||||
</div>
|
||||
}
|
||||
|
||||
</div>
|
||||
</Box>
|
||||
</div>}
|
||||
|
||||
{String(submenu) === String("rapport_activite") && <div style={{ "border": "None" }}>
|
||||
<h3> Rapport d'activité </h3>
|
||||
<Box >
|
||||
<div className="session_data" >
|
||||
|
||||
{Getall_Qry_Inscription_Data_result_JSON && Getall_Qry_Inscription_Data_result_JSON.length > 0 &&
|
||||
Getall_Qry_Inscription_Data_result_JSON[0].data &&
|
||||
<div>
|
||||
<div className="titre1"> Les Inscriptions </div>
|
||||
<div className="parent_group_by">
|
||||
|
||||
<Button variant="outlined" onClick={display_inscrit_by_periode} className="detail_class_submenu" id='montbd' name='montbd' > Par Période </Button>
|
||||
<Button variant="outlined" onClick={display_inscrit_by_formation} className="detail_class_submenu" id='rapport_activite' name='rapport_activite' >Par Ftion </Button>
|
||||
<Button variant="outlined" onClick={display_inscrit_by_session} className="detail_class_submenu" id='rapport_activite' name='rapport_activite' >Par Session </Button>
|
||||
<Button variant="outlined" onClick={display_inscrit_by_periode_cumule} className="detail_class_submenu" id='rapport_activite' name='rapport_activite' >Par période (Cumulé) </Button>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<BarChart
|
||||
|
||||
dataset={Getall_Qry_Inscription_Data_result_JSON[0].data}
|
||||
// xAxis={[{ scaleType: 'band', dataKey: 'label', tickPlacement: 'middle' }]}
|
||||
xAxis={[{
|
||||
scaleType: 'band', dataKey: 'label', tickPlacement: 'middle',
|
||||
valueFormatter: (month, context) => {
|
||||
|
||||
if (month) {
|
||||
if (String(month).length < 4) {
|
||||
return `${month.slice(0, 4)}`
|
||||
}
|
||||
|
||||
else if (String(month).length >= 4 && String(month).length <= 8) {
|
||||
return `${month.slice(0, 4)}` + " \n" + `${month.slice(4, String(month).length)}`
|
||||
}
|
||||
|
||||
else if (String(month).length > 8) {
|
||||
return `${month.slice(0, 4)}` + " \n" + `${month.slice(4, 8)}` + " \n" + `${month.slice(8, 12)}`
|
||||
}
|
||||
}
|
||||
|
||||
},
|
||||
|
||||
}]
|
||||
}
|
||||
|
||||
series={[
|
||||
|
||||
{ dataKey: 'count', label: 'Nb Inscrits', valueFormatter_count, color: '#1a75ff', },
|
||||
|
||||
]}
|
||||
{...chartSetting}
|
||||
margin={{ right: 15, left: 100 }}
|
||||
|
||||
|
||||
/>
|
||||
</div>
|
||||
}
|
||||
|
||||
<hr className="hr_break" />
|
||||
<br />
|
||||
|
||||
|
||||
{Getall_Qry_Formation_Session_result_JSON && Getall_Qry_Formation_Session_result_JSON.length > 0 &&
|
||||
Getall_Qry_Formation_Session_result_JSON[0].data &&
|
||||
<div>
|
||||
<div className="titre1"> Les Sessions de formation </div>
|
||||
|
||||
<div className="parent_group_by">
|
||||
|
||||
<Button variant="outlined" onClick={display_session_by_periode} className="detail_class_submenu" id='montbd' name='montbd' > Par Période </Button>
|
||||
<Button variant="outlined" onClick={display_session_by_formation} className="detail_class_submenu" id='rapport_activite' name='rapport_activite' >Par Ftion </Button>
|
||||
<Button variant="outlined" onClick={display_session_by_periode_cumule} className="detail_class_submenu" id='rapport_activite' name='rapport_activite' >Par période (Cumulé) </Button>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<BarChart
|
||||
|
||||
dataset={Getall_Qry_Formation_Session_result_JSON[0].data}
|
||||
// xAxis={[{ scaleType: 'band', dataKey: 'label', tickPlacement: 'middle' }]}
|
||||
xAxis={[{
|
||||
scaleType: 'band', dataKey: 'label', tickPlacement: 'middle',
|
||||
valueFormatter: (month, context) => {
|
||||
if (month) {
|
||||
if (String(month).length < 4) {
|
||||
return `${month.slice(0, 4)}`
|
||||
}
|
||||
|
||||
else if (String(month).length >= 4 && String(month).length <= 8) {
|
||||
return `${month.slice(0, 4)}` + " \n" + `${month.slice(4, String(month).length)}`
|
||||
}
|
||||
|
||||
else if (String(month).length > 8) {
|
||||
return `${month.slice(0, 4)}` + " \n" + `${month.slice(4, 8)}` + " \n" + `${month.slice(8, 12)}`
|
||||
}
|
||||
}
|
||||
},
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
series={[
|
||||
|
||||
{ dataKey: 'count', label: 'Nb Sessions', valueFormatter_count, color: '#00802b', },
|
||||
|
||||
]}
|
||||
{...chartSetting}
|
||||
margin={{ right: 15, left: 100 }}
|
||||
|
||||
|
||||
/>
|
||||
</div>
|
||||
}
|
||||
|
||||
<hr className="hr_break" />
|
||||
<br />
|
||||
|
||||
{Getall_Qry_Session_Taux_Remplissage_result_JSON[0] && Getall_Qry_Session_Taux_Remplissage_result_JSON[0].taux_replissage &&
|
||||
Getall_Qry_Session_Taux_Remplissage_result_JSON[0].taux_non_replissage &&
|
||||
<div>
|
||||
<div className="titre1"> Taux de remplissage des sessions </div>
|
||||
<Box >
|
||||
|
||||
|
||||
|
||||
<BarChart
|
||||
|
||||
|
||||
series={[
|
||||
{ ...Getall_Qry_Session_Taux_Remplissage_result_JSON[0].taux_replissage, stack: 'total', color: '#00802b', },
|
||||
{ ...Getall_Qry_Session_Taux_Remplissage_result_JSON[0].taux_non_replissage, stack: 'total', color: '#ffcc00', },
|
||||
|
||||
]}
|
||||
|
||||
xAxis={[{
|
||||
data: Getall_Qry_Session_Taux_Remplissage_result_JSON[0].axis_data, tickPlacement: 'middle',
|
||||
scaleType: 'band',
|
||||
valueFormatter: (month, context) => {
|
||||
|
||||
if (month) {
|
||||
if (String(month).length < 4) {
|
||||
return `${month.slice(0, 4)}`
|
||||
}
|
||||
|
||||
else if (String(month).length >= 4 && String(month).length <= 8) {
|
||||
return `${month.slice(0, 4)}` + " \n" + `${month.slice(4, String(month).length)}`
|
||||
}
|
||||
|
||||
else if (String(month).length > 8) {
|
||||
return `${month.slice(0, 4)}` + " \n" + `${month.slice(4, 8)}` + " \n" + `${month.slice(8, 12)}`
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}]}
|
||||
{...chartSetting_V2}
|
||||
margin={{ right: 15, left: 100 }}
|
||||
|
||||
|
||||
/>
|
||||
|
||||
|
||||
</Box>
|
||||
</div>}
|
||||
|
||||
</div>
|
||||
|
||||
</Box>
|
||||
|
||||
|
||||
</div>}
|
||||
|
||||
{String(submenu) === String("montbd") && <div style={{ "border": "None" }}>
|
||||
|
||||
<h3> Mon tableau de bord </h3>
|
||||
|
||||
<div className="div_row"> </div>
|
||||
|
@ -305,7 +1196,8 @@ const Mon_Tableau_De_Bord = (props) => {
|
|||
|
||||
</div>}
|
||||
|
||||
|
||||
</div>}
|
||||
</div>
|
||||
|
||||
</div>
|
||||
)
|
||||
|
|
|
@ -64,17 +64,17 @@ const Partner_Commande = (props) => {
|
|||
var date_today_90j = new Date();
|
||||
date_today_90j.setDate(date_today_90j.getDate() + 90);
|
||||
|
||||
const [p_filtre1, setp_filtre1] = useState();
|
||||
const [p_filtre1_value, setp_filtre1_value] = useState();
|
||||
const [p_filtre1, setp_filtre1] = useState("");
|
||||
const [p_filtre1_value, setp_filtre1_value] = useState("");
|
||||
|
||||
const [p_filtre2, setp_filtre2] = useState();
|
||||
const [p_filtre2_value, setp_filtre2_value] = useState();
|
||||
const [p_filtre2, setp_filtre2] = useState("");
|
||||
const [p_filtre2_value, setp_filtre2_value] = useState("");
|
||||
|
||||
const [p_filtre3, setp_filtre3] = useState();
|
||||
const [p_filtre3_value, setp_filtre3_value] = useState();
|
||||
const [p_filtre3, setp_filtre3] = useState("");
|
||||
const [p_filtre3_value, setp_filtre3_value] = useState("");
|
||||
|
||||
const [p_filtre4, setp_filtre4] = useState();
|
||||
const [p_filtre4_value, setp_filtre4_value] = useState();
|
||||
const [p_filtre4, setp_filtre4] = useState("");
|
||||
const [p_filtre4_value, setp_filtre4_value] = useState("");
|
||||
|
||||
function ExpandableCell_50({ value }) {
|
||||
const [expanded, setExpanded] = React.useState(false);
|
||||
|
@ -460,16 +460,16 @@ const Partner_Commande = (props) => {
|
|||
|
||||
|
||||
function clean_all_filters() {
|
||||
setp_filtre1();
|
||||
setp_filtre1("");
|
||||
setp_filtre1_value();
|
||||
|
||||
setp_filtre2();
|
||||
setp_filtre2("");
|
||||
setp_filtre2_value();
|
||||
|
||||
setp_filtre3();
|
||||
setp_filtre3("");
|
||||
setp_filtre3_value();
|
||||
|
||||
setp_filtre4();
|
||||
setp_filtre4("");
|
||||
setp_filtre4_value();
|
||||
|
||||
clean_order_detail_fields();
|
||||
|
@ -482,6 +482,8 @@ const Partner_Commande = (props) => {
|
|||
setselectionModel_order_lines([]);
|
||||
|
||||
Getall_Parter_Orders_No_Filter();
|
||||
|
||||
setgridline_id("");
|
||||
}
|
||||
|
||||
|
||||
|
@ -3820,6 +3822,16 @@ const Partner_Commande = (props) => {
|
|||
};
|
||||
|
||||
|
||||
const New_Option_Filter = [
|
||||
{ "id": "ref_interne", "label": "Ref. Interne", "value": "ref_interne" },
|
||||
{ "id": "ref_externe", "label": "Ref. Externe (chez le client)", "value": "ref_externe" },
|
||||
{ "id": "client_nom", "label": "Nom Client", "value": "client_nom" },
|
||||
{ "id": "formation", "label": "Lié à la Formation (code externe)", "value": "formation" },
|
||||
{ "id": "code_session", "label": "Lié à la session (code session)", "value": "code_session" },
|
||||
{ "id": "", "label": "", "value": "" },
|
||||
{ "id": "1", "label": "", "value": "1" }, // Cette ligne pour couvrir l'ajout d'une ligne de filter. C'est fait expres.
|
||||
]
|
||||
|
||||
|
||||
return (
|
||||
|
||||
|
@ -4661,7 +4673,7 @@ const Partner_Commande = (props) => {
|
|||
<div className="titre1"> Utilisez les filtres !</div>
|
||||
<div className="div_row" style={{ "marginBottom": "5px" }}>
|
||||
<div className="div_row_gauche texte_area_filter" >
|
||||
<TextField
|
||||
{/* <TextField
|
||||
name="filtre1"
|
||||
label="Choisir un champ"
|
||||
select
|
||||
|
@ -4680,6 +4692,31 @@ const Partner_Commande = (props) => {
|
|||
|
||||
|
||||
</TextField>
|
||||
|
||||
*/}
|
||||
|
||||
{New_Option_Filter && New_Option_Filter.length > 0 && <Autocomplete
|
||||
disablePortal
|
||||
name="filtre1"
|
||||
id="filtre1"
|
||||
className="disabled_style"
|
||||
value={New_Option_Filter.filter((data) => (data).value === String(p_filtre1))[0].label}
|
||||
options={New_Option_Filter}
|
||||
onChange={(event, value) => {
|
||||
if (value && value.value) {
|
||||
setp_filtre1(value.value);
|
||||
}else{
|
||||
setp_filtre1("");
|
||||
}
|
||||
|
||||
}}
|
||||
|
||||
renderInput={(params) => <TextField {...params} label="" placeholder="Choisir une option"
|
||||
inputProps={{ ...params.inputProps, style: { fontSize: 12, height: "1.4rem" } }}
|
||||
|
||||
/>
|
||||
}
|
||||
/>}
|
||||
</div>
|
||||
|
||||
|
||||
|
@ -4728,7 +4765,7 @@ const Partner_Commande = (props) => {
|
|||
<Tooltip className="tooltip_css" id="my-tooltip02" style={{ "fontSize": "12px" }} />
|
||||
<a data-tooltip-id="my-tooltip02" data-tooltip-html="Supprimer cette ligne de filtre">
|
||||
<MdRemoveCircleOutline onClick={(e) => {
|
||||
setp_filtre1();
|
||||
setp_filtre1("");
|
||||
setp_filtre1_value();
|
||||
}}
|
||||
/>
|
||||
|
@ -4741,25 +4778,27 @@ const Partner_Commande = (props) => {
|
|||
{p_filtre2 &&
|
||||
<div className="div_row" style={{ "marginBottom": "5px" }}>
|
||||
<div className="div_row_gauche texte_area_filter">
|
||||
<TextField
|
||||
{New_Option_Filter && New_Option_Filter.length > 0 && <Autocomplete
|
||||
disablePortal
|
||||
name="filtre2"
|
||||
label="Choisir un champ"
|
||||
select
|
||||
sx={{ m: 1, width: '100%' }}
|
||||
id="filtre2"
|
||||
className="disabled_style"
|
||||
value={New_Option_Filter.filter((data) => (data).value === String(p_filtre2))[0].label}
|
||||
options={New_Option_Filter}
|
||||
onChange={(event, value) => {
|
||||
if (value && value.value) {
|
||||
setp_filtre2(value.value);
|
||||
|
||||
value={p_filtre2}
|
||||
onChange={(e) => {
|
||||
setp_filtre2(e.target.value);
|
||||
}
|
||||
|
||||
}}
|
||||
>
|
||||
<MenuItem value="ref_interne" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Ref. Interne </MenuItem>
|
||||
<MenuItem value="ref_externe" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Ref. Externe (chez le client) </MenuItem>
|
||||
<MenuItem value="client_nom" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Nom Client </MenuItem>
|
||||
<MenuItem value="formation" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Lié a la Formation (code externe) </MenuItem>
|
||||
<MenuItem value="code_session" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Lié à la session (code session) </MenuItem>
|
||||
|
||||
</TextField>
|
||||
renderInput={(params) => <TextField {...params} label="" placeholder="Choisir une option"
|
||||
inputProps={{ ...params.inputProps, style: { fontSize: 12, height: "1.4rem" } }}
|
||||
|
||||
/>
|
||||
}
|
||||
/>}
|
||||
</div>
|
||||
<div className="div_row_droite texte_area_filter_value" style={{ "marginTop": "0.5rem" }}>
|
||||
{String(p_filtre2).length > 2 &&
|
||||
|
@ -4808,7 +4847,7 @@ const Partner_Commande = (props) => {
|
|||
<a data-tooltip-id="my-tooltip04" data-tooltip-html="Supprimer cette ligne de filtre">
|
||||
<MdRemoveCircleOutline
|
||||
onClick={(e) => {
|
||||
setp_filtre2();
|
||||
setp_filtre2("");
|
||||
setp_filtre2_value();
|
||||
}}
|
||||
/>
|
||||
|
@ -4822,24 +4861,27 @@ const Partner_Commande = (props) => {
|
|||
{p_filtre3 &&
|
||||
<div className="div_row" style={{ "marginBottom": "5px" }}>
|
||||
<div className="div_row_gauche texte_area_filter">
|
||||
<TextField
|
||||
{New_Option_Filter && New_Option_Filter.length > 0 && <Autocomplete
|
||||
disablePortal
|
||||
name="filtre3"
|
||||
label="Choisir un champ"
|
||||
select
|
||||
sx={{ m: 1, width: '100%' }}
|
||||
id="filtre3"
|
||||
className="disabled_style"
|
||||
value={New_Option_Filter.filter((data) => (data).value === String(p_filtre3))[0].label}
|
||||
options={New_Option_Filter}
|
||||
onChange={(event, value) => {
|
||||
if (value && value.value) {
|
||||
setp_filtre3(value.value);
|
||||
|
||||
}
|
||||
|
||||
value={p_filtre3}
|
||||
onChange={(e) => {
|
||||
setp_filtre3(e.target.value)
|
||||
}}
|
||||
>
|
||||
<MenuItem value="ref_interne" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Ref. Interne </MenuItem>
|
||||
<MenuItem value="ref_externe" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Ref. Externe (chez le client) </MenuItem>
|
||||
<MenuItem value="client_nom" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Nom Client </MenuItem>
|
||||
<MenuItem value="formation" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Lié a la Formation (code externe) </MenuItem>
|
||||
<MenuItem value="code_session" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Lié à la session (code session) </MenuItem>
|
||||
|
||||
</TextField>
|
||||
renderInput={(params) => <TextField {...params} label="" placeholder="Choisir une option"
|
||||
inputProps={{ ...params.inputProps, style: { fontSize: 12, height: "1.4rem" } }}
|
||||
|
||||
/>
|
||||
}
|
||||
/>}
|
||||
</div>
|
||||
<div className="div_row_droite texte_area_filter_value" style={{ "marginTop": "0.5rem" }}>
|
||||
{String(p_filtre3).length > 2 &&
|
||||
|
@ -4887,7 +4929,7 @@ const Partner_Commande = (props) => {
|
|||
<Tooltip className="tooltip_css" id="my-tooltip05" style={{ "fontSize": "12px" }} />
|
||||
<a data-tooltip-id="my-tooltip05" data-tooltip-html="Supprimer cette ligne de filtre">
|
||||
<MdRemoveCircleOutline onClick={(e) => {
|
||||
setp_filtre3();
|
||||
setp_filtre3("");
|
||||
setp_filtre3_value();
|
||||
}} />
|
||||
</a>
|
||||
|
|
|
@ -974,14 +974,14 @@ const Partner_Config_Formulaires = (props) => {
|
|||
const [selected_question_id, setselected_question_id] = useState("");
|
||||
const [question_question, setquestion_question] = useState("");
|
||||
const [question_type, setquestion_type] = useState("");
|
||||
const [question_max_note, setquestion_max_note] = useState("");
|
||||
const [question_max_note, setquestion_max_note] = useState("2");
|
||||
|
||||
|
||||
function Ajouter_Question() {
|
||||
setselected_question_id("");
|
||||
setquestion_question("");
|
||||
setquestion_type("");
|
||||
setquestion_max_note("");
|
||||
setquestion_max_note("2");
|
||||
setDialog_Question_open(true);
|
||||
|
||||
settab_qcm_choix([]);
|
||||
|
@ -1012,6 +1012,20 @@ const Partner_Config_Formulaires = (props) => {
|
|||
form.append("type", question_type);
|
||||
form.append("max_note", question_max_note);
|
||||
|
||||
if (String(question_type) === "note") {
|
||||
|
||||
if( String(question_max_note) === ""){
|
||||
alert(" La note maximale doit être un entier supérieur à 1");
|
||||
return;
|
||||
}
|
||||
|
||||
if (isNaN(Number(question_max_note))) {
|
||||
alert(" La note maximale doit être un entier supérieur à 1");
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if (statistic_checked === true) {
|
||||
form.append("is_statistic", "1");
|
||||
} else {
|
||||
|
@ -1062,7 +1076,7 @@ const Partner_Config_Formulaires = (props) => {
|
|||
setselected_question_id("");
|
||||
setquestion_question("");
|
||||
setquestion_type("");
|
||||
setquestion_max_note("");
|
||||
setquestion_max_note("2");
|
||||
settab_qcm_choix([]);
|
||||
setadd_new_qcm_choix("");
|
||||
setnew_qcm_choix_value("");
|
||||
|
@ -1144,7 +1158,7 @@ const Partner_Config_Formulaires = (props) => {
|
|||
setselected_question_id("");
|
||||
setquestion_question("");
|
||||
setquestion_type("");
|
||||
setquestion_max_note("");
|
||||
setquestion_max_note("2");
|
||||
|
||||
Get_Given_Formulaire_Data(selected_id);
|
||||
|
||||
|
@ -1322,10 +1336,14 @@ const Partner_Config_Formulaires = (props) => {
|
|||
name="field_question_question"
|
||||
|
||||
fullWidth
|
||||
type="intger"
|
||||
type="number"
|
||||
InputProps={{ inputProps: { min: 2, max: 21 } }}
|
||||
value={question_max_note}
|
||||
onChange={(e) => {
|
||||
|
||||
if (!isNaN(Number((e.target.value)))) {
|
||||
setquestion_max_note(e.target.value);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
@ -32,7 +32,7 @@ import { Typography, LinearProgress, sliderClasses } from '@mui/material';
|
|||
import styled from 'styled-components';
|
||||
import { CiTrash } from "react-icons/ci";
|
||||
import { MdAddCircleOutline, MdRemoveCircleOutline } from "react-icons/md";
|
||||
|
||||
import Autocomplete from '@mui/material/Autocomplete';
|
||||
import img_loading_spin from "./../mysy_img/mysy_spin_loading.gif";
|
||||
import { IoAddCircleOutline, IoCloseCircleOutline } from "react-icons/io5";
|
||||
import Dialog from '@mui/material/Dialog';
|
||||
|
@ -119,16 +119,16 @@ const Partner_Facture = (props) => {
|
|||
var date_today_90j = new Date();
|
||||
date_today_90j.setDate(date_today_90j.getDate() + 90);
|
||||
|
||||
const [p_filtre1, setp_filtre1] = useState();
|
||||
const [p_filtre1, setp_filtre1] = useState("");
|
||||
const [p_filtre1_value, setp_filtre1_value] = useState();
|
||||
|
||||
const [p_filtre2, setp_filtre2] = useState();
|
||||
const [p_filtre2, setp_filtre2] = useState("");
|
||||
const [p_filtre2_value, setp_filtre2_value] = useState();
|
||||
|
||||
const [p_filtre3, setp_filtre3] = useState();
|
||||
const [p_filtre3, setp_filtre3] = useState("");
|
||||
const [p_filtre3_value, setp_filtre3_value] = useState();
|
||||
|
||||
const [p_filtre4, setp_filtre4] = useState();
|
||||
const [p_filtre4, setp_filtre4] = useState("");
|
||||
const [p_filtre4_value, setp_filtre4_value] = useState();
|
||||
|
||||
function ExpandableCell_50({ value }) {
|
||||
|
@ -1492,6 +1492,8 @@ const Partner_Facture = (props) => {
|
|||
const [Getall_Parter_Invoice_With_Filter_result, setGetall_Parter_Invoice_With_Filter_result] = useState();
|
||||
function Getall_Parter_Invoice_With_Filter(event) {
|
||||
|
||||
setgridline_id("");
|
||||
|
||||
var form = new FormData();
|
||||
|
||||
// Recuperation des parametres
|
||||
|
@ -1958,16 +1960,16 @@ const Partner_Facture = (props) => {
|
|||
|
||||
|
||||
function clean_all_filters() {
|
||||
setp_filtre1();
|
||||
setp_filtre1("");
|
||||
setp_filtre1_value();
|
||||
|
||||
setp_filtre2();
|
||||
setp_filtre2("");
|
||||
setp_filtre2_value();
|
||||
|
||||
setp_filtre3();
|
||||
setp_filtre3("");
|
||||
setp_filtre3_value();
|
||||
|
||||
setp_filtre4();
|
||||
setp_filtre4("");
|
||||
setp_filtre4_value();
|
||||
|
||||
clean_order_detail_fields();
|
||||
|
@ -1978,6 +1980,8 @@ const Partner_Facture = (props) => {
|
|||
|
||||
Getall_Parter_Invoice_No_Filter();
|
||||
setdisplay_detail_invoice();
|
||||
|
||||
setgridline_id("");
|
||||
}
|
||||
|
||||
function clean_order_detail_fields() {
|
||||
|
@ -2359,7 +2363,15 @@ const Partner_Facture = (props) => {
|
|||
}
|
||||
|
||||
|
||||
|
||||
const New_Option_Filter = [
|
||||
{ "id": "ref_interne_invoice", "label": "Num Facture", "value": "ref_interne_invoice" },
|
||||
{ "id": "ref_interne_cmd", "label": "Ref. Interne Cmd", "value": "ref_interne_cmd" },
|
||||
{ "id": "ref_externe", "label": "Ref. Externe Cmd (chez le client)", "value": "ref_externe" },
|
||||
{ "id": "client_nom", "label": "Nom Client", "value": "client_nom" },
|
||||
{ "id": "formation", "label": "Lié a la Formation (code externe)", "value": "formation" },
|
||||
{ "id": "", "label": "", "value": "" },
|
||||
{ "id": "1", "label": "", "value": "1" }, // Cette ligne pour couvrir l'ajout d'une ligne de filter. C'est fait expres.
|
||||
]
|
||||
|
||||
|
||||
return (
|
||||
|
@ -2781,25 +2793,32 @@ const Partner_Facture = (props) => {
|
|||
<div className="titre1"> Utilisez les filtres !</div>
|
||||
<div className="div_row" style={{ "marginBottom": "5px" }}>
|
||||
<div className="div_row_gauche texte_area_filter" >
|
||||
<TextField
|
||||
|
||||
|
||||
{New_Option_Filter && New_Option_Filter.length > 0 && <Autocomplete
|
||||
disablePortal
|
||||
name="filtre1"
|
||||
label="Choisir un champ"
|
||||
select
|
||||
sx={{ m: 1, width: '100%' }}
|
||||
value={p_filtre1}
|
||||
onChange={(e) => {
|
||||
setp_filtre1(e.target.value);
|
||||
id="filtre1"
|
||||
className="disabled_style"
|
||||
value={New_Option_Filter.filter((data) => (data).value === String(p_filtre1))[0].label}
|
||||
options={New_Option_Filter}
|
||||
onChange={(event, value) => {
|
||||
if (value && value.value) {
|
||||
setp_filtre1(value.value);
|
||||
}else{
|
||||
setp_filtre1("");
|
||||
}
|
||||
|
||||
}}
|
||||
>
|
||||
<MenuItem value="ref_interne_invoice" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Num Facture </MenuItem>
|
||||
<MenuItem value="ref_interne_cmd" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Ref. Interne Cmd </MenuItem>
|
||||
<MenuItem value="ref_externe" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Ref. Externe Cmd (chez le client) </MenuItem>
|
||||
<MenuItem value="client_nom" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Nom Client </MenuItem>
|
||||
<MenuItem value="formation" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Lié a la Formation (code externe) </MenuItem>
|
||||
|
||||
renderInput={(params) => <TextField {...params} label="" placeholder="Choisir une option"
|
||||
inputProps={{ ...params.inputProps, style: { fontSize: 12, height: "1.4rem" } }}
|
||||
|
||||
/>
|
||||
}
|
||||
/>}
|
||||
|
||||
|
||||
</TextField>
|
||||
</div>
|
||||
|
||||
|
||||
|
@ -2848,7 +2867,7 @@ const Partner_Facture = (props) => {
|
|||
<Tooltip className="tooltip_css" id="my-tooltip02" style={{ "fontSize": "12px" }} />
|
||||
<a data-tooltip-id="my-tooltip02" data-tooltip-html="Supprimer cette ligne de filtre">
|
||||
<MdRemoveCircleOutline onClick={(e) => {
|
||||
setp_filtre1();
|
||||
setp_filtre1("");
|
||||
setp_filtre1_value();
|
||||
}}
|
||||
/>
|
||||
|
@ -2861,25 +2880,27 @@ const Partner_Facture = (props) => {
|
|||
{p_filtre2 &&
|
||||
<div className="div_row" style={{ "marginBottom": "5px" }}>
|
||||
<div className="div_row_gauche texte_area_filter">
|
||||
<TextField
|
||||
{New_Option_Filter && New_Option_Filter.length > 0 && <Autocomplete
|
||||
disablePortal
|
||||
name="filtre2"
|
||||
label="Choisir un champ"
|
||||
select
|
||||
sx={{ m: 1, width: '100%' }}
|
||||
id="filtre2"
|
||||
className="disabled_style"
|
||||
value={New_Option_Filter.filter((data) => (data).value === String(p_filtre2))[0].label}
|
||||
options={New_Option_Filter}
|
||||
onChange={(event, value) => {
|
||||
if (value && value.value) {
|
||||
setp_filtre2(value.value);
|
||||
|
||||
value={p_filtre2}
|
||||
onChange={(e) => {
|
||||
setp_filtre2(e.target.value);
|
||||
}
|
||||
|
||||
}}
|
||||
>
|
||||
<MenuItem value="ref_interne_invoice" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Num Facture </MenuItem>
|
||||
<MenuItem value="ref_interne_cmd" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Ref. Interne Cmd </MenuItem>
|
||||
<MenuItem value="ref_externe" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Ref. Externe Cmd (chez le client) </MenuItem>
|
||||
<MenuItem value="client_nom" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Nom Client </MenuItem>
|
||||
<MenuItem value="formation" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Lié a la Formation (code externe) </MenuItem>
|
||||
|
||||
</TextField>
|
||||
renderInput={(params) => <TextField {...params} label="" placeholder="Choisir une option"
|
||||
inputProps={{ ...params.inputProps, style: { fontSize: 12, height: "1.4rem" } }}
|
||||
|
||||
/>
|
||||
}
|
||||
/>}
|
||||
</div>
|
||||
<div className="div_row_droite texte_area_filter_value" style={{ "marginTop": "0.5rem" }}>
|
||||
{String(p_filtre2).length > 2 &&
|
||||
|
@ -2928,7 +2949,7 @@ const Partner_Facture = (props) => {
|
|||
<a data-tooltip-id="my-tooltip04" data-tooltip-html="Supprimer cette ligne de filtre">
|
||||
<MdRemoveCircleOutline
|
||||
onClick={(e) => {
|
||||
setp_filtre2();
|
||||
setp_filtre2("");
|
||||
setp_filtre2_value();
|
||||
}}
|
||||
/>
|
||||
|
@ -2942,25 +2963,27 @@ const Partner_Facture = (props) => {
|
|||
{p_filtre3 &&
|
||||
<div className="div_row" style={{ "marginBottom": "5px" }}>
|
||||
<div className="div_row_gauche texte_area_filter">
|
||||
<TextField
|
||||
{New_Option_Filter && New_Option_Filter.length > 0 && <Autocomplete
|
||||
disablePortal
|
||||
name="filtre3"
|
||||
label="Choisir un champ"
|
||||
select
|
||||
sx={{ m: 1, width: '100%' }}
|
||||
id="filtre3"
|
||||
className="disabled_style"
|
||||
value={New_Option_Filter.filter((data) => (data).value === String(p_filtre3))[0].label}
|
||||
options={New_Option_Filter}
|
||||
onChange={(event, value) => {
|
||||
if (value && value.value) {
|
||||
setp_filtre3(value.value);
|
||||
|
||||
}
|
||||
|
||||
value={p_filtre3}
|
||||
onChange={(e) => {
|
||||
setp_filtre3(e.target.value)
|
||||
}}
|
||||
>
|
||||
<MenuItem value="ref_interne_invoice" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Num Facture </MenuItem>
|
||||
<MenuItem value="ref_interne_cmd" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Ref. Interne Cmd </MenuItem>
|
||||
<MenuItem value="ref_externe" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Ref. Externe Cmd (chez le client) </MenuItem>
|
||||
<MenuItem value="client_nom" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Nom Client </MenuItem>
|
||||
<MenuItem value="formation" style={{ "paddingLeft": "5px", "textAlign": "left", "width": "100%" }} >Lié a la Formation (code externe) </MenuItem>
|
||||
|
||||
renderInput={(params) => <TextField {...params} label="" placeholder="Choisir une option"
|
||||
inputProps={{ ...params.inputProps, style: { fontSize: 12, height: "1.4rem" } }}
|
||||
|
||||
</TextField>
|
||||
/>
|
||||
}
|
||||
/>}
|
||||
</div>
|
||||
<div className="div_row_droite texte_area_filter_value" style={{ "marginTop": "0.5rem" }}>
|
||||
{String(p_filtre3).length > 2 &&
|
||||
|
@ -3008,7 +3031,7 @@ const Partner_Facture = (props) => {
|
|||
<Tooltip className="tooltip_css" id="my-tooltip05" style={{ "fontSize": "12px" }} />
|
||||
<a data-tooltip-id="my-tooltip05" data-tooltip-html="Supprimer cette ligne de filtre">
|
||||
<MdRemoveCircleOutline onClick={(e) => {
|
||||
setp_filtre3();
|
||||
setp_filtre3("");
|
||||
setp_filtre3_value();
|
||||
}} />
|
||||
</a>
|
||||
|
@ -3037,8 +3060,6 @@ const Partner_Facture = (props) => {
|
|||
|
||||
<div className="div_row" style={{ "border": "None", paddingRight: '10px' }}>
|
||||
|
||||
|
||||
|
||||
<div className="session_data">
|
||||
<div style={{ "border": "None" }}>
|
||||
<div style={{ height: 550, width: '100%', paddingRight: '5px' }}>
|
||||
|
|
|
@ -320,7 +320,9 @@ function SurveyDocument() {
|
|||
</div>}
|
||||
|
||||
{String(JSON.parse(get_Given_Survey_Data_result).survey_type) === "human_eval" && <div className="question_box_entete">
|
||||
Questionnaire d'évaluation
|
||||
Questionnaire d'évaluation pour le formateur <b> {JSON.parse(get_Given_Survey_Data_result).related_rh_data_civilite && JSON.parse(get_Given_Survey_Data_result).related_rh_data_civilite}.
|
||||
{JSON.parse(get_Given_Survey_Data_result).related_rh_data_nom && JSON.parse(get_Given_Survey_Data_result).related_rh_data_nom}
|
||||
{JSON.parse(get_Given_Survey_Data_result).related_rh_data_prenom && JSON.parse(get_Given_Survey_Data_result).related_rh_data_prenom} </b>
|
||||
</div>}
|
||||
|
||||
{String(JSON.parse(get_Given_Survey_Data_result).survey_type) === "autre_eval" && <div className="question_box_entete">
|
||||
|
|
|
@ -2372,7 +2372,6 @@
|
|||
|
||||
|
||||
.mode_affichage_selected {
|
||||
|
||||
text-underline-offset: 8px;
|
||||
text-decoration: green wavy underline;
|
||||
text-decoration-color: #F8C471;
|
||||
|
|
|
@ -153,6 +153,7 @@
|
|||
letter-spacing: 0.1rem;
|
||||
font-weight: normal;
|
||||
width: 100%;
|
||||
height: 2rem !important;
|
||||
}
|
||||
|
||||
.detail_class_submenu:hover:active,
|
||||
|
@ -751,6 +752,9 @@
|
|||
font-size: small;
|
||||
letter-spacing: 0.1rem;
|
||||
font-weight: normal;
|
||||
height: 2rem !important;
|
||||
font-size: 11px;
|
||||
min-width: 12rem;
|
||||
}
|
||||
|
||||
.detail_class_submenu:hover:active,
|
||||
|
@ -1404,6 +1408,9 @@
|
|||
font-size: small;
|
||||
letter-spacing: 0.1rem;
|
||||
font-weight: normal;
|
||||
height: 2rem !important;
|
||||
font-size: 11px;
|
||||
min-width: 13rem;
|
||||
}
|
||||
|
||||
.detail_class_submenu:hover:active,
|
||||
|
@ -1944,6 +1951,9 @@
|
|||
font-size: small;
|
||||
letter-spacing: 0.1rem;
|
||||
font-weight: normal;
|
||||
height: 2rem !important;
|
||||
font-size: 11px;
|
||||
min-width: 15rem;
|
||||
}
|
||||
|
||||
.detail_class_submenu:hover:active,
|
||||
|
@ -2500,10 +2510,61 @@
|
|||
top: -13px;
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
// end media
|
||||
|
||||
.css-10lpdtz-MuiResponsiveChart-container {
|
||||
svg{
|
||||
width: 90% !important;
|
||||
}
|
||||
}
|
||||
|
||||
.parent_group_by {
|
||||
width: 80%;
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
margin-top: 15px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.parent_group_by_div1 {
|
||||
grid-area: 1 / 1 / 2 / 2;
|
||||
}
|
||||
|
||||
.parent_group_by_div2 {
|
||||
grid-area: 1 / 2 / 2 / 3;
|
||||
cursor: pointer;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.parent_group_by_div3 {
|
||||
grid-area: 1 / 3 / 2 / 4;
|
||||
cursor: pointer;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.parent_group_by_div4 {
|
||||
grid-area: 1 / 4 / 2 / 5;
|
||||
cursor: pointer;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.parent_group_by_div1_selected {
|
||||
text-underline-offset: 8px;
|
||||
text-decoration: green wavy underline;
|
||||
text-decoration-color: #F8C471;
|
||||
text-decoration-style: solid;
|
||||
text-decoration-thickness: 5px;
|
||||
background: #F4F6F6;
|
||||
box-shadow: 1px 1px 5px 1px rgba(0, 0, 0, 0.1);
|
||||
border-radius: 5px;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.css-md26zr-MuiInputBase-root-MuiOutlinedInput-root {
|
||||
height: 3rem !important;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue