Merge branch 'master' of https://gitlab.chiefsoft.net/MyFit/www-myfit into myfit-import_images
This commit is contained in:
@@ -117,14 +117,10 @@ const Main = ({ brdcum }) => {
|
|||||||
|
|
||||||
//CALLS THE API AFTER COMPONENT LOADS
|
//CALLS THE API AFTER COMPONENT LOADS
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
allCountry().then((data) => setCountries(Object.keys(data.data))).catch((err)=>console.log(err.message));
|
allCountry().then((data) => setCountries(Object.entries(data.data))).catch((err)=>console.log(err.message));
|
||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
|
|
||||||
// useEffect(() => {
|
|
||||||
// myData
|
|
||||||
// }, [myData]);
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
{brdcum.b1 && (
|
{brdcum.b1 && (
|
||||||
@@ -202,7 +198,7 @@ const Main = ({ brdcum }) => {
|
|||||||
maxLenght={35}
|
maxLenght={35}
|
||||||
value={values.name}
|
value={values.name}
|
||||||
onChange={onChange}
|
onChange={onChange}
|
||||||
pattern="^$|^[a-zA-Z]+( [a-zA-Z]+)?$+( [a-zA-Z]+)?$"
|
pattern="^\w+( \w+)$"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<FormInput
|
<FormInput
|
||||||
@@ -230,8 +226,8 @@ const Main = ({ brdcum }) => {
|
|||||||
countries.map((country, index) => (
|
countries.map((country, index) => (
|
||||||
<option
|
<option
|
||||||
key={index}
|
key={index}
|
||||||
value={country}>
|
value={country[0]}>
|
||||||
{country}
|
{country[1]}
|
||||||
</option>
|
</option>
|
||||||
))}
|
))}
|
||||||
</select>
|
</select>
|
||||||
|
|||||||
Reference in New Issue
Block a user