diff --git a/common/src/main/webapp/js/lightblue-apps.js b/common/src/main/webapp/js/lightblue-apps.js index bbddcf2..a0282af 100644 --- a/common/src/main/webapp/js/lightblue-apps.js +++ b/common/src/main/webapp/js/lightblue-apps.js @@ -265,6 +265,48 @@ function callLightblue(uri, jsonData, method) { }); } +// Show a description of the action +function loadActionDescription(entity) { + if (entity == null || entity == "") { + return; + } + + var desc = ""; + var gitbook = "http://jewzaam.gitbooks.io/lightblue-specifications/content" + + switch(entity) { + case "view": + desc = "View all global information associated with the selected entity."; + break; + case "edit": + desc = "Edit the information of a specific entity."; + break; + case "new": + desc = "Create a new entity by defining new metadata."; + break; + case "version": + desc = "Create a new schema, representing a new version of an existing entity."; + break; + case "roles": + desc = "View all roles and the entities they allow access to. If an entity is slected, view all roles for that entity. If a version is seleceted, view all roles for that entity at the specified version."; + break; + case "summary": + desc = "View an overall summary of the available entities, including their versions."; + break; + } + $('#action-desc').html(desc); +} + function loadVersions() { "use strict"; @@ -342,6 +384,7 @@ $(document).ready(function() { loadVersions(); var entitySelect = $("#entities"); + var actionSelect = $("#actions"); var versionSelect = $("#versions"); var submitButton = $("#load-content-btn"); @@ -350,6 +393,10 @@ $(document).ready(function() { loadEntities(); + actionSelect.change(function() { + loadActionDescription($(this).val()); + }); + entitySelect.change(function() { loadEntityVersions($(this).val()); }); diff --git a/metadata-mgmt/src/main/webapp/index.html b/metadata-mgmt/src/main/webapp/index.html index eb9274b..e03c449 100644 --- a/metadata-mgmt/src/main/webapp/index.html +++ b/metadata-mgmt/src/main/webapp/index.html @@ -82,6 +82,8 @@ +
+