public function search_action() { $this->results = AdminList::getInstance()->getSearchResults(); $this->request = $_POST; $this->searchTermPost = $this->request['course_search']; if (Request::option('course_search')) { $this->searchTerm = Request::option('course_search'); } }
public function getModelIndicator($action, $id = NULL) { $model = 'indicator'; $array = []; if ($action == 'edit') { $indicator = \Solunes\Master\App\Indicator::find($id); $indicator_model = \FuncNode::node_check_model($indicator->node); $array['node_name'] = $indicator->node->plural; $array['filter_category'] = 'indicator'; $array['filter_node'] = $indicator->node->name; $array['filter_type'] = 'field'; $array['filter_category_id'] = $id; $filled_items = $indicator_model; $array = \AdminList::filter_node($array, $indicator->node, $indicator_model, $filled_items, 'indicator'); $array = \CustomFunc::custom_indicator($indicator->node, $indicator, $array); if (request()->has('search') && isset($array['filters']) && is_array($array['filters'])) { foreach ($array['filters'] as $field_name => $field) { $filter = \Solunes\Master\App\Filter::find($field['id']); $action_value = []; if ($field['subtype'] == 'date') { if (request()->has('f_' . $field_name . '_from')) { $action_value[request()->input('f_' . $field_name . '_from')] = 'is_greater'; } if (request()->has('f_' . $field_name . '_to')) { $action_value[request()->input('f_' . $field_name . '_to')] = 'is_less'; } } else { if ($field['subtype'] == 'string') { if (request()->has('f_' . $field_name)) { $action_value[request()->input('f_' . $field_name)] = request()->input('f_' . $field_name . '_action'); } } else { if (request()->has('f_' . $field_name) && is_array(request()->input('f_' . $field_name))) { foreach (request()->input('f_' . $field_name) as $subfield_key => $subfield_val) { $action_value[$subfield_val] = 'is'; } } else { if (request()->has('f_' . $field_name)) { $action_value[request()->input('f_' . $field_name)] = 'is'; } } } } $filter->action_value = json_encode($action_value); $filter->save(); } \CustomFunc::update_indicator_values($indicator); } $filled_items = $indicator_model; $array = \AdminList::filter_node($array, $indicator->node, $indicator_model, $filled_items, 'indicator'); $array['items'] = $array['items']->get(); } return AdminItem::get_request($model, $action, $id, $this, [], $array); }
<? parse_msg($message); ?> </td> </tr> <? endif; ?> </table> </form> <? //} // display Seminar-List //if ($_SESSION['links_admin_data']['srch_on'] || $auth->auth["perm"] =="tutor" || $auth->auth["perm"] == "dozent") { if(isset($admin_view)){ URLHelper::bindLinkParam('admin_view',$admin_view); } //Suchresultate abholen: $results = AdminList::getInstance()->getSearchResults(); ?> <form name="links_admin_action" action="<?php echo URLHelper::getLink(); ?> " method="POST"> <?php echo CSRFProtection::tokenTag(); ?> <table border=0 cellspacing=0 cellpadding=2 align=center width="99%"> <? $show_rooms_check_url = $show_rooms_check == 'on' ? '&show_rooms_check=on' : null; // only show table header in case of hits if (count($results)) { ?>