Update event image source to use new auto calendar generator
parent
781760812b
commit
981215e445
File diff suppressed because it is too large
Load Diff
|
|
@ -4,9 +4,9 @@
|
|||
"license": "MIT",
|
||||
"scripts": {
|
||||
"ng": "ng",
|
||||
"servehelena":"ng serve -host 192.168.43.144",
|
||||
"servebutte":"ng serve -host 192.168.2.8",
|
||||
"servebutteprod":"ng serve -host 192.168.2.8 --prod",
|
||||
"servehelena": "ng serve -host 192.168.43.144",
|
||||
"servebutte": "ng serve -host 192.168.2.8",
|
||||
"servebutteprod": "ng serve -host 192.168.2.8 --prod",
|
||||
"start": "ng serve",
|
||||
"build": "ng build",
|
||||
"test": "ng test",
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
<div class="wrapper" [@inout]="startFadeIn">
|
||||
<div class="photo">
|
||||
<button md-button (click)="toggleState()">
|
||||
<img src="../../assets/images/event_back.png" />
|
||||
<img src="{{imgSrc}}" />
|
||||
</button>
|
||||
</div><!--
|
||||
--><div class="info" (click)="toggleState()">
|
||||
|
|
|
|||
|
|
@ -1,6 +1,8 @@
|
|||
import { Component, AfterContentInit, Input } from '@angular/core';
|
||||
import { trigger, state, style, transition, animate } from '@angular/animations';
|
||||
|
||||
import { MONTHS_FULL } from '../../constants/months';
|
||||
|
||||
@Component({
|
||||
selector: 'event-large-component',
|
||||
templateUrl: './event-large.component.html',
|
||||
|
|
@ -54,6 +56,14 @@ export class EventLargeComponent implements AfterContentInit {
|
|||
@Input()
|
||||
public delayFadeIn: number = 100;
|
||||
|
||||
public _imgSrc: string;
|
||||
public get imgSrc(): string{
|
||||
var monthNum = this.startDate.getMonth();
|
||||
var monthName = '';
|
||||
monthName = MONTHS_FULL[monthNum];
|
||||
return "/cim/" + monthName + "/" + this.startDate.getDate();
|
||||
}
|
||||
|
||||
constructor(){
|
||||
console.log(this.title);
|
||||
}
|
||||
|
|
@ -72,3 +82,4 @@ export class EventLargeComponent implements AfterContentInit {
|
|||
}
|
||||
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -11,4 +11,19 @@ export const MONTHS = {
|
|||
9: "OCT",
|
||||
10: "NOV",
|
||||
11: "DEC"
|
||||
};
|
||||
|
||||
export const MONTHS_FULL = {
|
||||
0: "JANUARY",
|
||||
1: "FEBRUARY",
|
||||
2: "MARCH",
|
||||
3: "APRIL",
|
||||
4: "MAY",
|
||||
5: "JUNE",
|
||||
6: "JULY",
|
||||
7: "AUGUST",
|
||||
8: "SEPTEMBER",
|
||||
9: "OCTOBER",
|
||||
10: "NOVEMBER",
|
||||
11: "DECEMBER"
|
||||
};
|
||||
Loading…
Reference in New Issue