2018-05-28 05:41:56 +00:00
|
|
|
import {
|
|
|
|
Component,
|
|
|
|
OnDestroy,
|
|
|
|
OnInit,
|
|
|
|
} from '@angular/core';
|
|
|
|
import { Member } from '@overflow/commons-typescript/model/member';
|
|
|
|
import * as AuthStore from '../store/signup';
|
2018-05-28 06:24:29 +00:00
|
|
|
import { Store } from '@ngrx/store';
|
2018-05-28 05:41:56 +00:00
|
|
|
|
|
|
|
@Component({
|
|
|
|
selector: 'of-member-signup-container',
|
2018-05-28 06:24:29 +00:00
|
|
|
templateUrl: './member-signup-container.component.html',
|
2018-05-28 05:41:56 +00:00
|
|
|
})
|
|
|
|
export class MemberSignupContainerComponent implements OnInit, OnDestroy {
|
|
|
|
|
|
|
|
constructor(
|
|
|
|
private store: Store<AuthStore.State>,
|
|
|
|
) { }
|
|
|
|
|
|
|
|
ngOnInit() {
|
|
|
|
}
|
|
|
|
|
|
|
|
ngOnDestroy() {
|
|
|
|
}
|
|
|
|
|
|
|
|
onSignup(info: {member: Member, password: string}) {
|
|
|
|
this.store.dispatch(new AuthStore.Signup(info));
|
|
|
|
}
|
|
|
|
}
|