[Git][noosfero/noosfero][master] 2 commits: Fixes generation of empty elements
Rodrigo Souto
gitlab at mg.gitlab.com
Mon May 7 16:28:50 BRT 2018
Rodrigo Souto pushed to branch master at Noosfero / noosfero
Commits:
e2a0289e by MatheusRich at 2018-05-04T20:23:51Z
Fixes generation of empty elements
- - - - -
f86c721a by Rodrigo Souto at 2018-05-07T19:28:24Z
Merge branch 'empty-elements' into 'master'
#328 - Empty Elements
See merge request noosfero/noosfero!1462
- - - - -
1 changed file:
- public/javascripts/application.js
Changes:
=====================================
public/javascripts/application.js
=====================================
--- a/public/javascripts/application.js
+++ b/public/javascripts/application.js
@@ -1160,7 +1160,6 @@ function add_uploaded_file() {
var input = template.find('input[type=file]')[0]
var file_number = $('#uploaded_files .file-fieldset').length
- template.removeClass('template')
$(input).attr('name', 'uploaded_files[' + file_number + '][file]')
template.find('.crop_x').attr('name', 'uploaded_files[' + file_number + '][crop_x]')
template.find('.crop_y').attr('name', 'uploaded_files[' + file_number + '][crop_y]')
@@ -1171,6 +1170,7 @@ function add_uploaded_file() {
$(input).click()
$(input).change(function() {
let file = input.files[0];
+ template.first().removeClass('template')
template.find('.file-name').text(file.name)
template.find('.file-size').text(format_bytes(file.size))
})
View it on GitLab: https://gitlab.com/noosfero/noosfero/compare/c1eb8c8b9d2814b9184f90cceca26bad152dc02f...f86c721a6b7ba92b699824df9bf60d3411401d36
--
View it on GitLab: https://gitlab.com/noosfero/noosfero/compare/c1eb8c8b9d2814b9184f90cceca26bad152dc02f...f86c721a6b7ba92b699824df9bf60d3411401d36
You're receiving this email because of your account on gitlab.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listas.softwarelivre.org/pipermail/noosfero-dev/attachments/20180507/d8ea4832/attachment-0001.html>
More information about the Noosfero-dev
mailing list