This Tutorial will show how to create shopping cart in MVC using Jquery and Ajax.
In previous artilce I have shown How to create login and Registration page in MVC
Step 1- Create a new Empty MVC project.
Step 2- Add the following class to your model folder.
publicclass Item
{
[Key]
publicint Id { get; set; }
publicstring Name { get; set; }
publicint Price { get; set; }
publicstring Description { get; set; }
publicstring Category { get; set; }
publicint Offer { get; set; }
publicstring ImagePath { get; set; }
}
publicclass Cart
{
[Key]
publicint Id { get; set; }
publicstring UserName { get; set; }
publicint ItemId { get; set; }
}
View original post 974 more words