diff --git a/CHANGELOG_DEV.md b/CHANGELOG_DEV.md index 6dd41a43a7..32dbf1a00a 100644 --- a/CHANGELOG_DEV.md +++ b/CHANGELOG_DEV.md @@ -10,6 +10,7 @@ - Fix #4830: Fix Prerequisites / Self Test translations - Fix #4459: Make UserFollow activity public - Enh #3824: Run acceptance tests with pretty URLs +- Enh #5169: Enable more than 50 groups to a user 1.9.0-beta.1 (June 15, 2021) diff --git a/protected/humhub/compat/HForm.php b/protected/humhub/compat/HForm.php index 3045eb9c67..0c4d870f6e 100644 --- a/protected/humhub/compat/HForm.php +++ b/protected/humhub/compat/HForm.php @@ -259,7 +259,8 @@ class HForm extends \yii\base\Component case 'multiselectdropdown': $field = $this->form->field($model, $name)->widget(MultiSelect::class, [ 'items' => $definition['items'], - 'options' => $definition['options'] + 'options' => $definition['options'], + 'maxSelection' => $definition['maxSelection'] ?? 50, ]); break; case 'dropdownlist': diff --git a/protected/humhub/modules/admin/controllers/UserController.php b/protected/humhub/modules/admin/controllers/UserController.php index fb7852fbcd..be31e6c23a 100644 --- a/protected/humhub/modules/admin/controllers/UserController.php +++ b/protected/humhub/modules/admin/controllers/UserController.php @@ -149,6 +149,7 @@ class UserController extends Controller 'data-placeholder' => Yii::t('AdminModule.user', 'Select Groups'), 'data-placeholder-more' => Yii::t('AdminModule.user', 'Add Groups...') ], + 'maxSelection' => 250, 'isVisible' => Yii::$app->user->can(new ManageGroups()) ], ],