Sha256: 14096d8d7ebd6cf6a6a59af001475e3cdaf3917d27df3cfaeecfb257ca7e870c
Contents?: true
Size: 465 Bytes
Versions: 5
Compression:
Stored size: 465 Bytes
Contents
- entity_name = controller.controller_name.singularize.underscore - @entity = instance_variable_get("@#{entity_name}") - id = dom_id(@entity) $('##{id}').replaceWith('#{ j render(partial: entity_name, collection: [ @entity ]) }'); $('##{id}').effect("highlight", { duration:1500 }); - if called_from_index_page? = refresh_sidebar(:index) - elsif called_from_landing_page?("campaigns") = refresh_sidebar_for(:campaigns, :show) - else = refresh_sidebar(:show)
Version data entries
5 entries across 5 versions & 1 rubygems