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

[Forwardport] Using Media Image custom attribute type could not display on frontend #19369

Conversation

gelanivishal
Copy link
Contributor

Original Pull Request

#19068

Description (*)

Using Media Image custom attribute type could not display on frontend. #19054

Fixed Issues (if relevant)

  1. magento/magento2#Using Media Image custom attribute type could not display on frontend.  #19054: Using Media Image custom attribute type could not display on frontend
  2. ...

Manual testing scenarios (*)

  1. Create custom attribute named 'icon_image' of product from admin.
  2. Set attribute type Media Image.
  3. assign icon_image attribute in attribute set.
  4. Update product image and set new role 'icon_image'.
  5. In .phtml template ->
$productImageAttr = $product->getCustomAttribute( 'icon_image' );
$productImage = $this->helper('Magento\Catalog\Helper\Image')
->init($product, 'icon_image')
->setImageFile($productImageAttr->getValue());
<img src="<?php echo $productImage->getUrl() ?>" alt="<?php echo $block->escapeHtml($product->getTitle()) ?>" />

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 on Travis CI are green)

@magento-engcom-team
Copy link
Contributor

Hi @gelanivishal. 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-engcom-team give me test instance - deploy test instance based on PR changes
  • @magento-engcom-team give me 2.3-develop instance - deploy vanilla Magento instance

For more details, please, review the Magento Contributor Assistant documentation

Copy link
Contributor

@orlangur orlangur left a comment

Choose a reason for hiding this comment

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

Didn't re-review semantics of this code, just assured it is identical to 2.2 version.

@magento-engcom-team magento-engcom-team added this to the Release: 2.3.1 milestone Nov 24, 2018
@magento-engcom-team
Copy link
Contributor

Hi @orlangur, thank you for the review.
ENGCOM-3552 has been created to process this Pull Request

@Nazar65
Copy link
Member

Nazar65 commented Nov 26, 2018

Hi @gelanivishal this issue occurs only in 2.2-develop branch.

@orlangur
Copy link
Contributor

Thanks @Nazar65! Any idea why it works in 2.3.x? Wondering if we can have consistent fix across 2.2/2.3.

@Nazar65
Copy link
Member

Nazar65 commented Nov 26, 2018

@orlangur I'm working on it now, when i will find why does it work in 2.3, I'm immediately let you know.

@orlangur
Copy link
Contributor

This PR is not needed as the issue is not reproduced on 2.3.x.

@orlangur orlangur closed this Dec 26, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants