Open sbts opened 8 years ago
For prepayments, certainly payments could be made before the invoice was opened, btw.
if the user decides to go through, we might create an overpayment and a payment-from-overpayment in the background.
The initial solution I see here is to add a JS check on the invoice and (single) payment screens which warns once and then will simply allow the transaction if the user forces ahead. (From there, we can add other behaviours later.)
Thinking that this can be achieved with a bit of JS in the invoice entry form as well as the single and bulk payment screens
At least for invoices and payments nonsense dates can be entered. eg: invoice due date that is before the invoice date. Payment Date before invoice opening date. This can cause issues with reports showing completely incorrect figures for a given period (even nagative ones) compaired to what the user may expect, although if you run the report over a broad enough window (ie: encompasing all involved dates) the report would be correct.
Some date sanity checking and error reporting is required. Including prevention of future dates being used (although a grace period may be useful) Once we can "lock" periods (eg: previous financial years) historical dates should also raise an error.