The Shopify product image not pulling through

The Shopify product image not pulling through, I have tried various ways to prompt it to add the main image but it always throws out errors and I have to roll it back
No description
21 Replies
Simon
Simon4w ago
Add some logs to debug it?
Cubeyy
CubeyyOP4w ago
this is what I made a report section look like
No description
Cubeyy
CubeyyOP4w ago
I ask the Ai Assistant "in the main report, Top Products tile: make sure the product images are being pulled from the shopify store, it should display the main image from the product listed in the top products tile" and this happens
No description
Cubeyy
CubeyyOP4w ago
this is the only thing in the log that isnt blue on the side:
No description
Chocci_Milk
Chocci_Milk4w ago
Hello, Do you have the shopifyProductMedia model in your application? If not, there's no way for you to actually use the product's image as its not stored on the shopifyProduct model
Cubeyy
CubeyyOP4w ago
I checked and it appears not, even after trying about 10 different prompts with the ai assistant to place the product images there. I added it and then got chatgpt to give me a detailed prompt (which has been amazing so far) but nothing seems to actually pull the image through still
Chocci_Milk
Chocci_Milk4w ago
Could you please share the name of the application?
Cubeyy
CubeyyOP4w ago
"myshopwrapped"
Chocci_Milk
Chocci_Milk4w ago
So your shopifyProduct model definitely has a featuredMedia field since your application as the shopifyProductMedia model. Do you know what file the field is being used in? The media model is really weird (Shopify uses it for all media on the shop) and has multiple fields that the assistant could be getting confused about
Cubeyy
CubeyyOP4w ago
I'll be honest - I do not know what you mean by that. I am trying to use the photos in the "📊 Full Report" tab, there is a tile called "🏆 Top Products" showing the top 3 products sold from the store. The product names and stats all seem correct, just wont pull the main photo from those products
Chocci_Milk
Chocci_Milk4w ago
Whats the name of the route that you're seing those in?
Cubeyy
CubeyyOP4w ago
I am not familiar with that term - I am very new at ai coding and coding in general, struggling my way through
Chocci_Milk
Chocci_Milk4w ago
Two things: - You have not shopifyFile data in your application so you'll need to resync in order to evenm display any images - Your application is using the wrong field so I'll go switch that over for you. The field you were using was src when it should have been using image Give me a moment to see the correct syntax and make the change
Cubeyy
CubeyyOP4w ago
I appreciate that
Cubeyy
CubeyyOP4w ago
No description
Chocci_Milk
Chocci_Milk4w ago
Try now
Cubeyy
CubeyyOP4w ago
I have tried about 4 different ways via chatgpt prompts and nothing has worked yet
Chocci_Milk
Chocci_Milk4w ago
I have made the code changes for you. All you need to do now is sync the data
Cubeyy
CubeyyOP4w ago
Oh I didn't know what you meant by 'Try now' my bad. I am not sure if my recent prompts overrode what you did. I just resynced and it looks the same to me
No description
Chocci_Milk
Chocci_Milk4w ago
Ok, the code is fixed again
Cubeyy
CubeyyOP4w ago
thank you for that, I resynced again just in case but still just shows the initials of the product in those boxes

Did you find this page helpful?