Closed jenshp closed 5 years ago
I mentioned this in the related issue in mantle-udm: it would be better to use the relatedEnumId on the InvoiceType side of things so there is no risk of multiple PaymentType enums for the same InvoiceType and inconsistent behavior. In other words because we're looking up the PaymentType by the InvoiceType better to just look up the InvoiceType Enumeration record by PK to get a single record and look at relatedEnumId to get the PaymentType to use.
OK, the suggested changes are in as well as the seed data, in https://github.com/moqui/mantle-udm/pull/79.
In create#InvoicePayment, set paymentTypeEnumId according to InvoiceType mapping if not specified.
See details in https://github.com/moqui/mantle-udm/pull/77 pull request.