Ajax success function empty

Hello
I have try use Master/Detail grid but I have issue. I have passed a long hours but I dont know why my ajax answer is empty :(
I have tried adapt the code after the following link
https://help.syncfusion.com/aspnetmvc-classic/grid/master-details-grid
Could you please check my files and say me where is my error?
Thank you so much.

Best Regards
Eren

Attachment: Syncfussion_af374fad.zip

3 Replies

SS Seeni Sakthi Kumar Seeni Raj Syncfusion Team November 6, 2017 08:52 AM UTC

Hi Eren,  
 
Thanks for contacting Syncfusion Support.  
 
We could see your controller page is not receiving any data from the client-end and moreover the data were not returned from the server-end. Please refer to the following code example which sends the data from the server-end and receives the data from the client-end. 
 
        public ActionResult data(int val) { 
            List<Orders> dat = order.Where(or => or.EmployeeID == val).ToList(); 
            return Json(new { result = dat });    
        } 
 
<script type="text/javascript"> 
    $(function () { 
        window.rowSelected = function (args) { 
            var employeeID = args.data.EmployeeID; 
            $.ajax({ 
                url: "/Home/data", 
                type: "POST", 
                data: { val: employeeID }, 
                success: function (data) { 
                    $("#DetailGrid").ejGrid("dataSource", ej.DataManager({ 
                        json: data.result, 
                        adaptor: "remoteSaveAdaptor" 
                    })); 
                } 
            }); 
 
        } 
    }); 
</script> 
 
We have also prepared a sample that can be downloaded from the following location.  
 
 
Regards,  
Seeni Sakthi Kumar S. 



TH TheDarkBoz November 7, 2017 10:27 PM UTC

Thanks you for you help



SS Seeni Sakthi Kumar Seeni Raj Syncfusion Team November 8, 2017 04:08 AM UTC

Hi Eren,  
 
Thanks for the update. Please get back to us, if you require further assistance on this.  
 
Regards,  
Seeni Sakthi Kumar S. 


Loader.
Up arrow icon