[jira] [Comment Edited] (OFBIZ-9117) EntityAuto engine override the passed service in parameters

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[jira] [Comment Edited] (OFBIZ-9117) EntityAuto engine override the passed service in parameters

Nicolas Malin (Jira)

    [ https://issues.apache.org/jira/browse/OFBIZ-9117?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15666278#comment-15666278 ]

Deepak Dixit edited comment on OFBIZ-9117 at 11/15/16 6:38 AM:
---------------------------------------------------------------

Hi Paul,

InvoiceContactMech is assoc entity and its simply associate invoice with contactMech.
So if we are passing contactMechId=9001 as service in parameter, so entity auto should simple create InvoiceContactMech record with given parameters.

Main concern here is why entity auto engine using 10060 instead 9001, as we passed 9001 as service in parameter. I converted this service to simple method and its creating correct record. Its using same parameters that I passed while calling service.



was (Author: deepak.dixit):
Hi Paul,

InvoiceContactMech is assoc entity and its simply associate invoice with contactMech.
So if we are passing contactMechId=9001 service in parameter, so entity auto should simple create InvoiceContactMech record with given parameters.

Main concern here is why entity auto engine using 10060 instead 9001, as we passed 9001 as service in parameter. I converted this service to simple method and its creating correct record. Its using same parameters that I passed while calling service.


> EntityAuto engine override the passed service in parameters
> -----------------------------------------------------------
>
>                 Key: OFBIZ-9117
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-9117
>             Project: OFBiz
>          Issue Type: Bug
>          Components: ALL COMPONENTS
>    Affects Versions: Trunk
>            Reporter: Deepak Dixit
>         Attachments: errorlog.txt
>
>
> There is an bug in EntityAuto engine, it override the passed service in parameters.
> In createInvoiceForOrder service calls the createInvoiceContactMech to crate invoice contactMech for PAYMENT_LOCATION purpose (at line no 357). In case of SO it should use Company PAYMENT_LOCATION contactMech. It get the Company contactMechId correctly and set it createInvoiceContactMech service in context correctly, but system throws foreign key constraints error for incorrect contactMechId.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)