portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bhardage <bhard...@harding.edu>
Subject Edit Option isn't showing up
Date Fri, 25 Jun 2010 13:53:05 GMT


I'm fairly new to Jetspeed and I'm having some problems getting everything
to work correctly. I'll list off what I consider to be the relevant code
snippets for reference and then explain the problem.

Portlet.xml snippet:

<portlet-app id="Fake" version="1.0">
	<portlet id="MyPortletID">
		<display-name>My Portlet Name</display-name>
		<description>My Portlet Description</description>
			<title>My Portlet Title</title>
			<short-title>My Portlet Title</short-title>
			<keywords>My Portlet Title</keywords>

PSML Snippet:

<?xml version="1.0" encoding="UTF-8"?>
<page id="/administrator/MyPortlet.psml" hidden="false">
	<defaults skin="orange" layout-decorator="pagelayout"
	<fragment id="0685683554585891"
		<fragment id="04487633864220224"
			<property name="row" value="0"/>

Snippet from decorations/portlet/portletlayout/decorator.vm:

#set($decoration = $f.decoration)
#set($actions = $decoration.actions)

<!-- Begin: Fragment: ${f.id} Decoration: ${decoratorId} -->
<table width="100%">
      <div id="${f.id}" class="portletlayout">
        <div class="PTitle">
        #if( $!jetspeed.getTitle($jetspeed.getPortletEntity($f),
$f).length() <= 40)
          <div class="PTitleContent">
            $!jetspeed.getTitle($jetspeed.getPortletEntity($f), $f)
          #if( $!jetspeed.getTitle($jetspeed.getPortletEntity($f),
$f).length() > 40)
    	    #set($header1 = $!jetspeed.getTitle($jetspeed.getPortletEntity($f),
    	    #set($header2 = $!jetspeed.getTitle($jetspeed.getPortletEntity($f),
$f).substring(40, $!jetspeed.getTitle($jetspeed.getPortletEntity($f),
          <div class="PTitleContent">
            $header1 </br> $header2
        #PortletActionBar($decoration)  ##<-- NOTICE THIS LINE

        #if (!$jetspeed.isHidden($f) || $jetspeed.WindowState !=
        <div class="PContent">
<!-- END: Fragment: ${f.id} Decoration: ${decoratorId} -->

Definition of PortletActionBar:

#macro(PortletActionBar $_decoration)
  #set($_actions = $_decoration.actions)
  <div class="PActionBar">
    #foreach ($_action in $_actions)
      < a href="${_action.Action}"
         class="action portlet-action"
        < img src="$request.contextPath/${_action.link}"
alt="${_action.Alt}" border="0" />

Alright, so my problem is that when I load the page, the portlets don't have
an edit icon.

I've put a "<portlet-mode>EDIT</portlet-mode>" statement in the portlet.xml,
and org.Fake.MyClass extends GenericPortlet and overrides the doEdit
function. All the PortletActionBar macro does is print out all the portlets
actions. However, the edit action isn't showing up, and I don't know why.

I'm using Jetspeed 2.1.3. (Also, this is part of an upgrade process from 2.0
to 2.1.3)

Any help or advice would be much appreciated.

View this message in context: http://old.nabble.com/Edit-Option-isn%27t-showing-up-tp28992555p28992555.html
Sent from the Jetspeed - Dev mailing list archive at Nabble.com.

To unsubscribe, e-mail: jetspeed-dev-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-dev-help@portals.apache.org

View raw message