Changesets can be listed by changeset number.
The Git repository is here.
- Revision:
- 390
- Log:
Initial import of Canvass, a donations-based poll application.
- Author:
- rool
- Date:
- Mon Mar 21 14:58:04 +0000 2011
- Size:
- 1998 Bytes
1 | ActionController::Routing::Routes.draw do |map| |
2 | |
3 | map.root :controller => :polls, :action => :index |
4 | |
5 | # Local users are mirrors of Hub users with extra information stored so that |
6 | # they can be associated with created Polls and Donations. However, Poll and |
7 | # Donation objects contain enough information about themselves that a User |
8 | # can be deleted without breaking them, if necessary. |
9 | # |
10 | # When managing Polls and Donations in the context of the user, only index |
11 | # and show actions are supported to keep things simple. |
12 | |
13 | map.resources :users, :only => [ :index, :show, :delete ] do | user | |
14 | user.resources :polls, :only => [ :index, :show ] |
15 | user.resources :donations, :only => [ :index, :show ] |
16 | end |
17 | |
18 | # Privileged users browse donations without limiting the scope by user ID. |
19 | # Polls can be similarly viewed without restriction. |
20 | # |
21 | # Polls have many donations. Resource-ful URLs are used when creating a |
22 | # donation to associate with the poll to which the donation is being made. |
23 | # The payment gateway process proceeds in the context of the current logged |
24 | # in user, with the poll identified by the context inferred by the URL. |
25 | |
26 | map.resources :donations, :only => [ :index, :show ] |
27 | map.resources :polls do | poll | |
28 | poll.resources :donations, :only => [ :index, :show, :new, :create ] |
29 | poll.resource :payment_gateway_onsite, :controller => :payment_gateway_onsite, :member => { :delete => :get } |
30 | poll.resource :payment_gateway_offsite, :controller => :payment_gateway_offsite, :member => { :delete => :get } |
31 | end |
32 | |
33 | # Full currency support, for number formatting, editing etc. (CRUD interface |
34 | # available to privileged users only). Likewise, the audits interface - index |
35 | # only. |
36 | |
37 | map.resources :currencies |
38 | map.resources :auditers, :only => :index |
39 | |
40 | # Preview for RedCloth (Textile) text; translatable help pages. |
41 | |
42 | map.resource :redcloth, :only => :create, :controller => :redcloth |
43 | map.resources :help, :only => :show |
44 | |
45 | end |