CC-4793: System -> User: Sometimes the user type's tips turns out "undefined"

-fixed
This commit is contained in:
denise 2013-01-11 15:12:41 -05:00
parent 1c0d8abd4c
commit 224bcf0c2b
1 changed files with 6 additions and 3 deletions

View File

@ -99,9 +99,7 @@ function sizeFormElements() {
$("dd[id$='element']").addClass('user-form-element');
}
$(document).ready(function() {
populateUserTable();
function assignUserRightsToUserTypes() {
//assign user-rights and id to each user type option so we can
//display user rights for each with tipsy tooltip
$.each($('#type').children(), function(i, opt) {
@ -159,6 +157,10 @@ $(document).ready(function() {
break;
}
});
}
$(document).ready(function() {
populateUserTable();
assignUserRightsToUserTypes();
$('#type').live("change", function(){
//when the title changes on live tipsy tooltips the changes take
@ -192,6 +194,7 @@ $(document).ready(function() {
if (json.valid === "true") {
$('#content').empty().append(json.html);
populateUserTable();
assignUserRightsToUserTypes();
} else {
//if form is invalid we only need to redraw the form
$('#user_form').empty().append($(json.html).find('#user_form').children());