mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-05-16 14:41:39 +00:00
pass class name to preRun, invoke() returns false if preRun fails
This commit is contained in:
parent
59d24bde03
commit
5378d6e7d9
|
@ -66,7 +66,7 @@ class SeedDMS_View_Common {
|
||||||
elseif($request->isMethod('post'))
|
elseif($request->isMethod('post'))
|
||||||
$action = $request->request->get('action');
|
$action = $request->request->get('action');
|
||||||
}
|
}
|
||||||
if(!$this->callHook('preRun', $action ? $action : 'show')) {
|
if(!$this->callHook('preRun', get_class($this), $action ? $action : 'show')) {
|
||||||
if($action) {
|
if($action) {
|
||||||
if(method_exists($this, $action)) {
|
if(method_exists($this, $action)) {
|
||||||
$this->{$action}();
|
$this->{$action}();
|
||||||
|
@ -75,6 +75,8 @@ class SeedDMS_View_Common {
|
||||||
}
|
}
|
||||||
} else
|
} else
|
||||||
$this->show();
|
$this->show();
|
||||||
|
} else {
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
$this->callHook('postRun', $action ? $action : 'show');
|
$this->callHook('postRun', $action ? $action : 'show');
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user