EntityLegalDocument.php in Entity Legal 4.0.x
File
src/Plugin/migrate/source/EntityLegalDocument.php
View source
<?php
namespace Drupal\entity_legal\Plugin\migrate\source;
use Drupal\migrate_drupal\Plugin\migrate\source\DrupalSqlBase;
class EntityLegalDocument extends DrupalSqlBase {
public function query() {
return $this
->select('entity_legal_document', 'd')
->fields('d');
}
public function fields() {
return [
'name' => $this
->t('The legal document ID.'),
'label' => $this
->t('The human-readable label of the legal document.'),
'require_signup' => $this
->t('Require new users to accept this document on signup.'),
'require_existing' => $this
->t('Require existing users to accept this document.'),
'settings' => $this
->t('An array of additional data related to the legal document.'),
];
}
public function getIds() {
$ids['name']['type'] = 'string';
return $ids;
}
}