Skip to content

Newsletters' images aren't shown in development #9154

@andreslucena

Description

@andreslucena

Describe the bug

As a developer, while trying some images in the newsletter templates I don't see the image in development mode.

To Reproduce
Steps to reproduce the behavior:

  1. Sign in as admin
  2. Go to Newsletterrs in admin panel
  3. Click on New newsletter
  4. Click on Use this template in Image, text and Call To Action button template
  5. Fill the form, sent the newsletter
  6. See the preview
  7. See that there isn't the uploaded image

Expected behavior
To see the images

Mind that this is also happening in other places, for instance the logo in the template with the preview. This can be reproduced with

  1. Sign in as admin
  2. Go to /admin/organization/appearance/edit
  3. Upload a logo
  4. Go to Newsletterrs in admin panel
  5. Click on New newsletter
  6. Click on Use this template in any template
  7. Fill the form, sent the newsletter
  8. See the preview
  9. See that there isn't the uploaded logo

Screenshots

image

Extra data (please complete the following information):

  • Decidim Version: v0.27.0.dev
  • Decidim installation: development_app

Additional context

The problem is that we're not providing the port in the URL

This is on

newsletter.template.images_container.attached_uploader(:main_image).url(host: organization.host)
- but we should see others places that would probably have this same bug with

$ grep -r "host:" decidim-* |grep attached_uploader

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions