You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lenya.apache.org by ed...@apache.org on 2003/08/26 17:53:58 UTC
cvs commit: cocoon-lenya/src/webapp/lenya/content/rc view.xsp versions-screen.xsp
edith 2003/08/26 08:53:58
Modified: src/webapp/lenya/content/rc view.xsp versions-screen.xsp
Log:
fix the rollback/view
get the parameters from the page envelope
Revision Changes Path
1.11 +5 -3 cocoon-lenya/src/webapp/lenya/content/rc/view.xsp
Index: view.xsp
===================================================================
RCS file: /home/cvs/cocoon-lenya/src/webapp/lenya/content/rc/view.xsp,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -r1.10 -r1.11
--- view.xsp 25 Aug 2003 20:48:40 -0000 1.10
+++ view.xsp 26 Aug 2003 15:53:58 -0000 1.11
@@ -19,15 +19,17 @@
<xsp:logic>
- String docId=request.getParameter("documentid");
String rollbackTime=request.getParameter("rollbackTime");
Publication publication = (Publication)<input:get-attribute module="page-envelope" as="object" name="publication"/>;
String rootDir=publication.getEnvironment().getPublicationPath();
String servletContextPath = publication.getServletContext().getCanonicalPath();
- String filename = publication.CONTENT_PATH +"/"+ <input:get-attribute module="page-envelope" as="string" name="area"/> +"/"+ <input:get-attribute module="page-envelope" as="string" name="document-path"/>;
- RCEnvironment rcEnvironment = new RCEnvironment(servletContextPath);
+ String contextPath = publication.CONTENT_PATH;
+ String area = <input:get-attribute module="page-envelope" as="string" name="area"/>;
+ String documentPath = <input:get-attribute module="page-envelope" as="string" name="document-path"/>;
+ String filename = "/" + contextPath + "/" + area + "/" + documentPath;
+ RCEnvironment rcEnvironment = RCEnvironment.getInstance(publication.getServletContext().getAbsolutePath());
String rcmlDirectory = rcEnvironment.getRCMLDirectory();
rcmlDirectory=rootDir+rcmlDirectory;
String backupDirectory = rcEnvironment.getBackupDirectory();
1.13 +2 -2 cocoon-lenya/src/webapp/lenya/content/rc/versions-screen.xsp
Index: versions-screen.xsp
===================================================================
RCS file: /home/cvs/cocoon-lenya/src/webapp/lenya/content/rc/versions-screen.xsp,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -r1.12 -r1.13
--- versions-screen.xsp 23 Jul 2003 13:21:17 -0000 1.12
+++ versions-screen.xsp 26 Aug 2003 15:53:58 -0000 1.13
@@ -18,11 +18,11 @@
<!-- Import Lenya Page Envelope -->
<xsp:logic>
- String docId = request.getParameter("documentid");
+ String docId = <input:get-attribute module="page-envelope" as="string" name="document-id"/>;
<xsp:content><documentId><xsp:expr>docId</xsp:expr></documentId></xsp:content>
Publication publication = (Publication)<input:get-attribute module="page-envelope" as="object" name="publication"/>;
- String filename=publication.getEnvironment().getAuthoringPath() + "/" +docId;
+ String filename=publication.CONTENT_PATH +"/"+ <input:get-attribute module="page-envelope" as="string" name="area"/> +"/"+ <input:get-attribute module="page-envelope" as="string" name="document-path"/>;
<xsp:content><usecase><xsp:expr>request.getParameter("lenya.usecase")</xsp:expr></usecase></xsp:content>
<xsp:content><request_uri><xsp:expr>request.getRequestURI()</xsp:expr></request_uri></xsp:content>
---------------------------------------------------------------------
To unsubscribe, e-mail: lenya-cvs-unsubscribe@cocoon.apache.org
For additional commands, e-mail: lenya-cvs-help@cocoon.apache.org