function Role::prepareRow
Same name in this branch
- 9 core/modules/user/src/Plugin/migrate/source/d6/Role.php \Drupal\user\Plugin\migrate\source\d6\Role::prepareRow()
Same name in other branches
- 8.9.x core/modules/user/src/Plugin/migrate/source/d6/Role.php \Drupal\user\Plugin\migrate\source\d6\Role::prepareRow()
- 8.9.x core/modules/user/src/Plugin/migrate/source/d7/Role.php \Drupal\user\Plugin\migrate\source\d7\Role::prepareRow()
- 10 core/modules/user/src/Plugin/migrate/source/d6/Role.php \Drupal\user\Plugin\migrate\source\d6\Role::prepareRow()
- 10 core/modules/user/src/Plugin/migrate/source/d7/Role.php \Drupal\user\Plugin\migrate\source\d7\Role::prepareRow()
- 11.x core/modules/user/src/Plugin/migrate/source/d6/Role.php \Drupal\user\Plugin\migrate\source\d6\Role::prepareRow()
- 11.x core/modules/user/src/Plugin/migrate/source/d7/Role.php \Drupal\user\Plugin\migrate\source\d7\Role::prepareRow()
Overrides SourcePluginBase::prepareRow
File
-
core/
modules/ user/ src/ Plugin/ migrate/ source/ d7/ Role.php, line 44
Class
- Role
- Drupal 7 role source from database.
Namespace
Drupal\user\Plugin\migrate\source\d7Code
public function prepareRow(Row $row) {
$permissions = $this->select('role_permission', 'rp')
->fields('rp', [
'permission',
])
->condition('rid', $row->getSourceProperty('rid'))
->execute()
->fetchCol();
$row->setSourceProperty('permissions', $permissions);
return parent::prepareRow($row);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.