add signupSource

This commit is contained in:
Patrick Nagurny
2018-11-05 09:40:02 -05:00
parent ae9e9c9570
commit cd1f8a1e36
2 changed files with 3 additions and 0 deletions

View File

@@ -43,6 +43,7 @@ export class RegisterPage {
onSubmit() {
let formUser = new User(this.form.value);
formUser.id = Util.newGuid();
formUser.signupSource = 'web';
this.log.debug(formUser);
this.userService.postUser(formUser)

View File

@@ -8,6 +8,7 @@ export class User {
password: string;
agreeToTerms: boolean;
emailVerified: boolean;
signupSource: string;
constructor(options: any = {}) {
this.id = options.id || this.id;
this.inserted = options.inserted ? new Date(options.inserted) : null;
@@ -18,5 +19,6 @@ export class User {
this.password = options.password || this.password;
this.agreeToTerms = options.agreeToTerms || false;
this.emailVerified = options.emailVerified || this.emailVerified;
this.signupSource = options.signupSource || this.signupSource;
}
}