Forum: Ruby on Rails Inflections.rb in spanish

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
48ae1944e6a82dffa18694663e72c931?d=identicon&s=25 Pedro Visintin (peterpunk)
on 2006-04-10 05:43
Hi:

I have a problem with the plural of fracancia, I got fragancium but in
spanish is fragancia.

I modified inflections in environment.rb

Inflector.inflections do |i|
    i.irregular 'fragancia',       'fragancias'
end

but is ignored.

The solution that I found was comment this inflection on inflections.rb

  #inflect.singular(/([ti])a$/i, '\1um')

Any idea?

thanks

P
E28c35323f624b8b9ed8712e25105454?d=identicon&s=25 Ray Baxter (Guest)
on 2006-04-10 07:21
(Received via mailing list)
Pedro Visintin wrote:
>
> but is ignored.


Did you restart your server after you made this change?

The config is only loaded once, unlike application code.

Assuming that fragancias is the plural of fragancia, your code should be
working.

If fragancia is the plural of fracanica, as you stated in your first
sentence, you need to change your code.

--

Ray
48ae1944e6a82dffa18694663e72c931?d=identicon&s=25 Pedro Visintin (peterpunk)
on 2006-04-10 13:46
Ray Baxter wrote:
> Pedro Visintin wrote:
>>
>> but is ignored.
>
>
> Did you restart your server after you made this change?
>
> The config is only loaded once, unlike application code.
>
> Assuming that fragancias is the plural of fragancia, your code should be
> working.
>
> If fragancia is the plural of fracanica, as you stated in your first
> sentence, you need to change your code.
>
> --
>
> Ray

Ray:

Im running through dispatch.rb via rewrite in .htaccess.
 I restarted apache, but still same error.

Unknown column 'estilos_fragancias.fragancium_id

Thanks

P
48ae1944e6a82dffa18694663e72c931?d=identicon&s=25 Pedro Visintin (peterpunk)
on 2006-04-10 16:46
> Ray:
>
> Im running through dispatch.rb via rewrite in .htaccess.
>  I restarted apache, but still same error.
>
> Unknown column 'estilos_fragancias.fragancium_id
>
> Thanks
>
> P

I dont know if Inflector.inflections has effect on environment.rb. How
can I check that?

This issue starts when upgraded form rails 1.0 to 1.1.0 and 1.1.1.

Is a bug of rails 1.1.x?

Any Idea?

thanks

P
E28c35323f624b8b9ed8712e25105454?d=identicon&s=25 Ray Baxter (Guest)
on 2006-04-10 16:48
(Received via mailing list)
Pedro Visintin wrote:

>>> but is ignored.
>>
>> Did you restart your server after you made this change?
>
>
> Im running through dispatch.rb via rewrite in .htaccess.
>  I restarted apache, but still same error.
>
> Unknown column 'estilos_fragancias.fragancium_id

I don't know running via dispatch.rb.

I would try running through webrick to verify that your inflection rule
is working correctly and then work on the configuration issue.

--

Ray
48ae1944e6a82dffa18694663e72c931?d=identicon&s=25 Pedro Visintin (peterpunk)
on 2006-04-10 16:54
Ray Baxter wrote:
> Pedro Visintin wrote:
>
>>>> but is ignored.
>>>
>>> Did you restart your server after you made this change?
>>
>>
>> Im running through dispatch.rb via rewrite in .htaccess.
>>  I restarted apache, but still same error.
>>
>> Unknown column 'estilos_fragancias.fragancium_id
>
> I don't know running via dispatch.rb.
>
> I would try running through webrick to verify that your inflection rule
> is working correctly and then work on the configuration issue.
>
> --
>
> Ray

Ray:

I cannot use webrick because I get Lost Connection to MySql during
query.

Im not root on server, is a shared hosting.

So Im in trouble :-(

Thanks

P
This topic is locked and can not be replied to.