function category_overview(&$app) { global $lang; $p =& $app->ui; $conf = new tree_edit_conf(); $conf->source = 'directories'; $conf->id = '1'; $conf->treeview = $app->event(); $conf->nodeview = 'view_pages'; $conf->nodecreator = 'create_category'; $conf->rootname = 'shop'; $conf->table = 'directories'; $conf->name = 'name'; $conf->id = 'id'; $conf->preset_values = array('id_directory_type' => get_directory_type_id($app->db, 'category')); $conf->txt_select_node = $lang['msg choose category to move']; $conf->txt_select_dest = $lang['msg choose dest category']; $conf->txt_moved = $lang['msg category moved']; $conf->txt_not_moved = $lang['err category not moved']; $conf->txt_move_again = $lang['cmd move further']; $conf->txt_back = $lang['cmd back/quit']; $conf->txt_unnamed = $lang['unnamed']; $e = new event('tree_edit_move', array('conf' => $conf)); $e->set_caller($app->event()); $p->link($lang['cmd move_category'], $e); tree_edit($app, $conf); }
function _show_object_class(&$documents, &$images, &$user_defined, &$configuration, &$cache, &$app, $table, $id, $only_local, $id_class, $class, $descr) { $p =& $app->ui; $common_args = array('class' => $class, 'table' => $table, 'id' => $id, 'otable' => $table, 'oid' => $id); $e_edit_data = new event('edit_data', $common_args); $e_edit_data->set_caller($app->event()); $descr = preg_replace('/ /', ' ', $descr); if (!isset($cache[$id_class])) { # && ((!$only_local) || ($only_local && substr ($class, 0, 2) == 'u_'))) { $e = new event('assoc_object', $common_args); $e->set_next($e_edit_data); $tmp = '[' . $p->_looselink("<FONT COLOR=\"BLACK\">{$descr}</FONT>", $e) . "]\n"; } else { $tmp = _show_existing_object_class($images, $cache, $app, $table, $id, $only_local, $id_class, $class, $descr, $e_edit_data); } switch (substr($class, 0, 2)) { case 'l_': $documents .= $tmp; break; case 'd_': $configuration .= $tmp; break; default: $user_defined .= $tmp; } }