Anonymous | Login
Project:
RSS
  
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0034322
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] Z. Othersmajoralways2016-10-27 14:082016-12-16 18:38
ReporterngarciaView Statuspublic 
Assigned Torqueralta 
PriorityurgentResolutionfixedFixed in Version3.0PR17Q1
StatusclosedFix in branchFixed in SCM revision9e84e90e2f2a
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned Toaferraz
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0034322: Payment of 0 amount created when voiding an unpaid invoice is created in Awaiting Execution status

DescriptionPayment of 0 amount created when voiding an unpaid invoice is created in Awaiting Execution status.

The execution process associated to the payment method of the invoice should not be executed in this case
Steps To ReproduceAs system admin role:
   Install Remittances Infrastructure module
As group admin role:
   Apply the module's dataset
   Include the Remittance payment method in a financial account
   Create a Sales Invoice with that payment method
   Add a line to it, complete it and do not add any payment to it
   Void it
   Check the payment that includes both the original and the voiding invoice is in Awaiting Execution status
   Check the Sales Invoice is set as not paid until you execute the Payment In
   If you execute it the payment of 0 amount will be included in a remittance
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
related to defect 00309713.0PR16Q1 closedaferraz When voiding an unpaid invoice, payment schedule details should be canceled instead of deleted 
related to defect 0031367 scheduledmarkmm82 It should not be possible to change the payment method of an awaiting execution payment without being reactivated 
related to defect 0033492 scheduledSanjota Not possible to pay a void invoice if voided one has been already paid. 
related to defect 0034589 closedrqueralta Error message needed in case of voiding an invoice having an "Awaiting Execution" or "Awaiting Payment" payment related. 
related to defect 0034385 closedrqueralta Payment of 0 amount created when voiding an unpaid invoice should be created with Exchange Rate record from invoice (if any) 

-  Notes
(0091390)
psanjuan (manager)
2016-11-11 12:46
edited on: 2016-11-11 12:51

Please check if below aternative solution can work for the partner/end-customer or not:

Void the sales invoice.

Once the payment in is created in "Awaiting Execution" status, including the invoice (positive amount +100.00) and the reverse sales invoice (negative amount -100.00), execute the payment by:
* unselecting the check "Include in existing remittance or create a new one"
* selecting the check "Write-off total Amount".
Then press Execute.

Once done both sales invoice and reverse invoice are shown as payment complete = yes.

Only thing to consider is that write off action implies below posting with a null net effect.

100.00 (43000) Customer account (DEBIT)
100.00 (43000) Customer account (DEBIT)
100.00 (69400) Write-off account (DEBIT)
100.00 (69400) Write-off account (CREDIT)


Please check whether this alternative works for the customer or not.

(0091403)
psanjuan (manager)
2016-11-11 14:24
edited on: 2016-11-11 14:29

Above solution can work for "remittance" type automatic payment method.

Therefore, proposed solution can be:

"Automatic" Payment in/out created after voiding an invoice, need to be created as "Payment Made/Received", therefore there is no need to execute them.
This kind of payment created after voiding an invoice include an invoice and its reversed invoide, and a payment amount = 0.00

To be confirmed.

(0091439)
psanjuan (manager)
2016-11-14 11:42
edited on: 2016-11-21 11:59

Proposed solution:

Automatic payment in/out having an automatic payment method related, and an amount of 0,00 do not need to be executed, therefore must be created either with "Payment Made" or "Payment Receive" status.

Above payments can be the result of voiding an invoice that is NOT paid.

The status of not paid invoices will end being the same as if the payment was executed, while it was not as there is no need (amount = 0.00)

See scenario below.

(*) Proposed scenario not paid invoice (having an automatic payment method related)

Create a Sales Invoice for F&B España, Alimentos business partner.
Change payment method to an automatic payment method such as "Print Check Simple process" or "Remittance", set up as "Deferred" = Yes.

Add any line to the invoice. Complete and Post the invoice.
Do not pay it but void it.

Check that a payment in with an amount = 0.00 has been created in status "Payment Received" (therefore there is no need to execute this payment, because its amount is 0.00). This payment includes two lines, one for the invoice (81.07€) and another one for the reversed invoice (-81.07€).

Go back to the sales invoice and check that:
Payment Complete = Yes
Go to Payment Plan tab and verify that
Expected Amount = Received Amount = 81.07 (Invoice total gross amount)
Outstanding Amount = 0.00

Go to Payment Details and check that:
Payment in created is shown in there with all the data required.

