|
|
@@ -81,19 +81,17 @@ class ResetBeUserPermsCommand extends Command
|
|
|
|
|
|
if ($all) {
|
|
|
$connectionPool = GeneralUtility::makeInstance(ConnectionPool::class);
|
|
|
- $queryBuilder = $connectionPool->getQueryBuilderForTable('pages');
|
|
|
+ $queryBuilder = $connectionPool->getQueryBuilderForTable('ot_websites');
|
|
|
$sites = $queryBuilder
|
|
|
- ->select('tx_opentalent_structure_id')
|
|
|
- ->from('pages')
|
|
|
- ->where('is_siteroot=1')
|
|
|
- ->andWhere($queryBuilder->expr()->gt('tx_opentalent_structure_id', 0))
|
|
|
+ ->select('organization_id')
|
|
|
+ ->from('ot_websites')
|
|
|
->execute()
|
|
|
->fetchAll();
|
|
|
|
|
|
$io->progressStart(count($sites));
|
|
|
|
|
|
foreach ($sites as $site) {
|
|
|
- $org_id = $site['tx_opentalent_structure_id'];
|
|
|
+ $org_id = $site['organization_id'];
|
|
|
try {
|
|
|
$siteController->resetBeUserPermsAction($org_id, $create);
|
|
|
} catch (\Throwable $e) {
|