Page 1 of 1

Email User Account Info DOES NOT DISPLAY USERNAME?

Posted: Mon Oct 15, 2018 11:52 am
by TBT
When an account is created in Fusion 4.1.5 with the "Email User Account Information" option checked, no username is passed along in the email received, it simply displays "Username: none".

This passed Nagios internal QA testing, so lets assume it was by design. In that case, what is the purpose of not displaying the UID? Furthermore, if this is not intentional, can we get a fix ASAP?

Re: Email User Account Info DOES NOT DISPLAY USERNAME?

Posted: Mon Oct 15, 2018 12:17 pm
by lmiltchev
This is definitely not "by design". I filed an internal bug report (task_id=13680), and our developers will be looking into it as soon as they can. Thank you!

Re: Email User Account Info DOES NOT DISPLAY USERNAME?

Posted: Mon Oct 15, 2018 12:43 pm
by lmiltchev
Update:
Here's a fix for you. Open vi /usr/local/nagiosfusion/html/admin/users.php in a text editor, and change lines 379 to 385 to look like this:

Code: Select all

foreach ($user_mapping as $server_id => $server_username) {
                if ($server_username == 'none') {
                    delete_current_mapped_user($server_id, $user_id);
                } else {
                    set_current_mapped_user($server_id, $server_username, $user_id);
                }
            }
Note: You will be replacing $username with $server_username.

Let us know if this helped.

Re: Email User Account Info DOES NOT DISPLAY USERNAME?

Posted: Mon Oct 15, 2018 1:16 pm
by TBT
Issue resolved by changing three (3) occurrences of $username to $server_username.

Please send my "Nagios bug hunter of the month" trophy in the mail. ;)

Thanks again,

Re: Email User Account Info DOES NOT DISPLAY USERNAME?

Posted: Mon Oct 15, 2018 1:53 pm
by lmiltchev
Please send my "Nagios bug hunter of the month" trophy in the mail. ;)
LOL
Let us know if you have any more questions.