diff --git a/src/components/Formation.js b/src/components/Formation.js index 8bed898..167efa2 100644 --- a/src/components/Formation.js +++ b/src/components/Formation.js @@ -288,11 +288,11 @@ const Formation = (props) => {
- { props.formation.note && String(props.formation.note).length === 1 && - parseInt(String(props.formation.note)) <=5 && + {props.formation.note && String(props.formation.note).length === 1 && + parseInt(String(props.formation.note)) <= 5 && - - } + + }
@@ -321,7 +321,7 @@ const Formation = (props) => {

- + {String(parse(String(props.formation.title).replace(/(<([^>]+)>)/ig, ''))).substring(0, 100)} @@ -340,11 +340,26 @@ const Formation = (props) => {

} - {String(props.formation.price).length != 9 && String(props.formation.price) !== String("0") && + {String(props.formation.price).length != 9 && String(props.formation.price) !== String("0") && !props.formation.business_prices &&
{props.formation.price} € HT  +
} + {String(props.formation.price).length != 9 && String(props.formation.price) !== String("0") && props.formation.business_prices && +
+ + + + +
+ } + + +
@@ -367,7 +382,7 @@ const Formation = (props) => { {props.formation.duration_unit &&
-
Durée +
Durée
{String(props.formation.duration_unit) === "heure" && @@ -386,7 +401,7 @@ const Formation = (props) => { {props.formation.duration} jr(s)  
} - {String(props.formation.duration_unit) === "mois" && + {String(props.formation.duration_unit) === "mois" &&
{props.formation.duration} mois(s)
} diff --git a/src/components/Pricing.js b/src/components/Pricing.js index 64edcc5..b651b26 100644 --- a/src/components/Pricing.js +++ b/src/components/Pricing.js @@ -145,6 +145,7 @@ function Pricing() { const [isaddprice, setisaddprice] = useState(); function handleAddPriceClick() { + Clean_notification(); setisaddprice("1"); setiseditclientprice(); Desable_new_prices_fields(); @@ -411,7 +412,7 @@ function Pricing() { function Record_new_Price() { Clean_notification(); - + const formData = new FormData(); const url = process.env.REACT_APP_API_URL + "myclass/api/add_business_price/"; @@ -488,13 +489,14 @@ function Pricing() { const [Update_Price_result, setUpdate_Price_result] = useState(""); const [Update_Price_message, setUpdate_Price_message] = useState(""); - function Clean_notification(){ + function Clean_notification() { setRecord_new_Price_api(""); setRecord_new_Price_result(""); setRecord_new_Price_message(""); setDelete_Price_api(""); setUpdate_Price_api(""); - + + } function Update_Price() { @@ -749,14 +751,22 @@ function Pricing() { } - function update_Price() { - } function DataUpdated_exist_price() { } + function cancel_update_price(){ + + setiseditclientprice(); + setisaddprice(); + Clean_notification(); + + GetAPrice_Data(currentlineprice_id); + setiseditprice(false); + } + return (
@@ -775,6 +785,7 @@ function Pricing() {
{Delete_Price_message}
} {String(iseditclientprice) === "1" &&
+ Modification du prix :not(style)': { m: 1 }, width: '100%', }} onChange={DataUpdated_exist_price}> -
- Date Debut - { - var date_du = new Date(moment(date, "DD/MM/YYYY")).setHours(8, 0, 0); - setSessionstartDate(date_du); - setsessionChanged(true); - } - } - showTimeSelect={false} - filterTime={filterPassedTime_start} - dateFormat="dd/MM/yyyy" - className="texte_area" - locale='fr-FR' +
+
+ + { + var date_du = new Date(moment(date, "DD/MM/YYYY")).setHours(8, 0, 0); + setSessionstartDate(date_du); + setsessionChanged(true); + } + } + showTimeSelect={false} + filterTime={filterPassedTime_start} + dateFormat="dd/MM/yyyy" + className="texte_area" + locale='fr-FR' - /> + /> +
+ +
+ + { + var date_au = new Date(moment(date, "DD/MM/YYYY")).setHours(8, 0, 0); + setSessionendDate(date_au); + setsessionChanged(true); + } + } + + showTimeSelect={false} + filterTime={filterPassedTime_end} + dateFormat="dd/MM/yyyy" + className="texte_area" + /> +
-
Date Fin - { - var date_au = new Date(moment(date, "DD/MM/YYYY")).setHours(8, 0, 0); - setSessionendDate(date_au); - setsessionChanged(true); - } - } - - showTimeSelect={false} - filterTime={filterPassedTime_end} - dateFormat="dd/MM/yyyy" - className="texte_area" - /> -
- +
  +
+
- {iseditprice && } + +
-
+
- {!iseditprice && } - {iseditprice && }
- +
+
+
} @@ -883,112 +904,129 @@ function Pricing() {
{Record_new_Price_message}
} {String(isaddprice) === "1" &&
+ Creation d'un nouveau prix client :not(style)': { m: 1 }, width: '100%', }} onChange={DataUpdated}> - {GetClient_Linked_result &&
- -
} +
+
+ + {GetClient_Linked_result &&
+ +
} +
+
- - - - ), - }} - variant="standard" - /> + + + + ), + }} + variant="standard" + style={{"marginLeft":"0px"}} + /> - - -
- Date Debut - { - var date_du = new Date(moment(date, "DD/MM/YYYY")).setHours(8, 0, 0); - setNew_SessionstartDate(date_du); - setsessionChanged(true); - } - } - showTimeSelect={false} - filterTime={filterPassedTime_start} - dateFormat="dd/MM/yyyy" - className="texte_area" - locale='fr-FR' - - /> -
-
Date Fin - { - var date_au = new Date(moment(date, "DD/MM/YYYY")).setHours(8, 0, 0); - setNew_SessionendDate(date_au); - setsessionChanged(true); - } - } - showTimeSelect={false} - filterTime={filterPassedTime_end} - dateFormat="dd/MM/yyyy" - className="texte_area" - /> +
+
+
+ + + { + var date_du = new Date(moment(date, "DD/MM/YYYY")).setHours(8, 0, 0); + setNew_SessionstartDate(date_du); + setsessionChanged(true); + } + } + showTimeSelect={false} + filterTime={filterPassedTime_start} + dateFormat="dd/MM/yyyy" + className="texte_area" + locale='fr-FR' + + /> +
+
+ + + { + var date_au = new Date(moment(date, "DD/MM/YYYY")).setHours(8, 0, 0); + setNew_SessionendDate(date_au); + setsessionChanged(true); + } + } + showTimeSelect={false} + filterTime={filterPassedTime_end} + dateFormat="dd/MM/yyyy" + className="texte_area" + /> +
+
+
  +
