• Donald Rivard.ax1922
  • NEWBIE
  • 0 Points
  • Member since 2013

  • Chatter
    Feed
  • 0
    Best Answers
  • 1
    Likes Received
  • 0
    Likes Given
  • 2
    Questions
  • 10
    Replies
I am getting the error:

Ensure that you modify the constructCollaborationGroup method so that it has the correct return type and is not an instance method

Here is that method:
public CollaborationGroup ConstructCollaborationGroup(){
        //ToDo: Ensure this method returns a single Chatter CollaborationGroup
        //    whose Name starts with 'TEST' followed by the INVENTORY_ANNOUNCEMENTS constant
        //    and configured so anyone can join, see and post updates.
        //    
        CollaborationGroup ChatterGroup = new CollaborationGroup(
              Name = 'TEST'+Constants.INVENTORY_ANNOUNCEMENTS,  
              CollaborationType = 'Public',
              CanHaveGuests = true,
              IsArchived = false,
              IsAutoArchiveDisabled = true
        );
        insert ChatterGroup;
        return ChatterGroup;
        
    }
Any ideas on what is wrong. If I run
public void SetupTestData(Integer cnt){
        //ToDo: Ensure this method calls each of the construct methods
        //  and inserts the results for use as test data.
        //  
        CollaborationGroup g = this.ConstructCollaborationGroup();
        List<Account> accounts = this.ConstructAccounts(10);
        List<Contact> contacts = this.ConstructContacts(10,accounts);
        List<Product2> products = this.ConstructProducts(10);
        List<PricebookEntry> pes = this.ConstructPricebookEntries(products);
        List<Order>orders = this.ConstructOrders(10,accounts);
        List<OrderItem> ois = this.ConstructOrderItems(10,pes,orders);
            
    }
All works as expected. I am not sure what I am missing in the ConstructCollaborationGroup method. It is returing a CollaborationGroup and is not static.

Thanks!
I am tring to fire a lightning application event from a component being loaded by Lightning Components for Visualforce. 
Here is the event


<aura:event type="APPLICATION" description="Event template">
  <aura:attribute name="id" type="String"/>
</aura:event>

In my component I have
<aura:registerEvent name="getId" type="c:DWRE_getId"/>

My helper I have

    var getProductsEvent = $A.get("e.c:DWRE_getId");

However getProductsEvent is always undefined. Is it possible to fire application level events from components being loaded in VF user LCfVF?

Don
I am tring to fire a lightning application event from a component being loaded by Lightning Components for Visualforce. 
Here is the event


<aura:event type="APPLICATION" description="Event template">
  <aura:attribute name="id" type="String"/>
</aura:event>

In my component I have
<aura:registerEvent name="getId" type="c:DWRE_getId"/>

My helper I have

    var getProductsEvent = $A.get("e.c:DWRE_getId");

However getProductsEvent is always undefined. Is it possible to fire application level events from components being loaded in VF user LCfVF?

Don
I am getting the error:

Ensure that you modify the constructCollaborationGroup method so that it has the correct return type and is not an instance method

Here is that method:
public CollaborationGroup ConstructCollaborationGroup(){
        //ToDo: Ensure this method returns a single Chatter CollaborationGroup
        //    whose Name starts with 'TEST' followed by the INVENTORY_ANNOUNCEMENTS constant
        //    and configured so anyone can join, see and post updates.
        //    
        CollaborationGroup ChatterGroup = new CollaborationGroup(
              Name = 'TEST'+Constants.INVENTORY_ANNOUNCEMENTS,  
              CollaborationType = 'Public',
              CanHaveGuests = true,
              IsArchived = false,
              IsAutoArchiveDisabled = true
        );
        insert ChatterGroup;
        return ChatterGroup;
        
    }
Any ideas on what is wrong. If I run
public void SetupTestData(Integer cnt){
        //ToDo: Ensure this method calls each of the construct methods
        //  and inserts the results for use as test data.
        //  
        CollaborationGroup g = this.ConstructCollaborationGroup();
        List<Account> accounts = this.ConstructAccounts(10);
        List<Contact> contacts = this.ConstructContacts(10,accounts);
        List<Product2> products = this.ConstructProducts(10);
        List<PricebookEntry> pes = this.ConstructPricebookEntries(products);
        List<Order>orders = this.ConstructOrders(10,accounts);
        List<OrderItem> ois = this.ConstructOrderItems(10,pes,orders);
            
    }
All works as expected. I am not sure what I am missing in the ConstructCollaborationGroup method. It is returing a CollaborationGroup and is not static.

Thanks!
Hi, I'm starting a specific post for this topic. 

I'm getting the following message on step 9. 

Challenge Not yet complete... here's what's wrong: 
The 'Opp Stage by Adventure' report does not appear to be configured correctly. Make sure it has the correct report type, groupings, filters and chart type.

It is ironic to get to the end and get stuck on charts which I do all the time. :) Ok, here are the instructions:

Give sales reps a visual indicator to compare product performance. First, create a summary report on opportunities named Opp Stage by Adventure. Filter it by Product Date within the past year. For the purpose of this superbadge, assume this date range is 1/1/2026-12/31/2026. Second, add a stacked vertical bar chart of the number of explorers by product name, grouped by stage, to your summary report. Finally, add this chart to your Lightning Adventure Record Page with the label Adventure Stage Comparison. To ensure that this chart isn’t accidentally displayed to customers, add it to a new section called Adventure Comparison.

And, here is what I have. 

I have a Summary Report of "Opportunities with Adventures". In the data model, each Opportunnity corresponds to 1 Explorer from what I can tell per the data model. I've grouped the report by adventure and stage. I have not grouped by Explorer (which is a Contact Role on each Opportunity). I have tried that though and still got the same error. Note also that I'm using "Adventure Date" instead of Procuct Date per the instructions since Product has been renamed to Adventure. 

Opp Stage by Adventure Report



Chart Editor

In the Lightning Record page for Adventure, I've created a custom tab called "Adventure Comparison" and added in the chart called " Adventure Stage Comparison". I've also tried flipping those names, but I still got the same error. 

Adventure Chart in Lightning Record

Any hints would be appreciated. :)
Hi All,

Challenge Not yet complete... here's what's wrong: 
There was an unexpected error in your org which is preventing this assessment check from completing: System.DmlException: Delete failed. First exception on row 0 with id 0032800000VuJdTAAV; first error: DELETE_FAILED, Your attempt to delete Sam the ninja could not be completed because it is associated with the following adventure packages.: null, null : []

I am stuck with this error from long time.

I checked with debug logs when challenge tries to test our work. It is :
 
Execute Anonymous: Contact sam = new Contact(firstname='Sam', lastname='the ninja');
Execute Anonymous: insert sam;
Execute Anonymous: Opportunity opp = new Opportunity(name='Make Kite to Fly', stagename='New', closedate=date.today());
Execute Anonymous: insert opp;
Execute Anonymous: // insert product
Execute Anonymous: Product2 product = new Product2(name='Butterfly Net', isActive=true);
Execute Anonymous: insert product;
Execute Anonymous: // insert the pricebookentry
Execute Anonymous: Pricebook2 stdPrice = [Select id from Pricebook2 where isStandard=true limit 1];
Execute Anonymous: PricebookEntry pbe = new PricebookEntry( IsActive = true, Product2Id = product.id, UnitPrice = 2.00, Pricebook2Id = stdPrice.Id);
Execute Anonymous: insert pbe;
Execute Anonymous: // create the opp line item
Execute Anonymous: OpportunityLineItem oli1 = new OpportunityLineItem(OpportunityId=opp.Id, UnitPrice=2, quantity=1,pricebookentryid=pbe.Id, servicedate = date.newInstance(2050, 1, 1), explorer__c = sam.id);
Execute Anonymous: OpportunityLineItem oli2 = new OpportunityLineItem(OpportunityId=opp.Id, UnitPrice=2, quantity=1,pricebookentryid=pbe.Id, servicedate = date.newInstance(2010, 1, 1), explorer__c = sam.id);
Execute Anonymous: insert oli1;
Execute Anonymous: insert oli2;
Execute Anonymous: // this will create a fulfillment record
Execute Anonymous: // find the fulfillment -- by AdventurePackageId__c which is the opp line item
Execute Anonymous: Fulfillment__c f1 = [select id, deposit__c from Fulfillment__c where AdventurePackageId__c = :oli1.Id];
Execute Anonymous: Fulfillment__c f2 = [select id, deposit__c from Fulfillment__c where AdventurePackageId__c = :oli2.Id];
Execute Anonymous: // update the fulfillment and set to cancelled
Execute Anonymous: f1.Status__c = 'Cancelled';
Execute Anonymous: update f1;
Execute Anonymous: f2.Status__c = 'Cancelled';
Execute Anonymous: update f2;
Execute Anonymous: // get the fulfillment again to check the values
Execute Anonymous: oli1 = [select id, unitprice from OpportunityLineItem where Id = :oli1.Id];
Execute Anonymous: oli2 = [select id, unitprice from OpportunityLineItem where Id = :oli2.Id];
Execute Anonymous: // make sure the deposit matches the unit price
Execute Anonymous: System.assertEquals(f1.deposit__c, oli1.unitprice); // one way in the future
Execute Anonymous: System.assertNotEquals(f2.deposit__c, oli2.unitprice); // one way in the past
Execute Anonymous: // clean up
Execute Anonymous: delete opp;
Execute Anonymous: delete f1;
Execute Anonymous: delete f2;
Execute Anonymous: delete product;
Execute Anonymous: delete sam;

I tiried the same in anonymous window except the code of deleting records and there is no error. It means challenge is actually passed. But deleting test records causing error :
User-added image


Please help.
 
I am get this error: "Challenge Not yet complete... here's what's wrong: 
The 'Opp Stage by Adventure' report does not appear to be configured correctly. Make sure it has the correct report type, groupings, filters and chart type".

I believe i configured the report according to the instructions but it is still showing and error. Any assistance or insight would be apreciated. 
This is the error I'm getting: "The sharing rule that shares Opportunities owned by Field Sales users with Inside Sales users does not appear to be setup correctly."
Note that project managers have a variety of responsibilities within your Salesforce org, so you can’t use role for record sharing.

I set up an Opportunity Criteria based sharing rule with the 2 criteria.  I've tried sharing with the following interations but still haven't passed it
  • Inside Sales
  • a Public Group that includes (Inside Sales, VP Sales, Field Sales)
  • a Public Group that includes (Inside Sales, VP Sales, Field Sales)
  • All Internal Users

Additional Info for Profile opportunity object permissions:
Field Sales User: R/C/E
Inside Sales User: R
Project Management User: R
Sales Executive User: R/VA

3 Roles
Field Sales & Inside Sales reporting to VP Sales
  • June 16, 2016
  • Like
  • 0
Has anyone completed this trail? I am stomped on challenge number 3, regarding created the process for fulfillment. Any pointers or guidance would be appreciated.
 

Hi,

 

I am sending some email notification to admin and owner on case attachment.

 

This is working fine when a standard user does case attachment,but when a portal user does case attachment the following exception is throws:

 

AttachmentNotifier: execution of AfterInsert

caused by: System.EmailException: SendEmail failed. First exception on row 0; first error: FIELD_INTEGRITY_EXCEPTION, Portal user can't own an activity: []

 

I am not getting what i am missing.

 

Regards,

Chandra