set_type($entity_type); $entity_form = ''; switch($action){ case 'get_form': $entity_form = $this->get_manage_form("sort"); break; case 'get_already_selected_sorting' : ajax_http_send_response($this->get_already_selected_fields('sort')); break; default: parent::proceed(); break; } if ($entity_form) { header("Content-Type: text/html; charset=UTF-8"); print encoding_normalize::utf8_normalize($entity_form); } } protected function set_type($type) { if (!empty($type)) { $this->type = $type; } } protected function get_manage_form($type){ global $msg, $current_module; global $base_path; global $num_page; global $charset; //entite appelant le selecteur global $entity; global $entity_id; global $class_name; global ${$type."_data"}; //identifiant du tri ou du filtre $manage_id = 0; $name = ''; $entity_manage_controller = ""; $fields_class_name = ''; switch ($type) { case 'sort': $entity_manage_controller = "SortingEntityManageController"; $fields_class_name = 'sort_fields'; break; } $instance_fields = new $fields_class_name($this->get_indexation_type(), $this->get_indexation_path()); if (!empty(${$type."_data"})) { if (is_string(${$type."_data"})) { ${$type."_data"} = encoding_normalize::json_decode(stripslashes(${$type."_data"}), true); } $instance_fields->unformat_fields(${$type."_data"}); } $form = "
"; $form .= "