Hide Indent Column when grouping

Hi,

I want to hide the indent column when grouping. Please look at the screenshot:
https://i.imgur.com/GZCkV3z.png

I'm also trying to implement server side paging. I've a simple API:

public class StuffController : ApiController {

     public HttpResponseMessage GetTemplatesPage(int PageSize, int Page) {

          return this.ToJson(new RequestResult { Items = templates, Count = rowcount });
     }
}

I want the ejgrid to consume this service. I'm looking into the adapters documentation (UrlAdapter & WebApi) but you help will shorten the way for me.

Thanks

3 Replies

MS Mani Sankar Durai Syncfusion Team November 9, 2017 10:25 AM UTC

Hi Hussain, 

Thanks for contacting Syncfusion support. 

Query 1: I want to hide the indent column when grouping 
 
               We have checked your query and found that it is not feasible. When hiding the indent cell while grouping it will occur content misalignment and there will be changes in colspan to make the content not be misaligned. It will be more complexities to customize if we make more column to group. So it is not feasible to hide the indent cell while grouping.  
Also please let us know the reason why you need to hide the indent cell? Is that you have to disable to expand-collpase icon? So please provide the details which will help us to resolve the issue and provide you the response as early as possible. 
 
Query 2: I'm also trying to implement server side paging. I've a simple API: 
           
       From your code example we found that you have passing pageSize as parameter to server side while using WebAPI adaptor. When using WebAPIAdaptor in grid by default the paging, sorting etc.., request will be processed to the server side and there by using queryString we can perform the server side grid action.  
Refer the code example 
[app.component.ts] 
export class AppComponent { 
public gridData = ej.DataManager({ 
    url: "http://localhost:49339/api/Values", 
    adaptor: new ej.WebApiAdaptor(), 
    crossDomain: true 
}); 
      
[ValuesController.cs] 
public object Get() 
        { 
            var queryString = HttpContext.Current.Request.QueryString; 
            int skip = Convert.ToInt32(queryString["$skip"]);    
            int take = Convert.ToInt32(queryString["$top"]); 
            if (order.Count() == 0) 
                BindDataSource(); 
            var data = order; 
            return new { Items = data.Skip(skip).Take(take), Count = data.Count() };  //pefrom skip and take at server side. 
        } 
 
We have also prepared a sample that can be downloaded from the below link 
 
Also refer the KB link of about how to perform server side operation while using URlAdaptor in grid.  
 
Refer the documentation link 
 
Please let us know if you need further assistance. 
 
Regards, 
Manisankar Durai. 



HU Hussain November 13, 2017 10:47 AM UTC

Hi Mani,

The reason I want to hide the indent is because I though it doesn't look great and it would look better without it. The reason I have a grouping is just to separate similar rows with something that is visible to the user.

For the second query, I got it working fine, thanks. However, is it possible to make some operations local while the rest are in server? For example I want to perform paging and filtering in server, while I want sorting and searching to be done in local.



MS Mani Sankar Durai Syncfusion Team November 14, 2017 11:01 AM UTC

Hi Hussain, 

Query 1: The reason I want to hide the indent is because I though it doesn't look great  
    We have checked your query and it is not feasible to achieve your requirement. As we said in the previous update when hiding the indent cell while grouping it will occur content misalignment and there will be changes in colspan to make the content not be misaligned. It will be more complexities to customize if we make more column to group. So it is not feasible to hide the indent cell while grouping
 
Query 2: However, is it possible to make some operations local while the rest are in server?  
       When using Load on demand concept in grid we can perform the grid action (paging, filtering, sorting, grouping) only on server side. If you want to perform them locally we suggest you to use offline property as true which will tends to trigger the server side only on the initial time alone.  
So as per your requirement i.e to perform only paging, filtering on server side and other on client side is not feasible.  

Please let us know if you need further assistance. 

Regards,
manisankar Durai. 


Loader.
Up arrow icon