From 9d1822e7c6d1a8ffd636053d1e581948d6dddae5 Mon Sep 17 00:00:00 2001 From: Ingo Schommer Date: Fri, 6 Jan 2012 16:54:16 +0100 Subject: [PATCH] MINOR Don't allow page type selection in add form when radio button is disabled --- javascript/CMSMain.AddForm.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/javascript/CMSMain.AddForm.js b/javascript/CMSMain.AddForm.js index 6b4a9cf2..24536d05 100644 --- a/javascript/CMSMain.AddForm.js +++ b/javascript/CMSMain.AddForm.js @@ -69,10 +69,11 @@ this.setSelected(true); }, setSelected: function(bool) { + var input = this.find('input'); this.toggleClass('selected', bool); - if(bool) { + if(bool && !input.is(':disabled')) { this.siblings().setSelected(false); - this.find('input').attr('checked', 'checked'); + input.attr('checked', 'checked'); } }, setEnabled: function(bool) {