We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Grid hangs when using custom adapter even though for testing I set a manual value in proccessResponse

Thread ID:





132461 Sep 3,2017 09:29 PM UTC Sep 6,2017 01:48 PM UTC JavaScript 1
Tags: ejGrid
Asked On September 3, 2017 09:49 PM UTC

Is processResponse the last step before binding data to the grid.  Currently the grid just hangs with a spinning circle.

I am setting the results manually in processResponse to 
let results =  { result: [], count: 0 }
but it still hangs.  Normally I pass in a array on object for the value of result.  But the empty array should just result in empty results not a hang with spinning circle

Attached is my adapter if you could possibly take a look at it.

Thank you.

The attachment is the adapter.

Attachment: syncfusionfeathersadapter_4196a6b2.7z

The below is the grid being bound

let customers = await  this.api.customers.find();
let dataManager = new ej.DataManager(customers);
dataManager.adaptor = new this.adapter.feathersAdapter();

dataSource: dataManager,
toolbarSettings: {
showToolbar: true,
toolbarItems: ["add", "edit", "delete"]
editSettings: {
allowEditing: true,
allowAdding: true,
allowDeleting: true,
editMode: "dialog"
allowPaging: true,
allowSorting: true,
allowFiltering: true,
filterSettings: {showPredicate: true, filterType: "menu", enableCaseSensitivity: true},
searchSettings: {ignoreCase: false},
isResponsive: true,
columns: [
{"field": "first_name"},
{"field": "last_name"},
{"field": "company"},
{"field": "id", "isPrimaryKey": true}

Prasanna Kumar Viswanathan [Syncfusion]
Replied On September 6, 2017 01:48 PM UTC

Hi Dan, 

Thanks for contacting Syncfusion support. 

We created a sample with your adaptor and we can reproduce the mentioned issue in our sample. In this you have mentioned the grid just hangs with a spinning circle. The spinning circle will displayed when we face any script error in console page. In our sample we faced script error in console page.  
In adaptor code example you have an method called convertToQueryString. In this method we get the object as undefined for the mentioned code(var obj = req.sort[0]). If the object has undefined then we will face script error while using Object.entries method. To avoid the script error, we suggest you to check the mentioned condition before the for loop. 
Find the code example and sample:  
convertToQueryString: function (req, query, dm) { 
                    var obj = req.sort[0] 
                    if (!ej.isNullOrUndefined(obj)) { 
                        for (var key in Object.entries(obj)) { 
                            str += '$sort[' + key + ']=' + value + '&' 
              return str 

Prasanna Kumar N.S.V 


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon