viacreative / sudo-su

Laravel package to easily login as other users during development.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

enhancement: Be able to show customized attribute from User

robsoncombr opened this issue · comments

Hello.

On user-selector.blade.php you use the 'name' attribute to show available users.

In my system it comes blank, because I don't save names in User model.

I would like to suggest a change, we could be able to specify what user attribute we want to display in selector, for example on my case I would like to show 'username' other people could prefer 'email' etc.

It would be nice to have this option in configuration file.

Thank you.

Robson

Yeah, we talked about simply publishing the view so you could change it however you see fit.

Something personal, I do not like to have several views published in my resources folder.. Mainly because the package is not loaded in production so there is no reason to have views published. I would still believe that a simple variable in config to set the attribute we wish to show would be the best solution, but again only something personal.
Thank you.