The plural forms of autogenerated relationships are handle by
Lingua::EN::Inflect (I think), and that module will give the plural of
'person' as 'people'

Overriding the defaults is documented here:

http://search.cpan.org/~rkitover/DBIx-Class-Schema-Loader-0.05003/lib/DBIx/Class/Schema/Loader/Base.pm#inflect_plural

f

On Wed, Mar 10, 2010 at 1:15 PM, <t...@dix.cz> wrote:

>
> Hello catal[yi]sters,
>
> I'm going to be crazzy about one generated accessor name:
>
> __PACKAGE__->has_many(
>  "company_people",         # I expected to be "company_persons"
>  "Jf::Schema::Result::CompanyPerson",
>  { "foreign.role" => "self.id" },
> );
>
> Other names seems to be predictable:
>
> __PACKAGE__->has_many(
>  "company_addresses",
>  "Jf::Schema::Result::CompanyAddress",
>  { "foreign.role" => "self.id" },
> );
>
>
> I have no "people" pattern in my database. Did I miss something?
>
> The schema has been generated as usual:
>
> script/jf_create.pl model DB DBIC::Schema Jf::Schema create=static \
> 'dbi:Pg:dbname=jf' tomas
>
> Thanx,
> Tomas
>
> _______________________________________________
> List: Catalyst@lists.scsys.co.uk
> Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
> Searchable archive:
> http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
> Dev site: http://dev.catalyst.perl.org/
>
_______________________________________________
List: Catalyst@lists.scsys.co.uk
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
Dev site: http://dev.catalyst.perl.org/

Reply via email to