I was practicing rails by creating a food ordering website some what similar to FoodPanda. For now I have created pages to display restaurants, in restaurant profile to display menu items. I stuck up with a doubt how could I add the add to cart functionality button for a menu item. I request some one to help me for its functionality. Please find the screenshot attachment of the restaurant profile page with menu items. Thanks in Advance.
I was practicing rails by creating a food ordering website some what similar to FoodPanda. For now I have created pages to display restaurants, in restaurant profile to display menu items. I stuck up with a doubt how could I add the add to cart functionality button for a menu item. I request some one to help me for its functionality. Please find the screenshot attachment of the restaurant profile page with menu items.
Are you looking for design ideas, as in what models you will need and how to organize their associations and controllers? What have you tried so far in the direction of creating a cart?
Note that there are full-blown shopping carts out there (shopify have open-sourced theirs, I think, probably many others) but if you are learning, then making your own is a great exercise.
Try to narrow down your question a bit (and try something first), and someone here can help you.
Walter
Thanks for your kind words Walter, I have finally created the cart functionality using a controller.
Thanks for the response
Can you post in github? I need learn too. Thanks!