sdfs
parent
1bc8417f9c
commit
8e2d53633c
|
@ -4101,7 +4101,7 @@ const AddClassManual = (props) => {
|
|||
</div>
|
||||
|
||||
<div className="row_block zone_gestion_admin">
|
||||
<Button variant="contained" color="success" className="bton_gestion_admin"
|
||||
{/* <Button variant="contained" color="success" className="bton_gestion_admin"
|
||||
|
||||
onClick={(e) => {
|
||||
e.preventDefault();
|
||||
|
@ -4113,7 +4113,7 @@ const AddClassManual = (props) => {
|
|||
}}>
|
||||
|
||||
GESTION ADMINISTRATIVE <GrUserAdmin />
|
||||
</Button>
|
||||
</Button>*/}
|
||||
</div>
|
||||
|
||||
|
||||
|
|
|
@ -4837,7 +4837,6 @@ const Apprenant = (props) => {
|
|||
|
||||
function CustomToolbar(props) {
|
||||
|
||||
console.log(" my props = ", props);
|
||||
|
||||
return (
|
||||
<GridToolbarContainer {...props}>
|
||||
|
|
|
@ -1614,6 +1614,55 @@ const DisplayPartnerSession = (props) => {
|
|||
}
|
||||
|
||||
|
||||
// lorsqu'on rentre dans ce fichier avec une formation, il faut aller chercher toutes sessions de la formation zzz
|
||||
|
||||
const [Getall_TrainingSession_For_Given_Class_api, setGetall_TrainingSession_For_Given_Class_api] = useState();
|
||||
const [Getall_TrainingSession_For_Given_Class_message, setGetall_TrainingSession_For_Given_Class_message] = useState();
|
||||
const [Getall_TrainingSession_For_Given_Class_result, setGetall_TrainingSession_For_Given_Class_result] = useState();
|
||||
function Getall_TrainingSession_For_Given_Class(props_class_internal_url) {
|
||||
|
||||
var form = new FormData();
|
||||
const stored_cookie = getCookie('tokenmysypart');
|
||||
form.append("token", stored_cookie);
|
||||
|
||||
// Recuperation des parametres
|
||||
var filtre1 = "class_internal_url"
|
||||
var filtre1_value = props_class_internal_url;
|
||||
form.append(filtre1, filtre1_value);
|
||||
|
||||
var myurl = process.env.REACT_APP_API_URL + "myclass/api/GetAllValideSessionPartner_List_filter_like/";
|
||||
|
||||
|
||||
|
||||
setLoading(true);
|
||||
axios.post(myurl, form).then(res => {
|
||||
|
||||
if (String(res.data.status) === String("true")) {
|
||||
//console.log(" In Getall_TrainingSession_For_Given_Class res.data.status = " + res.data.status);
|
||||
// console.log(" In Getall_TrainingSession_For_Given_Class res.data.message r_class = " + res.data.message);
|
||||
setGetall_TrainingSession_For_Given_Class_api("true");
|
||||
setGetall_TrainingSession_For_Given_Class_result(res.data.message);
|
||||
setRows(res.data.message);
|
||||
}
|
||||
else {
|
||||
setGetall_TrainingSession_For_Given_Class_api("false");
|
||||
setGetall_TrainingSession_For_Given_Class_message(res.data.message);
|
||||
alert(res.data.message)
|
||||
}
|
||||
|
||||
setLoading(false);
|
||||
}).catch((error) => {
|
||||
setLoading(false);
|
||||
console.warn('Not good man :( Getall_TrainingSession_For_Given_Class = ', error);
|
||||
setGetall_TrainingSession_For_Given_Class_api("false");
|
||||
alert("Impossible de lancer la recherche");
|
||||
//setmyApimyApiMessage("")
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
const [New_Get_List_Partner_Clients_result, setNew_Get_List_Partner_Clients_result] = useState([]);
|
||||
|
||||
const [Get_List_Partner_Clients_api, setGet_List_Partner_Clients_api] = useState();
|
||||
|
@ -1979,13 +2028,9 @@ const DisplayPartnerSession = (props) => {
|
|||
Get_Partner_Object_Specific_Fields("session_formation");
|
||||
Getall_Training_Employee_No_Filter();
|
||||
Getall_Training_Materiel_No_Filter();
|
||||
|
||||
Get_List_Partner_Financeurs();
|
||||
|
||||
Getall_Parter_OR_Default_Session_Steps();
|
||||
|
||||
GetCurrentPartnerClass();
|
||||
Getall_TrainingSession();
|
||||
GetAttestation_Certif();
|
||||
Get_List_Partner_Clients();
|
||||
Getall_Partner_Site_Formation();
|
||||
|
@ -1995,13 +2040,24 @@ const DisplayPartnerSession = (props) => {
|
|||
setdatagrid_columns_size_model2(50);
|
||||
}
|
||||
|
||||
if (props.object_key && String(props.object_key).length > 3) {
|
||||
|
||||
|
||||
if (props.object_key && String(props.object_key).length > 2) {
|
||||
|
||||
setLoading(true);
|
||||
|
||||
let text = String(props.object_key);
|
||||
|
||||
if (props.object_key === "class") {
|
||||
Getall_TrainingSession_For_Given_Class(props.class_internal_url);
|
||||
} else {
|
||||
Getall_TrainingSession();
|
||||
GetCurrentSession(props.object_key, props.class_internal_url);
|
||||
Display_session_From_Props(props.object_key, props.class_internal_url);
|
||||
}
|
||||
setLoading(false);
|
||||
} else {
|
||||
Getall_TrainingSession();
|
||||
window.scrollTo({
|
||||
top: 0,
|
||||
behavior: "smooth",
|
||||
|
|
|
@ -6557,7 +6557,6 @@ const DisplayPartnerStagiaires = (props) => {
|
|||
|
||||
function CustomToolbar(props) {
|
||||
|
||||
console.log(" my props = ", props);
|
||||
|
||||
return (
|
||||
<GridToolbarContainer {...props}>
|
||||
|
|
|
@ -51,7 +51,7 @@ import {
|
|||
GridPreferencePanelsValue,
|
||||
|
||||
} from '@mui/x-data-grid';
|
||||
import * as XLSX from 'xlsx';
|
||||
import * as XLSX from 'xlsx';
|
||||
|
||||
|
||||
const DistplayPartnerTraningsPage = (props) => {
|
||||
|
@ -408,7 +408,7 @@ const DistplayPartnerTraningsPage = (props) => {
|
|||
const [datagrid_columns_size_model2, setdatagrid_columns_size_model2] = useState(120);
|
||||
|
||||
const columns = [
|
||||
{ field: 'id', headerName: 'id', hide: true, maxWidth: 1, disableExport: true,},
|
||||
{ field: 'id', headerName: 'id', hide: true, maxWidth: 1, disableExport: true, },
|
||||
{ field: '_id', headerName: '_id', hide: true, maxWidth: 1, disableExport: true, },
|
||||
{ field: 'lms_class_code', headerName: 'lms_class_code', hide: true, Width: 0, },
|
||||
{ field: 'duration', headerName: 'duration', hide: true, Width: 0, },
|
||||
|
@ -429,7 +429,52 @@ const DistplayPartnerTraningsPage = (props) => {
|
|||
{ field: 'categorie', headerName: 'Catégorie', minWidth: 100, flex: 1, maxWidth: 200, hideable: true, hide: true, editable: false, renderCell: (params) => <Display_Colunm_text {...params} />, },
|
||||
|
||||
|
||||
{ field: 'nb_session_formation', headerName: 'Nb Session', minWidth: 50, flex: 1, maxWidth: 100, hideable: true, hide: false, editable: false, align: "center", renderCell: (params) => <Display_Colunm_text {...params} />, },
|
||||
|
||||
|
||||
|
||||
{
|
||||
field: 'nb_session_formation', headerName: 'Nb Session', minWidth: 50, flex: 1, maxWidth: 100, hideable: true, hide: false, editable: false, align: "center",
|
||||
renderCell: (cellValues) => {
|
||||
return (
|
||||
|
||||
<nav style={{ width: '100%', 'textAlign': 'center' }}>
|
||||
{String(cellValues.row.nb_session_formation).length > 0 && parseInt(String(cellValues.row.nb_session_formation)) <= 0 && <div>
|
||||
|
||||
{cellValues.row.nb_session_formation}
|
||||
|
||||
</div>}
|
||||
|
||||
{String(cellValues.row.nb_session_formation).length > 0 && parseInt(String(cellValues.row.nb_session_formation)) > 0 &&
|
||||
|
||||
<nav>
|
||||
|
||||
<Button
|
||||
|
||||
onClick={(event) => {
|
||||
window.open(
|
||||
process.env.REACT_APP_FRONT_URL + "Partner/mes_sessions/class/"+String(cellValues.row.internal_url),
|
||||
'_blank'
|
||||
);
|
||||
}}
|
||||
|
||||
variant="outlined"
|
||||
|
||||
|
||||
>
|
||||
{cellValues.row.nb_session_formation}
|
||||
|
||||
</Button>
|
||||
</nav>}
|
||||
</nav>
|
||||
|
||||
);
|
||||
},
|
||||
|
||||
|
||||
},
|
||||
|
||||
|
||||
|
||||
{ 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} />, },
|
||||
|
||||
|
@ -454,7 +499,7 @@ const DistplayPartnerTraningsPage = (props) => {
|
|||
);
|
||||
},
|
||||
},
|
||||
{
|
||||
/*{
|
||||
field: "management", headerName: 'Gestion', minWidth: 50, flex: 1, maxWidth: 100,
|
||||
renderCell: (cellValues) => {
|
||||
return (
|
||||
|
@ -471,7 +516,7 @@ const DistplayPartnerTraningsPage = (props) => {
|
|||
|
||||
);
|
||||
}
|
||||
},
|
||||
},*/
|
||||
{
|
||||
field: "visual", headerName: 'Visualiser', minWidth: 50, flex: 1, maxWidth: 100, disableExport: true,
|
||||
renderCell: (cellValues) => {
|
||||
|
@ -1766,11 +1811,11 @@ const DistplayPartnerTraningsPage = (props) => {
|
|||
]
|
||||
|
||||
|
||||
// DEBUT EXPORT EXCEL DATAGRID
|
||||
// DEBUT EXPORT EXCEL DATAGRID
|
||||
|
||||
function CustomToolbar(props) {
|
||||
|
||||
function CustomToolbar(props) {
|
||||
|
||||
console.log(" my props = ", props);
|
||||
|
||||
return (
|
||||
<GridToolbarContainer {...props}>
|
||||
|
@ -1786,9 +1831,9 @@ function CustomToolbar(props) {
|
|||
|
||||
</GridToolbarContainer>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
function getExcelData(apiRef) {
|
||||
function getExcelData(apiRef) {
|
||||
// Select rows and columns
|
||||
const filteredSortedRowIds = gridFilteredSortedRowIdsSelector(apiRef);
|
||||
const visibleColumnsField = gridVisibleColumnFieldsSelector(apiRef);
|
||||
|
@ -1803,18 +1848,18 @@ function getExcelData(apiRef) {
|
|||
});
|
||||
|
||||
return data;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
function ExportButton(props) {
|
||||
function ExportButton(props) {
|
||||
return (
|
||||
<GridToolbarExportContainer {...props}>
|
||||
<ExportMenuItem data_colums={props.data_colums} />
|
||||
</GridToolbarExportContainer>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
function handleExport(apiRef, data_colums) {
|
||||
function handleExport(apiRef, data_colums) {
|
||||
const data = getExcelData(apiRef);
|
||||
const visibleColumnsField = gridVisibleColumnFieldsSelector(apiRef);
|
||||
|
||||
|
@ -1835,7 +1880,7 @@ function handleExport(apiRef, data_colums) {
|
|||
sheetName: 'Export_' + String(new Date().toJSON().slice(0, 10)).replaceAll("-", "_"),
|
||||
};
|
||||
|
||||
local_config.columnNames = local_config.columnNames.filter(function( element ) {
|
||||
local_config.columnNames = local_config.columnNames.filter(function (element) {
|
||||
return element !== undefined;
|
||||
});
|
||||
|
||||
|
@ -1856,9 +1901,9 @@ function handleExport(apiRef, data_colums) {
|
|||
const workbook = XLSX.utils.book_new();
|
||||
XLSX.utils.book_append_sheet(workbook, worksheet, local_config.sheetName);
|
||||
XLSX.writeFile(workbook, local_config.fileName, { compression: true });
|
||||
}
|
||||
}
|
||||
|
||||
function ExportMenuItem(props) {
|
||||
function ExportMenuItem(props) {
|
||||
const apiRef = useGridApiContext();
|
||||
const { hideMenu } = props;
|
||||
|
||||
|
@ -1873,9 +1918,9 @@ function ExportMenuItem(props) {
|
|||
Export Excel
|
||||
</MenuItem>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
// FIN EXPORT EXCEL DATAGRID
|
||||
// FIN EXPORT EXCEL DATAGRID
|
||||
|
||||
return (
|
||||
|
||||
|
|
|
@ -2177,7 +2177,6 @@ const Groupe_Apprenant = (props) => {
|
|||
|
||||
function CustomToolbar(props) {
|
||||
|
||||
console.log(" my props = ", props);
|
||||
|
||||
return (
|
||||
<GridToolbarContainer {...props}>
|
||||
|
|
|
@ -162,7 +162,7 @@ const Module_Historique_Action = (props) => {
|
|||
</DialogActions>
|
||||
</Dialog>
|
||||
<div className="div_row" id="div_header" style={{border:"none"}}>
|
||||
<nav style={{fontSize:"calc(1.275rem + .3vw)", color:"rgb(10, 42, 77)"}}> Historique des actions </nav>
|
||||
<nav style={{fontSize:"calc(1.1rem + .3vw)", color:"rgb(10, 42, 77)"}}> Historique des actions </nav>
|
||||
</div>
|
||||
|
||||
<Timeline
|
||||
|
|
|
@ -206,8 +206,8 @@ const Partner = (props) => {
|
|||
top: 0,
|
||||
border: '2px solid #ffffff',
|
||||
padding: '0 4px',
|
||||
background:'#6a329f',
|
||||
color:"#ffffff"
|
||||
background: '#6a329f',
|
||||
color: "#ffffff"
|
||||
},
|
||||
}));
|
||||
|
||||
|
@ -218,8 +218,8 @@ const Partner = (props) => {
|
|||
top: 0,
|
||||
border: '2px solid ',
|
||||
padding: '0 4px',
|
||||
background:'#f44336',
|
||||
color:"#ffffff",
|
||||
background: '#f44336',
|
||||
color: "#ffffff",
|
||||
},
|
||||
}));
|
||||
|
||||
|
@ -2086,7 +2086,7 @@ const Partner = (props) => {
|
|||
|
||||
<PartnerTranings ispending={partnerstatus} currentpack={partnerPackService} conntected_employee_id={conntected_employee_id}
|
||||
class_external_code={orderid} class_internal_url={packs} formation_initiale={formation_initiale}
|
||||
check_user_acces_right={check_user_acces_right}/>
|
||||
check_user_acces_right={check_user_acces_right} />
|
||||
</div>
|
||||
}
|
||||
|
||||
|
@ -2294,7 +2294,9 @@ const Partner = (props) => {
|
|||
{String(menu) === "mes_sessions" &&
|
||||
<div className="div_droite">
|
||||
|
||||
<DisplayPartnerSession conntected_employee_id={conntected_employee_id} object_key={orderid} class_internal_url={packs}
|
||||
<DisplayPartnerSession conntected_employee_id={conntected_employee_id}
|
||||
object_key={orderid}
|
||||
class_internal_url={packs}
|
||||
read_access={check_user_acces_right("session", "read")} write_access={check_user_acces_right("session", "write")}
|
||||
check_user_acces_right={check_user_acces_right} />
|
||||
</div>
|
||||
|
@ -2303,7 +2305,7 @@ const Partner = (props) => {
|
|||
{String(menu) === "mes_employes" &&
|
||||
<div className="div_droite">
|
||||
<Employes conntected_employee_id={conntected_employee_id} read_access={check_user_acces_right("employe", "read")} write_access={check_user_acces_right("employe", "write")}
|
||||
check_user_acces_right={check_user_acces_right}/>
|
||||
check_user_acces_right={check_user_acces_right} />
|
||||
</div>
|
||||
}
|
||||
|
||||
|
@ -2311,7 +2313,7 @@ const Partner = (props) => {
|
|||
<div className="div_droite">
|
||||
<Factures_Client conntected_employee_id={conntected_employee_id} read_access={check_user_acces_right("facture_client", "read")}
|
||||
write_access={check_user_acces_right("facture_client", "write")}
|
||||
check_user_acces_right={check_user_acces_right}/>
|
||||
check_user_acces_right={check_user_acces_right} />
|
||||
</div>
|
||||
}
|
||||
|
||||
|
@ -2326,7 +2328,7 @@ const Partner = (props) => {
|
|||
<div className="div_droite">
|
||||
<Materiels conntected_employee_id={conntected_employee_id} read_access={check_user_acces_right("materiel", "read")}
|
||||
write_access={check_user_acces_right("materiel", "write")}
|
||||
check_user_acces_right={check_user_acces_right}/>
|
||||
check_user_acces_right={check_user_acces_right} />
|
||||
</div>
|
||||
}
|
||||
|
||||
|
@ -2352,7 +2354,7 @@ const Partner = (props) => {
|
|||
<div className="div_droite">
|
||||
<Partner_Commande conntected_employee_id={conntected_employee_id} read_access={check_user_acces_right("commande", "read")}
|
||||
write_access={check_user_acces_right("commande", "write")}
|
||||
check_user_acces_right={check_user_acces_right}/>
|
||||
check_user_acces_right={check_user_acces_right} />
|
||||
</div>
|
||||
}
|
||||
|
||||
|
@ -2361,7 +2363,7 @@ const Partner = (props) => {
|
|||
|
||||
<Facture currentpack={partnerPackService} conntected_employee_id={conntected_employee_id}
|
||||
read_access={check_user_acces_right("compte_partner", "read")} write_access={check_user_acces_right("compte_partner", "write")}
|
||||
check_user_acces_right={check_user_acces_right}/>
|
||||
check_user_acces_right={check_user_acces_right} />
|
||||
</div>
|
||||
}
|
||||
|
||||
|
@ -2376,7 +2378,7 @@ const Partner = (props) => {
|
|||
|
||||
<Apprenant conntected_employee_id={conntected_employee_id} object_key={orderid} subdata={packs}
|
||||
read_access={check_user_acces_right("stagiaire", "read")} write_access={check_user_acces_right("stagiaire", "write")}
|
||||
check_user_acces_right={check_user_acces_right}/>
|
||||
check_user_acces_right={check_user_acces_right} />
|
||||
</div>
|
||||
}
|
||||
|
||||
|
@ -2385,7 +2387,7 @@ const Partner = (props) => {
|
|||
<DisplayPartnerStagiaires conntected_employee_id={conntected_employee_id} object_key={orderid} subdata={packs}
|
||||
read_access={check_user_acces_right("stagiaire", "read")} write_access={check_user_acces_right("stagiaire", "write")}
|
||||
formation_initiale={formation_initiale}
|
||||
check_user_acces_right={check_user_acces_right}/>
|
||||
check_user_acces_right={check_user_acces_right} />
|
||||
</div>
|
||||
}
|
||||
|
||||
|
@ -3019,7 +3021,7 @@ const Partner = (props) => {
|
|||
|
||||
<DisplayPartnerSession conntected_employee_id={conntected_employee_id} object_key={orderid} class_internal_url={packs}
|
||||
read_access={check_user_acces_right("session", "read")} write_access={check_user_acces_right("session", "write")}
|
||||
check_user_acces_right={check_user_acces_right}/>
|
||||
check_user_acces_right={check_user_acces_right} />
|
||||
</div>
|
||||
}
|
||||
|
||||
|
@ -3027,7 +3029,7 @@ const Partner = (props) => {
|
|||
<div className="div_droite div_droite_ralonge">
|
||||
<Employes conntected_employee_id={conntected_employee_id} read_access={check_user_acces_right("employe", "read")}
|
||||
write_access={check_user_acces_right("employe", "write")}
|
||||
check_user_acces_right={check_user_acces_right}/>
|
||||
check_user_acces_right={check_user_acces_right} />
|
||||
</div>
|
||||
}
|
||||
|
||||
|
@ -3035,7 +3037,7 @@ const Partner = (props) => {
|
|||
<div className="div_droite div_droite_ralonge">
|
||||
<Factures_Client conntected_employee_id={conntected_employee_id} read_access={check_user_acces_right("facture_client", "read")}
|
||||
write_access={check_user_acces_right("facture_client", "write")}
|
||||
check_user_acces_right={check_user_acces_right}/>
|
||||
check_user_acces_right={check_user_acces_right} />
|
||||
</div>
|
||||
}
|
||||
|
||||
|
@ -3050,7 +3052,7 @@ const Partner = (props) => {
|
|||
<div className="div_droite div_droite_ralonge">
|
||||
<Materiels conntected_employee_id={conntected_employee_id} read_access={check_user_acces_right("materiel", "read")}
|
||||
write_access={check_user_acces_right("materiel", "write")}
|
||||
check_user_acces_right={check_user_acces_right}/>
|
||||
check_user_acces_right={check_user_acces_right} />
|
||||
</div>
|
||||
}
|
||||
|
||||
|
@ -3059,7 +3061,7 @@ const Partner = (props) => {
|
|||
<div className="div_droite div_droite_ralonge">
|
||||
<Materiel_Salle conntected_employee_id={conntected_employee_id} read_access={check_user_acces_right("materiel", "read")}
|
||||
write_access={check_user_acces_right("materiel", "write")}
|
||||
check_user_acces_right={check_user_acces_right}/>
|
||||
check_user_acces_right={check_user_acces_right} />
|
||||
</div>
|
||||
}
|
||||
|
||||
|
@ -3074,7 +3076,7 @@ const Partner = (props) => {
|
|||
<div className="div_droite div_droite_ralonge">
|
||||
<Partner_Commande conntected_employee_id={conntected_employee_id} read_access={check_user_acces_right("commande", "read")}
|
||||
write_access={check_user_acces_right("commande", "write")}
|
||||
check_user_acces_right={check_user_acces_right}/>
|
||||
check_user_acces_right={check_user_acces_right} />
|
||||
</div>
|
||||
}
|
||||
|
||||
|
@ -3083,7 +3085,7 @@ const Partner = (props) => {
|
|||
|
||||
<Facture currentpack={partnerPackService} conntected_employee_id={conntected_employee_id}
|
||||
read_access={check_user_acces_right("compte_partner", "read")} write_access={check_user_acces_right("compte_partner", "write")}
|
||||
check_user_acces_right={check_user_acces_right}/>
|
||||
check_user_acces_right={check_user_acces_right} />
|
||||
</div>
|
||||
}
|
||||
|
||||
|
@ -3097,7 +3099,7 @@ const Partner = (props) => {
|
|||
|
||||
<Apprenant conntected_employee_id={conntected_employee_id} object_key={orderid} subdata={packs}
|
||||
read_access={check_user_acces_right("stagiaire", "read")} write_access={check_user_acces_right("stagiaire", "write")}
|
||||
check_user_acces_right={check_user_acces_right}/>
|
||||
check_user_acces_right={check_user_acces_right} />
|
||||
</div>
|
||||
}
|
||||
|
||||
|
@ -3105,7 +3107,7 @@ const Partner = (props) => {
|
|||
|
||||
<DisplayPartnerStagiaires conntected_employee_id={conntected_employee_id} object_key={orderid} subdata={packs}
|
||||
read_access={check_user_acces_right("stagiaire", "read")} write_access={check_user_acces_right("stagiaire", "write")}
|
||||
formation_initiale={formation_initiale} check_user_acces_right={check_user_acces_right}/>
|
||||
formation_initiale={formation_initiale} check_user_acces_right={check_user_acces_right} />
|
||||
</div>
|
||||
}
|
||||
|
||||
|
@ -3125,7 +3127,7 @@ const Partner = (props) => {
|
|||
|
||||
<Partner_Client conntected_employee_id={conntected_employee_id} object_key={orderid}
|
||||
read_access={check_user_acces_right("client", "read")} write_access={check_user_acces_right("client", "write")}
|
||||
check_user_acces_right={check_user_acces_right}/>
|
||||
check_user_acces_right={check_user_acces_right} />
|
||||
</div>
|
||||
}
|
||||
|
||||
|
|
|
@ -37,7 +37,7 @@ import DialogActions from '@mui/material/DialogActions';
|
|||
import DialogContent from '@mui/material/DialogContent';
|
||||
import DialogContentText from '@mui/material/DialogContentText';
|
||||
import DialogTitle from '@mui/material/DialogTitle';
|
||||
|
||||
import Module_Historique_Action from "./Module_Historique_Action";
|
||||
import img_loading_spin from "./../mysy_img/mysy_spin_loading.gif";
|
||||
import { Global } from "recharts";
|
||||
import { FcAddDatabase } from "react-icons/fc";
|
||||
|
@ -156,8 +156,8 @@ const Partner_Commande = (props) => {
|
|||
}
|
||||
|
||||
const columns = [
|
||||
{ field: '_id', headerName: '_id', hide: true , disableExport: true,},
|
||||
{ field: 'id', headerName: 'id', hide: true , disableExport: true,},
|
||||
{ field: '_id', headerName: '_id', hide: true, disableExport: true, },
|
||||
{ field: 'id', headerName: 'id', hide: true, disableExport: true, },
|
||||
{ field: 'order_header_ref_interne', headerName: 'Reference', maxWidth: 200, minWidth: 180, flex: 1, hide: false, editable: false, renderCell: (params) => <ExpandableCell_50 {...params} />, },
|
||||
{ field: 'order_header_type', headerName: 'Type', width: 100, hide: false, editable: false },
|
||||
{
|
||||
|
@ -197,9 +197,9 @@ const Partner_Commande = (props) => {
|
|||
|
||||
|
||||
},
|
||||
{ field: 'order_header_client_id', headerName: 'Client_Id', width: 0, hide: true, editable: false , disableExport: true,},
|
||||
{ field: 'order_header_client_id', headerName: 'Client_Id', width: 0, hide: true, editable: false, disableExport: true, },
|
||||
{ field: 'order_header_client_nom', headerName: 'Nom Client', minWidth: 200, flex: 1, renderCell: (params) => <ExpandableCell_50 {...params} />, },
|
||||
{ field: 'order_header_vendeur_id', headerName: 'Vendeur Id', width: 0, hide: true, editable: false , disableExport: true,},
|
||||
{ field: 'order_header_vendeur_id', headerName: 'Vendeur Id', width: 0, hide: true, editable: false, disableExport: true, },
|
||||
{ field: 'order_header_vendeur_nom_prenom', headerName: 'Vendeur', width: 150, flex: 1, editable: false, flex: 1 },
|
||||
{ field: 'order_header_date_cmd', headerName: 'Date', minWidth: 150, hide: false, editable: false, flex: 1, renderCell: (params) => <ExpandableCell_50 {...params} />, },
|
||||
{ field: 'order_header_date_expiration', headerName: 'Date Expiration', minWidth: 150, hide: false, editable: false },
|
||||
|
@ -988,9 +988,12 @@ const Partner_Commande = (props) => {
|
|||
}
|
||||
|
||||
|
||||
const [history_securite_read, sethistory_securite_read] = useState("");
|
||||
|
||||
useEffect(() => {
|
||||
|
||||
sethistory_securite_read(props.check_user_acces_right("historique", "read"))
|
||||
|
||||
Get_List_Partner_Clients();
|
||||
Getall_Training_Employee_No_Filter();
|
||||
GetCurrentPartnerClass();
|
||||
|
@ -1000,7 +1003,7 @@ const Partner_Commande = (props) => {
|
|||
Getall_Partner_Digital_Sign_Status();
|
||||
Getall_Partner_Product_Service();
|
||||
|
||||
console.log(" ~### mes facture props action, orderid = ", action, orderid);
|
||||
|
||||
if (orderid && String(orderid).length > 3) {
|
||||
|
||||
/*
|
||||
|
@ -3410,6 +3413,8 @@ const Partner_Commande = (props) => {
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
async function order_header_submenu_facturation() {
|
||||
setheader_submenu("facturation");
|
||||
submenu_color_management("order_header_facturation");
|
||||
|
@ -3464,8 +3469,23 @@ const Partner_Commande = (props) => {
|
|||
}
|
||||
}
|
||||
|
||||
async function order_header_submenu_historique() {
|
||||
/* setheader_submenu("historique");
|
||||
|
||||
submenu_color_management("historique");
|
||||
await sleep(5);
|
||||
|
||||
|
||||
if (String(order_data_edit_mode) !== "1") {
|
||||
disable_Order_Header_DetailFields();
|
||||
}*/
|
||||
|
||||
setDialog_order_history_open(true)
|
||||
}
|
||||
|
||||
function submenu_color_management(current_menu) {
|
||||
const list_sous_menu = ["order_header_facturation", "order_header_detail", "order_header_main", "order_header_relance",]
|
||||
const list_sous_menu = ["order_header_facturation", "order_header_detail", "order_header_main",
|
||||
"order_header_relance", "historique"]
|
||||
|
||||
for (let i = 0; i < list_sous_menu.length; i++) {
|
||||
|
||||
|
@ -4609,7 +4629,6 @@ const Partner_Commande = (props) => {
|
|||
|
||||
function CustomToolbar(props) {
|
||||
|
||||
console.log(" my props = ", props);
|
||||
|
||||
return (
|
||||
<GridToolbarContainer {...props}>
|
||||
|
@ -4674,7 +4693,7 @@ const Partner_Commande = (props) => {
|
|||
sheetName: 'Export_' + String(new Date().toJSON().slice(0, 10)).replaceAll("-", "_"),
|
||||
};
|
||||
|
||||
local_config.columnNames = local_config.columnNames.filter(function( element ) {
|
||||
local_config.columnNames = local_config.columnNames.filter(function (element) {
|
||||
return element !== undefined;
|
||||
});
|
||||
|
||||
|
@ -4714,6 +4733,29 @@ const Partner_Commande = (props) => {
|
|||
}
|
||||
|
||||
// FIN EXPORT EXCEL DATAGRID
|
||||
|
||||
const [Dialog_order_history_message, setDialog_order_history_message] = React.useState(false);
|
||||
const [Dialog_order_history_open, setDialog_order_history_open] = React.useState(false);
|
||||
function Dialog_order_history_handle_change_participant_session(message) {
|
||||
setDialog_order_history_message(message);
|
||||
setDialog_order_history_open(true);
|
||||
}
|
||||
|
||||
const Dialog_order_history_handleClose = () => {
|
||||
//alert(" Utiliser le bouton 'fermer' ");
|
||||
//setOpen(false);
|
||||
};
|
||||
|
||||
const Dialog_order_history_handleClose_buton = () => {
|
||||
setDialog_order_history_open(false);
|
||||
|
||||
if (document.getElementsByName("order_history_bton") && document.getElementsByName("order_history_bton")[0]) {
|
||||
document.getElementsByName("order_history_bton")[0].style.backgroundColor = "#d8edfc";
|
||||
document.getElementsByName("order_history_bton")[0].style.color = "#3b3e40";
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
return (
|
||||
|
||||
<div className="partner_commande">
|
||||
|
@ -4722,6 +4764,55 @@ const Partner_Commande = (props) => {
|
|||
</div>}
|
||||
|
||||
|
||||
{/* Dialog affichage historique commande/devis */}
|
||||
<Dialog
|
||||
open={Dialog_order_history_open}
|
||||
// onClose={Dialog_order_history_handleClose}
|
||||
className="displaypartnersession"
|
||||
static
|
||||
onClose={() => null} >
|
||||
|
||||
<DialogTitle>MySy Information</DialogTitle>
|
||||
<DialogContent className="DialogContent_width_700px" style={{ "minHeight": "20rem", width:'60rem' }}>
|
||||
|
||||
<div>
|
||||
<div>
|
||||
|
||||
<div className="div_row" style={{ "border": "None", "background": '#F8F9F9', "padding": '5px' }}>
|
||||
<Module_Historique_Action related_collection="partner_order_header"
|
||||
related_collection_recid={selected_id}
|
||||
read_access={"1"}
|
||||
write_access={"1"} />
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</DialogContent>
|
||||
|
||||
|
||||
|
||||
<DialogActions>
|
||||
<div className="div_row">
|
||||
<div className="div_row_gauche">
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div className="div_row_droite" style={{ "textAlign": 'center' }}>
|
||||
<Button onClick={Dialog_order_history_handleClose_buton} className="bton_annule_dialog" >Fermer</Button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</DialogActions>
|
||||
|
||||
</Dialog>
|
||||
{/* FIN Dialog affichage historique commande/devis */}
|
||||
|
||||
|
||||
{/****** Dialog pour créer une session depuis un devis */}
|
||||
|
||||
<Dialog
|
||||
|
@ -5188,7 +5279,7 @@ const Partner_Commande = (props) => {
|
|||
|
||||
|
||||
{(!selected_order_line_id || String(selected_order_line_id).length < 3) &&
|
||||
<div className="session_caract_Dialog" > Type Article
|
||||
<div className="session_caract_Dialog" > <b>Type Article</b>
|
||||
|
||||
<Autocomplete
|
||||
disablePortal
|
||||
|
@ -5226,7 +5317,7 @@ const Partner_Commande = (props) => {
|
|||
<div>
|
||||
{New_GetCurrentPartnerClass_result && New_GetCurrentPartnerClass_result.length > 0 &&
|
||||
(p_add_line_item || String(p_add_line_item) === "") && String(p_detail_header_statut_label).toLowerCase() !== "facturé" &&
|
||||
<div className="session_caract_Dialog" > Formation
|
||||
<div className="session_caract_Dialog" > <b> Formation </b>
|
||||
<Autocomplete
|
||||
disablePortal
|
||||
name="ref_article"
|
||||
|
@ -5301,7 +5392,7 @@ const Partner_Commande = (props) => {
|
|||
</div>}
|
||||
|
||||
|
||||
{String(p_detail_header_statut_label).toLowerCase() === "facturé" && <div className="session_caract_Dialog" > Article
|
||||
{String(p_detail_header_statut_label).toLowerCase() === "facturé" && <div className="session_caract_Dialog" > <b>Article </b>
|
||||
|
||||
<TextField
|
||||
autoFocus
|
||||
|
@ -5318,7 +5409,7 @@ const Partner_Commande = (props) => {
|
|||
|
||||
</div>}
|
||||
|
||||
{String(p_detail_header_statut_label).toLowerCase() === "facturé" && <div className="session_caract_Dialog" > Quantité
|
||||
{String(p_detail_header_statut_label).toLowerCase() === "facturé" && <div className="session_caract_Dialog" > <b>Quantité </b>
|
||||
|
||||
<TextField
|
||||
|
||||
|
@ -5337,7 +5428,7 @@ const Partner_Commande = (props) => {
|
|||
|
||||
</div>}
|
||||
|
||||
{String(p_detail_header_statut_label).toLowerCase() !== "facturé" && <div className="session_caract_Dialog" > Quantité
|
||||
{String(p_detail_header_statut_label).toLowerCase() !== "facturé" && <div className="session_caract_Dialog" > <b> Quantité </b>
|
||||
|
||||
<TextField
|
||||
required
|
||||
|
@ -5360,7 +5451,7 @@ const Partner_Commande = (props) => {
|
|||
</div>}
|
||||
|
||||
|
||||
{String(p_detail_header_statut_label).toLowerCase() !== "facturé" && <div className="session_caract_Dialog" > Prix Unitaire
|
||||
{String(p_detail_header_statut_label).toLowerCase() !== "facturé" && <div className="session_caract_Dialog" > <b> Prix Unitaire </b>
|
||||
<TextField
|
||||
required
|
||||
margin="dense"
|
||||
|
@ -5382,7 +5473,7 @@ const Partner_Commande = (props) => {
|
|||
/>
|
||||
</div>}
|
||||
|
||||
{String(p_detail_header_statut_label).toLowerCase() === "facturé" && <div className="session_caract_Dialog" > Prix Unitaire
|
||||
{String(p_detail_header_statut_label).toLowerCase() === "facturé" && <div className="session_caract_Dialog" > <b> Prix Unitaire </b>
|
||||
<TextField
|
||||
|
||||
margin="dense"
|
||||
|
@ -5507,7 +5598,7 @@ const Partner_Commande = (props) => {
|
|||
|
||||
|
||||
|
||||
{String(p_detail_header_statut_label).toLowerCase() === "facturé" && <div className="session_caract_Dialog" > Article
|
||||
{String(p_detail_header_statut_label).toLowerCase() === "facturé" && <div className="session_caract_Dialog" > <b>Article </b>
|
||||
|
||||
<TextField
|
||||
autoFocus
|
||||
|
@ -5524,7 +5615,7 @@ const Partner_Commande = (props) => {
|
|||
|
||||
</div>}
|
||||
|
||||
{String(p_detail_header_statut_label).toLowerCase() === "facturé" && <div className="session_caract_Dialog" > Quantité
|
||||
{String(p_detail_header_statut_label).toLowerCase() === "facturé" && <div className="session_caract_Dialog" ><b> Quantité </b>
|
||||
|
||||
<TextField
|
||||
|
||||
|
@ -5543,7 +5634,7 @@ const Partner_Commande = (props) => {
|
|||
|
||||
</div>}
|
||||
|
||||
{String(p_detail_header_statut_label).toLowerCase() !== "facturé" && <div className="session_caract_Dialog" > Quantité
|
||||
{String(p_detail_header_statut_label).toLowerCase() !== "facturé" && <div className="session_caract_Dialog" > <b>Quantité </b>
|
||||
|
||||
<TextField
|
||||
required
|
||||
|
@ -5566,7 +5657,7 @@ const Partner_Commande = (props) => {
|
|||
</div>}
|
||||
|
||||
|
||||
{String(p_detail_header_statut_label).toLowerCase() !== "facturé" && <div className="session_caract_Dialog" > Prix Unitaire
|
||||
{String(p_detail_header_statut_label).toLowerCase() !== "facturé" && <div className="session_caract_Dialog" > <b>Prix Unitaire </b>
|
||||
<TextField
|
||||
required
|
||||
margin="dense"
|
||||
|
@ -5588,7 +5679,7 @@ const Partner_Commande = (props) => {
|
|||
/>
|
||||
</div>}
|
||||
|
||||
{String(p_detail_header_statut_label).toLowerCase() === "facturé" && <div className="session_caract_Dialog" > Prix Unitaire
|
||||
{String(p_detail_header_statut_label).toLowerCase() === "facturé" && <div className="session_caract_Dialog" > <b>Prix Unitaire </b>
|
||||
<TextField
|
||||
|
||||
margin="dense"
|
||||
|
@ -5844,7 +5935,7 @@ const Partner_Commande = (props) => {
|
|||
<DialogTitle>{Dialog_1_message}</DialogTitle>
|
||||
<DialogContent>
|
||||
|
||||
<div className="session_caract_Dialog" > Client
|
||||
<div className="session_caract_Dialog" > <b>Client </b>
|
||||
<Autocomplete
|
||||
disablePortal
|
||||
id="ref_client"
|
||||
|
@ -6625,6 +6716,8 @@ const Partner_Commande = (props) => {
|
|||
{selected_order_header_type && String(selected_order_header_type) !== "devis" && <Button variant="outlined" onClick={order_header_submenu_facturation} className="detail_class_submenu" id='order_header_facturation' name='order_header_facturation'>Menu Facturation </Button>}
|
||||
{selected_order_header_type && String(selected_order_header_type) === "devis" && <Button variant="outlined" onClick={order_header_submenu_relance} className="detail_class_submenu" id='order_header_relance' name='order_header_relance'> Relance auto. </Button>}
|
||||
|
||||
{String(history_securite_read) === "1" && <Button variant="outlined" onClick={order_header_submenu_historique} className="detail_class_submenu" id='historique' name='historique'>Historique </Button>}
|
||||
|
||||
</div>
|
||||
|
||||
<div style={{ "width": "100%", "float": "left" }}>
|
||||
|
@ -7747,6 +7840,15 @@ const Partner_Commande = (props) => {
|
|||
</div>}
|
||||
|
||||
|
||||
{String(header_submenu) === "historique" && <div style={{ "border": "None", "background": '#F8F9F9', "padding": '5px' }}>
|
||||
<Module_Historique_Action related_collection="partner_order_header"
|
||||
related_collection_recid={selected_id}
|
||||
read_access={props.read_access}
|
||||
write_access={props.write_access} />
|
||||
</div>}
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
<div style={{ "width": "23%", "float": "left", "textAlign": "right", "paddingTop": "2rem" }}>
|
||||
|
||||
|
|
|
@ -2495,7 +2495,6 @@ const Partner_Facture = (props) => {
|
|||
|
||||
function CustomToolbar(props) {
|
||||
|
||||
// console.log(" my props = ", props);
|
||||
|
||||
return (
|
||||
<GridToolbarContainer {...props}>
|
||||
|
|
|
@ -2686,6 +2686,9 @@
|
|||
|
||||
}
|
||||
|
||||
.DialogContent_width_700px{
|
||||
width: 700px !important;
|
||||
}
|
||||
|
||||
// end media
|
||||
|
||||
|
|
|
@ -107,7 +107,7 @@
|
|||
border: 1px solid #9cf;
|
||||
color: #3b3e40;
|
||||
font-family: "verdana", "Quicksand", "Signika", sans-serif;
|
||||
font-size: small;
|
||||
font-size: 11px;
|
||||
letter-spacing: 0.1rem;
|
||||
font-weight: normal;
|
||||
width: 100%;
|
||||
|
@ -689,7 +689,7 @@
|
|||
border: 1px solid #9cf;
|
||||
color: #3b3e40;
|
||||
font-family: "verdana", "Quicksand", "Signika", sans-serif;
|
||||
font-size: small;
|
||||
font-size: 11px;
|
||||
letter-spacing: 0.1rem;
|
||||
font-weight: normal;
|
||||
height: 2rem !important;
|
||||
|
@ -1310,7 +1310,7 @@
|
|||
border: 1px solid #9cf;
|
||||
color: #3b3e40;
|
||||
font-family: "verdana", "Quicksand", "Signika", sans-serif;
|
||||
font-size: small;
|
||||
font-size: 11px;
|
||||
letter-spacing: 0.1rem;
|
||||
font-weight: normal;
|
||||
height: 2rem !important;
|
||||
|
@ -1810,7 +1810,7 @@
|
|||
border: 1px solid #9cf;
|
||||
color: #3b3e40;
|
||||
font-family: "verdana", "Quicksand", "Signika", sans-serif;
|
||||
font-size: small;
|
||||
font-size: 11px;
|
||||
letter-spacing: 0.1rem;
|
||||
font-weight: normal;
|
||||
height: 2rem !important;
|
||||
|
|
Loading…
Reference in New Issue