[Rails] Re: How do I make this relation?

2016-05-14 Thread Luis
Thanks Colin, that did it. -- 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+unsubscr...@googlegroups.com. To post to this group, send

Re: [Rails] Re: How do I make this relation?

2016-05-13 Thread Colin Law
On 13 May 2016 at 07:10, Colin Law wrote: > > On 12 May 2016 11:44 p.m., "Luis" wrote: >> >> Ok there is something that I am not getting in here I think this should >> work. What am I missing ? >> >> class Sched < ActiveRecord::Base >> belongs_to :admiting_md, :foreign_key => :admiting_md ,:cl

Re: [Rails] Re: How do I make this relation?

2016-05-12 Thread Colin Law
On 12 May 2016 11:44 p.m., "Luis" wrote: > > Ok there is something that I am not getting in here I think this should work. What am I missing ? > > class Sched < ActiveRecord::Base > belongs_to :admiting_md, :foreign_key => :admiting_md ,:class_name => "Pcp" > end > > class Pcp < ActiveRecord::B

[Rails] Re: How do I make this relation?

2016-05-12 Thread Luis
Ok there is something that I am not getting in here I think this should work. What am I missing ? class Sched < ActiveRecord::Base belongs_to :admiting_md, :foreign_key => :admiting_md ,:class_name => "Pcp" end class Pcp < ActiveRecord::Base has_many :admiting_mds, :foreing_key => :admi

[Rails] Re: How do I make this relation?

2016-05-12 Thread Luis
Hi Colin, Yes you are correct I meant admitting_md. My allergies are killing me but I need to finish this project soon. I posted like the 3rd version of the 5 tries at this point I am making a lot of syntax due to how swollen my eyes are due to the pollen allergy. My apologies in advance! I