KUIB 3 Blank View Grid - Forum - Kendo UI Builder - Progress Community
 Forum

KUIB 3 Blank View Grid

This question is answered

Hi all - Last week the community helped me in how to configure a Hierarchical Grid View so that JFP can be applied prior to requesting the back end for data.

See forum post

https://community.progress.com/community_groups/openedge_kendo_ui_builder/f/255/t/38844

Today - Im building a Blank view and including a plain Grid to it. 

I'm in need to also apply the JFP config so that this plain Grid on the Blank View can be server side filtered.

What file am I to look at to modify the added Grid? 

Verified Answer
  • Hello,

    The approach to apply the filter with a Blank View is similar as with a regular view.

    You would also add code to the <view>.view.component.ts file.

    The logic in the constructor would use the name of your Data Source:

          this.$dataServicesState.<DataSourceName>.filter = <filter object>;

    The filter object is corresponds to a CompositeFilterDescriptor:

    - www.telerik.com/.../

    For Data Sources in the View Data Sources, my convention is to add "DS" to the resource name.

    Example:

    export class CustomerViewViewComponent extends CustomerViewViewBaseComponent {

       constructor(@Inject(Injector) injector: Injector) {

           super(injector);

           this.$dataServicesState.CustomerDS.filter = {

               logic: 'and',

               filters: [{ field: 'CustNum', operator: 'lte', value: 20 }]

           };

       }

    ...

    }

    I hope this helps.

All Replies
  • Hello,

    The approach to apply the filter with a Blank View is similar as with a regular view.

    You would also add code to the <view>.view.component.ts file.

    The logic in the constructor would use the name of your Data Source:

          this.$dataServicesState.<DataSourceName>.filter = <filter object>;

    The filter object is corresponds to a CompositeFilterDescriptor:

    - www.telerik.com/.../

    For Data Sources in the View Data Sources, my convention is to add "DS" to the resource name.

    Example:

    export class CustomerViewViewComponent extends CustomerViewViewBaseComponent {

       constructor(@Inject(Injector) injector: Injector) {

           super(injector);

           this.$dataServicesState.CustomerDS.filter = {

               logic: 'and',

               filters: [{ field: 'CustNum', operator: 'lte', value: 20 }]

           };

       }

    ...

    }

    I hope this helps.