[SOLVED] I really need some help, please.

Hi,

Is there a way, how to import user data into the member’s database, while using the custom registration?
With the current code that I have, all new members are visible in the Contact List and Site Members, but not in my member’s database.

I’m trying to solve the problem here:

https://www.wix.com/corvid/forum/community-discussion/custom-registration-1/p-1/dl-5da9bb66078675001742691c-5da8e3a3110dd1002d688e43-2

Let me also share my code, and if any of you will be able to help, I would very much appreciate it.

  1. The registration code:
import wixUsers from 'wix-users';
import wixLocation from 'wix-location';
import wixWindow from 'wix-window';

$w.onReady(function(){  
    $w('#register').onClick(function (){   
 
 let email = $w('#email').value; 
 let password = $w('#password').value;   

        wixUsers.register(email,password)   
        .then(()=>{
        wixWindow.lightbox.close();
        wixWindow.openLightbox("Přihlášení");
            })
        })
    })
  1. The login code:
import wixUsers from 'wix-users';
import wixLocation from 'wix-location';
import wixWindow from 'wix-window';

$w.onReady(function () {
$w("#forgotPassword").onClick( (event) => {
wixWindow.lightbox.close()
   wixUsers.promptForgotPassword()
   .then( ( ) => {
 
   } )
    .catch( (err) => {
 let errorMsg = err;  //"The user closed the forgot password dialog"
    });
 });
});

export function loginButton_click(event) {

 let email = $w("#email").value;
 let password = $w("#password").value;

 wixUsers.login(email, password)
   .then( () => {
     console.log("User is logged in");
     wixLocation.to(`/Members/${wixUsers.currentUser.id}`); 
   } )
    .catch( (err) => {
     console.log(err);
     $w("#errorMessage").show();  
 // You can delete this line if you are not going to add an error message.  Use a regular text element set to 'collapse on load' from the Properties Panel.
   } ); 
}


Thank you,
Jakub