|
|
|
@ -46,7 +46,7 @@ RedmineApp::Application.routes.draw do
|
|
|
|
|
get "tags/show"
|
|
|
|
|
|
|
|
|
|
get "praise_tread/praise_plus"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
get "praise_tread/tread_plus"
|
|
|
|
|
#end
|
|
|
|
|
|
|
|
|
@ -120,28 +120,28 @@ RedmineApp::Application.routes.draw do
|
|
|
|
|
match 'user_courses', :to => 'users#user_courses', :via => :get
|
|
|
|
|
match 'user_homeworks', :to => 'users#user_homeworks', :via => :get
|
|
|
|
|
match 'watch_projects', :to => 'users#watch_projects', :via => :get
|
|
|
|
|
# added by bai
|
|
|
|
|
# added by bai
|
|
|
|
|
match 'show_score', :to => 'users#show_score', :via => :get
|
|
|
|
|
match 'topic_score_index', :controller => 'users', :action => 'topic_score_index', :via => [:get, :post]
|
|
|
|
|
match 'project_score_index', :to => 'users#project_score_index', :via => :get
|
|
|
|
|
match 'activity_score_index', :to => 'users#activity_score_index', :via => :get
|
|
|
|
|
match 'influence_score_index', :to => 'users#influence_score_index', :via => :get
|
|
|
|
|
match 'score_index', :to => 'users#score_index', :via => :get
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
match 'show_projects_score', :to => 'projects#show_projects_score', :via => [:get, :post]
|
|
|
|
|
match 'issue_score_index', :to => 'projects#issue_score_index', :via => [:get, :post]
|
|
|
|
|
match 'news_score_index', :to => 'projects#news_score_index', :via => [:get, :post]
|
|
|
|
|
match 'file_score_index', :to => 'projects#file_score_index', :via => [:get, :post]
|
|
|
|
|
match 'code_submit_score_index', :to => 'projects#code_submit_score_index', :via => [:get, :post]
|
|
|
|
|
match 'projects_topic_score_index', :to => 'projects#projects_topic_score_index', :via => [:get, :post]
|
|
|
|
|
# end
|
|
|
|
|
# end
|
|
|
|
|
end
|
|
|
|
|
end
|
|
|
|
|
match 'users/:id/user_newfeedback', :to => 'users#user_newfeedback', :via => :get, :as => "feedback"
|
|
|
|
|
match 'users/:id/user_projects', :controller => 'users', :action => 'user_projects', :via => :get
|
|
|
|
|
#match 'user/:id/watch_calls', :controller => 'users', :action => 'watch_bids', :via => [:get , :post]
|
|
|
|
|
|
|
|
|
|
#end
|
|
|
|
|
#end
|
|
|
|
|
match 'my/account', :controller => 'my', :action => 'account', :via => [:get, :post]
|
|
|
|
|
match 'my/account/destroy', :controller => 'my', :action => 'destroy', :via => [:get, :post]
|
|
|
|
|
match 'my/page', :controller => 'my', :action => 'page', :via => :get
|
|
|
|
@ -173,8 +173,10 @@ RedmineApp::Application.routes.draw do
|
|
|
|
|
delete 'issues/:object_id/watchers/:user_id' => 'watchers#destroy', :object_type => 'issue'
|
|
|
|
|
|
|
|
|
|
resources :bids, :only=>[:edit,:update,:show]
|
|
|
|
|
resources :projects do
|
|
|
|
|
resources :projects do
|
|
|
|
|
member do
|
|
|
|
|
post 'finishcourse'
|
|
|
|
|
post 'restartcourse'
|
|
|
|
|
get 'settings(/:tab)', :action => 'settings', :as => 'settings'
|
|
|
|
|
#by young
|
|
|
|
|
get 'member', :controller => 'projects', :action => 'member', :as => 'member'
|
|
|
|
@ -196,24 +198,24 @@ RedmineApp::Application.routes.draw do
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#by young
|
|
|
|
|
match '/member', :controller => 'projects', :action => 'member', :as => 'member', :via => :get
|
|
|
|
|
match '/file', :controller => 'projects', :action => 'file', :as => 'file', :via => :get
|
|
|
|
|
match '/statistics', :controller => 'projects', :action => 'statistics', :as => 'statistics', :via => :get
|
|
|
|
|
# match '/investor', :controller => 'projects', :action => 'investor', :as => 'investor', :via => :get
|
|
|
|
|
match '/homework', :controller => 'projects', :action => 'homework', :as => 'homework', :via => :get
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# match '/activity', :controller => 'activities', :action => 'index', :as => 'activity', :via => :get
|
|
|
|
|
# match '/repository', :controller => 'repositories', :action => 'show', :repository_id => nil, :path => nil, :rev => nil, :as => 'repository', :via => :get
|
|
|
|
|
# match '/', :controller => 'projects', :action => 'show', :as => 'project_show', :via => :get
|
|
|
|
|
# get 'projects/:project_id/show', :to => 'projects#show', :as => 'project_show'
|
|
|
|
|
# get 'projects/:project_id/repository', :to => 'repositories#show', :as => 'project_repository'
|
|
|
|
|
|
|
|
|
|
# match '/show', :controller => 'projects', :action => 'show', :as => 'project_show', :via => :get
|
|
|
|
|
#by young
|
|
|
|
|
match '/member', :controller => 'projects', :action => 'member', :as => 'member', :via => :get
|
|
|
|
|
match '/file', :controller => 'projects', :action => 'file', :as => 'file', :via => :get
|
|
|
|
|
match '/statistics', :controller => 'projects', :action => 'statistics', :as => 'statistics', :via => :get
|
|
|
|
|
# match '/investor', :controller => 'projects', :action => 'investor', :as => 'investor', :via => :get
|
|
|
|
|
match '/homework', :controller => 'projects', :action => 'homework', :as => 'homework', :via => :get
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# match '/activity', :controller => 'activities', :action => 'index', :as => 'activity', :via => :get
|
|
|
|
|
# match '/repository', :controller => 'repositories', :action => 'show', :repository_id => nil, :path => nil, :rev => nil, :as => 'repository', :via => :get
|
|
|
|
|
# match '/', :controller => 'projects', :action => 'show', :as => 'project_show', :via => :get
|
|
|
|
|
# get 'projects/:project_id/show', :to => 'projects#show', :as => 'project_show'
|
|
|
|
|
# get 'projects/:project_id/repository', :to => 'repositories#show', :as => 'project_repository'
|
|
|
|
|
|
|
|
|
|
# match '/show', :controller => 'projects', :action => 'show', :as => 'project_show', :via => :get
|
|
|
|
|
match '/watcherlist', :controller=>'projects', :action=> 'watcherlist', :as => 'watcherlist', :via => :get #add by huang
|
|
|
|
|
# matche '/news', :controller => 'news', :action => 'index', :as => 'news', :via => :get
|
|
|
|
|
#end
|
|
|
|
|
# matche '/news', :controller => 'news', :action => 'index', :as => 'news', :via => :get
|
|
|
|
|
#end
|
|
|
|
|
|
|
|
|
|
resources :memberships, :shallow => true, :controller => 'members', :only => [:index, :show, :new, :create, :update, :destroy] do
|
|
|
|
|
collection do
|
|
|
|
@ -336,8 +338,7 @@ RedmineApp::Application.routes.draw do
|
|
|
|
|
get 'projects/:id/repository/:repository_id/statistics', :to => 'repositories#stats'
|
|
|
|
|
get 'projects/:id/repository/:repository_id/graph', :to => 'repositories#graph'
|
|
|
|
|
|
|
|
|
|
get 'projects/:id/repository/:repository_id/changes(/*path(.:ext))',
|
|
|
|
|
:to => 'repositories#changes'
|
|
|
|
|
get 'projects/:id/repository/:repository_id/changes(/*path(.:ext))', :to => 'repositories#changes'
|
|
|
|
|
|
|
|
|
|
get 'projects/:id/repository/:repository_id/revisions/:rev', :to => 'repositories#revision'
|
|
|
|
|
get 'projects/:id/repository/:repository_id/revision', :to => 'repositories#revision'
|
|
|
|
@ -348,15 +349,14 @@ RedmineApp::Application.routes.draw do
|
|
|
|
|
:controller => 'repositories',
|
|
|
|
|
:format => false,
|
|
|
|
|
:constraints => {
|
|
|
|
|
:action => /(browse|show|entry|raw|annotate|diff)/,
|
|
|
|
|
:rev => /[a-z0-9\.\-_]+/
|
|
|
|
|
}
|
|
|
|
|
:action => /(browse|show|entry|raw|annotate|diff)/,
|
|
|
|
|
:rev => /[a-z0-9\.\-_]+/
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
get 'projects/:id/repository/statistics', :to => 'repositories#stats'
|
|
|
|
|
get 'projects/:id/repository/graph', :to => 'repositories#graph'
|
|
|
|
|
|
|
|
|
|
get 'projects/:id/repository/changes(/*path(.:ext))',
|
|
|
|
|
:to => 'repositories#changes'
|
|
|
|
|
get 'projects/:id/repository/changes(/*path(.:ext))', :to => 'repositories#changes'
|
|
|
|
|
|
|
|
|
|
get 'projects/:id/repository/revisions', :to => 'repositories#revisions'
|
|
|
|
|
get 'projects/:id/repository/revisions/:rev', :to => 'repositories#revision'
|
|
|
|
@ -367,9 +367,9 @@ RedmineApp::Application.routes.draw do
|
|
|
|
|
:controller => 'repositories',
|
|
|
|
|
:format => false,
|
|
|
|
|
:constraints => {
|
|
|
|
|
:action => /(browse|show|entry|raw|annotate|diff)/,
|
|
|
|
|
:rev => /[a-z0-9\.\-_]+/
|
|
|
|
|
}
|
|
|
|
|
:action => /(browse|show|entry|raw|annotate|diff)/,
|
|
|
|
|
:rev => /[a-z0-9\.\-_]+/
|
|
|
|
|
}
|
|
|
|
|
get 'projects/:id/repository/:repository_id/:action(/*path(.:ext))',
|
|
|
|
|
:controller => 'repositories',
|
|
|
|
|
:action => /(browse|show|entry|raw|changes|annotate|diff)/
|
|
|
|
@ -441,7 +441,7 @@ RedmineApp::Application.routes.draw do
|
|
|
|
|
end
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
match 'workflows', :controller => 'workflows', :action => 'index', :via => :get
|
|
|
|
|
match 'workflows/edit', :controller => 'workflows', :action => 'edit', :via => [:get, :post]
|
|
|
|
@ -529,10 +529,10 @@ RedmineApp::Application.routes.draw do
|
|
|
|
|
match 'project/course', :to => 'projects#course', :as => 'course'
|
|
|
|
|
|
|
|
|
|
#added by william
|
|
|
|
|
# match 'calls/:id/set_results',:controller => 'bids', :action => 'set_results',:via => [:get,:post],:as => 'set_results'
|
|
|
|
|
# match 'calls/:id/set_prizes',:controller => 'bids',:action => 'set_prizes',:as => 'set_prizes'
|
|
|
|
|
match 'calls/:id/set_reward',:controller => 'bids',:action => 'set_reward',:as => 'set_reward'
|
|
|
|
|
|
|
|
|
|
# match 'calls/:id/set_results',:controller => 'bids', :action => 'set_results',:via => [:get,:post],:as => 'set_results'
|
|
|
|
|
# match 'calls/:id/set_prizes',:controller => 'bids',:action => 'set_prizes',:as => 'set_prizes'
|
|
|
|
|
match 'calls/:id/set_reward',:controller => 'bids',:action => 'set_reward',:as => 'set_reward'
|
|
|
|
|
|
|
|
|
|
## 测试用
|
|
|
|
|
match 'test/index', :controller => 'test', :action => 'index'
|
|
|
|
|
# added by young
|
|
|
|
|