|
From: Leif J. <le...@us...> - 2007-06-10 20:14:36
|
User: leifj
Date: 07/06/10 13:14:37
Modified: andromda-jsf2/src/main/resources/templates/jsf2/flow
ViewPopulator.java.vsl
Log:
fall back to using session if storing in the pageFlowScope doesn\t work
Revision Changes Path
1.3 +6 -1 cartridges/andromda-jsf2/src/main/resources/templates/jsf2/flow/ViewPopulator.java.vsl
Index: ViewPopulator.java.vsl
===================================================================
RCS file: /cvsroot/andromdaplugins/cartridges/andromda-jsf2/src/main/resources/templates/jsf2/flow/ViewPopulator.java.vsl,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -w -r1.2 -r1.3
--- ViewPopulator.java.vsl 11 Dec 2006 13:43:58 -0000 1.2
+++ ViewPopulator.java.vsl 10 Jun 2007 20:14:37 -0000 1.3
@@ -80,6 +80,11 @@
(${managedBeansPackage}.AdfFacesContextWrapper)session.getAttribute("$adfContextAttributeName");
adfContext = contextWrapper != null ? contextWrapper.getCurrentInstance() : null;
form = adfContext != null ? adfContext.getPageFlowScope().get("$view.formKey") : null;
+ if (form == null)
+ {
+ form = session.getAttribute("$view.formKey");
+ session.removeAttribute("$view.formKey");
+ }
#if ($formSerialization)
// - if the form is still null, see if we can get it from a serialized state
if (form == null)
@@ -96,7 +101,7 @@
else
{
// - remove the ADF context in the event that its present
- session.removeAttribute("AndroMDAADFContext");
+ session.removeAttribute("$adfContextAttributeName");
}
}
else
|
|
From: Chad B. <cwb...@us...> - 2008-04-08 01:42:33
|
User: cwbrandon
Date: 08/04/07 18:42:36
Modified: andromda-jsf2/src/main/resources/templates/jsf2/flow
ViewPopulator.java.vsl
Log:
portlet seralization improvements
Revision Changes Path
1.6 +6 -0 cartridges/andromda-jsf2/src/main/resources/templates/jsf2/flow/ViewPopulator.java.vsl
Index: ViewPopulator.java.vsl
===================================================================
RCS file: /cvsroot/andromdaplugins/cartridges/andromda-jsf2/src/main/resources/templates/jsf2/flow/ViewPopulator.java.vsl,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -w -r1.5 -r1.6
--- ViewPopulator.java.vsl 8 Apr 2008 01:20:28 -0000 1.5
+++ ViewPopulator.java.vsl 8 Apr 2008 01:42:35 -0000 1.6
@@ -145,6 +145,12 @@
{
form = ${managedBeansPackage}.JsfUtils.getSerializedForm(session);
}
+ else
+ {
+ // - pass any properties from the serialized form along
+ org.andromda.presentation.jsf2.FormPopulator.populateForm(
+ org.andromda.presentation.jsf2.JsfUtils.getSerializedForm(session), form);
+ }
#end
}
else
|
|
From: Chad B. <cwb...@us...> - 2008-05-28 20:26:27
|
User: cwbrandon
Date: 08/05/28 13:26:35
Modified: andromda-jsf2/src/main/resources/templates/jsf2/flow
ViewPopulator.java.vsl
Log:
add ability to reset view variables
Revision Changes Path
1.9 +3 -0 cartridges/andromda-jsf2/src/main/resources/templates/jsf2/flow/ViewPopulator.java.vsl
Index: ViewPopulator.java.vsl
===================================================================
RCS file: /cvsroot/andromdaplugins/cartridges/andromda-jsf2/src/main/resources/templates/jsf2/flow/ViewPopulator.java.vsl,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -w -r1.8 -r1.9
--- ViewPopulator.java.vsl 15 May 2008 19:30:24 -0000 1.8
+++ ViewPopulator.java.vsl 28 May 2008 20:26:34 -0000 1.9
@@ -188,6 +188,9 @@
if ($readableVariable)
{
request.setAttribute("$variable.name", org.apache.commons.beanutils.PropertyUtils.getProperty(form, "$variable.name"));
+#if ($variable.reset)
+ org.apache.commons.beanutils.PropertyUtils.setProperty(form, "$variable.name", $variable.type.javaNullString);
+#end
}
#end
#foreach ($variable in $view.backingValueVariables)
|
|
From: Chad B. <cwb...@us...> - 2008-07-03 16:32:56
|
User: cwbrandon
Date: 08/07/03 09:33:05
Modified: andromda-jsf2/src/main/resources/templates/jsf2/flow
ViewPopulator.java.vsl
Log:
add comment to resettable view variables
Revision Changes Path
1.10 +1 -0 cartridges/andromda-jsf2/src/main/resources/templates/jsf2/flow/ViewPopulator.java.vsl
Index: ViewPopulator.java.vsl
===================================================================
RCS file: /cvsroot/andromdaplugins/cartridges/andromda-jsf2/src/main/resources/templates/jsf2/flow/ViewPopulator.java.vsl,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -w -r1.9 -r1.10
--- ViewPopulator.java.vsl 28 May 2008 20:26:34 -0000 1.9
+++ ViewPopulator.java.vsl 3 Jul 2008 16:33:04 -0000 1.10
@@ -189,6 +189,7 @@
{
request.setAttribute("$variable.name", org.apache.commons.beanutils.PropertyUtils.getProperty(form, "$variable.name"));
#if ($variable.reset)
+ // reset $variable.name (since the model indicates that it should be reset)
org.apache.commons.beanutils.PropertyUtils.setProperty(form, "$variable.name", $variable.type.javaNullString);
#end
}
|