Skip to content

Allow make:entity specify the table name #1626

Open
@omgslinux

Description

@omgslinux

It happens that though the default is to name the table to the lowercase entity name (i.e: Task-> task), it's not unusual that the table name could be "tasks" (i.e. in plural).

So, I can think of two ways for this:

  1. Just add an extra parameter where one can specifiy the table name

  2. Explicitily prompt for the table name, and in case it's the same as the entity name, you can skip using the ORM\Table attribute in the entity file. You can default to the same name or try to guess the plural, and offer it in the prompt.

There could be a third option, changing the current idea, and it's to directly insert the plural in the entity file, and maybe encourage to review if necessary.

Thanks in advance.

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