action_="setfilter"

<do action_="setfilter"> sets the filter on a specified table. (Available as of version 10.23)

Syntax

<dynamic>
    <do action_="setfilter" path_="[PATH]">
      [XML_FILTER]
    </do>
</dynamic>

Structure of XML filter

The XML format used for [XML_FILTER] is as follows:

<filter>
  <when user="[LIST_OF_USERS_OR_GROUPS]">
    [MACRO_LANGUAGE_OPERATIONS]
  </when>
  ...
  <default>
    [MACRO_LANGUAGE_OPERATIONS]
  </default>
</filter>

A filter may contain any number of <when> clauses and an optional <default> clause. A user opening a filtered table is restricted by the operations contained within the first <when> clause for which their user ID or any of their groups appears in the clause's user list, which is a comma-separated list of users or groups. If no <when> clause matches, but there is a <default> clause, a user opening a filtered table is restricted by the operations contained therein. If there is no match and no <default>, the filter is ignored. This is the only XML format currently accepted by action_="setfilter".

Attributes for action_="setfilter"

path_
Specifies the pathname of an existing 1010data table that the caller owns.

The XML specified between the opening and closing <do> tags is applied as a filter on the table. If no XML is specified, any existing filter is removed from the table.

Example

<do action_="setfilter" path_="{@path}">
        <filter>
          <when user="foo,bar">
            <quote>
              <sel value="include{@suffix_}=1"/>
              <colord hide="file_name{@suffix_}" hard="1"/>
            </quote>
          </when>
        </filter>
      </do>