customer available events improvements
This commit is contained in:
6
customer/app/src/app/app.types.ts
Normal file
6
customer/app/src/app/app.types.ts
Normal file
@@ -0,0 +1,6 @@
|
||||
import {Event, Registration} from "./services/event.service";
|
||||
|
||||
export interface CalendarEvent{
|
||||
event: Event;
|
||||
registrations: Registration;
|
||||
}
|
||||
@@ -1,25 +0,0 @@
|
||||
import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
|
||||
|
||||
import { MonthCalendarDayComponent } from './month-calendar-day.component';
|
||||
|
||||
describe('MonthCalendarDayComponent', () => {
|
||||
let component: MonthCalendarDayComponent;
|
||||
let fixture: ComponentFixture<MonthCalendarDayComponent>;
|
||||
|
||||
beforeEach(waitForAsync(() => {
|
||||
TestBed.configureTestingModule({
|
||||
declarations: [ MonthCalendarDayComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
}));
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(MonthCalendarDayComponent);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
@@ -5,7 +5,7 @@
|
||||
<h5 *ngFor="let dayOfWeek of daysOfWeek" class="col-sm p-1 text-center name-of-day-of-week">{{dayOfWeek.name}}</h5>
|
||||
</div>
|
||||
</header>
|
||||
<div *ngIf="eventsAvailableResponse" class="row border border-right-0 border-bottom-0">
|
||||
<div *ngIf="eventsAvailableResponse" class="row border border-right-0 border-bottom-0 mb-4">
|
||||
<ng-container *ngFor="let day of eventsAvailableResponse.dates; let i = index">
|
||||
<div app-month-calendar-day [day]="day" (onEvent)="handleEvent($event)" ></div>
|
||||
<div *ngIf="i > 0 && ( ((i+1) % 7) == 0)" class="w-100"></div>
|
||||
|
||||
@@ -1,25 +0,0 @@
|
||||
import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
|
||||
|
||||
import { MonthCalendarComponent } from './month-calendar.component';
|
||||
|
||||
describe('MonthCalendarComponent', () => {
|
||||
let component: MonthCalendarComponent;
|
||||
let fixture: ComponentFixture<MonthCalendarComponent>;
|
||||
|
||||
beforeEach(waitForAsync(() => {
|
||||
TestBed.configureTestingModule({
|
||||
declarations: [ MonthCalendarComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
}));
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(MonthCalendarComponent);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
@@ -1,25 +0,0 @@
|
||||
import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
|
||||
|
||||
import { EventsComponent } from './events.component';
|
||||
|
||||
describe('EventsComponent', () => {
|
||||
let component: EventsComponent;
|
||||
let fixture: ComponentFixture<EventsComponent>;
|
||||
|
||||
beforeEach(waitForAsync(() => {
|
||||
TestBed.configureTestingModule({
|
||||
declarations: [ EventsComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
}));
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(EventsComponent);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
@@ -1,6 +1,6 @@
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
import {EventsAvailableResponse, EventService} from "../../services/event.service";
|
||||
import {Observable} from "rxjs";
|
||||
import {forkJoin, Observable} from "rxjs";
|
||||
import {MonthCalendarEvent} from "../../components/month-calendar/month-calendar.component";
|
||||
import {NavigationService} from "../../services/navigation.service";
|
||||
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
import {Injectable} from '@angular/core';
|
||||
import {HttpClient} from "@angular/common/http";
|
||||
import {Endpoints} from "./endpoints";
|
||||
import {Observable} from "rxjs";
|
||||
import {forkJoin, Observable} from "rxjs";
|
||||
import {map} from "rxjs/operators";
|
||||
import {CalendarEvent} from "../app.types";
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
|
||||
Reference in New Issue
Block a user