Rest API and the Image Component

  • 1
  • Problem
  • Updated 4 months ago
  • In Progress
I'm having issues with the image component on Skuid Platform. I can get images to show in a table so I know that the data is pointing to the right source, but when trying to reference the same image through the image component, nothing shows. The attribute says "src(unkown) in the inspector. Also trying to use an HTML image tag in a template fails to show as well. If I use a static reference in the image or template components, it works as it should.
Photo of Sig

Sig

  • 92 Points 75 badge 2x thumb

Posted 5 months ago

  • 1
Photo of Luzie Baumgart

Luzie Baumgart, Official Rep

  • 2,240 Points 2k badge 2x thumb
Hey Sig, could you please try the following:

- add a new UI-only field to your model
- select "Display type = Formula" and "Formula Return Type = Text"
- in the field tab "Formula" please insert the field which stores the URL with double curly brackets
- now use the new UI-only field as "Image URL" in your image component

Does it work this way?
Could you please let me know the field name of the URL? I'm wondering if contains text only or is there maybe one or more dots included, like: {{any.text.here}}

Thanks,
Luzie
Photo of Sig

Sig

  • 92 Points 75 badge 2x thumb
Hi Luzie,

It doesn't work that way either.

The field name does contain dots, {{records.fields.Image}}. One thing I forgot to mention is that I did need to override the field type to be text instead of URL in order for the image to show in the table, but that doesn't help for the image component.
Photo of Luzie Baumgart

Luzie Baumgart, Official Rep

  • 2,240 Points 2k badge 2x thumb
OK, thank you for the feedback. I'll check what else could be relevant for this issue.
Photo of Luzie Baumgart

Luzie Baumgart, Official Rep

  • 2,240 Points 2k badge 2x thumb
Hi Sig, I reached out to you via e-mail last week (subject: "Rest API and the Image Component"), please let me know in case you didn't get the e-mail.
Photo of Sig

Sig

  • 92 Points 75 badge 2x thumb
Hi Luzie,

I don't see that email for some reason. Can you please resend it?
Photo of Luzie Baumgart

Luzie Baumgart, Official Rep

  • 2,240 Points 2k badge 2x thumb
Thanks for letting me know, I just sent it again, did you get it?