本文整理汇总了PHP中Drupal\views\Tests\ViewUnitTestBase::schemaDefinition方法的典型用法代码示例。如果您正苦于以下问题:PHP ViewUnitTestBase::schemaDefinition方法的具体用法?PHP ViewUnitTestBase::schemaDefinition怎么用?PHP ViewUnitTestBase::schemaDefinition使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Drupal\views\Tests\ViewUnitTestBase
的用法示例。
在下文中一共展示了ViewUnitTestBase::schemaDefinition方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: schemaDefinition
/**
* {@inheritdoc}
*/
protected function schemaDefinition()
{
$schema = parent::schemaDefinition();
$schema['views_test_data']['fields']['status'] = array('description' => 'The status of this record', 'type' => 'varchar', 'length' => 255, 'not null' => TRUE, 'default' => '');
return $schema;
}
示例2: schemaDefinition
/**
* {@inheritdoc}
*/
public function schemaDefinition()
{
$schema = parent::schemaDefinition();
$schema['views_test_data']['fields']['destroyed'] = array('description' => "The destruction date of this record", 'type' => 'int', 'unsigned' => TRUE, 'not null' => FALSE, 'default' => 0);
return $schema;
}
示例3: schemaDefinition
protected function schemaDefinition()
{
$schema = parent::schemaDefinition();
$schema['views_test_data']['fields']['description'] = array('description' => "A person's description", 'type' => 'text', 'not null' => FALSE, 'size' => 'big');
return $schema;
}
示例4: schemaDefinition
/**
* Allow {views_test_data}.job to be NULL.
*/
protected function schemaDefinition()
{
$schema = parent::schemaDefinition();
unset($schema['views_test_data']['fields']['job']['not null']);
return $schema;
}
示例5: schemaDefinition
/**
* Overrides \Drupal\views\Tests\ViewTestBase::schemaDefinition().
*/
protected function schemaDefinition()
{
$schema = parent::schemaDefinition();
$schema['views_test_data']['fields']['langcode'] = array('description' => 'The {language}.langcode of this beatle.', 'type' => 'varchar', 'length' => 12, 'default' => '');
return $schema;
}