more progress on setup

This commit is contained in:
2023-08-26 15:01:57 +02:00
parent 991b96d54d
commit 8c4d70ac28
5 changed files with 20 additions and 9 deletions

View File

@@ -157,6 +157,11 @@
this.$refs.notification.createNotification( 'Please provide your first and last name!', 5, 'error', 'normal' );
return;
}
if ( !this.checkEmail() ) {
this.$refs.notification.createNotification( 'This email address is not an email address', 5, 'error', 'normal' );
return;
}
let progress = this.$refs.notification.createNotification( 'Signing up...', 20, 'progress', 'normal' );
let fetchOptions = {
method: 'post',
@@ -166,9 +171,7 @@
'charset': 'utf-8'
}
};
console.log( 'signup initiated' )
fetch( localStorage.getItem( 'url' ) + '/user/signup', fetchOptions ).then( res => {
console.log( res )
res.text().then( status => {
if ( status === 'ok' ) {
this.$refs.notification.cancelNotification( progress );