/** * Handles POST requests for the groups page. */ public function post_groups() { // Process the forms on this page, if they were submitted. $this->theme->groups = UserGroups::get_all(); // Process the forms on this page, if they were submitted. $redirect_to = URL::get('admin', array('page' => 'groups')); FormUI::build('add_group', 'add_group')->post_redirect($redirect_to); }
/** * Handles POST requests from the Users listing (ie: creating a new user, deleting from the user list) */ public function post_users() { // Process the forms on this page, if they were submitted. $redirect_to = URL::get('admin', array('page' => 'users')); FormUI::build('add_user', 'add_user')->post_redirect($redirect_to); FormUI::build('delete_users', 'delete_users')->post_redirect($redirect_to); }