Fix Account datatype in client
This commit is contained in:
@@ -20,10 +20,8 @@ export class App {
|
|||||||
this.devMode = isDevMode();
|
this.devMode = isDevMode();
|
||||||
|
|
||||||
this.route.queryParams.subscribe(params => {
|
this.route.queryParams.subscribe(params => {
|
||||||
|
|
||||||
const loginToken = params['LoginToken'];
|
const loginToken = params['LoginToken'];
|
||||||
console.log("LoginToken : " + loginToken);
|
console.log("LoginToken : " + loginToken);
|
||||||
|
|
||||||
if (loginToken){
|
if (loginToken){
|
||||||
this.http.post( "api/account/loginticket", JSON.stringify(loginToken), { headers: {'Content-Type': 'application/json'} } ).subscribe({
|
this.http.post( "api/account/loginticket", JSON.stringify(loginToken), { headers: {'Content-Type': 'application/json'} } ).subscribe({
|
||||||
next: data => {
|
next: data => {
|
||||||
@@ -40,8 +38,8 @@ export class App {
|
|||||||
}else{
|
}else{
|
||||||
auth.getLoginState();
|
auth.getLoginState();
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2,12 +2,6 @@ export class Account {
|
|||||||
public id: number | null = null;
|
public id: number | null = null;
|
||||||
public userName: string = "";
|
public userName: string = "";
|
||||||
public email: string = "";
|
public email: string = "";
|
||||||
public emailVerified: boolean = false;
|
public role: string = "";
|
||||||
public passwordHash: string = "";
|
|
||||||
public failedPasswordLock: boolean = false;
|
|
||||||
public passwordAttempts: number = 5;
|
|
||||||
public currentPasswordAttempts: number = 0;
|
|
||||||
public role: string = "Generic";
|
|
||||||
public emailToken: string = "";
|
|
||||||
public dataServer: string = "";
|
public dataServer: string = "";
|
||||||
}
|
}
|
||||||
@@ -15,7 +15,6 @@ export class Authentication{
|
|||||||
let sub = this.http.post<Account>( "api/account/loginState", {}, {} );
|
let sub = this.http.post<Account>( "api/account/loginState", {}, {} );
|
||||||
sub.subscribe({
|
sub.subscribe({
|
||||||
next: data => {
|
next: data => {
|
||||||
data.passwordHash = "";
|
|
||||||
this._user.next(data);
|
this._user.next(data);
|
||||||
},
|
},
|
||||||
error: err => {
|
error: err => {
|
||||||
|
|||||||
Reference in New Issue
Block a user