1. I have teams, teams_users, and users. I want to be able to assign
users to teams by checking a checkbox on the team edit page or
something simple like that, without being able to add a user from any
of the teams pages. Is there an example of this kind of many-to-many
relationship and how to handle it in active_scaffold? Is it better to
do hmt or habtm? Am I actually including teams_users as a field, or
users?
2. I want to have access to the current user when determining the
contents of some select lists. Is this possible? can you point me to
some example?
Thank you very much for any info on these things.
has_many :team_users
has_many :users, :through => :team_users, :readonly => false
has_many :team_users
has_many :teams, :through => :team_users, :readonly => false
conf.columns[:users].set_ui = :select
conf.columns[:users].options = {:draggable_lists => true}