Hi.
I'm trying to create a custom listview component but i get the following error:
"'undefined' is not an object (evaluating 'Alloy.Abstract.createTemplates')";
Anybody got an idea of what i am doing wrong?
My customListView.js file:
exports.createCustomListView = function(args) { var listView = Ti.UI.createListView(args); return listView; };My alloy file:
<Alloy> <CustomWindow id="logbookWindow" ns="require('common/customWindow')" class="container"> <CustomListView id="meterLogList" ns="require('common/customListView')" onItemclick="logClicked" onDelete="deleteEntry"> <Templates> <ItemTemplate name="meterLogTemplate" id="meterLogTemplate"> <Label bindId="timeStamp" id="logTimestamp"/> <Label bindId="value" id="logValue"/> </ItemTemplate> <ItemTemplate name="meterLogHeaderTemplate" id="meterLogHeaderTemplate"> <Label bindId="timeStampHeader" id="logTimestampHeader"/> <Label bindId="valueHeader" id="logValueHeader"/> </ItemTemplate> <ItemTemplate name="addNewMeterLogItemTemlate" id="addNewMeterLogItemTemlate"> <ImageView id="addNewImage"/> <Label bindId="addNewItemLabel" id="addNewItemLabel"/> </ItemTemplate> </Templates> <ListSection id="addNewMeterLogSection"> </ListSection> <ListSection id="meterLogSection"> </ListSection> </CustomListView> </CustomWindow> </Alloy>