Re: [Rails] New To Community and ROR

2015-12-26 Thread Walter Lee Davis
> On Dec 25, 2015, at 3:11 PM, bryanguillen12 wrote: > > Hey ROR Community, > I am brand new to this fun world world of programming and obviously, ruby on > rails too. I have been picking up some basic skills in programming, enough > to write a !SIMPLE! program, and

[Rails] New To Community and ROR

2015-12-26 Thread bryanguillen12
Hey ROR Community, I am brand new to this fun world world of programming and obviously, ruby on rails too. I have been picking up some basic skills in programming, enough to write a !SIMPLE! program, and also some front end web development. With that said, I am hitting walls all over the

[Rails] how many levels of models should has_many be applied to

2015-12-26 Thread fugee ohu
if users has many profiles and profiles has many schools and schools has many teams then the user model would look like has_many: profiles has_many: schools, through: :profiles has_many: teams, through: :schools, through: :profiles see what i mean on the third line? the teams through schools

Re: [Rails] Why the first user created would get id 2 instead of 1?

2015-12-26 Thread Colin Law
On 26 December 2015 at 15:52, 'krfg' via Ruby on Rails: Talk wrote: > Have any of you any idea why at Heroku the first user created would get id 2 > instead of 1, and ActiveRecord cannot find user with id 1? > > After deploying my application I created a new

Re: [Rails] how does rails know if it should submit a form to update or create?

2015-12-26 Thread fugee ohu
they're the same, <%= render 'form' %> is all they contain other than links and either New model or Editing model On Friday, December 25, 2015 at 4:14:36 AM UTC-5, Colin Law wrote: > > On 25 December 2015 at 07:16, fugee ohu > wrote: > > how does rails know if it should

[Rails] Why the first user created would get id 2 instead of 1?

2015-12-26 Thread 'krfg' via Ruby on Rails: Talk
Have any of you any idea why at Heroku the first user created would get id 2 instead of 1, and ActiveRecord cannot find user with id 1? After deploying my application I created a new user and noticed that the address bar was reporting number 2 at the end of the url:

Re: [Rails] how does rails know if it should submit a form to update or create?

2015-12-26 Thread Colin Law
On 26 Dec 2015 22:35, "fugee ohu" wrote: > > they're the same, <%= render 'form' %> is all they contain other than links and either New model or Editing model I said to look at the HTML not your source code. The form tag is the HTML generated by the form_for code. Also