You are here

function highcharttable_add_decoration in HighchartTable 7

Add a new char decoration, using the supplied page path and chart type.

Parameters

string $page:

string $chart_type, defaults to 'column':

array $decorations:

1 call to highcharttable_add_decoration()
highcharttable_contextual_link in ./highcharttable.module
Menu callback for highcharttable/contextual-link

File

./highcharttable.module, line 219
highcharttable.module

Code

function highcharttable_add_decoration($page, $chart_type = NULL, &$decorations) {
  $decoration = array(
    'decoration-params' => array(
      'chart-type' => empty($chart_type) ? 'column' : $chart_type,
    ),
    'pages-and-selector' => array(
      'include-pages' => $page,
      'table-selector' => '',
    ),
  );
  $decorations[] = $decoration;
}