Go back to the reverse sales invoice and check that:
Payment Complete = Yes
Go to Payment Plan tab and verify that
Expected Amount = Received Amount = -81.07 (Invoice total gross amount)
Outstanding Amount = 0.00

Go to Payment Details and check that:
Payment in created is shown in there with all the data required.

(0091596)
psanjuan (manager)
2016-11-16 10:22
edited on: 2016-11-18 11:29

Test Plan

(*) Test Case 1 - "Remittance" payment method & Invoice Not Paid and Void.

As system admin role, istall Remittances Infrastructure module.

As group admin role, apply the module's dataset to F&B España organization.
Include "Remittance" payment method in a F&B España financial account

Create a Sales Invoice for F&B España org, Alimentos business partner. Change payment method to "Remittance".

Go to lines tab and add any line to it.
complete it and do not add any payment to the invoice but void it.

Check that a payment in has been created with a 0.00 amount, including both the original and the void invoice.
The status of the payment is "Payment Received".

Check that Sales Invoice and Void Sales Invoice are set as Payment Complete = Yes and there is no "outstanding" amount to be paid for any of them.

Repeat same test as above for a purchase invoice.

(*) Test Case 2 - "Simple Check" payment method & Invoice Not Paid and Void.

Go to "Cuenta de Banco" financial account and make sure that "Cheque" payment method is setup as described below for both payment in/payment out:
Execution Type: Automatic
Execution Process: Print Check simple process.
Deferred: Yes

Create a Sales Invoice for F&B España org, Alimentos business partner. Change payment method to "Cheque".

Go to lines tab and add any line to it.
complete it and do not add any payment to the invoice but void it.

Check that a payment in has been created with a 0.00 amount, including both the original and the void invoice.
The status of the payment is "Payment Received".

Check that Sales Invoice and Void Sales Invoice are set as Payment Complete = Yes and there is no "outstanding" amount to be paid for any of them.

Repeat same test as above for a purchase invoice.

(0091656)
psanjuan (manager)
2016-11-18 11:36
edited on: 2016-11-21 12:21

Test Case 3 - Invoice totally paid by an automatic payment method (Check). Invoice void.

Create a sales invoice for F&B España, Alimentos business partner.
Change payment method to "Cheque".

Go to lines and add any product and invoiced quantity.
Complete the invoice and pay it. Execute the payment.

Void the invoice. Verify that the created reversed invoice is not paid but it can be paid by using "Add Payment" process button.

Repeat same test for a purchase invoice. see issue: 33492

(0091657)
psanjuan (manager)
2016-11-18 11:36
edited on: 2016-11-21 12:21

Test Case 4 - Set New Currency process run for a supplier having credit generated with an automatic payment method.

Go to business partner window and create a new one for F&B España.
Name it as "Client TC7" for instance.
Select a customer BP Category.

Go to Customer tab and select below setup:
price list : Tarifa de ventas
Payment Method : Cheque
Payment Terms : 30 d
Financial Account : Cuenta de Banco

Go to Location tab, and enter an Spanish location.

Go to Cuenta de Banco financial account, payment method tab, and make sure that "Cheque" payment method allows "Making/Receiving" payments in multiple currencies.

Navigate to Payment in window and enter a credit of 100.00 € for the customer just created.

Execute the payment.

Go back to business partner window, and check that "Client TC7" balance is -100.00 €.
Run Set new currency process

Select USD, remove "Use default conversion rate", enter a conversion rate = 15 and select a G/L item. Press Done.

Check that current balance of customer has changed to 1500.00

Go to payment in window and filter by the payments created for the customer.

Verify that the last one is a credit payment of a 0.00 amount with status "Payment Received".


(**) second and third payment are in "Awaiting Execution" status.


Test Case 5 - Set New Currency process run for a customer having credit generated with an automatic payment method.

Go to business partner window and create a new one for F&B España.
Name it as "Supplier TC8" for instance.
Select a suppleir BP Category.

Go to Vendor tab and select below setup:
price list : Tarifa Bebidas Alegres
Payment Method : Cheque
Payment Terms : 30 d
Financial Account : Cuenta de Banco

Go to Location tab, and enter an Spanish location.

Navigate to Payment out window and enter a credit of 100.00 € for the vendor just created.

Execute the payment.

Go back to business partner window, and check that "Supplier TC8" balance is 100.00 €.
Run Set new currency process

Select USD, remove "Use default conversion rate", enter a conversion rate = 15 and select a G/L item. Press Done.

Check that current balance of supplier has changed to 1500.00

Go to payment out window and filter by the payments created for the customer.

Verify that the last one is a credit payment of a 0.00 amount with status "Payment Made".

