首页 新闻 赞助 找找看

EXT grid右击显示菜单,只有第一次显示是正常的。

0
[待解决问题]
 1             mainGrid.on("rowcontextmenu",function(grid, rowIndex,e){
 2                 e.preventDefault(); 
 3                 if (rowIndex < 0) { return; } 
 4                 var materialMenu = new Ext.menu.Menu({
 5                     items : [
 6                              {text : "增加",
 7                                  id : 'add',                             
 8                                  handler : function(){}
 9                              },
10                              { text : "修改",
11                                  id : 'update',
12                                  menu: new Ext.menu.Menu({  
13                                      items: [{  
14                                          text: '默认商品一',
15                                          handler : function(){
16                                              var record = grid.getStore().getAt(rowIndex); 
17                                              alert(record.data.BRAND_NAME); 
18                                          }
19                                      }, {  
20                                          text: '默认商品二'  
21                                      }]  
22                                  })  
23                              },
24                              {text : "删除",
25                                  id : 'delete',
26                                  handler : function() {}
27                              }]
28                 });
29                 materialMenu.showAt(e.getXY()); 
asd6034的主页 asd6034 | 菜鸟二级 | 园豆:202
提问于:2016-07-22 10:47
< >
分享
清除回答草稿
   您需要登录以后才能回答,未注册用户请先注册