@@ -233,58 +233,61 ActionController::Routing::Routes.draw do |map| | |||||
233 | repositories.with_options :conditions => {:method => :get} do |repository_views| |
|
233 | repositories.with_options :conditions => {:method => :get} do |repository_views| | |
234 | repository_views.connect 'projects/:id/repository', |
|
234 | repository_views.connect 'projects/:id/repository', | |
235 | :action => 'show' |
|
235 | :action => 'show' | |
|
236 | ||||
|
237 | repository_views.connect 'projects/:id/repository/:repository_id/statistics', | |||
|
238 | :action => 'stats' | |||
|
239 | repository_views.connect 'projects/:id/repository/:repository_id/graph', | |||
|
240 | :action => 'graph' | |||
|
241 | ||||
236 | repository_views.connect 'projects/:id/repository/statistics', |
|
242 | repository_views.connect 'projects/:id/repository/statistics', | |
237 | :action => 'stats' |
|
243 | :action => 'stats' | |
238 | repository_views.connect 'projects/:id/repository/graph', |
|
244 | repository_views.connect 'projects/:id/repository/graph', | |
239 | :action => 'graph' |
|
245 | :action => 'graph' | |
240 | repository_views.connect 'projects/:id/repository/revisions', |
|
246 | ||
|
247 | repository_views.connect 'projects/:id/repository/:repository_id/revisions', | |||
241 | :action => 'revisions' |
|
248 | :action => 'revisions' | |
242 | repository_views.connect 'projects/:id/repository/revisions.:format', |
|
249 | repository_views.connect 'projects/:id/repository/:repository_id/revisions.:format', | |
243 | :action => 'revisions' |
|
250 | :action => 'revisions' | |
244 | repository_views.connect 'projects/:id/repository/revisions/:rev', |
|
251 | repository_views.connect 'projects/:id/repository/:repository_id/revisions/:rev', | |
245 | :action => 'revision' |
|
252 | :action => 'revision' | |
246 | repository_views.connect 'projects/:id/repository/revisions/:rev/diff', |
|
253 | repository_views.connect 'projects/:id/repository/:repository_id/revisions/:rev/diff', | |
247 | :action => 'diff' |
|
254 | :action => 'diff' | |
248 | repository_views.connect 'projects/:id/repository/revisions/:rev/diff.:format', |
|
255 | repository_views.connect 'projects/:id/repository/:repository_id/revisions/:rev/diff.:format', | |
249 | :action => 'diff' |
|
256 | :action => 'diff' | |
250 | repository_views.connect 'projects/:id/repository/revisions/:rev/raw/*path', |
|
257 | repository_views.connect 'projects/:id/repository/:repository_id/revisions/:rev/raw/*path', | |
251 | :action => 'entry', :format => 'raw' |
|
258 | :action => 'entry', :format => 'raw' | |
252 | repository_views.connect 'projects/:id/repository/revisions/:rev/:action/*path', |
|
259 | repository_views.connect 'projects/:id/repository/:repository_id/revisions/:rev/:action/*path', | |
253 | :requirements => { |
|
260 | :requirements => { | |
254 | :action => /(browse|show|entry|changes|annotate|diff)/, |
|
261 | :action => /(browse|show|entry|changes|annotate|diff)/, | |
255 | :rev => /[a-z0-9\.\-_]+/ |
|
262 | :rev => /[a-z0-9\.\-_]+/ | |
256 | } |
|
263 | } | |
257 | repository_views.connect 'projects/:id/repository/raw/*path', |
|
264 | repository_views.connect 'projects/:id/repository/:repository_id/raw/*path', | |
258 | :action => 'entry', :format => 'raw' |
|
265 | :action => 'entry', :format => 'raw' | |
259 | repository_views.connect 'projects/:id/repository/:action/*path', |
|
266 | repository_views.connect 'projects/:id/repository/:repository_id/:action/*path', | |
260 | :requirements => { :action => /(browse|show|entry|changes|annotate|diff)/ } |
|
267 | :requirements => { :action => /(browse|show|entry|changes|annotate|diff)/ } | |
261 |
|
268 | |||
262 | # Same routes with a repository_id |
|
269 | repository_views.connect 'projects/:id/repository/revisions', | |
263 | repository_views.connect 'projects/:id/repository/:repository_id/statistics', |
|
|||
264 | :action => 'stats' |
|
|||
265 | repository_views.connect 'projects/:id/repository/:repository_id/graph', |
|
|||
266 | :action => 'graph' |
|
|||
267 | repository_views.connect 'projects/:id/repository/:repository_id/revisions', |
|
|||
268 | :action => 'revisions' |
|
270 | :action => 'revisions' | |
269 |
repository_views.connect 'projects/:id/repository/ |
|
271 | repository_views.connect 'projects/:id/repository/revisions.:format', | |
270 | :action => 'revisions' |
|
272 | :action => 'revisions' | |
271 |
repository_views.connect 'projects/:id/repository/ |
|
273 | repository_views.connect 'projects/:id/repository/revisions/:rev', | |
272 | :action => 'revision' |
|
274 | :action => 'revision' | |
273 |
repository_views.connect 'projects/:id/repository/ |
|
275 | repository_views.connect 'projects/:id/repository/revisions/:rev/diff', | |
274 | :action => 'diff' |
|
276 | :action => 'diff' | |
275 |
repository_views.connect 'projects/:id/repository/ |
|
277 | repository_views.connect 'projects/:id/repository/revisions/:rev/diff.:format', | |
276 | :action => 'diff' |
|
278 | :action => 'diff' | |
277 |
repository_views.connect 'projects/:id/repository/ |
|
279 | repository_views.connect 'projects/:id/repository/revisions/:rev/raw/*path', | |
278 | :action => 'entry', :format => 'raw' |
|
280 | :action => 'entry', :format => 'raw' | |
279 |
repository_views.connect 'projects/:id/repository/ |
|
281 | repository_views.connect 'projects/:id/repository/revisions/:rev/:action/*path', | |
280 | :requirements => { |
|
282 | :requirements => { | |
281 | :action => /(browse|show|entry|changes|annotate|diff)/, |
|
283 | :action => /(browse|show|entry|changes|annotate|diff)/, | |
282 | :rev => /[a-z0-9\.\-_]+/ |
|
284 | :rev => /[a-z0-9\.\-_]+/ | |
283 | } |
|
285 | } | |
284 |
repository_views.connect 'projects/:id/repository/ |
|
286 | repository_views.connect 'projects/:id/repository/raw/*path', | |
285 | :action => 'entry', :format => 'raw' |
|
287 | :action => 'entry', :format => 'raw' | |
286 |
repository_views.connect 'projects/:id/repository/: |
|
288 | repository_views.connect 'projects/:id/repository/:action/*path', | |
287 | :requirements => { :action => /(browse|show|entry|changes|annotate|diff)/ } |
|
289 | :requirements => { :action => /(browse|show|entry|changes|annotate|diff)/ } | |
|
290 | ||||
288 | repository_views.connect 'projects/:id/repository/:repository_id', |
|
291 | repository_views.connect 'projects/:id/repository/:repository_id', | |
289 | :action => 'show' |
|
292 | :action => 'show' | |
290 | end |
|
293 | end |
General Comments 0
You need to be logged in to leave comments.
Login now