:fixed filtering by berth id, also including outgoing and shifting moves

This commit is contained in:
Daniel Schick 2024-01-05 08:09:54 +01:00
parent 94fcf75d4c
commit c24bc981b0

View File

@ -516,7 +516,8 @@ namespace BreCalClient
if(sfm.Berths.Count > 0 )
{
this._visibleControlModels.RemoveAll(x => !sfm.Berths.Contains((x.Shipcall?.ArrivalBerthId) ?? -1));
this._visibleControlModels.RemoveAll(x => (!sfm.Berths.Contains((x.Shipcall?.ArrivalBerthId) ?? -1) && (x.Shipcall?.Type == (int) Extensions.TypeEnum.Incoming)) ||
(!sfm.Berths.Contains((x.Shipcall?.DepartureBerthId) ?? -1) && (x.Shipcall?.Type != (int) Extensions.TypeEnum.Incoming)));
}
if(sfm.Agencies.Count > 0 )