Closed alexander-albers closed 3 years ago
When enabling the Berlkönig flag, always getting a Berlkönig trip as the very first trip result is probably very annoying, as it is often times way slower than taking a regular train/bus. My new resolution is setting the following jnyFilterIncludes:
[
["value": "BERLKOENIG", "mode": "INC", "type": "GROUP"],
["value": "berlkoenig", "mode": "EXC", "type": "GISPROD"]
]
It might seem unnecessary to first enable the product and then disable it again right away, but this is also what the official BVG App does when disabling the product. The main advantage is that we still find all regular trips, like the trip mentioned above, while excluding Berlkönig products from the search results. Not including both flags would again lead to an error for the above mentioned trip.
BVG requires, for whatever reason, that the product type "BERLKOENIG" is included, or otherwise some trips may fail, even if those don't include any Berlkönig products.
See for example this request:
However, enabling this option leads to a new JNY-type named "KISS", which is currently not handled and results in a parse error.
--> Revert this commit after KISS is handled: https://github.com/alexander-albers/tripkit/commit/b04f52c0b1cf1f2bae755cd6a2c7f9ca479a11e9