rendro / easy-pie-chart

easy pie chart is a lightweight plugin to draw simple, animated pie charts for single values
http://rendro.github.io/easy-pie-chart
MIT License
2.07k stars 503 forks source link

[AngularJS] Options dynamically #65

Open renatoc opened 10 years ago

renatoc commented 10 years ago

Is it possible to change options dynamically, and chart redraw automatically ? I have tried and with no success.

Something like this:



var app = angular.module('app', ['easypiechart']);
app.controller('chartCtrl', ['$scope', function ($scope,frameworkFactory) {
...
   $scope.start = function(){
        var data = frameworkFactory.getData();
        data.$get().then(function(v){
            $scope.percent = data[$scope.data].percent;
            $scope.options = data[$scope.data].options;
        });
    }
    $scope.start();
...
mrzmyr commented 10 years ago

We're planning to bring dynamic options into easypiechart. For now you can use dynamic percentage values as you see in this example: http://plnkr.co/edit/HEyMt7AfI05yVxR8K8mu?p=preview

renatoc commented 10 years ago

Thanks, i'll wait for that feature.

nunosilva800 commented 10 years ago

+1 for this feature

simukka commented 9 years ago

+1

sathiya-mit commented 9 years ago

+1

sathiya-mit commented 9 years ago

Actually +100

baliomega commented 9 years ago

+1

polosatyi commented 8 years ago

+1

mrzmyr commented 8 years ago

PR's are welcome. :octocat::v:

lukaszgrolik commented 8 years ago

Setting options dynamically would be great, especially colors

jabiel commented 8 years ago

+1

waclock commented 7 years ago

+1

aledebs commented 7 years ago

+1

hannesaasamets commented 7 years ago

+1

brunoribeiro94 commented 6 years ago

+1