# Variable filter

filter: {
configuration_workflow: (req: any) => Workflow;
description: string;
get_state_fields: () => object[];
initial_config: () => Promise<object>;
name: string;
queries: (
__namedParameters: {
configuration: { columns: any };
exttable_name: any;
req: any;
res: any;
table_id: any;
viewname: any;
},
) => {
actionQuery(state: any, rndid: any): Promise<any>;
distinctValuesQuery(
state: any,
): Promise<{ distinct_values: {}; role: any }>;
optionsQuery(
reftable_name: any,
type: any,
attributes: any,
whereWithExisting: any,
user: any,
): Promise<any>;
};
routes: {
run_action: (
table_id: any,
viewname: any,
config: any,
body: any,
__namedParameters: { req: any; res: any },
__namedParameters: { actionQuery: any },
) => Promise<any>;
};
run: (
table_id: number,
viewname: string,
opts: { columns: object[]; layout: object },
state: object,
extra: object,
__namedParameters: { distinctValuesQuery: any; optionsQuery: any },
) => Promise<Layout>;
getStringsForI18n(opts: { layout: any }): string[];
}

#### Type Declaration

- ##### configuration_workflow: (req: any) => Workflow

- ##### description: string

- ##### get_state_fields: () => object[]

- ##### initial_config: () => Promise<object>

- ##### name: string

- ##### queries: (
  __namedParameters: {
  configuration: { columns: any };
  exttable_name: any;
  req: any;
  res: any;
  table_id: any;
  viewname: any;
  },
  ) => {
  actionQuery(state: any, rndid: any): Promise<any>;
  distinctValuesQuery(
  state: any,
  ): Promise<{ distinct_values: {}; role: any }>;
  optionsQuery(
  reftable_name: any,
  type: any,
  attributes: any,
  whereWithExisting: any,
  user: any,
  ): Promise<any>;
  }

- ##### routes: {
  run_action: (
  table_id: any,
  viewname: any,
  config: any,
  body: any,
  __namedParameters: { req: any; res: any },
  __namedParameters: { actionQuery: any },
  ) => Promise<any>;
  }

- ##### run: (
  table_id: number,
  viewname: string,
  opts: { columns: object[]; layout: object },
  state: object,
  extra: object,
  __namedParameters: { distinctValuesQuery: any; optionsQuery: any },
  ) => Promise<Layout>

- ##### getStringsForI18n: function

  - getStringsForI18n(opts: { layout: any }): string[]

    #### Parameters

    - opts: { layout: any }

    #### Returns string[]

    - Defined in packages/saltcorn-data/base-plugin/viewtemplates/filter.js:881

- Defined in packages/saltcorn-data/base-plugin/viewtemplates/filter.js:866