Skip to main content
added 2 characters in body
Source Link
Robert Sösemann
  • 38.2k
  • 29
  • 173
  • 508

It looks like either your sample code is incomplete, or you are missing some variables - the main issue seems to be path.currentStep isn't definied in your apex class.

<aura:component>
<aura:attribute name="path" type="CustomPath" />

// There isn't anything in your controller that maps to v.path.currentStep. 
// When the component tries to parse it, it can't read the 'Id' because there is not variable called 'currentSetup', so it results in a 'hasOwnProperty' error
<lightning:progressIndicator currentStep="{!v.path.currentStep.id}"> 
    <aura:iteration items="{!v.path.steps}" var="step">
        <lightning:progressStep label="{!step.label}" value="{!stage.id}"/>
    </aura:iteration>
</lightning:progressIndicator>

</aura:component>

To verify that this is correct, try temporarily removing the currentStep attribute on the lightning:progressIndicatorlightning:progressIndicator and see if it then loads successfully

It looks like either your sample code is incomplete, or you are missing some variables - the main issue seems to be path.currentStep isn't definied in your apex class.

<aura:component>
<aura:attribute name="path" type="CustomPath" />

// There isn't anything in your controller that maps to v.path.currentStep. 
// When the component tries to parse it, it can't read the 'Id' because there is not variable called 'currentSetup', so it results in a 'hasOwnProperty' error
<lightning:progressIndicator currentStep="{!v.path.currentStep.id}"> 
    <aura:iteration items="{!v.path.steps}" var="step">
        <lightning:progressStep label="{!step.label}" value="{!stage.id}"/>
    </aura:iteration>
</lightning:progressIndicator>

</aura:component>

To verify that this is correct, try temporarily removing the currentStep attribute on the lightning:progressIndicator and see if it then loads successfully

It looks like either your sample code is incomplete, or you are missing some variables - the main issue seems to be path.currentStep isn't definied in your apex class.

<aura:component>
<aura:attribute name="path" type="CustomPath" />

// There isn't anything in your controller that maps to v.path.currentStep. 
// When the component tries to parse it, it can't read the 'Id' because there is not variable called 'currentSetup', so it results in a 'hasOwnProperty' error
<lightning:progressIndicator currentStep="{!v.path.currentStep.id}"> 
    <aura:iteration items="{!v.path.steps}" var="step">
        <lightning:progressStep label="{!step.label}" value="{!stage.id}"/>
    </aura:iteration>
</lightning:progressIndicator>

</aura:component>

To verify that this is correct, try temporarily removing the currentStep attribute on the lightning:progressIndicator and see if it then loads successfully

Source Link
jongpie
  • 860
  • 6
  • 12

It looks like either your sample code is incomplete, or you are missing some variables - the main issue seems to be path.currentStep isn't definied in your apex class.

<aura:component>
<aura:attribute name="path" type="CustomPath" />

// There isn't anything in your controller that maps to v.path.currentStep. 
// When the component tries to parse it, it can't read the 'Id' because there is not variable called 'currentSetup', so it results in a 'hasOwnProperty' error
<lightning:progressIndicator currentStep="{!v.path.currentStep.id}"> 
    <aura:iteration items="{!v.path.steps}" var="step">
        <lightning:progressStep label="{!step.label}" value="{!stage.id}"/>
    </aura:iteration>
</lightning:progressIndicator>

</aura:component>

To verify that this is correct, try temporarily removing the currentStep attribute on the lightning:progressIndicator and see if it then loads successfully