• sfdcbusted
  • NEWBIE
  • 10 Points
  • Member since 2012

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 3
    Questions
  • 4
    Replies

Hi,

Does salesforce1 support the new Country and State picklist for standard objects?
We had implemented Country and State picklist on our instance and when I tried to create an Account record on Salesforce1 the Country and State picklist has no dependency and is a text input field.

 User-added image

Regards,
Sean

Hi

Quite having a problem enabling custom buttons using visualforce page on Salesforce1.

So here’s the situation, we currently have converted an onClick javascript Clone button to a visualforce page and it is working as expected on our salesforce full site, but when it comes to the Salesforce1 app were having a problem with the behaviour of the custom button. 

1. Does URL redirections work the same for salesforce1? I mean the URL hacks that we can do for the salesforce full site just like the one on the controller below which is the URL hack for cloning records and passing additional parameters to pre-populate record details upon cloning a record.

return new PageReference('/'+ camp.Id + '/e?clone=1&00NC0000005Ijnf=Clone&00NC0000005Ijne='+ camp.Id + '&00NC0000005CNRZ=1');

2. Is there other way of customizing the clone button on salesforce1 other than overriding it with visualforce page? Already tried using URL link buttons didn’t work either.

Here's the code:

VF Page:
<!-- PSDS 1/27/2014 -D-3063 - SF1 Enhancement - convert campaign clone javascript to visualforce page to enable it on Salesforce1 App -->
<apex:page standardController="Campaign" extensions="CampaignCloneController" action="{!init}">
    <apex:form >
        <apex:actionFunction action="{!redirect}" name="redirect"/>
        <apex:actionFunction action="{!cancel}" name="cancel"/>
    </apex:form>
   
    <script>
       
        var allowed = {!allowed};
        <!-- Validate if user is allowed to clone campaign -->
        function validate() {
            if(allowed == false) {
                alert('Only Email campaigns with "Test" in the campaign name can be cloned');
                cancel();
            }
        }
       
        validate();
    </script>
</apex:page>

Controller:
public class CampaignCloneController {

    public string campaignID {get; set;}
    public Campaign camp {get; set;}
    static string profileName;
    public boolean allowed{get;set;}
   
    /*
    @description: User using the clone button
    */
    static{
        profileName = [SELECT Name FROM Profile WHERE Id =: UserInfo.getProfileID()].Name;
    }
   
    /*
    @description: Verifies if the user is allowed to use the clone button
    */
    public CampaignCloneController(ApexPages.StandardController controller) {
        camp = [SELECT Id, RecordType.Name, Name FROM Campaign WHERE Id =: controller.getID()];     
       
        if((profileName.toUpperCase().contains('STANDARD') && !camp.RecordType.Name.toUpperCase().contains('EMAIL'))
            ||(profileName.toUpperCase().contains('STANDARD')
            && camp.RecordType.Name.toUpperCase().contains('EMAIL')
            && !camp.Name.toUpperCase().contains('TEST'))) {
            allowed = false;
        } else {
            allowed = true;
        }
    }
   
   
    public PageReference init() {
        if(allowed == true) {
            return redirect();
        } else {
            return null;
        }
    }
   
    /*
    @description redirects page to clone page
    */
    public PageReference redirect(){
        return new PageReference('/'+ camp.Id + '/e?clone=1&00NC0000005Ijnf=Clone&00NC0000005Ijne='+ camp.Id + '&00NC0000005CNRZ=1');
    }
  
    public PageReference cancel(){
        return new PageReference('/' + camp.Id);
    }

}

Hi,

 

We're having issue on our instance, we were not able to receive e-mail alerts from workflows. I've already checked the debug logs for this and it seems to be working because there were no errors shown on the logs.

 

//DEBUG LOGS
22:26:33.161 (161157000)|WF_RULE_INVOCATION|[Request Log: D-2930 a1aL00000001aNl]
22:26:33.161 (161168000)|WF_EMAIL_ALERT|Id=01WC0000000PZ00|CurrentRule:RL: New Request Created (Id=01QC0000000R5Y4)
22:26:33.235 (235116000)|WF_EMAIL_SENT|Template:00XC0000001XDOf|Recipients:phillip.s.d.soriano@accenture.com |CcEmails:
22:26:33.235 (235155000)|WF_ACTION| Email Alert: 4;
22:26:33.235 (235173000)|WF_RULE_EVAL_BEGIN|Escalation
22:26:33.235 (235182000)|WF_RULE_EVAL_END
22:26:33.237 (237463000)|WF_ACTIONS_END| Email Alert: 4;
//

 

I have also requested for the E-mail Logs to check if the mails were being delivered and there seems to be no problem because the status on the E-mail is D: which means delivered, but still I haven't received any E-mail alerts yet:

 

////E-mail LOGS

Date Time: 5/24/2013 5:57
Internal Message ID: BD/FB-08984-8510F915
Mail Event: D
Recipient: phillip.s.d.soriano@accenture.com
Sender: phillip.s.d.soriano=accenture.com__af0tkzccahqtot0w@5bnyv6y9o5m5.l-2qavima0.l.bnc.sandbox.salesforce.com
Remote Host: 10.226.39.3
Bytes Transferred: 1902
Salesforce.com User: 005C0000003WqB5
Message ID Header:
Retry Count: 0
Seconds In Queue: 0.735761
Delivery Stage:
Relay Address:

////

 

I already checked my Spam/Junk E-mails but the E-mail alert mails are no where to be found. I also tried to test the E-mail Deliverability, Setup>E-mail Administration>Test Deliverability. I also wasn't able to received any e-mails after testing it. I'm sure I was using a valid e-mail address, but why am I not receiving e-mail alerts?

 

Please advise. Thanks!

 

 

 

Hi

Quite having a problem enabling custom buttons using visualforce page on Salesforce1.

So here’s the situation, we currently have converted an onClick javascript Clone button to a visualforce page and it is working as expected on our salesforce full site, but when it comes to the Salesforce1 app were having a problem with the behaviour of the custom button. 

1. Does URL redirections work the same for salesforce1? I mean the URL hacks that we can do for the salesforce full site just like the one on the controller below which is the URL hack for cloning records and passing additional parameters to pre-populate record details upon cloning a record.

return new PageReference('/'+ camp.Id + '/e?clone=1&00NC0000005Ijnf=Clone&00NC0000005Ijne='+ camp.Id + '&00NC0000005CNRZ=1');

2. Is there other way of customizing the clone button on salesforce1 other than overriding it with visualforce page? Already tried using URL link buttons didn’t work either.

Here's the code:

VF Page:
<!-- PSDS 1/27/2014 -D-3063 - SF1 Enhancement - convert campaign clone javascript to visualforce page to enable it on Salesforce1 App -->
<apex:page standardController="Campaign" extensions="CampaignCloneController" action="{!init}">
    <apex:form >
        <apex:actionFunction action="{!redirect}" name="redirect"/>
        <apex:actionFunction action="{!cancel}" name="cancel"/>
    </apex:form>
   
    <script>
       
        var allowed = {!allowed};
        <!-- Validate if user is allowed to clone campaign -->
        function validate() {
            if(allowed == false) {
                alert('Only Email campaigns with "Test" in the campaign name can be cloned');
                cancel();
            }
        }
       
        validate();
    </script>
</apex:page>

Controller:
public class CampaignCloneController {

    public string campaignID {get; set;}
    public Campaign camp {get; set;}
    static string profileName;
    public boolean allowed{get;set;}
   
    /*
    @description: User using the clone button
    */
    static{
        profileName = [SELECT Name FROM Profile WHERE Id =: UserInfo.getProfileID()].Name;
    }
   
    /*
    @description: Verifies if the user is allowed to use the clone button
    */
    public CampaignCloneController(ApexPages.StandardController controller) {
        camp = [SELECT Id, RecordType.Name, Name FROM Campaign WHERE Id =: controller.getID()];     
       
        if((profileName.toUpperCase().contains('STANDARD') && !camp.RecordType.Name.toUpperCase().contains('EMAIL'))
            ||(profileName.toUpperCase().contains('STANDARD')
            && camp.RecordType.Name.toUpperCase().contains('EMAIL')
            && !camp.Name.toUpperCase().contains('TEST'))) {
            allowed = false;
        } else {
            allowed = true;
        }
    }
   
   
    public PageReference init() {
        if(allowed == true) {
            return redirect();
        } else {
            return null;
        }
    }
   
    /*
    @description redirects page to clone page
    */
    public PageReference redirect(){
        return new PageReference('/'+ camp.Id + '/e?clone=1&00NC0000005Ijnf=Clone&00NC0000005Ijne='+ camp.Id + '&00NC0000005CNRZ=1');
    }
  
    public PageReference cancel(){
        return new PageReference('/' + camp.Id);
    }

}

 

Removing of null to set gives an error "System.NullPointerException:Argument 1 cannot be null"

 

Ex.

 

acctid.remove(null); <------ This will give error in winter 13 but not in summer 12

 

Please help me to understand what is wrong i maybe missing something here. Thanks

Hi,

 

When im deploying one premission set with one custom app premission it is not deploying throwing error as :

 


# Deploy Results:
   File Name:    permissionsets/SSR_Holdings_Permission_Set.permissionset
   Full Name:  SSR_Holdings_Permission_Set
   Action:  NO ACTION
   Result:  FAILED
   Problem: Unknown user permission: AllowDeleteDandBCompany

 

Plz Advice