I am trying to make an ajax call for my controller
class PatientRecordController < ApplicationController def export .... end end
In my javascript file I have
$(document).ready(function(){ freezeTopRow($('#dataTable')); $("#export").click(function(){ $.ajax({url: "patient_record/export", type: "POST"}); }); });
when I check the item and debug, and when I click the export tag on my page. I click on a function but never gets to the controller
Also I have 2 controllers and 2 views. In my other controller and view, I am doing the same thing and it works
user1571609
source share