Skip to content

call controller / scope function from as valueFormatFunction #155

Open
@gadeynebram

Description

@gadeynebram

Hi,

Great library!

Is it possible to call a function from your controller or scope as the valueFormatFunction in chart-tooltip?

This does not work:

<div ng-controller="C3ChartController as chartCtrl"> <c3chart ....> <chart-tooltip valueFormatFunction="chartCtrl.formatValue(value)"></chart-tooltip> </<c3chart> </div>

or something like this does not either

<chart-tooltip valueFormatFunction="angular.element(document.getElementById('line-chart-{{$index + 1}}')).controller().formatValue(value)"></chart-tooltip>

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions