blob: 5b55e567ca46005522afde3616e784d9c6b82e9a [file] [log] [blame]
<?php require_once($_SERVER['DOCUMENT_ROOT'] . "/eclipse.org-common/system/app.class.php"); require_once($_SERVER['DOCUMENT_ROOT'] . "/eclipse.org-common/system/nav.class.php"); require_once($_SERVER['DOCUMENT_ROOT'] . "/eclipse.org-common/system/menu.class.php"); $App = new App(); $Nav = new Nav(); $Menu = new Menu(); include($App->getProjectCommon()); # All on the same line to unclutter the user's desktop'
/* 221934 - this page to remain on eclipse.org */
require_once($_SERVER['DOCUMENT_ROOT'] . "/projects/common/shared_functions.php");
$theme = '';
$pageTitle = "Submit IP Log to Eclipse Legal for ";
$pageKeywords = '';
$pageAuthor = '';
# Initiate session
$Session = $App->useSession("optional");
$Friend = $Session->getFriend();
$Nav->setLinkList(array()); // empty Nav
if( $Session->getBugzillaID() == 0 ) {
$Nav->addCustomNav("login", "http://dev.eclipse.org/site_login/", "", 1);
} else {
$Nav->addCustomNav("welcome<br>" . $Friend->getFirstName() . ' ' . $Friend->getLastName(),
"http://dev.eclipse.org/site_login/", "", 1);
}
preg_match('/^([a-z.0-9\-_,]+)$/', $_REQUEST['projectid'], $matches);
if(!isset($matches[1])) {
nice_die('You must specify a projectid parameter. This is not a standalone script.');
}
$pageTitle .= $matches[1];
$projectids = explode( ',', $matches[1] );
if (isset($_GET['test'])) {
echo "The following project ids are included: ";
print_r($projectids);
}
require_once("common/ip_log_common.php");
/*
* Check if the person is logged in and
* is a committer on any of the projects listed
*/
check_if_show_edit_form( $projectids, $Session, $Friend, false,
$ok_to_submit, $reason_no_edit_form, $logged_in_email_address );
ob_start();
?>
<div id="maincontent">
<div id="midcolumn">
<div style="width: 70%">
<?php if( $ok_to_submit ) {
if( count($_POST) ) {
$sql = "
INSERT INTO immediate_emails ( component, class, fromaddr, param1, param2, param3 )
VALUES ( 'portal/project_committer', 'send_iplog_to_legal',
'".addslashes($logged_in_email_address)."',
'" . addslashes($Friend->getFirstName() . ' ' . $Friend->getLastName()) . "',
'" . implode(",", $projectids) . "',
'" . addslashes($_POST['reason']) . "' )";
$App->portal_sql( $sql );
?>
<h1>IP Log Has Been Submitted</h1>
Thank you for submitting the
<?php
if( count($projectids) > 1 ) {
echo "unified ";
}
?>
IP Log for
<?php
if( count($projectids) == 1 ) {
echo $projectids[0];
} else {
$x = array_pop( $projectids );
$y = array_pop( $projectids );
$projectids[] = "$y and $x";
echo implode( ",", $projectids );
}
echo " ";
?>
to Eclipse Legal for review. Janet and her team will send you
further emails with questions and/or status (e.g., approval)
as they review the log. You must wait for official confirmation
of approval from Eclipse Legal before doing an official release.
<p>
Now that you have a few spare minutes, you might want to check
out your <a href="project.php?id=<?= $projectids[0] ?>">project summary page</a>
to update that information as well.
<?php
} else {
?>
<form method=POST>
<h1>Submit IP Log to Eclipse Legal</h1>
You are about to submit the
<?php
if( count($projectids) > 1 ) {
echo "unified ";
}
?>
IP Log for
<?php
if( count($projectids) == 1 ) {
echo $projectids[0];
} else {
$x = array_pop( $projectids );
$y = array_pop( $projectids );
$projectids[] = "$y and $x";
echo implode( ",", $projectids );
}
echo " ";
?>
to Eclipse Legal for review. Please explain to Janet and her team the purpose
and deadlined of the review (e.g., "release 1.0 on April 6th" or "just keeping our
IP log up-to-date, no release at this time"):<br>
<textarea cols="50" rows="10" name="reason"></textarea><p>
<input type="submit" name="B" value="Send IP Log to Eclipse Legal">
<p>
</form>
<?php
}
} else { ?>
<span style="color: red">Sorry,</span> you must be logged in as a committer on the project(s) before
you can submit the IP log to Eclipse Legal. Please <a href="http://dev.eclipse.org/site_login/">login</a>
and try again.
<p><?= $reason_no_edit_form ?>
<?php } ?>
</div>
</div><!-- midcolumn -->
</div><!-- maincontent -->
<?php
# Paste your HTML content between the EOHTML markers!
$html = ob_get_contents();
ob_end_clean();
# Generate the web page
$App->generatePage($theme, $Menu, $Nav, $pageAuthor, $pageKeywords, $pageTitle, $html);
?>