You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ode.apache.org by va...@apache.org on 2016/10/19 12:45:59 UTC

[1/3] ode-console git commit: fix fonts.

Repository: ode-console
Updated Branches:
  refs/heads/master 2573d34cc -> 9b0a8d60e


fix fonts.


Project: http://git-wip-us.apache.org/repos/asf/ode-console/repo
Commit: http://git-wip-us.apache.org/repos/asf/ode-console/commit/cd3903b1
Tree: http://git-wip-us.apache.org/repos/asf/ode-console/tree/cd3903b1
Diff: http://git-wip-us.apache.org/repos/asf/ode-console/diff/cd3903b1

Branch: refs/heads/master
Commit: cd3903b1cfe81d3f39e11b45045810de645607e8
Parents: 2573d34
Author: Tammo van Lessen <va...@apache.org>
Authored: Wed Oct 19 14:29:54 2016 +0200
Committer: Tammo van Lessen <va...@apache.org>
Committed: Wed Oct 19 14:34:22 2016 +0200

----------------------------------------------------------------------
 gulp/build.js       |   4 +-
 gulp/wiredep.js     |   8 +--
 src/app/index.scss  | 138 +++++++++++++++++++++++------------------------
 src/app/vendor.scss |   2 +
 src/index.html      |   7 ++-
 5 files changed, 80 insertions(+), 79 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ode-console/blob/cd3903b1/gulp/build.js
