私はExtJS3.3を使用しており、次のコードを使用していますformpanel
。
Ext.apply(this, {
items: [{
xtype: 'textfield',
fieldLabel: 'ApplicationGUID',
labelAlign: 'right',
name: 'Application_GUID',
value: 0,
readOnly: false,
width: 300
},
{
xtype: 'textfield',
fieldLabel: 'ApplicationName',
labelAlign: 'right',
name: 'Application_Name',
anchor: '-20',
msgTarget: 'side'
}
], //eof items
tbar: [{
xtype: 'mydeletebutton',
scope: this,
ownerCt: this,
handler: this.deleteHandler,
myAuth: {
compBaseRights: {
Delete: {
failProperty: {
disabled: false
}
} /*eof Delete*/
} /*eof compBaseRights*/
} /*eof sgAuth*/
}, {
xtype: 'tbseparator'
}, {
xtype: 'trashcanbutton',
scope: this,
ownerCt: this,
handler: this.setIsDeletedHandler,
myAuth: {
compBaseRights: {
Insert: {
failProperty: {
disabled: false
}
} /*eof Delete*/
} /*eof compBaseRights*/
}
}, {
xtype: 'mytrashcanrestorebutton',
scope: this,
ownerCt: this,
handler: this.unsetIsDeletedHandler,
myAuth: {
compBaseRights: {
Insert: {
failProperty: {
disabled: false
}
} /*eof Delete*/
} /*eof compBaseRights*/
}
}, {
xtype: 'tbseparator'
}, {
xtype: 'mysavebutton',
scope: this,
handler: this.saveHandler,
myAuth: {
compBaseRights: {
Write: {
failProperty: {
disabled: false
}
} /*eof Delete*/
} /*eof compBaseRights*/
}
}],
bbar: {
xtype: 'mystatusbar'
}
});
私が探しているのは、textfield
Application_GUIDのreadOnly: true
場合、値がすでに存在するかどうか(グリッドから既存の値をダブルクリックして編集する場合など)である必要があり、から新しいボタンを押すとgrid
、readonly
ステートメントはである必要がありますfalse
。
誰かが私を助けることができれば、それはありがたいです。ありがとう。