WIP Last added album
This commit is contained in:
@@ -5,13 +5,15 @@ import { DashboardComponent } from './dashboard.component';
|
||||
import { AlbumComponent } from './album/album.component';
|
||||
import { ArtistComponent } from './artist/artist.component';
|
||||
import { GenreComponent } from './genre/genre.component';
|
||||
import { LastAddedComponent } from './last-added/last-added.component';
|
||||
|
||||
const routes: Routes = [
|
||||
{ path: '', redirectTo: '/dashboard', pathMatch: 'full' },
|
||||
{ path: 'dashboard', component: DashboardComponent },
|
||||
{ path: 'album/:name', component: AlbumComponent },
|
||||
{ path: 'artist/:name', component: ArtistComponent },
|
||||
{ path: 'genre/:name', component: GenreComponent }
|
||||
{ path: 'genre/:name', component: GenreComponent },
|
||||
{ path: 'lastAdded', component: LastAddedComponent }
|
||||
];
|
||||
|
||||
@NgModule({
|
||||
|
||||
@@ -18,6 +18,8 @@ import { ConvertMoreExactPipe } from './convert-more-exact.pipe';
|
||||
import { SortByPipe } from './sort-by.pipe';
|
||||
import { ConvertSizeToStringPipe } from './convert-size-to-string.pipe';
|
||||
|
||||
import { LastAddedComponent } from './last-added/last-added.component';
|
||||
|
||||
@NgModule({
|
||||
imports: [
|
||||
BrowserModule,
|
||||
@@ -31,6 +33,7 @@ import { ConvertSizeToStringPipe } from './convert-size-to-string.pipe';
|
||||
ArtistComponent,
|
||||
GenreComponent,
|
||||
SongTableComponent,
|
||||
LastAddedComponent,
|
||||
ConvertMsPipe,
|
||||
ConvertMoreExactPipe,
|
||||
SortByPipe,
|
||||
|
||||
@@ -78,7 +78,7 @@
|
||||
</div>
|
||||
|
||||
<div class="col-md-12">
|
||||
<h3>Last added albums</h3>
|
||||
<h3><a [routerLink]="['/lastAdded']">Last Added</a></h3>
|
||||
|
||||
<table class="table table-striped">
|
||||
<thead>
|
||||
|
||||
2
dashboard/src/app/last-added/last-added.component.html
Normal file
2
dashboard/src/app/last-added/last-added.component.html
Normal file
@@ -0,0 +1,2 @@
|
||||
<div class="container">
|
||||
</div>
|
||||
25
dashboard/src/app/last-added/last-added.component.spec.ts
Normal file
25
dashboard/src/app/last-added/last-added.component.spec.ts
Normal file
@@ -0,0 +1,25 @@
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
|
||||
import { LastAddedComponent } from './last-added.component';
|
||||
|
||||
describe('LastAddedComponent', () => {
|
||||
let component: LastAddedComponent;
|
||||
let fixture: ComponentFixture<LastAddedComponent>;
|
||||
|
||||
beforeEach(async(() => {
|
||||
TestBed.configureTestingModule({
|
||||
declarations: [ LastAddedComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
}));
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(LastAddedComponent);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should be created', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
15
dashboard/src/app/last-added/last-added.component.ts
Normal file
15
dashboard/src/app/last-added/last-added.component.ts
Normal file
@@ -0,0 +1,15 @@
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
|
||||
@Component({
|
||||
selector: 'app-last-added',
|
||||
templateUrl: './last-added.component.html',
|
||||
styleUrls: ['./last-added.component.css']
|
||||
})
|
||||
export class LastAddedComponent implements OnInit {
|
||||
|
||||
constructor() { }
|
||||
|
||||
ngOnInit() {
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user