Loading simple_user_management.info.yml +1 −2 Original line number Diff line number Diff line name: Simple User Management type: module description: Interface for clients to manage their users for approving and delegating roles. core: 8.x core_version_requirement: ^8 || ^9 core_version_requirement: ^8 || ^9 || ^10 package: Custom dependencies: - role_delegation:role_delegation simple_user_management.module +0 −7 Original line number Diff line number Diff line Loading @@ -5,9 +5,7 @@ * Contains simple_user_management.module.. */ use Drupal\Core\Access\AccessResult; use Drupal\Core\Routing\RouteMatchInterface; use Drupal\Core\Session\AccountInterface; use Drupal\Core\Entity\EntityInterface; use Drupal\Core\Url; use Drupal\role_delegation\DelegatableRoles; Loading Loading @@ -38,11 +36,6 @@ function simple_user_management_help($route_name, RouteMatchInterface $route_mat /** * Implements hook_entity_operation_alter(). * * @param array $operations * The operations. * @param \Drupal\Core\Entity\EntityInterface $entity * The entity being operated on. */ function simple_user_management_entity_operation_alter(array &$operations, EntityInterface $entity) { if ($entity->getEntityTypeId() == 'user') { Loading src/Form/UserApprovalForm.php +1 −2 Original line number Diff line number Diff line Loading @@ -6,10 +6,9 @@ use Drupal\Core\Form\FormBase; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Url; use Drupal\user\Entity\User; use Symfony\Component\HttpFoundation\RedirectResponse; /** * Class UserApprovalForm. * A form to approve an inactive user. * * @package Drupal\simple_user_management\Form */ Loading src/Form/UserDeactivateForm.php +20 −26 Original line number Diff line number Diff line Loading @@ -9,7 +9,7 @@ use Drupal\user\Entity\User; use Drupal\role_delegation\DelegatableRoles; /** * Class UserDeactivateForm. * A form to deactivate an active user. * * @package Drupal\simple_user_management\Form */ Loading Loading @@ -112,13 +112,6 @@ class UserDeactivateForm extends FormBase { return $form; } /** * {@inheritdoc} */ public function validateForm(array &$form, FormStateInterface $form_state) { parent::validateForm($form, $form_state); } /** * {@inheritdoc} */ Loading @@ -136,4 +129,5 @@ class UserDeactivateForm extends FormBase { $message = $this->t('The user has been successfully deactivated.'); \Drupal::messenger()->addMessage($message, 'status'); } } src/Routing/RouteSubscriber.php +1 −1 File changed.Contains only whitespace changes. Show changes Loading
simple_user_management.info.yml +1 −2 Original line number Diff line number Diff line name: Simple User Management type: module description: Interface for clients to manage their users for approving and delegating roles. core: 8.x core_version_requirement: ^8 || ^9 core_version_requirement: ^8 || ^9 || ^10 package: Custom dependencies: - role_delegation:role_delegation
simple_user_management.module +0 −7 Original line number Diff line number Diff line Loading @@ -5,9 +5,7 @@ * Contains simple_user_management.module.. */ use Drupal\Core\Access\AccessResult; use Drupal\Core\Routing\RouteMatchInterface; use Drupal\Core\Session\AccountInterface; use Drupal\Core\Entity\EntityInterface; use Drupal\Core\Url; use Drupal\role_delegation\DelegatableRoles; Loading Loading @@ -38,11 +36,6 @@ function simple_user_management_help($route_name, RouteMatchInterface $route_mat /** * Implements hook_entity_operation_alter(). * * @param array $operations * The operations. * @param \Drupal\Core\Entity\EntityInterface $entity * The entity being operated on. */ function simple_user_management_entity_operation_alter(array &$operations, EntityInterface $entity) { if ($entity->getEntityTypeId() == 'user') { Loading
src/Form/UserApprovalForm.php +1 −2 Original line number Diff line number Diff line Loading @@ -6,10 +6,9 @@ use Drupal\Core\Form\FormBase; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Url; use Drupal\user\Entity\User; use Symfony\Component\HttpFoundation\RedirectResponse; /** * Class UserApprovalForm. * A form to approve an inactive user. * * @package Drupal\simple_user_management\Form */ Loading
src/Form/UserDeactivateForm.php +20 −26 Original line number Diff line number Diff line Loading @@ -9,7 +9,7 @@ use Drupal\user\Entity\User; use Drupal\role_delegation\DelegatableRoles; /** * Class UserDeactivateForm. * A form to deactivate an active user. * * @package Drupal\simple_user_management\Form */ Loading Loading @@ -112,13 +112,6 @@ class UserDeactivateForm extends FormBase { return $form; } /** * {@inheritdoc} */ public function validateForm(array &$form, FormStateInterface $form_state) { parent::validateForm($form, $form_state); } /** * {@inheritdoc} */ Loading @@ -136,4 +129,5 @@ class UserDeactivateForm extends FormBase { $message = $this->t('The user has been successfully deactivated.'); \Drupal::messenger()->addMessage($message, 'status'); } }