Hello,
I'm new in the Genesys World, i'm trying to make a simple customisation to the IWS when an interaction is received.
I want to open an webpage just at the moment when the interaction arrive to the agent but i d'ont know how to do it.
I already tried a lot of sample codes but nothing works.
Any one can help me please?
This is the code that i used
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Genesyslab.Desktop.Infrastructure;
using System.Windows;
using Genesyslab.Desktop.Infrastructure.Commands;
using Genesyslab.Desktop.Modules.Core.Model.Interactions;
using Genesyslab.Platform.Voice.Protocols.TServer.Events;
using Genesyslab.Platform.OpenMedia.Protocols.InteractionServer.Events;
using Genesyslab.Desktop.Infrastructure.ViewManager;
using Genesyslab.Desktop.Infrastructure.DependencyInjection;
using System.Diagnostics;
namespace Com.Learning.IW
{
public class CustomModule : IModule
{
ICommandManager commandManager;
IInteractionManager interactionManager;
IObjectContainer objectContainer;
IViewManager viewManager;
// IViewEventManager viewEventManager;
public CustomModule(ICommandManager commandManager,
IInteractionManager interactionManager,
IObjectContainer objectContainer,
IViewManager viewManager)
{
this.commandManager = commandManager;
this.interactionManager = interactionManager;
this.objectContainer = objectContainer;
this.viewManager = viewManager;
}
public void Initialize()
{
interactionManager.InteractionEvent += new EventHandler<EventArgs<IInteraction>>(interactionManager_InteractionEvent);
interactionManager.InteractionCreated += new EventHandler<EventArgs<IInteraction>>(interactionManager_InteractionCreated);
}
void interactionManager_InteractionCreated(object sender, EventArgs<IInteraction> e)
{
MessageBox.Show("Interaction Created: " + e.Value.InteractionId);
}
void interactionManager_InteractionEvent(object sender, EventArgs<IInteraction> e)
{
IInteraction interaction = e.Value;
switch (interaction.EntrepriseLastInteractionEvent.Name)
{
case EventInvite.MessageName:
Process.Start("https://www.google.com");
break;
case EventDialing.MessageName:
Process.Start("www.google.com");
break;
}
}
#endregion
}
}