Skip to content

Commit

Permalink
Resolving Issue #214
Browse files Browse the repository at this point in the history
  • Loading branch information
cigamit committed Jan 18, 2017
1 parent d91be3e commit aa21265
Showing 1 changed file with 31 additions and 0 deletions.
31 changes: 31 additions & 0 deletions user_admin.php
Original file line number Diff line number Diff line change
Expand Up @@ -1899,6 +1899,8 @@ function checkPasswordConfirm() {
}
}

var password_change = $('#password_change').is(':checked');

$(function() {
changeRealm();

Expand All @@ -1917,6 +1919,35 @@ function checkPasswordConfirm() {
$('#realm').change(function() {
changeRealm();
});

$('#password_change').click(function() {
password_change = $('#password_change').is(':checked');

if (!password_change && $('#must_change_password').is(':checked')) {
if (typeof $('#must_change_password').button === 'function') {
$('#must_change_password').prop('checked', false).button('refresh');
}else{
$('#must_change_password').prop('checked', false);
}
}
});

$('#must_change_password').click(function() {
if ($(this).is(':checked')) {
if (typeof $('#must_change_password').button === 'function') {
$('#password_change').prop('checked', true);
$('#password_change').button('refresh');
}else{
$('#password_change').prop('checked', true);
}
}else{
if (typeof $('#must_change_password').button === 'function') {
$('#password_change').prop('checked', password_change).button('refresh');
}else{
$('#password_change').prop('checked', password_change);
}
}
});
});

</script>
Expand Down

0 comments on commit aa21265

Please sign in to comment.