# HG changeset patch # User Sverre Rabbelier # Date 1239314707 0 # Node ID 70b4a5e90eb05ad1e3c2b109e2fb02f070e7ad92 # Parent 3d5692ae414c18ae6d7bc3b629c37ecbb5f0db55 Store min and max slots in the program model Also add a field to store the current allocation. Patch by: Sverre Rabbelier diff -r 3d5692ae414c -r 70b4a5e90eb0 app/soc/models/program.py --- a/app/soc/models/program.py Thu Apr 09 22:04:47 2009 +0000 +++ b/app/soc/models/program.py Thu Apr 09 22:05:07 2009 +0000 @@ -85,6 +85,18 @@ 'of Code, but 1 is the tasks limit that the student can work ' 'on at the same time during GHOP') + #: Optional field storing minimum slots per organization + min_slots = db.IntegerProperty(required=False, default=2, + verbose_name=ugettext('Min slots per org')) + min_slots.help_text = ugettext( + 'The amount of slots each org should get at the very least') + + #: Optional field storing maximum slots per organization + max_slots = db.IntegerProperty(required=False, default=50, + verbose_name=ugettext('Max slots per org')) + max_slots.help_text = ugettext( + 'The amount of slots each organization should get at most') + #: Required field storing slots limit of the program. slots = db.IntegerProperty(required=True, verbose_name=ugettext('Slots')) @@ -95,6 +107,10 @@ 'to the program.
For GHOP this indicates how ' 'many tasks can be completed.') + #: Optional field storing the allocation of slots for this program + slots_allocation = db.TextProperty(required=False, + verbose_name=ugettext('the allocation of slots')) + #: Required field storing the type of workflow this program has workflow = db.StringProperty(required=True, choices=['gsoc', 'ghop'],