[Git][noosfero/noosfero][master] 2 commits: Fix recaptcha buttons bar missing

Rodrigo Souto gitlab at mg.gitlab.com
Fri Jun 2 09:53:33 BRT 2017


Rodrigo Souto pushed to branch master at Noosfero / noosfero


Commits:
96235cb6 by pedrodelyra at 2017-06-01T18:13:53-03:00
Fix recaptcha buttons bar missing

- - - - -
91d5bd59 by Rodrigo Souto at 2017-06-02T12:52:55+00:00
Merge branch 'fix-captcha-modal-bug' into 'master'

Fix recaptcha buttons bar missing in comments form

See merge request !1224
- - - - -


2 changed files:

- app/helpers/buttons_helper.rb
- app/views/comment/_comment_form.html.erb


Changes:

=====================================
app/helpers/buttons_helper.rb
=====================================
--- a/app/helpers/buttons_helper.rb
+++ b/app/helpers/buttons_helper.rb
@@ -37,7 +37,7 @@ module ButtonsHelper
   def button_to_function(type, label, js_code, html_options = {}, &block)
     html_options[:class] = "button with-text" unless html_options[:class]
     html_options[:class] << " icon-#{type}"
-    link_to_function(label, js_code, html_options, &block)
+    link_to_function(label, j(js_code), html_options, &block)
   end
 
   def button_to_function_without_text(type, label, js_code, html_options = {}, &block)


=====================================
app/views/comment/_comment_form.html.erb
=====================================
--- a/app/views/comment/_comment_form.html.erb
+++ b/app/views/comment/_comment_form.html.erb
@@ -8,10 +8,10 @@
   <div id="recaptcha-container" style="display: none">
     <h3><%= _('Please type the two words below') %></h3>
     <%= recaptcha_tags(:display => { :theme => 'clean' }, :ajax => true, :ssl => true) %>
-    <% button_bar do %>
-      <%= button_to_function :add, _('Confirm'), "return false", :id => "confirm-captcha" %>
-      <%= button_to_function :cancel, _('Cancel'), "noosfero.modal.close()" %>
-    <% end %>
+    <div class="button-bar">
+      <%= button_to_function :add, _('Confirm'), j("return false"), :id => "confirm-captcha" %>
+      <%= button_to_function :cancel, _('Cancel'), j("noosfero.modal.close()") %>
+    </div>
   </div>
 
   <script type="text/javascript">



View it on GitLab: https://gitlab.com/noosfero/noosfero/compare/4b251dceb01cc53a2c8a98a18c6881323e4eb20f...91d5bd596f5f5395f41a0fca993c66fd1a25238c

---
View it on GitLab: https://gitlab.com/noosfero/noosfero/compare/4b251dceb01cc53a2c8a98a18c6881323e4eb20f...91d5bd596f5f5395f41a0fca993c66fd1a25238c
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/20170602/a43be2bb/attachment-0001.html>


More information about the Noosfero-dev mailing list