Skip to content
This repository has been archived by the owner on Mar 8, 2021. It is now read-only.

addMoneyToSavingsGoal requires amount in pence #5

Open
twstuart opened this issue Oct 15, 2018 · 0 comments
Open

addMoneyToSavingsGoal requires amount in pence #5

twstuart opened this issue Oct 15, 2018 · 0 comments

Comments

@twstuart
Copy link
Contributor

It appears there is a mismatch between a transaction value and adding money to a savings goal.

When retrieving Transactions, these are retrieved in decimalised pounds (ie 44.32, £44.32).
When calling: /savings-goals/$savingsGoalUid/add-money/$transactionUID, it appears the payload amount is expected in in pence (ie 500, £5).

Simple fix would be to amount = amount.multiply(new BigDecimal(100)) within the addMoneyToSavingsGoal method.

Alternatively a separate AmountInPence could be created to satisfy the requirement.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant