From 7a9c3414779e0db0053af7f5665453a6db6a669f Mon Sep 17 00:00:00 2001 From: Jake Vis Date: Tue, 27 Mar 2018 22:13:54 -0700 Subject: [PATCH] Events Working Basic events #19 --- Queercon/src/app/app.component.ts | 1 - Queercon/src/app/app.module.ts | 38 +++++++-- Queercon/src/pages/events/events-details.html | 12 +++ Queercon/src/pages/events/events.html | 56 -------------- Queercon/src/pages/events/events.scss | 2 - Queercon/src/pages/events/events.ts | 77 +++++++++++++++++-- Queercon/src/pages/tabs/tabs.html | 6 -- Queercon/src/pages/tabs/tabs.ts | 21 ----- 8 files changed, 114 insertions(+), 99 deletions(-) create mode 100644 Queercon/src/pages/events/events-details.html delete mode 100644 Queercon/src/pages/events/events.html delete mode 100644 Queercon/src/pages/events/events.scss delete mode 100644 Queercon/src/pages/tabs/tabs.html delete mode 100644 Queercon/src/pages/tabs/tabs.ts diff --git a/Queercon/src/app/app.component.ts b/Queercon/src/app/app.component.ts index da4d074..5475695 100644 --- a/Queercon/src/app/app.component.ts +++ b/Queercon/src/app/app.component.ts @@ -45,7 +45,6 @@ export class MyApp { { title: 'Events Calendar', component: EventsPage }, { title: 'Queercon Locals', component: LocalPage }, { title: 'Chat Room', component: ChatPage }, - { title: 'Events', component: EventsPage }, { title: 'Support Us', component: SupportersPage }, { title: 'Volunteer', component: VolunteerPage }, { title: 'Contact', component: ContactPage }, diff --git a/Queercon/src/app/app.module.ts b/Queercon/src/app/app.module.ts index 40ffd74..a2d0f74 100644 --- a/Queercon/src/app/app.module.ts +++ b/Queercon/src/app/app.module.ts @@ -9,7 +9,7 @@ import { ChatPage } from '../pages/chat/chat'; import { LocalPage } from '../pages/local/local'; import { QcRsa2018Page } from '../pages/qc-rsa2018/qc-rsa2018'; import { VolunteerPage } from '../pages/volunteer/volunteer'; -import { EventsPage } from '../pages/events/events'; +import { EventsPage as EventsPage, EventsDetailsPage} from '../pages/events/events'; import { ContactPage } from '../pages/contact/contact'; import { SupportersPage } from '../pages/supporters/supporters'; import { AboutPage } from '../pages/about/about'; @@ -20,8 +20,14 @@ import { SplashScreen } from '@ionic-native/splash-screen'; import { Calendar } from '@ionic-native/calendar'; + @NgModule({ declarations: [ + + EventsPage, + + EventsDetailsPage, + MyApp, NewsPage, SupportersPage, @@ -30,17 +36,40 @@ import { Calendar } from '@ionic-native/calendar'; LocalPage, QcRsa2018Page, VolunteerPage, - EventsPage, AboutPage, ContactPage, HomePage ], + imports: [ + BrowserModule, - IonicModule.forRoot(MyApp) - ], + + IonicModule.forRoot(MyApp, { + + statusbarPadding: false, + + }, + + { + + links: [ + { component: EventsPage, name: 'EventsPage', segment: 'navigation-basic' }, + + { component: EventsDetailsPage, name: 'NavigationDetailsPage', segment: 'navigation-details' }, + + ] + + }) + +], bootstrap: [IonicApp], entryComponents: [ + + EventsPage, + + EventsDetailsPage, + MyApp, NewsPage, SupportersPage, @@ -49,7 +78,6 @@ import { Calendar } from '@ionic-native/calendar'; LocalPage, QcRsa2018Page, VolunteerPage, - EventsPage, AboutPage, ContactPage, HomePage diff --git a/Queercon/src/pages/events/events-details.html b/Queercon/src/pages/events/events-details.html new file mode 100644 index 0000000..c1e37db --- /dev/null +++ b/Queercon/src/pages/events/events-details.html @@ -0,0 +1,12 @@ + + + + {{ item.title }} + + + + + + + {{ item.description }} + \ No newline at end of file diff --git a/Queercon/src/pages/events/events.html b/Queercon/src/pages/events/events.html deleted file mode 100644 index 4f5f1c2..0000000 --- a/Queercon/src/pages/events/events.html +++ /dev/null @@ -1,56 +0,0 @@ - - - - - Events - - - - - - - -

