refer-route added

This commit was merged in pull request #863.
This commit is contained in:
victorAnumudu
2024-12-02 20:10:52 +01:00
parent d6b6e34132
commit d234bb6747
3 changed files with 28 additions and 1 deletions
+9 -1
View File
@@ -8,7 +8,13 @@ import AuthLayout from "../AuthLayout2";
import GoogleDownload from '../../../assets/images/download/andriod.jpg'
import IOSDownload from '../../../assets/images/download/apple.jpg'
export default function SignUp({details}) {
/* Note
The Props in this component
1. refer_link holds the value to be sent as the referral code
2. details holds the value of the person either referred via invite or promo
*/
export default function SignUp({refer_link, details}) {
const location = useLocation();
// eslint-disable-next-line no-restricted-globals
@@ -104,6 +110,7 @@ export default function SignUp({details}) {
}
setSignUpLoading(true);
let referral_link = refer_link ? {refer_link} : {} // FOR USER COMING FROM REFERRAL PROCESS
const reqData = {
country: country,
firstname: first_name,
@@ -113,6 +120,7 @@ export default function SignUp({details}) {
password: password,
terms: 1,
news: 1,
...referral_link
};
const res = await userApi.CreateUser(reqData);