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

Sort and Filter by nested objects ( alpha => alpha.beta.bataName )

Thread ID:





127945 Dec 20,2016 06:48 PM UTC Dec 28,2016 07:06 AM UTC ASP.NET MVC 5
Tags: DataManager
Asked On December 20, 2016 06:48 PM UTC

I have the following grid, and i am wondering if it is possible to sort or filter by objects nested in objects. The second coloum i define is what i am trying to sort and filter by with no luck. i get no results back at all.
*** VIEW
@(Html.EJ().DataManager("FlatData").URL(Url.Action("GlobalDataSource", "Home", null, Request.Url.Scheme)).Adaptor(AdaptorType.UrlAdaptor))
   .ContextMenuSettings(contextMenu =>
  .Columns(c =>
    c.Field(f => f.ID).Width("7%").Add();
    c.Field(f => f.Company.CompanyName).Width("15%").Add();
    c.Field(f => f.TicketDisplayID).Width("15%").Add();
    c.Field(f => f.CreateDate).Width("10%").Add();
    c.Field(f => f.ClosedDate).Width("10%").Add();
    c.Field(f => f.ServiceItem).Width("10%").Add();
    c.Field(f => f.Desc).Width("13%").Add();
    c.Field(f => f.RespPartyResolutionTypeId).Width("10%").Add();
    c.Field(f => f.Parent).Width("10%").Add();
  .SortSettings(sort => sort.SortedColumns(col => col.Field("ID").Direction(SortOrder.Descending).Add()))
  .PageSettings(p => p.PageSize(30).EnableQueryString())
  .ClientSideEvents(e => e

public ActionResult GlobalDataSource(Syncfusion.JavaScript.DataManager dm)
 IEnumerable data = db.GlobalTicketInfo; 
 Syncfusion.JavaScript.DataSources.DataOperations operation = new Syncfusion.JavaScript.DataSources.DataOperations();
 if (dm.Sorted != null && dm.Sorted.Count > 0)
    data = operation.PerformSorting(data, dm.Sorted);
 if (dm.Where != null && dm.Where.Count > 0)
    data = operation.PerformWhereFilter(data, dm.Where, dm.Where[0].Operator);
 int count = data.AsQueryable().Count();
 if (dm.Skip != 0)
    data = operation.PerformSkip(data, dm.Skip);

 if (dm.Take != 0)
    data = operation.PerformTake(data, dm.Take);
 return Json(new { result = data, count = count }, JsonRequestBehavior.AllowGet);

Venkatesh Ayothi Raman [Syncfusion]
Replied On December 21, 2016 12:53 PM UTC

Hi Diamond, 

As you have posted the same query in another forum. So, we request you to follow with the forum #127948 for the further updates for the reported query.  
Venkatesh Ayothiraman.


Replied On December 21, 2016 02:14 PM UTC

i made this thread so that the tags would be correct with the technology that i was using.
Thank you

Venkatesh Ayothi Raman [Syncfusion]
Replied On December 22, 2016 04:15 AM UTC

Hi Diamond, 
Sorry for the inconvenience caused. 
We have wrongly updated the Forum id in previous update instead of Forum #127952.  
Venkatesh Ayothiraman.

Replied On December 22, 2016 04:14 PM UTC

This seems like an incident that multiple people must have ran into. Especially when entity makes it so easy to attack relational objects to other objects.
I am wondering what the standard work around for this problem is. I imagine that some has had to solve this problem before. 
Thank you for any workarounds that you are able to give me.

Diamond Wartenbee

Karthikeyan Viswanathan [Syncfusion]
Replied On December 28, 2016 07:06 AM UTC

Hi Diamond, 

you have posted the same query in Incident #169600 . So, we request you to follow that Incident for the further updates. 
Karthikeyan 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

or the page will be automatically redirected to 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