Srini, Salesforce console is totally based on Iframes, so it takes time to refresh everything, when you saved the case, wait to sometime it will get refreshed, side bar or anything sidebar that you have added associated with the detail page record.One suggestion, go to the layout of the Case and add that knowledgebar and Highlights panel on the detail layouts of the case sidebare, so that any case if you'll open you'll have knowledgebar and Highlights already their related to it. At that time on when you'll cancel the case it will close that particular primary tab.And when you edit and save it then also they will get refreshed with the time Case is updated.About opening a sub tab on click of a button, salesforce have some method to open primary tab, Sub tab etc like below
Abhi<apex:page standardController="Case">
<A HREF="⌗" onClick="testOpenSubtab();return false">
Click here to open a new subtab</A>
<apex:includeScript value="/support/console/22.0/integration.js"/>
<script type="text/javascript">
function testOpenSubtab() {
//First find the ID of the primary tab to put the new subtab in
sforce.console.getEnclosingPrimaryTabId(openSubtab);
}
var openSubtab = function openSubtab(result) {
//Now that we have the primary tab ID, we can open a new subtab in it
var primaryTabId = result.id;
sforce.console.openSubtab(primaryTabId , 'http://www.salesforce.com', false,
'salesforce', null, openSuccess, 'salesforceSubtab');
};
var openSuccess = function openSuccess(result) {
//Report whether we succeeded in opening the subtab
if (result.success == true) {
alert('subtab successfully opened');
} else {
alert('subtab cannot be opened');
}
};
</script>
</apex:page>
1 réponse