-
Notifications
You must be signed in to change notification settings - Fork 9.3k
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
M2.2.5 : CustomerRepository::getList() does not load custom attribute if the name is "company" #17759
Comments
Hi @kanduvisla. Thank you for your report.
Please make sure that the issue is reproducible on the vanilla Magento instance following Steps to reproduce. To deploy vanilla Magento instance on our environment, please, add a comment to the issue:
where @kanduvisla do you confirm that you was able to reproduce the issue on vanilla Magento instance following steps to reproduce?
|
@kanduvisla, thank you for your report. |
#mm18mx |
@irving0mar thank you for joining. Please accept team invitation here and self-assign the issue. |
Hi @irving0mar. Thank you for working on this issue.
|
#mageconf |
Hi @nik4152. Thank you for working on this issue.
|
fix select get list from repository customer customer field company
fix test get list from customer repository
As specified in issue magento#17759, CustomerRepository::getList() is unexpectedly returning NULL, when CustomerRepository::get() is correctly returning the value. Specifying the attribute as billing_company instead of company removes the conflict.
Hi @kanduvisla. Thank you for your report.
The fix will be available with the upcoming 2.3.1 release. |
Hi @kanduvisla. Thank you for your report. The fix will be available with the upcoming 2.2.8 release. |
I have custom EAV attributes named "company" for customers, but this is not loaded if I use the
CustomerRepository::getList()
-method. Other custom attributes seem to be loaded properly.Preconditions
Steps to reproduce
CustomerRepository::get() / getById()
CustomerRepository::getList()
Expected result
In both the situations,
$customer->getCustomAttribute('company')->getValue()
should return the value defined for this attribute.Actual result
The
get()
/getById()
-method loads the proper value,getList()
returnsNULL
.Possible cause
My best guess is that it has something to do with the fact that
getList()
joins the customer address that also has acompany
-column:Possible solution
I can think of 2 solutions:
company
(or whatever other joined attributed) is a reserved keyword.Workaround
I currently have to do the following workaround (in my situation, my search criteria always returns 1 customer):
The text was updated successfully, but these errors were encountered: