Ejemplo n.º 1
0
        }
        ereg("([a-zA-Z]+):(.+):(.+)", $name, $regs);
        $type = $regs[1];
        $cat = $regs[2];
        $mod = $regs[3];
        if ($type == "comment") {
            updateModComment($mod, $cat, $build, $version, $smoke, $regr);
        }
        if ($type == "bug") {
            updateModBugs($mod, $cat, $build, $version, $smoke, $regr);
        }
        if ($type == "bugsOld") {
            updateOldModBugs($mod, $cat, $build, $version, $smoke, $regr);
        }
        if ($type == "email" && $smoke == "Email") {
            $res = sendEmailReport($mod, $cat, $build, $version);
        }
        if ($type == "sqaOwn" || $type == "autOwn" || $type == "devOwn") {
            updateModOwner($mod, $type, $smoke);
        }
    }
}
/////////////////////////////////////////////////////////////////////////////////////////////////////////////
ereg("([0-9]+\\.[0-9]+)\\.[0-9]+\\.[0-9]+", $version, $regs);
$release = $regs[1];
$cases = $arrData[$release][builds][$build][cases];
$moduleArr = array();
$moduleArr[categories] = array();
//////Baseline/////////
$mapping = getCompCatMapping($version, $regr == "yes" && !$rap && !$gren ? "Reg" : "", $isBaselined, $baseValue);
$mapping_bk = $mapping;
Ejemplo n.º 2
0
<?php

include_once 'phplib/base.php';
if (!db::connect()) {
    echo "Database connection failed, cannot continue. ";
} else {
    $timestamp = time();
    $username = getUsername();
    $range_start = db::escape($_POST['range_start']);
    $range_end = db::escape($_POST['range_end']);
    $report_id = generateWeeklyReportID($username, $range_start, $range_end);
    $state = "final";
    $report = db::escape($_POST['weeklyupdate']);
    $query = "INSERT INTO generic_weekly (report_id, range_start, range_end, timestamp, user, state, report) VALUES ('{$report_id}', '{$range_start}', '{$range_end}', '{$timestamp}', '{$username}', '{$state}', '{$report}')";
    if (!db::query($query)) {
        echo "Database update failed, error: " . db::error();
    } else {
        if (isset($_POST['do_email'])) {
            # The user clicked the email button so also email a copy of the report
            if (sendEmailReport($username, $report, $range_start, $range_end)) {
                Header("Location: {$ROOT_URL}/add.php?weekly_succ_email=hellyeah");
            }
        } else {
            Header("Location: {$ROOT_URL}/add.php?weekly_succ=hellyeah");
        }
    }
}