Dashboard::useModel not working with Trait's boot(), however it works fine in the orchid:admin artisan command #2585
Unanswered
mabdelfattah
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Simply, I have a trait that is generating a default value for a (NOT NULL) column called referral_code. However, when I use Orchid to create a new user, I keep getting the database error that orchid is trying to create the insert query with null value for that column "referral_code".
On the other side, when I use "php artisan orchid:admin", it works perfectly and the Trait's boot() works as expected.
Here is my service provider
My User model
Trait (simplified)
Beta Was this translation helpful? Give feedback.
All reactions