I\'m trying to make some restaurant list. I associated two tables, and then write this code.
class Restaurant < ActiveRecord::Base has_many :resta
replace
td = restaurant.restaurant_translations.restaurantname
with
td = restaurant.restaurant_translations.first.restaurantname
this will help you