• Terri T Jiles
  • NEWBIE
  • 110 Points
  • Member since 2016

  • Chatter
    Feed
  • 3
    Best Answers
  • 1
    Likes Received
  • 1
    Likes Given
  • 2
    Questions
  • 30
    Replies
Hello, I am looking to integrate webservice callouts with Visual Workflow, can you please suggest the approach if anyone tried.
I have a SalesForce account in my organization’s sandbox that has system administrator privileges.  When I log into the web UI with porter_horne@wycliffe.org.staging and my password, then I see my login history.  I generated a security token that was delivered successfully to my email account.

I am now trying to create a CozyRoc SalesForce connector, but when I append the security token to my password and test the connection, I get the INVALID_LOGIN error

Is there a way for me to generate a log file that would show me what to change?

Why does the login failure not show in my login history?
 
 
I am looking to update a lookup field on the opportunity after a lead has been converted. Not sure if this is possible so I was first wondering if we could even do this. I currently have mapped the fields with a formula so that the lead ID shows on the opportunity but after the lead is converted the lookup will not allow me to select a converted lead. 

Does anyone have any suggestions to try and get me on the right track? 
Hi All,

I get the following error when attempting to check in this challenge.  However, if I test my code from workbench, it works correctly.  I've checked my spelling, order of parameters in the method signature.

Challenge Not yet complete... here's what's wrong: 
The 'ProjectRESTService' Apex REST service does not appear to be working properly. Calling the service either didn't update the opportunity correctly, return the string 'OK', create an associated project correctly or function correctly in general.

I've checked other forum post and I noticed people are searching for the project record prior to upserting it.  I don't understand why that is needed if I can upsert directly against the ProjectRef__c external id field.  I could try to copy and paste what they did to pass the challenge, but I want to understand why what I coded doesn't work.  A second pair (or more) eyes would be appreciated.  Thank you!
 
@RestResource(urlMapping='/project/*')
global with sharing class ProjectRESTService {
    @HttpPost
    global static String postProjectData(String ProjectRef, String ProjectName, String OpportunityId, Date StartDate, Date EndDate, Double Amount, String Status) {
		SavePoint sp = Database.setSavepoint();
        
        try {
	        Project__c p = new Project__c(ProjectRef__c=ProjectRef, Name=ProjectName, Opportunity__c=OpportunityId, Start_Date__c=StartDate, End_Date__c=EndDate, Billable_Amount__c=Amount, Status__c=Status);
    	    upsert p ProjectRef__c;
            Opportunity o = new Opportunity(Id=OpportunityId, DeliveryInstallationStatus__c='In Progress');
            update o;
        	return 'OK';
        } catch (Exception e) {
            System.debug('~~~ Cause: ' + e.getCause() +  ' Message: ' + e.getMessage() + ' getLineNumber: ' + e.getLineNumber() + ' StackTrace: ' + e.getStackTraceString() + ' Type: ' + e.getTypeName());
            Database.rollback(sp);
            return e.getMessage();
        }     
    }
        
}

 
Hi All,

I receive the following error when attempting to check the challenge for Apply Unit of Work

Challenge Not yet complete... here's what's wrong: 
The 'challangeComplete' method in the 'UnitOfWorkTest' class has not successfully passed all tests. Ensure that you run the tests and it passes successfully before attempting this challenge again.

However, when I run my code in Developer Console, my test passes.  Any ideas on the problem?  Here is the code:

@isTest
public class UnitOfWorkTest {
    @isTest static void challengeComplete(){
        fflib_SObjectUnitOfWork uow = new fflib_SObjectUnitOfWork(
            new Schema.SObjectType[]{
                Account.SObjectType,
                Contact.SObjectType,
                Note.SObjectType
            }
        );
        
        for (Integer i=0 ; i<100 ; i++) {
            Account a = new Account(Name= 'Test' + i);
            uow.registerNew(a);
            
            for (Integer j=0 ; j<5 ; j++) {
                Contact c = new Contact(LastName = 'Test'+i + ' ' +j);
                uow.registerNew(c, Contact.AccountId, a);
                
                Note n = new Note(Body='Test '+i + '' + j, Title='Test'+i+j);
                uow.registerRelationship(n, Note.ParentId, a);
                uow.registerNew(n, Note.ParentId, a);
            }
        }

        uow.commitWork();
 
        fflib_SObjectUnitOfWork uow2 = new fflib_SObjectUnitOfWork(
            new Schema.SObjectType[]{
                Account.SObjectType,
                Contact.SObjectType,
                Note.SObjectType
            }
        );        
        for (Account a : [SELECT Id, Name, (SELECT Id, LastName FROM Contacts), (SELECT Id, ParentId, Title, Body FROM Notes) FROM Account]) {
            a.Name = 'Test';
            uow2.registerDirty(a);
            
            Integer i = 0;
            for (Contact c : a.Contacts) {
                c.LastName = 'Test';
                uow2.registerDirty(c);
                
                a.Notes[i].Body='Test';
                uow2.registerDirty(a.Notes[i]);
                i++;
            }
        }        
        
        test.startTest();
        uow2.commitWork();
        test.stopTest();
        
        System.assertEquals(100, [Select Id from Account].size());
        System.assertEquals(500, [Select Id from Contact].size());
        System.assertEquals(500, [Select Id from Note].size());
    }
}
Hi All,

I get the following error when attempting to check in this challenge.  However, if I test my code from workbench, it works correctly.  I've checked my spelling, order of parameters in the method signature.

Challenge Not yet complete... here's what's wrong: 
The 'ProjectRESTService' Apex REST service does not appear to be working properly. Calling the service either didn't update the opportunity correctly, return the string 'OK', create an associated project correctly or function correctly in general.

I've checked other forum post and I noticed people are searching for the project record prior to upserting it.  I don't understand why that is needed if I can upsert directly against the ProjectRef__c external id field.  I could try to copy and paste what they did to pass the challenge, but I want to understand why what I coded doesn't work.  A second pair (or more) eyes would be appreciated.  Thank you!
 
@RestResource(urlMapping='/project/*')
global with sharing class ProjectRESTService {
    @HttpPost
    global static String postProjectData(String ProjectRef, String ProjectName, String OpportunityId, Date StartDate, Date EndDate, Double Amount, String Status) {
		SavePoint sp = Database.setSavepoint();
        
        try {
	        Project__c p = new Project__c(ProjectRef__c=ProjectRef, Name=ProjectName, Opportunity__c=OpportunityId, Start_Date__c=StartDate, End_Date__c=EndDate, Billable_Amount__c=Amount, Status__c=Status);
    	    upsert p ProjectRef__c;
            Opportunity o = new Opportunity(Id=OpportunityId, DeliveryInstallationStatus__c='In Progress');
            update o;
        	return 'OK';
        } catch (Exception e) {
            System.debug('~~~ Cause: ' + e.getCause() +  ' Message: ' + e.getMessage() + ' getLineNumber: ' + e.getLineNumber() + ' StackTrace: ' + e.getStackTraceString() + ' Type: ' + e.getTypeName());
            Database.rollback(sp);
            return e.getMessage();
        }     
    }
        
}

 
Hi All,

I get the following error when attempting to check in this challenge.  However, if I test my code from workbench, it works correctly.  I've checked my spelling, order of parameters in the method signature.

Challenge Not yet complete... here's what's wrong: 
The 'ProjectRESTService' Apex REST service does not appear to be working properly. Calling the service either didn't update the opportunity correctly, return the string 'OK', create an associated project correctly or function correctly in general.

I've checked other forum post and I noticed people are searching for the project record prior to upserting it.  I don't understand why that is needed if I can upsert directly against the ProjectRef__c external id field.  I could try to copy and paste what they did to pass the challenge, but I want to understand why what I coded doesn't work.  A second pair (or more) eyes would be appreciated.  Thank you!
 