Queercon, Inc

- - - - - My Event cool prod - - -

The most awesome party

-
- - -

Start: 2/15/20 2015

-

End: 2/15/20 2015

-
-
-
-
- -

Queercon Locals

- -

QC New York City

- -

QC Seattle

- -

QC DC

- - -

QC San Francisco

- - -

QC Denver

- - -
- - - - -
- - diff --git a/Queercon/src/pages/events/events.scss b/Queercon/src/pages/events/events.scss deleted file mode 100644 index 3c8ba9a..0000000 --- a/Queercon/src/pages/events/events.scss +++ /dev/null @@ -1,2 +0,0 @@ -page-events { -} diff --git a/Queercon/src/pages/events/events.ts b/Queercon/src/pages/events/events.ts index cb647b3..7c1b9f9 100644 --- a/Queercon/src/pages/events/events.ts +++ b/Queercon/src/pages/events/events.ts @@ -1,17 +1,78 @@ import { Component } from '@angular/core'; -import { NavController } from 'ionic-angular'; + +import { NavController, NavParams } from 'ionic-angular'; + @Component({ - selector: 'page-events', - templateUrl: 'events.html' + templateUrl: 'events-details.html', }) -export class EventsPage { - - constructor(public navCtrl: NavController) { +export class EventsDetailsPage { + item; + constructor(params: NavParams) { + this.item = params.data.item; } - +} +@Component({ + template: ` + + + + Events + + + + + + + {{ item.title }} + + + {{ item.summary }} + + + + +` +}) +export class EventsPage { + items = []; -} + constructor(public nav: NavController) { + this.items = [ + { + 'title': 'Event 1', + 'summary': '1111111111', + 'description': 'Blah Blah Blah', + 'host': 'QC' + }, + { + 'title': 'Event 2', + 'summary': '1111111111', + 'description': 'Blah Blah Blah', + 'host': 'QC' + }, + { + 'title': 'Event 3', + 'summary': '1111111111', + 'description': 'Blah Blah Blah', + 'host': 'SEA' + }, + { + 'title': 'Event 4', + 'summary': '1111111111', + 'description': 'Blah Blah Blah', + 'host': 'DC' + }, + ] + } + + openEventDetailsPage(item) { + this.nav.push(EventsDetailsPage, { item: item }); + } + +} \ No newline at end of file diff --git a/Queercon/src/pages/tabs/tabs.html b/Queercon/src/pages/tabs/tabs.html deleted file mode 100644 index ae20da0..0000000 --- a/Queercon/src/pages/tabs/tabs.html +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - diff --git a/Queercon/src/pages/tabs/tabs.ts b/Queercon/src/pages/tabs/tabs.ts deleted file mode 100644 index 4c56ffb..0000000 --- a/Queercon/src/pages/tabs/tabs.ts +++ /dev/null @@ -1,21 +0,0 @@ -import { Component } from '@angular/core'; - -import { EventsPage } from '../events/events'; -import { SupportersPage } from '../supporters/supporters'; -import { ContactPage } from '../contact/contact'; -import { HomePage } from '../home/home'; - -@Component({ - templateUrl: 'tabs.html' -}) -export class TabsPage { - - tab1Root = HomePage; - tab2Root = EventsPage; - tab3Root = SupportersPage; - tab4Root = ContactPage; - - constructor() { - - } -}