Merge branch 'perpetual'
This commit is contained in:
commit
697aa9af2d
1 changed files with 4 additions and 4 deletions
|
|
@ -222,18 +222,18 @@ class Bean:
|
|||
|
||||
idx_map[d.parentfield] = d.idx
|
||||
|
||||
def run_method(self, method):
|
||||
def run_method(self, method, *args, **kwargs):
|
||||
self.make_controller()
|
||||
|
||||
if hasattr(self.controller, method):
|
||||
getattr(self.controller, method)()
|
||||
getattr(self.controller, method)(*args, **kwargs)
|
||||
if hasattr(self.controller, 'custom_' + method):
|
||||
getattr(self.controller, 'custom_' + method)()
|
||||
getattr(self.controller, 'custom_' + method)(*args, **kwargs)
|
||||
|
||||
notify(self.controller, method)
|
||||
|
||||
self.set_doclist(self.controller.doclist)
|
||||
|
||||
|
||||
def get_method(self, method):
|
||||
self.make_controller()
|
||||
return getattr(self.controller, method, None)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue