Fix AW-1056, AW-1080
All checks were successful
FarmMaps.Develop/FarmMapsLib/develop This commit looks good
All checks were successful
FarmMaps.Develop/FarmMapsLib/develop This commit looks good
This commit is contained in:
parent
8db1edb262
commit
bc17f80050
@ -192,7 +192,7 @@ export class MapComponent implements OnInit, OnDestroy,AfterViewInit {
|
|||||||
newQueryState = this.serializeService.deserialize(queryState);
|
newQueryState = this.serializeService.deserialize(queryState);
|
||||||
queryState = this.serializeService.serialize(newQueryState);
|
queryState = this.serializeService.serialize(newQueryState);
|
||||||
}
|
}
|
||||||
queryStateChanged = this.serializeService.serialize(lastQueryState) != queryState;
|
queryStateChanged = this.serializeService.serialize(lastQueryState) != queryState || setStateCount==0;
|
||||||
}
|
}
|
||||||
let t =0;
|
let t =0;
|
||||||
if(setStateCount==0) t=600;
|
if(setStateCount==0) t=600;
|
||||||
|
@ -149,10 +149,11 @@ export class MapEffects {
|
|||||||
selectItem$: Observable<Action> = this.actions$.pipe(
|
selectItem$: Observable<Action> = this.actions$.pipe(
|
||||||
ofType(mapActions.SELECTITEM),
|
ofType(mapActions.SELECTITEM),
|
||||||
withLatestFrom(this.store$.select(mapReducers.selectGetSelectedItem)),
|
withLatestFrom(this.store$.select(mapReducers.selectGetSelectedItem)),
|
||||||
switchMap(([action, selectedItem]) => {
|
withLatestFrom(this.store$.select(mapReducers.getSetStateCount)),
|
||||||
|
switchMap(([[action, selectedItem],setStateCount]) => {
|
||||||
let a = action as mapActions.SelectItem;
|
let a = action as mapActions.SelectItem;
|
||||||
let itemCode = selectedItem ? selectedItem.code : "";
|
let itemCode = selectedItem ? selectedItem.code : "";
|
||||||
if (a.itemCode != itemCode) {
|
if (a.itemCode != itemCode || setStateCount == 1) {
|
||||||
return this.itemService$.getItem(a.itemCode).pipe(
|
return this.itemService$.getItem(a.itemCode).pipe(
|
||||||
map((item: IItem) => new mapActions.SelectItemSuccess(item)),
|
map((item: IItem) => new mapActions.SelectItemSuccess(item)),
|
||||||
catchError(error => of(new commonActions.Fail(error))))
|
catchError(error => of(new commonActions.Fail(error))))
|
||||||
|
Loading…
Reference in New Issue
Block a user