I'm trying to use include for my json response, which works great, but when I start to nest it, I'm getting a strange result
The include doesn't return the gym object. If I flip the order and put trainer last, that object doesn't get returned.
Am I missing something with my syntax ?
msg = {:requests => @customer_sessions.as_json(:include => [:session_coupon, :trainer => {:methods => [:rating, :completed_sessions_length, :following]}, :gym => {:methods => :rating}])}
format.json { render :json => msg }
:include => {:one, :two, :three}:include {:trainer => {:methods => [:rating, :completed_sessions_length, :following]}, :gym => {:methods => :rating}}