From b9dd44aaee3d6d5dc717b5a4f58bb6e1943b255b Mon Sep 17 00:00:00 2001 From: hjkhjk54 Date: Sun, 24 Jun 2012 01:40:29 +0000 Subject: [PATCH] adding deleting page controller mapping in web.xml and other updates for page management --- productMods/WEB-INF/ontologies/app/menu.n3 | 5 +++-- productMods/WEB-INF/web.xml | 8 ++++++++ .../js/menupage/processInternalClassDataGetterContent.js | 4 ++++ .../edit/forms/pageManagement--classIntersections.ftl | 2 +- 4 files changed, 16 insertions(+), 3 deletions(-) diff --git a/productMods/WEB-INF/ontologies/app/menu.n3 b/productMods/WEB-INF/ontologies/app/menu.n3 index 5b50962b..70876dde 100644 --- a/productMods/WEB-INF/ontologies/app/menu.n3 +++ b/productMods/WEB-INF/ontologies/app/menu.n3 @@ -138,14 +138,15 @@ display:pageListData display:query """ PREFIX display: PREFIX rdfs: - SELECT ?listedPageUri ?listedPageTitle ?listedPageUrlMapping ?listedPageTemplate ?listedPageMenuItem + SELECT ?listedPageUri ?listedPageTitle ?listedPageUrlMapping ?listedPageTemplate ?listedPageMenuItem ?listedPageCannotDeletePage WHERE { ?listedPageUri a display:Page . OPTIONAL{ ?listedPageUri display:urlMapping ?listedPageUrlMapping. } OPTIONAL{ ?listedPageUri display:title ?listedPageTitle. } OPTIONAL {?listedPageUri display:requiresBodyTemplate ?listedPageTemplate .} OPTIONAL {?listedPageMenuItem display:toPage ?listedPageUri .} - } """ . + OPTIONAL {?listedPageUri display:cannotDeletePage ?listedPageCannotDeletePage .} + } ORDER BY ?listedPageTitle """ . #Data getter type labels rdfs:label "Class Group Page" . diff --git a/productMods/WEB-INF/web.xml b/productMods/WEB-INF/web.xml index 2e4ecf23..e0840662 100644 --- a/productMods/WEB-INF/web.xml +++ b/productMods/WEB-INF/web.xml @@ -258,6 +258,14 @@ /postEditCleanupController + + DeletePageController + edu.cornell.mannlib.vitro.webapp.controller.edit.DeletePageController + + + DeletePageController + /deletePageController + MenuManagementController diff --git a/productMods/js/menupage/processInternalClassDataGetterContent.js b/productMods/js/menupage/processInternalClassDataGetterContent.js index 45338752..c8504c2f 100644 --- a/productMods/js/menupage/processInternalClassDataGetterContent.js +++ b/productMods/js/menupage/processInternalClassDataGetterContent.js @@ -63,6 +63,10 @@ var processInternalClassDataGetterContent = { retrieveAdditionalLabelText:function(existingContentObject) { return processClassGroupDataGetterContent.retrieveAdditionalLabelText(existingContentObject); + }, + //Validation on form submit: Check to see that class group has been selected + validateFormSubmission: function(pageContentSection) { + return processClassGroupDataGetterContent.validateFormSubmission(pageContentSection); } } \ No newline at end of file diff --git a/productMods/templates/freemarker/edit/forms/pageManagement--classIntersections.ftl b/productMods/templates/freemarker/edit/forms/pageManagement--classIntersections.ftl index 489d1862..78138fd4 100644 --- a/productMods/templates/freemarker/edit/forms/pageManagement--classIntersections.ftl +++ b/productMods/templates/freemarker/edit/forms/pageManagement--classIntersections.ftl @@ -11,7 +11,7 @@ checked role="input" /> - + ${enableInternalClass} \ No newline at end of file