Fix searchParams readonly error in the subission

This commit is contained in:
Art Lowel
2019-11-28 10:41:06 +01:00
parent 77f6294bde
commit f72343bd8e

View File

@@ -71,7 +71,9 @@ export class CollectionDataService extends ComColDataService<Collection> {
*/
getAuthorizedCollectionByCommunity(communityId: string, options: FindAllOptions = {}): Observable<RemoteData<PaginatedList<Collection>>> {
const searchHref = 'findAuthorizedByCommunity';
options.searchParams = [new SearchParam('uuid', communityId)];
options = Object.assign({}, options, {
searchParams: [new SearchParam('uuid', communityId)]
});
return this.searchBy(searchHref, options).pipe(
filter((collections: RemoteData<PaginatedList<Collection>>) => !collections.isResponsePending));