Openbravo Issue Tracking System - Modules
View Issue Details
0039013ModulesCredit Management - Dunningpublic2018-07-23 14:482018-08-01 13:54
shuehner 
markmm82 
normalmajorhave not tried
closedfixed 
5
 
 
Sandrahuguet
0039013: CustomerCalloutDK broken when used with ERP >=17Q1 or 17Q4
Dunning module contains the CustomerCalloutDK callout which is extending another callout from core named SE_Invoice_BPartner.

It does that by mocking an http-request and incoking the other callout.

However most callouts in core are no longer callable via http requests so that cannot work:
17Q1 change: https://code.openbravo.com/erp/devel/pi/rev/b468094df0d0ff1d168a03977ba314f64549b998 [^]
Makes callouts no longer be mapped via web.xml

17Q4 change: https://code.openbravo.com/erp/devel/pi/rev/2ab8016a23535c8182170c2dc4f991c2dc5786a9 [^]

Made the specific callouts not even being a servlet anymore.

The callout in this module should be refactored to extend the core callout the 'new way' http://wiki.openbravo.com/wiki/How_to_create_a_Callout#Extend_a_Callout [^]

When done the MockHttpServletResponse calls in the module should be removed as it will no longer be necessary.
As that class is not compatible with servet-api>30 (i.e. using tomcat8.5) that prepares the module to work with that tomcat version when that will be used in pi by default in short.
For the functional bug -> try to run the callout.

For the 'MockHttpServletResponse' not working with tomcat8.5
Setup eclipse with tomcat8.5 and notice this java file in the module no longer compiling.
-
No tags attached.
Issue History
2018-07-23 14:48shuehnerNew Issue
2018-07-23 14:48shuehnerAssigned To => Triage Finance
2018-07-26 18:05markmm82Assigned ToTriage Finance => markmm82
2018-07-26 18:05markmm82Statusnew => scheduled
2018-07-26 22:43markmm82Note Added: 0105969
2018-08-01 12:56hgbotCheckin
2018-08-01 12:56hgbotNote Added: 0106082
2018-08-01 12:56hgbotStatusscheduled => resolved
2018-08-01 12:56hgbotResolutionopen => fixed
2018-08-01 12:56hgbotFixed in SCM revision => http://code.openbravo.com/erp/pmods/org.openbravo.creditmanagement.dunning/rev/d9360a9a8c9c1811b0fd1140c93e142859925c75 [^]
2018-08-01 12:56hgbotCheckin
2018-08-01 12:56hgbotNote Added: 0106083
2018-08-01 13:54SandrahuguetReview Assigned To => Sandrahuguet
2018-08-01 13:54SandrahuguetNote Added: 0106086
2018-08-01 13:54SandrahuguetStatusresolved => closed

Notes
(0105969)
markmm82   
2018-07-26 22:43   
Test Plan:
Set the environment following the document:
http://forge.openbravo.com/plugins/mwiki/index.php/Creditmgtdunning/User_Documentation [^]
As System Admin
  Go to Windows, Tabs and Fields and select Sales Invoice window.
  Go to Lines Tab -> Fields and select the Business Partner field.
  Navigates to the column definition and change the SE_Invoice_BPartner Callout by CustomerCalloutDK callout.
As F&B group admin
  Go to Business Partner window and set up a dunning configuration to Alimentos y Supermercados, S.A customer.
  Create a new Sales Invoice header, select Alimentos y Supermercados, S.A bp.
    Notice that several fields like pice list, address, payment metho, etc has been updated by the SE_Invoice_BPartner callout.
    Also notice that the Dunning Key has been updated with the dunning key previously set to the BP. This action performed by the CustomerCalloutDK callout.

After install the patch try, and using tomcat 8.5 try to recompile the system and it is success
(0106082)
hgbot   
2018-08-01 12:56   
Repository: erp/pmods/org.openbravo.creditmanagement.dunning
Changeset: d9360a9a8c9c1811b0fd1140c93e142859925c75
Author: Mark <markmm82 <at> gmail.com>
Date: Thu Jul 26 16:30:04 2018 -0400
URL: http://code.openbravo.com/erp/pmods/org.openbravo.creditmanagement.dunning/rev/d9360a9a8c9c1811b0fd1140c93e142859925c75 [^]

Fixes issue 39013: CustomerCalloutDK broken when used with ERP >=17Q1 or 17Q4

The callout CustomerCalloutDK has been refactored to extend the core callout
SE_Invoice_BPartner instead of HttpSecureAppServlet as it is not used anymore.
Also it avoid the MockHttpServletResponse calls as it is not needed anymore and
it isn't compatible with servet-api>30.

---
M src/org/openbravo/creditmanagement/dunning/callouts/CustomerCalloutDK.java
---
(0106083)
hgbot   
2018-08-01 12:56   
Repository: erp/pmods/org.openbravo.creditmanagement.dunning
Changeset: 506cc78fc932a2f5ab2cb94a2c3ded5c84467b21
Author: Mark <markmm82 <at> gmail.com>
Date: Fri Jul 27 15:24:26 2018 -0600
URL: http://code.openbravo.com/erp/pmods/org.openbravo.creditmanagement.dunning/rev/506cc78fc932a2f5ab2cb94a2c3ded5c84467b21 [^]

Related to issue 39013: Removed unused MockHttpServletResponse.java class

The MockHttpServletResponse.java is not used anymore so it can be removed from
the module.

---
R src/org/openbravo/creditmanagement/dunning/biz/MockHttpServletResponse.java
---
(0106086)
Sandrahuguet   
2018-08-01 13:54   
Code review + testing OK