Convert data-association-insertion-template to string before escaping to html.

If CGI has been monkeypatched by the escape_utils gem, we need to
convert rendered association from ActiveSupport::SafeBuffer to String
in order for it to be escaped.