You need to sign in to do that
Don't have an account?
Thejasvi A
Navigation in Salesforce1
Hi,
I am working on salesforce1 app. I have created the following things in dev org:
1. Tabs for VF pages
2. Enabled Available for Salesforce mobile apps
3. Added VF pages in Mobile card section of page-layout
But I am unable to navigate the pages in Saleforce1.
When I click on a button that redirects to other page, the URL automatically takes " isdtp=p1 " and the page is invisible.
Are there any additional configurations that are to be done??
Please help me out at the earliest.
Thank you.
I am working on salesforce1 app. I have created the following things in dev org:
1. Tabs for VF pages
2. Enabled Available for Salesforce mobile apps
3. Added VF pages in Mobile card section of page-layout
But I am unable to navigate the pages in Saleforce1.
When I click on a button that redirects to other page, the URL automatically takes " isdtp=p1 " and the page is invisible.
Are there any additional configurations that are to be done??
Please help me out at the earliest.
Thank you.
Salesfrce1 support their own methods to navigate. I am assuming you are using following methods ?
Thanks,
Himanshu
Salesforce Certified Developer | Administrator | Service Cloud Consultant
P.S. If my answer helps you to solve your problem please mark it as best answer. It will help other to find best answer.
If my answer helps resolve your query, please mark it as the 'Best Answer' & upvote it to benefit others and improve the overall quality of Discussion Forums.
Gaurav Kheterpal
Certified Force.com Developer| Salesforce Mobile Evangelist| Developer Forums Moderator| Dreamforce Speaker
VF page:
<apex:page standardController="Lead" tabStyle="Lead" id="pageId" extensions="LeadPageController" showHeader="false" sidebar="false">
<apex:form id="fm">
<div align="center" ><img src="{!$Resource.OtherPages}" border="5" class="bg" /></div>
<apex:messages />
<table >
<br/>
<tr><td width="20%"><b style="color:black"> First Name :</b></td><td width="30%"><apex:inputText value="{!Lead.FirstName}" /></td></tr>
<tr> <td width="20%"><b style="color:black"> Last Name :</b></td><td width="30%"><apex:inputText value="{!Lead.LastName}" /></td></tr>
<tr> <td width="20%"><b style="color:black"> Phone :</b></td><td width="30%"><apex:inputText value="{!Lead.Phone}" /></td> </tr>
<tr> <td width="20%"><b style="color:black"> company :</b></td><td width="30%"><apex:inputText value="{!Lead.Company}" /></td></tr>
<tr> <td width="20%"><b style="color:black"> Personal Email :</b></td><td width="30%"><apex:inputText value="{!Lead.Email}" /></td></tr>
<tr>
<td><apex:commandbutton value="Save & Next" action="{!saveNext}" /> </td>
<td><apex:commandbutton value="Cancel" action="{!Cancel}" </td>
</tr>
</table>
</apex:form>
Controller:
public class LeadPageController {
Public Lead leaddata ;
private ApexPages.StandardController controller;
Public boolean ShowhomePage {get;set;}
public LeadPageController(ApexPages.StandardController controller) {
showHomePage = False;
this.controller = controller;
leaddata = (Lead)controller.getRecord();
}
public pageReference saveNext()
{
insert leaddata;
system.debug('************LEADDATA********'+Leaddata.id);
string lid1 = leaddata.Id;
PageReference redirect = new PageReference('http://autoinsurance-developer-edition.na15.force.com/VehiclePage?lid='+lid1+'&email='+Leaddata.Email);
system.debug('etretetest'+Leaddata.Email);
redirect.setRedirect(true);
return redirect;
}
public pageReference Cancel()
{
PageReference redirect = new PageReference('http://autoinsurance-developer-edition.na15.force.com/HomePage');
showHomePage = True;
redirect.setRedirect(true);
return redirect;
}
The details in this particular page gets saved and on redirection to the next page, its takes "isdtp=p1" at the end of the URL and the next page details are not considered.
Thank You!
As far as I know Salesforce1 does'nt suppport controller side redirection. You need to return true or false from controller side using action function and oncomplete event you can navigate using the sforce.one.navigateToURL function
Thanks,
Himanshu
Salesforce Certified Developer | Administrator | Service Cloud Consultant
P.S. If my answer helps you to solve your problem please mark it as best answer. It will help other to find best answer.