app/presenters/georgia/slide_portlet.rb in georgia-0.7.8 vs app/presenters/georgia/slide_portlet.rb in georgia-0.8.0
- old
+ new
@@ -34,18 +34,22 @@
def image_input_tag
hidden_field_tag("revision[slides_attributes][#{id}][contents_attributes][#{content_id}][image_id]", @content.image_id)
end
def slide_content_tag
- content_tag(:div, title_input_tag + text_input_tag + locale_input_tag, class: 'slide-text')
+ content_tag(:div, content_id_tag + title_input_tag + text_input_tag + locale_input_tag, class: 'slide-text')
end
def id_input_tag
hidden_field_tag("revision[slides_attributes][#{id}][id]", id)
end
def position_input_tag
hidden_field_tag("revision[slides_attributes][#{id}][position]", position, class: 'js-position')
+ end
+
+ def content_id_tag
+ hidden_field_tag("revision[slides_attributes][#{id}][contents_attributes][#{content_id}][id]", @content.id)
end
def title_input_tag
text_field_tag("revision[slides_attributes][#{id}][contents_attributes][#{content_id}][title]", @content.title, class: 'form-control', placeholder: 'Title')
end
\ No newline at end of file