--- a/app/soc/modules/ghop/logic/models/task.py Fri Aug 28 13:17:32 2009 +0200
+++ b/app/soc/modules/ghop/logic/models/task.py Fri Aug 28 19:41:28 2009 +0530
@@ -39,10 +39,10 @@
STATE_TRANSITIONS = {
- 'Claimed': transitFromClaimed,
- 'NeedsReview': transitFromNeedsReview,
- 'ActionNeeded': transitFromActionNeeded,
- 'NeedsWork': transitFromNeedsWork,
+ 'Claimed': 'transitFromClaimed',
+ 'NeedsReview': 'transitFromNeedsReview',
+ 'ActionNeeded': 'transitFromActionNeeded',
+ 'NeedsWork': 'transitFromNeedsWork',
}
@@ -292,7 +292,7 @@
if entity.deadline and datetime.datetime.now() > entity.deadline:
# calls a specific method to make a transition depending on the
# task's current state
- transit_func = STATE_TRANSITIONS[entity.status]
+ transit_func = getattr(self, STATE_TRANSITIONS[entity.status])
update_dict = transit_func(entity)
comment_properties = {