You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lenya.apache.org by th...@apache.org on 2007/01/25 23:08:58 UTC
svn commit: r500014 - in /lenya/trunk/src:
java/org/apache/lenya/transaction/UnitOfWorkImpl.java
modules/fckeditor/config/cocoon-xconf/usecases-edit-fckeditor.xconf
modules/fckeditor/sitemap.xmap modules/fckeditor/usecases/fckeditor.jx
Author: thorsten
Date: Thu Jan 25 14:08:57 2007
New Revision: 500014
URL: http://svn.apache.org/viewvc?view=rev&rev=500014
Log:
Bug 41421 - Visiting a locked page adds page to list of work
patch applied. Thanks to Richard Frovarp
Modified:
lenya/trunk/src/java/org/apache/lenya/transaction/UnitOfWorkImpl.java
lenya/trunk/src/modules/fckeditor/config/cocoon-xconf/usecases-edit-fckeditor.xconf
lenya/trunk/src/modules/fckeditor/sitemap.xmap
lenya/trunk/src/modules/fckeditor/usecases/fckeditor.jx
Modified: lenya/trunk/src/java/org/apache/lenya/transaction/UnitOfWorkImpl.java
URL: http://svn.apache.org/viewvc/lenya/trunk/src/java/org/apache/lenya/transaction/UnitOfWorkImpl.java?view=diff&rev=500014&r1=500013&r2=500014
==============================================================================
--- lenya/trunk/src/java/org/apache/lenya/transaction/UnitOfWorkImpl.java (original)
+++ lenya/trunk/src/java/org/apache/lenya/transaction/UnitOfWorkImpl.java Thu Jan 25 14:08:57 2007
@@ -203,7 +203,7 @@
for (int i = 0; i < objects.length; i++) {
if (objects[i] instanceof Transactionable) {
Transactionable t = (Transactionable) objects[i];
- if (t.isCheckedOut()) {
+ if (t.isCheckedOutByUser()) {
t.checkin();
}
if (t.isLocked()) {
Modified: lenya/trunk/src/modules/fckeditor/config/cocoon-xconf/usecases-edit-fckeditor.xconf
URL: http://svn.apache.org/viewvc/lenya/trunk/src/modules/fckeditor/config/cocoon-xconf/usecases-edit-fckeditor.xconf?view=diff&rev=500014&r1=500013&r2=500014
==============================================================================
--- lenya/trunk/src/modules/fckeditor/config/cocoon-xconf/usecases-edit-fckeditor.xconf (original)
+++ lenya/trunk/src/modules/fckeditor/config/cocoon-xconf/usecases-edit-fckeditor.xconf Thu Jan 25 14:08:57 2007
@@ -21,8 +21,9 @@
<component-instance name="fckeditor.edit" logger="lenya.publication"
class="org.apache.lenya.cms.editors.fckeditor.Fckeditor">
<transaction policy="pessimistic"/>
- <!-- <parameter name="tidyConfig" value="fallback://lenya/modules/fckeditor/config/jtidy.properties"/> -->
- <view template="modules/fckeditor/usecases/fckeditor.jx" menu="false"/>
+ <parameter name="tidyConfig" value="fallback://lenya/modules/fckeditor/config/jtidy.properties"/>
+ <view uri="cocoon://modules/fckeditor/fckeditor.open" menu="false"/>
+ <event id="edit" />
</component-instance>
-</xconf>
\ No newline at end of file
+</xconf>
Modified: lenya/trunk/src/modules/fckeditor/sitemap.xmap
URL: http://svn.apache.org/viewvc/lenya/trunk/src/modules/fckeditor/sitemap.xmap?view=diff&rev=500014&r1=500013&r2=500014
==============================================================================
--- lenya/trunk/src/modules/fckeditor/sitemap.xmap (original)
+++ lenya/trunk/src/modules/fckeditor/sitemap.xmap Thu Jan 25 14:08:57 2007
@@ -43,8 +43,29 @@
</map:components>
<map:pipelines>
-
<map:pipeline>
+ <map:match pattern="fckeditor.open" >
+ <map:act type="reserved-checkout">
+ <map:generate type="serverpages" src="fallback://lenya/content/rc/{exception}.xsp">
+ <map:parameter name="user" value="{user}"/>
+ <map:parameter name="filename" value="{filename}"/>
+ <map:parameter name="date" value="{date}"/>
+ <map:parameter name="message" value="{message}"/>
+ </map:generate>
+ <map:transform src="fallback://lenya/xslt/rc/rco-exception.xsl"/>
+ <map:call resource="style-cms-page"/>
+ <map:serialize />
+ </map:act>
+ <map:generate type="jx" src="fallback://lenya/modules/fckeditor/usecases/fckeditor.jx"/>
+ <map:transform type="i18n">
+ <map:parameter name="locale" value="{request:locale}"/>
+ </map:transform>
+ <map:transform type="cinclude"/>
+ <map:transform src="cocoon://lenya-screen.xsl"/>
+ <map:transform src="fallback://lenya/xslt/util/strip_namespaces.xsl"/>
+ <map:serialize type="xhtml"/>
+ </map:match>
+
<map:match pattern="link-show" type="step">
<map:generate src="context://lenya/content/util/empty.xml"/>
<map:transform src="fallback://lenya/modules/fckeditor/xslt/link.xsl" label="content">
Modified: lenya/trunk/src/modules/fckeditor/usecases/fckeditor.jx
URL: http://svn.apache.org/viewvc/lenya/trunk/src/modules/fckeditor/usecases/fckeditor.jx?view=diff&rev=500014&r1=500013&r2=500014
==============================================================================
--- lenya/trunk/src/modules/fckeditor/usecases/fckeditor.jx (original)
+++ lenya/trunk/src/modules/fckeditor/usecases/fckeditor.jx Thu Jan 25 14:08:57 2007
@@ -35,8 +35,14 @@
<page:title>FCKeditor - Sample</page:title>
- <page:body>
- <jx:import uri="fallback://lenya/modules/usecase/templates/messages.jx"/>
+ <jx:choose>
+ <jx:when test="${usecase.hasErrors()}">
+ <page:body>
+ <jx:import uri="fallback://lenya/modules/usecase/templates/messages.jx"/>
+ </page:body>
+ </jx:when>
+ <jx:otherwise>
+ <page:body>
<div class="lenya-box">
<div class="lenya-box-title">Information</div>
@@ -78,5 +84,7 @@
<input type="submit" name="cancel" value="Cancel"/>
</form>
- </page:body>
+ </page:body>
+ </jx:otherwise>
+ </jx:choose>
</page:page>
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@lenya.apache.org
For additional commands, e-mail: commits-help@lenya.apache.org