Merge pull request #268 from warpc/228-fix_remember_me

[Refs #228] Fix checking remember me button
This commit is contained in:
Vladimir Sharshov 2012-03-05 03:14:24 -08:00
commit 6e02d50664
2 changed files with 13 additions and 1 deletions

View File

@ -20,4 +20,16 @@ $(document).ready(function() {
$(this).addClass('registartion-input-no-focus').removeClass('registartion-input-focus');
});
$('#niceCheckbox1').click(function() {
var el = $(this),
input = el.find('input[type="checkbox"]');
if(input.attr("checked")) {
el.css('backgroundPosition', '0 0');
input.removeAttr('checked');
} else {
el.css('backgroundPosition', '0 -18px');
input.attr('checked', true);
}
return true;
});
});

View File

@ -20,7 +20,7 @@
.registration
.remember
.check
%span#niceCheckbox1.niceCheck{:onclick => "changeCheck(this)"}
%span#niceCheckbox1.niceCheck
= f.check_box :remember_me
.text=t('devise.sessions.remember_me')
.in=f.submit t('layout.devise.shared_links.sign_in'), :class => 'button', :id => 'btnLogin'