-
27 May 2008 9:52 AM #21
Me too!!!
Mandriva Linux in
LAMPE (Linux / Apache / MySQL / PHP / ExtJs)
-
29 Jul 2008 4:05 AM #22igor.stamaGuest
Greetings Animal and Condor,
thank you for the override code.
Let me first say how wonderful the ExtJS framework is, but as always there are some quirks like this.
I have a formPanel and it will contain, radios, textfields, comboboxes etc that need to be hidden or need to affect the visibility of other fields on the form. As usual the labels are not hidden but we have added your fix to extend the Ext.FormPanel code at the moment it doesn't work for a combo box field. Any help appriciated \0/
Here is the use-case and my investigation using Firebug:
When a combo is present on a form it does not add x-hide-display prior to the x-form-item class, but instead it adds display: none; to the style of the combo and as a result it does not hide the label
.
I would be available to give you additional information if you need them.
I'm using version 2.1 of ExtJS.
-
29 Jul 2008 4:27 AM #23Sencha - Community Support Team
- Join Date
- Mar 2007
- Location
- The Netherlands
- Posts
- 24,251
- Vote Rating
- 44
Combobox completely ignores the normal field show and hide and uses its own logic.
In your case you could replace the onShow and onHide methods with the original code, e.g.
or as an override:Code:{ xtype: 'combo', onShow: Ext.form.TextField.prototype.onShow, onHide: Ext.form.TextField.prototype.onHide, ... }
Code:Ext.override(Ext.form.TriggerField, { actionMode: 'wrap', onShow: Ext.form.TriggerField.superclass.onShow, onHide: Ext.form.TriggerField.superclass.onHide });Last edited by Condor; 30 Dec 2008 at 4:35 AM. Reason: Added override
-
14 Aug 2008 4:13 AM #24
Thanks a lot... this works fine with me too...
-
14 Aug 2008 5:37 AM #25
Condor...
I got a problem here... I used ur override code... but it broke my form, I
-
14 Aug 2008 5:53 AM #26
Hey Condor...
I think that I fixed here... now its hidding and showing all, I just need take off the delay kkkk
thanks again condor and animal
Code:Ext.override(Ext.layout.FormLayout, { renderItem : function(c, position, target){ if(c && !c.rendered && c.isFormField && c.inputType != 'hidden'){ var args = [ c.id, c.fieldLabel, c.labelStyle||this.labelStyle||'', this.elementStyle||'', typeof c.labelSeparator == 'undefined' ? this.labelSeparator : c.labelSeparator, (c.itemCls||this.container.itemCls||'') + (c.hideLabel ? ' x-hide-label' : ''), c.clearCls || 'x-form-clear-left' ]; if(typeof position == 'number'){ position = target.dom.childNodes[position] || null; } if(position){ c.formItem = this.fieldTpl.insertBefore(position, args, true); }else{ c.formItem = this.fieldTpl.append(target, args, true); } // Remove the form layout wrapper on Field destroy. c.on('destroy', c.formItem.remove, c.formItem, {single: true}); c.on('hide', c.formItem.hide, c.formItem, {single: false}); c.on('show', c.formItem.show, c.formItem, {single: false}); c.render('x-form-el-'+c.id); }else { Ext.layout.FormLayout.superclass.renderItem.apply(this, arguments); } } });
-
20 Oct 2008 12:00 AM #27
According to Jack's response, seems that there's no plan to add this functionality to the core code.
He mentions about a plugin.
Does anybody has created that plugin, or should I do the override ?Using Ext with cachefly
Working on LAMPExt
-
7 Nov 2008 6:32 PM #28
Any update on this guys? I've also run into this issue and it's quite a problem. Is there a semi-official fix - it sounded like Animal/Condor's wasn't quite fully functional,
Cheers!
-
18 Nov 2008 3:48 AM #29psarafGuest
Thanks leolima, you code help me to solve the issue.
-
30 Dec 2008 11:52 AM #30



Reply With Quote