Yii2 User management extension for the advanced template

I’m struggling with a yii2 User management extension for the advanced template.

First I tried 2amigos / yii2-usuario but it’s hopelessly out of date and no longer loads in composer, bringing up rows of incompatibilities.

I’ve tried yii2-usuario-2.0.0-dev but it doesn’t use composer and I failed to configure it, I ended up wasting hours of chasing error messages.

I’ve tried to use a User management extension mdmsoft / yii2-admin which I did get part working but I found was hopelessly out of date.

If you were starting a yii2 advanced template bootstrap 5 website today, which User GUI extension would you use?

Do you have complex requirements for User management?
If you do and any of those works, you can fork and maintain, or even ask to be added to repo as maintainer. I believe they’ll be happy to see their works do not go 6 feet under.

If your requirement are simple, some Gii crud with some little effort should make a decent simple user management module

We’re using usuario extensively, without any problems.
What exactly is out-of-date and which composer errors do you get?

If you start off by dowloading a fresh yii2 install which seems to use Bootstrap 5 then usuario will not install because it depends of an older version of Bootstrap (3 ?).

As far as I can tell there may be a Bootstrap 5 compatible usuario but it isn’t listed yet on Packagist, the default Composer package repository.

Yeah, there are issues about BS5:

This is a general problem, but asset management with composer in Yii2 makes it even more difficult.

Usuario v2.0.0-dev DOES use composer …

  • composer require 2amigos/yii2-usuario dev-v2.0.0-dev

Should work correctly for both new Basic and new Advanced installations. Remember to follow the installation guides. There are differences between the Basic and Advanced app requirements.

One issue that is very badly explained is " Remember that you have to configure the AuthManager component first." which appears almost as an afterthought in the install notes. YOU HAVE TO CONFIGURE AUTH MANAGER

Check you have this in your config:

        'authManager' => [
            'class' => 'Da\User\Component\AuthDbManagerComponent',

Finally ( and obviously) you also require yii2-bootrap5, twbs/bootstrap-icons, and kartik-v/yii2-widget-select2. Then set the kartik bsversion parameter to 5.0

It may not be an expected answer, but I believe that Making your own User Management UI would sometimes be a nice choice.

Since your needs for user management differ from app to app, any ready-made user management extension tends to be too complicated/bloated, or falls too short for your specific app.

I usually write my own User Management UI module starting from Gii genarated CRUD for user table. Basically, what I have to write additionally is only a page for Assigning Roles to User. It’s relatively simpler and more straight-forward than using and customizing 3rd party extensions.