----------------------------------------------------------------------
diff --git a/gulp/build.js b/gulp/build.js
index 8dcf45f..74e26e8 100644
--- a/gulp/build.js
+++ b/gulp/build.js
@@ -117,7 +117,7 @@ gulp.task('html', ['wiredep', 'injector:css', 'injector:js', 'partials'], functi
     .pipe($.uglify({preserveComments: $.uglifySaveLicense}))
     .pipe(jsFilter.restore)
     .pipe(cssFilter)
-    .pipe($.replace('bower_components/bootstrap-sass-official/assets/fonts/bootstrap','fonts'))
+    .pipe($.replace('bower_components/bootstrap-sass-official/assets/fonts/bootstrap','styles/fonts'))
     .pipe($.csso())
     .pipe(cssFilter.restore)
     .pipe($.useref())
@@ -147,7 +147,7 @@ gulp.task('fonts', function () {
   return gulp.src($.mainBowerFiles())
     .pipe($.filter('**/*.{eot,svg,ttf,woff,woff2}'))
     .pipe($.flatten())
-    .pipe(gulp.dest('dist/fonts/'));
+    .pipe(gulp.dest('dist/styles/fonts/'));
 });
 
 gulp.task('misc', function () {

http://git-wip-us.apache.org/repos/asf/ode-console/blob/cd3903b1/gulp/wiredep.js
----------------------------------------------------------------------
diff --git a/gulp/wiredep.js b/gulp/wiredep.js
index bab2830..9b75b56 100644
--- a/gulp/wiredep.js
+++ b/gulp/wiredep.js
@@ -1,4 +1,4 @@
-/* 
+/*
  * 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
@@ -6,9 +6,9 @@
  * 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
@@ -27,7 +27,7 @@ gulp.task('wiredep', function () {
   return gulp.src('src/index.html')
     .pipe(wiredep({
       directory: 'bower_components',
-      exclude: [/bootstrap-sass-official/, /bootstrap.css/]
+      exclude: [/bootstrap-sass-official/, /bootstrap.css/, /font-awesome/]
     }))
     .pipe(gulp.dest('src'));
 });

http://git-wip-us.apache.org/repos/asf/ode-console/blob/cd3903b1/src/app/index.scss
----------------------------------------------------------------------
diff --git a/src/app/index.scss b/src/app/index.scss
index fc02bbe..11f6e5e 100644
--- a/src/app/index.scss
+++ b/src/app/index.scss
@@ -1,69 +1,69 @@
-.browsehappy {
-  margin: 0.2em 0;
-  background: #ccc;
-  color: #000;
-  padding: 0.2em 0;
-}
-
-.thumbnail {
-  height: 200px;
-
-  img.pull-right {
-    width: 50px;
-  }
-}
-
-.st-sort-ascent:before{
-    content: '\25B2';
-}
-
-.st-sort-descent:before{
-    content: '\25BC';
-}
-
-.footer {
-  position: absolute;
-  bottom: 0;
-  width: 100%;
-  /* Set the fixed height of the footer here */
-  height: 25px;
-  background-color: #f5f5f5;
-}
-
-.modal-backdrop{
-  bottom: 0
-}
-
-.navbar-nav li:hover {
-    cursor: pointer;
-}
-
-// auto height in ace editor.
-.ace_editor {
-  min-height: 20px;
-  height: auto;
-}
-
-.btn-file {
-    position: relative;
-    overflow: hidden;
-    display: block;
-}
-.btn-file input[type=file] {
-    position: absolute;
-    top: 0;
-    right: 0;
-    min-width: 100%;
-    min-height: 100%;
-    font-size: 100px;
-    text-align: right;
-    filter: alpha(opacity=0);
-    opacity: 0;
-    outline: none;
-    background: white;
-    cursor: inherit;
-    display: block;
-}
-
-// injector
-// endinjector
+.browsehappy {
+  margin: 0.2em 0;
+  background: #ccc;
+  color: #000;
+  padding: 0.2em 0;
+}
+
+.thumbnail {
+  height: 200px;
+
+  img.pull-right {
+    width: 50px;
+  }
+}
+
+.st-sort-ascent:before{
+    content: '\25B2';
+}
+
+.st-sort-descent:before{
+    content: '\25BC';
+}
+
+.footer {
+  position: absolute;
+  bottom: 0;
+  width: 100%;
+  /* Set the fixed height of the footer here */
+  height: 25px;
+  background-color: #f5f5f5;
+}
+
+.modal-backdrop{
+  bottom: 0
+}
+
+.navbar-nav li:hover {
+    cursor: pointer;
+}
+
+// auto height in ace editor.
+.ace_editor {
+  min-height: 20px;
+  height: auto;
+}
+
+.btn-file {
+    position: relative;
+    overflow: hidden;
+    display: block;
+}
+.btn-file input[type=file] {
+    position: absolute;
+    top: 0;
+    right: 0;
+    min-width: 100%;
+    min-height: 100%;
+    font-size: 100px;
+    text-align: right;
+    filter: alpha(opacity=0);
+    opacity: 0;
+    outline: none;
+    background: white;
+    cursor: inherit;
+    display: block;
+}
+
+// injector
+// endinjector

http://git-wip-us.apache.org/repos/asf/ode-console/blob/cd3903b1/src/app/vendor.scss
----------------------------------------------------------------------
diff --git a/src/app/vendor.scss b/src/app/vendor.scss
index 95675a3..fa1e69c 100644
--- a/src/app/vendor.scss
+++ b/src/app/vendor.scss
@@ -1,8 +1,10 @@
 $icon-font-path: "../bower_components/bootstrap-sass-official/assets/fonts/bootstrap/";
 
 $font-family-base: 'Roboto Slab', serif;
+$fa-font-path:        "fonts" !default;
 
 @import '../../bower_components/bootstrap-sass-official/assets/stylesheets/bootstrap';
+@import '../../bower_components/font-awesome/scss/font-awesome';
 
 // custom instance labels
 .label-instance-active {

http://git-wip-us.apache.org/repos/asf/ode-console/blob/cd3903b1/src/index.html
----------------------------------------------------------------------
diff --git a/src/index.html b/src/index.html
index a1bcec8..9332de9 100644
--- a/src/index.html
+++ b/src/index.html
@@ -6,17 +6,16 @@
     <meta name="description" content="">
     <meta name="viewport" content="width=device-width">
     <!-- Place favicon.ico and apple-touch-icon.png in the root directory -->
-    
+
     <!-- build:css({.tmp,src}) styles/vendor.css -->
     <link rel="stylesheet" href="app/vendor.css">
     <!-- bower:css -->
     <link rel="stylesheet" href="../bower_components/ngtoast/dist/ngToast.css" />
-    <link rel="stylesheet" href="../bower_components/font-awesome/css/font-awesome.css" />
     <link rel="stylesheet" href="../bower_components/angular-loading-bar/build/loading-bar.css" />
     <link rel="stylesheet" href="../bower_components/roboto-slab-fontface/roboto-slab-fontface.css" />
     <!-- endbower -->
     <!-- endbuild -->
-    
+
 
     <!-- build:css({.tmp,src}) styles/app.css -->
     <!-- inject:css -->
@@ -67,6 +66,7 @@
     <script src="app/st-select.directive.js"></script>
     <script src="vendor/jquery.xpath.js"></script>
     <script src="vendor/vkbeautify.js"></script>
+    <script src="components/navbar/navbar.controller.js"></script>
     <script src="app/dashboard/dashboard.controller.js"></script>
     <script src="app/process/process.controller.js"></script>
     <script src="app/process/process.service.js"></script>
@@ -76,7 +76,6 @@
     <script src="app/instance/instance.service.js"></script>
     <script src="app/instance/instanceactions.controller.js"></script>
     <script src="app/instance/instancelist.controller.js"></script>
-    <script src="components/navbar/navbar.controller.js"></script>
     <!-- endinject -->
 
     <!-- inject:partials -->


[2/3] ode-console git commit: make ODE API endpoint configurable and set a smart default.

Posted by va...@apache.org.
make ODE API endpoint configurable and set a smart default.


Project: http://git-wip-us.apache.org/repos/asf/ode-console/repo
Commit: http://git-wip-us.apache.org/repos/asf/ode-console/commit/b39327bd
Tree: http://git-wip-us.apache.org/repos/asf/ode-console/tree/b39327bd
Diff: http://git-wip-us.apache.org/repos/asf/ode-console/diff/b39327bd

Branch: refs/heads/master
Commit: b39327bdca78172e413d9ecca5f07875aacb0b9b
Parents: cd3903b
Author: Tammo van Lessen <va...@apache.org>
Authored: Wed Oct 19 14:30:25 2016 +0200
Committer: Tammo van Lessen <va...@apache.org>
Committed: Wed Oct 19 14:38:47 2016 +0200

----------------------------------------------------------------------
 src/app/index.js | 23 +++++++++++++----------
 src/index.html   |  6 ++++++
 2 files changed, 19 insertions(+), 10 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ode-console/blob/b39327bd/src/app/index.js
----------------------------------------------------------------------
diff --git a/src/app/index.js b/src/app/index.js
index 5a5a46c..173a124 100644
--- a/src/app/index.js
+++ b/src/app/index.js
@@ -1,4 +1,4 @@
-/* 
+/*
  * 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
@@ -6,9 +6,9 @@
  * 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
@@ -19,15 +19,18 @@
 
 /*jslint browser: true*/
 /*global vkbeautify:false */
+/*global ApacheOdeConsole:true */
 
 'use strict';
 
+// prepopulate endpoint if not overridden
+ApacheOdeConsole.endpoint = ApacheOdeConsole.endpoint || window.location.protocol + '//' + window.location.host + window.location.pathname;
+ApacheOdeConsole.endpoint = ApacheOdeConsole.endpoint.replace(/\/$/, '');
+
 var underscore = angular.module('underscore', []);
 underscore.factory('_', function() {
   return window._;
-}); 
-
-var rootURI = window.location.toString().split('ode')[0];
+});
 
 angular.module('odeConsole', ['ngAnimate', 'ngSanitize', 'ngRoute', 'ui.bootstrap', 'ngToast', 'smart-table', 'xml', 'angularMoment', 'underscore', 'angular-loading-bar', 'ui.ace', 'naif.base64'])
   .config(function ($httpProvider) {
@@ -62,10 +65,10 @@ angular.module('odeConsole', ['ngAnimate', 'ngSanitize', 'ngRoute', 'ui.bootstra
         redirectTo: '/'
       });
   })
-  .constant('IMAPI_ENDPOINT', rootURI+'ode/processes/InstanceManagement')
-  .constant('PMAPI_ENDPOINT', rootURI+'ode/processes/ProcessManagement')
-  .constant('DSAPI_ENDPOINT', rootURI+'ode/processes/DeploymentService')
-  .constant('POLLING_INTERVAL', '0')
+  .constant('IMAPI_ENDPOINT', ApacheOdeConsole.endpoint + '/processes/InstanceManagement')
+  .constant('PMAPI_ENDPOINT', ApacheOdeConsole.endpoint + '/processes/ProcessManagement')
+  .constant('DSAPI_ENDPOINT', ApacheOdeConsole.endpoint + '/processes/DeploymentService')
+  .constant('POLLING_INTERVAL', '10000')
   .filter('escape', function() {
     return window.encodeURIComponent;
   })

http://git-wip-us.apache.org/repos/asf/ode-console/blob/b39327bd/src/index.html
----------------------------------------------------------------------
diff --git a/src/index.html b/src/index.html
index 9332de9..bca3aaa 100644
--- a/src/index.html
+++ b/src/index.html
@@ -33,6 +33,12 @@
 
     <div ng-view></div>
 
+    <script>
+        /** configure ODE console here: */
+        var ApacheOdeConsole = {
+          endpoint: '' // put ODE's root URL here, e.g. "http://myhost:myport/ode" -- defaults to host/path opened in the browser.
+        }
+    </script>
 
     <!-- build:js scripts/vendor.js -->
     <!-- bower:js -->


[3/3] ode-console git commit: resolve license issue for st-select and add some comments.

Posted by va...@apache.org.
resolve license issue for st-select and add some comments.


Project: http://git-wip-us.apache.org/repos/asf/ode-console/repo
Commit: http://git-wip-us.apache.org/repos/asf/ode-console/commit/9b0a8d60
Tree: http://git-wip-us.apache.org/repos/asf/ode-console/tree/9b0a8d60
Diff: http://git-wip-us.apache.org/repos/asf/ode-console/diff/9b0a8d60

Branch: refs/heads/master
Commit: 9b0a8d60e38c28d4596d606b664a0421f9dbcb0f
Parents: b39327b
Author: Tammo van Lessen <va...@apache.org>
Authored: Wed Oct 19 14:31:03 2016 +0200
Committer: Tammo van Lessen <va...@apache.org>
Committed: Wed Oct 19 14:40:53 2016 +0200

----------------------------------------------------------------------
 src/app/st-select.directive.js | 60 ++++++++++++++++++++-----------------
 1 file changed, 32 insertions(+), 28 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ode-console/blob/9b0a8d60/src/app/st-select.directive.js
----------------------------------------------------------------------
diff --git a/src/app/st-select.directive.js b/src/app/st-select.directive.js
index 3954afe..a030f9b 100644
--- a/src/app/st-select.directive.js
+++ b/src/app/st-select.directive.js
@@ -1,62 +1,66 @@
-/* 
- * 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.
- */
+/*
+ Copyright 2013 Daniel Unfried
+ Modifications 2015 Apache ODE team
+
+ Licensed 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.
+*/
 
- /* https://github.com/wldaunfr/ng-selectall/blob/develop/src/selectall.directive.js */
- 
 'use strict';
 
+/* See https://github.com/wldaunfr/ng-selectall/blob/develop/src/selectall.directive.js */
 angular.module('odeConsole')
   .directive('selectAllCheckbox', ['$filter', function($filter) {
     return {
         restrict: 'E',
         template: '<input type="checkbox">',
         replace: true,
-        link: function(scope, element, iAttrs) {
+        link: function(scope, element, attrs) {
+            // set checked and indeterminate state
             function changeState(checked, indet) {
                 element.prop('checked', checked).prop('indeterminate', indet);
             }
+            // update item checkboxes
             function updateItems() {
-                angular.forEach(scope.$eval(iAttrs.items), function(el) {
-                    el[iAttrs.prop] = element.prop('checked');
+                angular.forEach(scope.$eval(attrs.items), function(el) {
+                    el[attrs.prop] = element.prop('checked');
                 });
             }
             element.bind('change', function() {
+                // update items on change
                 scope.$apply(function() { updateItems(); });
             });
-            scope.$watch(iAttrs.items, function(newValue) {
+            scope.$watch(attrs.items, function(newValue) {
                 var checkedItems = $filter('filter')(newValue, function(el) {
-                    return el[iAttrs.prop];
+                    return el[attrs.prop];
                 });
                 switch(checkedItems ? checkedItems.length : 0) {
-                    case 0:                // none selected
+                    case 0:
+                        // none selected (not checked, not indeterminate)
                         changeState(false, false);
                         break;
-                    case newValue.length:  // all selected
+                    case newValue.length:
+                        // all selected (checked, not indeterminate)
                         changeState(true, false);
                         break;
-                    default:               // some selected
+                    default:
+                        // some selected (not checked, indeterminate)
                         changeState(false, true);
                 }
             }, true);
             scope.$on('$destroy', function() {
               element.off('change');
             });
+            // initially update items
             updateItems();
         }
     };