This plug-in lets you import selected products into Magento from SellerCloud. SellerCloud creates XML based on selected products and calls the plug-in in this context located in your Magento site and update those products directly without using the native Magento API. This facilitates smooth and performing product/inventory updates to your Magento website. We do have the option to import products into Magento without a plugin but it is limited in many ways. For example, the Magento API doesn't support configurable products, such as products with various sizes and colors. Also, the Magento API can be very high on bandwidth and slow things down if you are managing many thousands of products. We developed this plugin to avoid the limitations of the native Magento API.
SelerCloud supports Magento versions 1 and 2. Different plugins with different installations instructions are required for each version.
Magento Version 1+
Obtain Magento Plug-In from SellerCloud Support and install on FTP.
HOW TO INSTALL:
- Upload _import folder off plugin to http://yoursite.com/ so that http://www.yoursite.com/_impor... is accessible
- Upload _export folder off plugin to http://yoursite.com/ so that http://www.yoursite.com/_expor... is accessible
- Please make sure "files" under _import and _export folders have execution rights. 0445 is preferred, otherwise 0777.
- Please make sure _import and _export folders have execution rights set to 0775 or 0777.
- The first time, the import.php is called; a MySQL table will automatically be created in the same database your Magento instance is using.
Structure of the table: job
id BIGINT NOT NULL AUTO_INCREMENT,
submittedon DATETIME NOT NULL ,
processedon DATETIME NULL ,
localfilename VARCHAR( 100 ) NOT NULL ,
status TINYINT NOT NULL ,
logfilename VARCHAR( 100 ) NOT NULL
Note: “id” is the primary key.
Magento Version 2+
HOW TO INSTALL:
- Upload extension: upload to remote server so that Sellercloud folder (in plugin zip) is placed under /app/code
- Enable module: a) Go to Admin > Store > Configuration > Advanced > Advanced. Enable "Sellercloud_Scm2" OR b) from FTP, edit /app/etc/config.php, add an entry 'Sellercloud_Scm2' => 1.
- Run setup upgrade: Log into your terminal via ssh access and go to your magento root directory. Then run this command "php bin/magento setup:upgrade".
- Compile: Run this command “sudo ./magento setup:di:compile”. Compilation is needed when any modified code in extension is uploaded. This can take more than 10 minutes.
- Clean Cache: Either from Admin > System > Cache Management OR through command "php bin/magento:cache:clean"
- SSH Access is needed if we need to run command from console. Example:
- After logging into SSH console -
- command: cd public_html
- command: bin/magento setup:upgrade
- command: bin/magento setup:di:compile
Setup the CRON: (Use the following steps if you want to automate the scheduled import)
Why set up CRON?
Say you selected some products in SellerCloud console for the purpose of exporting into Magento site (refer to 5. FILTER PRODUCTS IN SELLERCLOUD… ). When you do Launch on Magento SellerCloud will create a job in Magento site database, because product import in Magento can take considerable amount of time. If CRON is set up in your Magento site control panel, it is your Magento site’s responsibility to execute “import process” internally. You don’t need to wait for the “import process” to be complete in SellerCloud console. So, based on the number of products, you can set the CRON interval. If you think that the “import process” is a one time thing, you can disable CRON after process is over.
CRON is usually set up within the control panel of your site. Create a CRON entry at an interval of your choice, point /www/.../cron.php as end point. Normally, CRON path is a physical path to the cron file i.e. /public_html/_import/cron.php. CRON service will fire at a predetermined interval; will execute one job at a time based on job’s creation date. Note that interval for the CRON depends on how long each import job takes. All the jobs with the status of “submitted” or “processing” are eligible for execution.
Manual execution of Job:
If somehow, you want to run or re-run a job, open http://yoursite/_import/cron.php?id=
Please replace <JOBID> with the actual Magento Job#. Where to find job# ? Open
SellerCloud console, navigate to Home->Companies->YourCompany->Magento General Settings->Uploaded Documents. You will find a list of jobs executed or queued to be executed.
Setup SellerCloud to port the product XML to the Magento site:
Note: There is no need to map SellerCloud fields to magento fields.
Navigate to Home > Companies > YourCompany > Magento General Settings
Magento Enabled checkbox should be ON
Switch on the checkbox “Enable Custom Plug-in for Communication”
Enabling “Enable Custom Plug-in for Communication” above will allow the user to enter magento plug-in URL.
Enter your magento URL in the textbox, captioned as “Custom Plug-in Base URL”. The plug-in base URL should look like “http://yoursite.com/"
Most likely, you will also want to check the following options: 'Enable New Products upload' and 'Enable Update existing Products'
Filter products in SellerCloud and export them to Magento
Go to Manage Inventory->Search
Search the products to get a filtered list of products or allow search to display all the products. You should be able to see which rows are enabled for Magento by checking the Magento icon.
To export a single product from SellerCloud, click on Magento icon. On the Magento Properties page, select the action “Post product on Magento” and click go button.
To export multiple products from SellerCloud, select products that you want to export from Manage Inventory and then the action “Launch on Channel" press GO. Then select Magento and click Continue.
You will be taken to another page displaying your product selection. Click the button “Launch on Magento”.
If number of items is small, (<=5), plug-in will process the products immediately, otherwise a job will be scheduled in order of execution.
Check the status of a submitted request by viewing the job status. SellerCloud has an uploaded file log, that will show you the Job# and you can use that to lookup the log. If your job ID# is 123, then use the url http://yoursite/_import/getjob...
The XML for that job which should look like this:
After you get this response, use the logfilename to get additional detail about what happened with this job. Here is an example of what import-log-121130040142.xml would look like: