Hi, i have 4 tables: questions, answers, users, and inquiries
(relationship)
def index
question_id = params[:id].to_i
question = Question.find(question_id)
@answers = question.answers
respond_to do |format|
format.ext_json { render :json => @answers.to_ext_json(:class =>
Answer) }
end
end
I have several scaffold in extjs, when I click on row, i get answers on
question that i just selected, COOL. But i need paste in this info email
of people (emails stores in users table). Now i have this:
| id | answer |
1 | lala
2 | lalala2
but i need this:
| id | answer | email
1 | lala | [email protected]
2 | lal2 | [email protected]
--
Posted via http://www.ruby-forum.com/.
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" 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/rubyonrails-talk?hl=en.