diff --git a/recurring_events.views.inc b/recurring_events.views.inc index 36e6714310b4951027f7584e2236eb0ea4d39128..98cfb61a954aee1ce214c1723cf382d54559471a 100644 --- a/recurring_events.views.inc +++ b/recurring_events.views.inc @@ -38,6 +38,18 @@ function recurring_events_views_data_alter(array &$data) { 'id' => 'eventinstance_title', 'field_name' => 'title', ], + 'filter' => [ + 'title' => t('Event instance title'), + 'help' => t('The inherited title of an event instance.'), + 'id' => 'eventinstance_title', + 'field_name' => 'title', + ], + 'sort' => [ + 'title' => t('Event instance title'), + 'help' => t('The inherited title of an event instance.'), + 'id' => 'eventinstance_title', + 'field_name' => 'title', + ], ]; // Create a field to show the inherited description of an event instance. @@ -49,5 +61,17 @@ function recurring_events_views_data_alter(array &$data) { 'id' => 'eventinstance_description', 'field_name' => 'description', ], + 'filter' => [ + 'title' => t('Event instance description'), + 'help' => t('The inherited description of an event instance.'), + 'id' => 'eventinstance_description', + 'field_name' => 'description', + ], + 'sort' => [ + 'title' => t('Event instance description'), + 'help' => t('The inherited description of an event instance.'), + 'id' => 'eventinstance_description', + 'field_name' => 'description', + ], ]; } diff --git a/src/Plugin/views/filter/EventInstanceDescription.php b/src/Plugin/views/filter/EventInstanceDescription.php new file mode 100644 index 0000000000000000000000000000000000000000..170550d244aeae020e745b589233a3dc83bb7d3d --- /dev/null +++ b/src/Plugin/views/filter/EventInstanceDescription.php @@ -0,0 +1,16 @@ +<?php + +namespace Drupal\recurring_events\Plugin\views\filter; + +use Drupal\views\Plugin\views\filter\StringFilter; + +/** + * Filter handler for the inherited event instance description. + * + * @ingroup views_filter_handlers + * + * @ViewsFilter("eventinstance_description") + */ +class EventInstanceDescription extends StringFilter { + +} diff --git a/src/Plugin/views/filter/EventInstanceTitle.php b/src/Plugin/views/filter/EventInstanceTitle.php new file mode 100644 index 0000000000000000000000000000000000000000..8d090032f4c2b29b96571ee79080b7c27431aee6 --- /dev/null +++ b/src/Plugin/views/filter/EventInstanceTitle.php @@ -0,0 +1,16 @@ +<?php + +namespace Drupal\recurring_events\Plugin\views\filter; + +use Drupal\views\Plugin\views\filter\StringFilter; + +/** + * Filter handler for the inherited event instance title. + * + * @ingroup views_filter_handlers + * + * @ViewsFilter("eventinstance_title") + */ +class EventInstanceTitle extends StringFilter { + +} diff --git a/src/Plugin/views/sort/EventInstanceDescription.php b/src/Plugin/views/sort/EventInstanceDescription.php new file mode 100644 index 0000000000000000000000000000000000000000..1504f6696b75e4a516f1983d86275b5eb69b6ed0 --- /dev/null +++ b/src/Plugin/views/sort/EventInstanceDescription.php @@ -0,0 +1,16 @@ +<?php + +namespace Drupal\recurring_events\Plugin\views\sort; + +use Drupal\views\Plugin\views\sort\Standard; + +/** + * Sort handler for the inherited event instance description. + * + * @ingroup views_filter_handlers + * + * @ViewsSort("eventinstance_description") + */ +class EventInstanceDescription extends Standard { + +} diff --git a/src/Plugin/views/sort/EventInstanceTitle.php b/src/Plugin/views/sort/EventInstanceTitle.php new file mode 100644 index 0000000000000000000000000000000000000000..de75e901dd77b575e0510abe05b4c181d7be6119 --- /dev/null +++ b/src/Plugin/views/sort/EventInstanceTitle.php @@ -0,0 +1,16 @@ +<?php + +namespace Drupal\recurring_events\Plugin\views\sort; + +use Drupal\views\Plugin\views\sort\Standard; + +/** + * Sort handler for the inherited event instance title. + * + * @ingroup views_filter_handlers + * + * @ViewsSort("eventinstance_title") + */ +class EventInstanceTitle extends Standard { + +}