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

Add afterGetList method in CustomerRepository plugin to retrieve is_s… #25311

Conversation

enriquei4
Copy link
Contributor

@enriquei4 enriquei4 commented Oct 27, 2019

Description (*)

Its not possible to get "is_subscibed" (to newsletter) extension attribute when you retrieve the list of customers in the Customer Repository, and also in REST API.
I added a new method to getList to retrieve the subscription extension attribute.

Fixed Issues

#13252

Manual testing scenarios (*)

  1. Register a New customer,
  2. Subscribe it to newsletter.
  3. Create a API rest integration.
  4. Configure Postman or other REST client.
  5. Create a GET call to the REST API like: http://MAGENTODOMAIN.lo/rest/V1/customers/search?searchCriteria[filterGroups][0][filters][0][field]=updated_at&searchCriteria[filterGroups][0][filters][0][value]=2018-03-21&searchCriteria[filterGroups][0][filters][0][conditionType]=gt

You wont get "extension_attributes" in the current implementation.

Contribution checklist (*)

  • Pull request has a meaningful description of its purpose
  • All commits are accompanied by meaningful commit messages
  • [] All new or changed code is covered with unit/integration tests (if applicable)
  • All automated tests passed successfully (all builds are green)

@m2-assistant
Copy link

m2-assistant bot commented Oct 27, 2019

Hi @enriquei4. Thank you for your contribution
Here is some useful tips how you can test your changes using Magento test environment.
Add the comment under your pull request to deploy test or vanilla Magento instance:

  • @magento give me test instance - deploy test instance based on PR changes
  • @magento give me 2.3-develop instance - deploy vanilla Magento instance

For more details, please, review the Magento Contributor Guide documentation.

@magento-engcom-team magento-engcom-team added Component: Newsletter Release Line: 2.3 Partner: Interactiv4 Pull Request is created by partner Interactiv4 partners-contribution Pull Request is created by Magento Partner labels Oct 27, 2019
@aleron75 aleron75 self-assigned this Oct 28, 2019
@aleron75
Copy link
Contributor

Hello @enriquei4, thank you for your contribution!

Due to Magento Definition of Done all code must be covered by tests.

For this specific case, you should cover your fix by automated tests with the scenario which leads to an issue.
Tests should fail on the mainline and pass with your fix.

Cheers!

@sidolov sidolov changed the base branch from 2.3-develop to 2.4-develop December 5, 2019 17:17
@ihor-sviziev ihor-sviziev self-assigned this Feb 17, 2020
Copy link
Contributor

@ihor-sviziev ihor-sviziev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @enriquei4,
Will you be able to update your PR and cover with tests?

@ihor-sviziev ihor-sviziev added the Auto-Tests: Not Covered Changes in Pull Request requires coverage by auto-tests label Feb 18, 2020
@engcom-Charlie engcom-Charlie self-assigned this Feb 19, 2020
…tory

# Conflicts:
#	app/code/Magento/Newsletter/Model/Plugin/CustomerPlugin.php
@ihor-sviziev ihor-sviziev added Auto-Tests: Covered All changes in Pull Request is covered by auto-tests and removed Auto-Tests: Not Covered Changes in Pull Request requires coverage by auto-tests labels Feb 20, 2020
@magento-engcom-team
Copy link
Contributor

Hi @ihor-sviziev, thank you for the review.
ENGCOM-6945 has been created to process this Pull Request

@magento-engcom-team
Copy link
Contributor

Hi @ihor-sviziev, thank you for the review.
ENGCOM-6945 has been created to process this Pull Request

@engcom-Alfa
Copy link
Contributor

✔️ QA Passed

Before:
before

After:
after

@m2-assistant
Copy link

m2-assistant bot commented Feb 28, 2020

Hi @enriquei4, thank you for your contribution!
Please, complete Contribution Survey, it will take less than a minute.
Your feedback will help us to improve contribution process.

@sdzhepa sdzhepa mentioned this pull request May 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Auto-Tests: Covered All changes in Pull Request is covered by auto-tests Award: bug fix Component: Newsletter Partner: Interactiv4 Pull Request is created by partner Interactiv4 partners-contribution Pull Request is created by Magento Partner Progress: accept Release Line: 2.4 Squashtoberfest 2019
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants