Simplify imageable/documentable note method names
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
<div class="documents-list">
|
||||
<%= f.label :documents, t("documents.form.title") %>
|
||||
<p class="help-text"><%= documentables_note %></p>
|
||||
<p class="help-text"><%= note %></p>
|
||||
|
||||
<div id="nested-documents" data-max-documents-allowed="<%= max_documents_allowed %>">
|
||||
<%= f.fields_for :documents do |documents_builder| %>
|
||||
|
||||
@@ -16,7 +16,7 @@ class Documents::NestedComponent < ApplicationComponent
|
||||
documentable.class.max_documents_allowed
|
||||
end
|
||||
|
||||
def documentables_note
|
||||
def note
|
||||
t "documents.form.note", max_documents_allowed: max_documents_allowed,
|
||||
accepted_content_types: documentable_humanized_accepted_content_types(documentable.class),
|
||||
max_file_size: max_file_size(documentable.class)
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<%= f.label image_fields, t("images.form.title") %>
|
||||
<p class="help-text"><%= imageables_note %></p>
|
||||
<p class="help-text"><%= note %></p>
|
||||
|
||||
<div id="nested-image">
|
||||
<%= f.fields_for image_fields do |image_builder| %>
|
||||
|
||||
@@ -13,7 +13,7 @@ class Images::NestedComponent < ApplicationComponent
|
||||
f.object
|
||||
end
|
||||
|
||||
def imageables_note
|
||||
def note
|
||||
t "images.form.note", accepted_content_types: imageable_humanized_accepted_content_types,
|
||||
max_file_size: imageable_max_file_size
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user