I am using <aura:iteration>
to generate a datatable. But I am continuously getting the error:
aura/Select_List_For_Message/Select_List_For_Message.cmp -- Error: unexpected token: a left angle bracket at column 1 of expression: lt['list_name'] (line N/A column N/A)
Below is the code snippet I am getting the error. Really not sure what is being wrong:
Attribute definition:
<aura:attribue name="lists" type="Send_Email_Controller.List_Helper[]"/>
Table:
<table class="slds-table slds-table--bordered slds-table--cell-buffer">
<thead>
<tr class="slds-text-title--caps">
<th scope="col">
<div class="slds-truncate">Send</div>
</th>
...
</tr>
</thead>
<tbody>
<aura:iteration items="{!v.lists}" var="lt">
<tr>
<td>
<ui:inputCheckbox value="{!lt.isSend}"/>
</td>
<td>
<div class="slds-truncate">{!lt['list_name']}</div>
</td>
As you can see here, I have already tried {!lt.isSend} and lt['list_name'] ways here. But neither one worked for me.
The answer should be something simple. But I just can't figure out.
Edit
List_helper is a wrapper class defined inside original VF page controller, which is also my lightning component server side controller now. The definition is as below:
public class Send_Email_Controller
{
//...
public class List_Helper
{
public String list_name {get; set;}
public String folder_name {get; set;}
public Boolean isSend {get; set;}
public Boolean unsent {get; set;}
public Decimal v6_id {get; set;}
public List_Helper()
{
isSend = false;
unsent = false;
}
}
}