mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-19 19:57:22 +08:00
Dollar event
This commit is contained in:
@ -24,22 +24,11 @@ export class LoginPage {
|
||||
email: ['', Validators.required],
|
||||
password: ['', Validators.required],
|
||||
});
|
||||
|
||||
/*
|
||||
this.loginForm = new FormControlGroup('form', [
|
||||
new FormControl('email'),
|
||||
new FormControl('password')
|
||||
]);
|
||||
*/
|
||||
|
||||
/*
|
||||
this.loginForm.readFrom({
|
||||
});
|
||||
*/
|
||||
}
|
||||
|
||||
doLogin() {
|
||||
doLogin(event) {
|
||||
Log.log('Doing login')
|
||||
event.preventDefault();
|
||||
//this.viewport.push(SecondPage)
|
||||
}
|
||||
}
|
||||
|
@ -1,12 +1,12 @@
|
||||
<ion-view nav-title="Login">
|
||||
<form (submit)="doLogin()" [control-group]="loginForm">
|
||||
<form (^submit)="doLogin($event)" [control-group]="loginForm">
|
||||
<ion-input>
|
||||
<input control="email" type="email" placeholder="Your email">
|
||||
</ion-input>
|
||||
<ion-input>
|
||||
<input control="password" type="email" placeholder="Your email">
|
||||
</ion-input>
|
||||
<button type="button" (click)="doLogin()">Log in</button>
|
||||
<button type="submit">Log in</button>
|
||||
|
||||
{{loginForm.controls.email.value}}
|
||||
</form>
|
||||
|
Reference in New Issue
Block a user