title: Can a custom to_s method be created for a specific association collection?
body: <p>I have an <code>Entry</code> model which <code>has_many :tags</code>. I want to be able to list my tags in an text input (ie. "tag-1, tag-2", etc.), however, I am running into an issue.</p>
  
  <p>If I just use </p>
  
  <pre><code>form_for(:entry, form_options) do |f|
    f.text_field :tags
  end
  </code></pre>
  
  <p>My text box gets created, but is filled with something like <code>#&lt;Tag:0xb79fb584&gt;#&lt;Tag:0xb79faddc&gt;</code>, which is obviously not what I'm looking for.</p>
  
  <p>I know I can add a <code>to_s</code> method to Tag:</p>
  
  <pre><code>class Tag &lt; ActiveRecord::Base
    def to_s
      name # the name of the tag
    end
  end
  </code></pre>
  
  <p>But that just leaves me with something like <code>tag-1tag-2</code> because <code>@entry.tags.to_s</code> still just refers to <code>Array#to_s</code>.</p>
  
  <p>Right now, I am using</p>
  
  <pre><code>f.text_field :tags, :value =&gt; @entry.tags.map(&amp;:name).join(", ")
  </code></pre>
  
  <p>instead, which will display the correct string, but doesn't feel like the "rails way" of doing things. Is there a way I can add a custom <code>to_s</code> method specifically to my <code>tags</code> association? </p>