profunctional
19 Jul 2010, 6:54 AM
I have a form panel, which currently has an item called "Choose Customer". The way it is implemented now is it is a textfield like this:
xtype: 'textfield',
disabled: true,
cls: 'arrow',
value: 'Choose Customer',
placeholder: 'Choose Customer',
listeners: {
afterrender: function(c){
c.fieldEl.on('click', function(){
mainPanel.setCard(customerSearchForm, 'slide');
});
}
}
However, I can't get the event to fire. This is because I have the texfield "disabled", so that the user can't actually type anything into the field. I need it to slide to another panel where the user will choose an item. Once the user chooses an item, the textfield will be set to that value.
I've attached a screenshot of what it is supposed to look like. I would like it to function much like a native iPhone form, where a user can click on a list element to slide to another panel. But in my case, I need to work inside the form panel. Is there a better way to do this? Or how can I get an event to fire, when the item is disabled?
xtype: 'textfield',
disabled: true,
cls: 'arrow',
value: 'Choose Customer',
placeholder: 'Choose Customer',
listeners: {
afterrender: function(c){
c.fieldEl.on('click', function(){
mainPanel.setCard(customerSearchForm, 'slide');
});
}
}
However, I can't get the event to fire. This is because I have the texfield "disabled", so that the user can't actually type anything into the field. I need it to slide to another panel where the user will choose an item. Once the user chooses an item, the textfield will be set to that value.
I've attached a screenshot of what it is supposed to look like. I would like it to function much like a native iPhone form, where a user can click on a list element to slide to another panel. But in my case, I need to work inside the form panel. Is there a better way to do this? Or how can I get an event to fire, when the item is disabled?