Ext.create('Ext.form.Panel', {
title: 'Time Card',
width: 300,
bodyPadding: 10,
renderTo: Ext.getBody(),
items: [{
xtype: 'timefield',
id: 'mytimefieldId',
name: 'in',
fieldLabel: 'Time In',
minValue: '00:00 AM',
maxValue: '11:59 PM',
increment: 30,
submitFormat : 'H:i',
//format: 'H:i',
value: new Date(),
anchor: '80%'
}]
});
Ext.getCmp('mytimefieldId').setValue(new Date())
console.log(Ext.getCmp('mytimefieldId').getSubmitValue())
//console.log(Ext.getCmp('mytimefieldId').value)
Test Online
http://jsfiddle.net/JAAx7/2/
Buen post me sirvió de mucho.
ResponderEliminar