Lots of things you need to customize.
MVC
First, let me explain how ajax calls should work in Rails
Rails MVC (Model View Control) - . , - -, :

, MVC "" . , MVC "" ( ) - , ,
, MVC, , ( ).
-
Ajax
, ajax ( Javascript XML), , , .
Ajax - "-" . "-" , "" :

HTTP "" (IE / "" ), " " - -.
Ajax , , . , - ( , Ajax )
-
-, javascript (IE piepline)
$(document).on("change", "#cbo", function() {
$.ajax({
url: "/product_details/show",
type: "POST",
data: {"cbo_id" : $(this).val()},
dataType: "json",
success: function(data) {
alert('successfully');
}
});
});
Class ProductDetailsController < ApplicationController
respond_to :js, :json, :html
def show
@product = Product.find params[:id]
respond_with @product
end
end
JSON , , .
, , ; , , MVC ..