project/templates/registration/submit-registration.html
branchpayments
changeset 264 f80e1c78dcc0
parent 250 ac52304d265d
child 315 566e5f783e75
--- a/project/templates/registration/submit-registration.html	Tue Nov 16 17:37:36 2010 +0530
+++ b/project/templates/registration/submit-registration.html	Tue Nov 16 17:38:06 2010 +0530
@@ -19,6 +19,20 @@
         $('#id_sex').removeAttr('disabled');
       }
     });
+
+    if (!$('#id_paid').is(':checked')) {
+        $('#id_type').attr('disabled', 'disabled');
+        $('#id_details').attr('disabled', 'disabled');
+      }
+      $('#id_paid').change(function() {
+        if (!$('#id_paid').is(':checked')) {
+          $('#id_type').attr('disabled', 'disabled');
+          $('#id_details').attr('disabled', 'disabled');
+        } else {
+          $('#id_type').removeAttr('disabled');
+          $('#id_details').removeAttr('disabled');
+        }
+      });
   });