Merge branch 'develop' of https://git.akkerweb.nl/FarmMaps/FarmMapsLib into develop
All checks were successful
FarmMaps.Develop/FarmMapsLib/pipeline/head This commit looks good

This commit is contained in:
Willem Dantuma 2020-08-05 10:34:04 +02:00
commit dfefa6746f

View File

@ -62,9 +62,8 @@ export class AppCommonEffects {
@Effect() @Effect()
initUserPackages$:Observable<Action> = this.actions$.pipe( initUserPackages$:Observable<Action> = this.actions$.pipe(
ofType(appCommonActions.INITUSERPACKAGES), ofType(appCommonActions.INITUSERPACKAGES),
withLatestFrom(this.store$.select(appCommonReducers.SelectGetUser)), switchMap(() => {
switchMap(([action,user]) => { return this.itemService$.getItemList('vnd.farmmaps.itemtype.package').pipe(
return this.itemService$.getChildItemList(user.code+":USER_PACKAGES","vnd.farmmaps.itemtype.package").pipe(
switchMap((items) => of(new appCommonActions.InitUserPackagesSuccess(items))), switchMap((items) => of(new appCommonActions.InitUserPackagesSuccess(items))),
catchError(error => of(new appCommonActions.Fail(error))) catchError(error => of(new appCommonActions.Fail(error)))
) )