You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jetspeed-dev@portals.apache.org by ta...@apache.org on 2007/10/29 18:03:48 UTC
svn commit: r589743 - in
/portals/jetspeed-2/trunk/jetspeed-portal-resources/src/main/resources/webapp/WEB-INF/templates/layout/html:
columns/layout.vm tcolumns/layout.vm
Author: taylor
Date: Mon Oct 29 10:03:47 2007
New Revision: 589743
URL: http://svn.apache.org/viewvc?rev=589743&view=rev
Log:
https://issues.apache.org/jira/browse/JS2-590
found a few errors in the move templates, not sure if this is the root cause or not since I cannot reproduce here
Modified:
portals/jetspeed-2/trunk/jetspeed-portal-resources/src/main/resources/webapp/WEB-INF/templates/layout/html/columns/layout.vm
portals/jetspeed-2/trunk/jetspeed-portal-resources/src/main/resources/webapp/WEB-INF/templates/layout/html/tcolumns/layout.vm
Modified: portals/jetspeed-2/trunk/jetspeed-portal-resources/src/main/resources/webapp/WEB-INF/templates/layout/html/columns/layout.vm
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/trunk/jetspeed-portal-resources/src/main/resources/webapp/WEB-INF/templates/layout/html/columns/layout.vm?rev=589743&r1=589742&r2=589743&view=diff
==============================================================================
--- portals/jetspeed-2/trunk/jetspeed-portal-resources/src/main/resources/webapp/WEB-INF/templates/layout/html/columns/layout.vm (original)
+++ portals/jetspeed-2/trunk/jetspeed-portal-resources/src/main/resources/webapp/WEB-INF/templates/layout/html/columns/layout.vm Mon Oct 29 10:03:47 2007
@@ -83,7 +83,11 @@
#end
#getIntProperty($maxLayoutNesting $rootDecorator "max.layout.nesting" 2)
- #if($request.getAttribute("fragmentNestingLevel") < $maxLayoutNesting)
+ #set ($fnl = $request.getAttribute("fragmentNestingLevel"))
+ #if (! $fnl)
+ #set ($fnl = 0)
+ #end
+ #if($fnl < $maxLayoutNesting)
#set($allowAddLayout=true)
#else
#set($allowAddLayout=false)
@@ -168,14 +172,18 @@
####### Take all fragments and apply style
#if($allowChangePortletDecorator)
<div>
- <input type="hidden" name="fragment" value="$f.id">
+ <input type="hidden" name="fragment" value="">
<input type="hidden" name="move" value="">
<input type="hidden" name="remove" value="">
<label for="decorators">$messages.getString("portal.page.editing.portlet.decorator")</label>
<select id="decorators" name="decorators">
<option value=''>
#foreach($pd in $decorationFactory.getPortletDecorations($rc))
- <option value='$pd' #if ($f.Decorator == $pd) SELECTED #end>$pd
+ #set ($fd = "")
+ #if (!$f.Decorator)
+ #set ($fd = $f.Decorator)
+ #end
+ <option value='$pd' #if ($pd == $fd) SELECTED #end>$pd
#end
</select>
<input type="submit" name="jsSubmitTheme" value="$messages.getString("portal.page.editing.changethemeall")"/>
@@ -323,8 +331,12 @@
#if($allowChangePortletDecorator)
<select id='decorator' name='decorator' onChange="$form$dcnt$submit">
<option value=''>
+ #set ($fd = "")
+ #if (!$f.Decorator)
+ #set ($fd = $f.Decorator)
+ #end
#foreach($pd in $decorationFactory.getPortletDecorations($rc))
- <option value='$pd' #if ($pd == $f.Decorator) SELECTED #end>$pd
+ <option value='$pd' #if ($pd == $fd) SELECTED #end>$pd
#end
</select>
#end
@@ -387,4 +399,3 @@
</form>
#parse($myFragment.decoration.footer)
#end
-
Modified: portals/jetspeed-2/trunk/jetspeed-portal-resources/src/main/resources/webapp/WEB-INF/templates/layout/html/tcolumns/layout.vm
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/trunk/jetspeed-portal-resources/src/main/resources/webapp/WEB-INF/templates/layout/html/tcolumns/layout.vm?rev=589743&r1=589742&r2=589743&view=diff
==============================================================================
--- portals/jetspeed-2/trunk/jetspeed-portal-resources/src/main/resources/webapp/WEB-INF/templates/layout/html/tcolumns/layout.vm (original)
+++ portals/jetspeed-2/trunk/jetspeed-portal-resources/src/main/resources/webapp/WEB-INF/templates/layout/html/tcolumns/layout.vm Mon Oct 29 10:03:47 2007
@@ -72,7 +72,11 @@
#end
#getIntProperty($maxLayoutNesting $rootDecorator "max.layout.nesting" 2)
- #if($request.getAttribute("fragmentNestingLevel") < $maxLayoutNesting)
+ #set ($fnl = $request.getAttribute("fragmentNestingLevel"))
+ #if (! $fnl)
+ #set ($fnl = 0)
+ #end
+ #if($fnl < $maxLayoutNesting)
#set($allowAddLayout=true)
#else
#set($allowAddLayout=false)
@@ -228,8 +232,12 @@
#if($allowChangePortletDecorator)
<select id='decorator' name='decorator' onChange="$form$dcnt$submit">
<option value=''>
+ #set ($fd = "")
+ #if (!$f.Decorator)
+ #set ($fd = $f.Decorator)
+ #end
#foreach($pd in $decorationFactory.getPortletDecorations($rc))
- <option value='$pd' #if ($f.Decorator == $pd) SELECTED #end>$pd
+ <option value='$pd' #if ($pd == $fd) SELECTED #end>$pd
#end
</select>
#end
---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-dev-help@portals.apache.org