This is an automated email from the ASF dual-hosted git repository.
dklco pushed a commit to branch master
in repository
https://gitbox.apache.org/repos/asf/sling-org-apache-sling-app-cms.git
The following commit(s) were added to refs/heads/master by this push:
new a977829 Fixing SLING-7946 adding the Load content console into the
tools menu and adding a label showing the suffix to both
a977829 is described below
commit a977829402477a3c642b470e31db6f21f8cbb9e7
Author: Dan Klco <[email protected]>
AuthorDate: Mon Sep 24 13:57:27 2018 -0400
Fixing SLING-7946 adding the Load content console into the tools menu and
adding a label showing the suffix to both
---
.../libs/sling-cms/content/admin/bulkreplace.json | 6 +
.../libs/sling-cms/content/admin/loadcontent.json | 123 ++++++-----
.../jcr_root/libs/sling-cms/content/start.json | 231 +++++++++++----------
3 files changed, 194 insertions(+), 166 deletions(-)
diff --git
a/ui/src/main/resources/jcr_root/libs/sling-cms/content/admin/bulkreplace.json
b/ui/src/main/resources/jcr_root/libs/sling-cms/content/admin/bulkreplace.json
index 3d512b5..55cf189 100644
---
a/ui/src/main/resources/jcr_root/libs/sling-cms/content/admin/bulkreplace.json
+++
b/ui/src/main/resources/jcr_root/libs/sling-cms/content/admin/bulkreplace.json
@@ -21,6 +21,12 @@
"target": "/cms/admin/bulkreplace.html",
"type": "nt:hierarchyNode",
"content": {
+ "jcr:primaryType": "nt:unstructured",
+ "suffixlabel": {
+ "jcr:primaryType": "nt:unstructured",
+ "sling:resourceType":
"sling-cms/components/editor/fields/suffixlabel",
+ "label": "Replacing properties under path:"
+ },
"slingform": {
"jcr:primaryType": "nt:unstructured",
"sling:resourceType":
"sling-cms/components/editor/slingform",
diff --git
a/ui/src/main/resources/jcr_root/libs/sling-cms/content/admin/loadcontent.json
b/ui/src/main/resources/jcr_root/libs/sling-cms/content/admin/loadcontent.json
index 993bc08..d1ed998 100644
---
a/ui/src/main/resources/jcr_root/libs/sling-cms/content/admin/loadcontent.json
+++
b/ui/src/main/resources/jcr_root/libs/sling-cms/content/admin/loadcontent.json
@@ -1,55 +1,72 @@
{
- "jcr:primaryType": "sling:Page",
- "jcr:content": {
- "sling:resourceType": "sling-cms/components/pages/base",
- "jcr:title": "Load Content",
- "jcr:primaryType": "nt:unstructured",
- "container": {
- "jcr:primaryType": "nt:unstructured",
- "sling:resourceType":
"sling-cms/components/general/container",
- "richtext": {
- "jcr:primaryType": "nt:unstructured",
- "sling:resourceType":
"sling-cms/components/general/richtext",
- "text": "<h3>Load Content</h3>"
- },
- "slingform": {
- "jcr:primaryType": "nt:unstructured",
- "sling:resourceType":
"sling-cms/components/editor/slingform",
- "button": "Load Content",
- "fields": {
- "jcr:primaryType": "nt:unstructured",
- "sling:resourceType":
"sling-cms/components/general/container",
- "operation": {
- "jcr:primaryType":
"nt:unstructured",
- "sling:resourceType":
"sling-cms/components/editor/fields/hidden",
- "name": ":operation",
- "value": "import"
- },
- "replaceProperties": {
- "jcr:primaryType":
"nt:unstructured",
- "sling:resourceType":
"sling-cms/components/editor/fields/hidden",
- "name": ":replaceProperties",
- "value": "true"
- },
- "contentType": {
- "jcr:primaryType":
"nt:unstructured",
- "sling:resourceType":
"sling-cms/components/editor/fields/hidden",
- "name": ":contentType",
- "value": "json"
- },
- "content": {
- "jcr:primaryType":
"nt:unstructured",
- "sling:resourceType":
"sling-cms/components/editor/fields/textarea",
- "name": ":content"
- },
- "format": {
- "jcr:primaryType":
"nt:unstructured",
- "sling:resourceType":
"sling-cms/components/editor/fields/button",
- "label": "Format",
- "onclick": "javascript:try
{$('textarea').val(JSON.stringify(JSON.parse($('textarea').val()), null, 2));}
catch (e) { alert('Unable to parse Content JSON'); };return false;"
- }
- }
- }
- }
- }
+ "jcr:primaryType": "sling:Page",
+ "jcr:content": {
+ "sling:resourceType": "sling-cms/components/pages/base",
+ "jcr:title": "Load Content",
+ "jcr:primaryType": "nt:unstructured",
+ "container": {
+ "jcr:primaryType": "nt:unstructured",
+ "sling:resourceType": "sling-cms/components/general/container",
+ "richtext": {
+ "jcr:primaryType": "nt:unstructured",
+ "sling:resourceType": "sling-cms/components/general/richtext",
+ "text": "<h3>Load Content</h3>"
+ },
+ "suffixswitch": {
+ "jcr:primaryType": "nt:unstructured",
+ "sling:resourceType": "sling-cms/components/cms/suffixswitch",
+ "base": "/content",
+ "button": "Go",
+ "label": "Path",
+ "target": "/cms/admin/loadcontent.html",
+ "type": "nt:hierarchyNode",
+ "content": {
+ "jcr:primaryType": "nt:unstructured",
+ "suffixlabel": {
+ "jcr:primaryType": "nt:unstructured",
+ "sling:resourceType":
"sling-cms/components/editor/fields/suffixlabel",
+ "label": "Loading content under path"
+ },
+ "slingform": {
+ "jcr:primaryType": "nt:unstructured",
+ "sling:resourceType":
"sling-cms/components/editor/slingform",
+ "button": "Load Content",
+ "fields": {
+ "jcr:primaryType": "nt:unstructured",
+ "sling:resourceType":
"sling-cms/components/general/container",
+ "operation": {
+ "jcr:primaryType": "nt:unstructured",
+ "sling:resourceType":
"sling-cms/components/editor/fields/hidden",
+ "name": ":operation",
+ "value": "import"
+ },
+ "replaceProperties": {
+ "jcr:primaryType": "nt:unstructured",
+ "sling:resourceType":
"sling-cms/components/editor/fields/hidden",
+ "name": ":replaceProperties",
+ "value": "true"
+ },
+ "contentType": {
+ "jcr:primaryType": "nt:unstructured",
+ "sling:resourceType":
"sling-cms/components/editor/fields/hidden",
+ "name": ":contentType",
+ "value": "json"
+ },
+ "content": {
+ "jcr:primaryType": "nt:unstructured",
+ "sling:resourceType":
"sling-cms/components/editor/fields/textarea",
+ "name": ":content"
+ },
+ "format": {
+ "jcr:primaryType": "nt:unstructured",
+ "sling:resourceType":
"sling-cms/components/editor/fields/button",
+ "label": "Format",
+ "onclick": "javascript:try
{$('textarea').val(JSON.stringify(JSON.parse($('textarea').val()), null, 2));}
catch (e) { alert('Unable to parse Content JSON'); };return false;"
+ }
+ }
+ }
+ }
+ }
+ }
+ }
}
\ No newline at end of file
diff --git a/ui/src/main/resources/jcr_root/libs/sling-cms/content/start.json
b/ui/src/main/resources/jcr_root/libs/sling-cms/content/start.json
index 1f95845..d8bce41 100644
--- a/ui/src/main/resources/jcr_root/libs/sling-cms/content/start.json
+++ b/ui/src/main/resources/jcr_root/libs/sling-cms/content/start.json
@@ -1,115 +1,120 @@
{
- "jcr:primaryType": "sling:Page",
- "jcr:content": {
- "sling:resourceType": "sling-cms/components/pages/base",
- "jcr:title": "Start",
- "jcr:primaryType": "nt:unstructured",
- "sling:vanityPath": "/cms",
- "sling:redirect": true,
- "center": true,
- "container": {
- "jcr:primaryType": "nt:unstructured",
- "sling:resourceType":
"sling-cms/components/general/container",
- "richtext": {
- "jcr:primaryType": "nt:unstructured",
- "sling:resourceType":
"sling-cms/components/general/richtext",
- "text": "<h2>Welcome to the Apache Sling
CMS!<\/h2><p>This is a full-featured Content Management System built using the
Apache Sling Framework! To begin, select Site on the left to add your first
website.<\/p>"
- }
- },
- "nav": {
- "jcr:primaryType": "nt:unstructured",
- "sling:resourceType":
"sling-cms/components/general/container",
- "sitenav": {
- "jcr:primaryType": "nt:unstructured",
- "sling:resourceType":
"sling-cms/components/cms/contentnav",
- "createPath":
"/cms/site/creategroup.html/content",
- "createTitle": "Site Group",
- "prefix": "/cms/site",
- "itemPrefix": "/cms/site/sites.html",
- "query": "SELECT * FROM [sling:OrderedFolder]
AS s WHERE ISCHILDNODE(s,'/content') ORDER BY NAME()",
- "title": "Sites"
- },
- "staticnav": {
- "jcr:primaryType": "nt:unstructured",
- "sling:resourceType":
"sling-cms/components/cms/contentnav",
- "createPath": "/cms/folder/create.html/static",
- "createTitle": "Folder",
- "prefix": "/cms/static",
- "itemPrefix": "/cms/static/content.html",
- "query": "SELECT * FROM [sling:Folder] AS s
WHERE ISCHILDNODE(s,'/static') ORDER BY NAME()",
- "title": "Static Content"
- },
- "taxonomynav": {
- "jcr:primaryType": "nt:unstructured",
- "sling:resourceType":
"sling-cms/components/cms/contentnav",
- "createPath":
"/cms/taxonomy/create.html/etc/taxonomy",
- "prefix": "/cms/taxonomy",
- "itemPrefix": "/cms/taxonomy/list.html",
- "query": "SELECT * FROM [sling:Taxonomy] AS s
WHERE ISCHILDNODE(s,'/etc/taxonomy') ORDER BY NAME()",
- "title": "Taxonomy"
- },
- "configurationnav": {
- "jcr:primaryType": "nt:unstructured",
- "sling:resourceType":
"sling-cms/components/cms/contentnav",
- "createPath": "/cms/folder/create.html/conf",
- "prefix": "/cms/config",
- "itemPrefix": "/cms/config/list.html",
- "query": "SELECT * FROM [sling:OrderedFolder]
AS s WHERE ISCHILDNODE(s,'/conf') ORDER BY NAME()",
- "title": "Configuration"
- },
- "usergeneratednav": {
- "jcr:primaryType": "nt:unstructured",
- "sling:resourceType":
"sling-cms/components/cms/contentnav",
- "createPath":
"/cms/folder/create.html/etc/usergenerated",
- "createFolder": "Bucket",
- "prefix": "/cms/usergenerated",
- "itemPrefix": "/cms/usergenerated/content.html",
- "query": "SELECT * FROM [sling:OrderedFolder]
AS s WHERE ISCHILDNODE(s,'/etc/usergenerated') ORDER BY NAME()",
- "title": "User Generated"
- },
- "toolsnav": {
- "jcr:primaryType": "nt:unstructured",
- "sling:resourceType":
"sling-cms/components/cms/staticnav",
- "title": "Tools",
- "links": {
- "jcr:primaryType": "nt:unstructured",
- "bulkreplace": {
- "jcr:primaryType":
"nt:unstructured",
- "link":
"/cms/admin/bulkreplace.html",
- "text": "Bulk Replace"
- },
- "contentpackages": {
- "jcr:primaryType":
"nt:unstructured",
- "link": "/bin/packages.html",
- "text": "Content Packages"
- },
- "i18n": {
- "jcr:primaryType":
"nt:unstructured",
- "link":
"/cms/i18n/dictionaries.html/etc/i18n",
- "text": "Internationalization
(i18n)"
- },
- "mappings": {
- "jcr:primaryType":
"nt:unstructured",
- "link":
"/cms/mappings/list.html/etc/map",
- "text": "Mappings"
- },
- "nodebrowser": {
- "jcr:primaryType":
"nt:unstructured",
- "link": "/bin/browser.html",
- "text": "Node Browser"
- },
- "systemconsole": {
- "jcr:primaryType":
"nt:unstructured",
- "link": "/system/console",
- "text": "System Console"
- },
- "usersgroups": {
- "jcr:primaryType":
"nt:unstructured",
- "link": "/bin/users.html",
- "text": "Users & Groups"
- }
- }
- }
- }
- }
+ "jcr:primaryType": "sling:Page",
+ "jcr:content": {
+ "sling:resourceType": "sling-cms/components/pages/base",
+ "jcr:title": "Start",
+ "jcr:primaryType": "nt:unstructured",
+ "sling:vanityPath": "/cms",
+ "sling:redirect": true,
+ "center": true,
+ "container": {
+ "jcr:primaryType": "nt:unstructured",
+ "sling:resourceType": "sling-cms/components/general/container",
+ "richtext": {
+ "jcr:primaryType": "nt:unstructured",
+ "sling:resourceType": "sling-cms/components/general/richtext",
+ "text": "<h2>Welcome to the Apache Sling CMS!<\/h2><p>This is
a full-featured Content Management System built using the Apache Sling
Framework! To begin, select Site on the left to add your first website.<\/p>"
+ }
+ },
+ "nav": {
+ "jcr:primaryType": "nt:unstructured",
+ "sling:resourceType": "sling-cms/components/general/container",
+ "sitenav": {
+ "jcr:primaryType": "nt:unstructured",
+ "sling:resourceType": "sling-cms/components/cms/contentnav",
+ "createPath": "/cms/site/creategroup.html/content",
+ "createTitle": "Site Group",
+ "prefix": "/cms/site",
+ "itemPrefix": "/cms/site/sites.html",
+ "query": "SELECT * FROM [sling:OrderedFolder] AS s WHERE
ISCHILDNODE(s,'/content') ORDER BY NAME()",
+ "title": "Sites"
+ },
+ "staticnav": {
+ "jcr:primaryType": "nt:unstructured",
+ "sling:resourceType": "sling-cms/components/cms/contentnav",
+ "createPath": "/cms/folder/create.html/static",
+ "createTitle": "Folder",
+ "prefix": "/cms/static",
+ "itemPrefix": "/cms/static/content.html",
+ "query": "SELECT * FROM [sling:Folder] AS s WHERE
ISCHILDNODE(s,'/static') ORDER BY NAME()",
+ "title": "Static Content"
+ },
+ "taxonomynav": {
+ "jcr:primaryType": "nt:unstructured",
+ "sling:resourceType": "sling-cms/components/cms/contentnav",
+ "createPath": "/cms/taxonomy/create.html/etc/taxonomy",
+ "prefix": "/cms/taxonomy",
+ "itemPrefix": "/cms/taxonomy/list.html",
+ "query": "SELECT * FROM [sling:Taxonomy] AS s WHERE
ISCHILDNODE(s,'/etc/taxonomy') ORDER BY NAME()",
+ "title": "Taxonomy"
+ },
+ "configurationnav": {
+ "jcr:primaryType": "nt:unstructured",
+ "sling:resourceType": "sling-cms/components/cms/contentnav",
+ "createPath": "/cms/folder/create.html/conf",
+ "prefix": "/cms/config",
+ "itemPrefix": "/cms/config/list.html",
+ "query": "SELECT * FROM [sling:OrderedFolder] AS s WHERE
ISCHILDNODE(s,'/conf') ORDER BY NAME()",
+ "title": "Configuration"
+ },
+ "usergeneratednav": {
+ "jcr:primaryType": "nt:unstructured",
+ "sling:resourceType": "sling-cms/components/cms/contentnav",
+ "createPath": "/cms/folder/create.html/etc/usergenerated",
+ "createFolder": "Bucket",
+ "prefix": "/cms/usergenerated",
+ "itemPrefix": "/cms/usergenerated/content.html",
+ "query": "SELECT * FROM [sling:OrderedFolder] AS s WHERE
ISCHILDNODE(s,'/etc/usergenerated') ORDER BY NAME()",
+ "title": "User Generated"
+ },
+ "toolsnav": {
+ "jcr:primaryType": "nt:unstructured",
+ "sling:resourceType": "sling-cms/components/cms/staticnav",
+ "title": "Tools",
+ "links": {
+ "jcr:primaryType": "nt:unstructured",
+ "bulkreplace": {
+ "jcr:primaryType": "nt:unstructured",
+ "link": "/cms/admin/bulkreplace.html",
+ "text": "Bulk Replace"
+ },
+ "contentpackages": {
+ "jcr:primaryType": "nt:unstructured",
+ "link": "/bin/packages.html",
+ "text": "Content Packages"
+ },
+ "i18n": {
+ "jcr:primaryType": "nt:unstructured",
+ "link": "/cms/i18n/dictionaries.html/etc/i18n",
+ "text": "Internationalization (i18n)"
+ },
+ "loadcontent": {
+ "jcr:primaryType": "nt:unstructured",
+ "link": "/cms/admin/loadcontent.html",
+ "text": "Load Content"
+ },
+ "mappings": {
+ "jcr:primaryType": "nt:unstructured",
+ "link": "/cms/mappings/list.html/etc/map",
+ "text": "Mappings"
+ },
+ "nodebrowser": {
+ "jcr:primaryType": "nt:unstructured",
+ "link": "/bin/browser.html",
+ "text": "Node Browser"
+ },
+ "systemconsole": {
+ "jcr:primaryType": "nt:unstructured",
+ "link": "/system/console",
+ "text": "System Console"
+ },
+ "usersgroups": {
+ "jcr:primaryType": "nt:unstructured",
+ "link": "/bin/users.html",
+ "text": "Users & Groups"
+ }
+ }
+ }
+ }
+ }
}
\ No newline at end of file