Started note attachment changes, and text changes
This commit is contained in:
parent
597afb7ce2
commit
c2c4424ff8
|
@ -38,8 +38,9 @@ init:
|
||||||
});
|
});
|
||||||
|
|
||||||
$("#note_attachment").change(function(e){
|
$("#note_attachment").change(function(e){
|
||||||
var val = $('input[type=file]').val();
|
var val = $('.input-file').val();
|
||||||
var filename = val.substr(val.lastIndexOf("/"));
|
var filename = val.substr(val.lastIndexOf("/"));
|
||||||
|
console.log(filename,val);
|
||||||
$(".file_name").text(filename);
|
$(".file_name").text(filename);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -25,7 +25,7 @@
|
||||||
%h5 Attachment:
|
%h5 Attachment:
|
||||||
.clearfix
|
.clearfix
|
||||||
.attachments.breadcrumb
|
.attachments.breadcrumb
|
||||||
%span.file_name File name...
|
%div.file_name File name...
|
||||||
%button.file_upload.btn.primary Upload File
|
%button.file_upload.btn.primary Upload File
|
||||||
.input= f.file_field :attachment, :class => "input-file"
|
.input= f.file_field :attachment, :class => "input-file"
|
||||||
%span Any file less then 10 MB
|
%span Any file less then 10 MB
|
||||||
|
|
Loading…
Reference in a new issue