Ruby on Rails Tuesday, November 24, 2015

On 24 November 2015 at 05:38, glomb <glombmail@gmail.com> wrote:
Hi,
I am kinda new to ruby but i know how to do the basic stuff but this has me really stumped. 
I want to create a page were a user can create a shipment with a customizable supply chain. For example: a user makes a new shipment so it starts at the origin and then it goes to point A for packaging then to point B then to point A again then to point C then to point D then to B then to the destination. 
Every shipment starts with an origin and ends with a destination, and every point should have a page. points can repeat and the user creates the points.

                                         
New Supply chain page
origin
Create new shipment pagepoint A
previously created  supply chains listpoint B
create new supply chainpoint A
point  C
point D
point B
destination
Originpoint  A Destination 
title title title 
texttexttext
upload attachmentupload attachmentupload attachment


Does this make sense? How can I go about doing this? what is this called? Is there a tutorial I can watch that is similar? 
any help will be appreciated. 



My approach in this situation would be to first consider how to store the data, then later work out how to display and enter it.  So you need to decide on the models (possibly User,  Shipment, Location), the relationships between them (has_many, belongs_to etc), and the attributes for each object.  Think about that first and come back to discuss your ideas if you are not sure.

Colin


--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/CAL%3D0gLvS6tBGfDVsdReVj%2BYXoL6x-TmMEUzaGi5H6nJJuxG9aQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment