add inactivity

This commit is contained in:
Peter Maquiran
2021-08-27 17:11:05 +01:00
parent 2e4458283a
commit 81b7f4820b
9 changed files with 55 additions and 84 deletions
+8 -3
View File
@@ -7,7 +7,7 @@ import { UserSession } from '../models/user.model';
@Injectable({
providedIn: 'root'
})
export class SessionService {
class SessionService {
// main data
private _user = new UserSession()
@@ -54,11 +54,16 @@ export class SessionService {
}
needTovalidateUser() {
return this._user.Inativity
return this._user.Inactivity
}
setInativity(value: boolean) {
this._user.Inativity = value
this._user.Inactivity = value
this.save()
}
setUrlBeforeInactivity(pathname: string) {
this._user.UrlBeforeInactivity = pathname
this.save()
}