" /> GAD get phone number from the campaign!?! - Genesys CTI User Forum

Author Topic: GAD get phone number from the campaign!?!  (Read 4432 times)

Offline tv4702

  • Newbie
  • *
  • Posts: 4
  • Karma: 0
GAD get phone number from the campaign!?!
« on: December 26, 2010, 12:53:14 PM »
Advertisement
Hi everyone

I'm just a rookie for GAD. So right now I got a problem that I can't fix it out.
If anyone can guild me how to do, please tell me.

My problem is I don't know how to get phone number from outbound-campaign.
My tab that I have created is work just for Inbound case because I can use ContactID
but it doesn't work for Outbound

The step that I want is when agent has click a campaign.
GAD will be show the number for calling
and my tab must show information of the person who the agent gonna talk with.

my code <custom.xml>
======================================
<gcn-resources>
    <desktop>
        <dictionary-class>custom</dictionary-class>
        <customer-records>
            <javascript-onload>
                <![CDATA[
                    selectTabByName("Information");
                ]]>
            </javascript-onload>
            <tabs>
                <tab name="Information">
                    <scrollbar>true</scrollbar>
                    <dictionary-key>Information</dictionary-key>
                    <javascript-onselect>
                        <![CDATA[
                            document.forms.InformationForm.target = getDetailFrameName();
                            document.forms.InformationForm.elements.idInteraction.value = idInteraction;
                            document.forms.InformationForm.elements.idContact.value = idContact;
                            document.forms.InformationForm.submit();
                        ]]>
                    </javascript-onselect>
                    <html-body>
                        <![CDATA[
                            <form name="InformationForm" action="custom\Information.jsp">
                                <input type="hidden" name="idInteraction">
                                <input type="hidden" name="idContact">
                            </form>
                        ]]>
                    </html-body>
                </tab>
            </tabs>
        </customer-records>
    </desktop>
</gcn-resources>
======================================

my code <information.jsp>
======================================
<%@ page language="java" buffer="none" contentType="text/html; charset=utf-8" %>
<%@ page import="com.genesyslab.ail.AilFactory" %>
<%@ page import="com.genesyslab.ail.AilLoader" %>
<%@ page import="com.genesyslab.ail.Contact" %>
<%@ page import="com.genesyslab.ail.ContactAttributeMetaData" %>
<%@ page import="com.genesyslab.ail.ContactAttributeValue" %>
<%@ page import="com.genesyslab.ail.ContactManager" %>
<%@ page import="com.genesyslab.ail.Interaction" %>
<%@ page import="com.genesyslab.ail.exception.RequestFailedException" %>
<%@ page import="java.util.Collection" %>
<%@ page import="java.util.Iterator" %>
<%
    // Get data from request
    String idContact = (String)request.getParameter("idContact");

    // Initialize AIL related data
    AilFactory factory = AilLoader.getAilFactory();
    com.genesyslab.ail.Interaction interaction = factory.getInteraction( (String)request.getParameter( "idInteraction" ) );
    ContactManager contactManager = factory.getContactManager();
    Contact contact = null;
    if ( (idContact != null) && (!idContact.equals("")) && (!idContact.equals("null")) )
        contact = factory.getContactManager().getContact(idContact, null);
%>
<html>
    <head>
      <title>Information</title>
      <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
      <link rel="stylesheet" type="text/css" href="style.css"/>
    </head>
    <body class="fontName scrollBar backgroundRoundedPanel" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<%
    if(contact == null) {
%>
    <br><br><center class="labelText">Contact Information Not Available</center>
<%
    } else {
%>
    <iframe name="iframe1" src="http://192.168.1.109/OFMTest/Calling.aspx?num=<%=contact.getPrimaryPhoneNumber()%>&user=<%=interaction.getUserName()%>" width="100%" height="100%" frameborder="1" scrolling="yes"  >
        Your browser does not support inline frames or is currently configured not to display inline frames.
</iframe>
<%
        }
%>
  </body>
</html>
======================================

Please help or ask me more if you need more information.

Offline René

  • Administrator
  • Hero Member
  • *****
  • Posts: 1832
  • Karma: 62
Re: GAD get phone number from the campaign!?!
« Reply #1 on: December 28, 2010, 02:53:58 PM »
Hi,

Handling outbound interaction is more complex than inbound ones. Please look for OutboundService and OutboundChain interfaces in AIL documentation for more details.

Let me know if you need more help.

R.

Offline tv4702

  • Newbie
  • *
  • Posts: 4
  • Karma: 0
Re: GAD get phone number from the campaign!?!
« Reply #2 on: December 29, 2010, 08:50:15 AM »
[quote author=René link=topic=6078.msg26413#msg26413 date=1293548038]
Hi,

Handling outbound interaction is more complex than inbound ones. Please look for OutboundService and OutboundChain interfaces in AIL documentation for more details.

Let me know if you need more help.

R.
[/quote]

Thanks René.

I've got what I want already.

But now I have a new problem that is my web on that tab can't show in Firefox but it's work on IE.
I don't understand why because I copied the URL and paste to Firefox directly then it's work.

Would you please tell me why and how to fix it? Pls.

Offline René

  • Administrator
  • Hero Member
  • *****
  • Posts: 1832
  • Karma: 62
Re: GAD get phone number from the campaign!?!
« Reply #3 on: December 29, 2010, 11:43:26 AM »
Hi,

It's hard to help you as I haven't seen your web. Try to use Firebug and check generated HTML code...

R.

Offline tv4702

  • Newbie
  • *
  • Posts: 4
  • Karma: 0
Re: GAD get phone number from the campaign!?!
« Reply #4 on: January 05, 2011, 06:04:44 AM »
Such a shame on me. I got it coz I really don't know when using iFrame, I have to call the full path for the parent page.
So now everything's perfect, right now. IE and Firefox have shown what I want.
Thanks, René.