diff --git a/examples/README.md b/examples/README.md index 64341a7fdbc..3f47af3b3f5 100644 --- a/examples/README.md +++ b/examples/README.md @@ -1,4 +1,5 @@ ## Example plugin implementations -datasource:[simple-json-datasource](https://github.com/grafana/simple-json-datasource) -app: [example-app](https://github.com/grafana/example-app) \ No newline at end of file +datasource:[simple-json-datasource](https://github.com/grafana/grafana-simple-json-datasource) +app: [example-app](https://github.com/grafana/grafana-example-app) +panel: [grafana-piechart-panel](https://github.com/grafana/piechart-panel) diff --git a/examples/boilerplate-es5-panel/css/styles.css b/examples/boilerplate-es5-panel/css/styles.css deleted file mode 100644 index b7259cb6cc8..00000000000 --- a/examples/boilerplate-es5-panel/css/styles.css +++ /dev/null @@ -1,3 +0,0 @@ -.panel-boilerplate-values { - text-align: center; -} \ No newline at end of file diff --git a/examples/boilerplate-es5-panel/module.js b/examples/boilerplate-es5-panel/module.js deleted file mode 100644 index ef6b23ea749..00000000000 --- a/examples/boilerplate-es5-panel/module.js +++ /dev/null @@ -1,53 +0,0 @@ -define([ - 'app/plugins/sdk', - 'lodash', - './css/styles.css!' -], function(sdk, _) { - - var BoilerPlatePanelCtrl = (function(_super) { - var self; - - function BoilerPlatePanelCtrl($scope, $injector) { - _super.call(this, $scope, $injector); - - this.results = [] - - self = this; - } - - // you do not need a templateUrl, you can use a inline template here - // BoilerPlatePanelCtrl.template = '

boilerplate

'; - - // all panel static assets can be accessed via 'public/plugins// - BoilerPlatePanelCtrl.templateUrl = 'panel.html'; - - BoilerPlatePanelCtrl.prototype = Object.create(_super.prototype); - BoilerPlatePanelCtrl.prototype.constructor = BoilerPlatePanelCtrl; - - BoilerPlatePanelCtrl.prototype.refreshData = function(datasource) { - this.issueQueries(datasource) - .then(function(result) { - self.results = []; - _.each(result.data, function(target) { - var last = _.last(target.datapoints) - self.results.push(last[0]); - }); - - self.render(); - }); - } - - BoilerPlatePanelCtrl.prototype.render = function() { - this.values = this.results.join(','); - } - - return BoilerPlatePanelCtrl; - - })(sdk.MetricsPanelCtrl); - - - return { - PanelCtrl: BoilerPlatePanelCtrl - }; -}); - diff --git a/examples/boilerplate-es5-panel/panel.html b/examples/boilerplate-es5-panel/panel.html deleted file mode 100644 index 4a413c95dfe..00000000000 --- a/examples/boilerplate-es5-panel/panel.html +++ /dev/null @@ -1,7 +0,0 @@ -

- Basic panel -

- -

{{ctrl.values}}

- - diff --git a/examples/boilerplate-es5-panel/plugin.json b/examples/boilerplate-es5-panel/plugin.json deleted file mode 100644 index b585698c20a..00000000000 --- a/examples/boilerplate-es5-panel/plugin.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "type": "panel", - "name": "Panel Boilerplate", - "id": "panel-boilerplate-es5", - "staticRoot": "." -}