Skip to content

Instantly share code, notes, and snippets.

@dpi
Created March 15, 2019 09:21
Show Gist options
  • Save dpi/9be63e42dfd08d75aa99be4b9d39701a to your computer and use it in GitHub Desktop.
Save dpi/9be63e42dfd08d75aa99be4b9d39701a to your computer and use it in GitHub Desktop.
revision_translation_affected for test entities

Getting issues like?

Drupal\Core\Entity\Query\QueryException: 'revision_translation_affected' not found in Drupal\Core\Entity\Query\Sql\Tables->ensureEntityTable() (line 351 of core/lib/Drupal/Core/Entity/Query/Sql/Tables.php).
Drupal\Core\Entity\Query\Sql\Tables->addField('revision_translation_affected', 'INNER', 'en') (Line: 52)
Drupal\Core\Entity\Query\Sql\Condition->compile(Object) (Line: 172)
Drupal\Core\Entity\Query\Sql\Query->compile() (Line: 80)
Drupal\Core\Entity\Query\Sql\Query->execute() (Line: 433)
Drupal\Core\Entity\ContentEntityStorageBase->getLatestTranslationAffectedRevisionId('1', 'en') (Line: 157)
Drupal\content_moderation\ModerationInformation->hasPendingRevision(Object) (Line: 58)
Drupal\content_moderation\Access\LatestRevisionCheck->access(Object, Object, Object)
Drupal\Core\Access\AccessManager->performCheck('access_check.latest_revision', Object) (Line: 135)
Drupal\Core\Access\AccessManager->check(Object, Object, NULL, 1) (Line: 92)

Ensure your entity type has a data_table/revision_data_table entry in @ContentEntityType annotation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment