diff --git a/src/app/modules/shared/components/technologies/technologies.component.html b/src/app/modules/shared/components/technologies/technologies.component.html index 36a4e9e56..4c2b8727a 100644 --- a/src/app/modules/shared/components/technologies/technologies.component.html +++ b/src/app/modules/shared/components/technologies/technologies.component.html @@ -3,7 +3,8 @@ Technology - -
LOADING...
+
+ +
{ this.isLoading = response.isLoading; - const filteredItems = response.technologyList.items.filter(item => !this.selectedTechnologies.includes(item.name)); - this.technology = {items: filteredItems}; + if ( response.technologyList.items ) { + const filteredItems = response.technologyList.items.filter(item => !this.selectedTechnologies.includes(item.name)); + this.technology = {items: filteredItems}; + } else { + this.technology = {items: []}; + } }); } diff --git a/src/app/modules/shared/store/technology.effects.ts b/src/app/modules/shared/store/technology.effects.ts index fecdcc60e..067c1d6ed 100644 --- a/src/app/modules/shared/store/technology.effects.ts +++ b/src/app/modules/shared/store/technology.effects.ts @@ -1,4 +1,3 @@ -import { ToastrService } from 'ngx-toastr'; import { Injectable } from '@angular/core'; import { ofType, Actions, Effect } from '@ngrx/effects'; import { Action } from '@ngrx/store'; @@ -10,7 +9,7 @@ import * as actions from './technology.actions'; @Injectable() export class TechnologyEffects { - constructor(private toastrService: ToastrService, private actions$: Actions, private technologyService: TechnologyService) { } + constructor(private actions$: Actions, private technologyService: TechnologyService) { } @Effect() findTechnology$: Observable = this.actions$.pipe( @@ -22,7 +21,6 @@ export class TechnologyEffects { return new actions.FindTechnologySuccess(technology); }), catchError((error) => { - this.toastrService.error(error.error.message); return of(new actions.FindTechnologyFail(error)); }) ) diff --git a/src/assets/img/spinner.gif b/src/assets/img/spinner.gif new file mode 100644 index 000000000..162ef405e Binary files /dev/null and b/src/assets/img/spinner.gif differ