コード例 #1
0
$t_filter = current_user_get_bug_filter();
$t_filter['_view_type'] = 'advanced';
$t_filter['show_status'] = array(META_FILTER_ANY);
$t_filter['sort'] = '';
$rows = filter_get_bug_rows($f_page_number, $t_per_page, $t_page_count, $t_bug_count, $t_filter, null, null, true);
if (count($rows) == 0) {
    // no data to graph
    exit;
}
$t_bug_table = db_get_table('mantis_bug_table');
$t_bug_hist_table = db_get_table('mantis_bug_history_table');
$t_marker = array();
$t_data = array();
$t_ptr = 0;
$t_end = $t_interval->get_end_timestamp();
$t_start = $t_interval->get_start_timestamp();
if ($t_end == false || $t_start == false) {
    return;
}
// grab all status levels
$t_status_arr = MantisEnum::getAssocArrayIndexedByValues(config_get('status_enum_string'));
$t_status_labels = MantisEnum::getAssocArrayIndexedByValues(lang_get('status_enum_string'));
$t_default_bug_status = config_get('bug_submit_status');
$t_bug = array();
$t_view_status = array();
// walk through all issues and grab their status for 'now'
$t_marker[$t_ptr] = time();
foreach ($rows as $t_row) {
    if (isset($t_data[$t_ptr][$t_row->status])) {
        $t_data[$t_ptr][$t_row->status]++;
    } else {