3

At our company, we want to create 2 tabs for the same object and call them differently. The object in question we want to use is the Opportunity object.

By default, we want one of the tab to only display opportunities based on a certain criteria (let's say Open opportunities). The second tab only needs to list Closed opportunities.

Is it possible to do so, keeping in mind that we want to:

  • Have a different name for each tab;
  • Keep core filtering features included in Salesforce

I have a feeling it's not possible natively and it requires a bit of Visualforce, but just want to make sure before going in.

Thanks

3

In salesforce you can not make two tabs of a custom object.

Instead you can create a visualforce tab and use recordSetVar and other native approach to show filtered record in that tab.

Sample:

<apex:page standardController="Account" recordSetVar="accounts">
 <apex:dataList var="a" value="{!accounts}" type="1">
     {!a.name}
 </apex:dataList>
</apex:page>
  • I'm not quite sure how this could compare to a regular list view with filters, it only returns a list of names. We want to keep the filtering & ordering features. – jpmonette Mar 7 '14 at 17:49
1

This partially solved my issue:

<apex:enhancedlist type="Opportunity" height="730" customizable="false" rowsPerPage="25" Listid="[SOME-LIST-ID]" />
  1. Create a Visualforce Page
  2. Add an apex:enhancedList for the object you want
  3. Create a list filter and put the listId
  4. Create a tab + display the Visualforce page
  • I am already having an existing tab. How can I create a tab on VF Page rather than Object? – Testing_SFDC Oct 5 '15 at 7:23
  • @SFDC_Learner You can use any object for which you don't need a tab and override that object's tab with your above vf page to solve the purpose. – Testing_SFDC Oct 5 '15 at 9:07
0

You can accomplish this without visualforce by using list views, web tabs, and the isdtp url parameter.

1) Create a list view, and copy the url of said list view.

2) Create a web tab, and set the url to be the url of the list view. You'll probably want to append &isdtp=vw to the url, so you don't double up on the standard salesforce header and sidebar.

  • This success.salesforce.com/ideaView?id=08730000000KeoeAAC includes some comments about this parameter working/not working in various versions. In your experience has it stayed working? (Personally I think SF's unwillingness to accept that URL parameters are part of their API pretty frustrating when typically there is no other reasonable way to accomplish something.) – Keith C Mar 6 '14 at 20:03
0

The closest thing to your requirements only uses a single tab. You can create a 'View' though to display. In your Opportunity tab, you can click 'Create New View'. You can create 2 views here. One for all Open Opportunities, and one for all Closed. It would give you pretty much the exact same thing you want besides the separate tab.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.