yes it does understand. i think you need to update your viewhints
files...

in user_hints.rb put...

children :lots

and in lot_hints.rb put

children :users

also i think your lots_users model needs to be a hobo generated one
too... (should have hobo_model etc..)

On 13 July, 19:38, spokra <[email protected]> wrote:
> does hobo understand how to display a has_many through relationship?
>
> I'm trying to add a association of many lots per user.
>
> class Lot < ActiveRecord::Base
>
>   hobo_model # Don't put anything above this
>
>   fields do
>     number :integer
>     code   :string
>     timestamps
>   end
>   has_many :lots_users
>   has_many :users, :through =>'lots_users', :foreign_key =>'user_id'
> .....
>
> class User < ActiveRecord::Base
>
>   hobo_user_model # Don't put anything above this
>
>   fields do
>     name          :string, :required, :unique
>     email_address :email_address, :login => true
>     administrator :boolean, :default => false
>     timestamps
>   end
>   has_many :lots_users
>   has_many :lots, :through =>'lots_users', :foreign_key => 'lot_id'
>
> ....
>
> class LotsUsers < ActiveRecord::Base
>         belongs_to      :user
>         belongs_to      :lot
> end

-- 
You received this message because you are subscribed to the Google Groups "Hobo 
Users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/hobousers?hl=en.

Reply via email to