diff options
Diffstat (limited to 'account/static/js')
| -rw-r--r-- | account/static/js/account_email_resend.js | 19 | 
1 files changed, 19 insertions, 0 deletions
| diff --git a/account/static/js/account_email_resend.js b/account/static/js/account_email_resend.js new file mode 100644 index 0000000..e8d2411 --- /dev/null +++ b/account/static/js/account_email_resend.js @@ -0,0 +1,19 @@ +/* + * email_resend.js for 'account/email_resend.html' + */ + +$(document).ready(function() { +    // disable email field by default +    $("input#id_email").prop("disabled", true); + +    // update email field when 'is_update_email' checkbox changed +    $("input#id_is_update_email").change(function(e) { +        if ($(this).prop("checked")) { +            $("input#id_email").prop("disabled", false); +        } +        else { +            $("input#id_email").prop("disabled", true); +        } +    }); +}); + | 
