当前位置: 首页>>代码示例>>PHP>>正文


PHP ViewsKernelTestBase::viewsData方法代码示例

本文整理汇总了PHP中Drupal\Tests\views\Kernel\ViewsKernelTestBase::viewsData方法的典型用法代码示例。如果您正苦于以下问题:PHP ViewsKernelTestBase::viewsData方法的具体用法?PHP ViewsKernelTestBase::viewsData怎么用?PHP ViewsKernelTestBase::viewsData使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Drupal\Tests\views\Kernel\ViewsKernelTestBase的用法示例。


在下文中一共展示了ViewsKernelTestBase::viewsData方法的12个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: viewsData

 function viewsData()
 {
     $data = parent::viewsData();
     $data['views_test_data']['age']['filter']['allow empty'] = TRUE;
     $data['views_test_data']['id']['filter']['allow empty'] = FALSE;
     return $data;
 }
开发者ID:aWEBoLabs,项目名称:taxi,代码行数:7,代码来源:FilterNumericTest.php

示例2: viewsData

 /**
  * {@inheritdoc}
  */
 protected function viewsData()
 {
     $data = parent::viewsData();
     $data['views_test_data']['table']['base']['access query tag'] = 'test_tag';
     $data['views_test_data']['table']['base']['query metadata'] = array('key1' => 'test_metadata', 'key2' => 'test_metadata2');
     return $data;
 }
开发者ID:eigentor,项目名称:tommiblog,代码行数:10,代码来源:SqlQueryTest.php

示例3: viewsData

 /**
  * {@inheritdoc}
  */
 public function viewsData()
 {
     $data = parent::viewsData();
     $data['views_test_data']['created']['field']['id'] = 'date';
     $data['views_test_data']['destroyed'] = array('title' => 'Destroyed', 'help' => 'Date in future this will be destroyed.', 'field' => array('id' => 'date'), 'argument' => array('id' => 'date'), 'filter' => array('id' => 'date'), 'sort' => array('id' => 'date'));
     return $data;
 }
开发者ID:sojo,项目名称:d8_friendsofsilence,代码行数:10,代码来源:FieldDateTest.php

示例4: viewsData

 /**
  * {@inheritdoc}
  */
 protected function viewsData()
 {
     $data = parent::viewsData();
     $data['views_test_data']['job']['field']['id'] = 'test_field';
     $data['views_test_data']['job']['field']['click sortable'] = FALSE;
     $data['views_test_data']['id']['field']['click sortable'] = TRUE;
     return $data;
 }
开发者ID:sojo,项目名称:d8_friendsofsilence,代码行数:11,代码来源:FieldKernelTest.php

示例5: viewsData

 function viewsData()
 {
     $data = parent::viewsData();
     $data['views_test_data']['name']['filter']['allow empty'] = TRUE;
     $data['views_test_data']['job']['filter']['allow empty'] = FALSE;
     $data['views_test_data']['description'] = $data['views_test_data']['name'];
     return $data;
 }
开发者ID:sojo,项目名称:d8_friendsofsilence,代码行数:8,代码来源:FilterStringTest.php

示例6: viewsData

 /**
  * {@inheritdoc}
  */
 protected function viewsData()
 {
     $data = parent::viewsData();
     // User the existing test_filter plugin.
     $data['views_test_data_alias']['table']['real table'] = 'views_test_data';
     $data['views_test_data_alias']['name_alias']['filter']['id'] = 'test_filter';
     $data['views_test_data_alias']['name_alias']['filter']['real field'] = 'name';
     return $data;
 }
开发者ID:aWEBoLabs,项目名称:taxi,代码行数:12,代码来源:HandlerAliasTest.php

示例7: viewsData

 /**
  * {@inheritdoc}
  */
 public function viewsData()
 {
     $data = parent::viewsData();
     $date_plugins = array('date_fulldate', 'date_day', 'date_month', 'date_week', 'date_year', 'date_year_month');
     foreach ($date_plugins as $plugin_id) {
         $data['views_test_data'][$plugin_id] = $data['views_test_data']['created'];
         $data['views_test_data'][$plugin_id]['real field'] = 'created';
         $data['views_test_data'][$plugin_id]['argument']['id'] = $plugin_id;
     }
     return $data;
 }
开发者ID:aWEBoLabs,项目名称:taxi,代码行数:14,代码来源:ArgumentDateTest.php

示例8: viewsData

 function viewsData()
 {
     $data = parent::viewsData();
     $data['views_test_data']['age']['field']['id'] = 'boolean';
     return $data;
 }
开发者ID:sojo,项目名称:d8_friendsofsilence,代码行数:6,代码来源:FieldBooleanTest.php

示例9: viewsData

 protected function viewsData()
 {
     $data = parent::viewsData();
     $data['views_test_data']['table']['base']['query_id'] = 'query_test';
     return $data;
 }
开发者ID:sojo,项目名称:d8_friendsofsilence,代码行数:6,代码来源:QueryTest.php

示例10: viewsData

 /**
  * {@inheritdoc}
  */
 protected function viewsData()
 {
     $data = parent::viewsData();
     $data['views_test_data']['test_cache_context'] = ['real field' => 'name', 'title' => 'Test cache context', 'filter' => ['id' => 'views_test_test_cache_context']];
     return $data;
 }
开发者ID:aWEBoLabs,项目名称:taxi,代码行数:9,代码来源:CacheTest.php

示例11: viewsData

 /**
  * {@inheritdoc}
  */
 protected function viewsData()
 {
     $views_data = parent::viewsData();
     $views_data['views_test_data']['status']['filter']['id'] = 'boolean_string';
     return $views_data;
 }
开发者ID:aWEBoLabs,项目名称:taxi,代码行数:9,代码来源:FilterBooleanOperatorStringTest.php

示例12: viewsData

 /**
  * {@inheritdoc}
  */
 protected function viewsData()
 {
     $data = parent::viewsData();
     $data['views_test_data']['langcode'] = array('title' => t('Langcode'), 'help' => t('Langcode'), 'field' => array('id' => 'language'), 'argument' => array('id' => 'language'), 'filter' => array('id' => 'language'));
     return $data;
 }
开发者ID:sojo,项目名称:d8_friendsofsilence,代码行数:9,代码来源:LanguageTestBase.php


注:本文中的Drupal\Tests\views\Kernel\ViewsKernelTestBase::viewsData方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。