add refundBankAccount to DebitorEntityPatcher

This commit is contained in:
Michael Hoennig 2024-01-20 14:46:35 +01:00
parent e4f772a049
commit 2ed639bbde

View File

@ -44,6 +44,10 @@ class HsOfficeDebitorEntityPatcher implements EntityPatcher<HsOfficeDebitorPatch
verifyNotNull(newValue, "defaultPrefix");
entity.setDefaultPrefix(newValue);
});
OptionalFromJson.of(resource.getRefundBankAccountUuid()).ifPresent(newValue -> {
verifyNotNull(newValue, "refundBankAccount");
entity.setRefundBankAccount(em.getReference(HsOfficeBankAccountEntity.class, newValue));
});
}
private void verifyNotNull(final Object newValue, final String propertyName) {