What would be the best way to add some badgeText to the Items of a List开发者_开发百科-Panel?
o.k., so one way to add badge text to a list item is to add the following code to the xtemplate/itemTpl:
...
'<span class="x-badge ">4</span>',
...
Sencha Touch 2.1
xtype: 'list',
itemId: 'listMainMenu',
store: 'storeMainMenu',
fullscreen: false,
itemTpl: '<span class="x-badge ">{BadgeText}</span>'
and it's not working.
DOM result:
<div class="x-innerhtml " id="ext-element-104"><span class="x-badge ">1</span></div>
精彩评论