mirror of
https://bitbucket.org/jsuto/piler.git
synced 2025-06-12 23:27:03 +02:00
added search capabilities to admin sections
This commit is contained in:
@ -24,6 +24,11 @@ class ControllerPolicyArchiving extends Controller {
|
||||
|
||||
$this->data['error'] = '';
|
||||
|
||||
$this->data['search'] = '';
|
||||
|
||||
if(isset($this->request->post['search'])) { $this->data['search'] = $this->request->post['search']; }
|
||||
else if(isset($this->request->get['search'])) { $this->data['search'] = $this->request->get['search']; }
|
||||
|
||||
if(Registry::get('admin_user') == 0) {
|
||||
die("go away");
|
||||
}
|
||||
@ -36,7 +41,7 @@ class ControllerPolicyArchiving extends Controller {
|
||||
}
|
||||
}
|
||||
|
||||
$this->data['rules'] = $this->model_policy_archiving->get_rules();
|
||||
$this->data['rules'] = $this->model_policy_archiving->get_rules($this->data['search']);
|
||||
|
||||
|
||||
$this->render();
|
||||
|
@ -22,6 +22,11 @@ class ControllerPolicyRetention extends Controller {
|
||||
$this->data['rules'] = array();
|
||||
$this->data['error'] = '';
|
||||
|
||||
$this->data['search'] = '';
|
||||
|
||||
if(isset($this->request->post['search'])) { $this->data['search'] = $this->request->post['search']; }
|
||||
else if(isset($this->request->get['search'])) { $this->data['search'] = $this->request->get['search']; }
|
||||
|
||||
if(Registry::get('admin_user') == 0) {
|
||||
die("go away");
|
||||
}
|
||||
@ -37,7 +42,7 @@ class ControllerPolicyRetention extends Controller {
|
||||
|
||||
}
|
||||
|
||||
$this->data['rules'] = $this->model_policy_retention->get_rules();
|
||||
$this->data['rules'] = $this->model_policy_retention->get_rules($this->data['search']);
|
||||
|
||||
|
||||
$this->render();
|
||||
|
Reference in New Issue
Block a user