Comment 24 for bug 800478

Revision history for this message
Bill Erickson (berick) wrote : Re: [Bug 800478] Re: Acquisitions - Funds transfer always transfers entire fund, not specified amount

On Mon, Mar 3, 2014 at 2:13 PM, Liam Whalen <email address hidden> wrote:
<snip>

> If removes the parameter that passed in the converted amount to be
> transferred to the new fund. This causes a problem if the rate used to
> convert outside of the function is different from the rate in
> acq.exchange_rate.
>

The purpose of this parameter is to allow staff to enter transfers where
the money has already been converted into the new currency. In this case,
the exact amounts are known in advance and the caller does not want to rely
on the configured exchange rate, particularly since the exchange rate used
for the conversion may no longer be applicable.

This seems like an important feature to keep, no? What problems was it
causing, exactly?

<snip>

> This commit also adds two columns to acq.fund_allocation: fund_amount
> and conversion_ratio. fund_amount is the amount allocated in the
> currency of the fund receiving the allocation. This will allow the
> system to display the total value in the fund without that value
> changing due to changes in the exchange rate.
>
> Currently, because the amount transferred is stored in the currency of
> the source, if the source and fund have different currencies then the
> VIEW acq.fund_allocation_total changes depending on the rate of
> exchange.
>

+1 to storing these.

>
> However, if 100 US allocated to a CDN account at 1 to 1 then that
> account has 100 CDN regardless of future rate changes. So that total
> needs to stay at 100.
>

Maybe we need a way to indicate when a fund_allocation is "final" or not.
 In the case of a physical transfer of money, the allocation would be
marked as "final" and fund_allocation.fund_amount would be used to
determine the true amount allocated (e.g. by acq.fund_allocation_total).
 For other allocations and transfers, where the currency conversion does
not occur until later, like when the money is spent, we continue relying on
fund_allocation.amount, since it tracks the current exchange rate.

-b

--
Bill Erickson
| Senior Software Developer
| phone: 877-OPEN-ILS (673-6457)
| email: <email address hidden>
| web: http://esilibrary.com
| Equinox Software, Inc. / The Open Source Experts