You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ofbiz.apache.org by "Adam Heath (JIRA)" <ji...@apache.org> on 2014/06/25 17:46:26 UTC

[jira] [Assigned] (OFBIZ-4331) trival update to EntityFieldValue.java in case the entityAlias is empty

     [ https://issues.apache.org/jira/browse/OFBIZ-4331?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Adam Heath reassigned OFBIZ-4331:
---------------------------------

    Assignee: Adam Heath

> trival update to EntityFieldValue.java in case the entityAlias is empty
> -----------------------------------------------------------------------
>
>                 Key: OFBIZ-4331
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-4331
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Leon
>            Assignee: Adam Heath
>            Priority: Trivial
>             Fix For: SVN trunk
>
>         Attachments: EntityFieldValue.patch
>
>
> Sometimes, there's only one member entity in a view. In such case, you can omit the "entity-alias" in entity condition setting. In this situation, the entityAlias is not "null" but an emtpty string.
> ===================================================================
> --- framework/entity/src/org/ofbiz/entity/condition/EntityFieldValue.java	(revision 1513)
> +++ framework/entity/src/org/ofbiz/entity/condition/EntityFieldValue.java	(working copy)
> @@ -124,7 +124,7 @@
>      @Override
>      public ModelField getModelField(ModelEntity modelEntity) {
>          if (this.modelViewEntity != null) {
> -            if (this.entityAlias != null) {
> +            if (UtilValidate.isNotEmpty(this.entityAlias)) {
>                  ModelEntity memberModelEntity = modelViewEntity.getMemberModelEntity(entityAlias);
>                  return getField(memberModelEntity, fieldName);
>              } else {



--
This message was sent by Atlassian JIRA
(v6.2#6252)