cancel
Showing results for 
Search instead for 
Did you mean: 

Updating Products In Plugin

SOLVED

Updating Products In Plugin

Hi

 

My main goal is to have a plugin which inserts/updates my products.

 

All my products are currently in a business management software database which I have SQL access for. What is the best way to go about this?

 

I guess what I'm looking for is how to add/update products inside of a plugin.

 

This it the current plan:

  • Have the plugin code run on a CRON job

  • Connect to the BMS and select the records (which will include the fields that the Magento Import system requires)

  • Go line by line and either inserts or updates the record (guessing by checking if the SKU already exists)

Thanks

1 ACCEPTED SOLUTION

Accepted Solutions

Re: Updating Products In Plugin

Hi @zcoyne,

 

Maybe you can take a look to this library: https://github.com/firegento/FireGento_FastSimpleImport2 (you'll find some examples too: https://github.com/firegento/FireGento_FastSimpleImport2_Demo )

 

You can create a cronjob or a console command to parse your external data an then use the library to insert/update your products.

On the demo link you'll find some examples of how to use the library.

 

 

View solution in original post

4 REPLIES 4

Re: Updating Products In Plugin

Hi @zcoyne,

 

Maybe you can take a look to this library: https://github.com/firegento/FireGento_FastSimpleImport2 (you'll find some examples too: https://github.com/firegento/FireGento_FastSimpleImport2_Demo )

 

You can create a cronjob or a console command to parse your external data an then use the library to insert/update your products.

On the demo link you'll find some examples of how to use the library.

 

 

Re: Updating Products In Plugin

Hi

 

Thanks for the link. This is exactly what I needed.

Where would I store the products as I can see it's ran via composer.

Re: Updating Products In Plugin

Using compsoer you'll be able to install the library.

Then you should create your own module/cron/console command and inside your code you could use the library.

Re: Updating Products In Plugin

Thank you