今天早上我开始使用Sencha Touch,我可以使用一些帮助。Sencha Touch - 列表/ nestesList包含图片
如果我创建这样一个nestedList:
var data = {
text: 'Groceries',
items: [{
text: 'Ninja',
items: [{
text: 'Water',
items: [{
text: 'Sparkling',
leaf: true
},{
text: 'Still',
leaf: true
}]
},{
text: 'Coffee',
leaf: true
},{
text: 'Espresso',
leaf: true
},{
text: 'Redbull',
leaf: true
},{
text: 'Coke',
leaf: true
},{
text: 'Diet Coke',
leaf: true
}]
}],{
text: 'Fruit',
items: [{
text: 'Bananas',
leaf: true
},{
text: 'Lemon',
leaf: true
}]
},{
text: 'Snacks',
items: [{
text: 'Nuts',
leaf: true
},{
text: 'Pretzels',
leaf: true
},{
text: 'Wasabi Peas',
leaf: true
}]
},{
text: 'Empty Category',
items: []
}]
};
我如何图像添加到列表中?例如,如果我想让可口可乐标志旁边的字符串饮食焦炭。我试着在里面设置一个html图像,但这只是给了我一个空白的项目。尽管有“text”属性,但我无法找到如何操作列表项的任何信息。我知道这是可能的,因为我看到一个包含联系人列表和联系人照片的例子。
我希望你能提前帮助我,谢谢你。
你能张贴你有什么到目前为止 – Ballsacian1