projects
/
gpl
/
argeo-suite.git
/ blobdiff
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Start migrating Suite UI to ACR.
[gpl/argeo-suite.git]
/
org.argeo.app.ui
/
src
/
org
/
argeo
/
app
/
ui
/
SuiteEvent.java
diff --git
a/org.argeo.app.ui/src/org/argeo/app/ui/SuiteEvent.java
b/org.argeo.app.ui/src/org/argeo/app/ui/SuiteEvent.java
index 6eaa60731601257cf9a52c9066340f1bad509e7f..c80be8e877d4dd7a33390a43702e93f676e7be7d 100644
(file)
--- a/
org.argeo.app.ui/src/org/argeo/app/ui/SuiteEvent.java
+++ b/
org.argeo.app.ui/src/org/argeo/app/ui/SuiteEvent.java
@@
-5,6
+5,7
@@
import java.util.Map;
import javax.jcr.Node;
import javax.jcr.Node;
+import org.argeo.api.acr.Content;
import org.argeo.api.cms.CmsEvent;
import org.argeo.jcr.Jcr;
import org.osgi.service.useradmin.User;
import org.argeo.api.cms.CmsEvent;
import org.argeo.jcr.Jcr;
import org.osgi.service.useradmin.User;
@@
-14,15
+15,25
@@
public enum SuiteEvent implements CmsEvent {
openNewPart, refreshPart, switchLayer;
public final static String LAYER = "layer";
openNewPart, refreshPart, switchLayer;
public final static String LAYER = "layer";
-// public final static String NODE_ID = "nodeId";
- public final static String NODE_PATH = "path";
public final static String USERNAME = "username";
public final static String USERNAME = "username";
+
+ // ACR
+ public final static String CONTENT_PATH = "contentPath";
+
+ // JCR
+ public final static String NODE_PATH = "path";
public final static String WORKSPACE = "workspace";
public String getTopicBase() {
return "argeo/suite/ui";
}
public final static String WORKSPACE = "workspace";
public String getTopicBase() {
return "argeo/suite/ui";
}
+ public static Map<String, Object> eventProperties(Content content) {
+ Map<String, Object> properties = new HashMap<>();
+ properties.put(CONTENT_PATH, content.getPath());
+ return properties;
+ }
+
public static Map<String, Object> eventProperties(Node node) {
Map<String, Object> properties = new HashMap<>();
properties.put(NODE_PATH, Jcr.getPath(node));
public static Map<String, Object> eventProperties(Node node) {
Map<String, Object> properties = new HashMap<>();
properties.put(NODE_PATH, Jcr.getPath(node));