vholik / medusa-custom-attributes

Plugin that extends MedusaJs with custom attributes API
92 stars 20 forks source link

CSV Export / Import support? #11

Open hmmhmmhm opened 12 months ago

hmmhmmhm commented 12 months ago

Do the additional fields created by this plugin support CSV import/export? And if not, would it be best to create my own custom import/exporter?

vholik commented 12 months ago

No it doesn't support CSV import/export, If you want to contribute and create this functionality I will verify it and if everything will be great it would be released in a next version.

hmmhmmhm commented 12 months ago

@vholik Fuuu.... To be honest, I really need this feature. However, I'm not sure if this is something that can be done in the plugin at the moment, as I don't have a lot of time on my hands right now, so I'll probably end up creating a separate extraction page or script rather than modifying this plugin.

I'm also looking to see if there are any ideas or breakthroughs that could solve this at the plugin level, but my knowledge of Medusa plugins is still pretty shallow. I'll give it a shot though.

vholik commented 12 months ago

You can create migration script that parse from csv and on every attribute it would make POST request to add it.

TrinhQuangvo commented 11 months ago

You can create migration script that parse from csv and on every attribute it would make POST request to add it.

how can i add the thumbnail for each of attributes ?

vholik commented 11 months ago

You can create migration script that parse from csv and on every attribute it would make POST request to add it.

how can i add the thumbnail for each of attributes ?

You can use metadata field in attribute model to add your thumbnail or store whatever data you like, also you can add metadata to every attribute value. https://github.com/vholik/medusa-custom-attributes/blob/main/src/models/attribute.ts

Amaljith64 commented 4 months ago

Is there any updates on this issue? If not, could you provide information on how to do this? I'll work on that.

TrinhQuangvo commented 4 months ago

@vholik Fuuu.... To be honest, I really need this feature. However, I'm not sure if this is something that can be done in the plugin at the moment, as I don't have a lot of time on my hands right now, so I'll probably end up creating a separate extraction page or script rather than modifying this plugin.

You should download and edit his extension locally. In my situation, I downloaded it and added my custom fields instead of using the metadata fields. Therefore, you shouldn't rely on his extension to address all your problems; you need to handle it yourself.

NicolasGorga commented 4 months ago

Hey guys, has anybody extended the import of product, to handle parsing custom attributes defined in the store? Meaning, apart from the out-of-the-box import product functionality, to make it possible to define attribute values on the csv and then store them in the DB against the product.

Would be keen to collaborate ASAP on this

Amaljith64 commented 3 months ago

Hey guys, has anybody extended the import of product, to handle parsing custom attributes defined in the store? Meaning, apart from the out-of-the-box import product functionality, to make it possible to define attribute values on the csv and then store them in the DB against the product.

Would be keen to collaborate ASAP on this

did you got any solution?

NicolasGorga commented 4 days ago

Hey @Amaljith64 I was tackling some more urgent things, but i have reached the point now where i need the import / export functionality to consider custom attributes defined.

Has anyone haad a go on this? Would be keen to chat about how i think we could do this (i don't have extensive knowledge on the out-of-the-box import / export product functionality). I have read the code regarding the CSV parser and batch job in charge of creating the product, it is rather big / complex.