You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a column in a .csv file meant to populate a Spree::ProductProperty called "product_family". I wrote the column name in the csv as [Prop]product_family, but found that after importing the csv using SolidusImportProducts::Import.call, I found the generated products did not have the product property field set.
After digging into the gem's code a bit, I found that a Spree::Property with a given name must exist in order for SIP to set the product property with the same name. So we fixed this issue by first creating the Spree::Property:
Doing this before the import caused products to have the desired property.
This requirement wasn't obvious to me, considering OptionTypes and OptionValues are generated automatically if they don't exist when encountered by the importer. I'd be up for taking a crack at implementing the fix to make ProductProperties automatic, but in the meantime, would you consider updating the README to make a note about this?
The text was updated successfully, but these errors were encountered:
I have a column in a .csv file meant to populate a
Spree::ProductProperty
called "product_family". I wrote the column name in the csv as[Prop]product_family
, but found that after importing the csv usingSolidusImportProducts::Import.call
, I found the generated products did not have the product property field set.After digging into the gem's code a bit, I found that a
Spree::Property
with a given name must exist in order for SIP to set the product property with the same name. So we fixed this issue by first creating theSpree::Property
:Doing this before the import caused products to have the desired property.
This requirement wasn't obvious to me, considering OptionTypes and OptionValues are generated automatically if they don't exist when encountered by the importer. I'd be up for taking a crack at implementing the fix to make ProductProperties automatic, but in the meantime, would you consider updating the README to make a note about this?
The text was updated successfully, but these errors were encountered: