renames js class
This commit is contained in:
@@ -6,7 +6,7 @@ App.Documentable =
|
||||
|
||||
initializeDirectUploads: ->
|
||||
|
||||
$('input.document_ajax_attachment[type=file]').fileupload
|
||||
$('input.js-document-attachment[type=file]').fileupload
|
||||
|
||||
paramName: "document[attachment]"
|
||||
|
||||
@@ -38,7 +38,7 @@ App.Documentable =
|
||||
return
|
||||
|
||||
initializeInterface: ->
|
||||
input_files = $('input.document_ajax_attachment[type=file]')
|
||||
input_files = $('input.js-document-attachment[type=file]')
|
||||
|
||||
$.each input_files, (index, file) ->
|
||||
wrapper = $(file).parent()
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
background-color: $light-gray;
|
||||
}
|
||||
|
||||
input.document_ajax_attachment[type=file]{
|
||||
.js-document-attachment {
|
||||
display: none;
|
||||
}
|
||||
|
||||
|
||||
@@ -54,7 +54,7 @@ module DocumentsHelper
|
||||
def render_attachment(document, index)
|
||||
html = file_field_tag :attachment,
|
||||
accept: accepted_content_types_extensions(document.documentable_type.constantize),
|
||||
class: 'document_ajax_attachment',
|
||||
class: 'js-document-attachment',
|
||||
data: {
|
||||
url: document_direct_upload_url(document),
|
||||
cached_attachment_input_field: document_nested_field_id(document, index, :cached_attachment),
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
<%= file_field_tag :attachment,
|
||||
accept: accepted_content_types_extensions(document.documentable.class),
|
||||
label: false,
|
||||
class: 'document_ajax_attachment',
|
||||
class: 'js-document-attachment',
|
||||
data: {
|
||||
url: upload_documents_url(documentable_type: document.documentable_type, documentable_id: document.documentable_id),
|
||||
cached_attachment_input_field: "document_cached_attachment",
|
||||
|
||||
Reference in New Issue
Block a user