(**) second and third payment are in "Awaiting Execution" status.

(0091658)
psanjuan (manager)
2016-11-18 11:36
edited on: 2016-11-21 12:21

Test Case 6 - Cancel and Replace netting payment.

Enable Cancel and Replace preference.

Go to sales order window, and create a new one for F&B España, Alimentos business partner. Change payment method to "Cheque".

Go to lines and add 15 units of any product. Complete the order.
Write down sales order number (1000382 for instance).
Pay the order partially.

Execute the payment.

Press Cancel and Replace. In the "Temporarl" order created changed ordered quantity to 25. Confirm Cancel and Replace. Press Done.

Go to Sales order 1000382. Navigate to payment plan tab, and then to payment details tabl.

Check that two payment details can be found.
Navigate to the *Z* Netting payment created.

Verify it is a 0.00 amount payment with status "Payment Received".

(0091659)
psanjuan (manager)
2016-11-18 11:38
edited on: 2016-11-21 12:22

Test Case 7 - Invoice do not paid and void (manual payment method)

Create a sales invoice for F&B España, Alimentos business partner.
Check that payment method is Transferencia.

Add any line and any invoiced quantity. Complete the invoice. Void the invoice.

Check that a payment in is created including the invoice and the reverse invoice, for an amount of 0.00 in status "Payment Received". Received (Financial Account) field = 0.00

Repeat same test for a purchase invoice.

Test Case 8 - Invoice partially paid and void (manual payment method)

Create a sales invoice for F&B España, Alimentos business partner.
Check that payment method is Transferencia.

Add any line and any invoiced quantity. Complete the invoice. Pay it partially.

Verify that no new payment in is created therefore invoice remains as partially paid and reverse invoice is not paid.

Repeat same test for a Purchase Invoice.

Test Case 9 - Invoice paid and void (manual payment method)

Create a sales invoice for F&B España, Alimentos business partner.
Check that payment method is Transferencia.

Add any line and any invoiced quantity. Complete the invoice. Pay it.

Void the invoice.

Verify that reverse sales invoice is not paid, and can be paid through "Add Payment" process button.

Repeat same test for a Purchase Invoice.

(0091695)
psanjuan (manager)
2016-11-21 12:49

Test plan above verified. While testing this issue a new issue has been opened to improve partially paid invoices. See issue relate 34589.

Please review the code and close the issue.
(0091697)
hgbot (developer)
2016-11-21 13:44

Repository: erp/devel/pi
Changeset: 9e84e90e2f2ae882a7dc59c8de46d25f1d0d445d
Author: Rafael Queralta Pozo <rqueralta <at> nauta.cu>
Date: Fri Nov 18 14:11:43 2016 -0500
URL: http://code.openbravo.com/erp/devel/pi/rev/9e84e90e2f2ae882a7dc59c8de46d25f1d0d445d [^]

Fixes issue 34322: Payment of 0 amount created when voiding an unpaid invoice

Payment of 0 amount created when voiding an unpaid invoice was created in Awaiting Execution status.
Now, if Automatic Payment In/Out having an automatic payment method related with an amount of 0,00
it is created in "Payment Receive" or "Payment Made" status.

---
M modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/process/FIN_PaymentProcess.java
---
(0091698)
aferraz (manager)
2016-11-21 13:45

Code review OK
(0092647)
hudsonbot (developer)
2016-12-16 18:38

A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/dc8bf00badd0 [^]
Maturity status: Test

