You are subscribed to the
{{name}}
+{{desc}}
icon of function | diff --git a/apps/demo/cord-gui/src/main/webapp/app/view/bundle/bundle.js b/apps/demo/cord-gui/src/main/webapp/app/view/bundle/bundle.js index a65214bdd3..c02af54e80 100644 --- a/apps/demo/cord-gui/src/main/webapp/app/view/bundle/bundle.js +++ b/apps/demo/cord-gui/src/main/webapp/app/view/bundle/bundle.js @@ -19,30 +19,12 @@ var $log, $resource; - var before = 'http://localhost:8080/rs/bundle/0', - after = 'http://localhost:8080/rs/bundle/1'; + var url = 'http://localhost:8080/rs/bundle'; - var basic = 'Basic Bundle', - family = 'Family Bundle', - current, which, - avScope; - - function getAvailable(scope) { - var AvailableData, resource; - - AvailableData = $resource(which); - resource = AvailableData.get({}, - // success - function () { - scope.name = resource.bundle.name; - scope.funcs = resource.bundle.functions; - }, - // error - function () { - $log.error('Problem with resource', resource); - }); - $log.debug('Resource received:', resource); - } + var basic = 'basic', + family = 'family', + current, + avCb; angular.module('cordBundle', []) .controller('CordBundleCtrl', ['$log', '$scope', '$resource', @@ -52,29 +34,36 @@ $log = _$log_; $resource = _$resource_; - BundleData = $resource(after); + BundleData = $resource(url); resource = BundleData.get({}, // success function () { + current = resource.bundle.id; $scope.name = resource.bundle.name; - current = $scope.name; + $scope.desc = resource.bundle.desc; $scope.funcs = resource.bundle.functions; - - which = (current === basic) ? after : before; - getAvailable(avScope); + avCb(resource); }, // error function () { $log.error('Problem with resource', resource); }); - $log.debug('Resource received:', resource); $log.debug('Cord Bundle Ctrl has been created.'); }]) .controller('CordAvailable', ['$scope', function ($scope) { - avScope = $scope; + avCb = function (resource) { + $scope.id = (current === basic) ? family : basic; + $scope.bundles = resource.bundles; + + $scope.bundles.forEach(function (bundle) { + if (bundle.id === $scope.id) { + $scope.available = bundle; + } + }); + }; $log.debug('Cord Available Ctrl has been created.'); }]) diff --git a/apps/demo/cord-gui/src/main/webapp/app/view/common/common.css b/apps/demo/cord-gui/src/main/webapp/app/view/common/common.css index 34f16bca91..60cb43bf48 100644 --- a/apps/demo/cord-gui/src/main/webapp/app/view/common/common.css +++ b/apps/demo/cord-gui/src/main/webapp/app/view/common/common.css @@ -30,6 +30,9 @@ p, a, li, th, td { body { background-color: #efefef; } +th, td { + color: rgba(0, 0, 0, 0.8); +} div.container { width: 75%; diff --git a/apps/demo/cord-gui/src/main/webapp/app/view/home/home.css b/apps/demo/cord-gui/src/main/webapp/app/view/home/home.css index 31cfe98f0d..dae525104e 100644 --- a/apps/demo/cord-gui/src/main/webapp/app/view/home/home.css +++ b/apps/demo/cord-gui/src/main/webapp/app/view/home/home.css @@ -15,9 +15,59 @@ */ #home table { - width: 100%; + width: 94%; + table-layout: fixed; + margin-left: 6%; +} +#home table.title { + background: linear-gradient(lightgray, darkgray); + border-top-left-radius: 3px; + border-top-right-radius: 3px; +} +#home table.title th { + text-align: center; +} + +#home table.content { + border-spacing: 0; + border-collapse: collapse; +} +#home table.content th, +#home table.content td { + font-size: 90%; +} +#home table.content th { + background-color: rgba(173, 216, 230, 0.75); +} + +#home table.content tbody tr:nth-of-type(even) { + background-color: rgba(173, 216, 230, 0.25); +} +#home table.content tbody tr:nth-of-type(odd) { + background-color: rgba(173, 216, 230, 0.5); } #home td, #home th { - text-align: center; + text-align: left; + padding: 2%; +} + +#home h3 { + font-weight: normal; + margin-bottom: 4%; +} + +#home h4 { + color: rgb(107, 107, 107); + font-style: italic; + font-weight: normal; + font-size: 90%; + margin-bottom: 1%; +} + +#home p { + font-size: 70%; + color: rgba(0,0,0, 0.8); + text-indent: 20px; + text-align: justify; } diff --git a/apps/demo/cord-gui/src/main/webapp/app/view/home/home.html b/apps/demo/cord-gui/src/main/webapp/app/view/home/home.html index 2d9130efc2..7b95cb075f 100644 --- a/apps/demo/cord-gui/src/main/webapp/app/view/home/home.html +++ b/apps/demo/cord-gui/src/main/webapp/app/view/home/home.html @@ -2,9 +2,16 @@