-
-
- +
+
+
} - -
- +
+
+
-

Mes prix client

+ Mes prix client {String(menu) === String("default") && GetClienPrices_result && GetClienPrices_result.length > 0 &&
Les prix que vous accordez à vos clients diff --git a/src/components/Recherche_new_v2.js b/src/components/Recherche_new_v2.js index f768786..c090f1b 100644 --- a/src/components/Recherche_new_v2.js +++ b/src/components/Recherche_new_v2.js @@ -1375,6 +1375,7 @@ const Recherche_new_v2 = () => { } else { myurl = process.env.REACT_APP_API_URL + "myclass/api/recherche_text_simple/"; + } @@ -1384,7 +1385,7 @@ const Recherche_new_v2 = () => { axios.post(myurl, form).then(res => { if (String(res.data.status) != String("false")) { //console.log(" In test res.data.status = " + res.data.status); - //console.log(" In test res.data.message = " + res.data.message); + console.log(" In test res.data.message = " + res.data.message); setmyApiResponse("True"); setResult(res.data.message) @@ -1443,15 +1444,16 @@ const Recherche_new_v2 = () => { if (typeof (NewSearchText) === "undefined" || String(NewSearchText) === '') { crit_SearchText = ""; myurl = process.env.REACT_APP_API_URL + "myclass/api/get_all_class/"; + + } else { clearsearchtext(); crit_SearchText = NewSearchText; myurl = process.env.REACT_APP_API_URL + "myclass/api/recherche_text_simple/"; + } - //alert(" crit_SearchText = " + crit_SearchText+" myurl = "+myurl); - - + var form = new FormData(); form.append("search_text", crit_SearchText); @@ -1496,7 +1498,8 @@ const Recherche_new_v2 = () => { axios.post(myurl, form).then(res => { if (String(res.data.status) != String("false")) { //console.log(" In test res.data.status = " + res.data.status); - //console.log(" In DisplayXfirstClas res.data.message = " + res.data.message); + console.log(" In DisplayXfirstClas res.data.message = " + res.data.message); + setmyApiResponse("True"); setResult(res.data.message) // textInput.current.focus(); diff --git a/src/styles/components/_formation.scss b/src/styles/components/_formation.scss index 8767e62..5d11b5d 100644 --- a/src/styles/components/_formation.scss +++ b/src/styles/components/_formation.scss @@ -1361,6 +1361,59 @@ } + .aaatraining_price_barre { + color: #619e31; + font-size: 1rem; + font-family: "Quicksand", "Signika", sans-serif; + text-align: left; + letter-spacing: 1px; + margin-bottom: 0.6rem !important; + font-family: 'Albert Sans'; + font-style: normal; + font-weight: 800; + font-size: 18px; + line-height: 22px; + + + font-family: 'Albert Sans'; + font-style: normal; + font-weight: 800; + font-size: 18px; + line-height: 22px; + /* identical to box height */ + + display: flex; + align-items: center; + font-feature-settings: 'liga' off; + + /* Deep Blue */ + + color: #0A043C; + + + /* Inside auto layout */ + + flex: none; + order: 2; + flex-grow: 0; + text-decoration: line-through; + + } + + .discounted_price { + font-weight: 600; + font-size: 20px; + color: #ff8c00; + } + + .training_price_barre { + font-weight: 500; + font-size: 18px; + color: #647585; + text-decoration: line-through; + margin-left: 2rem; +} + .bton_inscris { position: relative; background: red; @@ -1524,5 +1577,13 @@ .row_formation_crit { min-height: 10rem !important; } + + .discount_block{ + font-weight: 400; + margin-left: 1rem; +color: red; + } } + + // end media } \ No newline at end of file diff --git a/src/styles/components/_pricing.scss b/src/styles/components/_pricing.scss index 1240d1d..16326a9 100644 --- a/src/styles/components/_pricing.scss +++ b/src/styles/components/_pricing.scss @@ -1,179 +1,212 @@ .pricing { - @media only screen and (max-width: 600px) { - .koUpdateData { - font-size: small; - color: red; - font-style: italic; - } - .okUpdateData { - font-size: small; - color: green; - font-style: italic; - } - - .div_row { - float: left; - //border:0px solid black; - border-width: 0.01rem; - width: 100%; - margin-bottom: 1rem; - border-radius: 1rem; - } - - .div_row_gauche { - float: left; - //border:0px solid black; - border-width: 0.01rem; - width: 48%; - border-radius: 1rem; - } - - .div_row_droite { - float: right; - //border:0px solid black; - border-width: 0.01rem; - width: 48%; - border-radius: 1rem; - } - + @media only screen and (max-width: 600px) { + .koUpdateData { + font-size: small; + color: red; + font-style: italic; } - - @media only screen and (min-width: 601px) and (max-width: 991px) { - /*style petites-moyennes tablettes */ - - .koUpdateData { - font-size: small; - color: red; - font-style: italic; - } - .okUpdateData { - font-size: small; - color: green; - font-style: italic; - } - - .div_row { - float: left; - //border:0px solid black; - border-width: 0.01rem; - width: 100%; - margin-bottom: 1rem; - border-radius: 1rem; - } - - .div_row_gauche { - float: left; - //border:0px solid black; - border-width: 0.01rem; - width: 48%; - border-radius: 1rem; - } - - .div_row_droite { - float: right; - //border:0px solid black; - border-width: 0.01rem; - width: 48%; - border-radius: 1rem; - } - + .okUpdateData { + font-size: small; + color: green; + font-style: italic; } - @media only screen and (min-width: 992px) and (max-width: 1199px) { - .koUpdateData { - font-size: small; - color: red; - font-style: italic; - } - .okUpdateData { - font-size: small; - color: green; - font-style: italic; - } - - .div_row { - float: left; - //border:0px solid black; - border-width: 0.01rem; - width: 100%; - margin-bottom: 1rem; - border-radius: 1rem; - } - - .div_row_gauche { - float: left; - //border:0px solid black; - border-width: 0.01rem; - width: 48%; - border-radius: 1rem; - } - - .div_row_droite { - float: right; - //border:0px solid black; - border-width: 0.01rem; - width: 48%; - border-radius: 1rem; - } - + .div_row { + float: left; + //border:0px solid black; + border-width: 0.01rem; + width: 100%; + margin-bottom: 1rem; + border-radius: 1rem; } - - @media only screen and (min-width: 1200px) { - .koUpdateData { - font-size: small; - color: red; - font-style: italic; - } - .okUpdateData { - font-size: small; - color: green; - font-style: italic; - } - - .div_row { - float: left; - //border:0px solid black; - border-width: 0.01rem; - width: 100%; - margin-bottom: 1rem; - border-radius: 1rem; - } - - .div_row_gauche { - float: left; - //border:0px solid black; - border-width: 0.01rem; - width: 48%; - border-radius: 1rem; - } - - .div_row_droite { - float: right; - //border:0px solid black; - border-width: 0.01rem; - width: 48%; - border-radius: 1rem; - } - - .buton_add_price{ - border-radius: 5px; - font-size: small; - padding: 0.3rem; - width: 20%; - background: #81BC3A; - float: right; - margin-right: 10px; - - } - - .texte_area{ - width: 48% !important; - } + .div_row_gauche { + float: left; + //border:0px solid black; + border-width: 0.01rem; + width: 48%; + border-radius: 1rem; } - + .div_row_droite { + float: right; + //border:0px solid black; + border-width: 0.01rem; + width: 48%; + border-radius: 1rem; + } - // End media + } + + + @media only screen and (min-width: 601px) and (max-width: 991px) { + /*style petites-moyennes tablettes */ + + .koUpdateData { + font-size: small; + color: red; + font-style: italic; + } + + .okUpdateData { + font-size: small; + color: green; + font-style: italic; + } + + .div_row { + float: left; + //border:0px solid black; + border-width: 0.01rem; + width: 100%; + margin-bottom: 1rem; + border-radius: 1rem; + } + + .div_row_gauche { + float: left; + //border:0px solid black; + border-width: 0.01rem; + width: 48%; + border-radius: 1rem; + } + + .div_row_droite { + float: right; + //border:0px solid black; + border-width: 0.01rem; + width: 48%; + border-radius: 1rem; + } + + } + + @media only screen and (min-width: 992px) and (max-width: 1199px) { + .koUpdateData { + font-size: small; + color: red; + font-style: italic; + } + + .okUpdateData { + font-size: small; + color: green; + font-style: italic; + } + + .div_row { + float: left; + //border:0px solid black; + border-width: 0.01rem; + width: 100%; + margin-bottom: 1rem; + border-radius: 1rem; + } + + .div_row_gauche { + float: left; + //border:0px solid black; + border-width: 0.01rem; + width: 48%; + border-radius: 1rem; + } + + .div_row_droite { + float: right; + //border:0px solid black; + border-width: 0.01rem; + width: 48%; + border-radius: 1rem; + } + + } + + + @media only screen and (min-width: 1200px) { + .koUpdateData { + font-size: small; + color: red; + font-style: italic; + } + + .okUpdateData { + font-size: small; + color: green; + font-style: italic; + } + + .div_row { + float: left; + //border:0px solid black; + border-width: 0.01rem; + width: 100%; + margin-bottom: 0px !important; + margin-top: 0px !important; + border-radius: 1rem; + } + + .div_row_gauche { + float: left; + //border:0px solid black; + border-width: 0.01rem; + width: 48%; + border-radius: 1rem; + } + + .div_row_droite { + float: right; + //border:0px solid black; + border-width: 0.01rem; + width: 48%; + border-radius: 1rem; + } + + .buton_add_price { + border-radius: 10rem; + padding: 0.3rem; + width: 20%; + background: #81BC3A; + float: right; + margin-right: 10px; + border: none; + + } + + .texte_area { + width: 48% !important; + } + + .btn_editer { + width: 15rem; + background-color: #212121 !important; + color: white; + border-radius: 10rem; + } + + .btn_enreg { + width: 15rem; + background-color: green !important; + color: white; + border-radius: 10rem; + } + + .my_label { + color: rgba(0, 0, 0, 0.6); + font-family: "Roboto", "Helvetica", "Arial", sans-serif; + font-weight: 400; + font-size: small; + line-height: 1.4375em; + letter-spacing: 0.00938em; + } + + .div_row_droite_adapt_date{ + padding-left: 1rem; + float: left; + } + } + + + + // End media } \ No newline at end of file