Première navigation lgin to home
This commit is contained in:
parent
bd7264f111
commit
c3fe53e3e7
|
@ -3,12 +3,12 @@ import { Platform } from 'ionic-angular';
|
||||||
import { StatusBar } from '@ionic-native/status-bar';
|
import { StatusBar } from '@ionic-native/status-bar';
|
||||||
import { SplashScreen } from '@ionic-native/splash-screen';
|
import { SplashScreen } from '@ionic-native/splash-screen';
|
||||||
|
|
||||||
import { HomePage } from '../pages/home/home';
|
import { LoginPage } from '../pages/login/login';
|
||||||
@Component({
|
@Component({
|
||||||
templateUrl: 'app.html'
|
templateUrl: 'app.html'
|
||||||
})
|
})
|
||||||
export class MyApp {
|
export class MyApp {
|
||||||
rootPage:any = HomePage;
|
rootPage:any = LoginPage;
|
||||||
|
|
||||||
constructor(platform: Platform, statusBar: StatusBar, splashScreen: SplashScreen) {
|
constructor(platform: Platform, statusBar: StatusBar, splashScreen: SplashScreen) {
|
||||||
platform.ready().then(() => {
|
platform.ready().then(() => {
|
||||||
|
|
|
@ -6,11 +6,13 @@ import { StatusBar } from '@ionic-native/status-bar';
|
||||||
|
|
||||||
import { MyApp } from './app.component';
|
import { MyApp } from './app.component';
|
||||||
import { HomePage } from '../pages/home/home';
|
import { HomePage } from '../pages/home/home';
|
||||||
|
import { LoginPage } from '../pages/login/login';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
declarations: [
|
declarations: [
|
||||||
MyApp,
|
MyApp,
|
||||||
HomePage
|
HomePage,
|
||||||
|
LoginPage
|
||||||
],
|
],
|
||||||
imports: [
|
imports: [
|
||||||
BrowserModule,
|
BrowserModule,
|
||||||
|
@ -19,7 +21,8 @@ import { HomePage } from '../pages/home/home';
|
||||||
bootstrap: [IonicApp],
|
bootstrap: [IonicApp],
|
||||||
entryComponents: [
|
entryComponents: [
|
||||||
MyApp,
|
MyApp,
|
||||||
HomePage
|
HomePage,
|
||||||
|
LoginPage
|
||||||
],
|
],
|
||||||
providers: [
|
providers: [
|
||||||
StatusBar,
|
StatusBar,
|
||||||
|
|
|
@ -12,7 +12,6 @@
|
||||||
|
|
||||||
</ion-header>
|
</ion-header>
|
||||||
|
|
||||||
|
|
||||||
<ion-content padding>
|
<ion-content padding>
|
||||||
|
|
||||||
</ion-content>
|
</ion-content>
|
||||||
|
|
|
@ -4,6 +4,7 @@
|
||||||
See http://ionicframework.com/docs/components/#navigation for more info on
|
See http://ionicframework.com/docs/components/#navigation for more info on
|
||||||
Ionic pages and navigation.
|
Ionic pages and navigation.
|
||||||
-->
|
-->
|
||||||
|
|
||||||
<ion-header>
|
<ion-header>
|
||||||
|
|
||||||
<ion-navbar>
|
<ion-navbar>
|
||||||
|
@ -14,5 +15,7 @@
|
||||||
|
|
||||||
|
|
||||||
<ion-content padding>
|
<ion-content padding>
|
||||||
|
<ion-buttons>
|
||||||
|
<button ion-item (click)="changePage()">Rentrer à la maison</button>
|
||||||
|
</ion-buttons>
|
||||||
</ion-content>
|
</ion-content>
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
import { Component } from '@angular/core';
|
import { Component } from '@angular/core';
|
||||||
import { IonicPage, NavController, NavParams } from 'ionic-angular';
|
import { IonicPage, NavController, NavParams } from 'ionic-angular';
|
||||||
|
import { HomePage } from '../home/home';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Generated class for the LoginPage page.
|
* Generated class for the LoginPage page.
|
||||||
|
@ -22,4 +23,8 @@ export class LoginPage {
|
||||||
console.log('ionViewDidLoad LoginPage');
|
console.log('ionViewDidLoad LoginPage');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
changePage() {
|
||||||
|
this.navCtrl.push(HomePage);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue