Changeset 6f24604 for remit


Ignore:
Timestamp:
Apr 18, 2010, 5:49:35 PM (15 years ago)
Author:
Alex Dehnert <adehnert@…>
Branches:
master, client
Children:
00e722e
Parents:
5724bd5
git-author:
Alex Dehnert <adehnert@…> (04/18/10 17:49:35)
git-committer:
Alex Dehnert <adehnert@…> (04/18/10 17:49:35)
Message:

Make reimbursement base path configurable

Adds a BASE_COMMITTEE_PATH parameter (default ['Accounts', 'Assets', ])
to use as the base path for reimbursement requests.

UPGRADE NOTE: Previously the value was hardcoded as
['Accounts', 'Assets', 'Budget', ] --- previous deployments should make
sure to set BASE_COMMITTEE_PATH to that when upgrading.

Location:
remit
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • remit/settings.py

    r0f53aae r6f24604  
    2727DATABASE_HOST = ''             # Set to empty string for localhost. Not used with sqlite3.
    2828DATABASE_PORT = ''             # Set to empty string for default. Not used with sqlite3.
     29
     30BASE_COMMITTEE_PATH = ['Accounts', 'Assets', ]
    2931
    3032from local_settings import *
  • remit/vouchers/views.py

    rb34d568 r6f24604  
    3636class CommitteesField(ModelChoiceField):
    3737    def __init__(self, *args, **kargs):
    38         base_area = BudgetArea.get_by_path(['Accounts', 'Assets', 'Budget', ])
     38        base_area = BudgetArea.get_by_path(settings.BASE_COMMITTEE_PATH)
    3939        self.strip_levels = base_area.depth
    4040        areas = (base_area.get_descendants()
Note: See TracChangeset for help on using the changeset viewer.