EntityLegalDocumentAcceptance.php in Entity Legal 8.2
File
src/Plugin/migrate/source/EntityLegalDocumentAcceptance.php
View source
<?php
namespace Drupal\entity_legal\Plugin\migrate\source;
use Drupal\migrate_drupal\Plugin\migrate\source\d7\FieldableEntity;
class EntityLegalDocumentAcceptance extends FieldableEntity {
public function query() {
return $this
->select('entity_legal_document_acceptance', 'a')
->fields('a');
}
public function fields() {
return [
'aid' => $this
->t('The entity ID of this agreement.'),
'document_version_name' => $this
->t('The name of the document version this acceptance is bound to.'),
'uid' => $this
->t('The author of the acceptance.'),
'acceptance_date' => $this
->t('The date the document was accepted.'),
'data' => $this
->t('A dump of user data to help verify acceptances.'),
];
}
public function getIds() {
$ids['aid']['type'] = 'integer';
return $ids;
}
}