@RestResource(urlMapping='/project/*')
global with sharing class ProjectRESTService {
    @HttpPost
    global static String postProjectData(String ProjectRef, String ProjectName, String OpportunityId, Date StartDate, Date EndDate, Double Amount, String Status) {
		SavePoint sp = Database.setSavepoint();
        
        try {
	        Project__c p = new Project__c(ProjectRef__c=ProjectRef, Name=ProjectName, Opportunity__c=OpportunityId, Start_Date__c=StartDate, End_Date__c=EndDate, Billable_Amount__c=Amount, Status__c=Status);
    	    upsert p ProjectRef__c;
            Opportunity o = new Opportunity(Id=OpportunityId, DeliveryInstallationStatus__c='In Progress');
            update o;
        	return 'OK';
        } catch (Exception e) {
            System.debug('~~~ Cause: ' + e.getCause() +  ' Message: ' + e.getMessage() + ' getLineNumber: ' + e.getLineNumber() + ' StackTrace: ' + e.getStackTraceString() + ' Type: ' + e.getTypeName());
            Database.rollback(sp);
            return e.getMessage();
        }     
    }
        
}

 
I've got an error from last challange in "Developer Console Basics":

"Challenge Not yet complete... here's what's wrong: 
Could not find the contact's name in the debug log. Be sure to run a query for your record, and to write your contact's name to the debug log using the System.debug() method."

But I'm sure that debog log include the correct lastname, first name as requested and use SOSL.

Does anyone else have the same issue?

 
Just curious on folks' thoughts on which certification path might be more appropriate for a Business Analyst who still has the traditional role of extracting and crafting requirements, but also needs to help the business solve problems with functionality avaliable in SFDC? Was wondering if anyone out there can provide any experience or input on this. I noticed many certified SFDC BAs have gone more towards the DEV route than Admin....
Many thanks - Jeff 
Hello to everybody,

This is Andres . I have 5 years of experience as a Java developer,  ( JEE , XML, JavaScript, HTML, Rest and WebService, etc) , I've recently start studing the Salesforce Platform at Trailhead (trailhead.salesforce.com), and I have some quetions:

Could someone tell me which rails or examples I have to follow ? 
I finished this modules: 

Admin Beginner, 
Admin Intermediate
Developer Beginner
Developer Intermediate (in progress.)
Develop for Lightning Experience, (in progress.)

But the point most important is How I could find a Job witho experiance?

Could someone guide me how to find a job ?

Thanks,
Andres

 
Hello, I am looking to integrate webservice callouts with Visual Workflow, can you please suggest the approach if anyone tried.
We currently have a requirement that Cases for a certain customer are put against one account and that all of the assets are put against another account. This seems to work fine when doing an email to case as the code selects the asset accordingly. When creating a manual case you cannot see the assets which are against the asset account, obviously. I thought about using a parent/child relationship but that didn't make any difference.

Thanks in advance for any help/advice.
SalesForce Customer support has requested I seek assistance here, I am hoping you can help me!


I would like to exclude a custom object that we have called 'billing schedule' from our cloned opportunities with product lines.

I have followed the steps within the following links:

https://help.salesforce.com/articleView?id=000230954&type=1&language=en_US
https://success.salesforce.com/answers?id=90630000000iCIYAA2

But I am unable to accomplish what I need, here is an example of what I have:
User-added image

And here is the Field:

User-added image

Thanks!
I have a SalesForce account in my organization’s sandbox that has system administrator privileges.  When I log into the web UI with porter_horne@wycliffe.org.staging and my password, then I see my login history.  I generated a security token that was delivered successfully to my email account.

I am now trying to create a CozyRoc SalesForce connector, but when I append the security token to my password and test the connection, I get the INVALID_LOGIN error

Is there a way for me to generate a log file that would show me what to change?

