/** * Show dashboard overview * * @param void * @return null */ function index() { // Welcome message, displayed only to administrators if ($this->logged_user->isAdministrator() && ConfigOptions::getValue('show_welcome_message')) { $this->wireframe->addPageAction(lang('Hide Welcome Message'), assemble_url('admin_settings_hide_welcome_message'), null, array('method' => 'post', 'confirm' => lang('You are about to hide welcome message. If you wish to bring it back later on you can do it from General settings page in Administration. Hide now?'))); $this->smarty->assign(array('show_welcome_message' => true, 'available_modules' => Modules::findNotInstalled())); //BOF: task 05 | AD $this->wireframe->addPageAction(lang('View All'), assemble_url('view_projects_info')); //EOF: task 05 | AD // Regular dashboard } else { if (Project::canAdd($this->logged_user)) { $this->wireframe->addPageAction(lang('New Project'), assemble_url('projects_add')); //BOF: task 05 | AD $this->wireframe->addPageAction(lang('View All'), assemble_url('view_projects_info')); //EOF: task 05 | AD } // if $this->wireframe->addRssFeed($this->owner_company->getName() . ' - ' . lang('Recent activities'), assemble_url('rss', array('token' => $this->logged_user->getToken(true))), FEED_RSS); $pinned_project_ids = PinnedProjects::findProjectIdsByUser($this->logged_user); if (is_foreachable($pinned_project_ids)) { $pinned_projects = Projects::findByIds($pinned_project_ids); } else { $pinned_projects = null; } // if $dashboard_sections = new NamedList(); event_trigger('on_dashboard_sections', array(&$dashboard_sections, &$this->logged_user)); $important_items = new NamedList(); event_trigger('on_dashboard_important_section', array(&$important_items, &$this->logged_user)); $this->smarty->assign(array('show_welcome_message' => false, 'important_items' => $important_items, 'pinned_projects' => $pinned_projects, 'dashboard_sections' => $dashboard_sections, 'online_users' => Users::findWhoIsOnline($this->logged_user), 'grouped_activities' => group_by_date(ActivityLogs::findActiveProjectsActivitiesByUser($this->logged_user, 20), $this->logged_user))); } // if //BOF:mod 20110623 $tabs = new NamedList(); $tabs->add('dashboard', array('text' => 'Active Teams', 'url' => assemble_url('dashboard'))); $tabs->add('home_page', array('text' => 'Home Page', 'url' => assemble_url('goto_home_tab'))); $tabs->add('assigned_action_request', array('text' => 'Assigned Action Requests', 'url' => assemble_url('assigned_action_request'))); $tabs->add('owned_tickets', array('text' => 'Owned Tickets', 'url' => assemble_url('my_tickets'))); $tabs->add('subscribed_tickets', array('text' => 'Subscribed Tickets', 'url' => assemble_url('my_subscribed_tickets'))); $this->smarty->assign('page_tabs', $tabs); $this->smarty->assign('page_tab', 'dashboard'); //EOF:mod 20110623 }
/** * Show modules administration index page * * @param void * @return null */ function index() { $this->smarty->assign(array('modules' => Modules::findAll(), 'available_modules' => Modules::findNotInstalled())); }
<?php define('PUBLIC_PATH', dirname(__FILE__)); $config_file = realpath(PUBLIC_PATH . '/../config/config.php'); if (is_file($config_file)) { require_once $config_file; ini_set("default_charset", "UTF-8"); ini_set("error_reporting", ""); require ROOT . '/angie.php'; require ANGIE_PATH . '/init.php'; $application =& application(); $application->prepare(array('initialize_resources' => true, 'connect_to_database' => true, 'initialize_smarty' => true, 'init_modules' => true, 'authenticate' => true, 'init_locale' => true, 'load_hooks' => true)); //array $application->init(); include_once WEBDAV_MODULE_PATH . '/models/authenticate.php'; $not_installed_modules = Modules::findNotInstalled(); foreach ($not_installed_modules as $module) { if ($module->name == 'webdav') { header("HTTP/1.1 503 Service Unavailable"); die('Module is not installed'); } } if (!ConfigOptions::getValue('webdav_enabled')) { header("HTTP/1.1 503 Service Unavailable"); die('Module has been disabled by administrator'); } //if // Activate if your PHP is CGI mode $phpcgi = 0; $realm = 'activeCollab webdav area'; $user = AuthenticationBasicHTTP($realm);