• Abhi bhardwaj
  • NEWBIE
  • 5 Points
  • Member since 2019

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 3
    Replies
Hi, I am having trouble with the "Attributes and Expressions" module from trailhead.

Here is the challenge:
Create a Lightning Component to display a single item for your packing list.
  • Create a component called campingListItem that displays the name (ui:outputText) and the three custom fields using the appropriate output components.
  • Add an attribute named 'item' for type Camping_Item__c.
I created an component named campingListItem and this is the code:
<aura:component >
    <aura:attribute name="item" type="<my_domain>__Camping_Item__c"/>
    
    <ui:outputText value="{!v.item.Name}"/>
    <ui:outputCheckbox value="{!v.item.<my_domain>__Packed__c}"/>
    <ui:outputCurrency  value="{!v.item.<my_domain>__Price__c}"/>
    <ui:outputNumber value="{!v.item.<my_domain>__Quantity__c}"/>
</aura:component>

The error that I am getting is: "Challenge Not yet complete... here's what's wrong: 
The packingListItem Lightning Component's attribute tag doesn't exist or its attributes are not set correctly."

With this, I tried to create another component, with the name "packingListItem", but It didn't work.

Can anyone help me?

Thanks,
I cannot for the life of me, figure out what could be wrong with my campingList component markup for the "Create a Simple Camping List Lightning Component" challenge.  This is the markup for campingList.cmp:

<aura:component>
     <ul>
        <li>Bug Spray</li>
        <li>Bear Repellant</li>
        <li>Goat Food</li>
    </ul>
 </aura:component>

Please help me figure out why I am getting the error.  Thank you, Susan

 
I have a formula field, "Age", that caluclates the ages of our clients.  Age is set up as a text return type and has this formula:
IF(TODAY() >=Date(YEAR(TODAY()), 
MONTH(Birthdate), DAY(Birthdate)), 
TEXT(YEAR(TODAY()) - YEAR(Birthdate)), 
TEXT(YEAR(TODAY()) - YEAR(Birthdate) - 1))  

I want to create an "age range" field, so created another formula field with a return type of text, but keep getting the error:  Error: Incorrect parameter type for operator '>'. Expected Text, received Number.  Here is my formula:  

IF(age__c>"18","19+",
IF(age__c>="15","15-18",
IF(age__c>="10","10-14",
IF(age__c>="6","6-9",
IF(age__c>="3","3-5",
IF(age__c<="2","None"))))))

I get an error too if I try to change my age field to a number and try it from that way.  

Thanks for any help!
Kris