You need to sign in to do that
Don't have an account?
PACO_D
render threw an error in 'lightning:treeGrid' [can't convert undefined to object]
Hello I am trying using lightning:treeGrid and i am facing this issue render threw an error in 'lightning:treeGrid' [can't convert undefined to object]
my component
the error screenshot
what is the mistake ?
my component
<aura:component controller="Milestone" implements="flexipage:availableForAllPageTypes,flexipage:availableForRecordHome,force:hasRecordId" access="global" > <aura:attribute name="gridCol" type="List" /> <aura:attribute name="gridData" type="Object" /> <aura:handler name="init" value="{!this}" action="{!c.doInitTree}"/> <lightning:treeGrid columns="{!v.gridCol}" data="{!v.gridData}" keyField="id" aura:id="mytree" /> </aura:component>my Js Controller
public class Milestone { @AuraEnabled public static list<Stage__mdt> getlistTreeGrid(){ list<Stage__mdt> listvaleur=new list<Stage__mdt>([SELECT Label,IsSelect__c,(SELECT Label, IsSelect__c FROM Jalons__r) FROM Stage__mdt]); return listvaleur; } }my apex controller
public class Milestone { @AuraEnabled public static list<Stage__mdt> getlistTreeGrid(){ list<Stage__mdt> listvaleur=new list<Stage__mdt>([SELECT Label,IsSelect__c,(SELECT Label, IsSelect__c FROM Jalons__r) FROM Stage__mdt]); return listvaleur; } }
the error screenshot
what is the mistake ?
kajal rathod
Can u update the correct js controller of your's
PACO_D
my js controller