Need a special offer?Find out if your project fits.
+

Charts icon from amchart

Answered
shahad alaseri asked on November 30, 2021

Hi, 
I would like to ask if I can make all the charts in charts Icon beside the Grid icon to have only charts supported by amcharts library , is that possible ? 
 
thank you 

5 answers

Public
Nadia Khodakivska Nadia Khodakivska Flexmonster December 1, 2021

Hello, Shahad,
 
Thank you for reaching out to us.
 
Please check our recommendations for the necessary toolbar customization:
Firstly, you should find the index of the Chart tab in the tabs array. Knowing the necessary index, you can replace the tab containing the default Flexmonster Charts with your custom tab:

let pivot = new Flexmonster({
container: "pivot-container",
componentFolder: "https://cdn.flexmonster.com/",
toolbar: true,
beforetoolbarcreated: customizeToolbar
});
function customizeToolbar(toolbar) {
let tabs = toolbar.getTabs();
toolbar.getTabs = function() {
let indexOfChartTab = tabs.findIndex(tab => tab.id == "fm-tab-charts");
tabs[indexOfChartTab] = {
id: "fm-tab-charts",
title: "amCharts",
icon: this.icons.charts,
menu: [
{
args: "column",
handler: <your-function-createAmChartsColumn>,
icon: <your-icon>,
title: "column"
},
{
args: "bar",
handler: <your-function-createAmChartsBar>,
icon: this.icons.charts,
title: <your-icon>
}]
};
return tabs;
}
}

You can find more details on customizing the toolbar in our documentation: https://www.flexmonster.com/doc/customizing-toolbar/.
Also, here is the sample of highchart positioning: https://jsfiddle.net/flexmonster/9srmhckt/. As you can see, the chart is placed into the same position as the original Flexmonster Charts. You are welcome to use the same approach for amCharts. 
 
Please let us know if it works for you. Feel free to contact us if other questions arise.
 
Kind regards,
Nadia

Public
Nadia Khodakivska Nadia Khodakivska Flexmonster December 13, 2021

Hello,
 
Hope you are doing well.
 
We were wondering if the solution helped you. 
 
Looking forward to your feedback.
 
Kind regards,
Nadia

Public
Nadia Khodakivska Nadia Khodakivska Flexmonster December 20, 2021

Hello, Shahad,
 
Hope you are doing well.
 
Just checking in to ask if such an approach meets your needs.
 
Looking forward to hearing your feedback.
 
Kind regards,
Nadia

Public
shahad alaseri December 27, 2021

Hi Nadia , 
 
sorry for the delay , I just face another problem so I didn't check this , I need like a toutrial of hoe to manage data table to present it on chart can you please provide this ? 

Public
Nadia Khodakivska Nadia Khodakivska Flexmonster December 29, 2021

Hello,
 
Thank you for your response.
 
We have Flexmonster Connector for amCharts that provides necessary methods for integration. The detailed tutorial you can find in our documentation: https://www.flexmonster.com/doc/integration-with-amcharts/
Also, you are welcome to check some ready-to-use examples of integration with amCharts: https://www.flexmonster.com/examples/#amcharts
 
We hope it helps. Feel free to write to us in case further questions arise.
 
Kind regards,
Nadia

Please login or Register to Submit Answer