FutureStateMobile / AppCore.Data

A Portable, cross-platform, light weight, opinionated ORM designed to work across multiple Databases
9 stars 5 forks source link

Table names should be able to use inflections other than "S" #1

Closed ChaseFlorell closed 10 years ago

ChaseFlorell commented 10 years ago

Problem

Right now we just take the model name and singularize / pluralize it.

UserModel     =>   Users     |  User

This doesn't work with some Model names

[Model Name]   |   [Plural]  |  [Singular]
---------------------------------------------
MediaModel    =>   Medias    |  Media      ✗
MediumModel   =>   Media     |  Medium     ✔  (this is what it should be)

AddressModel  =>   Addresss  |  Address    ✗
AddressModel  =>   Addresses |  Address    ✔  (also what it should be)

Solution

We need to find / implement an Inflection Library to handle this.

ChaseFlorell commented 10 years ago

Fixed