Skip to Content
author's profile photo Former Member
Former Member

Applying custom filter on the device

Hi All,

Working on the CRM Sales Manager app, as per the customer data model we have various types of accounts which we want to show on the device. For one of the account types, we want to download it to the device but not show it on the accounts list by default when the accounts get downloaded. So that would be like applying a user filter on the device by default so that if user wants he can remove that filter and see those particular account types as well.

I know we can control the account types downloaded via the filters on the config panel but we have already configured it to download all account types as that's what we want but would like to restrict it on the device. For that I think we can create a rule as well as per my current understanding so that it filters the list with the account type we do not want to see but I think that would not show as a default filter on the filter icon for the list that the user can go and perform a remove filter when they want to see it.

I've already created a filter on the account type property and that works but user has to go and apply that. What we are looking for is a pre-filtered list on the device which user can remove later.

Requesting you to please suggest if this can be achieved and how. Please let me know if I need to be more clear.

Awaiting your responses.

Thanks & Regards,

Gourav

Tags edited by: Michael Appleby

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • Best Answer
    Posted on Jan 08, 2014 at 09:09 PM

    Gourav,

    You cannot programmatically apply a default filter using the standard Agentry filter mechanism built into lists. You can achieve this by adding or modifying the include rule on the list. Include rules will show all objects for which the rule logic returns true. Examine some of the existing include rules in your editor to get a feel for how they work. You can add additional logic to a rule if needed.

    You can control the user turning this on/off by adding a new variable to the main object, maybe a Boolean called "DisableFilter". This will be set to "False" by default.

    Add a new Action, Transaction and Button on the screen to toggle this boolean variable, so when the user pushes the button, the "DisableFilter" object property changes from "True" to "False".

    Modify the include rule on your list screen or control to look at your "DisableFilter" field and decide whether or not to include certain collection rows based on the boolean setting.

    Jason Latko - Senior Product Developer at SAP

    Add a comment
    10|10000 characters needed characters exceeded

    • Gourav,

      You said "What we are looking for is a pre-filtered list on the device which user can remove later." Maybe I am misunderstanding. What do you mean that the user can remove later? The solution I gave you will fiter the list by default without user interaction. Then if the user wants to remove the filter, they click the new button to toggle the filter off. This doesn't work for you?

      Maybe you mean that you want all the logic on the Java side, away from the client?

      Jason Latko - Senior Product Developer at SAP

  • author's profile photo Former Member
    Former Member
    Posted on Jan 08, 2014 at 08:00 PM

    Hi All,

    Still awaiting your responses. Thanks in advance.

    Regards,

    Gourav

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.