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AA0BvC,kBAQfwC,KAAuBxC,MACvByC,KAAWzC,sCATtBuC,EAA0BG,4TDZvC1C,gCAaAA,wBAsBAA,wCAnCeA,wBAaTA,+BAsBSA,yIE9BR,MAAM2C,EAAS,CAClB,CAACC,KAAM,GAAIC,UAAWN,EAA4BO,UAAW,QAC7D,CAACF,KAAM,SAAUC,UAAWN,EAA4BO,UAAW,SAWhE,+CAAMC,4DAPA,CACLC,KACAC,cAAsBN,GACtBO","names":["t","constructor","n","i","u","r","this","Z","ngOnInit","loading","route","params","pipe","ngUnsubscribe$","subscribe","hasOwnProperty","token","registrationRestService","confirm","a","error","errorCode","router","navigate","queryParams","JSON","stringify","credentialsSet","setLoading","auth","login","p","username","response","password","navigateByUrl","ngOnDestroy","next","complete","s","f","h","selectors","v","path","component","pathMatch","c","l","d","x"],"sources":["webpack:///src/app/modules/authentication/account-activation/account-activation.component.html","webpack:///src/app/modules/authentication/account-activation/account-activation.component.ts","webpack:///src/app/modules/authentication/account-activation/account-activation.module.ts"],"sourcesContent":["\n\n
\n
\n
\n
\n  Ihre Daten werden geladen.\n
\n
\n
\n
\n
\n\n\n
\n
\n
\n
\n

Legen Sie ein neues Passwort fest.

\n
\n
\n
\n
\n
\n
\n \n \n
\n
\n
\n
\n\n\n\n
\n
\n
\n

Ihr Token ist ungültig.

\n
\n
\n
\n
\n
\n
\n Bitte wenden sie sich an einen Mitarbeiter der Marketingabteilung.\n
\n
\n
\n
","import {ActivatedRoute, Router} from '@angular/router';\nimport { AuthService } from \"../../../core/services/api/auth.service\";\nimport { Component, Inject, OnDestroy, OnInit } from '@angular/core';\nimport { LoginRequest } from \"../../../core/models/login-request.model\";\nimport { RegistrationRestService } from \"../../../core/services/api/registration.rest-service\";\nimport { Subject } from 'rxjs';\nimport { takeUntil } from 'rxjs/operators';\n\n@Component({\n selector: 'account-activation',\n templateUrl: './account-activation.component.html',\n styleUrls: ['./account-activation.component.scss']\n})\nexport class AccountActivationComponent implements OnInit, OnDestroy {\n\n public token: string;\n public response: any;\n public loading: boolean;\n public ngUnsubscribe$ = new Subject(); // emit unsubscription\n\n constructor(public route: ActivatedRoute,\n @Inject(RegistrationRestService) public registrationRestService: RegistrationRestService,\n @Inject(AuthService) public auth: AuthService,\n public router: Router) {\n }\n\n ngOnInit() {\n this.loading = true;\n this.route.params.pipe(takeUntil(this.ngUnsubscribe$))\n .subscribe(params => {\n if (params.hasOwnProperty('token')) {\n this.token = params.token;\n\n this.registrationRestService.confirm(params.token).pipe(takeUntil(this.ngUnsubscribe$)).subscribe(\n (response) => {\n this.loading = false;\n },\n err => {\n if (err.error && err.error.errorCode) {\n this.router.navigate(['kontakt'], {queryParams: {error: JSON.stringify(err)}});\n }\n },\n () => {\n // Do stuff after completion\n }\n );\n } else {\n this.loading = false;\n }\n });\n }\n\n\n credentialsSet(e) {\n this.setLoading(true);\n this.auth.login(new LoginRequest({\n username: e.response.username,\n password: e.password\n })).pipe(takeUntil(this.ngUnsubscribe$)).subscribe(() => {\n this.router.navigateByUrl('dashboard');\n });\n }\n\n setLoading(e: boolean) {\n if (e === true)\n this.loading = e;\n }\n\n /**\n * unsubcribe all subscriptions on destroy\n */\n ngOnDestroy(): void {\n this.ngUnsubscribe$.next();\n this.ngUnsubscribe$.complete();\n }\n}\n","import {NgModule} from '@angular/core';\nimport {CommonModule} from '@angular/common';\nimport {AccountActivationComponent} from './account-activation.component';\nimport {RouterModule} from '@angular/router';\nimport {PasswordFormModule} from \"../../shared/password-form/password-form.module\";\n\nexport const routes = [\n {path: '', component: AccountActivationComponent, pathMatch: 'full'},\n {path: ':token', component: AccountActivationComponent, pathMatch: 'full'}\n];\n\n@NgModule({\n imports: [\n CommonModule,\n RouterModule.forChild(routes),\n PasswordFormModule\n ],\n declarations: [AccountActivationComponent]\n})\nexport class AccountActivationModule {\n}\n"]}