Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
  • Create a filter using an expression
  • Set a default filter on a stream view

Create a filter using an expression

  • Open the model Dashboards and Forms 01-08: Views, filters and dashboardsOpen the view dashboard Debt levels by payment means 2 from the stream Overall Debt Levels (you created this in exercise 18 Create further Stream Views)

The chart is cluttered. You will now add a filter to this view to limit the results to the last 40 days:

  • In the chart press
  • Press 
  • Configure the filter with the following details:
    • Name: Last 40 days
    • Conditions:
      • The condition dialogue starts with Where ALL the following are true - leave this as it is
      • Select CalculationDate
      • Press on contains - from the drop down list that appears, select greater than
      • Enter this formula:
Code Block
dateAdd(now(), _DAY_OF_MONTH, -40)

...

      • Press the ABC button - this will now say fx
  • When you have completed all these details press 

...

Since the view Debt levels by payment means 2 is too cluttered to be useful with all results showing, you decide to make the filter Last 40 days, that you created in the previous exercise, the default filter for this view:

  • Open the stream view configuration form for Debt levels by payment means 2
  • Set Default Filter to Last 40 days
  • Press

Close then open the view again – you will see that the filter has been automatically applied.Go into App mode to see the results

Using the same filter on other views

You can use the filter you created in the previous exercise on any other view defined on this streamthe underlying stream (Overall Debt Levels), but first you must associate the filter with the view:

  • Open the dashboard Debt levels by payment means
  • Open the stream view configuration form for the view Debt levels by payment means
  • Go to the Filters section
  • Press
  • Drag the filter Last 40 days into the list of filters for this view
  • Press 
  • Go into App mode
  • Open the view Debt levels by payment means
  • Apply In the dashboard, apply the filter Last 40 days

...

In PhixFlow, any filter defined on a view on a stream can be used on any other view defined on that stream.

...