0
I’m trying to implement the Gem Chartkick in a Rails application, but I’m having a small problem.
My application has a relationship between two models:
class Animal < ActiveRecord::Base
belongs_to :race
end
In my view, I’m trying to present the Percentage of Animals by Breed.
<%= pie_chart @animals.group(:race).count %>
The Charts are being presented as follows:
How do I present the names of the Races and not Race:0x007f6d48812970?
Thank you so much for the help! It worked perfectly.
– augustoppimenta