In testing an upgrade from 4.1.2 to 4.2.2 I've found that formatted %SEARCHes are not showing $formfield() data. e.g.
%SEARCH{ "Back to\:__ ProcurementTracking" casesensitive="on" type="regex" nosearch="on" nototal="on" format="|$formfield(Description)|$topic|"}%
returns this
||ProcurementReq0002|
||ProcurementReq0003|
||ProcurementReq0004|
The topics are found but the Description form field isn't being displayed. This is a simplified example--no matter which fields I try none of them will display. he form data shows up fine on the topics themselves.
This worked fine in 4.1.2. I ported over all my topics for the test, so I haven't yet tried creating a topic with a new form from scratch and %SEARCHing for it.
--
TWiki:Main/BillGunter
- 13 Aug 2008
Ah, this behavior is observed when the 'H' attribute is set on the field in the form definition.
--
TWiki:Main.BillGunter
- 13 Aug 2008
caused by
http://develop.twiki.org/~twiki4/cgi-bin/view/Bugs/Item5668
it seems
--
TWiki:Main.SvenDowideit
- 13 Aug 2008
Ah, it bit me too (broke the BlogAddOn). I propose the following fix:
- when formatted search calls
$meta->renderFormFieldForDisplay
it adds a new attribute showhidden
to the $attrs parameter
- the check for the H attribute in renderForDisplay is skipped if
showhidden
is there
I append the patch
formfield-hiddens-v1.patch for you to test on this topic. Apply via
patch -p0 <formfield-hiddens-v1.patch
And see if it fixes correctly this bug
--
TWiki:Main.ColasNahaboo
- 15 Aug 2008
I cannot see from above that Bill is working on a fix. So being Worked On by Bill seems a wrong assessment.
--
KennethLavrsen - 19 Aug 2008
Well, my patch seem from my test to correct the bug and not introduce other bugs, so I put myself back in Waiting For, and will commit on SVN (trunk & 4.2)
--
TWiki:Main.ColasNahaboo
- 20 Aug 2008
Commited as SVN revision 17458 (trunk) and 17459 (branches/TWikiRelease04x02)
--
TWiki:Main.ColasNahaboo
- 26 Aug 2008
I've recently upgraded from 4.2.0 to 4.2.3 using the TWiki-4.2.3-upgrade.tgz and I'm experiencing the same issue with hidden fields not being addressable by the formfield variable in formatted searches. I've tried the patch listed above, but it didn't seem to make any difference. Is there anything else I should be doing?
I've made a test topic called
JagTest with a form called "FormClient" with the following searches in the topic contents:
Related Services(on): %SEARCH{ "JagTest.*" scope="topic" type="regex" nosearch="on" showhidden="on" nototal="on" format="$topic - $formfield(RelatedServices)" }%
Related Services(1): %SEARCH{ "JagTest.*" scope="topic" type="regex" nosearch="on" showhidden="1" nototal="on" format="$topic - $formfield(RelatedServices)" }%
Related Services: %SEARCH{ "JagTest.*" scope="topic" type="regex" nosearch="on" nototal="on" format="$topic - $formfield(RelatedServices)" }%
I wasn't sure if showhidden was intended to be an internal value or an option to the formatted search so I tried several alternatives.
But I'm still seeing the same behaviour, if the form field
RelatedServices is hidden, the above displays nothing, if it is not hidden, it displays correctly.
After reading the Current State section of the attached form, I've set this back to New. I hope this is OK (I'm new to this bug tracker)
--
TWiki:Main.JeffreyGrace
- 17 Sep 2008
This fix is implemented on our subversion and will be in 4.2.4.
The 4.2.3 was pushed out in a hurry to close a security hole and unfortunately the fix for this known problem was not included in the rushed out version.
The fix checked in can be seen in
TWikirev:17459
I should put this back in waiting for release but I will check the fix first since you say that the patch did not work and I believe the attached patch is the same as the checked in fix.
--
TWiki:Main.KennethLavrsen
- 18 Sep 2008
Code in SVN works. I can display hidden fields with a formatted search.
Waiting for release again.
Sorry we did not get this fix into 4.2.3. Even though I am the release manager I did not get a chance to get this one into the release even though it is on the Known Problems page. But we will make a 4.2.4 soon that picks up this and a couple of other annoyances. Within 1-2 weeks. I promise
--
TWiki:Main.KennethLavrsen
- 18 Sep 2008
And then something happened...
--
TWiki:Main.ArthurClemens
- 01 Dec 2008
The release happened, with release new manager Sopan... Thanks Sopan!
--
TWiki:Main.PeterThoeny
- 09 Dec 2008