Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix missing $joinMap in AbstractQueryConverter #968

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

sad270
Copy link

@sad270 sad270 commented Nov 5, 2019

In AbstractQueryConverter::getParentJoinIdForVirtualColumnJoin method, $joinMap variable is missing.
So we never enter in last elseif isset($joinMap[$parentAlias]['processed'])
And when we have 2 joins in a virtual_fields the second join is not added in DQL

Example:

# src/Oro/Bundle/AccountBundle/Resources/config/oro/entity.yml
oro_entity:
    virtual_fields:
        Oro\Bundle\AccountBundle\Entity\Account:
            contactInformation:
                query:
                    select:
                        expr:         emails.email
                        return_type:  string
                    join:
                        left:
                            - { join: entity.defaultContact, alias: defaultContact }
                            - { join: defaultContact.emails, alias: emails, conditionType: 'WITH', condition: 'emails.primary = true' }

Need for fix this oroinc/crm#346

in AbstractQueryConverter::getParentJoinIdForVirtualColumnJoin method, `$joinMap` variable i missing.
@orocla
Copy link

orocla commented Nov 5, 2019

Thank you for your pull request.

It looks like this may be your first contribution to an Oro, Inc. open source project, in which case you'll need to sign a Contributor License Agreement (CLA) at http://www.orocrm.com/contributor-license-agreement/

If you've already signed the CLA, it's possible we don't have your GitHub username or you're using a different email address. GitHub uses the email address you set in your local Git configuration to associate commits with your GitHub account. Please sign the CLA again using the correct GitHub username and email address or see this help article on setting the email on your git commits.

Once you've signed the CLA, please allow for some time for the submission to be processed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

Successfully merging this pull request may close these issues.

None yet

2 participants