AgileApps Support Wiki Pre Release

Dynamic Filters

From AgileApps Support Wiki
Revision as of 01:34, 20 January 2012 by imported>Aeric

Dynamic Filters define a query with field variables, enabling more powerful controls.

  • Use Dynamic Filters when complex associations are needed for Record Selection Criteria
How it Works
  • In a Technology Asset record, display a list of Technicians certified to support or repair the equipment
  • For an Inventory Application, add a field to a Part Record that finds only component parts (subcomponents of the Part)
  • For a Product or Service Ordering Application, add a field to a Brand Record that limits the lookup to products that belong to the brand family
  • In a Candy Manufacturing Application, add a field to a Recipe Record that identifies organic ingredients only
Guidelines for building Dynamic Filters
The format of a Dynamic Filter changes, depending on the type of field:
  • Lookup
  • Other (text, date, other alphanumeric field)
To specify Dynamic filters in the UI, insert a derived field name in the Value field of the Record Selection Criteria builder
  • To create a derived field name, include a dollar sign ($) before the internal field name (this identifies the value as a dynamic filter)
  • If a Lookup field is chosen, use the $fieldname_name format
  • For all other fields, use $fieldname
Where fieldname can be found in Field Name
User Object template variables

Any Lookup field that targets the User object provides additional fields that can be used to select records that pertain to the current user. The criteria have the form:

{field_name} {operator} $loggedInUser.{User_object_field}
For example:
  • Owner equals $loggedInUser.id - Records owned by the current user
  • Created By equals $loggedInUser.id - Records created by the current user
  • Modified By equals $loggedInUser.id - Records modified by the current user
  • City equals $loggedInUser.city - Records in the current user's city
Examples
  • In a Lookup field of Object "Employee", to restrict the Employees available depending on the Location, set filter to {0} in the Location field. If the Location is any other field type, set filter to {1} in the Location field.
  • An IT assets object is linked to the Service Techs object, which includes staff members who are responsible for support
  • Service Techs have an Area of Responsibility that matches one of the available IT asset Types: "Laptop", "Desktop", or "Server"
  • The Service Tech object is defined as follows:
  • In the IT asset object, the Lookup field to the Service Tech object includes Record Selection Criteria that limits the lookup to Service Techs with Areas of Expertise that match the Asset Type:
  • When assigning the asset to a user, a Service Tech is selected, and the list of Service Techs displayed in the Lookup Window shows only the techs with expertise in the required area of technology