protected function WebformSubmissionDevelGenerateTrait::getUsers in Webform 6.x
Same name and namespace in other branches
- 8.5 src/Plugin/DevelGenerate/WebformSubmissionDevelGenerateTrait.php \Drupal\webform\Plugin\DevelGenerate\WebformSubmissionDevelGenerateTrait::getUsers()
Retrieve 50 uids from the database.
Return value
array An array of uids.
1 call to WebformSubmissionDevelGenerateTrait::getUsers()
- WebformSubmissionDevelGenerateTrait::initializeGenerate in src/
Plugin/ DevelGenerate/ WebformSubmissionDevelGenerateTrait.php - Add 'users' that contains a list of uids.
File
- src/
Plugin/ DevelGenerate/ WebformSubmissionDevelGenerateTrait.php, line 379
Class
- WebformSubmissionDevelGenerateTrait
- Provides a WebformSubmissionDevelGenerate plugin.
Namespace
Drupal\webform\Plugin\DevelGenerateCode
protected function getUsers() {
$users = [];
$result = $this->database
->queryRange('SELECT uid FROM {users}', 0, 50);
foreach ($result as $record) {
$users[] = $record->uid;
}
return $users;
}