I seem to have problems updating objects in Titanium Apcelerator Alloy,
Basically I want to add a table row to a table that is in another controller / view in which I am now. I hope it will be better to describe this below: s
basket.xml
<Alloy> <Window id="basketWindow" class="container"> <TableView id="basketTable" /> <Button id="addItemButton" onClick="addItem">Add Item</Button> </Window> </Alloy>
basket.js
function addItem() { var itemList = Alloy.createController('item_list'); itemList.getView().open(); }
item_list.xml
<Alloy> <Window id="itemListWindow" class="container"> <TableView id="itemListTable"> <TableViewRow id="item1" className="item" onClick="addItemToBasket"> Test Item </TableViewRow> </TableView> </Window> </Alloy>
item_list.js
function addItemToBasket() { var row = Ti.UI.createTableViewRow({title: 'Test Item'});
Does anyone know about this?
Thank you for reading:)
David source share