Bug 109973 - Cannot add any controls to FormItem or FormSectionItem
Cannot add any controls to FormItem or FormSectionItem
Status: CLOSED RAWHIDE
Product: Red Hat Enterprise CMS
Classification: Retired
Component: other (Show other bugs)
nightly
All Linux
medium Severity medium
: ---
: ---
Assigned To: ccm-bugs-list
Jon Orris
:
Depends On: 107635 107636 109978
Blocks: 100952
  Show dependency treegraph
 
Reported: 2003-11-13 11:21 EST by Daniel Berrange
Modified: 2007-04-18 12:59 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2003-12-10 15:10:42 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Daniel Berrange 2003-11-13 11:21:08 EST
Description of problem:
When attempting to add a control to a FormItem, errors are thrown.

Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1. Create a Form item
2. Attempt to add a 'Text field'
3.
  
Actual results:
com.arsdigita.bebop.FormProcessException: cannot find label for
WidgetLabel
	at
com.arsdigita.formbuilder.ui.editors.WidgetLabelForm.processWidgets(WidgetLabelForm.java:127)
	at
com.arsdigita.formbuilder.ui.editors.TextFieldForm.processWidgets(TextFieldForm.java:151)
	at
com.arsdigita.formbuilder.ui.editors.WidgetForm$WidgetFormProcessListener.process(WidgetForm.java:276)
	at com.arsdigita.bebop.FormSection.fireProcess(FormSection.java:490)
	at com.arsdigita.bebop.FormSection$4.process(FormSection.java:464)
	at com.arsdigita.bebop.FormModel.fireFormProcess(FormModel.java:475)
	at com.arsdigita.bebop.FormModel.process(FormModel.java:342)
	at com.arsdigita.bebop.Form.process(Form.java:440)
	at com.arsdigita.bebop.Form.respond(Form.java:281)
	at com.arsdigita.bebop.PageState.respond(PageState.java:367)
	at com.arsdigita.bebop.Page.process(Page.java:701)
	at com.arsdigita.bebop.Page.process(Page.java:683)
	at com.arsdigita.bebop.Page.buildDocument(Page.java:737)
	at com.arsdigita.cms.dispatcher.CMSPage$1.excurse(CMSPage.java:280)
	at com.arsdigita.cms.CMSExcursion$1.excurse(CMSExcursion.java:80)
	at com.arsdigita.kernel.KernelExcursion.run(KernelExcursion.java:57)
	at com.arsdigita.cms.CMSExcursion.run(CMSExcursion.java:75)
	at com.arsdigita.cms.dispatcher.CMSPage.dispatch(CMSPage.java:294)


Expected results:
Text field is added

Additional info:
Comment 1 Daniel Berrange 2003-11-13 11:46:51 EST
The following fixes the initial problem, by not trying to remove
process listeners from a widget that is newly created (because there
quite obviously aren't any yet!):

====
//core-platform/dev/src/com/arsdigita/formbuilder/ui/editors/WidgetForm.java#7
-
/var/ccm-devel/dev/dan/aplaws-rickshaw/core/src/com/arsdigita/formbuilder/ui/editors/WidgetForm.java
====
--- /tmp/tmp.12659.0    Thu Nov 13 16:47:46 2003
+++
/var/ccm-devel/dev/dan/aplaws-rickshaw/core/src/com/arsdigita/formbuilder/ui/editors/WidgetForm.java
       Thu Nov 13 16:27:31 2003
@@ -200,7 +200,9 @@
         widget.setParameterName(name);
 
         // Clear current validation listeners
+        if (!widget.isNew()) {
         widget.clearValidationListeners();
+        }
         if
(((String)m_required.getValue(pageState)).equals(Boolean.TRUE.toString()))
{
             // Answer is required
             String listenerClassName =
Comment 2 Daniel Berrange 2003-11-13 13:59:46 EST
Fixed on dev in p4 37977. Needs porting back to Troika too.
Comment 3 Archit Shah 2003-11-18 16:45:59 EST
applied to 6.0.x (38130)

Note You need to log in before you can comment on or make changes to this bug.