View Full Version : [INFOREQ] compositefield don't send any valid event
18 May 2010, 12:40 AM
In the API doc, compositefield have a "valid" event, but the event is never throw by the compositefield.
18 May 2010, 8:34 AM
I'm having some difficulty following you. Perhaps if you followed the bug forum guidelines: http://www.extjs.com/forum/showthread.php?71015-Posting-to-the-Bug-Forum we might be able to help.
Ext version tested:
only default ext-all.css
Browser versions tested against:
FF3 (firebug 126.96.36.199 installed)
I have a compositefield with, for example, a textfield.
When I set a value in the textfield, I dont have any "valid" event throw by the compositefield.
How can I be warn when the textfield is valid ?
console.log("ok");// never throw
20 May 2010, 2:49 PM
I believe OP is looking for the child field events to be relayed to the parent Composite field. ;)
26 Jan 2011, 3:06 PM
Further note -- events from items contained in a composite field don't bubble up, even if "bubbleEvents" is set. That seems to be because the ownerCt of the items are an Ext.Container built on the fly inside initComponent of Ext.form.CompositeField. Then then ownerCt of the Ext.Container is set to undefined, so there is no link from composite field items to their parent form.
This particular issue may have been reported in other places, but I thought I'd mention it led me to waste several hours trying to debug form validation. Basically the Ext.field.CompositeField class seems to be broken in a few ways, probably mostly related to the fact that the items inside the CompositeField are left inside an orphaned container.
26 Aug 2013, 4:07 AM
The CompositeField owerwrite the behaviour on validation of its children when combineErrors is TRUE (is the default setting).
If you are using a compositeField with a single child, you are misusing the compositeField, it's ment to be used with more fields (to "compose" them) and the validation should be done alltogether.
Powered by vBulletin® Version 4.1.5 Copyright © 2014 vBulletin Solutions, Inc. All rights reserved.