I have a field with an array of string to get several image as files. Is there a way to display all these image in a file viewer ?
You mean for instance like this?
This is possible by going to the field settings and selecting the file viewer widget.
Let me know if that helps!
Yeah exactly like that !
Can you show me what the value looks like ?
@PierreGaladrim It’s just a basic array of strings (the strings being the image full urls - or the relative url with a prefix).
Is it not working on your side?
Something like that ?
[img1.jpeg, img2.jpeg, img3.jpeg, img4.jpeg, img5.jpeg]
It depends on how are stored your images, you can get full documentation on what you want to achieve by clinking on this link.
Let me know if it helps,
As you can see the carousel don’t make a difference between one or multiple image instead the type is [String]
okay thanks, it seems that there is a problem in the configuration of the file viewer prefix, can you tell me what you have put in the input prefix?
I use a custom path to find my image and it work perfectly when I only have one picture. It just take my array as a single file.
Could you share one of your photos field> I mean if you go to the network tabs and give me the response you get from your server
Here is my network, the response tab is null.
Sorry I was not clear enough I mean the data from the listing view
You mean in the console ? Or when i click on one data ( Missing prefix to base64 data ) ?
I mean the reponse of
GET /forest/your-collection-name a call like that
I got this :
Where is your field photos defined ? In which collection ?
In a portfolio collection like that :
I almost tried with DataTypes.STRING cause i’m using mySQL but it didn’t work.
Okey so in your network tab could you share the response you have on the call
This one but on your browser , in the network tab