Project

General

Profile

« Previous | Next » 

Revision 4265

Added by Eric Davis over 14 years ago

Refactor: change :id on WikiController to use :project_id

Using :id to track projects on non-project controllers is confusing and
makes routing with resources difficult.

View differences:

redmine.rb
195 195
  menu.push :calendar, { :controller => 'calendars', :action => 'show' }, :param => :project_id, :caption => :label_calendar
196 196
  menu.push :news, { :controller => 'news', :action => 'index' }, :param => :project_id, :caption => :label_news_plural
197 197
  menu.push :documents, { :controller => 'documents', :action => 'index' }, :param => :project_id, :caption => :label_document_plural
198
  menu.push :wiki, { :controller => 'wiki', :action => 'index', :page => nil }, 
198
  menu.push :wiki, { :controller => 'wiki', :action => 'index', :page => nil }, :param => :project_id,
199 199
              :if => Proc.new { |p| p.wiki && !p.wiki.new_record? }
200 200
  menu.push :boards, { :controller => 'boards', :action => 'index', :id => nil }, :param => :project_id,
201 201
              :if => Proc.new { |p| p.boards.any? }, :caption => :label_board_plural

Also available in: Unified diff