Sitefinity Ecommerce – Importing Products into Sitefinity Ecommerce

Sitefinity Ecommerce – Importing Products into Sitefinity Ecommerce

Posted on May 10, 2012 0 Comments

The content you're reading is getting on in years
This post is on the older side and its content may be out of date.
Be sure to visit our blogs homepage for our latest news, updates and information.

Using the Sitefinity API, I would like to show you how you can import products into Sitefinity Ecommerce.  

How it Works

The product importer is actually a widget that is placed onto a page.  Once the page has been created, bring up the page in a browser and follow the instructions to upload your file of products to import.   Once you have uploaded your file, the product importer widget reads the values from your file and inserts them into the database.   The latest version of Product Import(Product upload widget) is available on github https://github.com/esitefinity/Sitefinity-Ecommerce-Product-Upload and the code behind utility classes that are used by the widget and that you need are available also on github here https://github.com/esitefinity/ProductUploadPackage.  We highly recommend using the latest version available from github. There is a NuGet package as well but it is possible that it is outdated.

In the example I am using a .csv file as my data input.  The format of this file has been created such that you can add many custom product type fields at the end of the file.  Here we are only going to create two custom product type fields, CustomProperty1,CustomProperty2.

Installation

  Once you have NuGet installed, please follow the following installation steps.

Installation Steps

  1. If you want to try using the NuGet Package: Right click on your solution and select “Manage NuGet Packages…”.
    image
  2. In the Manage NuGet Packages window, select “Online” on the left side column then search for “Sitefinity”.    NuGet will find the Sitefinity package allowing you to install it directly into your Visual Studio Solution.
    image
  3. Create a folder called “upload” at the top level of your solution.  This is where the .csv file will be uploaded in to.
  4. Copy over the file upload widget control into the root of your solution.  You can download latest version of the Widget from GitHub.
  5. Open Sitefinity Thunder and add the widget to Sitefinity
    image
  6. Build your solution
  7. Start your solution without debugging
  8. When your Sitefinity web site comes up, login to the backend of Sitefinity
  9. In the top navigation, click on “Ecommerce” and select   “Type of Products”.  
  10. Create all of your product types that you will be importing all of your products into. 
  11. Create a new page in Sitefinity and call it productimport
  12. Drag and Drop the new widget you inserted using Sitefinity Thunder onto the page.   Save the page.
  13. Bring up this page in your browser and upload your .csv file.  This will upload your .csv file into a folder called “upload”, located in the root of your solution.
    image
  14. In the top navigation, go to “Ecommerce” and select “Products” and you should now see all of your products imported.

I have created a video showing you how to install the Product Upload package using NuGet, add a widget using Sitefinity Thunder and upload your .csv file.

Sitefinity Ecommerce Product Import

image

 

Credits and thank you to Venkata Koppaka for programming this! Smile

progress-logo

The Progress Team

View all posts from The Progress Team on the Progress blog. Connect with us about all things application development and deployment, data integration and digital business.

Comments

Comments are disabled in preview mode.
Topics

Sitefinity Training and Certification Now Available.

Let our experts teach you how to use Sitefinity's best-in-class features to deliver compelling digital experiences.

Learn More
Latest Stories
in Your Inbox

Subscribe to get all the news, info and tutorials you need to build better business apps and sites

Loading animation