Skip to content

PascaleCase TableName become Tablename #9

@wutever0

Description

@wutever0

e.g. ServiceRelatedRequest table gets generated as Servicerelatedrequest domain class regardless of configurations.

Seems the TextInfo.ToTitleCase method considers the text "ServiceRelatedRequest" as one word and simply converts that to "Servicerelatedrequest".

When receiving the text as "Service_Related_Request" it converts it correctly to ServiceRelatedRequest.

Workaround
I found that the AbstractTextFormatter had a line to add these underscores but was commented out (TextFormatter.cs Line 32). When I uncommented this line it fixed ClassNames but generated property names (which were originally PascalCase) with underscore. Explicity using the "PascalCase" configuration option worked around this.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions