diff --git a/Career/Resources/Packages/Parental.md b/Career/Resources/Packages/Parental.md new file mode 100644 index 0000000..1026744 --- /dev/null +++ b/Career/Resources/Packages/Parental.md @@ -0,0 +1,11 @@ +https://github.com/tighten/parental + +A Laravel package that implements Single Table Inheritance (STI) for Eloquent models. Allows extending parent models while referencing the same database table, enabling model-specific behavior without separate tables. + +**Key features:** +- Automatic type column management to track model types +- `become()` method for transitioning models between types +- Relationship eager loading helpers for child models (`childrenWith`, `loadChildren`) +- Laravel Nova integration + +Useful for scenarios like user roles (Admin, Guest) or order states (Pending, Shipped) where models share database structure but need distinct functionality.