$moduleArr[categories][$cat][modules][$comp][chart] = createBarChartForReg(1, 1, 0, $build, $version, $comp, $cat, 0, $regr, $gren, $rap); //$moduleArr[categories][$cat][modules][$comp][comment] ='Yet to Run in this build'; $moduleArr[categories][$cat][modules][$comp][basetable] = createBasetable(0, $baseValue[$comp]); $commentData = getModuleComments($comp, $cat, $build, $version, $regr); $ownerData = getModuleOwners($modName); $moduleArr[categories][$cat][modules][$comp][comment] = $commentData[comment]; $moduleArr[categories][$cat][modules][$comp][bugLink] = createModuleBugField($commentData[bugs]); $moduleArr[categories][$cat][modules][$comp][bugs] = $commentData[bugs]; $moduleArr[categories][$cat][modules][$comp][bugsOld] = $commentData[bugsOld]; $moduleArr[categories][$cat][modules][$comp][bugLinkOld] = createModuleBugField($commentData[bugsOld]); } $moduleArr[basetable] = createBasetable($pass + $fail, $baseVal + $catextra); } //////4. till here/////////////////// $moduleArr[stats] = createTPFtable2($pass, $fail, $version, $build, "", "", "", "platform.php"); $moduleArr[chart] = createBarChartForReg($pass + $fail, $pass, $fail, $build, $version, $modName, $catName, 0); $moduleArr[time] = Sec2Time($time); /////////////////////////////////////////////////// ########################################################################################################################### // sort category / component names in alphabetical order ksort($moduleArr[categories], SORT_STRING); foreach ($moduleArr[categories] as $catName => $module) { ksort($moduleArr[categories][$catName][modules], SORT_STRING); } ########################################################################################################################### // export to excel if ($regr == "phase") { $build = $_GET[build]; } $index = 1; $filename = "casedata/exportData" . $build . ".csv";
function createGrenRegBuildTable($build, $name, $noneDisplay, $combineResults = 0) { $i = 0; $table = ""; ereg("([0-9]+\\.[0-9]+)\\.[0-9]+\\.[0-9]+", $build[version], $regs); $release = $regs[1]; if ($noneDisplay == "none") { $onMouse = "<tr\r\n onClick=\"location.href='modules.php?version=" . $build[version] . "&build=" . $name . "&gren=grenreg'\" style=\"cursor: pointer;\" onmouseover=\"mouse_event(this, 'hlt');\" onmouseout=\"mouse_event(this, '');\">"; } else { $onMouse = "<tr onmouseover=\"mouse_event(this, 'hlt');\" onmouseout=\"mouse_event(this, '');\">"; } $onClick = " onClick=\"location.href='platform.php?version=" . $build[version] . "&build=" . $name . "'&gren=grenreg\""; $bugField = createBugField2($build, $release, $name, $noneDisplay); if ($bugField == "N/A") { $bugFieldCol = "<td align=\"center\" style=\"color: #E1EEF7; border-left: 1pt dashed #059;\""; } else { $bugFieldCol = "<td align=\"center\" style=\"border-left: 1pt dashed #059;\""; } $borderTop = "<td "; //.$onClick; if ($build[status] == "Pass") { $statusColor = "<td style=\"color: green;\""; } elseif ($build[status] == "Fail") { $statusColor = "<td style=\"color: red;\""; } elseif ($build[status] == "Pending") { $statusColor = "<td style=\"color: blue;\""; } else { $statusColor = "<td style=\"color: #E1EEF7;\""; } // resolve comment field if ($noneDisplay == "none") { $comment = $build[comment] == "" ? "<td style=\"color: #E1EEF7\">N/A</td>" : "<td style=\"padding: 0 5px 0 9px;" . "font: bold 8px \"Trebuchet MS\", Verdana, " . "Arial, Helvetica, sans-serif;\" align=\"left\">" . $build[comment] . "</td>"; } else { $comment = "<td style=\"border-left: 1pt dashed #059;\"><input type=\"text\" maxlength=\"80\" size=\"20\" value=\"" . $build[comment] . "\"" . " name=\"comment-" . $name . "\"/></td>"; } // resolve buildType if (ereg("(.*)-FIPS", $build[version], $regs)) { $buildName = !$i ? $borderTop . " style=\"cursor: pointer;\" align=\"middle\"><img src=\"images/arrow_org.gif\"/><b>" . $name . "</b></td>" : $borderTop . " style=\"cursor: pointer;\"></td>"; $buildType = "<td style=\"font-size: xx-small; color: blue\" align=\"center\">FIPS</td>"; $versionFormat = $regs[1]; } elseif (ereg("(.*)_OAW", $name, $regs)) { $buildName = !$i ? $borderTop . " style=\"cursor: pointer;\" align=\"middle\"><img src=\"images/arrow_org.gif\"/><b>" . $regs[1] . "</b></td>" : $borderTop . " style=\"cursor: pointer;\"></td>"; $buildType = "<td style=\"font-size: xx-small; color: #483D8B\" align=\"center\">ALCATEL</td>"; $versionFormat = $build[version]; } elseif (ereg("-hosp", $build[version], $regs)) { $buildName = !$i ? $borderTop . " style=\"cursor: pointer;\" align=\"middle\"><img src=\"images/arrow_org.gif\"/><b>" . $name . "</b></td>" : $borderTop . " style=\"cursor: pointer;\"></td>"; $buildType = "<td style=\"font-size: xx-small; color: red\" align=\"center\">HOSPITALITY</td>"; $versionFormat = $build[version]; } else { $buildName = !$i ? $borderTop . " style=\"cursor: pointer;\" align=\"middle\"><img src=\"images/arrow_org.gif\"/><b>" . $name . "</b></td>" : $borderTop . " style=\"cursor: pointer;\"></td>"; # $buildType = "<td style=\"font-size: xx-small; color: green\" align=\"center\"><b>AOS</b></td>"; $buildType = "<td style=\"font-size: xx-small; color: green\" align=\"center\"><b>INSTANT</b></td>"; $versionFormat = $build[version]; } if ($combineResults) { $buildName = $borderTop . " style=\"cursor: pointer;\"></td>"; } $table .= $onMouse . $buildName . $buildType . "<td style=\"font-size: xx-small\" align=\"center\">" . $versionFormat . "</td>" . "<td style=\"font-size: xx-small\">" . $build[started] . "</td>" . "<td style=\"cursor: pointer;\">" . createTPFtableGren($build[passed], $build[failed], $build[version], $name, "", "", "yes", "yes", "") . "</td>" . createRunStatusColor3($build[runstatus], $name, $noneDisplay) . createResultMenu2($statusColor, $noneDisplay, "<td style=\"cursor: pointer; ", $name, $build[status], $build[runstatus]) . "<td style=\"cursor: pointer;\">" . createBarChartForReg($build[passed] + $build[failed], $build[passed], $build[failed], $name, $build[version], "", "", 1, "grenreg") . "</td>" . $comment . $bugFieldCol . " align=\"left\">" . $bugField . "</td>" . "</tr>"; $i++; return $table; }