Hide view item in Selector View programmatically - Forum - Rollbase - Progress Community

Hide view item in Selector View programmatically

 Forum

Hide view item in Selector View programmatically

This question is answered

I have two view General and General (Search)

General with predefined filters using on Record List Page by default.

General (Search) without predefined filters(because when i do search on result will show only by detailed search items) and using on Search Result Page by default.

I'd like to hide none default view that user can't change selector view to another one.

I tried like this:

var viewId = $("#viewSelectorId_110103961").data("kendoDropDownList");

var newFilter = {
logic: "or",
filters: [
{ field: "viewId", operator: "neq", value: '110103957' },
{ field: "viewId", operator: "neq", value: '110117955' }
]
};

viewId.dataSource.filter(newFilter);

Doesn't work.

Does anyone know how can i do it?

Regards,

Marat

Verified Answer
  • Working :)

    Changed logic from'or' to 'and'

    var newFilter = {

    logic: "and",

    filters: [

    { field: "viewId", operator: "neq", value: '110103957' },

    { field: "viewId", operator: "neq", value: '110117955' }

    ]

    };

All Replies
  • Working :)

    Changed logic from 'or' to 'and'.

    var newFilter = {

    logic: "and",

    filters: [

    { field: "viewId", operator: "neq", value: '110103957' },

    { field: "viewId", operator: "neq", value: '110117955' }

    ]

    };

  • Working :)

    Changed logic from'or' to 'and'

    var newFilter = {

    logic: "and",

    filters: [

    { field: "viewId", operator: "neq", value: '110103957' },

    { field: "viewId", operator: "neq", value: '110117955' }

    ]

    };

  • Working :)

    Changed logic from 'or' to 'and'

    var newFilter = {

    logic: "and",

    filters: [

    { field: "viewId", operator: "neq", value: '110103957' },

    { field: "viewId", operator: "neq", value: '110117955' }

    ]

    };