Skip to content

Commit

Permalink
try commenting out computed field defintion to see if it affects test…
Browse files Browse the repository at this point in the history
… failures I cannot view
  • Loading branch information
alexfinnarn committed Jan 17, 2024
1 parent 8e09dc3 commit 179bdc6
Showing 1 changed file with 14 additions and 14 deletions.
28 changes: 14 additions & 14 deletions docroot/modules/custom/va_gov_api/va_gov_api.module
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
* Defines the hooks for va_gov_api module.
*/

use Drupal\Core\Entity\EntityTypeInterface;
use Drupal\Core\Field\BaseFieldDefinition;
use Drupal\Core\Field\FieldStorageDefinitionInterface;
//use Drupal\Core\Entity\EntityTypeInterface;
//use Drupal\Core\Field\BaseFieldDefinition;
//use Drupal\Core\Field\FieldStorageDefinitionInterface;

/**
* Implements hook_entity_bundle_field_info().
Expand All @@ -16,14 +16,14 @@ use Drupal\Core\Field\FieldStorageDefinitionInterface;
*
* @see core_event_dispatcher.module#L26
*/
function va_gov_api_entity_bundle_field_info(EntityTypeInterface $entity_type, $bundle, array $base_field_definitions) {
if ($bundle === 'full_width_banner_alert') {
$base_field_definitions['computed_situations_updates'] = BaseFieldDefinition::create('map')
->setName('computed_situations_updates')
->setLabel(t('Computed Situation Updates'))
->setComputed(TRUE)
->setClass('\Drupal\va_gov_api\Field\ComputedSituationUpdatesItemList')
->setCardinality(FieldStorageDefinitionInterface::CARDINALITY_UNLIMITED);
}
return $base_field_definitions;
}
//function va_gov_api_entity_bundle_field_info(EntityTypeInterface $entity_type, $bundle, array $base_field_definitions) {
// if ($bundle === 'full_width_banner_alert') {
// $base_field_definitions['computed_situations_updates'] = BaseFieldDefinition::create('map')
// ->setName('computed_situations_updates')
// ->setLabel(t('Computed Situation Updates'))
// ->setComputed(TRUE)
// ->setClass('\Drupal\va_gov_api\Field\ComputedSituationUpdatesItemList')
// ->setCardinality(FieldStorageDefinitionInterface::CARDINALITY_UNLIMITED);
// }
// return $base_field_definitions;
//}

0 comments on commit 179bdc6

Please sign in to comment.