type is used for single table inheritance, I believe. So you
shouldn''t be able to use type as a normal field.
On 10/31/05, Morten <lists-Mr43XxmkdKzQT0dZR+AlfA@public.gmane.org>
wrote:>
> Hi.
>
> Rails seems to just swallow the "type" parameter from the
request. The
> below is from my development.log. Note that type=>1 in the request
> object, but is then NULL in the subsequent insert statement. Is this the
> expected behaviour?
>
> Morten
>
> Processing AdminController#add_submenu (for 127.0.0.1 at 2005-10-31
> 19:03:17) [POST]
> Parameters: {"commit"=>"Create submenu",
> "sub_menu"=>{"nav_menu_id"=>"2",
"title"=>"hsdgs", "type"=>"1"},
> "action"=>"add_submenu",
"controller"=>"admin"}
> NavSubmenu Columns (0.000691) SHOW FIELDS FROM nav_submenus
> SQL (0.000439) BEGIN
> SQL (0.000880) INSERT INTO nav_submenus (`nav_menu_id`, `title`,
> `type`) VALUES(2, ''hsdgs'', NULL)
> SQL (0.000409) COMMIT
> SQL (0.000288) BEGIN
> NavSubmenu Update (0.000920) UPDATE nav_submenus SET `title` >
''hsdgs'', `nav_menu_id` = 2, `type` = NULL WHERE id = 9
> SQL (0.000324) COMMIT
>
>
>
> _______________________________________________
> Rails mailing list
> Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org
> http://lists.rubyonrails.org/mailman/listinfo/rails
>