Beispiel #1
0
             // Send the email
             $title = "CDash [" . $Project->GetName() . "] - Low Coverage";
             $User = new User();
             $User->Id = $userid;
             $email = $User->GetEmail();
             cdashmail("{$email}", $title, $messagePlainText, "From: CDash <" . $CDASH_EMAIL_FROM . ">\nReply-To: " . $CDASH_EMAIL_REPLY . "\nContent-type: text/plain; charset=utf-8\nX-Mailer: PHP/" . phpversion() . "\nMIME-Version: 1.0");
             $xml .= add_XML_value("warning", "*The email has been sent successfully.");
         } else {
             $xml .= add_XML_value("warning", "*No email sent because the coverage is green.");
         }
     }
 }
 // end sendEmail
 // If we change the priority
 if (isset($_POST['prioritySelection'])) {
     $CoverageFile2User = new CoverageFile2User();
     $CoverageFile2User->ProjectId = $projectid;
     $CoverageFile2User->FullPath = htmlspecialchars(pdo_real_escape_string($_POST['fullpath']));
     $CoverageFile2User->SetPriority(pdo_real_escape_numeric($_POST['prioritySelection']));
 }
 /** We start generating the XML here */
 // Find the recent builds for this project
 if ($projectid > 0) {
     $xml .= "<project>";
     $xml .= add_XML_value("id", $Project->Id);
     $xml .= add_XML_value("name", $Project->GetName());
     $xml .= add_XML_value("name_encoded", urlencode($Project->GetName()));
     if ($buildid > 0) {
         $xml .= add_XML_value("buildid", $buildid);
     }
     $CoverageSummary = new CoverageSummary();