symfony API

sfFormFilterDoctrine Class

You are currently browsing
the website for symfony 1

Visit the Symfony2 website


« Back to API menu

1.2 API OpenSearch

Packages

You are currently browsing the symfony API for the 1.2 version. Switch to:
This version of symfony is not maintained anymore.
If some of your projects still use this version, consider upgrading as soon as possible.

sfFormFilterDoctrine is the base class for filter forms based on Doctrine objects.

Method Summary

Method Details

  • addBooleanQuery ($query, $field, $value) Browse code

    $query
    $field
    $value

  • addDateQuery ($query, $field, $values) Browse code

    $query
    $field
    $values

  • addEnumQuery ($query, $field, $value) Browse code

    $query
    $field
    $value

  • addForeignKeyQuery ($query, $field, $value) Browse code

    $query
    $field
    $value

  • addNumberQuery ($query, $field, $values) Browse code

    $query
    $field
    $values

  • addTextQuery ($query, $field, $values) Browse code

    $query
    $field
    $values

  • (Query) buildQuery ($values) Browse code

    $values An array of parameters to build the Query object

    Builds a Doctrine Query based on the passed values.

    returns A Doctrine Query object

  • camelize ($text) Browse code

    $text

  • getColName ($field) Browse code

    $field

  • getFieldName ($colName) Browse code

    $colName

  • (array) getFields () Browse code

    Returns the fields and their filter type.

    returns An array of fields with their filter type

  • (string) getModelName () Browse code

    Returns the current model name.

    returns The model class name

  • (Query) getQuery () Browse code

    Returns a Doctrine Query based on the current values form the form.

    returns A Doctrine Query object

  • getTable () Browse code

  • (string) getTableMethod () Browse code

    Get the name of the table method used to retrieve the query object for the filter

  • (array) processValues ($values) Browse code

    $values An array of cleaned up values to process

    Processes cleaned up values with user defined methods.


    To process a value before it is used by the buildQuery() method, you need to define an convertXXXValue() method where XXX is the PHP name of the column.

    The method must return the processed value or false to remove the value from the array of cleaned up values.

    returns An array of cleaned up values processed by the user defined methods

  • setTableMethod ($tableMethodName) Browse code

    $tableMethodName

    Set the name of the table method used to retrieve the query object for the filter