(SM) Support Tip: Use fullname for smart email activities.

When opening interactions with SmartEmail, the activities are not saved with the operator's fullname even when the "Use Operator Full Name?" option is checked in the Service Desk Environment record.
This is because the global variable $lo.ufname is null by the time that the activity is recorded.
In order to workaroud this problem, follow these steps:
1. look for the script library SmartEmailUtil
2. look for the function with name: setOperator
3. Change the function
From:
function setOperator(operator) {
      //vars['$L.op'] = operator;
      //system.functions.parse_evaluate('operator()=$L.op', 11);
      lib.reportExport.setOpertor(operator);
}


To:
function setOperator(operator) {
      //vars['$L.op'] = operator;
      //system.functions.parse_evaluate('operator()=$L.op', 11);
      lib.reportExport.setOpertor(operator);
      
      if (operator!="Email Agent")
      {
              var opeRecord=lib.operatorUtil.getOperatorByName(operator);
              if (opeRecord!=null)
              {
                  vars.$lo_ufname=opeRecord.full_name;
              }
      }
}

This change in the Javascript will set the $lo.ufname variable with the operator's full name.

Tags: