Rizwan Haider | 65baf55 | 2016-09-28 16:47:28 -0400 | [diff] [blame] | 1 | class Invoker(object): |
| 2 | |
| 3 | def __init__(self, **args): |
| 4 | pass |
| 5 | |
| 6 | # Method for handline pre save semantics |
| 7 | # content here would be model specific but could include handling Many-to-Many relationship |
| 8 | # creation - which must occur post save |
| 9 | # |
| 10 | # obj - Whatever obj was just saved |
| 11 | # returns - None - this is a pure invoke() call, return type is None |
| 12 | # |
| 13 | def presave(self, obj): |
| 14 | return None |
| 15 | |
| 16 | |
| 17 | # Method for handline post save semantics |
| 18 | # content here would be model specific but could include handling Many-to-Many relationship |
| 19 | # creation - which must occur post save |
| 20 | # |
| 21 | # obj - Whatever obj was just saved |
| 22 | # returns - None - this is a pure invoke() call, return type is None |
| 23 | # |
| 24 | def postsave(self, obj): |
| 25 | return None |