Skip to content
This repository has been archived by the owner on Jun 11, 2019. It is now read-only.

Commit

Permalink
Events Working
Browse files Browse the repository at this point in the history
Basic events #19
  • Loading branch information
jakevis committed Mar 28, 2018
1 parent 619a6e5 commit 7a9c341
Show file tree
Hide file tree
Showing 8 changed files with 114 additions and 99 deletions.
1 change: 0 additions & 1 deletion Queercon/src/app/app.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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 },
Expand Down
38 changes: 33 additions & 5 deletions Queercon/src/app/app.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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';
Expand All @@ -20,8 +20,14 @@ import { SplashScreen } from '@ionic-native/splash-screen';

import { Calendar } from '@ionic-native/calendar';


@NgModule({
declarations: [

EventsPage,

EventsDetailsPage,

MyApp,
NewsPage,
SupportersPage,
Expand All @@ -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,
Expand All @@ -49,7 +78,6 @@ import { Calendar } from '@ionic-native/calendar';
LocalPage,
QcRsa2018Page,
VolunteerPage,
EventsPage,
AboutPage,
ContactPage,
HomePage
Expand Down
12 changes: 12 additions & 0 deletions Queercon/src/pages/events/events-details.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<ion-header>
<ion-navbar>
<ion-title>
{{ item.title }}
</ion-title>
</ion-navbar>
</ion-header>

<ion-content padding>
<ion-icon [name]="'logo-' + item.icon" [ngStyle]="{'color': item.color}"></ion-icon>
{{ item.description }}
</ion-content>
56 changes: 0 additions & 56 deletions Queercon/src/pages/events/events.html

This file was deleted.

2 changes: 0 additions & 2 deletions Queercon/src/pages/events/events.scss

This file was deleted.

77 changes: 69 additions & 8 deletions Queercon/src/pages/events/events.ts
Original file line number Diff line number Diff line change
@@ -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: `
<ion-header>
<ion-navbar>
<button ion-button menuToggle>
<ion-icon name="menu"></ion-icon>
</button>
<ion-title>Events</ion-title>
</ion-navbar>
</ion-header>
<ion-content>
<ion-list>
<ion-card *ngFor="let item of items" (click)="openEventDetailsPage(item)">
<ion-card-header>
{{ item.title }}
</ion-card-header>
<ion-card-content>
{{ item.summary }}
</ion-card-content>
</ion-card>
</ion-list>
</ion-content>
`
})
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 });
}

}
6 changes: 0 additions & 6 deletions Queercon/src/pages/tabs/tabs.html

This file was deleted.

21 changes: 0 additions & 21 deletions Queercon/src/pages/tabs/tabs.ts

This file was deleted.

0 comments on commit 7a9c341

Please sign in to comment.