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

Olivier Heintz commented on OFBIZ-4349:
---------------------------------------

Leon,

Maybe, my explanations was not clear, I try to be more clear. The problem I 
want to solve was not about field name the method search to read the 
international content, but on the pk (name) to retrieve the correct record.

In the method you give, search is doing to check if there is a alias for field 
name to retrieve.
In my patch, I check to have correct pkName.

As exemple, in projectmgr component, there are view name Project.... with pk 
named projectId not workEffortId  and workeffortName should be renamed 
projectName.
With initiale code (before my first correction), it will be a call to get 
method with name=workEffortName, but search in properties  will fail because 
this.get("workEffortId") return a error "workEffortId is not a field for....".

I used this patch for 2 months and I can say that he solve really the problem.

Cheers.

> commit r1077940 breaks the function to retrieve i18n translation from real 
> entity underlying a view
> ---------------------------------------------------------------------------------------------------
>
>                 Key: OFBIZ-4349
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-4349
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Leon
>         Attachments: OFBIZ-4349.patch
>
>
> in r1077940 changeset 
> ([https://fisheye6.atlassian.com/changelog/ofbiz?cs=1077940]), it gets the pk 
> fiels from view entity instead of previous real entity. I cannot understand 
> what author erwan commented: "When using a view and fields with different 
> names than in the original entity, the model was taking the original names so 
> this could lead to warnings". The consequence of this commit is it cannot 
> retrieve i18n translation from real entity now because the pks of view entity 
> is usually different than that of its base tables.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to