app/helpers/alchemy/admin/contents_helper.rb in alchemy_cms-2.6.3 vs app/helpers/alchemy/admin/contents_helper.rb in alchemy_cms-2.7.0

- old
+ new

@@ -1,9 +1,8 @@ module Alchemy module Admin module ContentsHelper - include Alchemy::Admin::BaseHelper # Returns a string for the id attribute of a html element for the given content def content_dom_id(content) return "" if content.nil? @@ -12,9 +11,14 @@ return "" if c.nil? else c = content end "#{c.essence_type.demodulize.underscore}_#{c.id}" + end + + # Returns a jquery selector string of form field ids from given contents + def contents_form_field_ids_string(contents) + contents.collect { |c| "##{c.form_field_id}" }.join(', ') end # Renders the name of elements content or the default name defined in elements.yml def render_content_name(content) if content.blank?