Rework sample app and update UI
git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1735035 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/docs/content-model2.html b/slingshot/src/main/resources/SLING-INF/content/slingshot/docs/content-model2.html
new file mode 100644
index 0000000..c2fd249
--- /dev/null
+++ b/slingshot/src/main/resources/SLING-INF/content/slingshot/docs/content-model2.html
@@ -0,0 +1,64 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+-->
+<html>
+ <head>
+ <title>Slingshot Content Model</title>
+ </head>
+ <body>
+ <p>
+ Draft description of the Slingshot content model.
+ </p>
+ <ul>
+ <li>/slingshot</li>
+ <li><ul>
+ <li>/users</li>
+ <li><ul>
+ <li><username></li>
+ <li><ul>
+ <li>content</li>
+ <li><ul>
+ <li><stream></li>
+ <li><ul>
+ <li><item></li>
+ <li><ul>
+ <li>images</li>
+ </ul></li>
+ </ul></li>
+ </ul></li>
+ <li>info</li>
+ <li>profile</li>
+ <li>ugc</li>
+ <li><ul>
+ <li><stream></li>
+ <li><ul>
+ <li><item></li>
+ <li><ul>
+ <li>ratings</li>
+ </ul></li>
+ <li><ul>
+ <li>comments</li>
+ </ul></li>
+ </ul></li>
+ </ul></li>
+ </ul></li>
+ </ul></li>
+ </ul></li>
+ </ul>
+ </body>
+</html>
\ No newline at end of file
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1.json b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1.json
index c55522f..3b5357a 100644
--- a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1.json
+++ b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1.json
@@ -1,5 +1,5 @@
{
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/User",
"description":"This is the user space of slingshot1!",
"title":"Welcome to my World"
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content.json b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content.json
deleted file mode 100644
index 79ffc2d..0000000
--- a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content.json
+++ /dev/null
@@ -1,4 +0,0 @@
-{
- "jcr:primaryType":"sling:Folder",
- "sling:resourceType":"slingshot/Content"
-}
\ No newline at end of file
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/info.json b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/info.json
index d4c41a8..8fdd4f8 100644
--- a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/info.json
+++ b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/info.json
@@ -1,3 +1,4 @@
{
- "jcr:primaryType":"sling:Folder"
+ "jcr:primaryType":"sling:Folder",
+ "sling:resourceType":"slingshot/Userinfo"
}
\ No newline at end of file
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/profile.json b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/profile.json
index d4c41a8..fc8627c 100644
--- a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/profile.json
+++ b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/profile.json
@@ -1,3 +1,4 @@
{
- "jcr:primaryType":"sling:Folder"
+ "jcr:primaryType":"sling:Folder",
+ "sling:resourceType":"slingshot/Userprofile"
}
\ No newline at end of file
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel.json b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel.json
similarity index 72%
rename from slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel.json
rename to slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel.json
index 43aae26..5518997 100644
--- a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel.json
+++ b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel.json
@@ -1,5 +1,5 @@
{
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/Category",
"title":"Travel",
"description":"Stuff related to travel."
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel/home.json b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/home.json
similarity index 74%
rename from slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel/home.json
rename to slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/home.json
index 100c49f..658128b 100644
--- a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel/home.json
+++ b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/home.json
@@ -1,5 +1,5 @@
{
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/Item",
"title":"Home Sweet Home",
"description":"This is the place where I live..."
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel/home/images/home.jpg b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/home/images/home.jpg
similarity index 100%
rename from slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel/home/images/home.jpg
rename to slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/home/images/home.jpg
Binary files differ
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/info.json b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/info.json
new file mode 100644
index 0000000..0a8b3a3
--- /dev/null
+++ b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/info.json
@@ -0,0 +1,6 @@
+{
+ "jcr:primaryType":"sling:Folder",
+ "sling:resourceType":"slingshot/Streaminfo",
+ "title":"Travel",
+ "description":"Stuff related to travel."
+}
\ No newline at end of file
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel/pet.json b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/pet.json
similarity index 73%
rename from slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel/pet.json
rename to slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/pet.json
index 34e8f4b..7272b09 100644
--- a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel/pet.json
+++ b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/pet.json
@@ -1,5 +1,5 @@
{
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/Item",
"title":"My Pet",
"description":"Always hungry...but never gets fat"
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel/pet/images/pet.jpg b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/pet/images/pet.jpg
similarity index 100%
rename from slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel/pet/images/pet.jpg
rename to slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/pet/images/pet.jpg
Binary files differ
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel/sea.json b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/sea.json
similarity index 73%
rename from slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel/sea.json
rename to slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/sea.json
index 02785d8..5d8f372 100644
--- a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel/sea.json
+++ b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/sea.json
@@ -1,5 +1,5 @@
{
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/Item",
"title":"The Sea",
"description":"You can see my boat in the distance"
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel/sea/images/see.jpg b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/sea/images/see.jpg
similarity index 100%
rename from slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel/sea/images/see.jpg
rename to slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/sea/images/see.jpg
Binary files differ
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel/view.json b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/view.json
similarity index 73%
rename from slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel/view.json
rename to slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/view.json
index 9f89233..49ab6bc 100644
--- a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel/view.json
+++ b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/view.json
@@ -1,5 +1,5 @@
{
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/Item",
"title":"Nice View",
"description":"A view from the top of my home"
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel/view/images/view.jpg b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/view/images/view.jpg
similarity index 100%
rename from slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/content/travel/view/images/view.jpg
rename to slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot1/travel/view/images/view.jpg
Binary files differ
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2.json b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2.json
index 577623b..db89cbf 100644
--- a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2.json
+++ b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2.json
@@ -1,5 +1,5 @@
{
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/User",
"description":"This is the user space of slingshot2!",
"title":"The Truth Is Out There"
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/aliens.json b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/aliens.json
index 9bb74cf..ea526d7 100644
--- a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/aliens.json
+++ b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/aliens.json
@@ -1,5 +1,5 @@
{
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/Category",
"title":"Aliens",
"description":"Strange creatures from outer space."
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/aliens/strange.json b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/aliens/strange.json
index 38eb6b9..b81407e 100644
--- a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/aliens/strange.json
+++ b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/aliens/strange.json
@@ -1,15 +1,15 @@
{
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/Item",
"title":"Strange",
"description":"This guy looks really strange...",
comments : {
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/Comments"
},
ratings : {
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/Ratings"
}
}
\ No newline at end of file
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/aliens/underwater.json b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/aliens/underwater.json
index 23feeff..11056ad 100644
--- a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/aliens/underwater.json
+++ b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/aliens/underwater.json
@@ -1,15 +1,15 @@
{
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/Item",
"title":"Underwater",
"description":"Surprise down under...",
comments : {
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/Comments"
},
ratings : {
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/Ratings"
}
}
\ No newline at end of file
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/aliens/welcome.json b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/aliens/welcome.json
index e001f47..d4b8a87 100644
--- a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/aliens/welcome.json
+++ b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/aliens/welcome.json
@@ -1,15 +1,15 @@
{
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/Item",
"title":"Welcome",
"description":"This guy looks charming",
comments : {
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/Comments"
},
ratings : {
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/Ratings"
}
}
\ No newline at end of file
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/places.json b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/places.json
index ced782a..4240f84 100644
--- a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/places.json
+++ b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/places.json
@@ -1,5 +1,5 @@
{
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/Category",
"title":"Places",
"description":"Mysterious places around the globe."
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/places/flight.json b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/places/flight.json
index 95a9306..0d8b273 100644
--- a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/places/flight.json
+++ b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/places/flight.json
@@ -1,15 +1,15 @@
{
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/Item",
"title":"Flight Route",
"description":"Looks different from above...",
comments : {
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/Comments"
},
ratings : {
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/Ratings"
}
}
\ No newline at end of file
diff --git a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/places/landing.json b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/places/landing.json
index 1d14edd..5a6b838 100644
--- a/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/places/landing.json
+++ b/slingshot/src/main/resources/SLING-INF/content/slingshot/users/slingshot2/places/landing.json
@@ -1,15 +1,15 @@
{
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/Item",
"title":"Landing Place",
"description":"Something happened here long time ago!",
comments : {
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/Comments"
},
ratings : {
- "jcr:primaryType":"sling:OrderedFolder",
+ "jcr:primaryType":"sling:Folder",
"sling:resourceType":"slingshot/Ratings"
}
}
\ No newline at end of file