beehive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Carlin Rogers (JIRA)" <...@beehive.apache.org>
Subject [jira] Updated: (BEEHIVE-863) Passing a FormBean to a popup
Date Fri, 02 Sep 2005 06:42:17 GMT
     [ http://issues.apache.org/jira/browse/BEEHIVE-863?page=all ]

Carlin Rogers updated BEEHIVE-863:
----------------------------------

    Attachment: j863-first-patch.txt

Attaching a patch with a first cut at the implementation for this new feature. The patch includes
changes to the NetUI configurePopup tag, PopupSupport class, and the JavaScript in the javaScript.properties
to add support for passing form fields to a popup window. There is now a new passFormFields
attribute on the configurePopup tag. If this is set to true, then the generated JavaScript
will include a function that takes the form name and then pulls the name/value pairs from
the form fields to include as parameters of the query on the url of the popup window request.

This patch is for post V1. Any ideas for how to best modify this patch to leverage or refactor
existing JavaScript support for url params in the netui-datagrid.js would be great. Also,
to get and use the real/generated form name within the configurePopup tag, I made a local
copy of the HtmlBaseTag.getNearestForm() method. ConfigurePopup does not subclass from HtmlBaseTag
and didn't think it should and I didn't see a
good way yet to avoid the duplication so ideas appreciated here as well.

The patch also includes a test page flow with popups and a testRecorder file. The testRecorder
file may need updating if the generated JavaScript gets tweaked.

Note that this patch builds on top of my patch for BEEHIVE-542 (multiple popup scripts generated).
So this patch also contains those same changes as they are not checked into trunk.

> Passing a FormBean to a popup
> -----------------------------
>
>          Key: BEEHIVE-863
>          URL: http://issues.apache.org/jira/browse/BEEHIVE-863
>      Project: Beehive
>         Type: Improvement
>   Components: NetUI
>     Reporter: Jack Rudnick
>     Assignee: Carlin Rogers
>     Priority: Critical
>  Attachments: j863-first-patch.txt
>
> A popup is currently reached via a nested action, however, you can't pass a FormBean
(and more importantly, its values) from a parent action to the nested action for use in the
popup.  An example of how you may want to use this would be:
> 	>       1) parent form/page has a "To" text field in a form.
> 	>       2) I type in "hello.world@xyz.abc"
> 	>       3) click the button (netui:button popup=true) to trigger the popup in the
parent page
> 	>       4) popup has its own form/page that has a "To" text field.
> 	>       5) When the popup renders, the popups "To" field should be prepopulated with
the "hello .world@xyz.abc" value.
> You can currently pass the values of a popup to the parent, thus you should be able to
go the other way (pass the parent values to the popup) with a given framework way other than
constructing some javascript to do this in a custom manner.  One reason why this probably
doesn't currently work, is when you click the netui:button it doesn't submit the parent form,
thus the form and values don't get persisted for use by the popup.
> This is currently a very limiting shortcoming of using popups.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


Mime
View raw message