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 mo...@apache.org on 2003/02/12 22:33:04 UTC
cvs commit: jakarta-jetspeed/src/java/org/apache/jetspeed/modules/actions/portlets PsmlUpdateAction.java
morciuch 2003/02/12 13:33:04
Modified: src/java/org/apache/jetspeed/modules/actions/portlets
PsmlUpdateAction.java
Log:
Fixed Import/Export All messages (see Bugzilla bug# 16976)
Revision Changes Path
1.12 +9 -7 jakarta-jetspeed/src/java/org/apache/jetspeed/modules/actions/portlets/PsmlUpdateAction.java
Index: PsmlUpdateAction.java
===================================================================
RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/modules/actions/portlets/PsmlUpdateAction.java,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -r1.11 -r1.12
--- PsmlUpdateAction.java 8 Nov 2002 10:05:18 -0000 1.11
+++ PsmlUpdateAction.java 12 Feb 2003 21:33:04 -0000 1.12
@@ -657,7 +657,7 @@
{
if (!this.saveDocument(copyTo,doc))
throw new Exception("Failed to save PSML document");
- rundata.setMessage("Profile [" + copyFrom + "] has been saved to disk in [" + copyTo + "]");
+ rundata.addMessage("Profile [" + copyFrom + "] has been saved to disk in [" + copyTo + "]<br>");
}
}
else
@@ -761,9 +761,9 @@
if (!this.saveDocument(copyToFile.toString(), doc)) {
Log.error("Failed to save PSML document for [" + profile.getPath());
} else {
- String msg = "Profile [" + profile.getPath() + "] has been saved to disk in [" + copyToFile.toString() + "]";
+ String msg = "Profile [" + profile.getPath() + "] has been saved to disk in [" + copyToFile.toString() + "]<br>";
Log.info(msg);
- rundata.setMessage(msg);
+ rundata.addMessage(msg);
}
}
}
@@ -1026,7 +1026,7 @@
{
throw new Exception("Failed to load PSML document from disk");
}
- rundata.setMessage("Profile for [" + locator.getPath() + "] has been imported from file [" + copyFrom + "]");
+ rundata.addMessage("Profile for [" + locator.getPath() + "] has been imported from file [" + copyFrom + "]<br>");
setRefreshPsmlFlag(rundata, TRUE);
}
@@ -1095,10 +1095,11 @@
for (Iterator it = files.iterator(); it.hasNext(); )
{
// If error occurs processing one entry, continue on with the others
+ String path = null;
try
{
String psml = ((File) it.next()).getPath();
- String path = psml.substring(copyFrom.length() + 1);
+ path = psml.substring(copyFrom.length() + 1);
ProfileLocator locator = this.mapFileToLocator(path);
PSMLDocument doc = this.loadDocument(psml);
@@ -1122,12 +1123,13 @@
{
throw new Exception("Failed to load PSML document [" + psml + "] from disk");
}
- rundata.setMessage("Profile for [" + locator.getPath() + "] has been imported from file [" + psml + "]");
+ rundata.addMessage("Profile for [" + locator.getPath() + "] has been imported from file [" + psml + "]<br>");
setRefreshPsmlFlag(rundata, TRUE);
}
catch (Exception ouch)
{
Log.error(ouch);
+ rundata.addMessage("ERROR importing file [" + path + "]: " + ouch.toString() + "<br>");
}
}
---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org