Commit 68d5fa20 by Emil Holsti

eventList init

1 parent 1fa9a0fe
...@@ -68,6 +68,14 @@ ...@@ -68,6 +68,14 @@
"tslib": "1.9.0" "tslib": "1.9.0"
} }
}, },
"@angular/cdk": {
"version": "5.2.4",
"resolved": "https://registry.npmjs.org/@angular/cdk/-/cdk-5.2.4.tgz",
"integrity": "sha1-wKQpqHENj+2xV/VG4hy0nUM19/c=",
"requires": {
"tslib": "1.9.0"
}
},
"@angular/cli": { "@angular/cli": {
"version": "1.7.3", "version": "1.7.3",
"resolved": "https://registry.npmjs.org/@angular/cli/-/cli-1.7.3.tgz", "resolved": "https://registry.npmjs.org/@angular/cli/-/cli-1.7.3.tgz",
...@@ -201,6 +209,14 @@ ...@@ -201,6 +209,14 @@
"integrity": "sha512-aaLnGpW9NBDkG0JYqUeGc+al1Jd1CY9yrs3mew53x5nByetQbIdZwpYm1hnSTw7LBEZBxfHTMw5EZD2YYTDmJw==", "integrity": "sha512-aaLnGpW9NBDkG0JYqUeGc+al1Jd1CY9yrs3mew53x5nByetQbIdZwpYm1hnSTw7LBEZBxfHTMw5EZD2YYTDmJw==",
"dev": true "dev": true
}, },
"@angular/material": {
"version": "5.2.4",
"resolved": "https://registry.npmjs.org/@angular/material/-/material-5.2.4.tgz",
"integrity": "sha1-noI3mDJCg9I+qDkVb6xby3NEPVU=",
"requires": {
"tslib": "1.9.0"
}
},
"@angular/platform-browser": { "@angular/platform-browser": {
"version": "5.2.9", "version": "5.2.9",
"resolved": "https://registry.npmjs.org/@angular/platform-browser/-/platform-browser-5.2.9.tgz", "resolved": "https://registry.npmjs.org/@angular/platform-browser/-/platform-browser-5.2.9.tgz",
......
...@@ -13,12 +13,14 @@ ...@@ -13,12 +13,14 @@
}, },
"private": true, "private": true,
"dependencies": { "dependencies": {
"@angular/animations": "^5.2.0", "@angular/animations": "^5.2.9",
"@angular/cdk": "^5.2.4",
"@angular/common": "^5.2.0", "@angular/common": "^5.2.0",
"@angular/compiler": "^5.2.0", "@angular/compiler": "^5.2.0",
"@angular/core": "^5.2.0", "@angular/core": "^5.2.0",
"@angular/forms": "^5.2.0", "@angular/forms": "^5.2.0",
"@angular/http": "^5.2.0", "@angular/http": "^5.2.0",
"@angular/material": "^5.2.4",
"@angular/platform-browser": "^5.2.0", "@angular/platform-browser": "^5.2.0",
"@angular/platform-browser-dynamic": "^5.2.0", "@angular/platform-browser-dynamic": "^5.2.0",
"@angular/router": "^5.2.0", "@angular/router": "^5.2.0",
......
...@@ -5,4 +5,4 @@ ...@@ -5,4 +5,4 @@
</h1> </h1>
<img width="300" alt="Angular Logo" src="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyNTAgMjUwIj4KICAgIDxwYXRoIGZpbGw9IiNERDAwMzEiIGQ9Ik0xMjUgMzBMMzEuOSA2My4ybDE0LjIgMTIzLjFMMTI1IDIzMGw3OC45LTQzLjcgMTQuMi0xMjMuMXoiIC8+CiAgICA8cGF0aCBmaWxsPSIjQzMwMDJGIiBkPSJNMTI1IDMwdjIyLjItLjFWMjMwbDc4LjktNDMuNyAxNC4yLTEyMy4xTDEyNSAzMHoiIC8+CiAgICA8cGF0aCAgZmlsbD0iI0ZGRkZGRiIgZD0iTTEyNSA1Mi4xTDY2LjggMTgyLjZoMjEuN2wxMS43LTI5LjJoNDkuNGwxMS43IDI5LjJIMTgzTDEyNSA1Mi4xem0xNyA4My4zaC0zNGwxNy00MC45IDE3IDQwLjl6IiAvPgogIDwvc3ZnPg=="> <img width="300" alt="Angular Logo" src="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyNTAgMjUwIj4KICAgIDxwYXRoIGZpbGw9IiNERDAwMzEiIGQ9Ik0xMjUgMzBMMzEuOSA2My4ybDE0LjIgMTIzLjFMMTI1IDIzMGw3OC45LTQzLjcgMTQuMi0xMjMuMXoiIC8+CiAgICA8cGF0aCBmaWxsPSIjQzMwMDJGIiBkPSJNMTI1IDMwdjIyLjItLjFWMjMwbDc4LjktNDMuNyAxNC4yLTEyMy4xTDEyNSAzMHoiIC8+CiAgICA8cGF0aCAgZmlsbD0iI0ZGRkZGRiIgZD0iTTEyNSA1Mi4xTDY2LjggMTgyLjZoMjEuN2wxMS43LTI5LjJoNDkuNGwxMS43IDI5LjJIMTgzTDEyNSA1Mi4xem0xNyA4My4zaC0zNGwxNy00MC45IDE3IDQwLjl6IiAvPgogIDwvc3ZnPg==">
</div> </div>
<moya-organization-list></moya-organization-list> <moya-event-list></moya-event-list>
\ No newline at end of file \ No newline at end of file
<p> <mat-card *ngFor="let event of events" style="width:40%;margin:1em;">
event-list works! <mat-card-title>{{event.title}}</mat-card-title>
</p> <mat-card-subtitle>{{event.date}}</mat-card-subtitle>
<mat-card-actions>
<button mat-raised-button color="primary" (click)="onClick()" style="float:right;margin-top:-5em;margin-right:1em;">Edit</button>
</mat-card-actions>
</mat-card>
\ No newline at end of file
@import "~@angular/material/prebuilt-themes/indigo-pink.css";
\ No newline at end of file
...@@ -7,8 +7,19 @@ import { Component, OnInit } from '@angular/core'; ...@@ -7,8 +7,19 @@ import { Component, OnInit } from '@angular/core';
}) })
export class EventListComponent implements OnInit { export class EventListComponent implements OnInit {
public events = [
{title: 'Assembly Winter 18', date: '1.2.2018 - 3.2.2018'},
{title: 'Assembly Summer 18', date: '1.2.2018 - 3.2.2018'},
{title: 'Assembly Winter 19', date: '1.2.2018 - 3.2.2018'},
{title: 'Assembly Summer 19', date: '1.2.2018 - 3.2.2018'}
];
constructor() { } constructor() { }
onClick() {
console.log('Nappitoimii');
}
ngOnInit() { ngOnInit() {
} }
......
...@@ -3,10 +3,16 @@ import { CommonModule } from '@angular/common'; ...@@ -3,10 +3,16 @@ import { CommonModule } from '@angular/common';
import { NewOrganizationComponent } from './new-organization/new-organization.component'; import { NewOrganizationComponent } from './new-organization/new-organization.component';
import { OrganizationListComponent } from './organization-list/organization-list.component'; import { OrganizationListComponent } from './organization-list/organization-list.component';
import { EventListComponent } from './event-list/event-list.component'; import { EventListComponent } from './event-list/event-list.component';
import {BrowserAnimationsModule} from '@angular/platform-browser/animations';
import {MatCardModule} from '@angular/material/card';
import {MatButtonModule} from '@angular/material';
@NgModule({ @NgModule({
imports: [ imports: [
CommonModule CommonModule,
BrowserAnimationsModule,
MatCardModule,
MatButtonModule
], ],
declarations: [NewOrganizationComponent, OrganizationListComponent, EventListComponent], declarations: [NewOrganizationComponent, OrganizationListComponent, EventListComponent],
exports: [NewOrganizationComponent, OrganizationListComponent, EventListComponent], exports: [NewOrganizationComponent, OrganizationListComponent, EventListComponent],
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!