diff --git a/.travis.yml b/.travis.yml index d1d6fdfb..ca83584e 100644 --- a/.travis.yml +++ b/.travis.yml @@ -29,6 +29,11 @@ script: export OPENSENSEMAP_API_URL=$OPENSENSEMAP_API_URL_DEV; export OPENSENSEMAP_MAPTILES_URL=$OPENSENSEMAP_MAPTILES_URL_DEV; fi + - if [[ -z "$TRAVIS_TAG" && "$TRAVIS_BRANCH" == "workshop" ]]; then + echo "Lets use the workshop envs"; + export OPENSENSEMAP_API_URL=$WORKSHOP_API_URL; + export OPENSENSEMAP_MAPTILES_URL=$OPENSENSEMAP_MAPTILES_URL; + fi - npm run build - docker build -t $IMAGE_NAME:$TRAVIS_BRANCH-temp . diff --git a/Gruntfile.js b/Gruntfile.js index de6bca7a..fcd61fcb 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -175,6 +175,7 @@ module.exports = function (grunt) { '<%= yeoman.app %>/components/calendar.directive.js', '<%= yeoman.app %>/components/badge.directive.js', '<%= yeoman.app %>/components/loader.directive.js', + '<%= yeoman.app %>/components/workshop.directive.js', '<%= yeoman.app %>/components/clipboard.directive.js' ], tasks: [ diff --git a/app/components/workshop.directive.html b/app/components/workshop.directive.html new file mode 100644 index 00000000..ccf19dad --- /dev/null +++ b/app/components/workshop.directive.html @@ -0,0 +1,18 @@ +
+ + +
\ No newline at end of file diff --git a/app/components/workshop.directive.js b/app/components/workshop.directive.js new file mode 100644 index 00000000..45666bc0 --- /dev/null +++ b/app/components/workshop.directive.js @@ -0,0 +1,57 @@ +(function () { + 'use strict'; + + angular + .module('openSenseMapApp') + .directive('osemWorkshop', osemWorkshop); + + osemWorkshop.$inject = []; + function osemWorkshop () { + // Usage: + // + // Creates: + // + var directive = { + templateUrl: 'components/workshop.directive.html', + link: link, + restrict: 'EA', + bindToController: true, + controller: WorkshopController, + controllerAs: 'workshop', + }; + + return directive; + + function link (scope, element, attrs) { } + } + + WorkshopController.$inject = ['$scope']; + + /* @ngInject */ + function WorkshopController ($scope) { + var vm = this; + + + vm.$onInit = onInit; + vm.$onDestroy = onDestroy; + vm.close = close; + vm.visible = true; + vm.activate = activate; + + function onInit () { + activate(); + } + + function activate () { + vm.visible = true; + } + + function onDestroy () { + + } + + function close () { + vm.visible = false; + } + } +})(); diff --git a/app/index.html b/app/index.html index 98253512..9603a596 100644 --- a/app/index.html +++ b/app/index.html @@ -62,7 +62,7 @@
@@ -312,6 +312,7 @@
+
@@ -356,6 +357,7 @@ + @@ -401,6 +403,11 @@ +