• Paul Mackintosh 3
  • NEWBIE
  • 10 Points
  • Member since 2014

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 2
    Questions
  • 1
    Replies
The [Salesforce Console Integration Tookit][1] provides two functions for detecting switching focus of console tabs:

- `onFocusedPrimaryTab`
http://www.salesforce.com/us/developer/docs/api_console/Content/sforce_api_console_onfocusedprimarytab.htm
- `onFocusedSubtab` http://www.salesforce.com/us/developer/docs/api_console/Content/sforce_api_console_onfocusedsubtab.htm

I've been working on a Custom Visualforce Global Action and I'm able to use `onFocusedSubtab` without any issue to detect focus.  However `onFocusedPrimaryTab` does not work in the same way.  I have tested both functions using the samples from the documentation and I have no errors in Chrome dev tools that would indicate the callback is not being registered with `onFocusedPrimaryTab`.

The documentation does not indicate that they should behave differently, the only subtle hint that they may be different is that `onFocusedSubtab` is in the "Methods for Primary Tabs and Subtabs" section of the docs whilst `onFocusedPrimaryTab` is in the "Methods for Application-Level Custom Console Components" section.  For this reason I tried hooking up a callback in the console from a Custom Console Component in the highlights panel (top of Service Console), but it still didn't work.

Does anyone have any experience of `onFocusedPrimaryTab` working?

  [1]: http://www.salesforce.com/us/developer/docs/api_console/index.htm
In my Salesforce developer org, I have created an app Foo1 that uses the console and displays Accounts and Contacts.

I have created a Publisher Action called FooAction:

<?xml version="1.0" encoding="UTF-8"?>
<QuickAction xmlns="http://soap.sforce.com/2006/04/metadata">
    <height>250</height>
    <label>FooAction</label>
    <page>Foo</page>
    <type>VisualforcePage</type>
    <width>-100</width>
</QuickAction>

I have created a Visualforce page Foo:

<apex:page >
    Foo
</apex:page>

I have added the action as a quick action on both the Contact and Account layouts:

...
<quickActionList>
    <quickActionListItems>
        <quickActionName>FooAction</quickActionName>
    </quickActionListItems>
...

In both Firefox 30.0 and IE 11 when I open 2 or more Accounts into Salesforce console tabs, when I switch between the tabs the contents of the FooAction Publisher Action become empty when navigating back to the tab on which it was previously displayed.


In Firefox attempting to refresh the Publisher Action iframe has no effect.

In IE attempting to refresh the Publisher Action iframe produces this message:

Is there anything I can do about this?


In my Salesforce developer org, I have created an app Foo1 that uses the console and displays Accounts and Contacts.

I have created a Publisher Action called FooAction:

<?xml version="1.0" encoding="UTF-8"?>
<QuickAction xmlns="http://soap.sforce.com/2006/04/metadata">
    <height>250</height>
    <label>FooAction</label>
    <page>Foo</page>
    <type>VisualforcePage</type>
    <width>-100</width>
</QuickAction>

I have created a Visualforce page Foo:

<apex:page >
    Foo
</apex:page>

I have added the action as a quick action on both the Contact and Account layouts:

...
<quickActionList>
    <quickActionListItems>
        <quickActionName>FooAction</quickActionName>
    </quickActionListItems>
...

In both Firefox 30.0 and IE 11 when I open 2 or more Accounts into Salesforce console tabs, when I switch between the tabs the contents of the FooAction Publisher Action become empty when navigating back to the tab on which it was previously displayed.


In Firefox attempting to refresh the Publisher Action iframe has no effect.

In IE attempting to refresh the Publisher Action iframe produces this message:

Is there anything I can do about this?