From d5cf2375dde5435917b901d472f11d4b7682671a Mon Sep 17 00:00:00 2001 From: Chris Morgan Date: Fri, 14 Sep 2007 23:27:36 -0400 Subject: [PATCH] =?UTF-8?q?Alexander=20Nicolaysen=20S=C3=B8rnes=20?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Use objectManager to delete monitors. --- appview.php | 23 +---------------------- include/version.php | 11 ++++++++--- 2 files changed, 9 insertions(+), 25 deletions(-) diff --git a/appview.php b/appview.php index 34c5895..f332ee3 100644 --- a/appview.php +++ b/appview.php @@ -8,7 +8,7 @@ * - iVersionId, version identifier * * Optional parameters: - * - sSub, action to perform ("delete", "unqueue", "Submit a new bug link.", "StartMonitoring", "StopMonitoring") + * - sSub, action to perform ("delete", "unqueue", "Submit a new bug link.") * - iBuglinkId, bug identifier to link a bug with a version * * TODO: @@ -25,7 +25,6 @@ require_once(BASE."include/appdb.php"); require_once(BASE."include/vote.php"); require_once(BASE."include/category.php"); require_once(BASE."include/maintainer.php"); -require_once(BASE."include/monitor.php"); /** @@ -113,26 +112,6 @@ if (isset($aClean['sSub'])) $oBuglink->create(); util_redirect_and_exit($oVersion->objectMakeUrl()); } - if($aClean['sSub'] == 'StartMonitoring') - { - $oMonitor = new Monitor(); - $oMonitor->iUserId = $_SESSION['current']->iUserId; - $oMonitor->iAppId = $aClean['iAppId']; - $oMonitor->iVersionId = $aClean['iVersionId']; - $oMonitor->create(); - util_redirect_and_exit($oVersion->objectMakeUrl()); - } - if($aClean['sSub'] == 'StopMonitoring') - { - $oMonitor = new Monitor(); - $oMonitor->find($_SESSION['current']->iUserId, $aClean['iVersionId']); - if($oMonitor->iMonitorId) - { - $oMonitor->delete(); - } - util_redirect_and_exit($oVersion->objectMakeUrl()); - } - } /** diff --git a/include/version.php b/include/version.php index 3488c43..b3428d3 100644 --- a/include/version.php +++ b/include/version.php @@ -899,9 +899,14 @@ class version { { echo ''."\n"; echo ''."\n"; - echo '
'."\n"; - echo ''."\n"; + echo '\n"; + echo "\tiMonitorId."\" />\n"; + echo "\t\n"; + echo "\t\n"; + echo "\tobjectMakeUrl()."\" />\n"; echo ''."\n"; echo "
\n"; echo "\n";