diff --git a/README.md b/README.md index c836af6..a6970de 100644 --- a/README.md +++ b/README.md @@ -34,7 +34,7 @@ Each goal can be used as parameter for the gulp command. * *clean*: removes the dist folder * *lint*: checks css and javascript files for common errors -* *serve*: starts an webserver to test the widget +* *serve*: starts an webserver to test the widgets in local development. To provide the widgets with test data, "https://builds.apache.org/" is stored as the URL in `jenkins.js` by default. For local development, a [CORS plugin](https://chrome.google.com/webstore/detail/allow-cors-access-control/lhobafahddgcelffkeicbaginigeejlf) must be used in the browser. ## Usage diff --git a/dist/adf-widget-jenkins.js b/dist/adf-widget-jenkins.js index a69b2ed..9d3185b 100644 --- a/dist/adf-widget-jenkins.js +++ b/dist/adf-widget-jenkins.js @@ -1,14 +1,8 @@ (function(window, undefined) {'use strict'; -var jenkinsWidget = angular.module('adf.widget.jenkins', ['adf.provider', 'chart.js', 'ui.bootstrap']) - .constant("jenkinsEndpoint", { - "url": "http://builds.apache.org" - }) - .config(registerWidget); - function registerWidget(dashboardProvider) { - var category = 'Jenkins'; + const category = 'Jenkins'; dashboardProvider .widget('jenkinsBuildReport', { @@ -59,10 +53,16 @@ function registerWidget(dashboardProvider) { } registerWidget.$inject = ["dashboardProvider"]; +const jenkinsWidget = angular.module('adf.widget.jenkins', ['adf.provider', 'chart.js', 'ui.bootstrap']) + .constant("jenkinsEndpoint", { + "url": "https://builds.apache.org/" + }) + .config(registerWidget); + angular.module("adf.widget.jenkins").run(["$templateCache", function($templateCache) {$templateCache.put("{widgetsPath}/jenkins/src/edit.html","
"); -$templateCache.put("{widgetsPath}/jenkins/src/view.html","{{jc.data.stable || 0}}
stable builds{{jc.data.unstable || 0}}
unstable builds{{jc.data.fail || 0}}
failed builds{{jc.data.aborted+jc.data.disabled || 0}}
disabled builds{{jc.data.stable || 0}}
stable builds{{jc.data.unstable || 0}}
unstable builds{{jc.data.fail || 0}}
failed builds{{jc.data.aborted+jc.data.disabled || 0}}
disabled builds{{jc.data.stable || 0}}
stable builds{{jc.data.unstable || 0}}
unstable builds{{jc.data.fail || 0}}
failed builds{{jc.data.aborted+jc.data.disabled || 0}}
disabled buildsLast Commit: {{vm.data.lastCommitMsg}}
Author: {{vm.data.lastCommitBy}}