Esempio n. 1
0
/**
 * Outputs the list of all the events in system
 */
function edit_events()
{
    if (isset($_GET['order'])) {
        $orderAttribute = mysql_real_escape_string($_GET['order']);
    } else {
        $orderAttribute = "";
    }
    $attributes = array();
    if (isset($_GET['mandant']) && is_numeric($_GET['mandant'])) {
        $attributes['mandantID'] = $_GET['mandant'];
    }
    if (isset($_GET['topic']) && is_numeric($_GET['topic'])) {
        $attributes['topicID'] = $_GET['topic'];
    }
    $events = EventDatabaseManager::getEventsByAttributes($attributes, $orderAttribute);
    $mandants = EventDatabaseManager::getAllMandants();
    $topics = EventDatabaseManager::getAllTopics();
    View::outputAllEvents('manage_events', 'edit_event', 'edit_participants', $events, $mandants, $topics, $attributes);
    View::linkToAddEvent();
}