Lots of refactoring from nvModel Mega Function to PieChart extends Chart