You need to sign in to do that
Don't have an account?

Hide Task section on leadconvert.jsp
Is it possible to hide the 'Task' section altogether on LeadConvert.jsp page? I guess building a VisualForce page is the answer, but I would really appreciate if somebody could point me to sample code that does something similar. I want to retain most of the functionality on that page and just customize the layout a bit.
Thanks much!
I just did this - it's not too bad.
The stock lead convert page is one of those little "hidden gems" that you can't control anything inside of. You have to roll your own VF page - remove the stock "Convert" button and replace it with a Custom Button that calls this VF page:
and the controller...
Hopefully that helps!
-Andy
All Answers
I just did this - it's not too bad.
The stock lead convert page is one of those little "hidden gems" that you can't control anything inside of. You have to roll your own VF page - remove the stock "Convert" button and replace it with a Custom Button that calls this VF page:
and the controller...
Hopefully that helps!
-Andy
Awesome! Thank you, Andy! I will need to play with this now and expand on it for my needs. Really appreciate your help!
So big THANK YOU!
:smileyvery-happy:
That is awesome!! THANKS A LOT!!!
Hello Sbb,
If you Know much more about this (or) you have any new ideas about this share with us ,I tried to create new lead conversion process it working good anyhow at some point it shows error as in the below line,here master label means lead status it automatically fetches the lead status but in my case we have lot lead process when i run this it fetches the value but we are not using this value in lead status in some record types there it shows an error, If you have any idea about this kindely share with us it helps a lot.
Can one of you help me with test class for this custom code.
I have been trying to increase test coverage but lost.
here is my test code.
@IsTest
private class TestXXCSRLeadConvertClass{
static testMethod void TestXXCSRLeadConvertClass() {
test.startTest();
Boolean bolCreateOpp;
String strAccountId;
String strContactId;
Lead l = new Lead();
l.FirstName = 'CRM Testing First';
l.LastName = 'CRM Testing Last';
l.Company = 'CRM Testing INCtest';
l.description = 'Test descr';
l.city = 'test';
l.street = 'test';
l.state = 'CA';
l.country = 'United States';
l.status = 'Qualified';
l.email = 'test@testnetgear.com';
l.website = 'www.testcrm.com';
l.ApprovalStatus__c='Approved';
// l.RecordTypeId='012110000004b9Q';
insert l;
Id leadId = l.Id;
bolCreateOpp = false;
//Create a reference to the VF page
PageReference pageRef = Page.XXCSR_LEAD_CONVERT;
Test.setCurrentPageReference(pageRef);
//Create an instance of the controller extension and call the autoRun method.
//autoRun must be called explicitly even though it is "autoRun".
ApexPages.StandardController sc = new ApexPages.standardController(l);
XXCSRLeadConvertClass leadconvt = new XXCSRLeadConvertClass(sc);
leadconvt.autoRun();
//String nextPage = sc.save().getUrl();
List<SelectOption> testacct = new List<SelectOption>();
testacct = leadconvt.getlstCompanyInfo();
system.debug(testacct);
List<SelectOption> testcon = new List<SelectOption>();
testcon = leadconvt.getlstContactInfo();
system.debug(testcon);
leadconvt.doNothing();
//Retrieve the converted Lead info and the opps and roles.
l = [select Id, IsConverted, ConvertedAccountId, ConvertedContactId ,Status, ApprovalStatus__c,
Company,OwnerId,firstname,lastname,city,country from Lead where Id = :leadId];
system.assert(!l.IsConverted,'Lead Converted' );
test.stopTest();
}
}
Thanks
Pallavi