87,921
社区成员
发帖
与我相关
我的任务
分享
function isFormChanged(formPanel){
var form = formPanel.getForm();
var dirty = false;
if(form) {
form.items.each(function(item){
if(!dirty) dirty = item.isDirty();
});
}
return dirty;
}
var AddPublishForm = new Ext.form.FormPanel({
labelWidth: 65,
labelAlign: 'left',
align: 'center',
frame: true,
items: [
{
layout: 'column',
items:
[
{
columnWidth: .25,
layout: 'form',
items: [
{ xtype: 'textfield', id: 'jydbh_add', style: 'background:#F8F3F7', width: 115, fieldLabel: '运单编号', selectOnFocus: true }
]
},
{
columnWidth: .25,
layout: 'form',
items: [
{ xtype: 'textfield', id: 'sxhh_add',allowBlank:false, style: 'background:#F8F3F7', width: 115, fieldLabel: '手写货号', selectOnFocus: true }
]
},
{
columnWidth: .25,
layout: 'form',
items: [
new Ext.form.TriggerField({ id: 'fhrbm_add', fieldLabel: '发 货 人', name: 'fhrbm_add', width: 115, triggerClass: 'x-form-search-trigger', onTriggerClick: function(e) { FhrxxFn(); }, listeners: { specialkey: function(field, e) { if (e.getKey() == Ext.EventObject.ENTER) { SearchFhrbm(); } } } }), { xtype: 'hidden', readOnly: true, id: 'tri_fhrbm' }
]
},
{
columnWidth: .25,
layout: 'form',
items: [
{ xtype: 'textfield', id: 'fhrdh_add', style: 'background:#F8F3F7', width: 115, fieldLabel: '发货电话', selectOnFocus: true }
]
}
]
}, //1
function isFormChanged(formPanel){
var form = formPanel.getForm();
var dirty = false;
if(form) {
form.items.each(function(item){
if(!dirty) dirty = item.isDirty();
});
}
return dirty;
}