我有一个sencha touch正在列表中显示的联系人列表.然后,当您单击列表中的名称时,它应向右滑动并说出Hello {联系人姓名}!但是当它现在滑过时它只是说你好!在第29行是项目点击动作发生的地方我相信问题就在这里.我只是不知道如何正确格式化它.以下是我的源代码.
ListDemo = new Ext.Application({
name: "ListDemo",
launch: function() {
ListDemo.detailPanel = new Ext.Panel({
id: 'detailpanel',
tpl: 'Hello, {firstName}!',
dockedItems: [
{
xtype: 'toolbar',
items: [{
text: 'back',
ui: 'back',
handler: function() {
ListDemo.Viewport.setActiveItem('disclosurelist', {type:'slide', direction:'right'});
}
}]
}
]
});
ListDemo.listPanel = new Ext.List({
id: 'disclosurelist',
store: ListDemo.ListStore,
itemTpl: '<div class="contact">{firstName} {lastName}</div>',
listeners:{
itemtap: function(record, index){
ListDemo.detailPanel.update(record.data);
ListDemo.Viewport.setActiveItem('detailpanel');
}
}
});
ListDemo.Viewport = new Ext.Panel ({
fullscreen: true,
layout: 'card',
cardSwitchAnimation: 'slide',
items: [ListDemo.listPanel, ListDemo.detailPanel]
});
} …Run Code Online (Sandbox Code Playgroud) 当我将鼠标放在下拉菜单上时,我创建了这个css3下拉菜单,它出现在图像后面,我试图找出它.但不能为我的生活.任何帮助都非常明确,你可以在这里看一看.
我正在尝试创建php脚本,按顺序生成11,000,000,000个唯一ID.但是,我试图在20分钟内很快完成它应该产生这1100万个独特的ID.此外,一旦达到12,000,000,它应该环绕并从零开始.
这是我到目前为止所拥有的.这个脚本一次只能返回一个id.我刚刚添加了一个循环,看看生成id需要多长时间.
while(true){
try {
$this->getAdapter()->query('INSERT INTO generate_ids (assigned_id) SELECT (MAX(assigned_id)+1) FROM generate_ids');
$id = $this->getAdapter()->lastInsertId();
$sql = 'SELECT assigned_id FROM generate_ids WHERE id = $id';
$query = $this->getAdapter()->query($sql);
$result = $query->fetchAll();
//Live system would return id here
$assigned_id = $result[0]['assigned_id'];
} catch (Exception $e) {
//do nothing
}
if($count == 11000000){
die();
}
$count++;
}
Run Code Online (Sandbox Code Playgroud)
}