Refactoring

This commit is contained in:
2019-09-30 17:54:47 -04:00
parent 89df5efe5a
commit 5b64470d1f
35 changed files with 484 additions and 485 deletions

View File

@@ -22,3 +22,4 @@
</tr> </tr>
</table> </table>
</div> </div>
</div>

View File

@@ -1,6 +1,6 @@
import { Component, OnInit } from '@angular/core'; import { Component, OnInit } from '@angular/core';
import { LaundryService } from '../../services/laundry/laundry.service'; import { LaundryService } from '../../services/laundry/laundry.service';
import { LaundryStatus } from '../../services/laundry/laundry-status'; import { LaundryStatus } from '../../models/laundry/laundry-status';
@Component({ @Component({
selector: 'app-laundry', selector: 'app-laundry',

View File

@@ -9,7 +9,6 @@ import { map, shareReplay } from 'rxjs/operators';
styleUrls: ['./nav.component.scss'] styleUrls: ['./nav.component.scss']
}) })
export class NavComponent { export class NavComponent {
isHandset$: Observable<boolean> = this.breakpointObserver.observe(Breakpoints.Handset) isHandset$: Observable<boolean> = this.breakpointObserver.observe(Breakpoints.Handset)
.pipe( .pipe(
map(result => result.matches), map(result => result.matches),
@@ -17,5 +16,4 @@ export class NavComponent {
); );
constructor(private breakpointObserver: BreakpointObserver) { } constructor(private breakpointObserver: BreakpointObserver) { }
} }

View File

@@ -2,7 +2,7 @@ import { Component, OnInit } from '@angular/core';
import { Chart } from 'angular-highcharts'; import { Chart } from 'angular-highcharts';
import { SeriesLineOptions } from 'highcharts'; import { SeriesLineOptions } from 'highcharts';
import { HttpClient } from '@angular/common/http'; import { HttpClient } from '@angular/common/http';
import { WeatherValue } from '../../../services/weather/weather-value'; import { WeatherValue } from '../../../models/weather/weather-value';
import { ActivatedRoute, ParamMap } from '@angular/router'; import { ActivatedRoute, ParamMap } from '@angular/router';
import * as moment from 'moment'; import * as moment from 'moment';

View File

@@ -1,5 +1,5 @@
import { Component, OnInit } from '@angular/core'; import { Component, OnInit } from '@angular/core';
import { WeatherReading } from '../../../services/weather/weather-reading'; import { WeatherReading } from '../../../models/weather/weather-reading';
import { WeatherService } from '../../../services/weather/weather.service'; import { WeatherService } from '../../../services/weather/weather.service';
@Component({ @Component({

View File

@@ -0,0 +1,7 @@
import { LaundryStatus } from './laundry-status';
describe('LaundryStatus', () => {
it('should create an instance', () => {
expect(new LaundryStatus()).toBeTruthy();
});
});

View File

@@ -0,0 +1,7 @@
import { WeatherReading } from './weather-reading';
describe('WeatherReading', () => {
it('should create an instance', () => {
expect(new WeatherReading()).toBeTruthy();
});
});

View File

@@ -1,7 +0,0 @@
import { LaundryStatus } from './laundry-status';
describe('LaundryStatus', () => {
it('should create an instance', () => {
expect(new LaundryStatus()).toBeTruthy();
});
});

View File

@@ -1,7 +1,7 @@
import { Injectable } from '@angular/core'; import { Injectable } from '@angular/core';
import { Observable, BehaviorSubject } from 'rxjs'; import { Observable, BehaviorSubject } from 'rxjs';
import { Socket } from 'ngx-socket-io'; import { Socket } from 'ngx-socket-io';
import { LaundryStatus } from './laundry-status'; import { LaundryStatus } from '../../models/laundry/laundry-status';
@Injectable({ @Injectable({
providedIn: 'root' providedIn: 'root'

View File

@@ -1,7 +0,0 @@
import { WeatherReading } from './weather-reading';
describe('WeatherReading', () => {
it('should create an instance', () => {
expect(new WeatherReading()).toBeTruthy();
});
});

View File

@@ -1,7 +1,7 @@
import { Injectable } from '@angular/core'; import { Injectable } from '@angular/core';
import { Observable, BehaviorSubject } from 'rxjs'; import { Observable, BehaviorSubject } from 'rxjs';
import { HubConnectionBuilder, HubConnection } from '@aspnet/signalr'; import { HubConnectionBuilder, HubConnection } from '@aspnet/signalr';
import { WeatherReading } from './weather-reading'; import { WeatherReading } from '../../models/weather/weather-reading';
@Injectable({ @Injectable({
providedIn: 'root' providedIn: 'root'