Skip to content

[Feature Request]: Support For tightenco/parental #1361

Description

@SamuelMwangiW

Feature Description

The tightenco/parental package is quite popular in the Laravel ecosystem.

It adds support for is-a kind of relationship e.g Admin is a user where Admin model extends User, etc

I am receiving Table Not Found helper warnings while generating eloquent helper code.

See sample models below for your reference:
namespace App\Models;

use Parental\HasParent;

class Attendee extends User
{
    use HasParent;
}
namespace App\Models;

use Parental\HasParent;

class Admin extends User
{
    use HasParent;
}
namespace App\Models;

use Illuminate\Foundation\Auth\User as Authenticatable;
use Parental\HasChildren;

class User extends Authenticatable
{
    use HasChildren;
}

And the warning pop-up

Image

These would be valid warnings without the package. With the package is installed, I wish there were a way the plugin would associate the model with the parent's table and inherit the parent attributes.

That being said, the warning is harmless and does not in any way take away the amout of quality of life improvement the plugin provides to Laravel developers. Kudos for the great work💪

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions