cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Wadim Kruse <z-c...@web.de>
Subject portal + cforms + coplet links
Date Wed, 06 Sep 2006 19:57:14 GMT

Hi folks,

I would like to pass some information from one coplet to another. I've read
that one possible solution to achieve this is by using coplet links. I've
tried it, but it doesn't work. When I click the link, the coplet with the
link is redisplayed.

This is the coplet with the link:

	<coplet-data id="Programme" name="standard">
		<title>Programme</title>
		<coplet-base-data>URICoplet</coplet-base-data>
		<attribute>
			<name>buffer</name>
			<value xsi:type="java:java.lang.Boolean"
				xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
				true
			</value>
		</attribute>
		<attribute>
			<name>handleParameters</name>
			<value xsi:type="java:java.lang.Boolean"
				xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
				true
			</value>
		</attribute>
		<attribute>
			<name>uri</name>
			<value xsi:type="java:java.lang.String">
				cocoon:/coplets/moped/ProgrammeDescriptions
			</value>
		</attribute>
		<aspect>
			<name>mandatory</name>
			<value xsi:type="java:java.lang.Boolean">true</value>
		</aspect>
	</coplet-data>

This is the target coplet:

<coplet-data id="CreateNewProgramme" name="standard">
		<title>Create New Programme</title>
		<coplet-base-data>CachingURICoplet</coplet-base-data>
		<attribute>
			<name>buffer</name>
			<value xsi:type="java:java.lang.Boolean"
				xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
				true
			</value>
		</attribute>
		<attribute>
			<name>handleParameters</name>
			<value xsi:type="java:java.lang.Boolean"
				xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
				true
			</value>
		</attribute>
		<attribute>
			<name>uri</name>
			<value xsi:type="java:java.lang.String">
				cocoon:/coplets/html/application
			</value>
		</attribute>
		<attribute>
			<name>temporary:application-uri</name>
			<value xsi:type="java:java.lang.String"
				xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
				cocoon://portal/coplets/moped/ProgrammeDescriptions/cform
			</value>
		</attribute>
		<aspect>
			<name>mandatory</name>
			<value xsi:type="java:java.lang.Boolean">true</value>
		</aspect>
	</coplet-data>

The copletinstancedata and the layout of the target coplet:

<?xml version="1.0" encoding="UTF-8"?>
<coplets>
   <coplet-instance-data id="Programme-1" name="standard">
      <coplet-data>Programme</coplet-data>
   </coplet-instance-data>
    <coplet-instance-data id="CreateNewProgramme-1" name="standard">
      <coplet-data>CreateNewProgramme</coplet-data>
   </coplet-instance-data>
</coplets>

<?xml version="1.0" encoding="UTF-8"?>
<composite-layout name="tab" id="maintab">
	<named-item name="Programme Descriptions">
	<composite-layout name="column">
      <item>
        <coplet-layout name="coplet">
          <coplet-instance-data>Programme-1</coplet-instance-data>
        </coplet-layout>
      </item>
    </composite-layout>
    </named-item>
	<named-item name="Create New Programme">
		<coplet-layout name="coplet">
			<coplet-instance-data>CreateNewProgramme-1</coplet-instance-data>
		</coplet-layout>
	</named-item>
</composite-layout>

The link is:
<cl:link path="attributes/fileName" value="{concat($ProgrammeCode,'.xml')}"
coplet="CreateNewProgramme-1">
      images/document.gif 
</cl:link>

The portal.log says:

WARN    (2006-09-06) 20:49.06:257   [portal] (/cocoon/portal/portal)
http-8080-Processor25/DefaultEventManager: Exception during event
dispatching on receiver
org.apache.cocoon.portal.event.subscriber.impl.DefaultJXPathEventSubscriber@121321f5
and event org.apache.cocoon.portal.event.impl.JXPathEvent@2ac02d83
java.lang.reflect.InvocationTargetException
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:585)
	at
org.apache.cocoon.portal.event.impl.DefaultEventManager.send(DefaultEventManager.java:363)
	at
org.apache.cocoon.portal.event.aspect.impl.RequestParameterEventAspect.process(RequestParameterEventAspect.java:56)
	at
org.apache.cocoon.portal.event.aspect.impl.RequestParameterEventAspect.process(RequestParameterEventAspect.java:82)
	at
org.apache.cocoon.portal.event.impl.DefaultEventAspectContext.invokeNext(DefaultEventAspectContext.java:60)
	at
org.apache.cocoon.portal.wsrp.adapter.WSRPEventAspect.process(WSRPEventAspect.java:67)
	at
org.apache.cocoon.portal.event.impl.DefaultEventAspectContext.invokeNext(DefaultEventAspectContext.java:60)
	at
org.apache.cocoon.portal.event.aspect.impl.FullScreenCopletEventAspect.process(FullScreenCopletEventAspect.java:101)
	at
org.apache.cocoon.portal.event.impl.DefaultEventAspectContext.invokeNext(DefaultEventAspectContext.java:60)
	at
org.apache.cocoon.portal.event.aspect.impl.AbstractContentEventAspect.process(AbstractContentEventAspect.java:132)
	at
org.apache.cocoon.portal.event.impl.DefaultEventAspectContext.invokeNext(DefaultEventAspectContext.java:60)
	at
org.apache.cocoon.portal.event.aspect.impl.AbstractContentEventAspect.process(AbstractContentEventAspect.java:132)
	at
org.apache.cocoon.portal.event.impl.DefaultEventAspectContext.invokeNext(DefaultEventAspectContext.java:60)
	at
