本文整理汇总了PHP中Drupal\Core\Field\FieldItemBase::defaultStorageSettings方法的典型用法代码示例。如果您正苦于以下问题:PHP FieldItemBase::defaultStorageSettings方法的具体用法?PHP FieldItemBase::defaultStorageSettings怎么用?PHP FieldItemBase::defaultStorageSettings使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Drupal\Core\Field\FieldItemBase
的用法示例。
在下文中一共展示了FieldItemBase::defaultStorageSettings方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: defaultStorageSettings
/**
* {@inheritdoc}
*/
public static function defaultStorageSettings()
{
foreach (['first', 'second'] as $subfield) {
$settings['storage'][$subfield] = ['type' => 'string', 'maxlength' => 255, 'precision' => 10, 'scale' => 2];
}
return $settings + parent::defaultStorageSettings();
}
示例2: defaultStorageSettings
/**
* {@inheritdoc}
*/
public static function defaultStorageSettings()
{
return array('datetime_type' => 'datetime') + parent::defaultStorageSettings();
}
示例3: defaultStorageSettings
/**
* {@inheritdoc}
*/
public static function defaultStorageSettings()
{
return array('max_length' => 255, 'is_ascii' => FALSE, 'case_sensitive' => FALSE) + parent::defaultStorageSettings();
}
示例4: defaultStorageSettings
/**
* {@inheritdoc}
*/
public static function defaultStorageSettings() {
return array(
'allowed_values' => array(),
'allowed_values_function' => '',
) + parent::defaultStorageSettings();
}
示例5: defaultStorageSettings
/**
* {@inheritdoc}
*/
public static function defaultStorageSettings()
{
return array('target_type' => \Drupal::moduleHandler()->moduleExists('node') ? 'node' : 'user', 'target_bundle' => NULL) + parent::defaultStorageSettings();
}
示例6: defaultStorageSettings
/**
* {@inheritdoc}
*/
public static function defaultStorageSettings()
{
return array('mc_list_id' => '', 'double_opt_in' => 0, 'send_welcome' => 0) + parent::defaultStorageSettings();
}
示例7: defaultStorageSettings
/**
* {@inheritdoc}
*/
public static function defaultStorageSettings()
{
return array('comment_type' => '') + parent::defaultStorageSettings();
}
示例8: defaultStorageSettings
/**
* {@inheritdoc}
*/
public static function defaultStorageSettings()
{
return array('unsigned' => FALSE) + parent::defaultStorageSettings();
}
示例9: defaultStorageSettings
/**
* {@inheritdoc}
*
* @DSG: Optional.
*/
public static function defaultStorageSettings()
{
$settings = ['lorem' => 123];
return $settings + parent::defaultStorageSettings();
}
示例10: defaultStorageSettings
/**
* {@inheritdoc}
*/
public static function defaultStorageSettings()
{
$settings = array('components' => array('title' => TRUE, 'given' => TRUE, 'middle' => TRUE, 'family' => TRUE, 'generational' => TRUE, 'credentials' => TRUE), 'minimum_components' => array('title' => FALSE, 'given' => TRUE, 'middle' => FALSE, 'family' => TRUE, 'generational' => FALSE, 'credentials' => FALSE), 'allow_family_or_given' => FALSE, 'labels' => array('title' => t('Title'), 'given' => t('Given'), 'middle' => t('Middle name(s)'), 'family' => t('Family'), 'generational' => t('Generational'), 'credentials' => t('Credentials')), 'max_length' => array('title' => 31, 'given' => 63, 'middle' => 127, 'family' => 63, 'generational' => 15, 'credentials' => 255), 'autocomplete_source' => array('title' => array('title'), 'given' => array(), 'middle' => array(), 'family' => array(), 'generational' => array('generation'), 'credentials' => array()), 'autocomplete_separator' => array('title' => ' ', 'given' => ' -', 'middle' => ' -', 'family' => ' -', 'generational' => ' ', 'credentials' => ', '), 'title_options' => array(t('-- --'), t('Mr.'), t('Mrs.'), t('Miss'), t('Ms.'), t('Dr.'), t('Prof.')), 'generational_options' => array(t('-- --'), t('Jr.'), t('Sr.'), t('I'), t('II'), t('III'), t('IV'), t('V'), t('VI'), t('VII'), t('VIII'), t('IX'), t('X')), 'sort_options' => array('title' => FALSE));
return $settings + parent::defaultStorageSettings();
}
示例11: defaultStorageSettings
/**
* {@inheritdoc}
*/
public static function defaultStorageSettings()
{
return array('test_field_storage_setting' => 'dummy test string', 'changeable' => 'a changeable field storage setting', 'unchangeable' => 'an unchangeable field storage setting') + parent::defaultStorageSettings();
}
示例12: defaultStorageSettings
/**
* {@inheritdoc}
*/
public static function defaultStorageSettings()
{
$defaultStorageSettings = array('maxlength' => self::LANGUAGEFIELD_LANGCODE_MAXLENGTH, 'language_range' => array(self::LANGUAGEFIELD_LANGUAGES_PREDEFINED => self::LANGUAGEFIELD_LANGUAGES_PREDEFINED), 'included_languages' => array(), 'excluded_languages' => array(), 'groups' => '') + parent::defaultStorageSettings();
return $defaultStorageSettings;
}
示例13: defaultStorageSettings
/**
* {@inheritdoc}
*/
public static function defaultStorageSettings()
{
return array('data_type' => 'varchar', 'data_length' => 32, 'data_size' => 'normal', 'data_precision' => 10, 'data_scale' => 2) + parent::defaultStorageSettings();
}
示例14: defaultStorageSettings
/**
* {@inheritdoc}
*/
public static function defaultStorageSettings()
{
return array() + parent::defaultStorageSettings();
}
示例15: defaultStorageSettings
/**
* {@inheritdoc}
*/
public static function defaultStorageSettings()
{
return array('max_length' => 255) + parent::defaultStorageSettings();
}