Commit 0029a95708eb8a3754d1c01db1cd0063f6d6e22d
1 parent
aa657272
Exists in
master
and in
1 other branch
Apply "disabled" attribute to inputs, not div
Showing
1 changed file
with
1 additions
and
1 deletions
Show diff stats
public/javascripts/form.js
@@ -74,7 +74,7 @@ function activateTypeSelector(field_class, section_class) { | @@ -74,7 +74,7 @@ function activateTypeSelector(field_class, section_class) { | ||
74 | $('div.'+field_class+' input[name*='+field_class+'_type]').live('click', function(){ | 74 | $('div.'+field_class+' input[name*='+field_class+'_type]').live('click', function(){ |
75 | var chosen = $(this).val(); | 75 | var chosen = $(this).val(); |
76 | var wrapper = $(this).closest('.nested'); | 76 | var wrapper = $(this).closest('.nested'); |
77 | - wrapper.find('div.chosen.'+section_class).removeClass('chosen').attr('disabled','disabled');; | 77 | + wrapper.find('div.chosen.'+section_class).removeClass('chosen').find('input').attr('disabled','disabled'); |
78 | wrapper.find('div.'+section_class+'.'+chosen).addClass('chosen').find('input').removeAttr('disabled'); | 78 | wrapper.find('div.'+section_class+'.'+chosen).addClass('chosen').find('input').removeAttr('disabled'); |
79 | }); | 79 | }); |
80 | } | 80 | } |