Closed westnordost closed 2 years ago
In the implemented solution, leistungsBeginn
and leistungsEnde
is optional in all types of Leistung
, even though leistungsBeginn
is only mandatory for verguetungsart
04 and leistungsEnde
is only mandatory for verguetungsart
01, 02, 03 or 04. I did this because you have some logic in index.ts
that assumes that any Leistung potentially has these fields defined (for grouping and sorting Leistungen by time/date). I wasn't sure if you'd be okay with changing this logic. You might argue that for convenience/consistency reasons, you'd want the user in coop-care to always specify the start and end time of any Leistung in the UI even when it is not necessary for billing.
I can change this to be stricter, if you wish. I.e. e.g. leistungsBeginn
would be a field in VollstationaerOderKurzzeitpflegeLeistung
only.
Review note: Look at types.ts first.
It has been some time since I looked at it. But I think that's fair enough - if the type is removed, there should simply be a documentation comment that explains that hte optional field is actually mandatory if XYZ.
Do you expect me to change this or will you do it?
I will take care of it.
Issue
leistung
field for theELS
segment should contain a completely different information depending on the type of Leistung, i.e. depending on the value ofverguetungsart
. This makes it to cite yourself "insanely complex"verguetungsart
. As a user of this library, one would need to read through the GKV docs again to find out what one is expected to specify.Solution
Just type it. A Leistung can be a "Wegegeld Leistung", a "Zeitvergütung Leistung", a "Pflegehilfsmittel Leistung" etc. Depending on the type of Leistung, different fields are mandatory and the fields are named and typed according to what should be filled in.