Bulk Deletion (#697)
* Implemented bulk deletion of series * Don't show unauthorized exception on UI, just redirect to the login page.
This commit is contained in:
parent
e3b33bcbf9
commit
6d6eee999a
12 changed files with 107 additions and 7 deletions
|
|
@ -467,4 +467,21 @@ export class ActionService implements OnDestroy {
|
|||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Mark all chapters and the volumes as Read. All volumes and chapters must belong to a series
|
||||
* @param seriesId Series Id
|
||||
* @param volumes Volumes, should have id, chapters and pagesRead populated
|
||||
* @param chapters? Chapters, should have id
|
||||
* @param callback Optional callback to perform actions after API completes
|
||||
*/
|
||||
deleteMultipleSeries(seriesIds: Array<Series>, callback?: VoidActionCallback) {
|
||||
this.seriesService.deleteMultipleSeries(seriesIds.map(s => s.id)).pipe(take(1)).subscribe(() => {
|
||||
this.toastr.success('Series deleted');
|
||||
|
||||
if (callback) {
|
||||
callback();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue