+ Start a Discussion
LinvioIncLinvioInc 

Error in packaging orgs that prevents use of sObject collection attributes in lightning:availableForFlowScreens

We've found that while you can have an sObject collection attribute on a lightning component that implements the lightning:availableForFlowScreens interface and access the attribute from the flow designer,  you cannot see the attribute if the component was created in a developer org that has a package prefix.

Example: We created the following sample component in both a clean developer org, and an org that had a package prefix defined:
 
<aura:component implements="lightning:availableForFlowScreens" access="global">
    <aura:attribute name="contacts" type="Contact[]" />
    <aura:iteration items="{!v.contacts}" var="contact">
        {!contact.Name}: {!contact.Email}<br/>
    </aura:iteration>
</aura:component>

And configured the design attributes so that the flow designer would be able to "see" the component attribute:
<design:component >
    <design:attribute name="contacts" label="Contact records"/>
</design:component>



The flow designer in package org refused to display the "Contact records" attribute:
(we also published the component as part of the package and tested it in the flow designer of the target org and got the same results).

User-added image 

However if we use the same source code to create a component in a non-packaging org, the component (without a namespace prefix) works fine and we can see the component attribute in the flow screen inputs and outputs:

User-added image

Has anyone else run into this?
LinvioIncLinvioInc
The same is true if the attribute is marked "global"
 
<aura:component implements="lightning:availableForFlowScreens" access="global">
    <aura:attribute name="contacts" type="Contact[]" access="global"/>
    <aura:iteration items="{!v.contacts}" var="contact">
        {!contact.Name}: {!contact.Email}<br/>
    </aura:iteration>
</aura:component>

 
Amit Chaudhary 8Amit Chaudhary 8
Did you found any solution for this ?
LinvioIncLinvioInc
Not yet.  There appear to be several issues related to flow designer and orgs with a managed package.  You cannot pass custom objects from the package to flow input attributes either.  Here's a related Known Issue: https://success.salesforce.com/issues_view?id=a1p3A000000JWxi

Voting it up couldn't hurt.  Thanks!
Bill DodsonBill Dodson
Any work around to this issue yet?