cvs: pearweb /public_html/pepr pepr-proposal-show.php
| From: | Tobias Schlitt | Date: | Wed, 21 Jan 2004 16:07:33 +0000 |
| Subject: | cvs: pearweb /public_html/pepr pepr-proposal-show.php | ||
| Groups: | php.pear.cvs | ||
| Request: | Send a blank email to pear-cvs+get-15840@lists.php.net to get a copy of this message | ||
toby Wed Jan 21 11:07:33 2004 EDT
Modified files:
/pearweb/public_html/pepr pepr-proposal-show.php
Log:
* Comments are now saved into database.
http://cvs.php.net/diff.php/pearweb/public_html/pepr/pepr-proposal-show.php?r1=1.9&r2=1.10&ty=u
Index: pearweb/public_html/pepr/pepr-proposal-show.php
diff -u pearweb/public_html/pepr/pepr-proposal-show.php:1.9
pearweb/public_html/pepr/pepr-proposal-show.php:1.10
--- pearweb/public_html/pepr/pepr-proposal-show.php:1.9 Mon Jan 19 08:22:52 2004
+++ pearweb/public_html/pepr/pepr-proposal-show.php Wed Jan 21 11:07:33 2004
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
| Authors: Tobias Schlitt <toby@php.net> |
+----------------------------------------------------------------------+
- $Id: pepr-proposal-show.php,v 1.9 2004/01/19 13:22:52 toby Exp $
+ $Id: pepr-proposal-show.php,v 1.10 2004/01/21 16:07:33 toby Exp $
*/
require_once 'pepr/pepr.php';
@@ -94,13 +94,11 @@
if ($form->validate()) {
$values = $form->exportValues();
$proposal->sendActionEmail('proposal_comment', 'user',
$_COOKIE['PEAR_USER'], $values['comment']);
+ $proposal->addComment($values['comment'], 'package_proposal_comments');
$form->removeElement('submit');
$form->addElement('static', '', '<b>Your comment has been sent
successfully!</b>');
$form->freeze();
- // if (!DEVBOX) {
- localredirect("pepr-proposal-show.php?id=".$proposal->id."&comment=1");
- // }
-
+ localredirect("pepr-proposal-show.php?id=".$proposal->id."&comment=1");
}
}
@@ -140,7 +138,7 @@
$bb->fullRow("<small>Sorry, BBCode facilities of PEPr have been temporarily siwtched
off, due to instabillities in BBCodeParser.</small>");
$bb->fullRow(nl2br($proposal->pkg_describtion));
- $changelog = @ppComment::getAll($dbh, $proposal->id);
+ $changelog = @ppComment::getAll($proposal->id, 'package_proposal_changelog');
$changeLogRow = "";
foreach ($changelog as $comment) {
if (!isset($userinfos[$comment->user_handle])) {
@@ -286,6 +284,7 @@
$bb->fullRow("Please login to comment or comment directly on
".make_link("pear-dev@lists.php.net",
"pear-dev@lists.php.net").".");
$bb->end();
}
+ echo "<p
align='center'>".make_link("/pepr/pepr-comments-show.php?id=".$proposal->id,
"View comments on this proposal.")."</p>";
} else {
$bb = new BorderBox("Vote on this proposal", "100%", "", 2, true);
$bb->fullRow("Voting is only enabled during 'Call for votes phase'.");