Ext-设置form表单不可编辑

时间:2022-05-25 01:38:55

1.

    var formEach  = win.down('form').items.items;
Ext.each(formEach,function(item){
console.log(item);
//item.setReadOnly(true);
item.setDisabled(true);
//item.readOnly = true;
item.fieldStyle = 'background:#E6E6E6';
});

2.

var form = getWinForm(grid);
form.items.each(function(items) {
items.items.each(function(item) {
console.log(item);
//item.setReadOnly(true);
item.readOnly = true;
item.fieldStyle = 'background:#E6E6E6';
});
});

3.

 win.down('form').setDisabled(true);