- 36 名前:nobodyさん mailto:sage [2013/09/12(木) 23:09:03.21 ID:???]
- 質問させて頂きます。
下記のリレーションを持つモデルがあります。 User hasmany Thread(Thread belongsto User) Thread hasmany Response(Response belongsto Thread) User hasmany Response(Response belongsto User) Threadの詳細表示画面(viewアクション)で 一覧表示されるResponseのuser_idの代わりに、 Userテーブルのフィールドの一つであるusernameを 表示させたいんですが、スマートなやり方はありますか? 力技で何とかしようと結構時間を掛けて試行錯誤したんですが 上手く行かなくて質問させて頂きました。
|

|