Append User Name on My CRM Menu Option in Sage CRM

By | July 29, 2017

Sage CRM has always been helpful to manage and maintain Customer relationship data with an ease. It has always been easy to accommodate various customizations with different programming libraries such as jQuery, Javascript or say Client side API. Earlier, we had explained how you can append Logged in user name to Custom tabs. You can refer below blog link.
Related Post: Display Current User Name under Custom Tab using jQuery

In this blog, I will explain how you can append User name to My CRM Menu options using jQuery. Below is the screen shot of the My CRM’s options. Here, I have one custom tab named as Subscriptions added to the list. To append the Username to this option, below are the steps to follow.

1.    Create a JavaScript page (e.g.Changes.js) with below jQuery Code and Copy it under “<installation path>”\WWWRoot\js\custom” folder.
crm.ready(function()
{
var User_Logon = new String(CurrentUser.user_logon);
//For Get User Name
if(User_Logon==”” || User_Logon==”undefined” ||User_Logon==null)
{
User_Logon=CurrentUser.user_logon;
if(User_Logon==”” || User_Logon==”undefined” ||User_Logon==null)User_Logon=””;
}
TabName=User_Logon+” Subscriptions”;
//For overwrite name
if($(‘#sub-menu-Subscriptions’))
$(‘#sub-menu-Subscriptions’).text(TabName);
});
2.   Once done, execute metadata refresh and check.

Also Read:
1.    How to Add or Remove tabs from My CRM
2.    Hide options for specific users from Menu bar
3.    Displaying Popup window in Sage CRM 7.2 Using Client side API
4.    Linked selection fields through client side scripting
5.    New way of Client side field customizations