PermissionManager
PermissionManager copied to clipboard
Use authentication column
This is for issue #213 creates a new field and column allowing for custom authentication column. Also adds that necessary requirement for it.
Note: Email is still a required field. I can't think of any apps that don't really use an email for something.


- Non-Breaking Change
- Tested it on a live product and fresh install.
Hello @AbbyJanke hope you are doing fine 👍
I have this issue on my back to close 4.1 board, I know it's old but anyway, if you re-call what this does is:
- If autentication column is different than email, it adds the column/the field and setup a new field validation
But it still requires email.
I half agree with you that most apps use email even if it's not used as auth column, but I think that people that does not use email as auth column, the email column might not be required.
@tabacitu i'd like to close this, what you think it's the best approach ?
- Setup email as required
- Setup email as not required
- Don't setup email if auth column is not email
Let me know, Pedro
I'd agree with you @pxpm . Here's the way I see it:
- if somebody changed the auth column from
emailto something else, that something else is probablyusername; like... in 99% of the cases; - to be able to correctly edit that user, you'd still need to edit that
usernamecolumn; which is great, this PR does that; - we have NO IDEA if the
emailcolumn exists; so we should either:- (a) check if the
emailcolumn is present, and only add a field for it then; (also needs this change in the FormRequest) - (b) assume the
emailcolumn is gone;
- (a) check if the
I think the best way to proceed would be with option (a), basically on top of this PR:
- [ ] check if
emailcolumn exists before adding a field for it; - [ ] check if
emailcolumn exists before making it required inside the FormRequest;
In any case, I believe this will make it a breaking change. So when we merge this we should bump the package version and provide an upgrade guide in README.md, just to be safe.
Hey @AbbyJanke - long time no see. I do agree with doing this, but since nobody actually asked for this in so long... I think it's safe to just close it, to be honest.
If more people say they need it, let's do it 💪 I've outlined how I see this coming along above.
Sorry to take so long Abby. Haven't heard from you in a while either, hope you're good.
Cheers!