From b0db0b0b5f376d6a0ea0c09e16090c8641eb7397 Mon Sep 17 00:00:00 2001 From: cherif Date: Sat, 22 Jul 2023 17:42:38 +0200 Subject: [PATCH] 22/07/2023 - 17h --- src/components/AddClassManual.js | 77 +- src/components/AddPartnerClient.js | 1281 ++++++++++++++++++ src/components/Partner.js | 113 +- src/components/Partner_Client.js | 162 +++ src/styles/components/_addpartnerclient.scss | 178 +++ src/styles/components/_partner_client.scss | 28 - src/styles/components/_partnerclient.scss | 64 + src/styles/index.scss | 3 +- 8 files changed, 1817 insertions(+), 89 deletions(-) create mode 100644 src/components/AddPartnerClient.js create mode 100644 src/styles/components/_addpartnerclient.scss delete mode 100644 src/styles/components/_partner_client.scss create mode 100644 src/styles/components/_partnerclient.scss diff --git a/src/components/AddClassManual.js b/src/components/AddClassManual.js index 464c771..ac79956 100644 --- a/src/components/AddClassManual.js +++ b/src/components/AddClassManual.js @@ -11,7 +11,7 @@ import { Alert } from "@mui/material"; import { AiTwotoneEdit, AiTwotoneSave } from "react-icons/ai"; import profileimg from "../mysy_img/MYSY-profil-2.png"; import Abonnement from "./Abonnement"; -import { PropaneSharp } from "@mui/icons-material"; +import { PropaneSharp, ResetTvRounded } from "@mui/icons-material"; import { useHistory } from "react-router-dom"; import CheckOut from "./CheckOut"; @@ -167,7 +167,7 @@ const AddClassManual = (props) => { value: 'heure', label: 'Heures', }, - + { value: 'jour', label: 'Jours', @@ -305,9 +305,9 @@ const AddClassManual = (props) => { setdatamodification("0"); window.scrollTo({ - top: 0, - behavior: "smooth", - }); + top: 0, + behavior: "smooth", + }); }, [props.mytrainingclass['ref'],]); @@ -347,7 +347,7 @@ const AddClassManual = (props) => { var myurl = process.env.REACT_APP_API_URL + "myclass/api/get_partner_class/"; axios.post(myurl, form).then(res => { - if (res.data.status != "False") { + if (String(res.data.status) === String("true")) { //console.log(" In test res.data.status = " + res.data.status); //console.log(" In test res.data.message r_class = " + res.data.message); setmyApiResponse("True"); @@ -631,7 +631,7 @@ const AddClassManual = (props) => { plus_produit = editorRef_plus_produit.current.getContent(); } - + // Verification si il y a plus de 3 mot clés separés par des ";" mots_cle = mots_cle.replace(/(<([^>]+)>)/ig, ''); @@ -925,7 +925,8 @@ const AddClassManual = (props) => { else if (String(result['status']) === String("Err_Connexion")) { alert('Erreur: ' + result['message']); history.push("/Connexion"); - } + return; + } else { setisimgclassdeleted("0"); @@ -1101,9 +1102,9 @@ const AddClassManual = (props) => { setdatamodification("0"); window.scrollTo({ - top: 0, - behavior: "smooth", - }); + top: 0, + behavior: "smooth", + }); } @@ -1190,7 +1191,7 @@ const AddClassManual = (props) => { }} disabled={false} className="disabled_style" - + /> @@ -1424,30 +1425,30 @@ const AddClassManual = (props) => { -
- - - {duration_unit_list.map((option) => ( - - {option.label}  
-
- ))} - -
-
-
+
+ + + {duration_unit_list.map((option) => ( + + {option.label}  
+
+ ))} + +
+
+
{ - {/*