Name

sn_sow_interaction.SOWContextualPanelInteractionVisibility

Description

Implements extension point sn_sow_collab.SOWContextualPanelVisibility for Interaction of type other than walkup

Script

var SOWContextualPanelInteractionVisibility = Class.create();
SOWContextualPanelInteractionVisibility.prototype = {

  canLaunchChat: function(recordSysId, table) {
      if (table == 'interaction' && new sn_sow_collab.SOWSidebarChatUtils().isSidebarSupportedOnSOW())
          return true;

      if (GlidePluginManager.isActive('com.snc.ms_teams.it') && table == 'interaction') {
          var type = '';
          var intGr = new GlideRecord('interaction');
          if (intGr.get(recordSysId)) {
              type = intGr.getValue('type');
              return type != "walkup" && new sn_tcm_collab_hook.MSTeamsChatUtil().canLaunchChat(intGr, 'interaction_agent');
          }
      }
  },

  type: 'SOWContextualPanelInteractionVisibility'
};

Sys ID

49df759c872d1d1094470e16dabb35f7

Offical Documentation

Official Docs: