protected function StringDatabaseStorage::dbFieldTable in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/modules/locale/src/StringDatabaseStorage.php \Drupal\locale\StringDatabaseStorage::dbFieldTable()
Gets table alias for field.
Parameters
string $field: One of the field names of the locales_source, locates_location, locales_target tables to find the table alias for.
Return value
string One of the following values:
- 's' for "source", "context", "version" (locales_source table fields).
- 'l' for "type", "name" (locales_location table fields)
- 't' for "language", "translation", "customized" (locales_target table fields)
1 call to StringDatabaseStorage::dbFieldTable()
- StringDatabaseStorage::dbStringSelect in core/
modules/ locale/ src/ StringDatabaseStorage.php - Builds a SELECT query with multiple conditions and fields.
File
- core/
modules/ locale/ src/ StringDatabaseStorage.php, line 257 - Contains \Drupal\locale\StringDatabaseStorage.
Class
- StringDatabaseStorage
- Defines a class to store localized strings in the database.
Namespace
Drupal\localeCode
protected function dbFieldTable($field) {
if (in_array($field, array(
'language',
'translation',
'customized',
))) {
return 't';
}
elseif (in_array($field, array(
'type',
'name',
))) {
return 'l';
}
else {
return 's';
}
}