- Issue History
Date Modified Username Field Change
2016-10-27 14:08 ngarcia New Issue
2016-10-27 14:08 ngarcia Assigned To => Triage Finance
2016-10-27 14:08 ngarcia Modules => Core
2016-10-27 14:08 ngarcia Resolution time => 1479337200
2016-10-27 14:08 ngarcia Triggers an Emergency Pack => No
2016-10-27 14:08 ngarcia Relationship added related to 0030971
2016-10-27 14:08 ngarcia Issue Monitored: networkb
2016-10-27 14:09 ngarcia Relationship added related to 0031367
2016-11-03 20:57 aferraz Assigned To Triage Finance => nonofrancisco
2016-11-04 10:03 aferraz Relationship added related to 0034385
2016-11-11 12:46 psanjuan Note Added: 0091390
2016-11-11 12:51 psanjuan Note Edited: 0091390 View Revisions
2016-11-11 12:51 psanjuan Note Edited: 0091390 View Revisions
2016-11-11 14:24 psanjuan Note Added: 0091403
2016-11-11 14:29 psanjuan Note Edited: 0091403 View Revisions
2016-11-11 15:31 rqueralta Assigned To nonofrancisco => rqueralta
2016-11-14 11:42 psanjuan Note Added: 0091439
2016-11-14 11:46 psanjuan Note Edited: 0091439 View Revisions
2016-11-16 10:22 psanjuan Note Added: 0091596
2016-11-16 10:27 psanjuan Note Edited: 0091596 View Revisions
2016-11-16 11:05 psanjuan Note Edited: 0091439 View Revisions
2016-11-16 13:00 psanjuan Note Edited: 0091439 View Revisions
2016-11-16 13:03 psanjuan Note Edited: 0091439 View Revisions
2016-11-16 13:55 psanjuan Note Edited: 0091596 View Revisions
2016-11-16 15:44 psanjuan Note Edited: 0091596 View Revisions
2016-11-18 11:17 psanjuan Note Edited: 0091439 View Revisions
2016-11-18 11:21 psanjuan Note Edited: 0091439 View Revisions
2016-11-18 11:22 psanjuan Note Edited: 0091439 View Revisions
2016-11-18 11:28 psanjuan Note Edited: 0091596 View Revisions
2016-11-18 11:28 psanjuan Note Added: 0091654
2016-11-18 11:29 psanjuan Note Edited: 0091596 View Revisions
2016-11-18 11:34 psanjuan Note Edited: 0091654 View Revisions
2016-11-18 11:36 psanjuan Note Added: 0091656
2016-11-18 11:36 psanjuan Note Added: 0091657
2016-11-18 11:36 psanjuan Note Added: 0091658
2016-11-18 11:38 psanjuan Note Added: 0091659
2016-11-18 12:34 psanjuan Note Edited: 0091654 View Revisions
2016-11-18 12:41 psanjuan Note Edited: 0091656 View Revisions
2016-11-18 12:41 psanjuan Note Edited: 0091656 View Revisions
2016-11-18 12:41 psanjuan Relationship added related to 0033492
2016-11-18 12:43 psanjuan Note Edited: 0091654 View Revisions
2016-11-18 12:46 psanjuan Note Edited: 0091439 View Revisions
2016-11-18 12:48 psanjuan Note Edited: 0091656 View Revisions
2016-11-18 12:49 psanjuan Note Edited: 0091656 View Revisions
2016-11-18 12:51 psanjuan Note Edited: 0091657 View Revisions
2016-11-18 13:01 psanjuan Note Edited: 0091657 View Revisions
2016-11-18 13:11 psanjuan Note Edited: 0091657 View Revisions
2016-11-18 13:52 psanjuan Note Edited: 0091658 View Revisions
2016-11-18 13:57 psanjuan Note Edited: 0091658 View Revisions
2016-11-18 14:15 psanjuan Note Edited: 0091659 View Revisions
2016-11-21 11:11 psanjuan Note Edited: 0091439 View Revisions
2016-11-21 11:22 psanjuan Note Edited: 0091439 View Revisions
2016-11-21 11:56 psanjuan Relationship added related to 0034589
2016-11-21 11:59 psanjuan Note Edited: 0091439 View Revisions
2016-11-21 12:18 psanjuan Note Edited: 0091654 View Revisions
2016-11-21 12:18 psanjuan Note Deleted: 0091654
2016-11-21 12:18 psanjuan Note Edited: 0091656 View Revisions
2016-11-21 12:19 psanjuan Note Edited: 0091656 View Revisions
2016-11-21 12:21 psanjuan Note Edited: 0091656 View Revisions
2016-11-21 12:21 psanjuan Note Edited: 0091657 View Revisions
2016-11-21 12:21 psanjuan Note Edited: 0091658 View Revisions
2016-11-21 12:22 psanjuan Note Edited: 0091659 View Revisions
2016-11-21 12:49 psanjuan Note Added: 0091695
2016-11-21 13:44 hgbot Checkin
2016-11-21 13:44 hgbot Note Added: 0091697
2016-11-21 13:44 hgbot Status new => resolved
2016-11-21 13:44 hgbot Resolution open => fixed
2016-11-21 13:44 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/9e84e90e2f2ae882a7dc59c8de46d25f1d0d445d [^]
2016-11-21 13:45 aferraz Review Assigned To => aferraz
2016-11-21 13:45 aferraz Note Added: 0091698
2016-11-21 13:45 aferraz Status resolved => closed
2016-11-21 13:45 aferraz Fixed in Version => 3.0PR17Q1
2016-12-16 18:38 hudsonbot Checkin
2016-12-16 18:38 hudsonbot Note Added: 0092647


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker