Skip to content

Instantly share code, notes, and snippets.

@pphetra
Created June 27, 2013 09:32
Show Gist options
  • Select an option

  • Save pphetra/5875200 to your computer and use it in GitHub Desktop.

Select an option

Save pphetra/5875200 to your computer and use it in GitHub Desktop.
f1 = Ext.create('Ext.window.Window', {
title: 'Employee Form',
height: 200,
width: 300,
bodyPadding: 10,
items: [
{
xtype: 'form',
url: '/sagi/service/employees',
defaultType: 'textfield',
items: [
{
fieldLabel: 'First Name',
name: 'firstName'
},
{
fieldLabel: 'Last Name',
name: 'lastName'
},
{
xtype: 'datefield',
fieldLabel: 'Date of birth',
name: 'birthDate'
}
],
buttons: [
{
text: 'submit',
handler: function() {
this.up('form').submit({
success: function() {
alert('submit success')
}
});
}
}
]
}
]
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment