Fix [1902240] BanksStatement beggining balance not working

This commit is contained in:
armenrz 2008-02-28 04:21:52 +00:00
parent 358e5bc4ab
commit a6668e11b9
1 changed files with 0 additions and 12 deletions

View File

@ -326,11 +326,6 @@ public class MBankStatement extends X_C_BankStatement implements DocAction
maxDate = line.getDateAcct();
}
setStatementDifference(total);
//AZ Goodwill
//refresh current balance
MBankAccount ba = MBankAccount.get(getCtx(), getC_BankAccount_ID());
setBeginningBalance(ba.getCurrentBalance());
//end AZ
setEndingBalance(getBeginningBalance().add(total));
if (!MPeriod.isOpen(getCtx(), minDate, MDocType.DOCBASETYPE_BankStatement)
|| !MPeriod.isOpen(getCtx(), maxDate, MDocType.DOCBASETYPE_BankStatement))
@ -465,13 +460,6 @@ public class MBankStatement extends X_C_BankStatement implements DocAction
return false; // could not delete
}
//Added Lines by AZ Goodwill
//Recover Bank Account
MBankAccount ba = MBankAccount.get(getCtx(), getC_BankAccount_ID());
ba.setCurrentBalance(ba.getCurrentBalance().subtract(getStatementDifference()));
ba.save(get_TrxName());
//End of Added Lines
// Set lines to 0
MBankStatementLine[] lines = getLines(true);
for (int i = 0; i < lines.length; i++)