diff --git a/claims/claim-utils/claimResults.component.ts b/claims/claim-utils/claimResults.component.ts index 631f6a3f..71170a35 100644 --- a/claims/claim-utils/claimResults.component.ts +++ b/claims/claim-utils/claimResults.component.ts @@ -28,11 +28,11 @@ declare var UIkit: any; height="1"> - + - + @@ -78,6 +78,27 @@ export class ClaimResultsComponent { if (this.selectedResults != null) { localStorage.setItem(this.localStoragePrefix, JSON.stringify(this.selectedResults)); } + UIkit.notification(item.type + ' added in your basket!', { + status: 'success', + timeout: 4000, + pos: 'bottom-right' + }); } } + + remove(item: any) { + const index: number = this.selectedResults.indexOf(item); + if (index > -1) { + this.selectedResults.splice(index, 1); + if (this.selectedResults != null) { + localStorage.setItem(this.localStoragePrefix, JSON.stringify(this.selectedResults)); + } + UIkit.notification(item.type + ' removed from your basket!', { + status: 'warning', + timeout: 4000, + pos: 'bottom-right' + }); + } + + } } diff --git a/claims/linking/selected/selectedResults.component.ts b/claims/linking/selected/selectedResults.component.ts index add80f71..6119e1e1 100644 --- a/claims/linking/selected/selectedResults.component.ts +++ b/claims/linking/selected/selectedResults.component.ts @@ -1,6 +1,6 @@ import {Component, Input} from '@angular/core'; import {ClaimEntity} from '../../claim-utils/claimHelper.class'; - +declare var UIkit: any; @Component({ selector: 'claim-selected-results', templateUrl: 'selectedResults.component.html' @@ -24,6 +24,11 @@ export class ClaimSelectedResultsComponent { if (this.results != null) { localStorage.setItem(this.localStoragePrefix, JSON.stringify(this.results)); } + UIkit.notification(item.type + ' removed from your basket!', { + status: 'warning', + timeout: 4000, + pos: 'bottom-right' + }); } }