On Dec 11, 12:12 am, Mauro
<mrsan...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
wrote:> Here is the partial:
>
> %tr
> %td
> = company.name
> - unless company.reports.nil?
> = link_to image_tag("alert.png"),
"#company_reports", :class => "reports"
> %td
> - company.categories.each do |category|
> = link_to category.name, category_path(category)
> - unless category == company.categories.last
> –
> %td= link_to t(''Show''), company
> %td= link_to t(''Edit''), edit_company_path(company)
> %td= link_to t(''Destroy''), company, :confirm =>
''are_you_sure'',
> :method => :delete
>
> %div(style="display: none;")
> #company_reports
> = company.name
>
> When I click in the link with image "alert.png" is displayed the
name
> of another company but not the current company.
> Why?
Presumably you''ve got some JavaScript that shows divs in response to
these clicks. All of these divs have the same id, so the browser isn''t
going to know which one to show
Fred
--
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
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en.