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

Do not show img tag with same src attribute if an image field is empty #6268

Merged

Conversation

PedroErnst
Copy link
Contributor

@PedroErnst PedroErnst commented Aug 28, 2018

This PR fixes a small bug with the image type field from Studio / Module Builder.

Description

Image fields have in their src attribute the url of an entrypoint composed of the id of the record we're viewing and the name of the field. However, once we clear an image field, since this url doesn't change the browser might display a cached version where we would expect not to see any image.

How To Test This

  1. Add an image field to any module
  2. Add it to detail and edit view
  3. Edit a record, upload an image to this field
  4. See it displays in detail view
  5. Edit the record, remove the image
  6. See it doesn't display in detail view. The img tag should have an empty src attribute.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Final checklist

  • My code follows the code style of this project found here.
  • My change requires a change to the documentation.
  • I have read the How to Contribute guidelines.

@Dillon-Brown
Copy link
Contributor

Dillon-Brown commented Aug 28, 2018

Assessed

Approved with PullApprove

@Dillon-Brown Dillon-Brown added the Status:Assessed PRs that have been tested and confirmed to resolve an issue by a core team member label Aug 28, 2018
@samus-aran samus-aran merged commit f9a7f50 into salesagility:hotfix-7.8.x Aug 30, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status:Assessed PRs that have been tested and confirmed to resolve an issue by a core team member
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants