... | ... | @@ -6,6 +6,23 @@ Torque::PostgreSQL.configure do |c| |
|
|
end
|
|
|
```
|
|
|
|
|
|
## <a name="general"></a>General configurations
|
|
|
|
|
|
These are the keys available to configure general features:
|
|
|
|
|
|
<a name="eager_load"></a>`eager_load` Set if any information that requires querying and searching or collectiong information shuld be eager loaded. This automatically changes when rails same configuration is set to true.
|
|
|
Default value: `false`
|
|
|
|
|
|
<a name="irregular_models"></a>`irregular_models` Set a list of irregular model names when associated with table names. It uses the `'table_name' => 'model_name'` format. This is widely used for inheritance, because record types need to be associated with a model class.
|
|
|
Default value: `{}`
|
|
|
|
|
|
## <a name="auxiliary_statement"></a>Auxiliary statements configurations
|
|
|
|
|
|
These are the keys available to configure Auxiliary statements features:
|
|
|
|
|
|
<a name="auxiliary_statement.send_arguments_key"></a>`auxiliary_statement.send_arguments_key` Define the key that is used on auxiliary statements to send extra arguments to format string or send on a proc.
|
|
|
Default value: `:args`
|
|
|
|
|
|
## <a name="enum"></a>Enum configurations
|
|
|
|
|
|
These are the keys available to configure Enum features:
|
... | ... | @@ -34,3 +51,16 @@ Default value: |
|
|
|
|
|
<a name="enum.i18n_type_scope"></a>`enum.i18n_type_scope` Specify the scopes for I18n translations, detached from model.
|
|
|
Default value: `# Same list as before but without items that have ${attr} or %{model}`
|
|
|
|
|
|
## <a name="inheritance"></a>Inheritance configurations
|
|
|
|
|
|
These are the keys available to configure Inheritance features:
|
|
|
|
|
|
<a name="inheritance.inverse_lookup"></a>`inheritance.inverse_lookup` Define the lookup of models from their given name to be inverted, which means that they are going to be form the last namespaced one to the most namespaced one. If you prefer `User::Role` instead of `UserRole` as model name, set this to `false` to improve performance.
|
|
|
Default value: `true`
|
|
|
|
|
|
<a name="inheritance.record_class_column_name"></a>`inheritance.record_class_column_name` Determines the name of the column used to collect the table of each record. When the table has inheritance tables, this column will return the name of the table that actually holds the record.
|
|
|
Default value: `:_record_class`
|
|
|
|
|
|
<a name="inheritance.auto_cast_column_name"></a>`inheritance.auto_cast_column_name` Determines the name of the column used when identifying that the loaded records should be casted to its correctly model. This will be TRUE for the records mentioned on `cast_records`.
|
|
|
Default value: `:_auto_cast` |
|
|
\ No newline at end of file |