Why does the login failure not show in my login history?
 
 
I have an external ID field I want to use to match SFDC accounts with accounts in another application.  I would like to push in data weekly or even more often from the 3rd party application to our SFDC org and was wondering how to set this up.  

Do I need to create a connected App in SFDC, or just find api keys?  It would be very helpful to get pointed in the right direction!

Thanks
I am looking to update a lookup field on the opportunity after a lead has been converted. Not sure if this is possible so I was first wondering if we could even do this. I currently have mapped the fields with a formula so that the lead ID shows on the opportunity but after the lead is converted the lookup will not allow me to select a converted lead. 

Does anyone have any suggestions to try and get me on the right track? 
Reading through other examples and I still can't see my issue.

SELECT CSR__r.name, sum(margin__c) FROM shipment__C WHERE Actual_Delivery_Date__c = this_month  group by CSR__r.name.

If I drop the aggregate and group by my simple list comes back just fine.

Thanks in advance!
  • January 03, 2017
  • Like
  • 0
Hi All,

I receive the following error when attempting to check the challenge for Apply Unit of Work

Challenge Not yet complete... here's what's wrong: 
The 'challangeComplete' method in the 'UnitOfWorkTest' class has not successfully passed all tests. Ensure that you run the tests and it passes successfully before attempting this challenge again.

However, when I run my code in Developer Console, my test passes.  Any ideas on the problem?  Here is the code:

@isTest
public class UnitOfWorkTest {
    @isTest static void challengeComplete(){
        fflib_SObjectUnitOfWork uow = new fflib_SObjectUnitOfWork(
            new Schema.SObjectType[]{
                Account.SObjectType,
                Contact.SObjectType,
                Note.SObjectType
            }
        );
        
        for (Integer i=0 ; i<100 ; i++) {
            Account a = new Account(Name= 'Test' + i);
            uow.registerNew(a);
            
            for (Integer j=0 ; j<5 ; j++) {
                Contact c = new Contact(LastName = 'Test'+i + ' ' +j);
                uow.registerNew(c, Contact.AccountId, a);
                
                Note n = new Note(Body='Test '+i + '' + j, Title='Test'+i+j);
                uow.registerRelationship(n, Note.ParentId, a);
                uow.registerNew(n, Note.ParentId, a);
            }
        }

        uow.commitWork();
 
        fflib_SObjectUnitOfWork uow2 = new fflib_SObjectUnitOfWork(
            new Schema.SObjectType[]{
                Account.SObjectType,
                Contact.SObjectType,
                Note.SObjectType
            }
        );        
        for (Account a : [SELECT Id, Name, (SELECT Id, LastName FROM Contacts), (SELECT Id, ParentId, Title, Body FROM Notes) FROM Account]) {
            a.Name = 'Test';
            uow2.registerDirty(a);
            
            Integer i = 0;
            for (Contact c : a.Contacts) {
                c.LastName = 'Test';
                uow2.registerDirty(c);
                
                a.Notes[i].Body='Test';
                uow2.registerDirty(a.Notes[i]);
                i++;
            }
        }        
        
        test.startTest();
        uow2.commitWork();
        test.stopTest();
        
        System.assertEquals(100, [Select Id from Account].size());
        System.assertEquals(500, [Select Id from Contact].size());
        System.assertEquals(500, [Select Id from Note].size());
    }
}
Hi All,  We recently brought our schedule balancing app, DayBack, to Salesforce. DayBack is a JavaScript web app and bringing it to Salesforce was  intimidating--more learning a new culture than a new language--but it went really well and now DayBack works seamlessly with Salesforce and is Lightning and Mobile1 ready.

We've packaged up what we've learned in this process as an opensource Canvas App Starter Kit. This is the reasource I wish we'd had when we got started. It consolidates a lot of the docs and best practices from around the ecosystem and includes a simpler Hello World application more tuned to JS devs.

So if you have a web app you'd like to bring to the App Exchange, I hope this gives you a big head start. (Feedback MUCH appreciated.)

Starter Kit Splash Screen