Address format wrong in report
In the report, the address should be shown as "the house name or number and the postcode".
CRM_Civigiftaid_Declaration::getDonorAddress()
returns a house
field as the first part of the stored address up to a comma. This would work if the stored address was structured correctly.
But getAddressAndPostalCode()
and getFormattedAddress()
that are used to set the address on the declaration do not attempt to extract the house name or number.
There was some work on this in 7325f5dc
There was a regexp in getHouseNo()
attempting to extract the house name/number but it was removed in that commit.
It seems the intent was to move the house number matching to the point where the address is stored on the declaration, rather than when the address is read from the declaration. But I don't see that the house name/number extraction made it to the declaration setting stage.
Before attempting to fix this, I'd like some confirmation that the intention is that the address stored on the declaration is a single string formatted such that the house name/number required for the report is the first part of the address up to a comma.