bonjour,
je suis en train de mettre à jour mes routes pour utiliser le edge,
mais depuis que j’utilise has_many ma deuxième route
“map.resources :faqs, :collection => { :search => :get }” ne marche
ne pluus
http://localhost:3000/faqs/search
ca me retourne une erreur 404
mon log
Processing FaqsController#show (for 192.168.1.66 at 2007-10-29
12:29:36) [GET]
Session ID: 88ac3fa2b208f48dbcd8a95df2d6c3d5
Parameters: {“action”=>“show”, “id”=>“search”, “controller”=>“faqs”}
Asked for a remote server ? nil, ENV[“FERRET_USE_LOCAL_INDEX”] is nil,
looks like we are not the server
Will use local index.
using index in /var/www/apps/wexpay/releases/20071025190205/index/
development/faq
default field list: [:questionfr, :reponsefr]
Faq Columns (0.002366)
SELECT
cols.COLUMN_NAME as ColName,
cols.COLUMN_DEFAULT as DefaultValue,
cols.NUMERIC_SCALE as numeric_scale,
cols.NUMERIC_PRECISION as numeric_precision,
cols.DATA_TYPE as ColType,
cols.IS_NULLABLE As IsNullable,
COL_LENGTH(cols.TABLE_NAME, cols.COLUMN_NAME) as Length,
COLUMNPROPERTY(OBJECT_ID(cols.TABLE_NAME), cols.COLUMN_NAME,
‘IsIdentity’) as IsIdentity,
cols.NUMERIC_SCALE as Scale
FROM INFORMATION_SCHEMA.COLUMNS cols
WHERE cols.TABLE_NAME = ‘questions’
SQL (0.000835) SELECT * FROM questions WHERE (questions.[id] = 0)
Rendering /var/www/apps/wexpay/releases/20071025190205/public/404.html
(404)
Filter chain halted as
[#<ActionController::Filters::ClassMethods::SymbolFilter:0xb70eda28
@filter=:find_faq>] rendered_or_redirected.
Completed in 0.01221 (81 reqs/sec) | Rendering: 0.00062 (5%) | DB:
0.00320 (26%) | 404 Not Found [http://beta.expay.local/faqs/search]
toutes mes routes
map.resources :faq_categories, :has_many => [:faq]
map.resources :faqs, :has_many => [:comments, :votes]
map.resources :pays_distributeurs,
:collection => { :sort => :put }
map.resources :distributeurs,
:name_prefix => ‘all_’,
:collection => { :search => :get }
map.resources :faqs, :collection => { :search => :get }
map.root :controller => “fr”
map.logout ‘/logout’, :controller => ‘sessions’, :action => ‘destroy’
map.activate ‘/activate’, :controller => ‘users’, :action =>
‘activate’
map.index ‘’, :controller => “fr”, :action => “index”
merci