(NOTE: I do not know if this is the right place to ask this question, if not, I apologize)
I’m now at Task D of the depot application, and at this point a very basic question appears. I guess this is a basic RUBY question but I have no answer for it:
def add_to_cart begin product = Product.find(params[:id]) …
Question: if add_to_cart has no parameters where is params defined?, how do i get access to id? How is that I get access to the Product table of the database? I guess everything relays on the objects hierarchy.
I know is basic, but now I’m a bit lost.
thanks is advance