org.apache.cocoon.portal.event.aspect.impl.NoClientCachingEventAspect.process(NoClientCachingEventAspect.java:52)
	at
org.apache.cocoon.portal.event.impl.DefaultEventAspectContext.invokeNext(DefaultEventAspectContext.java:60)
	at
org.apache.cocoon.portal.event.impl.DefaultEventManager.processEvents(DefaultEventManager.java:312)
	at
org.apache.cocoon.portal.impl.PortalManagerImpl.prepare(PortalManagerImpl.java:156)
	at
org.apache.cocoon.portal.impl.DefaultPortalManagerAspectContext.invokeNext(DefaultPortalManagerAspectContext.java:62)
	at
org.apache.cocoon.portal.wsrp.adapter.WSRPAdapter.prepare(WSRPAdapter.java:734)
	at
org.apache.cocoon.portal.impl.DefaultPortalManagerAspectContext.invokeNext(DefaultPortalManagerAspectContext.java:62)
	at
org.apache.cocoon.portal.coplet.adapter.impl.PortletAdapter.prepare(PortletAdapter.java:374)
	at
org.apache.cocoon.portal.impl.DefaultPortalManagerAspectContext.invokeNext(DefaultPortalManagerAspectContext.java:62)
	at
org.apache.cocoon.portal.impl.PortalManagerImpl.process(PortalManagerImpl.java:116)
	at
org.apache.cocoon.portal.generation.PortalGenerator.generate(PortalGenerator.java:79)
	at
org.apache.cocoon.components.pipeline.AbstractProcessingPipeline.processXMLPipeline(AbstractProcessingPipeline.java:579)
	at
org.apache.cocoon.components.pipeline.impl.AbstractCachingProcessingPipeline.processXMLPipeline(AbstractCachingProcessingPipeline.java:282)
	at
org.apache.cocoon.components.pipeline.AbstractProcessingPipeline.process(AbstractProcessingPipeline.java:481)
	at
org.apache.cocoon.components.treeprocessor.sitemap.SerializeNode.invoke(SerializeNode.java:121)
	at
org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:47)
	at
org.apache.cocoon.components.treeprocessor.sitemap.ActTypeNode.invoke(ActTypeNode.java:139)
	at
org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:47)
	at
org.apache.cocoon.components.treeprocessor.sitemap.MatchNode.invoke(MatchNode.java:108)
	at
org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:69)
	at
org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(PipelineNode.java:143)
	at
org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:69)
	at
org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(PipelinesNode.java:93)
	at
org.apache.cocoon.components.treeprocessor.ConcreteTreeProcessor.process(ConcreteTreeProcessor.java:235)
	at
org.apache.cocoon.components.treeprocessor.ConcreteTreeProcessor.process(ConcreteTreeProcessor.java:177)
	at
org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcessor.java:253)
	at
org.apache.cocoon.components.treeprocessor.sitemap.MountNode.invoke(MountNode.java:118)
	at
org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:47)
	at
org.apache.cocoon.components.treeprocessor.sitemap.MatchNode.invoke(MatchNode.java:108)
	at
org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:69)
	at
org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(PipelineNode.java:143)
	at
org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:69)
	at
org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(PipelinesNode.java:93)
	at
org.apache.cocoon.components.treeprocessor.ConcreteTreeProcessor.process(ConcreteTreeProcessor.java:235)
	at
org.apache.cocoon.components.treeprocessor.ConcreteTreeProcessor.process(ConcreteTreeProcessor.java:177)
	at
org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcessor.java:253)
	at org.apache.cocoon.Cocoon.process(Cocoon.java:697)
	at org.apache.cocoon.servlet.CocoonServlet.service(CocoonServlet.java:1154)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
	at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
	at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
	at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
	at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
	at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
	at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
	at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
	at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
	at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
	at
org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
	at
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
	at
org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
	at
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
	at java.lang.Thread.run(Thread.java:595)
Caused by: org.apache.commons.jxpath.JXPathException: Exception trying to
set value with xpath attributes/fileName; Cannot set property
/attributes/fileName, path does not match a changeable location
	at
org.apache.commons.jxpath.ri.JXPathContextReferenceImpl.setValue(JXPathContextReferenceImpl.java:421)
	at
org.apache.commons.jxpath.ri.JXPathContextReferenceImpl.setValue(JXPathContextReferenceImpl.java:412)
	at
org.apache.cocoon.portal.event.subscriber.impl.DefaultJXPathEventSubscriber.inform(DefaultJXPathEventSubscriber.java:44)
	... 69 more
Caused by: org.apache.commons.jxpath.JXPathException: Cannot set property
/attributes/fileName, path does not match a changeable location
	at
org.apache.commons.jxpath.ri.model.beans.NullPropertyPointer.setValue(NullPropertyPointer.java:95)
	at
org.apache.commons.jxpath.ri.JXPathContextReferenceImpl.setValue(JXPathContextReferenceImpl.java:503)
	at
org.apache.commons.jxpath.ri.JXPathContextReferenceImpl.setValue(JXPathContextReferenceImpl.java:418)
	... 71 more
INFO    (2006-09-06) 20:49.07:300   [portal] (/cocoon/portal/portal)
http-8080-Processor25/AbstractCopletAdapter: Streamed coplet Programme
(instance Programme-1) in 343ms.

Best regards,
Wadim 

(Cocoon 2.1.10-dev, Java 1.5.0_08, Ubuntu Linux 6.06)




-- 
View this message in context: http://www.nabble.com/portal-%2B-cforms-%2B-coplet-links-tf2229236.html#a6178634
Sent from the Cocoon - Users forum at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message