我正在使用 Extjs4,我有 1 个带有复选框的网格,我需要更新用户选择的记录。
我正在获取用户选择的所有记录,但问题是它没有更新...代码如下所示
{
xtype: 'button',
text: 'Save/Update',
iconCls : 'icon-save',
handler:function(){
//saveAndUpdate();
var s=grid.getSelectionModel().getSelection();
alert(s.length);
if(s.length==0){
alert(" No Records Selecteds");
}else{
for(var i=0;i<s.length;i++){
var menuKey=s[i].get('menuKey');
var addYN=s[i].get('addYN')==true?'Y':'N';
var editYN=s[i].get('editYN')==true?'Y':'N';
var viewYN=s[i].get('viewYN')==true?'Y':'N';
var deleteYN=s[i].get('deleteYN')==true?'Y':'N';
var exportYN=s[i].get('exportYN')==true?'Y':'N';
alert(menuKey+addYN+editYN+viewYN+deleteYN+exportYN);
var record = Ext.create('RoleMenuLinks');
record.set({
roleKey:roleKey.value,
menuKey:menuKey,
addYN:addYN,
editYN:editYN,
viewYN:viewYN,
deleteYN:deleteYN,
exportYN:exportYN
});
alert("All Record Set ");
tempStore.sync();
}
}
它没有调用java控制器....?